MBA-SLAM requires an NVIDIA GPU and CUDA. We provide two ways to set up the environment.
Create the Python environment from environment.yaml:
conda env create -f environment.yaml
conda activate mba-slam
pip install -r requirements.txt
pip install pypose --no-depsBuild and install the MBA-VO extension:
cd external/MBA-VO
cmake -GNinja -B build
cmake --build build -t install
cd python
pip install .
cd ../../..If cmake --build build -t install cannot write to /usr/local, run that install step with sudo, then run sudo ldconfig. If CMake cannot find Eigen, OpenCV, or CUDA, install the corresponding system packages first, or use the Docker environment below.
The project Docker setup uses two images. Dockerfile.dev builds the base environment and tags it as mba-slam-base; Dockerfile then uses FROM mba-slam-base and installs MBA-VO plus the remaining Python requirements.
Build the base image:
docker build -f Dockerfile.dev -t mba-slam-base .Build the MBA-SLAM image:
docker build -f Dockerfile -t mba-slam .Run the container from the project root:
docker run --gpus all --ipc=host -it --rm \
-v "$(pwd)":/workspace/MBA-SLAM \
-w /workspace/MBA-SLAM \
mba-slam bashInside the container, you can quickly check CUDA and MBA-VO:
python -c "import torch; import pymbavo; print('cuda:', torch.cuda.is_available())"The Docker build compiles several CUDA/C++ dependencies and can take a long time. Make sure the host has Docker, the NVIDIA driver, and NVIDIA Container Toolkit installed.
Put the dataset under the path used by the config file. For example, configs/MbaVo/archviz1.yaml expects:
data:
input_folder: Datasets/MBA-VO/archviz1
output: output/MBA-VO/archviz1Run MBA-SLAM on the ArchViz1 example config:
python run.py ./configs/MbaVo/archviz1.yamlOutputs are written to the config's data.output directory.
After training, evaluate the absolute trajectory error with:
python ./src/tools/eval_ate.py ./configs/MbaVo/archviz1.yamlEvaluate 3D and 2D reconstruction metrics with:
python ./src/tools/eval_recon.py --rec_mesh <your.ply path> --gt_mesh <gt.ply path> -3d -2dIf you find this useful, please consider citing our paper:
@article{wang2025mbaslam,
title = {MBA-SLAM: MBA-SLAM: Motion Blur Aware Dense Visual SLAM with Radiance Fields Representation},
author = {Wang, Peng and Zhao, Lingzhe and Zhang, Yin and Zhao, Shiyu and Liu, Peidong},
journal = {IEEE Transactions on Pattern Analysis and Machine Intelligence},
year = {2025},
publisher = {IEEE}
}
or
@article{wang2024mbaslam,
title = {MBA-SLAM: Motion Blur Aware Gaussian Splatting SLAM},
author = {Wang, Peng and Zhao, Lingzhe and Zhang, Yin and Zhao, Shiyu and Liu, Peidong},
journal = {arXiv preprint arXiv:2411.08279},
year = {2024}
}We would like to thank the authors of CoSLAM, ESLAM, gsplat, and MonoGS for their excellent open-source projects and helpful discussions.

