Skip to content

Commit

Permalink
Reduce number of minimum draw in warning message
Browse files Browse the repository at this point in the history
  • Loading branch information
aloctavodia authored and ricardoV94 committed Feb 20, 2024
1 parent 7b38a48 commit 97a7a00
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions pymc/sampling/mcmc.py
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 97a7a00

Please sign in to comment.