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

Does this implementation not work for 2d points? #38

Open
raacampbell opened this issue Mar 21, 2024 · 0 comments
Open

Does this implementation not work for 2d points? #38

raacampbell opened this issue Mar 21, 2024 · 0 comments

Comments

@raacampbell
Copy link

I did some testing with the Python implementation and it seems that it fails with 2D point clouds. Is this expected? If so, it would be good if that was spelt out more clearly in the docs. If it was there I didn't see it. It might be a helpful feature to have.

A PointCloud must have three columns

In [35]: pc_zfix = PointCloud(x_f[:,0:2], columns=["x", "y"])
---------------------------------------------------------------------------
PointCloudException                       Traceback (most recent call last)
Cell In[35], line 1
----> 1 pc_zfix = PointCloud(x_f[:,0:2], columns=["x", "y"])

File ~/mambaforge/envs/icp/lib/python3.10/site-packages/simpleicp/pointcloud.py:42, in PointCloud.__init__(self, remapping, *args, **kwargs)
     40 for coordinate in ("x", "y", "z"):
     41     if coordinate not in self:
---> 42         raise PointCloudException(
     43             f'Column "{coordinate}" is missing in DataFrame.'
     44         )
     46 self._num_points = len(self)
     48 if "selected" not in self:

PointCloudException: Column "z" is missing in DataFrame.

Setting Z to zero causes errors when running ICP

I can just make a dummy Z column and set all the numbers in it to zero, but when I do that I see a lot of invalid value encountered in scalar divide messages and it not produce a meaningful answer. I tried this with both my own dataset and also the bunny dataset.

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

No branches or pull requests

1 participant