Rosanswers logo

This is a noobie question. But I found that we can manually edit the map file generated from the gmapping output using some editors. So can we use a png/jpeg map and transform it into some different format which can be used by the acml to navigate later? If yes then please guide me through. If not, then can I enhance the map output from gmapping using this PNG map? like fix some corners etc.

Thank you! :D



Edit - I changed JPEG to PNG after considering the remark in the accepted answer.

Originally posted by pallavbakshi on ROS Answers with karma: 39 on 2017-02-04

Post score: 1


1 Answer 1


Rosanswers logo

The map you've linked to is a PNG, not a JPEG; but that shouldn't really matter in the bigger picture.

It should be possible to manually create a map for AMCL, but it needs to be in specific format:

  • In PGM format, so that the map_server can load it
  • Black and white; black for obstacles, white for free space
  • Properly scaled, so that one pixel in your map matches the resolution setting in AMCL

Keep in mind that the map should be WHAT THE SENSOR SEES and not what you see. In particular, some of the typical lidars may not see glass windows or mirrors the same way you do.

So yes, you could start with your building map, but you'd probably need to make significant edits to scale it and get it into the correct format.

There are also a few existing questions about editing existing maps that may be useful:

Originally posted by ahendrix with karma: 47576 on 2017-02-04

This answer was ACCEPTED on the original site

Post score: 4


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.