-
Notifications
You must be signed in to change notification settings - Fork 153
Interior SDF seems to be wrong #475
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
Comments
cuRobo is not doing anything extra to handle SDF values in the interior. Here is the code:
cuRobo uses finite difference (central difference) to compute gradient given sdf:
Your link shows ways to improve interior SDF, have you used a particular one in the past? I still have to read them in detail to see which one would be easy to implement. One workaround is to merge all your spheres into a single mesh before creating the SDF. You can do that with:
|
Issue: CuRobo SDFs seem to be incorrect in the interior of "merged" objects.
Background: Boolean operations on SDFs are not trivial - given two SDFs A and B, the commonly performed approximation$sdf(A \cup B) = \max sd(A), sd(B)$ is correct outside the SDF, but a lower bound on the inside only. [more]
Details: It seems as if the SDF computation in CuRobo is following this approach, but I couldn't find any documentation regarding this. This "problem" would arise whenever multiple objects (meshes, primitives, ...) overlap and the signed distance is computed with a max operator. If this is the case, is there a way to get the correct interior SDF with curobo?
This might be beneficial for:
Example:
I wrote this small example to check my assumption. It creates a grid of overlapping spheres and then computes the signed distance between the grid and their center points. If the SDF was correct in its interior, the signed distances would differ. However, they do not:
The text was updated successfully, but these errors were encountered: