ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

How does DWA works in relation to global planner?

asked 2019-10-23 08:19:48 -0500

kiko453 gravatar image

updated 2019-10-23 08:21:31 -0500

I'm trying to understand how DWA works by looking at this implementation

https://github.com/AtsushiSakai/Pytho...

I try to make the connection with global planner. I don't see where global planner comes into play.

  • How does DWA use information provided by the global planner in ROS, more precisely the trajectory coming from global planner that DWA has to follow? I don't see anywhere where it is following some trajectory.
  • What others information coming from global planner (apart from the trajectory) does DWA use?
  • How does DWA know about the obstacles? because in this implementation, to compute the cost, it computes the distance to each obstacles, so DWA should somehow as input know where the obstacles are (coordinates of obstacle I presume).
  • When we talk about trajectory in DWA (in the original papers they also often use the term trajectory), does DWA compute itself some trajectory to follow or does it follow a trajectory generated by the global planner?

How does all of this work in the DWA implementation of ros? Thanks a lot.

edit retag flag offensive close merge delete

Comments

Please realise that the code you link to appears to be a completely ROS-agnostic implementation. I don't know whether you'll receive any answers here, as on ROS Answers, we typically tend to discuss ROS-related topics and questions.

gvdhoorn gravatar image gvdhoorn  ( 2019-10-23 08:31:09 -0500 )edit

my questions are however general related and therefore also ROS related. I just wanted to cite the resource I'm learning DWA from.

kiko453 gravatar image kiko453  ( 2019-10-23 08:38:15 -0500 )edit

I'm inclined to agree with @gvdhoorn, this isn't a ROS question. That implementation is independent to all of your followups.

stevemacenski gravatar image stevemacenski  ( 2019-10-23 12:02:46 -0500 )edit

2 Answers

Sort by ยป oldest newest most voted
0

answered 2019-12-07 08:53:41 -0500

ed gravatar image

I am also trying to sort out how this is working because I am having issues with it. But to answer your questions specifically

Looking at the ROS implementation here is more info on the inputs

The question about knowing where the obstacles are. It uses a costmap. This is set it initialize in dwa_planner_ros and then is passed to dwa_planner in its constructor

The question about the trajectory is the global plan This is set it initialize in dwa_planner_ros and then is passed to dwa_planner in its constructor. as fergs said the global plan is just a set of pose

Other information velocity max and mins are sent in and they are split into linear x and theta z velocities from the min (which should be negative) to the max and put into 2 array of potential velocities to be used. this is done in planner_util I think. Also the robot's current velocity and position are passed in.

edit flag offensive delete link more
0

answered 2019-10-23 21:58:01 -0500

fergs gravatar image

DWA is really more of a controller - not a planner. Given a trajectory (which in ROS is simply an array of geometry_msgs/Pose), and the current position of the robot (again, another Pose message), it will compute the best command to apply to the mobile base at that instant in time (in ROS, a geometry_msgs/Twist message). If you run the DWA algorithm at a high enough frequency (20-50hz), you can "follow" the plan pretty accurately.

In the ROS implementation, the "trajectory" is nothing but a series of poses - there is no time-parameterization, etc. This trajectory is created by a global planner (which, really, is the only real "planner" since DWA really is more of a "controller").

The ROS implementations are located here: https://github.com/ros-planning/navig...

edit flag offensive delete link more

Question Tools

2 followers

Stats

Asked: 2019-10-23 08:19:48 -0500

Seen: 1,133 times

Last updated: Dec 07 '19