Learning a Better Control Barrier Function Under Uncertain Dynamics
Bolun Dai, Prashanth Krishnamurthy, Farshad Khorrami
TL;DR
This work addresses safety in control under uncertain dynamics by jointly learning a refined CBF and the true system dynamics starting from a conservative CBF (HCBF) and a nominal model. The authors introduce loss functions that leverage a distance-based prior to avoid trivial CBF solutions, and employ a deep differential network to learn $\Delta h$ along with a dynamics model for $\Delta f$ and $\Delta g$, enabling a CBF-QP safety filter that adapts online to uncertainty. The approach is trained offline via replay buffers and evaluated on a double integrator, a unicycle, and a two-link arm, showing that the learned CBF and dynamics yield safe trajectories even when nominal models are inaccurate. The contributions include (1) a CBF refinement method using a distance prior, (2) extension to uncertain dynamics with joint learning, and (3) empirical validation across multiple safety-critical settings, suggesting substantial potential for robust safety filtering in real-world robotic systems.
Abstract
Using control barrier functions (CBFs) as safety filters provides a computationally inexpensive yet effective method for constructing controllers in safety-critical applications. However, using CBFs requires the construction of a valid CBF, which is well known to be a challenging task, and accurate system dynamics, which are often unavailable. This paper presents a learning-based approach to learn a valid CBF and the system dynamics starting from a conservative handcrafted CBF (HCBF) and the nominal system dynamics. We devise new loss functions that better suit the CBF refinement pipeline and are able to produce well-behaved CBFs with the usage of distance functions. By adopting an episodic learning approach, our proposed method is able to learn the system dynamics while not requiring additional interactions with the environment. Additionally, we provide a theoretical analysis of the quality of the learned system dynamics. We show that our proposed learning approach can effectively learn a valid CBF and an estimation of the actual system dynamics. The effectiveness of our proposed method is empirically demonstrated through simulation studies on three systems, a double integrator, a unicycle, and a two-link arm.
