Parasol Planning Library (PPL)
HierarchicalLP Class Reference

Apply a sequence of local planners until one succeeds, or all fail. More...

#include <HierarchicalLP.h>

Inheritance diagram for HierarchicalLP:
Inheritance graph
[legend]
Collaboration diagram for HierarchicalLP:
Collaboration graph
[legend]

Public Types

Local Types
typedef MPBaseObject::WeightType WeightType
 
- Public Types inherited from LocalPlannerMethod
typedef MPBaseObject::GroupCfgType GroupCfgType
 
typedef GroupCfgType::Formation Formation
 
- Public Types inherited from MPBaseObject
typedef DefaultWeight< Cfg > WeightType
 
typedef GenericStateGraph< Cfg, WeightType > RoadmapType
 
typedef GroupCfg< RoadmapType > GroupCfgType
 
typedef GroupLocalPlan< RoadmapType > GroupWeightType
 
typedef GroupRoadmap< GroupCfgType, GroupWeightType > GroupRoadmapType
 

Public Member Functions

Constructors
 HierarchicalLP (const vector< string > &_lpLabels=vector< string >(), bool _saveIntermediates=false)
 
 HierarchicalLP (XMLNode &_node)
 
Overrides
virtual void Print (ostream &_os) const
 
virtual bool IsConnected (const Cfg &_c1, const Cfg &_c2, Cfg &_col, LPOutput *_lpOutput, double _posRes, double _oriRes, bool _checkCollision=true, bool _savePath=false)
 
- Public Member Functions inherited from LocalPlannerMethod
 LocalPlannerMethod (bool _saveIntermediates=false)
 
 LocalPlannerMethod (XMLNode &_node)
 
virtual ~LocalPlannerMethod ()=default
 
bool IsConnected (const Cfg &_start, const Cfg &_end, LPOutput *_lpOutput, double _posRes, double _oriRes, bool _checkCollision=true, bool _savePath=false)
 
virtual bool IsConnected (const GroupCfgType &_start, const GroupCfgType &_end, GroupCfgType &_col, GroupLPOutput *_lpOutput, double _posRes, double _oriRes, bool _checkCollision=true, bool _savePath=false, const Formation &_formation=Formation())
 
bool IsConnected (const GroupCfgType &_start, const GroupCfgType &_end, GroupLPOutput *_lpOutput, double _posRes, double _oriRes, bool _checkCollision=true, bool _savePath=false, const Formation &_formation=Formation())
 
std::vector< Cfg > BlindPath (const std::vector< Cfg > &_waypoints, const double _posRes, const double _oriRes)
 
std::vector< Cfg > BlindPath (const std::vector< Cfg > &_waypoints)
 
std::vector< GroupCfgType > BlindPath (const std::vector< GroupCfgType > &_waypoints, const double _posRes, const double _oriRes, const Formation &_formation=Formation())
 
std::vector< GroupCfgType > BlindPath (const std::vector< GroupCfgType > &_waypoints, const Formation &_formation=Formation())
 
- Public Member Functions inherited from MPBaseObject
 MPBaseObject (const std::string &_label="", const std::string &_name="", bool _debug=false)
 
 MPBaseObject (XMLNode &_node)
 
virtual ~MPBaseObject ()
 
virtual void Initialize ()
 
const std::string & GetName () const
 Get the class name for this object. More...
 
const std::string & GetLabel () const
 Get the unique label for this object. More...
 
std::string GetNameAndLabel () const
 Get the unique string identifier for this object "m_name::m_label". More...
 
void SetLabel (const std::string &)
 Set the unique label for this object. More...
 
void SetMPLibrary (MPLibrary *) noexcept
 Set the owning MPLibrary. More...
 
MPLibrary * GetMPLibrary () const noexcept
 Get the owning MPLibrary. More...
 
bool IsRunning () const noexcept
 Check the library's running flag. More...
 
MPProblem * GetMPProblem () const noexcept
 Get the library's current MPProblem. More...
 
Environment * GetEnvironment () const noexcept
 Get the current environment. More...
 
MPTask * GetTask () const noexcept
 Get the current task. More...
 
GroupTask * GetGroupTask () const noexcept
 Get the current group task. More...
 
MPSolutionType * GetMPSolution () const noexcept
 
RoadmapType * GetRoadmap (Robot *const _r=nullptr) const noexcept
 Get the current free-space roadmap. More...
 
GroupRoadmapType * GetGroupRoadmap (RobotGroup *const _g=nullptr) const noexcept
 Get the current free-space group roadmap. More...
 
RoadmapType * GetBlockRoadmap (Robot *const _r=nullptr) const noexcept
 Get the current obstacle-space roadmap. More...
 
Path * GetPath (Robot *const _r=nullptr) const noexcept
 
GroupPath * GetGroupPath (RobotGroup *const _g=nullptr) const noexcept
 Get the current best group path. More...
 
StatClass * GetStatClass () const noexcept
 Get the current StatClass. More...
 
LocalObstacleMap * GetLocalObstacleMap () const noexcept
 Get the local obstacle map. More...
 

Additional Inherited Members

- Protected Member Functions inherited from MPBaseObject
void SetName (const std::string &_s)
 
const std::string & GetBaseFilename () const
 
- Protected Attributes inherited from LocalPlannerMethod
bool m_saveIntermediates {false}
 Save the intermediates in the roadmap? More...
 
- Protected Attributes inherited from MPBaseObject
bool m_debug
 Print debug info? More...
 

Detailed Description

Apply a sequence of local planners until one succeeds, or all fail.

Hierarchical local planning applies a sequence of local planners until one succeeds or they all fail. It will return the information of the successful local plan.

Member Typedef Documentation

◆ WeightType

Constructor & Destructor Documentation

◆ HierarchicalLP() [1/2]

HierarchicalLP::HierarchicalLP ( const vector< string > &  _lpLabels = vector<string>(),
bool  _saveIntermediates = false 
)

◆ HierarchicalLP() [2/2]

HierarchicalLP::HierarchicalLP ( XMLNode &  _node)

Member Function Documentation

◆ IsConnected()

bool HierarchicalLP::IsConnected ( const Cfg &  _start,
const Cfg &  _end,
Cfg &  _col,
LPOutput *  _lpOutput,
double  _posRes,
double  _oriRes,
bool  _checkCollision = true,
bool  _savePath = false 
)
virtual

Validate a simple path between two nodes.

Parameters
_startThe starting configuration.
_endThe ending configuration.
_colThe witness configuration on failure.
_lpOutputWeight and path computed from local plan.
_posResPositional DOF resolution.
_oriResRotational DOF resolution.
_checkCollisionUse validity checking?
_savePathSave all configurations along the path?
Returns
A boolean indicating whether the connection succeeded.

@usage

LocalPlannerPointer lp = this->GetLocalPlanner(m_lpLabel);
Environment* env = this->GetEnvironment();
CfgType c1, c2, col;
LPOutput lpOut;
lp->IsConnected(c1, c2, col, &lpOut, env->GetPositionRes(),
Definition: Environment.h:137
double GetOrientationRes() const noexcept
Get the orientation resolution.
Definition: Environment.cpp:600
double GetPositionRes() const noexcept
Get the position resolution.
Definition: Environment.cpp:586
Environment * GetEnvironment() const noexcept
Get the current environment.
Definition: MPBaseObject.cpp:94
Definition: LPOutput.h:24

Implements LocalPlannerMethod.

◆ Print()

void HierarchicalLP::Print ( ostream &  _os) const
virtual

Print internal state of this object.

Parameters
_osThe std::ostream to print to.

Reimplemented from LocalPlannerMethod.


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