Robowflex  v0.1
Making MoveIt Easy
robowflex::Planner Class Referenceabstract

An abstract interface to a motion planning algorithm. More...

#include <planning.h>

+ Inheritance diagram for robowflex::Planner:

Public Types

using ProgressProperty = std::function< std::string()>
 A function that returns the value of a planner property over the course of a run. More...
 

Public Member Functions

 Planner (const RobotPtr &robot, const std::string &name="")
 Constructor. Takes in a robot description and an optional namespace name. If name is specified, planner parameters are namespaced under the namespace of robot. More...
 
 Planner (Planner const &)=delete
 
void operator= (Planner const &)=delete
 
virtual planning_interface::MotionPlanResponse plan (const SceneConstPtr &scene, const planning_interface::MotionPlanRequest &request)=0
 Plan a motion given a request and a scene. A virtual method that must be implemented by any robowflex::Planner. More...
 
virtual std::vector< std::stringgetPlannerConfigs () const =0
 Return all planner configurations offered by this planner. Any of the configurations returned can be set as the planner for a motion planning query sent to plan(). More...
 
virtual std::map< std::string, ProgressPropertygetProgressProperties (const SceneConstPtr &scene, const planning_interface::MotionPlanRequest &request) const
 Retrieve the planner progress property map for this planner given a specific request. More...
 
const RobotPtr getRobot () const
 Return the robot for this planner. More...
 
const std::stringgetName () const
 Get the name of the planner. More...
 
virtual void preRun (const SceneConstPtr &scene, const planning_interface::MotionPlanRequest &request)
 This function is called before benchmarking. More...
 

Protected Attributes

RobotPtr robot_
 The robot to plan for. More...
 
IO::Handler handler_
 The parameter handler for the planner. More...
 
const std::string name_
 Namespace for the planner. More...
 

Detailed Description

An abstract interface to a motion planning algorithm.

Definition at line 33 of file robowflex_library/include/robowflex_library/planning.h.

Member Typedef Documentation

◆ ProgressProperty

A function that returns the value of a planner property over the course of a run.

Definition at line 38 of file robowflex_library/include/robowflex_library/planning.h.

Constructor & Destructor Documentation

◆ Planner() [1/2]

Planner::Planner ( const RobotPtr robot,
const std::string name = "" 
)

Constructor. Takes in a robot description and an optional namespace name. If name is specified, planner parameters are namespaced under the namespace of robot.

Parameters
[in]robotThe robot to plan for.
[in]nameOptional namespace for planner.

Planner

Definition at line 26 of file robowflex_library/src/planning.cpp.

27  : robot_(robot), handler_(robot_->getHandler(), name), name_(name)
28 {
29 }
const std::string name_
Namespace for the planner.
IO::Handler handler_
The parameter handler for the planner.
Functions for loading and animating robots in Blender.

◆ Planner() [2/2]

robowflex::Planner::Planner ( Planner const &  )
delete

Member Function Documentation

◆ getName()

const std::string & Planner::getName ( ) const

Get the name of the planner.

Returns
The planner's name.

Definition at line 36 of file robowflex_library/src/planning.cpp.

37 {
38  return name_;
39 }

◆ getPlannerConfigs()

virtual std::vector<std::string> robowflex::Planner::getPlannerConfigs ( ) const
pure virtual

Return all planner configurations offered by this planner. Any of the configurations returned can be set as the planner for a motion planning query sent to plan().

Returns
A vector of strings of planner configuration names.

Implemented in robowflex::TrajOptPlanner, robowflex::OMPL::OMPLInterfacePlanner, robowflex::opt::CHOMPPipelinePlanner, robowflex::OMPL::OMPLPipelinePlanner, robowflex::SimpleCartesianPlanner, robowflex::PoolPlanner, and robowflex::darts::DARTPlanner.

◆ getProgressProperties()

std::map< std::string, Planner::ProgressProperty > Planner::getProgressProperties ( const SceneConstPtr scene,
const planning_interface::MotionPlanRequest request 
) const
virtual

Retrieve the planner progress property map for this planner given a specific request.

Parameters
[in]sceneA planning scene for the same robot_ to compute the plan in.
[in]requestRequest to get progress properties for.
Returns
The map of progress properties.

Reimplemented in robowflex::OMPL::OMPLInterfacePlanner.

Definition at line 46 of file robowflex_library/src/planning.cpp.

49 {
50  return {};
51 }

◆ getRobot()

const RobotPtr Planner::getRobot ( ) const

Return the robot for this planner.

Returns
Get the robot associated with the planner.

Definition at line 31 of file robowflex_library/src/planning.cpp.

32 {
33  return robot_;
34 }

◆ operator=()

void robowflex::Planner::operator= ( Planner const &  )
delete

◆ plan()

virtual planning_interface::MotionPlanResponse robowflex::Planner::plan ( const SceneConstPtr scene,
const planning_interface::MotionPlanRequest request 
)
pure virtual

Plan a motion given a request and a scene. A virtual method that must be implemented by any robowflex::Planner.

Parameters
[in]sceneA planning scene for the same robot_ to compute the plan in.
[in]requestThe motion planning request to solve.
Returns
The motion planning response generated by the planner.

Implemented in robowflex::TrajOptPlanner, robowflex::OMPL::OMPLInterfacePlanner, robowflex::PipelinePlanner, robowflex::SimpleCartesianPlanner, robowflex::PoolPlanner, and robowflex::darts::DARTPlanner.

◆ preRun()

void Planner::preRun ( const SceneConstPtr scene,
const planning_interface::MotionPlanRequest request 
)
virtual

This function is called before benchmarking.

Parameters
[in]sceneScene to plan for.
[in]requestPlanning request.

Reimplemented in robowflex::OMPL::OMPLInterfacePlanner, and robowflex::darts::DARTPlanner.

Definition at line 41 of file robowflex_library/src/planning.cpp.

43 {
44 }

Member Data Documentation

◆ handler_

IO::Handler robowflex::Planner::handler_
protected

The parameter handler for the planner.

Definition at line 94 of file robowflex_library/include/robowflex_library/planning.h.

◆ name_

const std::string robowflex::Planner::name_
protected

Namespace for the planner.

Definition at line 95 of file robowflex_library/include/robowflex_library/planning.h.

◆ robot_

RobotPtr robowflex::Planner::robot_
protected

The robot to plan for.

Definition at line 93 of file robowflex_library/include/robowflex_library/planning.h.


The documentation for this class was generated from the following files: