Simox  2.3.74.0
GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized Class Reference

An efficient implementation of the grasp wrench space algorithm for grasp quality evaluation. More...

Inheritance diagram for GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized:
GraspStudio::GraspQualityMeasure VirtualRobot::BasicGraspQualityMeasure

Public Member Functions

bool calculateObjectProperties () override
 This method is used to compute a reference value that describes a perfect grasp. More...
 
float getGraspQuality () override
 
virtual float getVolumeGraspMeasure ()
 
bool isGraspForceClosure () override
 Indicate whether the grasp is in force closure. More...
 
virtual VirtualRobot::MathTools::ConvexHull6DPtr getConvexHullGWS ()
 
void updateGWS ()
 
VirtualRobot::MathTools::ContactPoint getCenterGWS ()
 
void setContactPoints (const std::vector< VirtualRobot::MathTools::ContactPoint > &contactPoints) override
 
void setContactPoints (const VirtualRobot::EndEffector::ContactInfoVector &contactPoints) override
 
bool calculateGraspQuality () override
 Compute the grasp quality for the given contact points. More...
 
std::string getName () override
 Returns description of this object. More...
 
- Public Member Functions inherited from GraspStudio::GraspQualityMeasure
EIGEN_MAKE_ALIGNED_OPERATOR_NEW GraspQualityMeasure (VirtualRobot::SceneObjectPtr object, float unitForce=1.0f, float frictionConeCoeff=0.35f, int frictionConeSamples=8)
 Constructor. More...
 
virtual ~GraspQualityMeasure () override
 Destructor. More...
 
virtual VirtualRobot::MathTools::ContactPoint getSampledObjectPointsCenter ()
 
bool isValid () override
 
virtual ContactConeGeneratorPtr getConeGenerator ()
 
- Public Member Functions inherited from VirtualRobot::BasicGraspQualityMeasure
EIGEN_MAKE_ALIGNED_OPERATOR_NEW BasicGraspQualityMeasure (VirtualRobot::SceneObjectPtr object)
 
virtual ~BasicGraspQualityMeasure ()
 Destructor. More...
 
virtual Eigen::Vector3f getCoM ()
 
virtual VirtualRobot::MathTools::ContactPoint getContactPointsCenter ()
 
virtual void setVerbose (bool enable)
 
VirtualRobot::SceneObjectPtr getObject ()
 

Static Public Member Functions

static std::vector< VirtualRobot::MathTools::ContactPointcreateWrenchPoints (std::vector< VirtualRobot::MathTools::ContactPoint > &points, const Eigen::Vector3f &centerOfModel, float objectLengthMM)
 
static float minOffset (VirtualRobot::MathTools::ConvexHull6DPtr ch)
 Goes through all facets of convex hull and searches the minimum distance to it's center. More...
 

Protected Member Functions

VirtualRobot::MathTools::ConvexHull6DPtr calculateConvexHull (std::vector< VirtualRobot::MathTools::ContactPoint > &points)
 
VirtualRobot::MathTools::ContactPoint calculateHullCenter (VirtualRobot::MathTools::ConvexHull6DPtr hull)
 
float minDistanceToGWSHull (VirtualRobot::MathTools::ContactPoint &point)
 
bool isOriginInGWSHull ()
 
void printContacts (std::vector< VirtualRobot::MathTools::ContactPoint > &points)
 
- Protected Member Functions inherited from GraspStudio::GraspQualityMeasure
bool sampleObjectPoints (int nMaxFaces=400)
 

Static Protected Member Functions

static Eigen::Vector3f crossProductPosNormalInv (const VirtualRobot::MathTools::ContactPoint &v1)
 

Protected Attributes

bool GWSCalculated {false}
 
VirtualRobot::MathTools::ConvexHull6DPtr convexHullGWS
 
VirtualRobot::MathTools::ContactPoint convexHullCenterGWS
 
- Protected Attributes inherited from GraspStudio::GraspQualityMeasure
float unitForce
 
float frictionCoeff
 
int frictionConeSamples
 
ContactConeGeneratorPtr coneGenerator
 
std::vector< VirtualRobot::MathTools::ContactPointsampledObjectPoints
 
std::vector< VirtualRobot::MathTools::ContactPointsampledObjectPointsM
 
- Protected Attributes inherited from VirtualRobot::BasicGraspQualityMeasure
Eigen::Vector3f centerOfModel
 
float objectLength
 
float graspQuality
 
int maxContacts
 
VirtualRobot::SceneObjectPtr object
 
std::vector< VirtualRobot::MathTools::ContactPointcontactPoints
 
std::vector< VirtualRobot::MathTools::ContactPointcontactPointsM
 
