Analysis of Randomization Effects on Sim2Real Transfer in Reinforcement Learning for Robotic Manipulation Tasks

Josip Josifovski, Mohammadhossein Malmir, Noah Klarmann, Bare Luka Zagar, Nicolás Navarro-Guerrero, Alois C. Knoll

Introduction

The transition of Reinforcement Learning (RL) policies from simulated environments to physical robotic hardware—commonly referred to as "Sim2Real" transfer—remains one of the most significant challenges in robotics. While simulators provide a safe and fast environment for training, they are inherently "idealized" versions of reality. Discrepancies in physics, such as sensor noise, mechanical latency, and torque variations, create a "reality gap" that often causes policies optimized in simulation to fail when deployed on physical robots.

Presented at the 2022 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), this research provides a systematic benchmarking of domain randomization strategies. By intentionally introducing variability during training, researchers aim to build policies robust enough to bridge the reality gap. This paper evaluates five distinct training strategies to determine the most effective method for achieving stable real-world performance.

The Reach-and-Balance Benchmark

To evaluate these strategies, the authors developed a "reach-and-balance" task using a KUKA LBR iiwa 14 robot. Unlike standard reaching tasks, which often terminate upon contact with a target, the reach-and-balance task requires the robot to reach a specific coordinate and maintain a steady position. This requirement for sustained stability makes the task particularly sensitive to jitter, oscillations, and control instabilities—factors that are frequently exacerbated by the reality gap.

The simulation environment was built using Unity, providing an OpenAI Gym-compatible API. The physical implementation utilized ROS (Robot Operating System) to control the KUKA arm, ensuring a direct comparison between simulated and real-world execution.

Training Strategies and Randomization Parameters

The study focused on three primary randomization parameters:

  1. Latency (L): Delays in the control loop.
  2. Torque (T): Variations in motor output and friction.
  3. Noise (N): Stochasticity in sensor readings.

Five training strategies were benchmarked using the Proximal Policy Optimization (PPO) algorithm:

  • Ideal Simulation: Training exclusively in a perfect physics environment.
  • Randomized Simulation: Training from scratch with L, T, and N parameters randomized simultaneously.
  • Fine-tuning: Starting with a policy trained in an "ideal" environment, then sequentially training on individual randomized parameters.
  • Curriculum Learning: Starting with an "ideal" environment and gradually increasing the range of randomized parameters.
  • ideal2randomized: Starting with an "ideal" model and then switching to a fully randomized environment for the remainder of training.

Key Insights: The Simulation-Reality Paradox

The experimental results revealed a striking "Simulation-Reality Paradox." Policies that achieved the highest rewards in the "Ideal" simulation performed the worst in the real world. For instance, the "Ideal" model frequently hit safety limits in physical tests (46% of the time), leading to episode termination due to erratic movements.

Conversely, the "Randomized" model, which showed the lowest performance metrics during training due to the difficulty of the randomized environment, proved to be the most robust in reality. It achieved a mean real-world reward of -109.10, significantly outperforming the "Ideal" model's reward of -142.50.

The Efficacy of Sequential Fine-Tuning

While training with full randomization from scratch produces robust agents, it is often computationally expensive and can suffer from slow convergence. The researchers found that sequential fine-tuning represents a superior "sweet spot."

By training an agent in an ideal environment first and then introducing randomized parameters one by one (specifically in the order of Torque -> Latency -> Noise), the researchers achieved a real-world reward of -113.82. This performance nearly matches the fully randomized model but with significantly higher training stability. Furthermore, fine-tuned models were remarkably safe, hitting safety limits only 4.33% of the time compared to the 46% failure rate of the ideal-only models.

Conclusion

This research demonstrates that domain randomization is essential for Sim2Real transfer, but the method of applying that randomization matters. While heavy randomization builds the most robust policies, it can impede the initial learning process. Sequential fine-tuning offers a balanced alternative, allowing the agent to learn the core task in an ideal environment before adapting to the complexities of physical reality.

Future work will involve extending these findings to more complex manipulation tasks involving multi-contact physics, such as grasping and object manipulation, as well as exploring the impact of visual domain randomization.

Summary updated

BibTeX
@inproceedings{josifovski2022analysis,
  author = {Josip Josifovski and Mohammadhossein Malmir and Noah Klarmann and Bare Luka Zagar and Nicolás Navarro-Guerrero and Alois C. Knoll},
  title = {{Analysis of Randomization Effects on Sim2Real Transfer in Reinforcement Learning for Robotic Manipulation Tasks}},
  booktitle = {IEEE/RSJ International Conference on Intelligent Robots and Systems},
  year = {2022},
  doi = {10.1109/iros47612.2022.9981951},
}
Figure