MoE-Loco: Mixture of Experts for Multitask Locomotion

Runhan Huang, Shaoting Zhu, Yilun Du, Hang Zhao

TL;DR

MoE-Loco introduces a Mixture of Experts (MoE) framework that enables a single reinforcement learning policy to master multiple locomotion modes (both quadrupedal and bipedal) across diverse, challenging terrains. By dynamically routing tasks to specialized sub-networks, the method successfully mitigates the destructive gradient conflicts typical of multitask learning, enabling seamless real-world deployment on a physical robot.

What Problem Does This Paper Address?

While reinforcement learning (RL) has achieved remarkable success in training legged robots for specific locomotion tasks, creating a single, unified policy that generalizes across highly diverse terrains and distinct gaits remains a major hurdle.

When a standard neural network tries to learn fundamentally different skills simultaneously—such as crawling under a low baffle on four legs versus walking up a steep slope on two legs—it encounters gradient conflicts. The optimization gradients calculated for one task often counteract or overwrite the progress made on another, leading to poor overall performance, training inefficiency, or complete model divergence. MoE-Loco tackles this bottleneck to achieve true multitask locomotion without sacrificing performance.

Overview of MoE-Loco traversing diverse terrains with a single policy

Methods

The core innovation of MoE-Loco is the integration of a Mixture of Experts (MoE) architecture into a two-stage Deep RL training pipeline (based on Proximal Policy Optimization, or PPO).

Instead of using a massive, monolithic Multi-Layer Perceptron (MLP), MoE-Loco splits the policy's capacity across multiple parallel "expert" networks. A learned gating network evaluates the current robot state and history to output a routing score, dynamically weighting the contributions of each expert for the given scenario.

Key components of the architecture include:

  • Shared Gating Network: Both the actor (action generation) and critic (value evaluation) networks utilize MoE structures and share the exact same gating network to ensure consistency between policy evaluation and execution.
  • Two-Stage Training: In the first stage, an "Oracle" policy is trained using both proprioceptive data and privileged simulation information (e.g., ground friction, exact linear velocity). In the second stage, the policy is distilled to run entirely on blind locomotion (proprioception only) using an estimator network and Probability Annealing Selection (PAS) to bridge the sim-to-real gap.
The MoE-Loco pipeline architecture

Datasets

The authors evaluated their approach by constructing a rigorous multitask simulation benchmark within IsaacGym, simulating 4,096 robots concurrently.

The benchmark features a $5\text{m} \times 100\text{m}$ runway containing an even distribution of challenging obstacles. The tasks span 9 distinct combinations of terrains and gaits:

  • Quadrupedal mode: Bar crossing, pit crossing, baffle crawling, stair climbing, and slope walking.
  • Bipedal mode: Standing up, flat-plane walking, slope walking, and stair descending.

Key Insights and Ideas

  • Automatic Specialization: The experts naturally partition the task space without explicit manual assignment. For instance, one expert might specialize in body balancing, while another focuses on lifting the front legs for obstacle clearance.
  • Gradient Conflict Alleviation: By calculating the cosine similarity and negative gradient ratios between different tasks, the authors proved mathematically that the MoE structure prevents tasks from fighting each other during backpropagation.
  • Zero-Shot Skill Composition: Because the experts learn interpretable, distinct physical behaviors, researchers can manually alter or freeze the gating weights post-training to synthesize entirely new gaits. For example, by combining a balancing expert with a leg-lifting expert, they generated a novel "dribbling" gait to kick a ball without any additional training.

Key Results

MoE-Loco was validated both in simulation and via zero-shot transfer to a physical Unitree Go2 quadruped robot.

  • Simulation Superiority: In the mixed-task benchmark, MoE-Loco achieved a 87.9% success rate, vastly outperforming a standard MLP baseline with the same parameter count (57.1% success) and Rapid Motor Adaptation (RMA) which failed completely on the mixed track (0% success).
  • Efficiency: MoE-Loco demonstrated significantly higher mean rewards and longer episode lengths during the pretraining phase compared to standard architectures.
  • Real-World Robustness: Deployed in the real world, the robot successfully navigated a continuous "mix terrain" track—crossing bars, crawling under baffles, tackling stairs, and smoothly transitioning into a bipedal stance to walk up and down slopes.

Real-world success rates across different terrains Snapshots of the real-world deployment on various terrains

Limitations and Future Work

The primary limitation of the current MoE-Loco framework is its reliance on blind locomotion. Because the robot only uses proprioceptive feedback (joint positions, IMU data), it cannot anticipate upcoming obstacles and must react purely on impact.

The authors note that future work will focus on integrating exteroceptive sensory data—such as onboard cameras and LiDAR—into the MoE framework to allow the gating network to proactively route tasks based on visual perception.

Summary updated

BibTeX
@inproceedings{huang2025moe,
  author = {Runhan Huang and Shaoting Zhu and Yilun Du and Hang Zhao},
  title = {{MoE-Loco: Mixture of Experts for Multitask Locomotion}},
  booktitle = {IEEE/RSJ International Conference on Intelligent Robots and Systems},
  year = {2025},
  doi = {10.1109/iros60139.2025.11246585},
}
Figure