Skip to content

A tutorial on Bayesian Inference with Tensorflow Probability

License

Notifications You must be signed in to change notification settings

nayyarv/ProbablyTensorFlow

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

ProbablyTensorFlow

Bayesian Inference is not a complex idea, while there are some complexities, we are actually witnessing a selection bias in that we rarely see simple problems solved in a Bayesian way because simple problems work well with frequentist analysis. We only turn to Bayesian inference when frequentism fails! As such, Bayesian Inference seems significantly more insurmountable when your introduction has us solving problems which you've never heard of before!

This is an introduction to Bayesian Inference with TensorFlow Probability, looking at simple problems like coin tosses and linear regression to build an intuition and understanding of what's happening. Colab Link for this notebook

Disclaimer

Tensorflow Probability is a new feature and is still under construction. It's very powerful and this notebook only covers the basics of both Bayesian Inference and Tensorflow Probability. There is still a lot of boilerplate which I expect to see less of in future releases.

Additionally, I'm not the most experienced Tensorflow user, being more accustomed to pytorch (tensorflow feels more functional and pytorch more imperative/OO), so my code is unlikely to be efficent, or even good. I have strived for clarity and understanding, aiming this talk at relative newcomers to stats/programmning. Arguably, TFP is the wrong choice to introduce to beginners, but each of PyMC3 and STAN come with their own baggage too.

Bayesian Resources

  1. Statistical Rethinking is the best introductory text to Bayesian Inference. It's not maths heavy, but is very concept heavy.
  2. My Slide Deck on why you should care about Bayesian Inference
  3. STAN and PyMC3 are much gentler introductions to Probabilistic/Bayesian Programming. They're much more mature and PyMC4 will be written with TFP as it's backend instead of theano.

About

A tutorial on Bayesian Inference with Tensorflow Probability

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published