ouster-lidar / ouster-sdk

Ouster, Inc. sample code
Other
469 stars 438 forks source link

Removing ground points #466

Closed Shibaditya99 closed 1 year ago

Shibaditya99 commented 1 year ago

How to remove ground points from 2D range view(client.ChanField.RANGE)? is there any API or algo available in the ouster SDK to remove ground points in the 2D data field?

Samahu commented 1 year ago

The SDK doesn't have offer an API for this type of task, you would need to use a third party library to achieve this. There are many way you could approach this problem and it depends on your scene and setup, is the ground fully planar, is the distance to the ground plane fixed, if your setup is like this then you can easily filter the points with a thin box filter. If it is more than that you would need to perform segmentation of the scene and detect any planar structures in you scene. Checkout this PCL tutorial on planar segmentation and then you can take the output and filter the ground based on indices that fall within a plane.

Ussama

Samahu commented 1 year ago

Also Open3D offers a similar functionality, checkout their Plane Segmentation Example.