Measure Transformer Semantics for Bayesian Machine Learning
arXiv:1308.0689 · doi:10.2168/LMCS-9(3:11)2013
Abstract
The Bayesian approach to machine learning amounts to computing posterior distributions of random variables from a probabilistic model of how the variables are related (that is, a prior distribution) and a set of observations of variables. There is a trend in machine learning towards expressing Bayesian models as probabilistic programs. As a foundation for this kind of programming, we propose a core functional calculus with primitives for sampling prior distributions and observing variables. We define measure-transformer combinators inspired by theorems in measure theory, and use these to give a rigorous semantics to our core calculus. The original features of our semantics include its support for discrete, continuous, and hybrid measures, and, in particular, for observations of zero-probability events. We compile our core language to a small imperative language that is processed by an existing inference engine for factor graphs, which are data structures that enable many efficient inference algorithms. This allows efficient approximate inference of posterior marginal distributions, treating thousands of observations per second for large instances of realistic models.
An abridged version of this paper appears in the proceedings of the 20th European Symposium on Programming (ESOP'11), part of ETAPS 2011
References in corpus (3)
Cited by in corpus (8)
- Semantics for probabilistic programming: higher-order functions, continuous distributions, and soft constraints
- Disintegration and Bayesian Inversion via String Diagrams
- The Base Measure Problem and its Solution
- A Linear Exponential Comonad in s-finite Transition Kernels and Probabilistic Coherent Spaces
- Symbolic Semantics for Probabilistic Programs (extended version)
- Analyzing Expected Outcomes and Almost-Sure Termination of Probabilistic Programs is Hard
- On the Hardness of Almost-Sure Termination
- Applied Measure Theory for Probabilistic Modeling