OrganizedMultiPlaneSegmentation refinement step seems to not work

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

OrganizedMultiPlaneSegmentation refinement step seems to not work

Kaju Bubanja
I am trying to segment 3 planes, the floor and two sides of a cube as can be
seen in this picture:
<http://www.pcl-users.org/file/t499392/image396.png>
I'm using this code with following parameters:
ne_.setNormalEstimationMethod(ne_.COVARIANCE_MATRIX);
ne_.setMaxDepthChangeFactor(0.02);
ne_.setDepthDependentSmoothing(true);
ne_.setNormalSmoothingSize(40.0);
ne_.setInputCloud(cloud);
ne_.compute(*cloud_normals);
std::vector<pcl::ModelCoefficients> model_coefficients;
std::vector<pcl::PointIndices> inlier_indices;
pcl::PointCloud<pcl::Label>::Ptr labels(new pcl::PointCloud<pcl::Label>);
std::vector<pcl::PointIndices> label_indices;
std::vector<pcl::PointIndices> boundary_indices;
unsigned int min_linliers = 1000;
mps_.setMinInliers(min_linliers);
mps_.setMaximumCurvature(0.002);
mps_.setAngularThreshold(pcl::deg2rad(1));
mps_.setDistanceThreshold(0.03);
mps_.setInputNormals(cloud_normals);
mps_.setInputCloud(cloud);
mps_.segmentAndRefine(regions_, model_coefficients, inlier_indices, labels,
label_indices, boundary_indices);
mps_.setAngularThreshold(pcl::deg2rad(1));
mps_.setDistanceThreshold(0.03);
mps_.setInputNormals(cloud_normals);
mps_.setInputCloud(cloud);
mps_.segmentAndRefine(regions_, model_coefficients, inlier_indices, labels,
label_indices, boundary_indices);

I found out about how OrganizedMultiPlaneSegmentation works by looking at
these slides:
http://www.pointclouds.org/assets/icra2013/pcl_organized_segmentation.pdf
Now looking at the planes I get it looks like the refinement step does not
happen or the parameters are wrong.
Here a picture of the normals, they look pretty normal ;) to me. And a
picture of the segmented plane. As I understand the algorithm includes the
bottom points because the change in normals is smooth and it
angular_threshold only looks at neighbours, so far so good, but when doing
the refinement and comparing the normals of the floor points they should get
filtered out? Is this right or am I missing something?
<http://www.pcl-users.org/file/t499392/normals.png>
<http://www.pcl-users.org/file/t499392/planes_detected.png>



--
Sent from: http://www.pcl-users.org/
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users