Function stomp_moveit::costs::getConstraintsCostFunction

Function Documentation

CostFn stomp_moveit::costs::getConstraintsCostFunction(const std::shared_ptr<const planning_scene::PlanningScene> &planning_scene, const moveit::core::JointModelGroup *group, const moveit_msgs::msg::Constraints &constraints_msg, double cost_scale)

Creates a cost function for binary constraint checks applied to group states. This function uses a StateValidatorFn for computing smooth penalty costs from binary constraint checks using getCostFunctionFromStateValidator().

Parameters:
  • planning_scene – The planning scene instance to use for computing transforms

  • group – The group to use for computing link transforms from joint positions

  • constraints_msg – The constraints used for validating group states

  • cost_scale – A scalar factor applied to the distance cost of invalid states

Returns:

Cost function that computes smooth costs for invalid path segments