RADIUM: Predicting and Repairing End-to-End Robot Failures using Gradient-Accelerated Sampling (2404.03412v1)
Abstract: Before autonomous systems can be deployed in safety-critical applications, we must be able to understand and verify the safety of these systems. For cases where the risk or cost of real-world testing is prohibitive, we propose a simulation-based framework for a) predicting ways in which an autonomous system is likely to fail and b) automatically adjusting the system's design and control policy to preemptively mitigate those failures. Existing tools for failure prediction struggle to search over high-dimensional environmental parameters, cannot efficiently handle end-to-end testing for systems with vision in the loop, and provide little guidance on how to mitigate failures once they are discovered. We approach this problem through the lens of approximate Bayesian inference and use differentiable simulation and rendering for efficient failure case prediction and repair. For cases where a differentiable simulator is not available, we provide a gradient-free version of our algorithm, and we include a theoretical and empirical evaluation of the trade-offs between gradient-based and gradient-free methods. We apply our approach on a range of robotics and control problems, including optimizing search patterns for robot swarms, UAV formation control, and robust network control. Compared to optimization-based falsification methods, our method predicts a more diverse, representative set of failure modes, and we find that our use of differentiable simulation yields solutions that have up to 10x lower cost and requires up to 2x fewer iterations to converge relative to gradient-free techniques. In hardware experiments, we find that repairing control policies using our method leads to a 5x robustness improvement. Accompanying code and video can be found at https://mit-realm.github.io/radium/
- A. Madry, A. Makelov, L. Schmidt, D. Tsipras, and A. Vladu, “Towards Deep Learning Models Resistant to Adversarial Attacks,” in International Conference on Learning Representations, Feb. 2018.
- H. Salman, A. Ilyas, L. Engstrom, S. Vemprala, A. Madry, and A. Kapoor, “Unadversarial Examples: Designing Objects for Robust Vision,” in Advances in Neural Information Processing Systems, vol. 34. Curran Associates, Inc., 2021, pp. 15 270–15 284.
- N. Hanselmann, K. Renz, K. Chitta, A. Bhattacharyya, and A. Geiger, “KING: Generating Safety-Critical Driving Scenarios for Robust Imitation via Kinematics Gradients,” in Computer Vision – ECCV 2022: 17th European Conference, Tel Aviv, Israel, October 23–27, 2022, Proceedings, Part XXXVIII. Berlin, Heidelberg: Springer-Verlag, Oct. 2022, pp. 335–352.
- W. Ding, B. Chen, M. Xu, and D. Zhao, “Learning to Collide: An Adaptive Safety-Critical Scenarios Generating Method,” in 2020 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), Oct. 2020, pp. 2243–2250.
- A. Corso, P. Du, K. Driggs-Campbell, and M. J. Kochenderfer, “Adaptive Stress Testing with Reward Augmentation for Autonomous Vehicle Validatio,” in 2019 IEEE Intelligent Transportation Systems Conference (ITSC), Oct. 2019, pp. 163–168.
- J. Wang, A. Pun, J. Tu, S. Manivasagam, A. Sadat, S. Casas, M. Ren, and R. Urtasun, “AdvSim: Generating Safety-Critical Scenarios for Self-Driving Vehicles,” in Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, 2021, pp. 9909–9918.
- A. Sinha, M. O’Kelly, R. Tedrake, and J. Duchi, “Neural bridge sampling for evaluating safety-critical autonomous systems,” in Proceedings of the 34th International Conference on Neural Information Processing Systems, ser. NIPS’20. Red Hook, NY, USA: Curran Associates Inc., Dec. 2020, pp. 6402–6416.
- H. Delecki, A. Corso, and M. Kochenderfer, “Model-based Validation as Probabilistic Inference,” in Proceedings of The 5th Annual Learning for Dynamics and Control Conference. PMLR, Jun. 2023, pp. 825–837.
- Y. Zhou, S. Booth, N. Figueroa, and J. Shah, “RoCUS: Robot Controller Understanding via Sampling,” in 5th Annual Conference on Robot Learning, Nov. 2021.
- M. O’ Kelly, A. Sinha, H. Namkoong, R. Tedrake, and J. C. Duchi, “Scalable End-to-End Autonomous Vehicle Testing via Rare-event Simulation,” in Advances in Neural Information Processing Systems, vol. 31. Curran Associates, Inc., 2018.
- M. Betancourt, “A Conceptual Introduction to Hamiltonian Monte Carlo,” Jan. 2017.
- C. Dawson and C. Fan, “A Bayesian approach to breaking things: Efficiently predicting and repairing failure modes via sampling,” in 7th Annual Conference on Robot Learning, Aug. 2023.
- J. de Kleer and B. C. Williams, “Diagnosing multiple faults,” Artificial Intelligence, vol. 32, no. 1, pp. 97–130, Apr. 1987.
- D. Benard, G. A. Dorais, E. Gamble, B. Kanefsky, J. Kurien, W. Millar, N. Muscettola, P. Nayak, N. Rouquette, K. Rajan, and P. Norvig, “Remote Agent Experiment,” Jan. 2000.
- Y. Annpureddy, C. Liu, G. Fainekos, and S. Sankaranarayanan, “S-TaLiRo: A tool for temporal logic falsification for hybrid systems,” Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics), vol. 6605 LNCS, pp. 254–257, 2011.
- G. Chou, Y. E. Sahin, L. Yang, K. J. Rutledge, P. Nilsson, and N. Ozay, “Using control synthesis to generate corner cases: A case study on autonomous driving,” IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, vol. 37, no. 11, pp. 2906–2917, Nov. 2018.
- C. Dawson and C. Fan, “Robust Counterexample-guided Optimization for Planning from Differentiable Temporal Logic,” in 2022 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), Oct. 2022, pp. 7205–7212.
- B. Amos and J. Z. Kolter, “OptNet: Differentiable optimization as a layer in neural networks,” in Proceedings of the 34th International Conference on Machine Learning - Volume 70, ser. ICML’17. Sydney, NSW, Australia: JMLR.org, Aug. 2017, pp. 136–145.
- F. de Avila Belbute-Peres, K. Smith, K. Allen, J. Tenenbaum, and J. Z. Kolter, “End-to-end differentiable physics for learning and control,” in Advances in Neural Information Processing Systems, S. Bengio, H. Wallach, H. Larochelle, K. Grauman, N. Cesa-Bianchi, and R. Garnett, Eds., vol. 31. Curran Associates, Inc., 2018.
- W. Jakob, S. Speierer, N. Roussel, and D. Vicini, “DR.JIT: A just-in-time compiler for differentiable rendering,” ACM Transactions on Graphics, vol. 41, no. 4, pp. 124:1–124:19, Jul. 2022.
- L. Jain, V. Chandrasekaran, U. Jang, W. Wu, A. Lee, A. Yan, S. Chen, S. Jha, and S. A. Seshia, “Analyzing and Improving Neural Networks by Generating Semantic Counterexamples through Differentiable Rendering,” Jul. 2020.
- Y. Hu, L. Anderson, T.-M. Li, Q. Sun, N. Carr, J. Ragan-Kelley, and F. Durand, “DiffTaichi: Differentiable Programming for Physical Simulation,” in International Conference on Learning Representations, Dec. 2019.
- Z. Zhong, D. Rempe, D. Xu, Y. Chen, S. Veer, T. Che, B. Ray, and M. Pavone, “Guided Conditional Diffusion for Controllable Traffic Simulation,” Oct. 2022.
- C. Dawson and C. Fan, “Certifiable Robot Design Optimization using Differentiable Programming,” in Robotics: Science and Systems XVIII, vol. 18, Jun. 2022.
- P. Donti, A. Agarwal, N. V. Bedmutha, L. Pileggi, and J. Z. Kolter, “Adversarially robust learning for security-constrained optimal power flow,” in Advances in Neural Information Processing Systems, vol. 34. Curran Associates, Inc., 2021, pp. 28 677–28 689.
- S. Yaghoubi and G. Fainekos, “Gray-box Adversarial Testing for Control Systems with Machine Learning Component,” HSCC 2019 - Proceedings of the 2019 22nd ACM International Conference on Hybrid Systems: Computation and Control, pp. 179–184, Dec. 2018.
- A. Corso, R. Moss, M. Koren, R. Lee, and M. Kochenderfer, “A Survey of Algorithms for Black-Box Safety Validation of Cyber-Physical Systems,” Journal of Artificial Intelligence Research, vol. 72, pp. 377–428, Oct. 2021.
- C. Xu, W. Ding, W. Lyu, Z. Liu, S. Wang, Y. He, H. Hu, D. Zhao, and B. Li, “SafeBench: A Benchmarking Platform for Safety Evaluation of Autonomous Vehicles,” Advances in Neural Information Processing Systems, vol. 35, pp. 25 667–25 682, Dec. 2022.
- S. Riedmaier, T. Ponn, D. Ludwig, B. Schick, and F. Diermeyer, “Survey on Scenario-Based Safety Assessment of Automated Vehicles,” IEEE Access, vol. 8, pp. 87 456–87 477, 2020.
- H. Sun, S. Feng, X. Yan, and H. X. Liu, “Corner Case Generation and Analysis for Safety Assessment of Autonomous Vehicles,” Transportation Research Record, vol. 2675, no. 11, pp. 587–600, Nov. 2021.
- A. Corso and M. J. Kochenderfer, “Interpretable Safety Validation for Autonomous Vehicles,” in 2020 IEEE 23rd International Conference on Intelligent Transportation Systems (ITSC), Sep. 2020, pp. 1–6.
- Q. Zhang, S. Hu, J. Sun, Q. A. Chen, and Z. M. Mao, “On Adversarial Robustness of Trajectory Prediction for Autonomous Vehicles,” in Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, 2022, pp. 15 159–15 168.
- Y. A. Ma, Y. Chen, C. Jin, N. Flammarion, and M. I. Jordan, “Sampling can be faster than optimization,” Proceedings of the National Academy of Sciences of the United States of America, vol. 116, no. 42, pp. 20 881–20 885, Oct. 2019.
- Y. Song, J. Sohl-Dickstein, D. P. Kingma, A. Kumar, S. Ermon, and B. Poole, “Score-Based Generative Modeling through Stochastic Differential Equations,” in International Conference on Learning Representations, Jan. 2023.
- G. Rubino and B. Tuffin, “Introduction to Rare Event Simulation,” in Rare Event Simulation Using Monte Carlo Methods. John Wiley & Sons, Ltd, 2009, ch. 1, pp. 1–13.
- W. K. Hastings, “Monte Carlo sampling methods using Markov chains and their applications,” Biometrika, vol. 57, no. 1, pp. 97–109, Apr. 1970.
- R. M. Neal, “MCMC Using Hamiltonian Dynamics,” in Handbook of Markov Chain Monte Carlo. Chapman and Hall/CRC, 2011.
- J. Bresag, “Comments on U. Grenadier, M. Miller, ”Representations of Knowledge in Complex Systems”,” Journal of the Royal Statistical Society. Series B (Methodological), vol. 56, no. 4, pp. 549–603, 1994.
- Q. Liu and D. Wang, “Stein Variational Gradient Descent: A General Purpose Bayesian Inference Algorithm,” in Advances in Neural Information Processing Systems, vol. 29. Curran Associates, Inc., 2016.
- Q. Le Lidec, I. Laptev, C. Schmid, and J. Carpentier, “Differentiable rendering with perturbed optimizers,” in Advances in Neural Information Processing Systems, vol. 34. Curran Associates, Inc., 2021, pp. 20 398–20 409.
- P. Kidger, “On Neural Differential Equations,” Feb. 2022.
- Y. Hu, J. Liu, A. Spielberg, J. B. Tenenbaum, W. T. Freeman, J. Wu, D. Rus, and W. Matusik, “Chainqueen: A real-time differentiable physical simulator for soft robotics,” Proceedings of IEEE International Conference on Robotics and Automation (ICRA), 2019.
- J. H. Lee, M. Y. Michelis, R. Katzschmann, and Z. Manchester, “Aquarium: A fully differentiable fluid-structure interaction solver for robotics applications,” in 2023 IEEE International Conference on Robotics and Automation (ICRA), 2023, pp. 11 272–11 279.
- S. Zhao, W. Jakob, and T.-M. Li, “Physics-based differentiable rendering: From theory to implementation,” in ACM SIGGRAPH 2020 Courses, ser. SIGGRAPH ’20. New York, NY, USA: Association for Computing Machinery, Aug. 2020, pp. 1–30.
- W. Jakob, S. Speierer, N. Roussel, M. Nimier-David, D. Vicini, T. Zeltner, B. Nicolet, M. Crespo, V. Leroy, and Z. Zhang, “Mitsuba 3 renderer,” 2022, https://mitsuba-renderer.org.
- H. J. Suh, M. Simchowitz, K. Zhang, and R. Tedrake, “Do Differentiable Simulators Give Better Policy Gradients?” in Proceedings of the 39th International Conference on Machine Learning. PMLR, Jun. 2022, pp. 20 668–20 696.
- J. Schulman, F. Wolski, P. Dhariwal, A. Radford, and O. Klimov, “Proximal Policy Optimization Algorithms,” Aug. 2017.
- A. Dosovitskiy, G. Ros, F. Codevilla, A. Lopez, and V. Koltun, “CARLA: An open urban driving simulator,” in Proceedings of the 1st Annual Conference on Robot Learning, 2017, pp. 1–16.
- S. Wilson, P. Glotfelter, L. Wang, S. Mayya, G. Notomista, M. Mote, and M. Egerstedt, “The Robotarium: Globally Impactful Opportunities, Challenges, and Lessons Learned in Remote-Access, Distributed Control of Multirobot Systems,” IEEE Control Systems Magazine, vol. 40, no. 1, pp. 26–44, Feb. 2020.