Probabilistic Safety Programs

Ashish Kapoor, Debadeepta Dey, Shital ShaharXiv 2016

Introduction

Autonomous systems, such as drones and self-driving cars, operate in environments defined by uncertainty. Sensor noise and unpredictable environmental dynamics mean that "safety" is rarely a binary state; it is a probability. To ensure a system remains safe, it must reason about this uncertainty in real-time. However, traditional formal methods like Probabilistic Signal Temporal Logic (PrSTL) and sampling-based probabilistic programming (e.g., MCMC) are often too computationally intensive for high-speed applications.

This paper introduces Probabilistic Safety Programs (PSP), a framework designed to bridge the gap between rigorous probabilistic safety reasoning and real-time execution. By imposing specific syntactic constraints on probabilistic programs, the authors enable the compilation of safety checks into graphical models solvable via fast variational inference.

Methodology

PSPs are C-like programs used to define safety invariants, such as maintaining a minimum distance from obstacles. To achieve the performance required for control frequencies exceeding 300 Hz, the framework restricts program syntax in three key ways:

  1. Fixed Iteration Loops: while loops are replaced by for loops with predetermined iteration counts.
  2. Deterministic Control Flow: if-then-else statements are disallowed to ensure a static sequence of evaluations.
  3. Standard Distributions: Probabilistic assignments are limited to exponential family distributions (e.g., Gaussian).

These constraints allow a PSP to be statically unrolled and compiled into a Directed Acyclic Graph (DAG). Instead of relying on slow stochastic sampling, the system employs Variational Inference. This technique approximates complex posterior distributions with simpler ones, transforming a difficult integration problem into a rapid optimization task.

Evaluation and Results

The framework was evaluated across several dynamic simulations, including obstacle avoidance for quadrotors, battery management, and autonomous vehicle maneuvering. A key test involved the "Las Vegas Motor Speedway" challenge, where a PSP was embedded within an RRT* planner to navigate a drone through a course with unknown obstacles.

Computational Efficiency

The primary advantage of the PSP approach is its extreme speed. As shown in Figure 1, the variational inference method maintains near-constant, sub-millisecond inference times even as trajectory lengths increase, significantly outperforming MCMC sampling methods across multiple scenarios.

Inference time comparison across three examples, showing the speed of the PSP approach versus MCMC sampling.

Safety and Accuracy

A critical insight of the paper is that variational inference naturally provides a "lower bound" on the probability of safety. This makes the approximation inherently conservative—if the system deems a path safe, the true probability of safety is likely higher. Evaluation across the three examples (Figure 2) shows that the proportion of false negatives remains below 4%, ensuring high reliability without the risk of false positives (labeling an unsafe path as safe).

Proportion of false negatives across three examples, demonstrating the high accuracy and conservative nature of the PSP framework.

Conclusion and Future Work

Probabilistic Safety Programs offer a path toward real-time, uncertainty-aware autonomy. By trading off some expressiveness for computational speed, PSPs enable safety reasoning at frequencies suitable for high-speed robotics. Future research will focus on deploying PSPs on physical hardware, integrating them more deeply with high-level deliberative planners, and exploring extensions to the restricted syntax to handle more complex logical negations.

Summary updated

BibTeX
@misc{kapoor2016probabilistic,
  author = {Ashish Kapoor and Debadeepta Dey and Shital Shah},
  title = {{Probabilistic Safety Programs}},
  year = {2016},
  eprint = {1610.05376},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1610.05376},
}
Figure