Point Cloud Library (PCL)
1.11.1-dev
|
44 #include <pcl/sample_consensus/sac_model_plane.h>
45 #include <pcl/sample_consensus/ransac.h>
46 #include <pcl/kdtree/kdtree.h>
47 #include <pcl/people/person_cluster.h>
48 #include <pcl/people/head_based_subcluster.h>
49 #include <pcl/people/person_classifier.h>
50 #include <pcl/common/transforms.h>
67 template <
typename Po
intT>
96 setGround (Eigen::VectorXf& ground_coeffs);
144 setFOV (
float min,
float max);
370 #include <pcl/people/impl/ground_based_people_detection_app.hpp>
void setPersonClusterLimits(float min_height, float max_height, float min_width, float max_width)
Set minimum and maximum allowed height and width for a person cluster.
bool person_classifier_set_flag_
flag stating if the classifier has been set or not
void setTransformation(const Eigen::Matrix3f &transformation)
Set the transformation matrix, which is used in order to transform the given point cloud,...
float min_height_
person clusters minimum height from the ground plane
Eigen::Matrix3f transformation_
rotation matrix which transforms input point cloud to internal people tracker coordinate frame
void setInputCloud(PointCloudPtr &cloud)
Set the pointer to the input cloud.
Eigen::VectorXf getGround()
Get floor coefficients.
void applyTransformationPointCloud()
Applies the transformation to the input point cloud.
float sqrt_ground_coeffs_
ground plane normalization factor
GroundBasedPeopleDetectionApp performs people detection on RGB-D data having as input the ground plan...
float heads_minimum_distance_
minimum distance between persons' heads
bool intrinsics_matrix_set_
flag stating whether the intrinsics matrix has been set or not
pcl::PointCloud< pcl::RGB >::Ptr rgb_image_
pointer to a RGB cloud corresponding to cloud_
void swapDimensions(pcl::PointCloud< pcl::RGB >::Ptr &cloud)
Swap rows/cols dimensions of a RGB point cloud (90 degrees counterclockwise rotation).
PointCloud represents the base class in PCL for storing collections of 3D points.
bool compute(std::vector< pcl::people::PersonCluster< PointT > > &clusters)
Perform people detection on the input data and return people clusters information.
float min_fov_
the beginning of the field of view in z-direction, should be usually set to zero
void setClassifier(pcl::people::PersonClassifier< pcl::RGB > person_classifier)
Set SVM-based person classifier.
float max_width_
person clusters maximum width, used to estimate how many points maximally represent a person cluster
void setGround(Eigen::VectorXf &ground_coeffs)
Set the ground coefficients.
virtual ~GroundBasedPeopleDetectionApp()
Destructor.
float min_width_
person clusters minimum width, used to estimate how many points minimally represent a person cluster
float voxel_size_
voxel size
void setHeadCentroid(bool head_centroid)
Set head_centroid_ to true (person centroid is in the head) or false (person centroid is the whole bo...
void updateMinMaxPoints()
Estimates min_points_ and max_points_ based on the minimal and maximal cluster size and the voxel siz...
int max_points_
maximum number of points for a person cluster
void applyTransformationGround()
Applies the transformation to the ground plane.
Eigen::Matrix3f intrinsics_matrix_transformed_
the transformed intrinsics matrix
int min_points_
minimum number of points for a person cluster
Eigen::VectorXf ground_coeffs_
ground plane coefficients
void setVoxelSize(float voxel_size)
Set voxel size.
pcl::people::PersonClassifier< pcl::RGB > person_classifier_
SVM-based person classifier.
GroundBasedPeopleDetectionApp()
Constructor.
void setMinimumDistanceBetweenHeads(float heads_minimum_distance)
Set minimum distance between persons' heads.
int sampling_factor_
sampling factor used to downsample the point cloud
float getMinimumDistanceBetweenHeads()
Get minimum distance between persons' heads.
void getDimensionLimits(int &min_points, int &max_points)
Get minimum and maximum allowed number of points for a person cluster.
void filter()
Reduces the input cloud to one point per voxel and limits the field of view.
void applyTransformationIntrinsics()
Applies the transformation to the intrinsics matrix.
float max_fov_
the end of the field of view in z-direction
void setSamplingFactor(int sampling_factor)
Set sampling factor.
void setIntrinsics(Eigen::Matrix3f intrinsics_matrix)
Set intrinsic parameters of the RGB camera.
bool head_centroid_
if true, the person centroid is computed as the centroid of the cluster points belonging to the head;...
void setSensorPortraitOrientation(bool vertical)
Set sensor orientation (vertical = true means portrait mode, vertical = false means landscape mode).
PointCloudPtr cloud_
pointer to the input cloud
void extractRGBFromPointCloud(PointCloudPtr input_cloud, pcl::PointCloud< pcl::RGB >::Ptr &output_cloud)
Extract RGB information from a point cloud and output the corresponding RGB point cloud.
PersonCluster represents a class for representing information about a cluster containing a person.
float max_height_
person clusters maximum height from the ground plane
PointCloudPtr getNoGroundCloud()
Get pointcloud after voxel grid filtering and ground removal.
shared_ptr< PointCloud< PointT > > Ptr
Eigen::VectorXf ground_coeffs_transformed_
the transformed ground coefficients
bool transformation_set_
flag stating whether the transformation matrix has been set or not
PointCloudPtr no_ground_cloud_
pointer to the cloud after voxel grid filtering and ground removal
typename PointCloud::ConstPtr PointCloudConstPtr
shared_ptr< const PointCloud< PointT > > ConstPtr
bool vertical_
if true, the sensor is considered to be vertically placed (portrait mode)
bool ground_coeffs_set_
flag stating whether the ground coefficients have been set or not
PointCloudPtr getFilteredCloud()
Get the filtered point cloud.
PointCloudPtr cloud_filtered_
pointer to the filtered cloud
void setFOV(float min, float max)
Set the field of view of the point cloud in z direction.
Eigen::Matrix3f intrinsics_matrix_
intrinsic parameters matrix of the RGB camera
typename PointCloud::Ptr PointCloudPtr
void getPersonClusterLimits(float &min_height, float &max_height, float &min_width, float &max_width)
Get the minimum and maximum allowed height and width for a person cluster.