Parallel version of "Mesh.ExplodeAtUnweldedEdges()"?

For medical mesh segmentation the method ExplodeAtUnweldedEdges() is crucial to me (in combination with Unweld & Weld). Unfortunately this method is really slow on huge meshes. A 300.000 MeshFaces mesh takes 3.2 minutes on my 3.2/3.7Ghz i7 3039 machine. 3.2 seconds would be bearable…

So, is there any chance that this method could run in parallel? Or is there anything else I can do to speed it up? The source code can reveal if there’s some exponential stuff going on there, or whatever reason for it being so slow. Knowing why could give hints about how I could (perhaps) prepare my meshes to reduce the processing time. 3.2 minutes is way way off for my use case.

Any other approach to achieve a similar segmentation functionality?


[Edit] - I tried to split the 300.000 face mesh into two and disjoint them in parallel (just a simple Mesh[2] parallel loop) and reduced the time to 54sec. 2 x 54 sec = 1:52 min is a significant reduction from 3.2 minues (single mesh, single thread). This could be an indication, although not certain, that there’s some kind of O(N^2) phenomenon going on in the ExplodeAtUnweldedEdges() method. Anyone?

// Rolf

Moved to Rhino Developer category

Hi @RIL,

Can you provide a mesh that exhibits this slowness?

Thanks,

– Dale

Yes, i tried to upload the mesh (in a internalized zipped gh file) to Rhino - Upload to Support but I keep getting “server error”.

image

// Rolf

Hi @RIL,

The upload site seems to work from here. But you can always use dropbox, etc.

– Dale

Strange, it consistently refuses to upload from here. Tried different browsers etc.

Anyway, I send a mail (dale & tech) with download info.

// Rolf

Thanks Rolf, I’ve opened an issue.

https://mcneel.myjetbrains.com/youtrack/issue/RH-56313

– Dale

1 Like

14 posts were split to a new topic: Show unwelded edges?