bool verbose
 

Detailed Description

An efficient implementation of the grasp wrench space algorithm for grasp quality evaluation.

the grasp wrench space algorithm is widely used in the context of grasp planning. By analyzing the grasp wrench space (GWS) of a given set of contact points, a quality score of a grasp can be evaluated. In this implementation, additionally an object specific wrench space (WS) is calculated, which approximatevly represents a "perfect" grasp. This object is used to normalize the quality score.

Member Function Documentation

◆ calculateConvexHull()

VirtualRobot::MathTools::ConvexHull6DPtr GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::calculateConvexHull ( std::vector< VirtualRobot::MathTools::ContactPoint > &  points)
protected

◆ calculateGraspQuality()

bool GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::calculateGraspQuality ( )
overridevirtual

Compute the grasp quality for the given contact points.

Reimplemented from VirtualRobot::BasicGraspQualityMeasure.

◆ calculateHullCenter()

VirtualRobot::MathTools::ContactPoint GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::calculateHullCenter ( VirtualRobot::MathTools::ConvexHull6DPtr  hull)
protected

◆ calculateObjectProperties()

bool GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::calculateObjectProperties ( )
inlineoverridevirtual

This method is used to compute a reference value that describes a perfect grasp.

Implements GraspStudio::GraspQualityMeasure.

◆ createWrenchPoints()

std::vector< VirtualRobot::MathTools::ContactPoint > GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::createWrenchPoints ( std::vector< VirtualRobot::MathTools::ContactPoint > &  points,
const Eigen::Vector3f &  centerOfModel,
float  objectLengthMM 
)
static

◆ crossProductPosNormalInv()

Eigen::Vector3f GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::crossProductPosNormalInv ( const VirtualRobot::MathTools::ContactPoint v1)
staticprotected

◆ getCenterGWS()

VirtualRobot::MathTools::ContactPoint GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::getCenterGWS ( )
inline

◆ getConvexHullGWS()

virtual VirtualRobot::MathTools::ConvexHull6DPtr GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::getConvexHullGWS ( )
inlinevirtual

◆ getGraspQuality()

float GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::getGraspQuality ( )
overridevirtual

Returns f_max_gws with f_max_gws = max distance of GWS hull center to one of its facets -> also known as "epsilon" quality == radius of larges enclosing 6D ball

Reimplemented from VirtualRobot::BasicGraspQualityMeasure.

◆ getName()

std::string GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::getName ( )
overridevirtual

Returns description of this object.

Reimplemented from GraspStudio::GraspQualityMeasure.

◆ getVolumeGraspMeasure()

float GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::getVolumeGraspMeasure ( )
virtual

Volume grasp quality ratio of GWS volume -> also known as "v" quality

◆ isGraspForceClosure()

bool GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::isGraspForceClosure ( )
overridevirtual

Indicate whether the grasp is in force closure.

Implements GraspStudio::GraspQualityMeasure.

◆ isOriginInGWSHull()

bool GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::isOriginInGWSHull ( )
protected

◆ minDistanceToGWSHull()

float GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::minDistanceToGWSHull ( VirtualRobot::MathTools::ContactPoint point)
protected

◆ minOffset()

float GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::minOffset ( VirtualRobot::MathTools::ConvexHull6DPtr  ch)
static

Goes through all facets of convex hull and searches the minimum distance to it's center.

◆ printContacts()

void GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::printContacts ( std::vector< VirtualRobot::MathTools::ContactPoint > &  points)
protected

◆ setContactPoints() [1/2]

void GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::setContactPoints ( const std::vector< VirtualRobot::MathTools::ContactPoint > &  contactPoints)
overridevirtual

setup contact information the contact points are normalized by subtracting the COM the contact normals are normalize to unit length

Reimplemented from VirtualRobot::BasicGraspQualityMeasure.

◆ setContactPoints() [2/2]

void GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::setContactPoints ( const VirtualRobot::EndEffector::ContactInfoVector contactPoints)
overridevirtual

setup contact information the contact points are normalized by subtracting the COM the contact normals are normalize to unit length

Reimplemented from VirtualRobot::BasicGraspQualityMeasure.

◆ updateGWS()

void GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::updateGWS ( )

Field Documentation

◆ convexHullCenterGWS

VirtualRobot::MathTools::ContactPoint GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::convexHullCenterGWS
protected

◆ convexHullGWS

VirtualRobot::MathTools::ConvexHull6DPtr GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::convexHullGWS
protected

◆ GWSCalculated

bool GraspStudio::GraspQualityMeasureWrenchSpaceNotNormalized::GWSCalculated {false}
protected