Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filter out redundant surface mesh vertices #340

Merged
merged 1 commit into from
Oct 2, 2023
Merged

Conversation

mdoube
Copy link
Member

@mdoube mdoube commented Sep 29, 2023

Triangles in the surface mesh share vertices but the vertices are repeated for every triangle in the mesh. This change reduces the number of points for the surface by 4-6× and should in principle reduce the time for brute-force all-to-all calculations used by Feret max by 16-36×. In testing on small meshes there is a several-fold speed up but not as much as predicted.

Triangles in the surface mesh share vertices but the vertices are
repeated for every triangle in the mesh. This change reduces the number
of points for the surface by 4-6× and should in principle reduce the
time for brute-force all-to-all calculations used by Feret max by
16-36×.
Copy link
Member

@alessandrofelder alessandrofelder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice. Changes LGTM.
Just as a comment because I don't know the PA code well: we're sure that no other part of the code relies on having those points more than once?

@mdoube
Copy link
Member Author

mdoube commented Oct 2, 2023

Nice. Changes LGTM. Just as a comment because I don't know the PA code well: we're sure that no other part of the code relies on having those points more than once?

Surface Area calculation requires the triangles to be complete, so it doesn't call the filtering method. Only ellipsoid fitting and feret max, which don't care about triangles, use the filtering method.

@mdoube mdoube merged commit a3b9ad2 into master Oct 2, 2023
1 check passed
@mdoube mdoube deleted the feret-performance branch October 2, 2023 23:21
mdoube added a commit that referenced this pull request Apr 5, 2024
Triangles in the surface mesh share vertices but the vertices are
repeated for every triangle in the mesh. This change reduces the number
of points for the surface by 4-6× and should in principle reduce the
time for brute-force all-to-all calculations used by Feret max by
16-36×.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants