ShapeWorks icon indicating copy to clipboard operation
ShapeWorks copied to clipboard

Optimization: Image spacing greatly affects surface sampling

Open akenmorris opened this issue 3 years ago • 4 comments

I am not sure quite why, but there are significant differences in surface sampling depending on the image spacing. The same image at 0.05x0.05x0.05 propagates particles at a much faster rate than the same image with 1x1x1 spacing. Moreover, it requires a larger narrow band.

I don't see any reason why ShapeWorks should operate so much differently depending on the scale.

Can this be easily fixed? Ideally, I would expect that particles should propagate at the same relative speed (e.g. take the same number of iterations to reach the other side of an object).

Somewhere it seems that we have an opposite relationship set up such that a smaller spacing image generates larger forces than a larger spacing image, when in fact the opposite should be true.

akenmorris avatar Apr 30 '21 16:04 akenmorris

This also relates to splitting epsilon, especially for contour domain: a large split(that's unaware of contour scale) will cause particles to swap

medakk avatar May 09 '21 06:05 medakk

Regarding the splitting for contour domain, I have modified it to use average edge length. Additionally, I have modified the update gradient clamping to be a function of distance to closest neighbor. This seem to have solved problems with contour domain splitting. This is in #1235

medakk avatar May 14 '21 15:05 medakk

Is this a feature request or a bug? Both?

cchriste avatar Oct 13 '21 00:10 cchriste

Rather an improvment.

sheryjoe avatar Oct 13 '21 13:10 sheryjoe