Point Cloud Library (PCL)
1.14.1-dev
|
HeadBasedSubclustering represents a class for searching for people inside a HeightMap2D based on a 3D head detection algorithm More...
#include <pcl/people/head_based_subcluster.h>
Public Types | |
using | PointCloud = pcl::PointCloud< PointT > |
using | PointCloudPtr = typename PointCloud::Ptr |
using | PointCloudConstPtr = typename PointCloud::ConstPtr |
Public Member Functions | |
HeadBasedSubclustering () | |
Constructor. More... | |
virtual | ~HeadBasedSubclustering () |
Destructor. More... | |
void | subcluster (std::vector< pcl::people::PersonCluster< PointT > > &clusters) |
Compute subclusters and return them into a vector of PersonCluster. More... | |
void | mergeClustersCloseInFloorCoordinates (std::vector< pcl::people::PersonCluster< PointT > > &input_clusters, std::vector< pcl::people::PersonCluster< PointT > > &output_clusters) |
Merge clusters close in floor coordinates. More... | |
void | createSubClusters (pcl::people::PersonCluster< PointT > &cluster, int maxima_number_after_filtering, std::vector< int > &maxima_cloud_indices_filtered, std::vector< pcl::people::PersonCluster< PointT > > &subclusters) |
Create subclusters centered on the heads position from the current cluster. More... | |
void | setInputCloud (PointCloudPtr &cloud) |
Set input cloud. More... | |
void | setGround (Eigen::VectorXf &ground_coeffs) |
Set the ground coefficients. More... | |
void | setSensorPortraitOrientation (bool vertical) |
Set sensor orientation to landscape mode (false) or portrait mode (true). More... | |
void | setHeadCentroid (bool head_centroid) |
Set head_centroid_ to true (person centroid is in the head) or false (person centroid is the whole body centroid). More... | |
void | setInitialClusters (std::vector< pcl::PointIndices > &cluster_indices) |
Set initial cluster indices. More... | |
void | setHeightLimits (float min_height, float max_height) |
Set minimum and maximum allowed height for a person cluster. More... | |
void | setDimensionLimits (int min_points, int max_points) |
Set minimum and maximum allowed number of points for a person cluster. More... | |
void | setMinimumDistanceBetweenHeads (float heads_minimum_distance) |
Set minimum distance between persons' heads. More... | |
void | getHeightLimits (float &min_height, float &max_height) |
Get minimum and maximum allowed height for a person cluster. More... | |
void | getDimensionLimits (int &min_points, int &max_points) |
Get minimum and maximum allowed number of points for a person cluster. More... | |
float | getMinimumDistanceBetweenHeads () |
Get minimum distance between persons' heads. More... | |
Protected Attributes | |
Eigen::VectorXf | ground_coeffs_ |
ground plane coefficients More... | |
float | sqrt_ground_coeffs_ |
ground plane normalization factor More... | |
std::vector< pcl::PointIndices > | cluster_indices_ |
initial clusters indices More... | |
PointCloudPtr | cloud_ |
pointer to the input cloud More... | |
float | max_height_ |
person clusters maximum height from the ground plane More... | |
float | min_height_ |
person clusters minimum height from the ground plane More... | |
bool | vertical_ |
if true, the sensor is considered to be vertically placed (portrait mode) More... | |
bool | head_centroid_ |
if true, the person centroid is computed as the centroid of the cluster points belonging to the head if false, the person centroid is computed as the centroid of the whole cluster points (default = true) More... | |
int | max_points_ |
maximum number of points for a person cluster More... | |
int | min_points_ |
minimum number of points for a person cluster More... | |
float | heads_minimum_distance_ |
minimum distance between persons' heads More... | |
HeadBasedSubclustering represents a class for searching for people inside a HeightMap2D based on a 3D head detection algorithm
Definition at line 58 of file head_based_subcluster.h.
using pcl::people::HeadBasedSubclustering< PointT >::PointCloud = pcl::PointCloud<PointT> |
Definition at line 62 of file head_based_subcluster.h.
using pcl::people::HeadBasedSubclustering< PointT >::PointCloudConstPtr = typename PointCloud::ConstPtr |
Definition at line 64 of file head_based_subcluster.h.
using pcl::people::HeadBasedSubclustering< PointT >::PointCloudPtr = typename PointCloud::Ptr |
Definition at line 63 of file head_based_subcluster.h.
pcl::people::HeadBasedSubclustering< PointT >::HeadBasedSubclustering |
Constructor.
Definition at line 47 of file head_based_subcluster.hpp.
|
virtualdefault |
Destructor.
void pcl::people::HeadBasedSubclustering< PointT >::createSubClusters | ( | pcl::people::PersonCluster< PointT > & | cluster, |
int | maxima_number_after_filtering, | ||
std::vector< int > & | maxima_cloud_indices_filtered, | ||
std::vector< pcl::people::PersonCluster< PointT > > & | subclusters | ||
) |
Create subclusters centered on the heads position from the current cluster.
[in] | cluster | A PersonCluster. |
[in] | maxima_number_after_filtering | Number of local maxima to use as centers of the new cluster. |
[in] | maxima_cloud_indices_filtered | Cloud indices of local maxima to use as centers of the new cluster. |
[out] | subclusters | Output vector of PersonCluster objects derived from the input cluster. |
Definition at line 194 of file head_based_subcluster.hpp.
References pcl::people::PersonCluster< PointT >::getIndices(), and pcl::PointIndices::indices.
void pcl::people::HeadBasedSubclustering< PointT >::getDimensionLimits | ( | int & | min_points, |
int & | max_points | ||
) |
Get minimum and maximum allowed number of points for a person cluster.
[out] | min_points | Minimum allowed number of points for a person cluster. |
[out] | max_points | Maximum allowed number of points for a person cluster. |
Definition at line 121 of file head_based_subcluster.hpp.
void pcl::people::HeadBasedSubclustering< PointT >::getHeightLimits | ( | float & | min_height, |
float & | max_height | ||
) |
Get minimum and maximum allowed height for a person cluster.
[out] | min_height | Minimum allowed height for a person cluster. |
[out] | max_height | Maximum allowed height for a person cluster. |
Definition at line 114 of file head_based_subcluster.hpp.
float pcl::people::HeadBasedSubclustering< PointT >::getMinimumDistanceBetweenHeads |
Get minimum distance between persons' heads.
Definition at line 128 of file head_based_subcluster.hpp.
void pcl::people::HeadBasedSubclustering< PointT >::mergeClustersCloseInFloorCoordinates | ( | std::vector< pcl::people::PersonCluster< PointT > > & | input_clusters, |
std::vector< pcl::people::PersonCluster< PointT > > & | output_clusters | ||
) |
Merge clusters close in floor coordinates.
[in] | input_clusters | Input vector of PersonCluster. |
[in] | output_clusters | Output vector of PersonCluster (after merging). |
Definition at line 134 of file head_based_subcluster.hpp.
References pcl::PointIndices::indices.
void pcl::people::HeadBasedSubclustering< PointT >::setDimensionLimits | ( | int | min_points, |
int | max_points | ||
) |
Set minimum and maximum allowed number of points for a person cluster.
[in] | min_points | Minimum allowed number of points for a person cluster. |
[in] | max_points | Maximum allowed number of points for a person cluster. |
Definition at line 95 of file head_based_subcluster.hpp.
void pcl::people::HeadBasedSubclustering< PointT >::setGround | ( | Eigen::VectorXf & | ground_coeffs | ) |
Set the ground coefficients.
[in] | ground_coeffs | The ground plane coefficients. |
Definition at line 69 of file head_based_subcluster.hpp.
Referenced by pcl::people::GroundBasedPeopleDetectionApp< PointT >::compute().
void pcl::people::HeadBasedSubclustering< PointT >::setHeadCentroid | ( | bool | head_centroid | ) |
Set head_centroid_ to true (person centroid is in the head) or false (person centroid is the whole body centroid).
[in] | head_centroid | Set the location of the person centroid (head or body center) (default = true). |
Definition at line 108 of file head_based_subcluster.hpp.
void pcl::people::HeadBasedSubclustering< PointT >::setHeightLimits | ( | float | min_height, |
float | max_height | ||
) |
Set minimum and maximum allowed height for a person cluster.
[in] | min_height | Minimum allowed height for a person cluster (default = 1.3). |
[in] | max_height | Maximum allowed height for a person cluster (default = 2.3). |
Definition at line 88 of file head_based_subcluster.hpp.
Referenced by pcl::people::GroundBasedPeopleDetectionApp< PointT >::compute().
void pcl::people::HeadBasedSubclustering< PointT >::setInitialClusters | ( | std::vector< pcl::PointIndices > & | cluster_indices | ) |
Set initial cluster indices.
[in] | cluster_indices | Point cloud indices corresponding to the initial clusters (before subclustering). |
Definition at line 76 of file head_based_subcluster.hpp.
Referenced by pcl::people::GroundBasedPeopleDetectionApp< PointT >::compute().
void pcl::people::HeadBasedSubclustering< PointT >::setInputCloud | ( | PointCloudPtr & | cloud | ) |
Set input cloud.
[in] | cloud | A pointer to the input point cloud. |
Definition at line 63 of file head_based_subcluster.hpp.
Referenced by pcl::people::GroundBasedPeopleDetectionApp< PointT >::compute().
void pcl::people::HeadBasedSubclustering< PointT >::setMinimumDistanceBetweenHeads | ( | float | heads_minimum_distance | ) |
Set minimum distance between persons' heads.
[in] | heads_minimum_distance | Minimum allowed distance between persons' heads (default = 0.3). |
Definition at line 102 of file head_based_subcluster.hpp.
Referenced by pcl::people::GroundBasedPeopleDetectionApp< PointT >::compute().
void pcl::people::HeadBasedSubclustering< PointT >::setSensorPortraitOrientation | ( | bool | vertical | ) |
Set sensor orientation to landscape mode (false) or portrait mode (true).
[in] | vertical | Landscape (false) or portrait (true) mode (default = false). |
Definition at line 82 of file head_based_subcluster.hpp.
Referenced by pcl::people::GroundBasedPeopleDetectionApp< PointT >::compute().
void pcl::people::HeadBasedSubclustering< PointT >::subcluster | ( | std::vector< pcl::people::PersonCluster< PointT > > & | clusters | ) |
Compute subclusters and return them into a vector of PersonCluster.
[in] | clusters | Vector of PersonCluster. |
Definition at line 253 of file head_based_subcluster.hpp.
References pcl::people::HeightMap2D< PointT >::compute(), pcl::people::HeightMap2D< PointT >::getMaximaCloudIndicesFiltered(), pcl::people::HeightMap2D< PointT >::getMaximaNumberAfterFiltering(), pcl::people::HeightMap2D< PointT >::setGround(), pcl::people::HeightMap2D< PointT >::setInputCloud(), pcl::people::HeightMap2D< PointT >::setMinimumDistanceBetweenMaxima(), and pcl::people::HeightMap2D< PointT >::setSensorPortraitOrientation().
Referenced by pcl::people::GroundBasedPeopleDetectionApp< PointT >::compute().
|
protected |
pointer to the input cloud
Definition at line 203 of file head_based_subcluster.h.
|
protected |
initial clusters indices
Definition at line 200 of file head_based_subcluster.h.
|
protected |
ground plane coefficients
Definition at line 194 of file head_based_subcluster.h.
|
protected |
if true, the person centroid is computed as the centroid of the cluster points belonging to the head if false, the person centroid is computed as the centroid of the whole cluster points (default = true)
Definition at line 216 of file head_based_subcluster.h.
|
protected |
minimum distance between persons' heads
Definition at line 225 of file head_based_subcluster.h.
|
protected |
person clusters maximum height from the ground plane
Definition at line 206 of file head_based_subcluster.h.
|
protected |
maximum number of points for a person cluster
Definition at line 219 of file head_based_subcluster.h.
|
protected |
person clusters minimum height from the ground plane
Definition at line 209 of file head_based_subcluster.h.
|
protected |
minimum number of points for a person cluster
Definition at line 222 of file head_based_subcluster.h.
|
protected |
ground plane normalization factor
Definition at line 197 of file head_based_subcluster.h.
|
protected |
if true, the sensor is considered to be vertically placed (portrait mode)
Definition at line 212 of file head_based_subcluster.h.