Bayesian neural networks via MCMC: a Python-based tutorial

Rohitash Chandra, Joshua Simmons
4/2/2023
stat.MLcs.AIcs.LG

No official code found. Best implementation: sydney-machine-learning/Bayesianneuralnetworks-MCMC-tutorial (75 stars, last commit 2024-10-22).

Abstract

Bayesian inference provides a methodology for parameter estimation and uncertainty quantification in machine learning and deep learning methods. Variational inference and Markov Chain Monte-Carlo (MCMC) sampling methods are used to implement Bayesian inference. In the past three decades, MCMC sampling methods have faced some challenges in being adapted to larger models (such as in deep learning) and big data problems. Advanced proposal distributions that incorporate gradients, such as a Langevin proposal distribution, provide a means to address some of the limitations of MCMC sampling for Bayesian neural networks. Furthermore, MCMC methods have typically been constrained to statisticians and currently not well-known among deep learning researchers. We present a tutorial for MCMC methods that covers simple Bayesian linear and logistic models, and Bayesian neural networks. The aim of this tutorial is to bridge the gap between theory and implementation via coding, given a general sparsity of libraries and tutorials to this end. This tutorial provides code in Python with data and instructions that enable their use and extension. We provide results for some benchmark problems showing the strengths and weaknesses of implementing the respective Bayesian models via MCMC. We highlight the challenges in sampling multi-modal posterior distributions for the case of Bayesian neural networks and the need for further improvement of convergence diagnosis methods.

View on arXivView PDF

Code Implementations(1)

Bayesian neural networks via MCMC: tutorial

7518Python, DockerfileJun 13, 20221 years ago

Similar Papers

Cite this paper

@article{chandra2023bayesian,
  title  = {Bayesian neural networks via MCMC: a Python-based tutorial},
  author = {Rohitash Chandra and Joshua Simmons},
  year   = {2023},
  eprint = {2304.02595},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2304.02595v3}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2304.02595.svg)](https://codeofpaper.com/paper/2304.02595)

Discussion