Global Planner With Different Planner Algorithms
I was wondering if there is a .launch file that allows to run the different planner algorithms (e.g. APF, A*, Dijkstra's....) ? Or perhaps if there might be a file in the base_move package to perform that automatically?
I am performing my simulation in Gazebo/RViz platform using the turtlebot3/navigation packages and would like to use different algorithms for path planning and compare their performance. I would like to only have to run one launch file several times instead of re-configuring multiple other files to adjust to each different algorithm since I will be running many simulations with several path planning algorithms.
I am using ROS kinetic & Ubuntu 16.04.
Thank you in advance.
Asked by jesus on 2019-02-25 13:10:05 UTC
Answers
If you are using the default "global_planner/GlobalPlanner" plugin, you have the option to toggle between 2 different types of global planners, A* and Dijkstra's. If you are not already using the GlobalPlanner plugin, you can do so by first going over to "turtlebot3_navigation/launch/move_base.launch" and adding the following line to your move_base node as follows:
<node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">
<param name="base_local_planner" value="dwa_local_planner/DWAPlannerROS" />
<param name="base_global_planner" value="global_planner/GlobalPlanner"/>
<rosparam file="$(find turtlebot3_navigation)/param/global_planner.yaml" command="load" ns="GlobalPlanner"/>
...
You can then toggle between A* and Dijkstra's in your global_planner.yaml file. Please create this param file according to the global_planner documentation. An example is provided below:
allow_unknown: true
default_tolerance: 0.0
visualize_potential: false
use_dijkstra: true
use_quadratic: true
use_grid_path: false
old_navfn_behavior: false
lethal_cost: 253
neutral_cost: 50
cost_factor: 1.0
publish_potential: True
orientation_mode: 1
orientation_window_size: 1
outline_map: true
If you would like to try out alternative global planners aside from the defaults, you can check out sbpl_lattice_planner from the navigation_experimental repo.
Alternatively, if you need to write your own global planner plugin to suit your needs, you can refer to Writing A Global Path Planner As Plugin in ROS
Asked by JohnTGZ on 2021-10-02 11:14:07 UTC
Comments