mujoco-playground

Installation
SKILL.md

MuJoCo Playground Sim-to-Real Composition (playground_sim2real.py)

Compose live MuJoCo Studio visualization, perception, IK, collision-aware planning, and visual servoing on mujoco_playground's out-of-the-box so101 and yam 50 Hz DeviceLayer stacks with identical code in mode="sim" and mode="real":

  1. Workspace Setup:

    • Clone and sync: git clone https://github.com/google-deepmind/mujoco_playground.git && cd mujoco_playground && make sync-cpu (or make sync / make sync-cu12 on Linux CUDA; add uv sync --extra so101 or --extra yam --default-index https://pypi.org/simple on robot hosts, and pass --no-sync to uv run).
    • Install composed skill packages into .venv: uv pip install --python .venv/bin/python --default-index https://pypi.org/simple ruckig opencv-python-headless scipy mink daqp. Set MUJOCO_GL=osmesa only on headless Linux (omit on macOS).
  2. Unified sim / real DeviceLayer Execution (PlaygroundSim2Real):

    • Wrap SO101Follower / SO101FollowerDevice (so101_aloha_table, arm in rad, gripper in [0, 100]) or YamFollower / YamFollowerDevice (yam_aloha_table, arm in rad, gripper in [0, 1]) via with PlaygroundSim2Real(robot="yam", mode="sim", setup_scene=...) as env:, passing setup_scene(spec) (mujoco-spec-editing / mujoco-python) to customize objects, containers, conveyors, or camera/base poses for any scene.
    • Never bypass the follower DeviceLayer or read privileged object mj_data.xpos inside controllers; PlaygroundSim2Real steps through follower/goal_position/*, reads follower/joint_position/* + camera streams, and cosine-interpolates safely to FOLLOWER_HOME on close().
Installs
20
GitHub Stars
161
First Seen
3 days ago