40 #ifndef PCL_MULTISCALE_FEATURE_PERSISTENCE_H_
41 #define PCL_MULTISCALE_FEATURE_PERSISTENCE_H_
43 #include <pcl/pcl_base.h>
44 #include <pcl/features/feature.h>
45 #include <pcl/point_representation.h>
46 #include <pcl/common/norms.h>
63 template <
typename Po
intSource,
typename Po
intFeature>
67 typedef boost::shared_ptr<MultiscaleFeaturePersistence<PointSource, PointFeature> >
Ptr;
68 typedef boost::shared_ptr<const MultiscaleFeaturePersistence<PointSource, PointFeature> >
ConstPtr;
93 boost::shared_ptr<std::vector<int> > &output_indices);
99 setScalesVector (std::vector<float> &scale_values) { scale_values_ = scale_values; }
102 inline std::vector<float>
114 inline FeatureEstimatorPtr
121 setPointRepresentation (
const FeatureRepresentationConstPtr& feature_representation) { feature_representation_ = feature_representation; }
124 inline FeatureRepresentationConstPtr
const
156 computeFeatureAtScale (
float &scale,
157 FeatureCloudPtr &features);
164 distanceBetweenFeatures (
const std::vector<float> &a,
165 const std::vector<float> &b);
171 calculateMeanFeature ();
177 extractUniqueFeatures ();
181 std::vector<float> scale_values_;
190 FeatureEstimatorPtr feature_estimator_;
192 std::vector<FeatureCloudPtr> features_at_scale_;
193 std::vector<std::vector<std::vector<float> > > features_at_scale_vectorized_;
194 std::vector<float> mean_feature_;
195 FeatureRepresentationConstPtr feature_representation_;
200 std::vector<std::list<size_t> > unique_features_indices_;
201 std::vector<std::vector<bool> > unique_features_table_;
205 #ifdef PCL_NO_PRECOMPILE
206 #include <pcl/features/impl/multiscale_feature_persistence.hpp>
FeatureRepresentationConstPtr const getPointRepresentation()
Get a pointer to the feature representation used when converting features into k-D vectors...
void setScalesVector(std::vector< float > &scale_values)
Method for setting the scale parameters for the algorithm.
FeatureEstimatorPtr getFeatureEstimator()
Getter method for the feature estimator.
std::vector< float > getScalesVector()
Method for getting the scale parameters vector.
virtual ~MultiscaleFeaturePersistence()
Empty destructor.
void setPointRepresentation(const FeatureRepresentationConstPtr &feature_representation)
Provide a pointer to the feature representation to use to convert features to k-D vectors...
pcl::Feature< PointSource, PointFeature >::Ptr FeatureEstimatorPtr
NormType
Enum that defines all the types of norms available.
void setDistanceMetric(NormType distance_metric)
Method for setting the distance metric that will be used for computing the difference between feature...
MultiscaleFeaturePersistence()
Empty constructor.
boost::shared_ptr< const MultiscaleFeaturePersistence< PointSource, PointFeature > > ConstPtr
void computeFeaturesAtAllScales()
Method that calls computeFeatureAtScale () for each scale parameter.
boost::shared_ptr< PointCloud< PointT > > Ptr
void setFeatureEstimator(FeatureEstimatorPtr feature_estimator)
Setter method for the feature estimator.
PointCloud represents the base class in PCL for storing collections of 3D points. ...
pcl::PointCloud< PointFeature > FeatureCloud
Generic class for extracting the persistent features from an input point cloud It can be given any Fe...
float getAlpha()
Get the value of the alpha parameter.
boost::shared_ptr< MultiscaleFeaturePersistence< PointSource, PointFeature > > Ptr
NormType getDistanceMetric()
Returns the distance metric that is currently used to calculate the difference between feature vector...
boost::shared_ptr< Feature< PointInT, PointOutT > > Ptr
pcl::PointCloud< PointFeature >::Ptr FeatureCloudPtr
boost::shared_ptr< const pcl::PointRepresentation< PointFeature > > FeatureRepresentationConstPtr
void setAlpha(float alpha)
Sets the alpha parameter.
void determinePersistentFeatures(FeatureCloud &output_features, boost::shared_ptr< std::vector< int > > &output_indices)
Central function that computes the persistent features.