Probabilistic Machine Learning

CS 691 · IIT Gandhinagar · Semester I, 2022–23

This course treats machine learning as inference under uncertainty. It moves from Bayes' rule, maximum likelihood and MAP estimation through approximate inference (Laplace, Monte Carlo, MCMC and variational methods) to Bayesian neural networks, Gaussian processes, latent-variable models, active learning, Bayesian optimisation and diffusion models. Assignments are written in JAX with TensorFlow Probability, and a project carries most of the grade.

Instructor
Prof. Nipun Batra
Email
nipun.batra@iitgn.ac.in
Classes
Thursday, 12:00–1:30 pm, 7/102; Friday, 2:00–3:30 pm, 7/105
Google Classroom
Class code u7jjtu2
Teaching assistant
Zeel B Patel
Prerequisites
Mathematics for ML, a prior ML course such as ES 654, and good Python programming (details)

Lectures

Questions

What does the course cover?
  • Probability refresher: probability theory, discrete and continuous distributions, joint distributions, sampling from different distributions (for example with the Box–Muller transform), uncertainty modelling, and information-theoretic concepts such as KL divergence and entropy.
  • Bayesian concept learning: likelihood, prior and posterior; maximum likelihood (MLE) and maximum a posteriori (MAP) estimation; full Bayesian estimation with conjugate priors (the Beta–Bernoulli model for a coin toss, the Normal–Normal model for the parameters of a Normal distribution).
  • Bayesian supervised methods: for regression, Bayesian linear regression and robust linear regression through alternative likelihoods (Laplace, Student-t); for classification, Bayesian logistic regression and Bayesian naive Bayes.
  • Latent-variable modelling: Gaussian mixture models and probabilistic principal component analysis (PPCA).
  • Approximate inference: sampling (rejection sampling, importance sampling, Markov chain Monte Carlo, Metropolis–Hastings, Gibbs sampling, the No-U-Turn Sampler) and variational inference (mean field, the evidence lower bound, the reparameterisation trick, stochastic VI, automatic differentiation VI).
  • Gaussian processes: the multivariate Normal distribution and its properties, kernels, GP regression and classification, approximate inference and sparse GPs.
  • Bayesian optimisation and active learning: query by committee, uncertainty sampling, expected model change; acquisition functions, GP-based and random-forest-based Bayesian optimisation.
  • Probabilistic deep learning: MC dropout, deep ensembles, Bayesian neural networks and deep GPs.
What should I know before the course?
  • Mathematics for ML: the recommended reading is the Mathematics for Machine Learning book.
  • A prior ML course: ES 654 at IIT Gandhinagar or equivalent.
  • Good programming skills in Python and familiarity with NumPy, pandas, Matplotlib and scikit-learn. The recommended reading is the Python Data Science Handbook.
How is the course graded?

Assignments 20%, quizzes 20% and the project 60%. Each quiz covers everything from the previous quiz up to the day of the quiz. See Assessment.

How are assignments done?

In groups of two, as a single Jupyter notebook, using TensorFlow Probability with the JAX substrate for distributions and JAX for automatic differentiation and vectorised code. Draw insights from your results rather than only presenting answers. See Assignments.

Is there a project?

Yes, and it is worth 60% of the grade. The Projects page lists ideas, from Bayesian unlearning and Stein variational inference to deep GPs and neural processes for energy disaggregation and air quality.

References

Textbooks:

  • Kevin P. Murphy, Machine Learning: A Probabilistic Perspective, MIT Press, 2012
  • Kevin P. Murphy, Probabilistic Machine Learning: An Introduction, MIT Press, 2022
  • Kevin P. Murphy, Probabilistic Machine Learning: Advanced Topics, MIT Press, 2023
  • Christopher M. Bishop, Pattern Recognition and Machine Learning
  • Allen B. Downey, Think Bayes: Bayesian Statistics in Python, Green Tea Press, 2012
  • David Barber, Bayesian Reasoning and Machine Learning, Cambridge University Press, 2012
  • Carl Edward Rasmussen and Christopher K. I. Williams, Gaussian Processes for Machine Learning, MIT Press, 2006
  • Richard McElreath, Statistical Rethinking, CRC Press, 2020

Similar courses:

YouTube channels and playlists:

Teaching assistant