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

Revision history [back]

click to hide/show revision 1
initial version

You can use any image editor. I would recommend using GIMP in Ubuntu. After drawing your map, export it to .png or .pgm format. The tricky thing is to populate the YAML file that contains metadata of the map. The fields in the YAML file are,

  • image: yourimagename.png
  • resolution: 0.1 (this is the distance/pixel value. 0.1 refers to a distance of 0.1m between adjacent pixels)
  • origin: [0, 0, 0] (this is the coordinate of the lower left pixel in your image (x,y,yaw))
  • occupied_thresh : 0.9 (Pixels with occupancy probability greater than this threshold are considered completely occupied.)
  • free_thresh :0.1 (Pixels with occupancy probability less than this threshold are considered completely free.)
  • negate : 0 (Whether the white/black free/occupied semantics should be reversed (interpretation of thresholds is unaffected))

There is a workaround to do this in a easy way. Checkout this YouTube video. [https://youtu.be/ySlU5CIXUKE]