I wonder what has prevented these languages from being widely adopted by the robotics community? My suspicion is that it's always easier to work with general purpose languages, but even then "probabilistic programming libraries" for Python, e.g. Pyro or Edward, haven't really taken off either... Most people write SLAM algorithms in C++ and don't pay much attention to what the PPL people are doing.
We’re always looking for interested people to join and try out some of the systems. For easy access to some of the active PP frameworks:
Why so many? The design space is just beginning to be well-explored! And the community has welcomed experimentation!
Gen.jl and Jaynes.jl are research projects aiming to push the boundary of what you can express inside a PP framework - inference here is sample-based, with incremental computation providing most of the optimization. Gen.jl is much more mature than the latter (which I develop) and has tons of great and thought-provoking documentation. Turing.jl is also very mature, and they have a great number of resources showing how to express a number of classic models in their language, as well as how to compose sampling-based inference algorithms. The Turing folks also implemented the de-facto version of HMC in Julia https://github.com/TuringLang/AdvancedHMC.jl. Soss.jl is also very cool - and works by AST re-writing - with cool functionality integration from SymPy in Python. I’m not sure the state of the docs for Soss.jl - but the researchers for each of these systems are always willing to discuss the systems on the Julia Slack or Zulip!
A PPS in an environment without those two things is at a disadvantage.
I think Stan and PyMC3 both focus on optimized implementations of Hamiltonian Monte Carlo - a Markov chain Monte Carlo algorithm which requires that you express models with target variables whose log probability densities are differentiable with respect to their sample spaces. I think Stan provides other algorithms as well, and possibly also PyMC3 but I know that these systems are known for their implementations of HMC (similar to NumPyro, which has a highly optimized version of HMC).
This is certainly not all probabilistic programs - but many popular models do tend to fall in this category (where you can use HMC for inference). In both cases, I’m also unsure if these systems are “universal” in the sense that you can express any stochastic computable function which halts with probability 1. Similar to Turing completeness, if the system does not allow you to express control flow with runtime bounds, or disallows stochastic bounds - it’s not Turing universal. This is not typically a bad thing, because most classical models don’t require this feature, but it does tend to separate frameworks for PP.
As a shameless plug, my own library doesn’t rely on AST meta programming (e.g macros) but instead relies upon dynamic compiler interception - which is metaprogramming of a different sort.
PS for another PP system which doesn’t rely on metaprogramming, you could explore Probabilistic C: http://proceedings.mlr.press/v32/paige14.pdf
The downside is a trickier to write and debug API on the inference developer's side. Do link your library as I try to evaluate every PPS I encounter.
And being rough around the edges is an ok price to pay for not losing an ecosystem.
Most pre- and post- processing (with the exception of visualization) should probably be a part of your model!
In comparison to other PPLs in Julia, Turing is less a single probabilistic programming library and more a framework for probabilistic programming by providing a large collection of exchangeable libraries.
AdvancedHMC, which you mentioned, is simply one of the many projects for probabilistic machine learning that we actively develop. AdvancedHMC specifically is meant as a research platform for HMC algorithms and implements state of the art algorithms for HMC based inference. Other Turing libraries focus more towards variational approximations of static models, Bayesian learning in neural networks, and universal probabilistic programming with support for dynamic models.
I just read the tutorials & examples for Turing and Gen, and to me, it seems that they are more or less nifty DSLs for expressing statistical models, but their functionalities could be easily replicated, albeit in an uglier way, with standard Julia.
Is there some deeper theoretical divergence I missed, or are they just strongly facilitating the expression of statistical models?
I also disagree that their functionality could be easily replicated in standard Julia. What you see is the easiest way to provide this functionality in a model-agnostic way.
That's true. But if you should describe the essence of probabilistic programming to someone used only to “classical” scientific computing, what would be the key point(s)?
BTW, I'm sorry if I came off as dismissive, I'm only frustrated not to grasp why it's considered to be such a step forward. AD I get it, all the differentials are automagically imputed directly from the source code, which is something that practically could not be done otherwise. But what I get from Turing or Gen are just nifty DSLs.
Without a PPL, you would traditionally write your code for your model and would have to implement a suitable inference algorithm yourself.
With a PPL you only specify the generative process and don't have to implement the inference side of things nor care about an implementation of your model that is suitable for inference.
Also, I am pretty sure more than 90% of them have never learned functional programming or related computational theories, even in schools.