Search handles given grasp hypotheses. More...
#include <handle_search.h>
Classes | |
struct | LastElementComparator |
Comparator for equality of the last element of two 2D-vectors. More... | |
struct | VectorFirstTwoElementsComparator |
Comparator for equality of the first two elements of two 3D-vectors. More... | |
Public Member Functions | |
std::vector< Handle > | findHandles (const std::vector< GraspHypothesis > &hand_list, int min_inliers, double min_length) |
Search for handles given a list of grasp hypotheses. | |
Private Member Functions | |
double | safeAcos (double x) |
Safe version of the acos(x) function. | |
bool | shortenHandle (std::vector< Eigen::Vector2d > &inliers, double gap_threshold) |
Shorten a handle to a continuous piece. |
Search handles given grasp hypotheses.
HandleSearch class
This class searches for handles, i.e., clusters of grasps that are geometrically aligned. It can also plot the results of this search.
Definition at line 57 of file handle_search.h.
std::vector< Handle > HandleSearch::findHandles | ( | const std::vector< GraspHypothesis > & | hand_list, |
int | min_inliers, | ||
double | min_length | ||
) |
Search for handles given a list of grasp hypotheses.
hand_list | the list of grasp hypotheses |
min_inliers | the minimum number of grasp hypothesis contained in a handle |
min_length | the minimum length of a handle |
Definition at line 4 of file handle_search.cpp.
double HandleSearch::safeAcos | ( | double | x | ) | [private] |
Safe version of the acos(x) function.
x | the value whose arc cosine is computed |
Definition at line 121 of file handle_search.cpp.
bool HandleSearch::shortenHandle | ( | std::vector< Eigen::Vector2d > & | inliers, |
double | gap_threshold | ||
) | [private] |
Shorten a handle to a continuous piece.
This function finds continuous handles by searching for a gap that is larger than gap_threshold
.
inliers | the list of grasp hypotheses that are part of the handle to be shortened |
gap_threshold | the maximum gap size |
Definition at line 92 of file handle_search.cpp.