Skip to content

Commit 3127190

Browse files
Adjust tolerance for interger dtypes
1 parent dfc76e0 commit 3127190

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

dpnp/tests/test_linalg.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2182,7 +2182,10 @@ def test_lu_solve(self, shape, rhs_cols, order, dtype):
21822182

21832183
# check A @ x = b
21842184
Ax = a_dp @ x
2185-
assert dpnp.allclose(Ax, b_dp, rtol=1e-6, atol=1e-6)
2185+
if dpnp.issubdtype(dtype, dpnp.integer):
2186+
assert dpnp.allclose(Ax, b_dp, rtol=1e-5, atol=1e-5)
2187+
else:
2188+
assert dpnp.allclose(Ax, b_dp, rtol=1e-6, atol=1e-6)
21862189

21872190
@pytest.mark.parametrize("trans", [0, 1, 2])
21882191
@pytest.mark.parametrize("dtype", get_float_complex_dtypes())

0 commit comments

Comments
 (0)