GithubHelp home page GithubHelp logo

Comments (11)

sgsellan avatar sgsellan commented on June 14, 2024 1

Hi EmJay!

The PR #32 should fix this issue. Running your command from above now works without issue (the boundary vertices are not remeshed). Once the PR is merged, you can either wait for the 0.0.3 release or build the library locally running pip install . Thanks for raising this issue and for using our library!

-Silvia

from gpytoolbox.

EmJay276 avatar EmJay276 commented on June 14, 2024 1

Hi Silvia,
thank you very much for the very fast fix and also adding the feature vector, that's exactly what I needed!
Michael

from gpytoolbox.

EmJay276 avatar EmJay276 commented on June 14, 2024 1

@sgsellan
Hi Silvia,
is it somehow possible to keep track of the "feature" vector or at least of the points which are removed?

Before remeshing I know which point is is on which face of my model (I need this info for edge detection / projection on the original surface - like a sphere / cylinder). But even the feature "points" change their index during remeshing.

Simplified example:

  • Input:
    • Points - P0 = [A, B, C, D, E]
    • Feature points - F0 = [A, B, E] (indices 0, 1, 4 in P0)
  • Remeshing removes point D
  • Output points - P1 = [A, B, C*, E]
  • Feature points now have the indices 0, 1, 3

I could try to find the index of each point of P1 in P0, but this seems very tedious and not very practical for large models.

-Michael

from gpytoolbox.

EmJay276 avatar EmJay276 commented on June 14, 2024 1

👍 I try to send the PR by end of the week

from gpytoolbox.

sgsellan avatar sgsellan commented on June 14, 2024

Hi EmJay! If I recall correctly, you must fix the boundary vertices as feature vertices for the method to work. Actually remising the boundary is not supported. Could you please attach the mesh you used and the exact command you ran to encounter this problem?

from gpytoolbox.

EmJay276 avatar EmJay276 commented on June 14, 2024

I will try to build a minimal example, my code / mesh is currently rather complicated (result of an toplogy optimization, I want to remesh partially).

from gpytoolbox.

EmJay276 avatar EmJay276 commented on June 14, 2024

Here is a minimal example

vertices_full, faces_full = gpytoolbox.read_mesh('mesh_full.obj')
U, G = gpytoolbox.remesh_botsch(vertices_full, faces_full)

Works fine

vertices_part, faces_part = gpytoolbox.read_mesh('mesh_part.obj')
U2, G2 = gpytoolbox.remesh_botsch(vertices_part, faces_part)

Process finished with exit code -1073741819 (0xC0000005)

meshes.zip

from gpytoolbox.

EmJay276 avatar EmJay276 commented on June 14, 2024

@sgsellan
My current workaround for this is too reorder the input, so all fixed nodes are at the beginning of the array.

A solution would be to also return the indices of the fixed nodes after the remesh.

from gpytoolbox.

sgsellan avatar sgsellan commented on June 14, 2024

Interesting workaround! I'll set a low priority to this but it's a nice / feasible thing to add to the remesher (would also be happy to merge a PR that did it 😉 !)

from gpytoolbox.

EmJay276 avatar EmJay276 commented on June 14, 2024

I can try to create a PR, but I'm not very familiar with C code. Don't count on me 😅

from gpytoolbox.

sgsellan avatar sgsellan commented on June 14, 2024

Oh, maybe even just a PR that only touches the python code in src/gpytoolbox/remesh_botsch.py to reorder the mesh such that feature vertices are first and calls the C++ remesher like in your hotfix? We could just add in the documentation that the n fixed vertices are returned first. After all, the output ordering right now is arbitrary.

from gpytoolbox.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.