Advice with hierarchical model

Again quoting straight from the blog post (we really should port all these tips into an FAQ, shouldn’t we?):

The number of effective samples is smaller than XYZ for some parameters.

  • Quoting Junpeng Lao on discourse.pymc3.io: “A low number of effective samples is usually an indication of strong autocorrelation in the chain.”
  • Make sure you’re using an efficient sampler like NUTS. (And not, for instance, Metropolis-Hastings. (I mean seriously, it’s the 21st century, why would you ever want Metropolis-Hastings?))
  • Tweak the acceptance probability ( target_accept ) - it should be large enough to ensure good exploration, but small enough to not reject all proposals and get stuck.

Also, I think that prior visualization will be moved to ArviZ, see this issue. But we appreciate any code you think would be good to contribute!