resistration of 2 clouds from kinect sensor

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

resistration of 2 clouds from kinect sensor

jun nyukai
I want to resister 2 point clouds from kinect sensor.
I resister as the below step 1 - 5.

1. remove the noise point. (pcl::StatisticalOutlierRemoval)
2.  voxeling the point. (pcl::VoxelGrid)
3. detect key points and features. (pcl::SIFTKeypoint, FPFH)
4. calculate the initial affine matrix (pcl::SampleConsensusInitialAlignment)
5. calculate the final affine matrix (pcl::IterativeClosestPoint)

But, I can't get the initial affine matrix.
I set the parameter as the below.

3. detect key points

  float nr_scales = 8;
  float nr_scale_per_octave = 8;
  float min_constrast = 0.3;
 
  // sift3D->setScales(0.01, 3, 2);//0.1
  sift3D->setScales(min_scale, nr_scales, nr_scale_per_octave);//0.1
  sift3D->setMinimumContrast(min_constrast);

// FPFH

  pcl::Feature<pcl::PointXYZRGB, pcl::FPFHSignature33>::Ptr feature_extractor_ (new pcl::FPFHEstimationOMP<pcl::PointXYZRGB, pcl::Normal, pcl::FPFHSignature33>);
  feature_extractor_->setSearchMethod (pcl::search::Search<pcl::PointXYZRGB>::Ptr (new pcl::search::KdTree<pcl::PointXYZRGB>));
  feature_extractor_->setRadiusSearch (0.05);//25

  pcl::PointCloud<pcl::PointXYZRGB>::Ptr kpts(new pcl::PointCloud<pcl::PointXYZRGB>);
  kpts->points.resize(keypoints->points.size());

  pcl::copyPointCloud(*keypoints, *kpts);
  //passo da XYZRGB a XYZRGB
  pcl::FeatureFromNormals<pcl::PointXYZRGB, pcl::Normal, pcl::FPFHSignature33>::Ptr feature_from_normals = boost::dynamic_pointer_cast<pcl::FeatureFromNormals<pcl::PointXYZRGB, pcl::Normal, pcl::FPFHSignature33> > (feature_extractor_);
  feature_extractor_->setInputCloud(kpts);

  pcl::PointCloud<pcl::Normal>::Ptr normals (new  pcl::PointCloud<pcl::Normal>);
  pcl::NormalEstimation<pcl::PointXYZRGB, pcl::Normal> normal_estimation;
  normal_estimation.setSearchMethod (pcl::search::Search<pcl::PointXYZRGB>::Ptr (new pcl::search::KdTree<pcl::PointXYZRGB>));

  normal_estimation.setRadiusSearch (0.05);//20
  normal_estimation.setInputCloud (kpts);//input, ho messo kpts per accelerare

  normal_estimation.compute (*normals);
  feature_from_normals->setInputNormals(normals);
  feature_extractor_->compute (*features);

4. calculate the initial affine matrix.

  pcl::SampleConsensusInitialAlignment<pcl::PointXYZRGB,pcl::PointXYZRGB,pcl::FPFHSignature33> sacIA;

  sacIA.setMaxCorrespondenceDistance(0.5);
  sacIA.setMaximumIterations(100);
  sacIA.setNumberOfSamples(5);

5.  calculate the final affine matrix.

  pcl::IterativeClosestPoint<pcl::PointXYZRGB, pcl::PointXYZRGB> icp;
  icp.setMaximumIterations(500);
  icp.setRANSACOutlierRejectionThreshold(0.05);
  icp.setMaxCorrespondenceDistance(0.1);

Please let me know about the appropriate parameters.

Reply | Threaded
Open this post in threaded view
|

Re: resistration of 2 clouds from kinect sensor

Jochen Sprickerhof
Administrator
Hi Jun,

* jun nyukai <[hidden email]> [2014-01-28 20:34]:
> Please let me know about the appropriate parameters.

The parameters depend on your input cloud, there are no magic values.
Have a look at the Presentation by Suat for a working version:
http://www.pointclouds.org/media/iccv2011.html

Cheers Jochen

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

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: resistration of 2 clouds from kinect sensor

saimanoj18
Here is a good work 

http://www.pointclouds.org/assets/uploads/cglibs13_registration_small.pdf

This provides different steps you can use for registration and mapping
 
With all Good wishes,
Sai Manoj Prakhya


On Wednesday, 29 January 2014 3:47 PM, Jochen Sprickerhof <[hidden email]> wrote:
Hi Jun,

* jun nyukai <[hidden email]> [2014-01-28 20:34]:
> Please let me know about the appropriate parameters.


The parameters depend on your input cloud, there are no magic values.
Have a look at the Presentation by Suat for a working version:
http://www.pointclouds.org/media/iccv2011.html

Cheers Jochen





_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: resistration of 2 clouds from kinect sensor

drHogan
In reply to this post by jun nyukai
Hi Jun,

i'm trying to do basically the same, but as explained in another post, i have some issues with the SampleConsensusInitialAlignment that somehow doesn't seem to work during the linking of the project. did you do anything special to make it work? (or in the cmakelists or somewhere else?)

Best,
H