Skip to content

Commit 43d5699

Browse files
Fix flaky Moyal logcdf test
1 parent 6440d59 commit 43d5699

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

pymc/tests/distributions/test_continuous.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -778,10 +778,13 @@ def test_moyal_logp(self):
778778
reason="PyMC underflows earlier than scipy on float32",
779779
)
780780
def test_moyal_logcdf(self):
781+
# SciPy has new (?) precision issues at {mu=-2.1, sigma=0.5, x=2.1}
782+
# We circumvent it by skipping sigma=0.5:
783+
rplusbig = Domain([0, 0.9, 0.99, 1, 1.5, 2, 20, np.inf])
781784
check_logcdf(
782785
pm.Moyal,
783786
R,
784-
{"mu": R, "sigma": Rplusbig},
787+
{"mu": R, "sigma": rplusbig},
785788
lambda value, mu, sigma: floatX(st.moyal.logcdf(value, mu, sigma)),
786789
)
787790
if pytensor.config.floatX == "float32":

0 commit comments

Comments
 (0)