Use MapClosures in your C++ project
- Include the following snippet in your project's
CMakeLists.txt:
set(USE_SYSTEM_EIGEN3 ON CACHE BOOL "use system eigen3")
set(USE_SYSTEM_OPENCV ON CACHE BOOL "use system opencv")
include(FetchContent)
FetchContent_Declare(
map_closures
GIT_REPOSITORY https://github.com/PRBonn/MapClosures.git
GIT_TAG main
SOURCE_SUBDIR cpp
)
FetchContent_MakeAvailable(map_closures)
You can trigger the automatic installation of the dependencies by playing around with the options in the first three lines of the snippet.
- Link MapClosures against your library or executable:
target_link_libraries(my_target PUBLIC map_closures)
- The following include directive in your source code file will provide access to the core API of MapClosures:
#include <map_closures/MapClosures.hpp>
Install the Python API and CLI
pip install map-closures
Usage
The following command will provide details about how to use our pipeline:
map_closure_pipeline --help

Providing the -v flag will initialize the visualizer:

Citation
If you use this library for any academic work, please cite our original papers.
@inproceedings{gupta2024icra,
author = {S. Gupta and T. Guadagnino and B. Mersch and I. Vizzo and C. Stachniss},
title = {{Effectively Detecting Loop Closures using Point Cloud Density Maps}},
booktitle = {IEEE International Conference on Robotics and Automation (ICRA)},
year = {2024},
codeurl = {https://github.com/PRBonn/MapClosures},
}
@article{gupta2026ijrr,
author = {Saurabh Gupta and Tiziano Guadagnino and Benedikt Mersch and Niklas Trekel and Meher V. R. Malladi and Cyrill Stachniss},
title = {{Efficiently Closing Loops in LiDAR-Based SLAM Using Point Cloud Density Maps}},
booktitle = {The International Journal of Robotics Research (IJRR)},
volume = {0},
number = {0},
year = {2026},
codeurl = {https://github.com/PRBonn/MapClosures},
}
Paper Results
As we decided to continue the development of MapClosures beyond the scope of the papers, we created a git tag so that researchers can consistently reproduce the results of the publication. To checkout at this tag, you can run the following:
git checkout ICRA2024
git checkout gupta2026ijrr
Our development aims to push the performances of MapClosures above the original results of the paper.
Acknowledgement
This repository is heavily inspired by, and also depends on KISS-ICP
Contributors