SLAM Map Builder
Build 2-D grid maps using lidar-based SLAM
Description
The SLAM Map Builder app loads recorded lidar scans and odometry sensor data to build a 2-D occupancy grid using simultaneous localization and mapping (SLAM) algorithms. Incremental scan matching aligns and overlays scans to build the map. Loop closure detection adjusts for drift of the vehicle odometry by detecting previously visited locations and adjusting the overall map. Sometimes, the scan matching algorithm and loop closure detection require manual adjustment. Use the app to manually align scans and modify loop closures to improve the overall map accuracy. You can also tune the SLAM algorithm settings to improve the automatic map building.
To use the app:
| To load rosbag log files, select Import > Import from rosbag. Select the rosbag file and click Open. This opens the Import tab. For more information, see Import and Filter a rosbag. To load data from the workspace, Import > Import from workspace. Select your Scans and
Poses variables using the drop downs provided. You
can also specify the variables in the |
| Use SLAM Settings to adjust the SLAM algorithm settings. Default values are provided, but your specific sensors and data may require tuning of these settings. The most important value to tune is the Loop Closure Threshold. For more information, see Tune SLAM Settings. |
| Click Build to begin the SLAM map building process. The building process aligns scans in the map using incremental scan matching, identifies loop closures when visiting previous locations, and adjusts poses. Click Pause at any time during the map building process to manually align incremental scans or modify loop closures. |
| Click Incremental Match to modify the relative pose of the currently selected frame and align the scan with the previous scan. Click Loop Closure to modify or ignore the detected loop closure for the current frame. Use the slider on the bottom to scroll back to areas where scan matching or loop closures are not accurate. You can modify any number of scans or loop closures. For more information, see Modify Increment Scans and Loop Closures. |
| After modifying your map, click Sync to update all the poses in the scan map. The two options under Sync are Sync, which searches for new loop closures, or Sync Fast, which skips loop closure searching and just updates the scan map. For more information, see Sync the Map. |
| When you are satisfied with how the map looks, click Export to
OccupancyGrid to either export the map to an m-file or save the map in
the workspace. The map is output as a 2-D probabilistic occupancy grid in an occupancyMap object. |
| You can open existing app sessions you have saved using Open Session. When you are in the Map Builder tab, you can save your progress to an m-file using Save Session. |
Open the SLAM Map Builder App
MATLAB® Toolstrip: In the Apps tab, under ROBOTICS AND AUTONOMOUS SYSTEMS, click SLAM Map Builder.
MATLAB Command Window: Enter
slamMapBuilder
Examples
Related Examples
Parameters
Programmatic Use
More About
Version History
Introduced in R2019b
See Also
Functions
buildMap
|matchScans
|matchScansGrid
|rosbag
(ROS Toolbox) |optimizePoseGraph