需先装 git lfs 和 hugging face cli 再克隆 HF 上的数据集;nvcc --version 必须与 nvidia-smi 的 CUDA 版本一致,gcc/g++ 建议 10~12;本地跑可视化需额外 pip install rerun-sdk。
git clone https://github.com/VladimirYugay/MAGiC-SLAM.git
conda create -n magic-slam python=3.11
conda activate magic-slam
conda install pytorch==2.5.1 torchvision==0.20.1 pytorch-cuda=11.8 -c pytorch -c nvidia
conda install -c conda-forge faiss-gpu=1.8.0
pip install -r requirements.txtREADME 说明在 RTX3090 和 RTX A6000 上测试过,系统需要 n+1 块 GPU(n 为智能体数量),调试时可设 multi_gpu: False 与 agent_ids: [0] 用单卡同时跑服务端和智能体;未说明 CPU 运行与显存需求。
多智能体高斯全局一致 SLAM,让多个机器人协同建图并保持全局一致
多智能体 SLAM 系统,用高斯泼溅实现多机器人协同建图并保持全局一致,适合大规模场景的三维重建研究。
核心能力
- 多智能体各自跟踪建图后做全局一致性优化
- 基于 Gaussian-SLAM 实现单智能体跟踪与建图模块
- 用 GraphSLAM 库做位姿图全局优化
- 支持 ReplicaMultiagent 与 AriaMultiagent 数据集
- 用 Rerun 离线可视化建图结果
容易踩的坑
暂无 release 数据(可能没有发版,或尚未同步)。
用户点评
登录用户的真实使用记录,可按版本和硬件筛选还没有人点评。第一个说出真实体验的人最有价值。
⚙️ Setting Things Up
Clone the repo:
git clone https://github.com/VladimirYugay/MAGiC-SLAM.git
We tested the installation with gcc and g++ of versions 10, 11 and 12. Also, make sure that nvcc --version matches nvidia-smi version.
Run the following commands to set up the environment
conda create -n magic-slam python=3.11
conda activate magic-slam
Install pytorch:
# CUDA 11.8
conda install pytorch==2.5.1 torchvision==0.20.1 pytorch-cuda=11.8 -c pytorch -c nvidia
# CUDA 12.1
conda install pytorch==2.5.1 torchvision==0.20.1 pytorch-cuda=12.1 -c pytorch -c nvidia
# CUDA 12.4
conda install pytorch==2.5.1 torchvision==0.20.1 pytorch-cuda=12.4 -c pytorch -c nvidia
Install other dependencies:
conda install -c conda-forge faiss-gpu=1.8.0
pip install -r requirements.txt
In case you are on a local machine and want to run visualization script run:
pip install rerun-sdk
We tested our code on RTX3090 and RTX A6000 GPUs with Ubuntu22 and CentOS7.5 respectively.
🔨 Running MAGiC-SLAM
Here we elaborate on how to load the necessary data, configure Gaussian-SLAM for your use-case, debug it, and how to reproduce the results mentioned in the paper.
ReplicaMultiagent was created by CP-SLAM authors. However, it is a bit tricky to find it on the web. Therefore, we uploaded it to HF datasets for easier access. Install git lfs and download it by running: git lfs install git clone https://huggingface.co/datasets/voviktyl/ReplicaMultiagent
AriaMultiagent consists of clips from AriaDigitalTwin. You can download already processed data with the command: git clone https://huggingface.co/datasets/voviktyl/AriaMultiagent
Alternatively, you can create the data yourself. First, download raw AriaDigitalTwin sequences following instructions here. We recommend using the data tools described here. You can find the names of the raw videos we used in prepare_aria_room_data.py in DATASET_DICT. After you have downloaded the raw videos, process them using prepare_aria_room_data.py. This will create a folder with the format matching our repository.
python run_slam.py configs/<dataset_name>/<config_name> --input_path <path_to_the_scene> --output_path <output_path>
For example:
python run_slam.py configs/AriaMultiagent/room0.yaml --input_path <path_to>/AriaMultiagent/room0 --output_path output/AriaMultiagent/room0
In addition, you can set up wandb to log the results of the runs.
You can reproduce the results for a single scene by running:
python run_slam.py configs/<dataset_name>/<config_name> --input_path <path_to_the_scene> --output_path <output_path>
If you are running on a SLURM cluster, you can reproduce the results for all scenes in a dataset by running the script:
./scripts/reproduce_aria_sbatch.sh
🙏 Acknowledgments
Individual tracking and mapping modules of the agents are based on Gaussian-SLAM. We thank Jeff Irion, for the GraphSLAM library and the fruitful discussions.
📌 Citation
If you find our paper and code useful, please cite us:
@misc{yugay2024magicslammultiagentgaussianglobally,
title={MAGiC-SLAM: Multi-Agent Gaussian Globally Consistent SLAM},
author={Vladimir Yugay and Theo Gevers and Martin R. Oswald},
year={2024},
eprint={2411.16785},
archivePrefix={arXiv},
primaryClass={cs.CV},
url={https://arxiv.org/abs/2411.16785},
}