Skip to content

AI model

MOSAIC (humanoid motion tracking and teleoperation)

By BAAI-Humanoid, China (checked on github.com/BAAI-Humanoid (opens in a new tab)), from github.com/BAAI-Humanoid/MOSAIC (opens in a new tab)

  • Humanoids and robot learning
  • Apache-2.0 (code)
  • Apache-2.0 (weights)

MOSAIC is a training codebase for humanoid motion tracking and whole-body teleoperation, built on Isaac Lab and aimed at G1, H1_2 and Adam robots.

Facts

Code last updated
7 Mar 2026Newest commit on main
Maintenance
Maintaineda commit in the last 12 months
Difficulty
Advanced

Checked on GitHub on 28 Nov 2026.

Licenses

Code
Apache-2.0 (opens in a new tab)

Read by Robotheca from LICENSE (opens in a new tab) (Apache-2.0) at commit d73e885 (opens in a new tab), on 16 Oct 2026.

Commercial use
Yes

At a glance

What it is
  • Trains a teleoperation-oriented motion tracker that emphasizes global motion consistency for long-horizon behaviors.
  • Adds interface-specific corrections through rapid residual adaptation to bridge sim-to-real gaps.
  • Converts retargeted motion CSV files into full kinematic data via forward kinematics for training.
  • Provides task IDs for single-motion and multi-motion tracking, distillation, and multi-teacher residual training.
  • Supports multi-GPU training through torchrun and logs runs to WandB.
  • Deployment to simulation or a real robot is handled by a separate project, RobotBridge.

Robotheca's summary of the project's documents, not the creator's words.

Robots on Robotheca
No robot on Robotheca uses this model yet.
Licence
Apache-2.0 (code); Apache-2.0 (weights). Commercial use: Yes. Where it was read
Load it
In the creator's words: The project's website (opens in a new tab)
Maintenance
Maintained, last commit on 7 Mar 2026.

Use it

How to load it, in the creator's words: The project's website (opens in a new tab)

Robotheca doesn't review code. Read it before running it.

Files and versions

Facts read at commit d73e885

Robotheca never hosts the code or the weights: each link goes to the creator's own page.

The README and the model card

The creator's own README, copied as written: README.md by BAAI-Humanoid, at commit d73e885, under Apache-2.0 (opens in a new tab). The original on GitHub (opens in a new tab).

Read the README here

MOSAIC Training Code

(opens in a new tab) (opens in a new tab) (opens in a new tab) (opens in a new tab) (opens in a new tab) (opens in a new tab)

[Website] (opens in a new tab) [Arxiv] (opens in a new tab) [Dataset] (opens in a new tab) [Model] (opens in a new tab)

Overview

MOSAIC is an open-source system for generalist humanoid motion tracking and whole-body teleoperation across multiple interfaces. It trains a teleoperation-oriented tracker with rewards that emphasize global motion consistency for stable, long-horizon behaviors. To bridge sim-to-real interface gaps, it uses rapid residual adaptation to inject interface-specific corrections while preserving generality.

This repo focuses on the teleoperation policy training; for sim-to-sim and sim-to-real deployment, see RobotBridge (opens in a new tab).

Installation
  • Install Isaac Lab v2.1.0 by following the installation guide (opens in a new tab). We recommend using the conda installation as it simplifies calling Python scripts from the terminal.

    # create virtual environment
    conda create -n isaaclab python=3.10 -y
    conda activate isaaclab
    pip install --upgrade pip
    
    # install PyTorch
    pip install torch==2.5.1 torchvision==0.20.1 --index-url https://download.pytorch.org/whl/cu121
    
    # install isaacsim 4.5
    pip install "isaacsim[all,extscache]==4.5.0" --extra-index-url https://pypi.nvidia.com
    
    # verify the isaacsim installation
    isaacsim 
    
    ## isaaclab
    # download
    git clone https://github.com/isaac-sim/IsaacLab.git
    cd IsaacLab
    
    # switch to version 2.1.0
    git fetch --all
    git checkout v2.1.0 
    
    # install
    ./isaaclab.sh --install
    
    # verify
    ./isaaclab.sh -p scripts/tutorials/00_sim/create_empty.py
    
    
  • Clone this repository separately from the Isaac Lab installation (i.e., outside the IsaacLab directory):

# Option 1: SSH (main branch only)
git clone -b main --single-branch git@github.com:BAAI-Humanoid/MOSAIC.git

