BabyLocoFormer is an open-source unofficial baby version of LocoFormer. It includes the deployment of TransformerXL (not in its original form, but using flash attention, RoPE, SwiLU, etc.), multi-morph quadruped generation, limited domain randomization, and related training and evaluation.
-
Install Isaac Lab by following the installation guide. We recommend using the conda or uv installation as it simplifies calling Python scripts from the terminal.
-
Clone or copy this project/repository separately from the Isaac Lab installation (i.e. outside the
IsaacLabdirectory): -
Using a python interpreter that has Isaac Lab installed, install the library in editable mode using:
pip install -e source/babylocoformer cd rsl_rl && pip install -e .
python scripts/list_envs.pypython model/generate_quad.py
python model/convert_to_usd.py.py --headless --input_dir <PATH> --output_dir <PATH>python scripts/rsl_rl/train.py --task=Babylocoformer-v0 --num_env 2048 --headless --video
python scripts/rsl_rl/play.py --task=Babylocoformer-v0
python scripts/rsl_rl/play.py --task=Unitree-Go2-VelocityIf you find this project useful or interesting, please consider starring ⭐ this repository! Contributions, issues, and pull requests are all very welcome — every bit of feedback helps the project grow. Let's make BabyLocoFormer even better together!
We have a pre-commit template to automatically format your code. To install pre-commit and run:
pip install pre-commit
pre-commit run --files <path/to/file>More robot morphologies help stabilize training, and stronger randomization improves adaptation, which makes sense. Just messing around. Results are bad, mainly for learning. Trained on a single 5090.
Thanks to the following projects for their great work and inspiration:
-
IsaacLab: The foundation for training and running codes.
-
Unitree_rl_lab : The training and evaluation codes.
-
LocoFormer: The core ideas.