New major version of Pymc

PYMC received a major update: version 6.0., but not only! All the ecosystem around this package (Pytensor, Arviz, and more) benefited from a major update. Let’s see what’s new in the different areas:

Backend

Pytensor also received a major update and arrived with version 3.0. This package is the core of the PyMC computation engine and improves performance by about 2x.

Numba is now the default backend. The others (C or JAX) are still available.

Small note If you had problems like me with the BLAS library (which was beyond the range of pip and had to be installed and linked separately), you will be happy to learn that these problems have been solved.

Inference

Modeling

Easier indexing with named dims. Indeed, the argument ‘dims=’ automatically accepts and broadcasts the necessary dimensions when they are passed to the model with the dictionary Coords.

The discrete and latent variables had to be summed by hand, from now on the process is automated with ‘pymc_extras.marginalize’.

Again in pymc_extras, statesspaces model are more easy to compose with the ‘structural’ package

Bayesian workflow

Arviz already allowed beautiful plots to assess the convergence of models written with PyMC, it is now enriched with many new charts. In particular, a graph on the channel ranks. Credibility intervals go from 94% to 89% and Equal-Tailed (ETI) is the new default setting and replaces Highest-Density (HDI)

Two new (?) packages:

  • Preliz which helps us to declare the priors on the basis of the desired minimum, maximum and center of mass.
  • Kulprit will allow you to select the most explanatory variables to include in the models

Leave a Reply

Your email address will not be published. Required fields are marked *