ADEV: Sound Automatic Differentiation of Expected Values of Probabilistic Programs
Alexander K. Lew, Mathieu Huot, Sam Staton, Vikash K. Mansinghka
摘要
Optimizing the expected values of probabilistic processes is a central problem in computer science and its applications, arising in fields ranging from artificial intelligence to operations research to statistical computing. Unfortunately, automatic differentiation techniques developed for deterministic programs do not in general compute the correct gradients needed for widely used solutions based on gradient-based optimization.
In this paper, we present ADEV, an extension to forward-mode AD that correctly differentiates the expectations of probabilistic processes represented as programs that make random choices. Our algorithm is a source-to-source program transformation on an expressive, higher-order language for probabilistic computation, with both discrete and continuous probability distributions. The result of our transformation is a new probabilistic program, whose expected return value is the derivative of the original program's expectation. This output program can be run to generate unbiased Monte Carlo estimates of the desired gradient, which can then be used within the inner loop of stochastic gradient descent. We prove ADEV correct using logical relations over the denotations of the source and target probabilistic programs. Because it modularly extends forward-mode AD, our algorithm lends itself to a concise implementation strategy, which we exploit to develop a prototype in just a few dozen lines of Haskell (https://github.com/probcomp/adev).
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 9 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- Probabilistic Programming with Programmable Variational Inference 引用了 Automatic Differentiation of Programs with Discrete Randomness
- Probabilistic Programming with Programmable Variational Inference 引用了 Trace types and denotational semantics for sound programmable inference in probabilistic languages
- Probabilistic Programming with Programmable Variational Inference 引用了 Probabilistic Programming with Stochastic Probabilities
- ωPAP Spaces: Reasoning Denotationally About Higher-Order, Recursive Probabilistic and Differentiable Programs 引用了 Automatic differentiation in PCF
- ωPAP Spaces: Reasoning Denotationally About Higher-Order, Recursive Probabilistic and Differentiable Programs 引用了 Trace types and denotational semantics for sound programmable inference in probabilistic languages
- ωPAP Spaces: Reasoning Denotationally About Higher-Order, Recursive Probabilistic and Differentiable Programs 引用了 On Correctness of Automatic Differentiation for Non-Differentiable Functions
- Automatic differentiation in PCF 引用了 A simple differentiable programming language
- Automatic differentiation in PCF 引用了 On Correctness of Automatic Differentiation for Non-Differentiable Functions
- On Correctness of Automatic Differentiation for Non-Differentiable Functions 引用了 A simple differentiable programming language
- Probabilistic Programming with Stochastic Probabilities 引用了 Trace types and denotational semantics for sound programmable inference in probabilistic languages
引用它的顶会 Paper9
- Automatic Differentiation of Programs with Discrete RandomnessGaurav Arya, Moritz Schauer, Frank Schäfer, Christopher RackauckasNeurIPS 2022 · 56 次引用
- Probabilistic Programming with Stochastic ProbabilitiesAlexander K. Lew, Matin Ghavamizadeh, Martin C. Rinard, Vikash K. MansinghkaPLDI 2023 · 9 次引用
- Probabilistic Programming with Programmable Variational InferenceMcCoy R. Becker, Alexander K. Lew, Xiaoyan Wang, Matin Ghavami 等PLDI 2024 · 8 次引用
- Automated Efficient Estimation using Monte Carlo Efficient Influence FunctionsRaj Agrawal, Sam Witty, Andy Zane, Elias BinghamNeurIPS 2024 · 6 次引用
- ωPAP Spaces: Reasoning Denotationally About Higher-Order, Recursive Probabilistic and Differentiable ProgramsMathieu Huot, Alexander K. Lew, Vikash K. Mansinghka, Sam StatonLICS 2023 · 5 次引用
它引用的 Paper13
- Automatic Differentiation of Programs with Discrete RandomnessGaurav Arya, Moritz Schauer, Frank Schäfer, Christopher RackauckasNeurIPS 2022 · 56 次引用
- On Correctness of Automatic Differentiation for Non-Differentiable FunctionsWonyeol Lee, Hangyeol Yu, Xavier Rival, Hongseok YangNeurIPS 2020 · 50 次引用
- A simple differentiable programming languageMartín Abadi, Gordon D. PlotkinPOPL 2020 · 49 次引用
- Automatic differentiation in PCFDamiano Mazza, Michele PaganiPOPL 2021 · 47 次引用
- Trace types and denotational semantics for sound programmable inference in probabilistic languagesAlexander K. Lew, Marco F. Cusumano-Towner, Benjamin Sherman, Michael Carbin 等POPL 2020 · 30 次引用
相关 Paper
- GradInf: Gradient Estimation as Probabilistic InferenceGaurav Arya, Mathieu Huot, Moritz Schauer, Alexander K. Lew 等PLDI 2026
- Storchastic: A Framework for General Stochastic Automatic DifferentiationEmile van Krieken, Jakub M. Tomczak, Annette ten TeijeNeurIPS 2021 · 19 次引用
- Provably correct, asymptotically efficient, higher-order reverse-mode automatic differentiationFaustyna Krawiec, Simon Peyton Jones, Neel Krishnaswami, Tom Ellis 等POPL 2022 · 27 次引用
- Universal Semantics for the Stochastic λ-CalculusPedro H. Azevedo de Amorim, Dexter Kozen, Radu Mardare, Prakash Panangaden 等LICS 2021 · 5 次引用
- 𝜆ₛ: computable semantics for differentiable programming with higher-order functions and datatypesBenjamin Sherman, Jesse Michel, Michael CarbinPOPL 2021 · 11 次引用