# Option 2: HTTPS (main branch only)
git clone -b main --single-branch https://github.com/BAAI-Humanoid/MOSAIC.git
  • Using a Python interpreter that has Isaac Lab installed, install the library
python -m pip install -e source/whole_body_tracking

and install the algorithm library

python -m pip install -e source/rsl_rl
General Training Pipeline
Motion Preprocessing

We store all processed motions locally. The reference motion should be retargeted and use generalized coordinates only.

  • Gather the reference motion datasets (please follow the original licenses), we use the same convention as .csv of Unitree's dataset (opens in a new tab)

  • Convert retargeted motions to include the maximum coordinates information (body pose, body velocity, and body acceleration) via forward kinematics:

    • Single Motion
    python scripts/csv_to_npz.py --input_file {motion_name}.csv --input_fps 30 --output_name {motion_name} --headless
    

    The processed motion file will be saved locally with output name {motion_name}.

    • Multiple Motions
    python scripts/batch_csv_to_npz.py --input_dir {motion_path} --input_fps 30 --output_prefix {output_name} --output_dir {motion_save_path} --headless
    

    This converts the processed motion files to the output target path {motion_save_path}.

  • Replay motions from local files in Isaac Sim:

python scripts/replay_npz.py --motion_file={motion_file_path}
Policy Training
  • Train policy by the following command for single motion:
python scripts/rsl_rl/train.py --task=Tracking-Flat-G1-v0 \
--motion the path to the motion file \
--headless --logger wandb --log_project_name {project_name} --run_name {run_name}
  • Train policy by the following command for multiple motion:
python scripts/rsl_rl/train.py --task=General-Tracking-Flat-G1-v0 \
--motion the path to the motion folder \
--headless --logger wandb --log_project_name {project_name} --run_name {run_name}
  • If you want to activate multiple GPUs for training in parallel, just follow the command like that:
torchrun --standalone --nnodes=1 --nproc_per_node=2 scripts/rsl_rl/train.py --task=General-Tracking-Flat-G1-v0 --distributed \
--headless --logger wandb --log_project_name {project_name} --run_name {run_name} \
--motion the path to the motion folder
Policy Evaluation
  • Play the trained policy by the following command for single motion:
python scripts/rsl_rl/play.py --task=Tracking-Flat-G1-v0 --num_envs=2 --wandb_path={wandb-run-path}
  • Play the trained policy by the following command for multiple motion:
python scripts/rsl_rl/play.py --task=General-Tracking-Flat-G1-v0 --num_envs=2 --wandb_path={wandb-run-path}

The WandB run path can be located in the run overview. It follows the format {your_organization}/{project_name}/ along with a unique 8-character identifier. Note that run_name is different from run_path.

MOSAIC Training

This section follows the full training flow in order. Before training, prepare the following motion sources:

  1. Public datasets downloaded from their official sites: AMASS (opens in a new tab) and OMOMO (opens in a new tab).
  2. Built-in MOSAIC datasets (optical MoCap, inertial MoCap, and GENMO (opens in a new tab)-generated motions) downloaded from our open dataset (opens in a new tab).
  3. Adaptor training data (VR and inertial MoCap) downloaded from our open dataset (opens in a new tab).

Training is provided as shell scripts. Run them in order, and make sure to set the motion source paths inside each script before running.

  1. MOSAIC GMT policy training using multi-source dataset
bash run/run_mosaic_gmt.sh

After training, you get the GMT model: gmt_checkpoint.pt

  1. MOSAIC teleoperation adaptor training using adaptor training data
bash run/run_mosaic_adaptor.sh

After training, you get the adaptor model: adaptor_checkpoint.pt

Then update the motion path and model path for GMT and Adaptor in with relative task config:

  • source/whole_body_tracking/whole_body_tracking/tasks/tracking/config/g1/flat_env_cfg.py
  • source/whole_body_tracking/whole_body_tracking/tasks/tracking/config/g1/agents/rsl_rl_mosaic_cfg.py
  1. MOSAIC multi-teacher residual distillation (fast adaptation)
bash run/run_mosaic_residual_adaptation.sh
Code Structure

