Problems detecting plane in pointcloud data using detectRectangularPlanePoints
14 views (last 30 days)
Show older comments
Hello everyone,
I'm having trouble using the detectRectangularPlanePoints() function from the Lidar Toolbox. At the moment I'm working on a lidar and camera calibration, as described here. I've referred to the guide on the Lidar Camera Calibrator to do this and collected data following the Calibration Guidelines. The pointcloud data was captured using a Velodyne Alpha Prime (128-Layer) lidar sensor. After loading the data in the LidarCameraCalibrator all of the data pairs were rejected as the board wasn't detected in the lidar data. I've managed to get plausible results for the calibration by selecting the board manually in the lidar data. However I would like to understand why the automatic detection doesn't work, as the manual selection is very tedious.
Because the LidarCameraCalibrator uses the detectRectangularPlanePoints() function to detect the board I've started my troubleshooting there. For that I followed along the example given in the documentation. The problem can be reproduced using the code from the example and loading the attached .pcd file. The board size is 700x900mm. So far I've tried changing the parameters to get better results, namely reducing the MinDistance parameter as I'm using a high resolution lidar. I've tried a lot of other settings and combinations as well (higher DimensionTolerance ...) but still currently I'm not able to detect the calibration board automatically in any of the pointcloud data I've tried. As the function is relatively new I haven't been able to find a lot of information on it ,so I would be greatful for any ideas on where I went wrong.
Thanks a lot in advance!
0 Comments
Answers (1)
Akshat Dalal
on 13 Oct 2023
Hi Nick,
I understand you are facing some issue while using the ‘detectRectangularPlanePoints’ function from the Lidar Toolbox. You can troubleshoot by adjusting input parameters to refine your result.
In the processing of ‘detectRectangularPlanePoints’ function, clustering of point clouds is performed before plane detection. Therefore, it is necessary to avoid considering the point cloud of the checkerboard as part of the larger plane in the background.
The code for ‘detectRectangularPlanePoints’ can be expanded to deeper levels by right-clicking, allowing you to navigate through the code. It is recommended to set breakpoints within ‘lidar.internal.calibration.extractRectangle’ and pause the execution to examine the results of ‘pcsegdist’ using ‘pcshow’ while proceeding. By following this approach, you can debug within ‘lidar.internal.calibration.extractRectangle’ and inspect the results of ‘pcsegdist’ using ‘pcshow’ as you progress through the code.
You can also refer to the following documentations to learn more –
0 Comments
See Also
Categories
Find more on Preprocessing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!