Skip to content

Commit b2df8cc

Browse files
committed
Seed test_tuning::test_mle_jacobian test
1 parent cac68ab commit b2df8cc

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

pymc3/tests/models.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ def simple_normal(bounded_prior=False):
215215
sd = 1.0
216216
a, b = (9, 12) # bounds for uniform RV, need non-symmetric to reproduce issue
217217

218-
with pm.Model() as model:
218+
with pm.Model(rng_seeder=2482) as model:
219219
if bounded_prior:
220220
mu_i = pm.Uniform("mu_i", a, b)
221221
else:

pymc3/tests/test_tuning.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818

1919
from pymc3.step_methods.metropolis import tune
2020
from pymc3.tests import models
21-
from pymc3.tests.helpers import select_by_precision
2221
from pymc3.tuning import find_MAP, scaling
2322

2423

@@ -37,7 +36,7 @@ def test_guess_scaling():
3736
def test_mle_jacobian():
3837
"""Test MAP / MLE estimation for distributions with flat priors."""
3938
truth = 10.0 # Simple normal model should give mu=10.0
40-
rtol = select_by_precision(float64=1e-6, float32=1e-4)
39+
rtol = 1e-5 # this rtol should work on both floatX precisions
4140

4241
start, model, _ = models.simple_normal(bounded_prior=False)
4342
with model:

0 commit comments

Comments
 (0)