State Lattice Planning

This script is a path planning code with state lattice planning.

This code uses the model predictive trajectory generator to solve boundary problem.

Uniform polar sampling

https://github.com/AtsushiSakai/PythonRoboticsGifs/raw/master/PathPlanning/StateLatticePlanner/UniformPolarSampling.gif

Biased polar sampling

https://github.com/AtsushiSakai/PythonRoboticsGifs/raw/master/PathPlanning/StateLatticePlanner/BiasedPolarSampling.gif

Code Link

PathPlanning.StateLatticePlanner.state_lattice_planner.calc_biased_polar_states(goal_angle, ns, nxy, nh, d, a_min, a_max, p_min, p_max)[source]

calc biased state

Parameters:
  • goal_angle – goal orientation for biased sampling

  • ns – number of biased sampling

  • nxy – number of position sampling

  • nxy – number of position sampling

  • nh – number of heading sampleing

  • d – distance of terminal state

  • a_min – position sampling min angle

  • a_max – position sampling max angle

  • p_min – heading sampling min angle

  • p_max – heading sampling max angle

Returns:

states list

Lane sampling

https://github.com/AtsushiSakai/PythonRoboticsGifs/raw/master/PathPlanning/StateLatticePlanner/LaneSampling.gif

Code Link

PathPlanning.StateLatticePlanner.state_lattice_planner.calc_lane_states(l_center, l_heading, l_width, v_width, d, nxy)[source]

calc lane states

Parameters:
  • l_center – lane lateral position

  • l_heading – lane heading

  • l_width – lane width

  • v_width – vehicle width

  • d – longitudinal position

  • nxy – sampling number

Returns:

state list

Reference