40 #ifndef PCL_RECOGNITION_CORRESPONDENCE_GROUPING_H_ 41 #define PCL_RECOGNITION_CORRESPONDENCE_GROUPING_H_ 43 #include <pcl/pcl_base.h> 44 #include <pcl/correspondence.h> 45 #include <pcl/console/print.h> 54 template <
typename Po
intModelT,
typename Po
intSceneT>
86 inline SceneCloudConstPtr
119 inline std::vector<double>
130 cluster (std::vector<Correspondences> &clustered_corrs);
169 PCL_ERROR (
"[initCompute] Scene not set.\n");
175 PCL_ERROR (
"[initCompute] Input not set.\n");
179 if (!model_scene_corrs_)
181 PCL_ERROR (
"[initCompute] Model-Scene Correspondences not set.\n");
200 #include <pcl/recognition/impl/cg/correspondence_grouping.hpp> 202 #endif // PCL_RECOGNITION_CORRESPONDENCE_GROUPING_H_ virtual void setSceneCloud(const SceneCloudConstPtr &scene)
Provide a pointer to the scene dataset.
SceneCloud::Ptr SceneCloudPtr
virtual ~CorrespondenceGrouping()
destructor.
virtual void clusterCorrespondences(std::vector< Correspondences > &clustered_corrs)=0
The actual clustering method, should be implemented by each subclass.
boost::shared_ptr< PointCloud< PointT > > Ptr
std::vector< double > getCharacteristicScales() const
Getter for the vector of characteristic scales associated to each cluster.
boost::shared_ptr< const Correspondences > CorrespondencesConstPtr
CorrespondenceGrouping()
Empty constructor.
virtual void setModelSceneCorrespondences(const CorrespondencesConstPtr &corrs)
Provide a pointer to the precomputed correspondences between points in the input dataset and points i...
CorrespondencesConstPtr model_scene_corrs_
The correspondences between points in the input and the scene datasets.
void cluster(std::vector< Correspondences > &clustered_corrs)
Clusters the input correspondences belonging to different model instances.
boost::shared_ptr< const PointCloud< PointT > > ConstPtr
PointCloud represents the base class in PCL for storing collections of 3D points. ...
bool deinitCompute()
This method should get called after finishing the actual computation.
SceneCloud::ConstPtr SceneCloudConstPtr
Abstract base class for Correspondence Grouping algorithms.
std::vector< double > corr_group_scale_
characteristic scale associated to each correspondence subset; if the cg algorithm can not handle sca...
SceneCloudConstPtr scene_
The scene cloud.
bool initCompute()
This method should get called before starting the actual computation.
PointCloudConstPtr input_
The input point cloud dataset.
CorrespondencesConstPtr getModelSceneCorrespondences() const
Getter for the precomputed correspondences between points in the input dataset and points in the scen...
pcl::PointCloud< PointSceneT > SceneCloud
SceneCloudConstPtr getSceneCloud() const
Getter for the scene dataset.