SPI-Active is a sampling-based System Identification (SysID) framework for legged robots, designed with active exploration to identify parameters of legged robots and therby reducing sim2real gap.
This codebase implements the approach published in our CoRL 2025 paper.
Current codebase targets identification of the base mass, center of mass (CoM), and inertia parameters of the Unitree Go2 robot, along with a modular motor dynamics model—enabling robust sim-to-real transfer for legged locomotion control.
Key features:
- Hydra-powered configuration for clean, modular experiment setup
- Modular motor model classes inheriting from a base environment for easy extensibility
- Isaac Gym accelerated simulation for fast sampling and evaluation
- Release SPI Code
- Release Active Exploration code
- Release Downstream Task training code
- Release Dataset Replay and Visualize code
- Release Sim2real
This codebase is built following the structure of Humanoidverse and ASAP codebases.
- Ubuntu 22.04 LTS (recommended)
- NVIDIA GPU with CUDA support
- Python 3.8
- uv installed: https://docs.astral.sh/uv/getting-started/
- Quick install (Linux/macOS):
curl -LsSf https://astral.sh/uv/install.sh | sh
- Quick install (Linux/macOS):
uv venv -p 3.8
source .venv/bin/activateClone the repository and from the repo root:
# Installs the workspace in editable mode and resolves dependencies
uv sync --dev
uv pip install -e isaac_utils/Download IsaacGym and extract:
wget https://developer.nvidia.com/isaac-gym-preview-4
tar -xvzf isaac-gym-preview-4Install IsaacGym Python API:
uv pip install -e isaacgym/pythonTest installation:
python 1080_balls_of_solitude.py # or
python joint_monkey.pyFor libpython error:
- Check conda path:
conda info -e
- Set LD_LIBRARY_PATH:
export LD_LIBRARY_PATH=</path/to/conda/envs/your_env/lib>:$LD_LIBRARY_PATH
Tools for collecting trajectory data and identifying physical parameters (e.g., mass) in Isaac Gym.
- Note: For
walk.py, install unitree_rl_gym and placewalk.pyunderunitree_rl_gym/legged_gym/scripts/.
# walk.py should be run from unitree_rl_gym/legged_gym/scripts/
python scripts/data/walk.py [--no-video]
# Other data collection scripts
python scripts/data/jump.py [--no-video]
python scripts/data/stand.py [--no-video]
python scripts/data/sine.py [--no-video]Visualize prediction error across different mass values:
python scripts/mass_landscape.py --config all --horizon 5 \
--env-batch 2048 --project-dir logs/mass_landscape_allFind optimal mass using Bayesian optimization:
python scripts/mass_opt.py --config all --horizon 5 \
--env-batch 4096 --project-dir logs/mass_opt_allConfiguration: all, horizon=5, 50 trials
Ground truth base mass: 6.921 kg
Optimal base mass: 7.006 kg
Best cost: 0.028378
Detailed documentation in present in Active-SysID
Note
Currently the command and dataset is for Unitree Go2. More details on setting up custom dataset, robot parameters and motor models will be released soon!
We also provide training scripts to train the different downstream tasks we evaluate in our work. More details can be found in Downstream-Tasks
If you find our work useful, please consider citing us!
@article{sobanbabu2025spiactive,
title={Sampling-Based System Identification with Active Exploration for Legged Robot Sim2Real Learning},
author={Nikhil Sobanbabu and Guanqi He and Tairan He and Yuxiang Yang and Guanya Shi},
year={2025}
url={https://arxiv.org/abs/2505.14266},
}This project is licensed under the MIT License - see the LICENSE file for details.


