class mrpt::nav::PlannerRRT_SE2_TPS

TP Space-based RRT path planning for SE(2) (planar) robots.

This planner algorithm is described in the paper:

  • M. Bellone, J.L. Blanco, A. Gimenez, “TP-Space RRT: Kinematic path planning of non-holonomic any-shape vehicles”, International Journal of Advanced Robotic Systems, 2015.

Typical usage:

mrpt::nav::PlannerRRT_SE2_TPS  planner;

// Set or load planner parameters:
//planner.loadConfig( mrpt::config::CConfigFile("config_file.cfg") );
//planner.params.... // See RRTAlgorithmParams

// Set RRT end criteria (when to stop searching for a solution)
//planner.end_criteria.... // See RRTEndCriteria

planner.initialize();  // Initialize after setting the algorithm parameters

// Set up planning problem:
PlannerRRT_SE2_TPS::TPlannerResult planner_result;
PlannerRRT_SE2_TPS::TPlannerInput planner_input;
// Start & goal:
planner_input.start_pose = mrpt::math::TPose2D(XXX,XXX,XXX);
planner_input.goal_pose  = mrpt::math::TPose2D(XXX,XXX,XXX);
// Set obtacles: (...)
// planner_input.obstacles_points ...
// Set workspace bounding box for picking random poses in the RRT algorithm:
planner_input.world_bbox_min = mrpt::math::TPoint2D(XX,YY);
planner_input.world_bbox_max = mrpt::math::TPoint2D(XX,YY);
// Do path planning:
planner.solve( planner_input, planner_result);
// Analyze contents of planner_result...
  • Changes history:

    • 06/MAR/2014: Creation (MB)

    • 06/JAN/2015: Refactoring (JLBC)

Todo Factorize into more generic path planner classes! //template <class POSE, class MOTIONS>…

#include <mrpt/nav/planners/PlannerRRT_SE2_TPS.h>

class PlannerRRT_SE2_TPS: public mrpt::nav::PlannerTPS_VirtualBase
{
public:
    // typedefs

    typedef mrpt::math::TPose2D node_pose_t;

    // structs

    struct TPlannerInput;
    struct TPlannerResult;

    //
fields

    RRTAlgorithmParams params;

    // construction

    PlannerRRT_SE2_TPS();

    //
methods

    void loadConfig(
        const mrpt::config::CConfigFileBase& cfgSource,
        const std::string& sSectionName = std::string("PTG_CONFIG")
        );

    void initialize();
    void solve(const TPlannerInput& pi, TPlannerResult& result);
};

Inherited Members

public:
    // structs

    struct TRenderPlannedPathOptions;

    //
fields

    RRTEndCriteria end_criteria;

    //
methods

    mrpt::system::CTimeLogger& getProfiler();
    const mrpt::nav::TListPTGPtr& getPTGs() const;

    template <typename node_pose_t, typename world_limits_t, typename tree_t>
    void renderMoveTree(
        mrpt::opengl::COpenGLScene& scene,
        const TPlannerInputTempl<node_pose_t, world_limits_t>& pi,
        const TPlannerResultTempl<tree_t>& result,
        const TRenderPlannedPathOptions& options
        );

Typedefs

typedef mrpt::math::TPose2D node_pose_t

The type of poses at nodes.

Fields

RRTAlgorithmParams params

Parameters specific to this path solver algorithm.

Construction

PlannerRRT_SE2_TPS()

Constructor.

Methods

void loadConfig(
    const mrpt::config::CConfigFileBase& cfgSource,
    const std::string& sSectionName = std::string("PTG_CONFIG")
    )

Load all params from a config file source.

void initialize()

Must be called after setting all params (see loadConfig()) and before calling solve()

void solve(const TPlannerInput& pi, TPlannerResult& result)

The main API entry point: tries to find a planned path from ‘goal’ to ‘target’.