Safe Imitation Learning of Nonlinear Model Predictive Control for Flexible Robots
Shamil Mamedov, Rudolf Reiter, Seyed Mahdi Basiri Azad, Ruan Viljoen, Joschka Boedecker, Moritz Diehl, Jan Swevers
TL;DR
This work targets real-time, safe control of flexible robots, where nonlinear, high-dimensional dynamics hinder traditional NMPC. It introduces a framework that learns an NMPC policy through imitation learning (DAgger) and enforces safety with a predictive safety filter, achieving substantial speedups over NMPC while maintaining safety. Empirical results show an eightfold reduction in action computation time and superior performance to a strong RL baseline (SAC), with robustness to model-plant mismatch. The approach has practical implications for industrial adoption of flexible robots and suggests directions for extending to trajectory tracking and soft-robot applications.
Abstract
Flexible robots may overcome some of the industry's major challenges, such as enabling intrinsically safe human-robot collaboration and achieving a higher payload-to-mass ratio. However, controlling flexible robots is complicated due to their complex dynamics, which include oscillatory behavior and a high-dimensional state space. Nonlinear model predictive control (NMPC) offers an effective means to control such robots, but its significant computational demand often limits its application in real-time scenarios. To enable fast control of flexible robots, we propose a framework for a safe approximation of NMPC using imitation learning and a predictive safety filter. Our framework significantly reduces computation time while incurring a slight loss in performance. Compared to NMPC, our framework shows more than an eightfold improvement in computation time when controlling a three-dimensional flexible robot arm in simulation, all while guaranteeing safety constraints. Notably, our approach outperforms state-of-the-art reinforcement learning methods. The development of fast and safe approximate NMPC holds the potential to accelerate the adoption of flexible robots in industry. The project code is available at: tinyurl.com/anmpc4fr
