Point Cloud Library (PCL)
1.8.1
|
Abstract base class for Correspondence Grouping algorithms. More...
#include <pcl/recognition/cg/correspondence_grouping.h>
Public Types | |
typedef pcl::PointCloud< PointSceneT > | SceneCloud |
typedef SceneCloud::Ptr | SceneCloudPtr |
typedef SceneCloud::ConstPtr | SceneCloudConstPtr |
![]() | |
typedef pcl::PointCloud< PointModelT > | PointCloud |
typedef PointCloud::Ptr | PointCloudPtr |
typedef PointCloud::ConstPtr | PointCloudConstPtr |
typedef boost::shared_ptr< PointIndices > | PointIndicesPtr |
typedef boost::shared_ptr< PointIndices const > | PointIndicesConstPtr |
Public Member Functions | |
CorrespondenceGrouping () | |
Empty constructor. More... | |
virtual | ~CorrespondenceGrouping () |
destructor. More... | |
virtual void | setSceneCloud (const SceneCloudConstPtr &scene) |
Provide a pointer to the scene dataset. More... | |
SceneCloudConstPtr | getSceneCloud () const |
Getter for the scene dataset. More... | |
virtual void | setModelSceneCorrespondences (const CorrespondencesConstPtr &corrs) |
Provide a pointer to the precomputed correspondences between points in the input dataset and points in the scene dataset. More... | |
CorrespondencesConstPtr | getModelSceneCorrespondences () const |
Getter for the precomputed correspondences between points in the input dataset and points in the scene dataset. More... | |
std::vector< double > | getCharacteristicScales () const |
Getter for the vector of characteristic scales associated to each cluster. More... | |
void | cluster (std::vector< Correspondences > &clustered_corrs) |
Clusters the input correspondences belonging to different model instances. More... | |
![]() | |
PCLBase () | |
Empty constructor. More... | |
PCLBase (const PCLBase &base) | |
Copy constructor. More... | |
virtual | ~PCLBase () |
Destructor. More... | |
virtual void | setInputCloud (const PointCloudConstPtr &cloud) |
Provide a pointer to the input dataset. More... | |
PointCloudConstPtr const | getInputCloud () const |
Get a pointer to the input point cloud dataset. More... | |
virtual void | setIndices (const IndicesPtr &indices) |
Provide a pointer to the vector of indices that represents the input data. More... | |
virtual void | setIndices (const IndicesConstPtr &indices) |
Provide a pointer to the vector of indices that represents the input data. More... | |
virtual void | setIndices (const PointIndicesConstPtr &indices) |
Provide a pointer to the vector of indices that represents the input data. More... | |
virtual void | setIndices (size_t row_start, size_t col_start, size_t nb_rows, size_t nb_cols) |
Set the indices for the points laying within an interest region of the point cloud. More... | |
IndicesPtr const | getIndices () |
Get a pointer to the vector of indices used. More... | |
IndicesConstPtr const | getIndices () const |
Get a pointer to the vector of indices used. More... | |
const PointModelT & | operator[] (size_t pos) const |
Override PointCloud operator[] to shorten code. More... | |
Protected Member Functions | |
virtual void | clusterCorrespondences (std::vector< Correspondences > &clustered_corrs)=0 |
The actual clustering method, should be implemented by each subclass. More... | |
bool | initCompute () |
This method should get called before starting the actual computation. More... | |
bool | deinitCompute () |
This method should get called after finishing the actual computation. More... | |
![]() | |
bool | initCompute () |
This method should get called before starting the actual computation. More... | |
bool | deinitCompute () |
This method should get called after finishing the actual computation. More... | |
Protected Attributes | |
SceneCloudConstPtr | scene_ |
The scene cloud. More... | |
CorrespondencesConstPtr | model_scene_corrs_ |
The correspondences between points in the input and the scene datasets. More... | |
std::vector< double > | corr_group_scale_ |
characteristic scale associated to each correspondence subset; if the cg algorithm can not handle scale invariance, the size of the vector will be 0. More... | |
![]() | |
PointCloudConstPtr | input_ |
The input point cloud dataset. More... | |
IndicesPtr | indices_ |
A pointer to the vector of point indices to use. More... | |
bool | use_indices_ |
Set to true if point indices are used. More... | |
bool | fake_indices_ |
If no set of indices are given, we construct a set of fake indices that mimic the input PointCloud. More... | |
Abstract base class for Correspondence Grouping algorithms.
Definition at line 55 of file correspondence_grouping.h.
typedef pcl::PointCloud<PointSceneT> pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::SceneCloud |
Definition at line 58 of file correspondence_grouping.h.
typedef SceneCloud::ConstPtr pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::SceneCloudConstPtr |
Definition at line 60 of file correspondence_grouping.h.
typedef SceneCloud::Ptr pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::SceneCloudPtr |
Definition at line 59 of file correspondence_grouping.h.
|
inline |
Empty constructor.
Definition at line 63 of file correspondence_grouping.h.
|
inlinevirtual |
destructor.
Definition at line 66 of file correspondence_grouping.h.
References pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::model_scene_corrs_, and pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::scene_.
void pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::cluster | ( | std::vector< Correspondences > & | clustered_corrs | ) |
Clusters the input correspondences belonging to different model instances.
[out] | clustered_corrs | a vector containing the correspondences for each instance of the model found within the input data. |
Definition at line 44 of file correspondence_grouping.hpp.
|
protectedpure virtual |
The actual clustering method, should be implemented by each subclass.
[out] | clustered_corrs | a vector containing the correspondences for each instance of the model found within the input data. |
Implemented in pcl::Hough3DGrouping< PointModelT, PointSceneT, PointModelRfT, PointSceneRfT >, and pcl::GeometricConsistencyGrouping< PointModelT, PointSceneT >.
|
inlineprotected |
This method should get called after finishing the actual computation.
Definition at line 192 of file correspondence_grouping.h.
|
inline |
Getter for the vector of characteristic scales associated to each cluster.
Definition at line 120 of file correspondence_grouping.h.
References pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::corr_group_scale_.
|
inline |
Getter for the precomputed correspondences between points in the input dataset and points in the scene dataset.
Definition at line 110 of file correspondence_grouping.h.
References pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::model_scene_corrs_.
|
inline |
Getter for the scene dataset.
Definition at line 87 of file correspondence_grouping.h.
References pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::scene_.
|
inlineprotected |
This method should get called before starting the actual computation.
Internally, initCompute() does the following:
Definition at line 160 of file correspondence_grouping.h.
References pcl::PCLBase< PointModelT >::input_, pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::model_scene_corrs_, and pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::scene_.
|
inlinevirtual |
Provide a pointer to the precomputed correspondences between points in the input dataset and points in the scene dataset.
The correspondences are going to be clustered into different model hypotheses by the algorithm.
[in] | corrs | the correspondences between the model and the scene. |
Reimplemented in pcl::Hough3DGrouping< PointModelT, PointSceneT, PointModelRfT, PointSceneRfT >.
Definition at line 99 of file correspondence_grouping.h.
References pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::model_scene_corrs_.
|
inlinevirtual |
Provide a pointer to the scene dataset.
[in] | scene | the const boost shared pointer to a PointCloud message. |
Reimplemented in pcl::Hough3DGrouping< PointModelT, PointSceneT, PointModelRfT, PointSceneRfT >.
Definition at line 77 of file correspondence_grouping.h.
References pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::scene_.
|
protected |
characteristic scale associated to each correspondence subset; if the cg algorithm can not handle scale invariance, the size of the vector will be 0.
Definition at line 143 of file correspondence_grouping.h.
Referenced by pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::getCharacteristicScales().
|
protected |
The correspondences between points in the input and the scene datasets.
Definition at line 139 of file correspondence_grouping.h.
Referenced by pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::getModelSceneCorrespondences(), pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::initCompute(), pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::setModelSceneCorrespondences(), pcl::Hough3DGrouping< PointModelT, PointSceneT, PointModelRfT, PointSceneRfT >::setModelSceneCorrespondences(), and pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::~CorrespondenceGrouping().
|
protected |
The scene cloud.
Definition at line 134 of file correspondence_grouping.h.
Referenced by pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::getSceneCloud(), pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::initCompute(), pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::setSceneCloud(), pcl::Hough3DGrouping< PointModelT, PointSceneT, PointModelRfT, PointSceneRfT >::setSceneCloud(), and pcl::CorrespondenceGrouping< PointModelT, PointSceneT >::~CorrespondenceGrouping().