A web-based map editor for quick editing of ROS and ROS2 SLAM maps
This repository provides a web-based map editor designed specifically for quick and convenient editing of ROS and ROS2 SLAM maps, such as those created in the popular slam_toolbox. As the ROS2 ecosystem never had a native tool for this purpose, a significant gap existed in the workflow of many robotics developers and researchers. Instead of command lines or image editors, this is a hassle-free, open-source tool that enables engineers and researchers to fine-tune their SLAM maps right inside a modern browser, as well as create Keep-out zones using a mask-filter overlay.
The map editor can be thought of as a specialized paint tool, allowing users to effortlessly modify and refine their maps with precision. With this tool, users can add, remove, or modify map features, such as walls, obstacles, and other elements (e.g. furniture changes in a building), to create a more accurate and reliable representation of their environment. This tool helps users achieve what would normally take longer with a 3rd party image editor.
- Completely Browser-based Self-Hosted Solution (superior privacy)
- Responsive Map Editing for Touchscreen Devices and Computers
- Drag and Drop Map PGM and YAML files
- Drag and Drop Keepout PGM and YAML files (suffix as
_keepout.pgmand_keepout.yaml) - Drag and Drop to Load Both File Sets
- Uses Font Awesome for sleek UI icons
- Convenient Zoom In, Zoom Out, and Auto-Fit buttons
- Invert and Auto-level options
- Paint or Erase Walls in your PGM Map
- Paint or Erase Keep-out zones in your PGM Map
- Un-Scan Area (Mark area as unknown)
- Line or Rectangle Tools for Clean Edits
- Live-Preview Overlay for Brushing or Drawing Lines/Rectangles
- Multi-level Undo and Redo Capabilities (with
CTRL+ZandCTRL+Yhotkeys) - Option to Draw Filled Rectangles
- (Hold
Spacebar+ Drag Mouse) to Pan the Map - (Hold
Shift+ Scroll) to Zoom to Cursor - Drag to Take Measurements Dynamically from a Map
- Download Separate Map and Keepout Mask (yaml and PGM files)
Future Work:
- Speed Limit Mask overlay
- Polygon Tool
- Grid in Meters
You can use this tool for free by visiting: https://gyropalm.github.io/ROS-SLAM-Map-Editor/editor.html
Demo SLAM maps are included in the maps folder.
- Select both your
map.yamlandmap.pgmfiles. Drag and drop them in the top-left designated box. - Once loaded, you should see the "YAML preview" and Debug info. You can Zoom In or Zoom Out using the bottoms on the top toolbar. You can also zoom by holding
Shiftand scrolling up. - Click the
Wallbutton to start painting a wall at your desired area. Change the Brush size by using the slider on the right. (Zooming in will not change your brush size) - You can also use the "Line" or "Rectangle" mode to draw cleaner walls or keep-out zones. To draw a solid-filled rectangle, checkmark the
Filledoption. - Select the
Erasebutton to erase a wall. If you wish to mark an area as unknown, select theUn-Scanbutton. - To draw a Keep-Out zone, click the
Keep-Outbutton, then choose between "Freehand", "Line", or "Rectangle" mode. - To measure distance of one point to another, select the "Measure Distance" mode (icon with dual arrows). Then click on point A and drag your mouse to point B to see the dimension. Both meters and feet are provided for convenience.
- Once editing is completed, click the
Download Mapbutton and you will be prompted to save your updatedmap_edited.yamlandmap_edited.pgmfiles respectively. Do the same for Keep-Out zones by clickingDownload Keepout Mask.
This tool is created by Dominick Lee as part of GyroPalm's OmniBot V2 AMR product. By making this tool available to the open-source community, the author demonstrates commitment to the principles of collaboration and innovation that are at the heart of the open-source community and ROS2 ecosystem. If you are interested in ROS2 gesture-based robotic control, collaboration based on ROS2 robots, have a commercial use-case, or would like to support the author's work, please feel free to reach out at dlee(@)gyropalm.com
If you choose to use this tool in your work or research, please refer to the MIT license file provided. Please cite the work as follows:
Lee, Dominick. (2025). ROS SLAM Map Editor [Computer software]. GyroPalm, LLC. https://github.com/GyroPalm/ROS-SLAM-Map-Editor
