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

Global Costmap Implementation

asked 2014-12-05 04:22:02 -0500

Greetings,

I would like to ask if there is a way to create a global costmap for the navigation package from a map that doesnt comply to the 3 color standard ROS expects. This means having a map with extra information, such as elevation and terrain type. Ideally I would like to create the global costmap only once in order to calculate a single global path.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2014-12-06 17:16:08 -0500

l0g1x gravatar image

The costmap_2d package only accepts a nav_msgs::OccupancyGrid type of map into the static_map layer of the costmap. Im assuming the static_map layer is what you are interested in since you want to 'create' a global costmap and then be able to calculate a single global path for the robot to traverse along. However, you must note that the nav_msgs::OccupancyGrid is a 2D representation of a grid map (3 colors as you mentioned; known, empty, unknown).

One thing you could do, is set the voxel grid parameter in your costmap configurations to true, so that your data (pointclouds, LIDAR, etc) is represented in 3D; just setup your observation sources to whatever types of sensors you use like in line 38. But i actually am not sure myself if the path planner will plan paths around elevated obstacles (for example like a hanging chandelier) since you only specify 2D footprint of your robot (width and length) but no height. But now that i think about it, i think all the 3D obstacle data gets squashed into a 2D layer anyway (can someone verify this please?).

Another option would be using a octomap which is a 3D occupancy grid. Please note, you wont be able to simply input the 3D occupancy grid into the costmap static_layer through the /map topic, since the topic sends nav_msgs::OccupancyGrid messages as i said above. However i have found a question here which basically states that the octomap_server can already just publish a 2D projection of your 3D occupancy grid, so you can use it with the map_server or costmap static layer.

Hope this helps

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2014-12-05 04:22:02 -0500

Seen: 1,279 times

Last updated: Dec 06 '14