Skip to content

Commit

Permalink
RNG.sample_ln_pdf: force sample_size to be integer
Browse files Browse the repository at this point in the history
  • Loading branch information
MuellerSeb committed Jul 4, 2021
1 parent d7a00c5 commit 4b35512
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions gstools/random/rng.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ def sample_ln_pdf(
sample_size = burn_in
else:
sample_size = max(burn_in, (size / nwalkers) * oversampling_factor)
# sample_size needs to be integer for emcee >= 3.1
sample_size = int(sample_size)
# initial guess
init_guess = (
self.random.rand(nwalkers).reshape((nwalkers, 1)) * sample_around
Expand Down

0 comments on commit 4b35512

Please sign in to comment.