@@ -1911,7 +1911,7 @@ def test_lu_factor(self, shape, order, dtype):
1911
1911
A_cast = a_dp .astype (LU .dtype , copy = False )
1912
1912
PA = self ._apply_pivots_rows (A_cast , piv )
1913
1913
1914
- assert_allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
1914
+ assert dpnp . allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
1915
1915
1916
1916
@pytest .mark .parametrize ("dtype" , get_float_complex_dtypes ())
1917
1917
def test_overwrite_inplace (self , dtype ):
@@ -1928,7 +1928,7 @@ def test_overwrite_inplace(self, dtype):
1928
1928
PA = self ._apply_pivots_rows (a_dp_orig , piv )
1929
1929
LU = L @ U
1930
1930
1931
- assert_allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
1931
+ assert dpnp . allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
1932
1932
1933
1933
@pytest .mark .parametrize ("dtype" , get_float_complex_dtypes ())
1934
1934
def test_overwrite_copy (self , dtype ):
@@ -1945,7 +1945,7 @@ def test_overwrite_copy(self, dtype):
1945
1945
PA = self ._apply_pivots_rows (a_dp_orig , piv )
1946
1946
LU = L @ U
1947
1947
1948
- assert_allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
1948
+ assert dpnp . allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
1949
1949
1950
1950
def test_overwrite_copy_special (self ):
1951
1951
# F-contig but dtype != res_type
@@ -1972,7 +1972,7 @@ def test_overwrite_copy_special(self):
1972
1972
a_orig .astype (L .dtype , copy = False ), piv
1973
1973
)
1974
1974
LU = L @ U
1975
- assert_allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
1975
+ assert dpnp . allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
1976
1976
1977
1977
@pytest .mark .parametrize ("shape" , [(0 , 0 ), (0 , 2 ), (2 , 0 )])
1978
1978
def test_empty_inputs (self , shape ):
@@ -2003,7 +2003,7 @@ def test_strided(self, sl):
2003
2003
PA = self ._apply_pivots_rows (a_dp , piv )
2004
2004
LU = L @ U
2005
2005
2006
- assert_allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
2006
+ assert dpnp . allclose (LU , PA , rtol = 1e-6 , atol = 1e-6 )
2007
2007
2008
2008
def test_singular_matrix (self ):
2009
2009
a_dp = dpnp .array ([[1.0 , 2.0 ], [2.0 , 4.0 ]])
@@ -2070,7 +2070,7 @@ def test_lu_factor_batched(self, shape, order, dtype):
2070
2070
L , U = self ._split_lu (lu_3d [i ], m , n )
2071
2071
A_cast = a_3d [i ].astype (L .dtype , copy = False )
2072
2072
PA = self ._apply_pivots_rows (A_cast , piv_2d [i ])
2073
- assert_allclose (L @ U , PA , rtol = 1e-6 , atol = 1e-6 )
2073
+ assert dpnp . allclose (L @ U , PA , rtol = 1e-6 , atol = 1e-6 )
2074
2074
2075
2075
@pytest .mark .parametrize ("dtype" , get_float_complex_dtypes ())
2076
2076
@pytest .mark .parametrize ("order" , ["C" , "F" ])
@@ -2082,7 +2082,7 @@ def test_overwrite(self, dtype, order):
2082
2082
)
2083
2083
2084
2084
assert lu is not a_dp
2085
- assert_allclose (a_dp , a_dp_orig )
2085
+ assert dpnp . allclose (a_dp , a_dp_orig )
2086
2086
2087
2087
m = n = 2
2088
2088
lu_3d = lu .reshape ((- 1 , m , n ))
@@ -2092,7 +2092,7 @@ def test_overwrite(self, dtype, order):
2092
2092
L , U = self ._split_lu (lu_3d [i ], m , n )
2093
2093
A_cast = a_3d [i ].astype (L .dtype , copy = False )
2094
2094
PA = self ._apply_pivots_rows (A_cast , piv_2d [i ])
2095
- assert_allclose (L @ U , PA , rtol = 1e-6 , atol = 1e-6 )
2095
+ assert dpnp . allclose (L @ U , PA , rtol = 1e-6 , atol = 1e-6 )
2096
2096
2097
2097
@pytest .mark .parametrize (
2098
2098
"shape" , [(0 , 2 , 2 ), (2 , 0 , 2 ), (2 , 2 , 0 ), (0 , 0 , 0 )]
@@ -2119,7 +2119,7 @@ def test_strided(self):
2119
2119
PA = self ._apply_pivots_rows (
2120
2120
a_stride [i ].astype (L .dtype , copy = False ), piv [i ]
2121
2121
)
2122
- assert_allclose (L @ U , PA , rtol = 1e-6 , atol = 1e-6 )
2122
+ assert dpnp . allclose (L @ U , PA , rtol = 1e-6 , atol = 1e-6 )
2123
2123
2124
2124
def test_singular_matrix (self ):
2125
2125
a = dpnp .zeros ((3 , 2 , 2 ), dtype = dpnp .default_float_type ())
0 commit comments