Your robot sim is lying about friction
BAM replaces toy friction models with data-driven servo physics so policies trained in simulation actually survive contact with real motors.

What it does
BAM is a Python toolkit that fits extended friction models to real servo trajectories, then drops them into MuJoCo. It ships ready-made models for seven common actuators—including Dynamixel and eRob series—so you can swap out the default Coulomb-Viscous approximation for something that acknowledges Stribeck effects and load-dependent drag.
The interesting bit
Most simulators treat servo friction like a simple dimmer switch; BAM treats it like the weird mechanical mess it actually is. The payoff is a narrower sim-to-real gap when you are doing reinforcement learning on physical hardware.
Key highlights
- Pre-identified models for seven servos (Dynamixel MX-64/106/XL-320/XL330, eRob80:50/100, Feetech STS3215)
- Supports both MuJoCo CPU and the newer MuJoCo Warp backend
- Includes an identification pipeline to fit models from your own recorded trajectories
- Targets complex phenomena like Stribeck, load-dependence, and quadratic friction
- Backed by an ICRA 2025 paper
Caveats
- The README is essentially a landing page; most technical details live on ReadTheDocs.
- Only seven servos have pre-built models; anything else requires running the identification pipeline yourself.
- The BibTeX software citation lists the release as version 0.0.1.
Verdict
Grab this if you are training RL policies on real robots and wondering why your sim-perfect gait falls apart on hardware. Skip it if your actuators already behave like idealized physics homework.
Frequently asked
- What is Rhoban/bam?
- BAM replaces toy friction models with data-driven servo physics so policies trained in simulation actually survive contact with real motors.
- Is bam open source?
- Yes — Rhoban/bam is open source, released under the Apache-2.0 license.
- What language is bam written in?
- Rhoban/bam is primarily written in Python.
- How popular is bam?
- Rhoban/bam has 502 stars on GitHub.
- Where can I find bam?
- Rhoban/bam is on GitHub at https://github.com/Rhoban/bam.