Below is an overview of the code structure for this repository:

  • source/whole_body_tracking/whole_body_tracking/tasks/tracking/mdp This directory contains the atomic functions to define the MDP for MOSAIC. Below is a breakdown of the functions:

    • commands.py Command library to compute relevant variables from the reference motion, current robot state, and error computations. This includes pose and velocity error calculation, initial state randomization, and adaptive sampling.

    • rewards.py Implements the DeepMimic reward functions and smoothing terms.

    • events.py Implements domain randomization terms.

    • observations.py Implements observation terms for motion tracking and data collection.

    • terminations.py Implements early terminations and timeouts.

  • source/whole_body_tracking/whole_body_tracking/tasks/tracking/tracking_env_cfg.py Contains the environment (MDP) hyperparameters configuration for the tracking task.

  • source/whole_body_tracking/whole_body_tracking/tasks/tracking/config/g1/agents/rsl_rl_ppo_cfg.py Contains the PPO hyperparameters for the tracking task.

  • source/whole_body_tracking/whole_body_tracking/robots Contains robot-specific settings, including armature parameters, joint stiffness/damping calculation, and action scale calculation.

  • scripts Includes utility scripts for preprocessing motion data, training policies, and evaluating trained policies.

This structure is designed to ensure modularity and ease of navigation for developers expanding the project.

Supported Task List

Currently, three robot platform G1/H1_2/Adam are supported. The G1 registry in source/whole_body_tracking/whole_body_tracking/tasks/tracking/config/g1/__init__.py exposes the following Isaac Lab task IDs.

Task IDDescription
Tracking-Flat-G1-v0Single-motion tracking baseline using G1FlatEnvCfg with the standard control frequency and state-estimation inputs.
Tracking-Flat-G1-Wo-State-Estimation-v0Single-motion variant without state-estimation inputs via G1FlatWoStateEstimationEnvCfg.
Tracking-Flat-G1-Low-Freq-v0Single-motion setup that lowers the control frequency (G1FlatLowFreqEnvCfg + G1FlatLowFreqPPORunnerCfg).
General-Tracking-Flat-G1-v0Multi-motion training environment configured by G1FlatGeneralEnvCfg.
General-Tracking-Flat-G1-Wo-State-Estimation-v0Multi-motion variant without state-estimation inputs, based on G1FlatWoStateEstimationGeneralEnvCfg.
General-Tracking-Flat-G1-Low-Freq-v0Multi-motion environment with reduced control frequency using G1FlatLowFreqGeneralEnvCfg and G1FlatLowFreqPPORunnerCfg.
Expert-General-Tracking-Flat-G1-v0Expert multi-motion environment using G1FlatExpertGeneralEnvCfg with the standard PPO runner.
Expert-General-Tracking-Flat-G1-MOSAIC-v0Expert multi-motion environment using G1FlatExpertGeneralEnvCfg with G1FlatMOSAICRunnerCfg.
Distillation-General-Tracking-Flat-G1-v0Distillation environment using G1DistillationTrackingEnvCfg with G1FlatDistillationRunnerCfg.
MOSAIC-Distill-General-Tracking-Flat-G1-v0Distillation environment using G1DistillationTrackingEnvCfg with G1FlatMOSAICHybridRunnerCfg.
MOSAIC-Pure-Distill-General-Tracking-Flat-G1-v0Distillation environment using G1DistillationTrackingEnvCfg with G1FlatMOSAICPureDistillationRunnerCfg.
MOSAIC-RL-Continue-General-Tracking-Flat-G1-v0Distillation environment using G1DistillationTrackingEnvCfg with G1FlatMOSAICRLContinueRunnerCfg.
MOSAIC-Residual-General-Tracking-Flat-G1-v0Distillation environment using G1DistillationTrackingEnvCfg with G1FlatMOSAICRLContinueResidualRunnerCfg.
MOSAIC-MultiTeacher-Residual-Tracking-Flat-G1-v0Multi-teacher distillation environment using G1MultiDistillationTrackingEnvCfg with G1FlatMOSAICMultiTeacherResidualRunnerCfg.
General-Tracking-Flat-G1-Wo-State-Estimation-v0-World-Coordinate-RewardOne-stage tracking variant using G1OneStageTrackingEnvCfg with the standard PPO runner.

To introduce additional tasks, add new gym.register entries in the same file and point them to the corresponding EnvCfg and PPO runner configurations.

Acknowledgements

This project is built on the following open-source projects:

Contact

We are hiring!!! Full-time researchers, engineers, interns and PhD students are all open for recruitment. If you are interested in working with us on whole-body mobile manipulation for humanoid robots, please contact hitsunzhenguo@gmail.com (opens in a new tab).

Read the model card on Hugging Face (opens in a new tab)

Robotheca lists AI models as a reference: nothing is hosted or run here, and every fact links to where it was read.