Abstract
Training control policies in simulation is more appealing than on real robots directly, as it allows for exploring diverse states in an efficient manner. Yet, robot simulators inevitably exhibit disparities from the real-world dynamics, yielding inaccuracies that manifest as the dynamical simulation-to-reality (sim-to-real) gap. Existing literature has proposed to close this gap by actively modifying specific simulator parameters to align the simulated data with real-world observations. However, the set of tunable parameters is usually manually selected to reduce the search space in a case-by-case manner, which is hard to scale up for complex systems and requires extensive domain knowledge. To address the scalability issue and automate the parameter-tuning process, we introduce COMPASS, which aligns the simulator with the real world by discovering the causal relationship between the environment parameters and the sim-to-real gap. Concretely, our method learns a differentiable mapping from the environment parameters to the differences between simulated and real-world robot-object trajectories. This mapping is governed by a simultaneously learned causal graph to help prune the search space of parameters, provide better interpretability, and improve generalization on unseen parameters. We perform experiments to achieve both sim-to-sim and sim-to-real transfer, and show that our method has significant improvements in trajectory alignment and task success rate over strong baselines in several challenging manipulation tasks.
Introduction
While simulators offer a safe and efficient environment for training robotic policies, the "sim-to-real gap"—the discrepancy between simulated and real-world dynamics—remains a significant hurdle. Traditional approaches like System Identification (SysID) or Domain Randomization (DR) often rely on manual selection of tunable parameters. This process is labor-intensive, requires deep domain expertise, and fails to scale as simulators become more complex. To overcome these limitations, we propose COMPASS (Causality-between-env-parameters-and-the-Sim-to-real-gap), a framework that automates parameter selection by discovering the causal links between environment parameters and trajectory errors.
Methodology: The COMPASS Framework
COMPASS treats the sim-to-real gap as a differentiable causal discovery problem. The framework consists of three primary components:
- Differentiable Causal Model: The core of COMPASS is a model that maps environment parameters ($\epsilon$) and actions ($a$) to the trajectory difference ($d_\tau$) between simulation and reality. This mapping is constrained by a learned causal graph ($\mathcal{G}$), which identifies which parameters actually influence the gap.
- Causality-Guided Domain Randomization: By leveraging the learned causal graph, COMPASS identifies a sparse subset of relevant parameters. Parameters without a causal link to the trajectory error are excluded, significantly reducing the optimization search space.
- End-to-End Optimization: The entire pipeline is differentiable, allowing for the backpropagation of trajectory errors directly to environment parameters. This enables efficient gradient-based tuning of the simulator.
Experimental Evaluation
We evaluated COMPASS on three complex manipulation tasks: Mini-Air-Hockey with Obstacle (64 parameters), Double-Bouncing-Ball (82 parameters), and Push-I (67 parameters). Real-world validation was performed using a Kinova Gen 3 robot arm.
The strength of COMPASS lies in its ability to handle high-dimensional parameter spaces. In complex systems, most parameters are "distractors." COMPASS automatically discovers a sparse causal graph, focusing only on the influential factors, such as camera bias or specific friction coefficients, providing both efficiency and interpretability.
Key Results
COMPASS demonstrates superior performance in both parameter recovery and task success.
- Parameter Recovery: In sim-to-sim benchmarks, COMPASS recovered ground-truth parameters more accurately than baselines like EXI-Net or NPDR.
- Real-World Success: In the challenging Air Hockey task, policies trained using COMPASS-adjusted simulators achieved an 80% success rate, vastly outperforming the best baseline (39%) and the untuned nominal simulator (0%).
Conclusion and Future Work
COMPASS provides a scalable, interpretable solution for closing the sim-to-real gap. By identifying causal relationships, it automates the tuning of complex simulators. Future work will address potential local minima in gradient-based optimization and explore maintaining parameter distributions rather than point estimates to further enhance robustness.
Summary updated