-
Notifications
You must be signed in to change notification settings - Fork 74
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
[Question] Sub-sampling method #86
Comments
Hello @maximecharriere , This is very interesting question and experiment that you made. I am suspecting our sampling algorithm to be the cause of many of the wrong results we get with the library. Unfortunately I couldn't find time to investigate on this question. @sgiraudot shall we update the documentation of the cgal wrapper to encourage users to subsample using cgal instead of OpenGR ? Sampling is performed by hashing the coordinates of the input point cloud in a 3d grid, and keep only one representative sample per voxel. The resolution of the grid is computed according to the parameter (source code: https://github.com/STORM-IRIT/OpenGR/blob/master/src/gr/utils/sampling.h#L100) I see a simple way to improve the performances of the sampling algorithm, which is to pre-rotate the input point cloud so it is aligned with the xyz coordinates of the grid (see call to the sampler here: https://github.com/STORM-IRIT/OpenGR/blob/master/src/gr/algorithms/matchBase.hpp#L275). |
CGAL offers 3 subsampling algorithms for point clouds : grid (pretty much the same as you describe for OpenGR), random (self-explanatory) and hierarchical (which uses recursive subdivisions along PCA and thus is supposed to simplify more on planar regions). This last one might be interesting for registration but I wouldn't recommend it before being sure of this. The algorithm cited in this issue is a remeshing algorithm which means that users need meshes as input (not raw point clouds). I'm glad it does bring good results with registration, but it seems quite specialized (and unusable for point clouds in general). |
Hello,
I was wondering what was the method behind the sub-sampling parameterized with Number of samples (-n).
I have a 3D scan with 50k points and a reference with 500pts.
If I sub-sample the scan with
CGAL::Polygon_mesh_processing::isotropic_remeshing()
to get 1k points and use :(Note the large N to avoid subsampling by OpenGr)
The result is perfect.
But if I don't sub-sample and directly use:
(Note the N of 1k samples)
I'm getting a bad result.
So I was wondering what sub-sampling method OpenGr uses.
Does it takes N points at random or the first N points?
The text was updated successfully, but these errors were encountered: