Nav2 Navigation Stack - humble  humble
ROS 2 Navigation Stack
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
nav2_smac_planner::LatticeMotionTable Struct Reference

A table of motion primitives and related functions. More...

#include <nav2_smac_planner/include/nav2_smac_planner/node_lattice.hpp>

Collaboration diagram for nav2_smac_planner::LatticeMotionTable:
Collaboration graph
[legend]

Public Member Functions

 LatticeMotionTable ()
 A constructor for nav2_smac_planner::LatticeMotionTable.
 
void initMotionModel (unsigned int &size_x_in, SearchInfo &search_info)
 Initializing state lattice planner's motion model. More...
 
MotionPrimitivePtrs getMotionPrimitives (const NodeLattice *node)
 Get projections of motion models. More...
 
unsigned int getClosestAngularBin (const double &theta)
 Get the angular bin to use from a raw orientation. More...
 
float & getAngleFromBin (const unsigned int &bin_idx)
 Get the raw orientation from an angular bin. More...
 

Static Public Member Functions

static LatticeMetadata getLatticeMetadata (const std::string &lattice_filepath)
 Get file metadata needed. More...
 

Public Attributes

unsigned int size_x
 
unsigned int num_angle_quantization
 
float change_penalty
 
float non_straight_penalty
 
float cost_penalty
 
float reverse_penalty
 
float travel_distance_reward
 
float rotation_penalty
 
bool allow_reverse_expansion
 
std::vector< std::vector< MotionPrimitive > > motion_primitives
 
ompl::base::StateSpacePtr state_space
 
std::vector< TrigValues > trig_values
 
std::string current_lattice_filepath
 
LatticeMetadata lattice_metadata
 

Detailed Description

A table of motion primitives and related functions.

Definition at line 51 of file node_lattice.hpp.

Member Function Documentation

◆ getAngleFromBin()

float & nav2_smac_planner::LatticeMotionTable::getAngleFromBin ( const unsigned int &  bin_idx)

Get the raw orientation from an angular bin.

Parameters
bin_idxIndex of the bin
Returns
Raw orientation in radians

Definition at line 170 of file node_lattice.cpp.

Referenced by nav2_smac_planner::NodeLattice::getDistanceHeuristic(), nav2_smac_planner::NodeLattice::isNodeValid(), and nav2_smac_planner::NodeLattice::precomputeDistanceHeuristic().

Here is the caller graph for this function:

◆ getClosestAngularBin()

unsigned int nav2_smac_planner::LatticeMotionTable::getClosestAngularBin ( const double &  theta)

Get the angular bin to use from a raw orientation.

Parameters
thetaAngle in radians
Returns
bin index of closest angle to request

Definition at line 155 of file node_lattice.cpp.

◆ getLatticeMetadata()

LatticeMetadata nav2_smac_planner::LatticeMotionTable::getLatticeMetadata ( const std::string &  lattice_filepath)
static

Get file metadata needed.

Parameters
lattice_filepathFilepath to the lattice file
Returns
A set of metadata containing the number of angular bins and the global coordinates minimum turning radius of the primitives for use in analytic expansion and heuristic calculation.

Definition at line 141 of file node_lattice.cpp.

Referenced by nav2_smac_planner::SmacPlannerLattice::configure(), nav2_smac_planner::SmacPlannerLattice::dynamicParametersCallback(), and nav2_smac_planner::NodeLattice::precomputeDistanceHeuristic().

Here is the caller graph for this function:

◆ getMotionPrimitives()

MotionPrimitivePtrs nav2_smac_planner::LatticeMotionTable::getMotionPrimitives ( const NodeLattice node)

Get projections of motion models.

Parameters
nodePtr to NodeLattice
Returns
A set of motion poses

Definition at line 114 of file node_lattice.cpp.

Referenced by nav2_smac_planner::NodeLattice::getNeighbors().

Here is the caller graph for this function:

◆ initMotionModel()

void nav2_smac_planner::LatticeMotionTable::initMotionModel ( unsigned int &  size_x_in,
SearchInfo search_info 
)

Initializing state lattice planner's motion model.

Parameters
size_x_inSize of costmap in X
search_infoParameters for searching

Definition at line 48 of file node_lattice.cpp.


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