From 97a7a00432e0c39bb968bb87a6220afe583d089b Mon Sep 17 00:00:00 2001 From: aloctavodia Date: Mon, 19 Feb 2024 13:07:44 -0300 Subject: [PATCH] Reduce number of minimum draw in warning message --- pymc/sampling/mcmc.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pymc/sampling/mcmc.py b/pymc/sampling/mcmc.py index 9c031d47c4..dcb461066c 100644 --- a/pymc/sampling/mcmc.py +++ b/pymc/sampling/mcmc.py @@ -665,8 +665,11 @@ def sample( if draws == 0: msg = "Tuning was enabled throughout the whole trace." _log.warning(msg) - elif draws < 500: - msg = "Only %s samples in chain." % draws + elif draws < 100: + msg = ( + "Only %s samples per chain. Reliable r-hat and ESS diagnostics require longer chains for accurate estimate." + % draws + ) _log.warning(msg) auto_nuts_init = True