3232 get_integer_float_dtypes ,
3333 has_support_aspect16 ,
3434 has_support_aspect64 ,
35- is_gpu_device ,
3635 numpy_version ,
3736)
3837from .third_party .cupy import testing
@@ -2178,25 +2177,11 @@ def test_out(self, func, dt_in, dt_out):
21782177 if dt_in != dt_out :
21792178 if numpy .can_cast (dt_in , dt_out , casting = "same_kind" ):
21802179 # NumPy allows "same_kind" casting, dpnp does not
2181- if (
2182- func != "fix"
2183- and dt_in == dpnp .bool
2184- and dt_out == dpnp .int8
2185- and is_gpu_device ()
2186- ):
2187- # TODO: get rid of w/a when dpctl#2030 is fixed
2188- pass
2189- else :
2190- assert_raises (ValueError , getattr (dpnp , func ), ia , out = iout )
2180+ assert_raises (ValueError , getattr (dpnp , func ), ia , out = iout )
21912181 else :
21922182 assert_raises (ValueError , getattr (dpnp , func ), ia , out = iout )
21932183 assert_raises (TypeError , getattr (numpy , func ), a , out = out )
21942184 else :
2195- if func != "fix" and dt_in == dpnp .bool and is_gpu_device ():
2196- # TODO: get rid of w/a when dpctl#2030 is fixed
2197- out = out .astype (numpy .int8 )
2198- iout = iout .astype (dpnp .int8 )
2199-
22002185 expected = getattr (numpy , func )(a , out = out )
22012186 result = getattr (dpnp , func )(ia , out = iout )
22022187 assert result is iout
@@ -2222,11 +2207,6 @@ def test_out_usm_ndarray(self, func, dt):
22222207 out = numpy .empty (a .shape , dtype = dt )
22232208 ia , usm_out = dpnp .array (a ), dpt .asarray (out )
22242209
2225- if func != "fix" and dt == dpnp .bool and is_gpu_device ():
2226- # TODO: get rid of w/a when dpctl#2030 is fixed
2227- out = out .astype (numpy .int8 )
2228- usm_out = dpt .asarray (usm_out , dtype = dpnp .int8 )
2229-
22302210 expected = getattr (numpy , func )(a , out = out )
22312211 result = getattr (dpnp , func )(ia , out = usm_out )
22322212 assert result .get_array () is usm_out
0 commit comments