Learning Safety Constraints from Demonstrations with Unknown Rewards

David Lindner, Xin Chen, Sebastian Tschiatschek, Katja Hofmann, Andreas Krause
5/25/2023
cs.LGcs.AIstat.ML

No official code found. Best implementation: lasgroup/cocorl (7 stars, last commit 2024-02-28).

Abstract

We propose Convex Constraint Learning for Reinforcement Learning (CoCoRL), a novel approach for inferring shared constraints in a Constrained Markov Decision Process (CMDP) from a set of safe demonstrations with possibly different reward functions. While previous work is limited to demonstrations with known rewards or fully known environment dynamics, CoCoRL can learn constraints from demonstrations with different unknown rewards without knowledge of the environment dynamics. CoCoRL constructs a convex safe set based on demonstrations, which provably guarantees safety even for potentially sub-optimal (but safe) demonstrations. For near-optimal demonstrations, CoCoRL converges to the true safe set with no policy regret. We evaluate CoCoRL in gridworld environments and a driving simulation with multiple constraints. CoCoRL learns constraints that lead to safe driving behavior. Importantly, we can safely transfer the learned constraints to different tasks and environments. In contrast, alternative methods based on Inverse Reinforcement Learning (IRL) often exhibit poor performance and learn unsafe policies.

View on arXivView PDF

Code Implementations(1)

lasgroup/cocorlCommunity100%

Code for Convex Constraint Learning for RL

71PythonFeb 28, 20242 years ago

Similar Papers

Cite this paper

@article{lindner2023learning,
  title  = {Learning Safety Constraints from Demonstrations with Unknown Rewards},
  author = {David Lindner and Xin Chen and Sebastian Tschiatschek and Katja Hofmann and Andreas Krause},
  year   = {2023},
  eprint = {2305.16147},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2305.16147v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2305.16147.svg)](https://codeofpaper.com/paper/2305.16147)

Discussion