JohannesBuchner / UltraNest

Fit and compare complex models reliably and rapidly. Advanced nested sampling.
https://johannesbuchner.github.io/UltraNest/
Other
153 stars 30 forks source link

How does ultranest determine convergence and stop? #146

Closed LuShenJ closed 2 months ago

LuShenJ commented 2 months ago

I am new to using UltraNest and have used emcee in the past. I am curious how UltraNest determines convergence. Because in emcee I need to decide the number of steps myself, but in UltraNest it seems like I don't need to do that.

erinaldi commented 2 months ago

Nested sampling is a different algorithm than MCMC. You can see here a summary on the ultranest documentation https://johannesbuchner.github.io/UltraNest/method.html The termination criteria (number 4 in the list) is how the algorithm stops. Intuitively you can think of nested sampling as computing an integral (the marginal likelihood or evidence) and stopping when the sum for the integral has converged (within some tolerance).

In nested sampling you do need to specify other parameters such as the number of live points or the parameters of the slice samplers. However, the type of diagnostic tests you would do on the final results are different from what you are used in emcee, like burn-in or autocorrelations.

JohannesBuchner commented 2 months ago

Thanks @erinaldi

Here are some additional resources: https://arxiv.org/abs/2101.09675 https://www.youtube.com/watch?v=baLFl_4ZwXw