Implementation and derivation of "Variational Bayesian inference for a nonlinear forward model." [Chappell et al. 2008] for arbitrary, user-defined model errors.
By default, bayes.vb.MVN and bayes.vb.Gamma are not serializable with JSON. This PR provides a matching encoder and decoder to enable this.
IMO this is very handy when you want to easily read and write intermediate results to disk, e.g. in a pydoit-workflow where the posterior from one experiment is the prior of a subsequent one.
If that is too specific, let me know. This BayesEncoder and bayes_hook can easily moved somewhere else, e.g. to my examples, if I am the only one to use it.
By default,
bayes.vb.MVN
andbayes.vb.Gamma
are not serializable with JSON. This PR provides a matching encoder and decoder to enable this.IMO this is very handy when you want to easily read and write intermediate results to disk, e.g. in a pydoit-workflow where the posterior from one experiment is the prior of a subsequent one.