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

✨ Create the function ComputeClosestPoint to speedup the que… #6719

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

sebastienmascha
Copy link
Contributor

@sebastienmascha sebastienmascha commented Mar 25, 2024

Computes the closest point on the surface of the scene to a single query point.

This function calculates the closest point on any surface within the scene to the provided query point.
It's optimized for single-point queries, making it suitable for applications that require precise, real-time calculations of nearest surface points, such as collision detection or interactive simulations.

Type

Motivation and Context

  • It speeds up the query when you just have a point cloud and you want to do registration for instance.

Checklist:

  • I have run python util/check_style.py --apply to apply Open3D code style
    to my code.
  • This PR changes Open3D behavior or adds new functionality.
    • Both C++ (Doxygen) and Python (Sphinx / Google style) documentation is
      updated accordingly.
    • I have added or updated C++ and / or Python unit tests OR included test
      results
      (e.g. screenshots or numbers) here.
  • I will follow up and update the code if CI fails.
  • For fork PRs, I have selected Allow edits from maintainers.

Copy link

update-docs bot commented Mar 25, 2024

Thanks for submitting this pull request! The maintainers of this repository would appreciate if you could update the CHANGELOG.md based on your changes.

Copy link
Contributor

@benjaminum benjaminum left a comment

Choose a reason for hiding this comment

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

@sebastienmascha Thanks for this PR!
Do you have a runtime comparison for the new function compared to the function processing multiple queries?
About the application using this function, do you use this from C++ or from Python?
Would there be a significant performance drop with using the O3D Tensor?

query point. The shape is {3}, and the format is [x, y, z], indicating
the coordinates of the closest surface point.

Note:
Copy link
Contributor

Choose a reason for hiding this comment

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

The code commits the scene if necessary. Is there a reason for adding this note?

Computes the closest point on the surface of the scene to a single query point.

Args:
query_point (open3d.core.Tensor): A tensor with 1 dim, shape {3},
Copy link
Contributor

Choose a reason for hiding this comment

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

Input and output are not o3d Tensors but numpy arrays because the function uses Eigen::Vector3.

@ssheorey ssheorey added the status / needs info Waiting for information from reporter / author label May 1, 2024
@benjaminum
Copy link
Contributor

@sebastienmascha Just wanted to ask if you need info from us or help for this PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status / needs info Waiting for information from reporter / author
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Speedup the ComputeClosestPoint query for a single 3D Point
3 participants