Skip to content

Commit 138daee

Browse files
committed
fix tests on float32
1 parent 9e69e0d commit 138daee

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

tests/tensor/rewriting/test_linalg.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -150,15 +150,16 @@ def test_cholesky_ldotlt(tag, cholesky_form, product):
150150
# Test some concrete value through f
151151
# there must be lower triangular (f assumes they are)
152152
Avs = [
153-
np.eye(1),
154-
np.eye(10),
155-
np.array([[2, 0], [1, 4]]),
153+
np.eye(1, dtype=pytensor.config.floatX),
154+
np.eye(10, dtype=pytensor.config.floatX),
155+
np.array([[2, 0], [1, 4]], dtype=pytensor.config.floatX),
156156
]
157157
if not tag:
158158
# these must be positive def
159159
Avs.extend(
160160
[
161-
np.ones((4, 4)) + np.eye(4),
161+
np.ones((4, 4), dtype=pytensor.config.floatX)
162+
+ np.eye(4, dtype=pytensor.config.floatX),
162163
]
163164
)
164165

0 commit comments

Comments
 (0)