More IID data yields lots of divergences & terrible recovery

@betanalpha commented in another thread:

IID data just amplifies the shape of the individual likelihood function. If each individual likelihood function is mildly multimodal – but not so much that the sampler can’t move between the modes and find all of the probability mass – then the product of likelihood functions can be extremely multimodal – such that the sampler gets stuck in bad modes due to initialization. In other words peaks get amplified and the valleys between the peaks get suppressed.

I coded up the computation of just the likelihood for a model with inference on the phase and frequency of a sine. Here’s the topography with just one IID sample-per-timepoint:

image

And for 10 IID samples per timepoint:
image

Note the color scale has changed by a factor of 10. Here’s the two on the same scale:

So I think the explanation of what goes wrong with periodic models is those diagonal troughs, into which chains can get stuck depending on where they’re initialized, and (as @betanalpha pointed out) the inclusion of more IID data only exacerbates the problem because the troughs get deeper.

I’m going to play a bit to see if I can discern why those troughs are there; they’re not at the frequencies I’d have expected from simple harmonic behaviours, plus they’re sensitive to phase too. Hopefully by working out why the modes are there in the first place a transform of some sort will suggest itself that will help improve the geometry.

1 Like