English

Statically Bounded-Memory Delayed Sampling for Probabilistic Streams

Programming Languages 2021-12-15 v5

Abstract

Probabilistic programming languages aid developers performing Bayesian inference. These languages provide programming constructs and tools for probabilistic modeling and automated inference. Prior work introduced a probabilistic programming language, ProbZelus, to extend probabilistic programming functionality to unbounded streams of data. This work demonstrated that the delayed sampling inference algorithm could be extended to work in a streaming context. ProbZelus showed that while delayed sampling could be effectively deployed on some programs, depending on the probabilistic model under consideration, delayed sampling is not guaranteed to use a bounded amount of memory over the course of the execution of the program. In this paper, we present conditions on a probabilistic program's execution under which delayed sampling will execute in bounded memory. The two conditions are dataflow properties of the core operations of delayed sampling: the mm-consumed property and the unseparated paths property. A program executes in bounded memory under delayed sampling if, and only if, it satisfies the mm-consumed and unseparated paths properties. We propose a static analysis that abstracts over these properties to soundly ensure that any program that passes the analysis satisfies these properties, and thus executes in bounded memory under delayed sampling.

Keywords

Cite

@article{arxiv.2109.12473,
  title  = {Statically Bounded-Memory Delayed Sampling for Probabilistic Streams},
  author = {Eric Atkinson and Guillaume Baudart and Louis Mandel and Charles Yuan and Michael Carbin},
  journal= {arXiv preprint arXiv:2109.12473},
  year   = {2021}
}

Comments

The following is a summary of the changes in each revision. [v2] corrected the URL for the code repository. [v3] corrected the definition of the m-consumed semantic property. [v4] fixed a typo. [v5] added this comment