44 #include <pcl/features/feature.h>
80 template <
typename Po
intInT,
typename Po
intNT,
typename Po
intOutT = pcl::PFHSignature125>
84 using Ptr = shared_ptr<PFHEstimation<PointInT, PointNT, PointOutT> >;
85 using ConstPtr = shared_ptr<const PFHEstimation<PointInT, PointNT, PointOutT> >;
103 d_pi_ (1.0f / (2.0f * static_cast<float> (
M_PI))),
106 max_cache_size_ ((1ul*1024ul*1024ul*1024ul) / sizeof (std::pair<std::pair<int, int>,
Eigen::Vector4f>))
167 int p_idx,
int q_idx,
float &f1,
float &f2,
float &f3,
float &f4);
179 const pcl::Indices &indices,
int nr_split, Eigen::VectorXf &pfh_histogram);
206 std::map<std::pair<int, int>, Eigen::Vector4f, std::less<>, Eigen::aligned_allocator<std::pair<const std::pair<int, int>, Eigen::Vector4f> > >
feature_map_;
219 #ifdef PCL_NO_PRECOMPILE
220 #include <pcl/features/impl/pfh.hpp>
Feature represents the base feature class.
shared_ptr< Feature< PointInT, PointOutT > > Ptr
std::string feature_name_
The feature name.
shared_ptr< const Feature< PointInT, PointOutT > > ConstPtr
PFHEstimation estimates the Point Feature Histogram (PFH) descriptor for a given point cloud dataset ...
void computePointPFHSignature(const pcl::PointCloud< PointInT > &cloud, const pcl::PointCloud< PointNT > &normals, const pcl::Indices &indices, int nr_split, Eigen::VectorXf &pfh_histogram)
Estimate the PFH (Point Feature Histograms) individual signatures of the three angular (f1,...
bool computePairFeatures(const pcl::PointCloud< PointInT > &cloud, const pcl::PointCloud< PointNT > &normals, int p_idx, int q_idx, float &f1, float &f2, float &f3, float &f4)
Compute the 4-tuple representation containing the three angles and one distance between two points re...
float d_pi_
Float constant = 1.0 / (2.0 * M_PI)
int f_index_[3]
Placeholder for a histogram index.
void computeFeature(PointCloudOut &output) override
Estimate the Point Feature Histograms (PFH) descriptors at a set of points given by <setInputCloud ()...
Eigen::VectorXf pfh_histogram_
Placeholder for a point's PFH signature.
Eigen::Vector4f pfh_tuple_
Placeholder for a PFH 4-tuple.
PFHEstimation()
Empty constructor.
int nr_subdiv_
The number of subdivisions for each angular feature interval.
void setUseInternalCache(bool use_cache)
Set whether to use an internal cache mechanism for removing redundant calculations or not.
bool getUseInternalCache()
Get whether the internal cache is used or not for computing the PFH features.
bool use_cache_
Set to true to use the internal cache for removing redundant computations.
unsigned int max_cache_size_
Maximum size of internal cache memory.
void setMaximumCacheSize(unsigned int cache_size)
Set the maximum internal cache size.
std::queue< std::pair< int, int > > key_list_
Queue of pairs saved, used to constrain memory usage.
typename Feature< PointInT, PointOutT >::PointCloudOut PointCloudOut
std::map< std::pair< int, int >, Eigen::Vector4f, std::less<>, Eigen::aligned_allocator< std::pair< const std::pair< int, int >, Eigen::Vector4f > > > feature_map_
Internal hashmap, used to optimize efficiency of redundant computations.
unsigned int getMaximumCacheSize()
Get the maximum internal cache size.
Defines all the PCL implemented PointT point type structures.
IndicesAllocator<> Indices
Type used for indices in PCL.