Posts by Thomas Wiecki

Faster Sampling with JAX and Numba

PyMC can compile its models to various execution backends through PyTensor, including:

Read more ...


Using ModelBuilder class for deploying PyMC models

Many users face difficulty in deploying their PyMC models to production because deploying/saving/loading a user-created model is not well standardized. One of the reasons behind this is there is no direct way to save or load a model in PyMC like scikit-learn or TensorFlow. The new ModelBuilder class is aimed to improve this workflow by providing a scikit-learn inspired API to wrap your PyMC models.

Read more ...


Pathfinder Variational Inference

Pathfinder [Zhang et al., 2021] is a variational inference algorithm that produces samples from the posterior of a Bayesian model. It compares favorably to the widely used ADVI algorithm. On large problems, it should scale better than most MCMC algorithms, including dynamic HMC (i.e. NUTS), at the cost of a more biased estimate of the posterior. For details on the algorithm, see the arxiv preprint.

Read more ...


Rolling Regression

Pairs trading is a famous technique in algorithmic trading that plays two stocks against each other.

Read more ...


GLM: Robust Linear Regression

Duplicate implicit target name: “glm: robust linear regression”.

Read more ...


How to debug a model

There are various levels on which to debug a model. One of the simplest is to just print out the values that different variables are taking on.

Read more ...


Variational Inference: Bayesian Neural Networks

Probabilistic Programming, Deep Learning and “Big Data” are among the biggest topics in machine learning. Inside of PP, a lot of innovation is focused on making things scale using Variational Inference. In this example, I will show how to use Variational Inference in PyMC to fit a simple Bayesian Neural Network. I will also discuss how bridging Probabilistic Programming and Deep Learning can open up very interesting avenues to explore in future research.

Read more ...


Lasso regression with block updating

Sometimes, it is very useful to update a set of parameters together. For example, variables that are highly correlated are often good to update together. In PyMC block updating is simple. This will be demonstrated using the parameter step of pymc.sample.

Read more ...


Bayesian Estimation Supersedes the T-Test

Non-consecutive header level increase; H1 to H3 [myst.header]

Read more ...


GLM: Robust Regression using Custom Likelihood for Outlier Classification

Using PyMC for Robust Regression with Outlier Detection using the Hogg 2010 Signal vs Noise method.

Read more ...