Thermodynamic Bayesian Inference