Abstract
Sensitivity properties describe how changes to the input of a program affect the output, typically by upper bounding the distance between the outputs of two runs by a monotone function of the distance between the corresponding inputs. When programs are probabilistic, the distance between outputs is a distance between distributions. The Kantorovich lifting provides a general way of defining a distance between distributions by lifting the distance of the underlying sample space; by choosing an appropriate distance on the base space, one can recover other usual probabilistic distances, such as the Total Variation distance. We develop a relational pre-expectation calculus to upper bound the Kantorovich distance between two executions of a probabilistic program. We illustrate our methods by proving algorithmic stability of a machine learning algorithm, convergence of a reinforcement learning algorithm, and fast mixing for card shuffling algorithms. We also consider some extensions: using our calculus to show convergence of Markov chains to the uniform distribution over states and an asynchronous extension to reason about pairs of program executions with different control flow.
- David Aldous. 1983. Random Walks on Finite Groups and Rapidly Mixing Markov Chains. In Séminaire de Probabilités XVII 1981/82 (Lecture Notes in Mathematics, Vol. 986 ). Springer-Verlag, 243-297. https://eudml.org/doc/113445Google Scholar
- Philip Amortila, Doina Precup, Prakash Panangaden, and Marc G. Bellemare. 2020. A Distributional Analysis of SamplingBased Reinforcement Learning Algorithms. In The 23rd International Conference on Artificial Intelligence and Statistics, AISTATS 2020, 26-28 August 2020, Online [Palermo, Sicily, Italy] (Proceedings of Machine Learning Research, Vol. 108 ), Silvia Chiappa and Roberto Calandra (Eds.). PMLR, 4357-4366. http://proceedings.mlr.press/v108/amortila20a.htmlGoogle Scholar
- Robert B. Ash and Catherine A. Doleans-Dade. 2000. Probability and Measure Theory. Academic Press.Google Scholar
- Arthur Azevedo de Amorim, Marco Gaboardi, Emilio Jesús Gallego Arias, and Justin Hsu. 2014. Really natural linear indexed type-checking. In Symposium on Implementation and Application of Functional Programming Languages (IFL), Boston, Massachusetts. ACM Press, 5 : 1-5 : 12. https://doi.org/10.1145/2746325.2746335 Google Scholar
Digital Library
- Arthur Azevedo de Amorim, Marco Gaboardi, Justin Hsu, Shin-ya Katsumata, and Ikram Cherigui. 2017. A semantic account of metric preservation. In ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL), Paris, France. 545-556. https://doi.org/10.1145/3009837.3009890 Google Scholar
Digital Library
- Giorgio Bacci, Radu Mardare, Prakash Panangaden, and Gordon D. Plotkin. 2018. An Algebraic Theory of Markov Processes. In Proceedings of the 33rd Annual ACM/IEEE Symposium on Logic in Computer Science, LICS 2018, Oxford, UK, July 09-12, 2018, Anuj Dawar and Erich Grädel (Eds.). ACM, 679-688. https://doi.org/10.1145/3209108.3209177 Google Scholar
Digital Library
- Gilles Barthe, Thomas Espitau, Benjamin Grégoire, Justin Hsu, and Pierre-Yves Strub. 2018. Proving expected sensitivity of probabilistic programs. PACMPL 2, POPL ( 2018 ), 57 : 1-57 : 29. https://doi.org/10.1145/3158145 Google Scholar
Digital Library
- Kevin Batz, Benjamin Lucien Kaminski, Joost-Pieter Katoen, Christoph Matheja, and Thomas Noll. 2019. Quantitative Separation Logic: A Logic for Reasoning About Probabilistic Pointer Programs. PACMPL 3, POPL ( 2019 ), 34 : 1-34 : 29. https://doi.org/10.1145/3290347 Google Scholar
Digital Library
- Kevin Batz, Benjamin Lucien Kaminski, Joost-Pieter Katoen, and Christoph Matheja. 2021. Relatively Complete Verification of Probabilistic Programs-An Expressive Language for Expectation-based Reasoning. Proc. ACM Program. Lang. 5, POPL ( 2021 ).Google Scholar
Digital Library
- Nick Benton. 2004. Simple Relational Correctness Proofs for Static Analyses and Program Transformations. In ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL), Venice, Italy. 14-25. https://doi.org/10. 1145/964001.964003 Google Scholar
Digital Library
- Olivier Bousquet and André Elisseef. 2002. Stability and Generalization. Journal of Machine Learning Research 2 ( 2002 ), 499-526. http://www.jmlr.org/papers/v2/bousquet02a.htmlGoogle Scholar
- Swarat Chaudhuri, Sumit Gulwani, and Roberto Lublinerman. 2010. Continuity analysis of programs. In ACM SIGPLANSIGACT Symposium on Principles of Programming Languages (POPL), Madrid, Spain. 57-70. https://doi.org/10.1145/ 1706299.1706308 Google Scholar
Digital Library
- Swarat Chaudhuri, Sumit Gulwani, and Roberto Lublinerman. 2012. Continuity and robustness of programs. Commun. ACM 55, 8 ( 2012 ), 107-115. https://doi.org/10.1145/2240236.2240262 Google Scholar
Digital Library
- Marco Gaboardi, Andreas Haeberlen, Justin Hsu, Arjun Narayan, and Benjamin C. Pierce. 2013. Linear dependent types for diferential privacy. In ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL), Rome, Italy. 357-370. https://doi.org/10.1145/2429069.2429113 Google Scholar
Digital Library
- Daniel Gebler, Kim G. Larsen, and Simone Tini. 2016. Compositional bisimulation metric reasoning with probabilistic process calculi. Logical Methods in Computer Science 12, 4 ( 2016 ). https://doi.org/10.2168/LMCS-12 ( 4 :12) 2016 Google Scholar
Cross Ref
- Daniel Gebler and Simone Tini. 2018. SOS specifications for uniformly continuous operators. J. Comput. Syst. Sci. 92 ( 2018 ), 113-151. https://doi.org/10.1016/j.jcss. 2017. 09.011 Google Scholar
Digital Library
- Friedrich Gretz, Joost-Pieter Katoen, and Annabelle McIver. 2014. Operational versus weakest pre-expectation semantics for the probabilistic guarded command language. Perform. Evaluation 73 ( 2014 ), 110-132. https://doi.org/10.1016/j.peva. 2013. 11.004 Google Scholar
Digital Library
- Moritz Hardt, Ben Recht, and Yoram Singer. 2016. Train faster, generalize better: Stability of stochastic gradient descent. In International Conference on Machine Learning (ICML), New York, NY (Journal of Machine Learning Research, Vol. 48 ). JMLR.org, 1225-1234. http://jmlr.org/proceedings/papers/v48/hardt16.htmlGoogle Scholar
- Zixin Huang, Zhenbang Wang, and Sasa Misailovic. 2018. PSense: Automatic Sensitivity Analysis for Probabilistic Programs. In Automated Technology for Verification and Analysis-16th International Symposium, ATVA 2018, Los Angeles, CA, USA, October 7-10, 2018, Proceedings (LNCS, Vol. 11138 ), Shuvendu K. Lahiri and Chao Wang (Eds.). Springer, 387-403. https://doi.org/10.1007/978-3-030-01090-4_23 Google Scholar
Cross Ref
- Benjamin Lucien Kaminski and Joost-Pieter Katoen. 2017. A weakest pre-expectation semantics for mixed-sign expectations. In LICS. IEEE Computer Society, 1-12. https://doi.org/10.1109/LICS. 2017.8005153 Google Scholar
Cross Ref
- Benjamin Lucien Kaminski, Joost-Pieter Katoen, Christoph Matheja, and Federico Olmedo. 2016. Weakest Precondition Reasoning for Expected Run-Times of Probabilistic Programs. In European Symposium on Programming (ESOP), Eindhoven, The Netherlands (Lecture Notes in Computer Science, Vol. 9632 ). Springer-Verlag, 364-389. https://doi.org/10.1007/978-3-662-49498-1_15 Google Scholar
Digital Library
- Dexter Kozen. 1985. A Probabilistic PDL. J. Comput. System Sci. 30, 2 ( 1985 ), 162-178. https://doi.org/10.1016/ 0022-0000 ( 85 ) 90012-1 Google Scholar
Cross Ref
- Annabelle McIver and Carroll Morgan. 2005. Abstraction, Refinement and Proof for Probabilistic Systems. Springer.Google Scholar
- Carroll Morgan, Annabelle McIver, and Karen Seidel. 1996. Probabilistic Predicate Transformers. ACM Transactions on Programming Languages and Systems 18, 3 ( 1996 ), 325-353.Google Scholar
Digital Library
- Federico Olmedo, Friedrich Gretz, Nils Jansen, Benjamin Lucien Kaminski, Joost-Pieter Katoen, and Annabelle McIver. 2018. Conditioning in Probabilistic Programming. ACM Trans. Program. Lang. Syst. 40, 1 ( 2018 ), 4 : 1-4 : 50. https: //doi.org/10.1145/3156018 Google Scholar
Digital Library
- Federico Olmedo, Benjamin Lucien Kaminski, Joost-Pieter Katoen, and Christoph Matheja. 2016. Reasoning about Recursive Probabilistic Programs. In Proceedings of the 31st Annual ACM/IEEE Symposium on Logic in Computer Science, LICS ' 16, New York, NY, USA, July 5-8, 2016, Martin Grohe, Eric Koskinen, and Natarajan Shankar (Eds.). ACM, 672-681. https://doi.org/10.1145/2933575.2935317 Google Scholar
Digital Library
- David Park. 1969. Fixpoint Induction and Proofs of Program Properties. Machine Intelligence 5 ( 1969 ).Google Scholar
- Benedetto Piccoli and Francesco Rossi. 2016. On Properties of the Generalized Wasserstein Distance. Archive for Rational Mechanics and Analysis 222, 3 ( 01 Dec 2016 ), 1339-1365. https://doi.org/10.1007/s00205-016-1026-7 Google Scholar
Cross Ref
- Jason Reed and Benjamin C Pierce. 2010. Distance Makes the Types Grow Stronger: A Calculus for Diferential Privacy. In ACM SIGPLAN International Conference on Functional Programming (ICFP), Baltimore, Maryland. https://doi.org/10.1145/ 1863543.1863568 Google Scholar
Digital Library
- Richard S. Sutton. 1988. Learning to Predict by the Methods of Temporal Diferences. Mach. Learn. 3 ( 1988 ), 9-44. https://doi.org/10.1007/BF00115009 Google Scholar
Cross Ref
- Cédric Villani. 2008. Optimal Transport: Old and New. Springer-Verlag.Google Scholar
- Peixin Wang, Hongfei Fu, Krishnendu Chatterjee, Yuxin Deng, and Ming Xu. 2020. Proving expected sensitivity of probabilistic programs with randomized variable-dependent termination time. Proc. ACM Program. Lang. 4, POPL ( 2020 ), 25 : 1-25 : 30. https://doi.org/10.1145/3371093 Google Scholar
Digital Library
- Daniel Winograd-Cort, Andreas Haeberlen, Aaron Roth, and Benjamin C. Pierce. 2017. A framework for adaptive diferential privacy. In ACM SIGPLAN International Conference on Functional Programming (ICFP), Oxford, England. 10 : 1-10 : 29. https://doi.org/10.1145/3110254 Google Scholar
Digital Library
Index Terms
A pre-expectation calculus for probabilistic sensitivity
Recommendations
Guaranteed bounds for posterior inference in universal probabilistic programming
PLDI 2022: Proceedings of the 43rd ACM SIGPLAN International Conference on Programming Language Design and ImplementationWe propose a new method to approximate the posterior distribution of probabilistic programs by means of computing guaranteed bounds. The starting point of our work is an interval-based trace semantics for a recursive, higher-order probabilistic ...
A lambda-calculus foundation for universal probabilistic programming
ICFP 2016: Proceedings of the 21st ACM SIGPLAN International Conference on Functional ProgrammingWe develop the operational semantics of an untyped probabilistic λ-calculus with continuous distributions, and both hard and soft constraints,as a foundation for universal probabilistic programming languages such as Church, Anglican, and Venture. Our ...
Characterizing and reasoning about probabilistic and non-probabilistic expectation
Expectation is a central notion in probability theory. The notion of expectation also makes sense for other notions of uncertainty. We introduce a propositional logic for reasoning about expectation, where the semantics depends on the underlying ...






Comments