Public Member Functions | Private Member Functions | Private Attributes | List of all members
base_local_planner::OscillationCostFunction Class Reference

#include <oscillation_cost_function.h>

Inheritance diagram for base_local_planner::OscillationCostFunction:
Inheritance graph
[legend]

Public Member Functions

 OscillationCostFunction ()
 
bool prepare ()
 
void resetOscillationFlags ()
 Reset the oscillation flags for the local planner. More...
 
double scoreTrajectory (Trajectory &traj)
 
void setOscillationResetDist (double dist, double angle)
 
void updateOscillationFlags (Eigen::Vector3f pos, base_local_planner::Trajectory *traj, double min_vel_trans)
 
virtual ~OscillationCostFunction ()
 
- Public Member Functions inherited from base_local_planner::TrajectoryCostFunction
double getScale ()
 
void setScale (double scale)
 
virtual ~TrajectoryCostFunction ()
 

Private Member Functions

void resetOscillationFlagsIfPossible (const Eigen::Vector3f &pos, const Eigen::Vector3f &prev)
 
bool setOscillationFlags (base_local_planner::Trajectory *t, double min_vel_trans)
 Given a trajectory that's selected, set flags if needed to prevent the robot from oscillating. More...
 

Private Attributes

bool forward_neg_
 
bool forward_neg_only_
 
bool forward_pos_
 
bool forward_pos_only_
 
double oscillation_reset_angle_
 
double oscillation_reset_dist_
 
Eigen::Vector3f prev_stationary_pos_
 
bool rot_neg_only_
 
bool rot_pos_only_
 
bool rotating_neg_
 
bool rotating_pos_
 
bool strafe_neg_only_
 
bool strafe_pos_only_
 
bool strafing_neg_
 
bool strafing_pos_
 

Additional Inherited Members

- Protected Member Functions inherited from base_local_planner::TrajectoryCostFunction
 TrajectoryCostFunction (double scale=1.0)
 

Detailed Description

Definition at line 81 of file oscillation_cost_function.h.

Constructor & Destructor Documentation

◆ OscillationCostFunction()

base_local_planner::OscillationCostFunction::OscillationCostFunction ( )

Definition at line 79 of file oscillation_cost_function.cpp.

◆ ~OscillationCostFunction()

base_local_planner::OscillationCostFunction::~OscillationCostFunction ( )
virtual

Definition at line 82 of file oscillation_cost_function.cpp.

Member Function Documentation

◆ prepare()

bool base_local_planner::OscillationCostFunction::prepare ( )
inlinevirtual

General updating of context values if required. Subclasses may overwrite. Return false in case there is any error.

Implements base_local_planner::TrajectoryCostFunction.

Definition at line 123 of file oscillation_cost_function.h.

◆ resetOscillationFlags()

void base_local_planner::OscillationCostFunction::resetOscillationFlags ( )

Reset the oscillation flags for the local planner.

Definition at line 119 of file oscillation_cost_function.cpp.

◆ resetOscillationFlagsIfPossible()

void base_local_planner::OscillationCostFunction::resetOscillationFlagsIfPossible ( const Eigen::Vector3f &  pos,
const Eigen::Vector3f &  prev 
)
private

Definition at line 105 of file oscillation_cost_function.cpp.

◆ scoreTrajectory()

double base_local_planner::OscillationCostFunction::scoreTrajectory ( Trajectory traj)
virtual

return a score for trajectory traj

Implements base_local_planner::TrajectoryCostFunction.

Definition at line 201 of file oscillation_cost_function.cpp.

◆ setOscillationFlags()

bool base_local_planner::OscillationCostFunction::setOscillationFlags ( base_local_planner::Trajectory t,
double  min_vel_trans 
)
private

Given a trajectory that's selected, set flags if needed to prevent the robot from oscillating.

Parameters
tThe selected trajectory
Returns
True if a flag was set, false otherwise

Definition at line 136 of file oscillation_cost_function.cpp.

◆ setOscillationResetDist()

void base_local_planner::OscillationCostFunction::setOscillationResetDist ( double  dist,
double  angle 
)

Definition at line 86 of file oscillation_cost_function.cpp.

◆ updateOscillationFlags()

void base_local_planner::OscillationCostFunction::updateOscillationFlags ( Eigen::Vector3f  pos,
base_local_planner::Trajectory traj,
double  min_vel_trans 
)

Definition at line 91 of file oscillation_cost_function.cpp.

Member Data Documentation

◆ forward_neg_

bool base_local_planner::OscillationCostFunction::forward_neg_
private

Definition at line 150 of file oscillation_cost_function.h.

◆ forward_neg_only_

bool base_local_planner::OscillationCostFunction::forward_neg_only_
private

Definition at line 150 of file oscillation_cost_function.h.

◆ forward_pos_

bool base_local_planner::OscillationCostFunction::forward_pos_
private

Definition at line 150 of file oscillation_cost_function.h.

◆ forward_pos_only_

bool base_local_planner::OscillationCostFunction::forward_pos_only_
private

Definition at line 150 of file oscillation_cost_function.h.

◆ oscillation_reset_angle_

double base_local_planner::OscillationCostFunction::oscillation_reset_angle_
private

Definition at line 153 of file oscillation_cost_function.h.

◆ oscillation_reset_dist_

double base_local_planner::OscillationCostFunction::oscillation_reset_dist_
private

Definition at line 153 of file oscillation_cost_function.h.

◆ prev_stationary_pos_

Eigen::Vector3f base_local_planner::OscillationCostFunction::prev_stationary_pos_
private

Definition at line 155 of file oscillation_cost_function.h.

◆ rot_neg_only_

bool base_local_planner::OscillationCostFunction::rot_neg_only_
private

Definition at line 149 of file oscillation_cost_function.h.

◆ rot_pos_only_

bool base_local_planner::OscillationCostFunction::rot_pos_only_
private

Definition at line 149 of file oscillation_cost_function.h.

◆ rotating_neg_

bool base_local_planner::OscillationCostFunction::rotating_neg_
private

Definition at line 149 of file oscillation_cost_function.h.

◆ rotating_pos_

bool base_local_planner::OscillationCostFunction::rotating_pos_
private

Definition at line 149 of file oscillation_cost_function.h.

◆ strafe_neg_only_

bool base_local_planner::OscillationCostFunction::strafe_neg_only_
private

Definition at line 148 of file oscillation_cost_function.h.

◆ strafe_pos_only_

bool base_local_planner::OscillationCostFunction::strafe_pos_only_
private

Definition at line 148 of file oscillation_cost_function.h.

◆ strafing_neg_

bool base_local_planner::OscillationCostFunction::strafing_neg_
private

Definition at line 148 of file oscillation_cost_function.h.

◆ strafing_pos_

bool base_local_planner::OscillationCostFunction::strafing_pos_
private

Definition at line 148 of file oscillation_cost_function.h.


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


base_local_planner
Author(s): Eitan Marder-Eppstein, Eric Perko, contradict@gmail.com
autogenerated on Mon Mar 6 2023 03:50:24