Does an ICP-like fitting only in the X and Y translation DOFs. More...
#include <iterative_distance_fitter.h>
Public Member Functions | |
template<class PointCloudType > | |
ModelFitInfo | fitPointCloud (const PointCloudType &cloud) |
Main fitting function. | |
IterativeTranslationFitter () | |
Stub, just calls super's constructor. | |
~IterativeTranslationFitter () | |
Empty stub. | |
Private Member Functions | |
template<class PointCloudType > | |
geometry_msgs::Point32 | centerOfSupport (const PointCloudType &cloud) |
Helper function for fitting. | |
template<class PointCloudType > | |
double | getFitScoreAndGradient (const PointCloudType &cloud, const geometry_msgs::Point32 &location, geometry_msgs::Point32 &vector, double &maxDist) |
Inner loop when doing translation fitting. |
Does an ICP-like fitting only in the X and Y translation DOFs.
Definition at line 47 of file iterative_distance_fitter.h.
Stub, just calls super's constructor.
Definition at line 63 of file iterative_distance_fitter.h.
Empty stub.
Definition at line 65 of file iterative_distance_fitter.h.
geometry_msgs::Point32 tabletop_object_detector::IterativeTranslationFitter::centerOfSupport | ( | const PointCloudType & | cloud | ) | [private] |
Helper function for fitting.
Computes the point at the bottom of the point cloud vertical to the center of gravity. This is the point where the table supports the object.
Definition at line 78 of file iterative_distance_fitter.h.
ModelFitInfo tabletop_object_detector::IterativeTranslationFitter::fitPointCloud | ( | const PointCloudType & | cloud | ) |
Main fitting function.
Iterates over the inner loop of getFitScoreAndGradient, then moves in the direction of the computed gradient. Does this until the score stops decreasing.
The fit is initialized to the centroid of the cloud along x and y, and 0 along z. This assumes that the meshes are all such that the origin is at the bottom, with the z axis pointing up. It also assumes the points have been translated to a coordinate frame where z=0 is the table plane.
For the same reason. there is no iteration done along z at all.
Definition at line 172 of file iterative_distance_fitter.h.
double tabletop_object_detector::IterativeTranslationFitter::getFitScoreAndGradient | ( | const PointCloudType & | cloud, |
const geometry_msgs::Point32 & | location, | ||
geometry_msgs::Point32 & | vector, | ||
double & | maxDist | ||
) | [private] |
Inner loop when doing translation fitting.
Definition at line 98 of file iterative_distance_fitter.h.