21 #include <geometry_msgs/Pose.h> 22 #include <geometry_msgs/Point.h> 23 #include <Eigen/Dense> 62 double getAngleRating(
const geometry_msgs::Pose &object_pose,
bool direction);
70 bool getBBRating(
const std::array<geometry_msgs::Point, 8> &bounding_box);
80 double getNormalRating(
const geometry_msgs::Pose &object_pose,
const std::vector<geometry_msgs::Point> &normals);
91 Rating(
double fovx,
double fovy,
double ncp,
double fcp);
102 bool ratePose(
const geometry_msgs::Pose &pose,
double threshold_d,
double threshold_x,
double threshold_y);
115 bool rateBBandNormal(
const geometry_msgs::Pose &object_pose,
const std::array<geometry_msgs::Point, 8> &bounding_box,
const std::vector<geometry_msgs::Point> &normals,
double threshold);
bool getBBRating(const std::array< geometry_msgs::Point, 8 > &bounding_box)
Returns the amount of points of the bounding box inside the frustum divided by the amount of all poin...
double getAngleRating(const geometry_msgs::Pose &object_pose, bool direction)
Returns a rating of an object's pose based on the (azimut or elevation) angle between the camera's vi...
This class is used to rate an object's pose based on the current camera position. ...
bool rateBBandNormal(const geometry_msgs::Pose &object_pose, const std::array< geometry_msgs::Point, 8 > &bounding_box, const std::vector< geometry_msgs::Point > &normals, double threshold)
Rates an objects visibility based on its bounding box and its normals.
double getNormalRating(const geometry_msgs::Pose &object_pose, const std::vector< geometry_msgs::Point > &normals)
Returns a rating for the angle between sight vector to object and object's normal. 1.0 is best, 0.0 worst.
bool ratePose(const geometry_msgs::Pose &pose, double threshold_d, double threshold_x, double threshold_y)
Return whether a pose is visible in the camera frustum based on the distance and angle rating...
const Eigen::Vector3d camera_orientation_
double getDistanceRating(const geometry_msgs::Pose &object_pose)
Returns a rating of an object's pose based on the distance to the camera.
Rating(double fovx, double fovy, double ncp, double fcp)
The constructor of the class.