From b6bd08acaa46dc2a2eb073633d8c22cc6249e071 Mon Sep 17 00:00:00 2001 From: Natalia Polina Date: Fri, 20 Sep 2024 10:32:12 -0700 Subject: [PATCH 01/23] Testing is adapted for cuda devices --- dpnp/dpnp_iface.py | 16 + dpnp/dpnp_iface_indexing.py | 3 + dpnp/dpnp_iface_libmath.py | 2 + dpnp/dpnp_iface_mathematical.py | 2 + dpnp/dpnp_iface_sorting.py | 2 + dpnp/dpnp_iface_statistics.py | 4 + tests/conftest.py | 11 + tests/skipped_tests_cuda.tbl | 820 ++++++++++++++++++++++++++++++++ tests/test_sycl_queue.py | 3 + 9 files changed, 863 insertions(+) create mode 100644 tests/skipped_tests_cuda.tbl diff --git a/dpnp/dpnp_iface.py b/dpnp/dpnp_iface.py index 62cd0683fe5..15802a470c6 100644 --- a/dpnp/dpnp_iface.py +++ b/dpnp/dpnp_iface.py @@ -72,6 +72,7 @@ "get_usm_ndarray_or_scalar", "is_supported_array_or_scalar", "is_supported_array_type", + "not_implemented_for_cuda_backend", "synchronize_array_data", ] @@ -800,6 +801,21 @@ def is_supported_array_type(a): return isinstance(a, (dpnp_array, dpt.usm_ndarray)) +def not_implemented_for_cuda_backend(obj): + """ + Raise NotImplementedError for cuda devices. + + Parameters + ---------- + obj : {SyclDevice, SyclQueue, dpnp.ndarray, usm_ndarray} + An input object with sycl_device property to check device backend. + + """ + sycl_device = getattr(obj, "sycl_device", None) + if sycl_device is not None and "cuda" in sycl_device.backend.name: + raise NotImplementedError("function not implemented for cuda backend") + + def synchronize_array_data(a): """ The dpctl interface was reworked to make asynchronous execution. diff --git a/dpnp/dpnp_iface_indexing.py b/dpnp/dpnp_iface_indexing.py index 3c94c7091ec..148e8b86f6c 100644 --- a/dpnp/dpnp_iface_indexing.py +++ b/dpnp/dpnp_iface_indexing.py @@ -173,6 +173,9 @@ def choose(x1, choices, out=None, mode="raise"): :obj:`dpnp.take_along_axis` : Preferable if choices is an array. """ + + dpnp.not_implemented_for_cuda_backend(x1) + x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) choices_list = [] diff --git a/dpnp/dpnp_iface_libmath.py b/dpnp/dpnp_iface_libmath.py index 82b86f3b9c5..b9e7e9daf69 100644 --- a/dpnp/dpnp_iface_libmath.py +++ b/dpnp/dpnp_iface_libmath.py @@ -78,6 +78,8 @@ def erf(in_array1): """ + dpnp.not_implemented_for_cuda_backend(in_array1) + x1_desc = dpnp.get_dpnp_descriptor( in_array1, copy_when_strides=False, copy_when_nondefault_queue=False ) diff --git a/dpnp/dpnp_iface_mathematical.py b/dpnp/dpnp_iface_mathematical.py index 443ad7c43da..d3809610518 100644 --- a/dpnp/dpnp_iface_mathematical.py +++ b/dpnp/dpnp_iface_mathematical.py @@ -2477,6 +2477,8 @@ def modf(x1, **kwargs): """ + dpnp.not_implemented_for_cuda_backend(x1) + x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) if x1_desc and not kwargs: return dpnp_modf(x1_desc) diff --git a/dpnp/dpnp_iface_sorting.py b/dpnp/dpnp_iface_sorting.py index c007def058b..1ae92bddf2b 100644 --- a/dpnp/dpnp_iface_sorting.py +++ b/dpnp/dpnp_iface_sorting.py @@ -174,6 +174,8 @@ def partition(x1, kth, axis=-1, kind="introselect", order=None): """ + dpnp.not_implemented_for_cuda_backend(x1) + x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) if x1_desc: if not isinstance(kth, int): diff --git a/dpnp/dpnp_iface_statistics.py b/dpnp/dpnp_iface_statistics.py index d663d9d1836..00bf5c47e72 100644 --- a/dpnp/dpnp_iface_statistics.py +++ b/dpnp/dpnp_iface_statistics.py @@ -371,6 +371,8 @@ def correlate(x1, x2, mode="valid"): """ + dpnp.not_implemented_for_cuda_backend(x1) + x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) x2_desc = dpnp.get_dpnp_descriptor(x2, copy_when_nondefault_queue=False) if x1_desc and x2_desc: @@ -655,6 +657,8 @@ def median(x1, axis=None, out=None, overwrite_input=False, keepdims=False): """ + dpnp.not_implemented_for_cuda_backend(x1) + x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) if x1_desc: if axis is not None: diff --git a/tests/conftest.py b/tests/conftest.py index db07c8d463e..a8b4c4e1dca 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -64,13 +64,20 @@ def pytest_collection_modifyitems(config, items): test_path, "skipped_tests_gpu_no_fp64.tbl" ) + # global skip file for cuda backend + test_exclude_file_cuda = os.path.join( + test_path, "skipped_tests_cuda.tbl" + ) + dev = dpctl.select_default_device() is_cpu = dev.is_cpu is_gpu_no_fp64 = not dev.has_aspect_fp64 + is_cuda = "cuda" in str(dev.backend.name) print("") print(f"DPNP current device is CPU: {is_cpu}") print(f"DPNP current device is GPU without fp64 support: {is_gpu_no_fp64}") + print(f"DPNP current device is GPU with cuda backend: {is_cuda}") print(f"DPNP version: {dpnp.__version__}, location: {dpnp}") print(f"NumPy version: {numpy.__version__}, location: {numpy}") print(f"Python version: {sys.version}") @@ -81,6 +88,10 @@ def pytest_collection_modifyitems(config, items): excluded_tests.extend( get_excluded_tests(test_exclude_file_gpu_no_fp64) ) + if is_cuda: + excluded_tests.extend( + get_excluded_tests(test_exclude_file_cuda) + ) else: excluded_tests.extend(get_excluded_tests(test_exclude_file)) diff --git a/tests/skipped_tests_cuda.tbl b/tests/skipped_tests_cuda.tbl new file mode 100644 index 00000000000..9762232f585 --- /dev/null +++ b/tests/skipped_tests_cuda.tbl @@ -0,0 +1,820 @@ +# FAILED +# fft +tests/test_fft.py::TestFftn::test_fftn[C-forward-None-complex64] +tests/test_fft.py::TestFftn::test_fftn[C-forward-None-complex128] +tests/test_fft.py::TestFftn::test_fftn[C-forward-axes2-complex64] +tests/test_fft.py::TestFftn::test_fftn[C-forward-axes2-complex128] +tests/test_fft.py::TestFftn::test_fftn[C-forward-axes3-complex64] +tests/test_fft.py::TestFftn::test_fftn[C-forward-axes3-complex128] +tests/test_fft.py::TestFftn::test_fftn[C-backward-None-complex64] +tests/test_fft.py::TestFftn::test_fftn[C-backward-None-complex128] +tests/test_fft.py::TestFftn::test_fftn[C-backward-axes2-complex64] +tests/test_fft.py::TestFftn::test_fftn[C-backward-axes2-complex128] +tests/test_fft.py::TestFftn::test_fftn[C-backward-axes3-complex64] +tests/test_fft.py::TestFftn::test_fftn[C-backward-axes3-complex128] +tests/test_fft.py::TestFftn::test_fftn[C-ortho-None-complex64] +tests/test_fft.py::TestFftn::test_fftn[C-ortho-None-complex128] +tests/test_fft.py::TestFftn::test_fftn[C-ortho-axes2-complex64] +tests/test_fft.py::TestFftn::test_fftn[C-ortho-axes2-complex128] +tests/test_fft.py::TestFftn::test_fftn[C-ortho-axes3-complex64] +tests/test_fft.py::TestFftn::test_fftn[C-ortho-axes3-complex128] +tests/test_fft.py::TestFftn::test_fftn[F-forward-None-complex64] +tests/test_fft.py::TestFftn::test_fftn[F-forward-None-complex128] +tests/test_fft.py::TestFftn::test_fftn[F-forward-axes1-complex64] +tests/test_fft.py::TestFftn::test_fftn[F-forward-axes1-complex128] +tests/test_fft.py::TestFftn::test_fftn[F-forward-axes3-complex64] +tests/test_fft.py::TestFftn::test_fftn[F-forward-axes3-complex128] +tests/test_fft.py::TestFftn::test_fftn[F-backward-None-complex64] +tests/test_fft.py::TestFftn::test_fftn[F-backward-None-complex128] +tests/test_fft.py::TestFftn::test_fftn[F-backward-axes1-complex64] +tests/test_fft.py::TestFftn::test_fftn[F-backward-axes1-complex128] +tests/test_fft.py::TestFftn::test_fftn[F-backward-axes3-complex64] +tests/test_fft.py::TestFftn::test_fftn[F-backward-axes3-complex128] +tests/test_fft.py::TestFftn::test_fftn[F-ortho-None-complex64] +tests/test_fft.py::TestFftn::test_fftn[F-ortho-None-complex128] +tests/test_fft.py::TestFftn::test_fftn[F-ortho-axes1-complex64] +tests/test_fft.py::TestFftn::test_fftn[F-ortho-axes1-complex128] +tests/test_fft.py::TestFftn::test_fftn[F-ortho-axes3-complex64] +tests/test_fft.py::TestFftn::test_fftn[F-ortho-axes3-complex128] +tests/test_fft.py::TestFftn::test_fftn_repeated_axes_with_s[s1-axes1] +tests/test_fft.py::TestFftn::test_fftn_out[s0-axes0] +tests/test_fft.py::TestFftn::test_fftn_out[s1-axes0] +tests/test_fft.py::TestFftn::test_fftn_out[s2-axes0] +tests/test_fft.py::TestFftn::test_fftn_out[s2-axes1] +tests/test_fft.py::TestFftn::test_fftn_out[s2-axes2] +tests/test_fft.py::TestRfftn::test_rfftn_out[s1-axes1] +tests/test_fft.py::TestRfftn::test_rfftn_out[s2-axes0] +tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_50_{axes=None, norm=None, s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_51_{axes=None, norm='backward', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_52_{axes=None, norm='ortho', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_53_{axes=None, norm='forward', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_ifft2[_param_50_{axes=None, norm=None, s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_ifft2[_param_51_{axes=None, norm='backward', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_ifft2[_param_52_{axes=None, norm='ortho', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_ifft2[_param_53_{axes=None, norm='forward', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_fftn[_param_60_{axes=None, norm=None, s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_fftn[_param_61_{axes=None, norm='backward', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_fftn[_param_62_{axes=None, norm='ortho', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_fftn[_param_63_{axes=None, norm='forward', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_60_{axes=None, norm=None, s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_61_{axes=None, norm='backward', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_62_{axes=None, norm='ortho', s=None, shape=(2, 3, 4, 5)}] +tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_63_{axes=None, norm='forward', s=None, shape=(2, 3, 4, 5)}] + +# std +tests/test_linalg.py::TestCond::test_cond_nan_input[-dpnp.inf] +tests/test_linalg.py::TestCond::test_cond_nan_input[-1] +tests/test_linalg.py::TestCond::test_cond_nan_input[1] +tests/test_linalg.py::TestCond::test_cond_nan_input[dpnp.inf] +tests/test_linalg.py::TestCond::test_cond_nan_input[fro] +tests/test_linalg.py::TestCond::test_cond_nan[-dpnp.inf] +tests/test_linalg.py::TestCond::test_cond_nan[-1] +tests/test_linalg.py::TestCond::test_cond_nan[1] +tests/test_linalg.py::TestCond::test_cond_nan[dpnp.inf] +tests/test_linalg.py::TestCond::test_cond_nan[fro] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-bool_] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-int32] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-int64] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-float32] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-float64] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-complex64] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-complex128] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-None] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-bool_] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-int32] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-int64] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-float32] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-float64] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-complex64] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-complex128] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-None] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-bool_] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-int32] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-int64] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-float32] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-float64] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-complex64] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-complex128] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-None] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-int32] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-int64] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-float32] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-float64] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-None] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-int32] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-int64] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-float32] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-float64] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-None] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-int32] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-int64] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-float32] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-float64] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-int32] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-int64] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-float32] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-float64] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-None] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-int32] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-int64] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-float32] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-float64] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-None] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-int32] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-int64] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-float32] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-float64] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None--2-complex64] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None--2-complex128] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-2-complex64] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-2-complex128] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-"nuc"-complex64] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None--2-complex64] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None--2-complex128] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-2-complex64] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-2-complex128] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-"nuc"-complex64] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-int32] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-int64] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-float32] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-float64] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-None] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-int32] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-int64] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-float32] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-float64] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-None] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-int32] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-int64] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-float32] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-float64] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-int32] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-int64] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-float32] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-float64] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-None] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-int32] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-int64] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-float32] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-float64] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-None] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-int32] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-int64] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-float32] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-float64] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)--2-complex64] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)--2-complex128] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-2-complex64] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-2-complex128] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-"nuc"-complex64] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)--2-complex64] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)--2-complex128] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-2-complex64] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-2-complex128] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-"nuc"-complex64] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-None] +tests/test_linalg.py::TestSvd::test_svd[(3,4)-int32] +tests/test_linalg.py::TestSvd::test_svd[(3,4)-int64] +tests/test_linalg.py::TestSvd::test_svd[(3,4)-float32] +tests/test_linalg.py::TestSvd::test_svd[(3,4)-float64] +tests/test_linalg.py::TestSvd::test_svd[(3,4)-complex64] +tests/test_linalg.py::TestSvd::test_svd[(3,4)-complex128] +tests/test_linalg.py::TestSvd::test_svd[(3,4)-None] +tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-int32] +tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-int64] +tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-float32] +tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-float64] +tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-complex64] +tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-complex128] +tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-None] +tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-int32] +tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-int64] +tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-float32] +tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-float64] +tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-complex64] +tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-complex128] +tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-None] +tests/test_usm_type.py::test_cond[-dpnp.inf-device] +tests/test_usm_type.py::test_cond[-dpnp.inf-shared] +tests/test_usm_type.py::test_cond[-dpnp.inf-host] +tests/test_usm_type.py::test_cond[-1-device] +tests/test_usm_type.py::test_cond[-1-shared] +tests/test_usm_type.py::test_cond[-1-host] +tests/test_usm_type.py::test_cond[1-device] +tests/test_usm_type.py::test_cond[1-shared] +tests/test_usm_type.py::test_cond[1-host] +tests/test_usm_type.py::test_cond[dpnp.inf-device] +tests/test_usm_type.py::test_cond[dpnp.inf-shared] +tests/test_usm_type.py::test_cond[dpnp.inf-host] +tests/test_usm_type.py::test_cond[fro-device] +tests/test_usm_type.py::test_cond[fro-shared] +tests/test_usm_type.py::test_cond[fro-host] +tests/test_sycl_queue.py::test_norm[(0, 1)--2-cuda:gpu:0] +tests/test_sycl_queue.py::test_norm[(0, 1)-2-cuda:gpu:0] +tests/test_sycl_queue.py::test_norm[(0, 1)-"nuc"-cuda:gpu:0] +tests/test_sycl_queue.py::test_norm[(-2, -1)--2-cuda:gpu:0] +tests/test_sycl_queue.py::test_norm[(-2, -1)-2-cuda:gpu:0] +tests/test_sycl_queue.py::test_norm[(-2, -1)-"nuc"-cuda:gpu:0] +tests/test_sycl_queue.py::test_pinv[cuda:gpu:0-(2, 2, 3)] +tests/test_sycl_queue.py::test_pinv[cuda:gpu:0-(2, 2, 3), rcond_as_array] +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank2 +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank2_no_uv +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank3 +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank3_loop +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank3_no_uv +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank3_no_uv_loop +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank4 +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank4_loop +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank4_no_uv +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank4_no_uv_loop +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank2 +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank2_no_uv +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank3 +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank3_loop +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank3_no_uv +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank3_no_uv_loop +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank4 +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank4_loop +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank4_no_uv +tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank4_no_uv_loop +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_66_{axis=(0, 1), keepdims=True, ord=-2, shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_72_{axis=(0, 1), keepdims=True, ord=2, shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_78_{axis=(0, 1), keepdims=True, ord='nuc', shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_82_{axis=(0, 1), keepdims=False, ord=-2, shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_88_{axis=(0, 1), keepdims=False, ord=2, shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_94_{axis=(0, 1), keepdims=False, ord='nuc', shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_98_{axis=None, keepdims=True, ord=-2, shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_104_{axis=None, keepdims=True, ord=2, shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_110_{axis=None, keepdims=True, ord='nuc', shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_114_{axis=None, keepdims=False, ord=-2, shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_120_{axis=None, keepdims=False, ord=2, shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_126_{axis=None, keepdims=False, ord='nuc', shape=(1, 2)}::test_norm +tests/third_party/cupy/linalg_tests/test_solve.py::TestPinv::test_pinv +tests/third_party/cupy/linalg_tests/test_solve.py::TestPinv::test_pinv_batched +tests/third_party/cupy/linalg_tests/test_solve.py::TestPinv::test_pinv_batched_vector_rcond +tests/third_party/cupy/linalg_tests/test_solve.py::TestLstsq::test_lstsq_solutions + +# matmul +tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_cupy_matmul[shape10-shape20] +tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_cupy_matmul[shape11-shape21] +tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_operator_matmul[shape10-shape20] +tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_operator_matmul[shape11-shape21] + + +# NotImplementedError +# modf +tests/test_arithmetic.py::TestArithmetic::test_modf_part1 +tests/test_arithmetic.py::TestArithmetic::test_modf_part2 +tests/test_umath.py::test_umaths[('modf', 'f')] +tests/test_umath.py::test_umaths[('modf', 'd')] +tests/third_party/cupy/math_tests/test_arithmetic.py::TestArithmeticModf::test_modf +tests/test_sycl_queue.py::test_modf[cuda:gpu:0] + +# partition +tests/test_sort.py::test_partition[[3, 4, 2, 1]-bool_-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-bool_-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-int32-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-int32-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-int64-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-int64-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-float32-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-float32-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-float64-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-float64-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex64-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex64-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex128-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex128-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-bool_-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-bool_-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int32-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int32-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int64-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int64-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float32-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float32-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float64-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float64-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex64-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex64-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex128-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex128-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-bool_-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-bool_-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int32-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int32-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int64-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int64-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float32-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float32-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float64-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float64-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex64-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex64-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex128-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex128-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-bool_-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-bool_-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int32-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int32-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int64-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int64-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float32-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float32-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float64-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float64-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex64-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex64-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex128-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex128-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-bool_-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-bool_-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int32-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int32-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int64-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int64-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float32-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float32-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float64-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float64-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex64-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex64-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex128-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex128-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-bool_-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-bool_-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int32-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int32-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int64-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int64-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float32-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float32-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float64-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float64-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex64-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex64-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex128-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex128-1] +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_negative_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_negative_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_negative_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_non_contiguous +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_one_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_sequence_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_zero_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_negative_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_negative_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_negative_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_non_contiguous +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_one_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_sequence_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_zero_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_negative_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_negative_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_negative_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_non_contiguous +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_none_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_one_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_sequence_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_zero_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_negative_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_negative_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_negative_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_non_contiguous +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_none_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_one_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_sequence_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_zero_dim + +# erf +tests/test_special.py::test_erf +tests/test_special.py::test_erf_fallback +tests/test_strides.py::test_strides_erf[(10,)-int32] +tests/test_strides.py::test_strides_erf[(10,)-int64] +tests/test_strides.py::test_strides_erf[(10,)-float32] +tests/test_strides.py::test_strides_erf[(10,)-float64] +tests/test_strides.py::test_strides_erf[(10,)-None] + +# median +tests/test_statistics.py::test_median[2-int32] +tests/test_statistics.py::test_median[2-int64] +tests/test_statistics.py::test_median[2-float32] +tests/test_statistics.py::test_median[2-float64] +tests/test_statistics.py::test_median[4-int32] +tests/test_statistics.py::test_median[4-int64] +tests/test_statistics.py::test_median[4-float32] +tests/test_statistics.py::test_median[4-float64] +tests/test_statistics.py::test_median[8-int32] +tests/test_statistics.py::test_median[8-int64] +tests/test_statistics.py::test_median[8-float32] +tests/test_statistics.py::test_median[8-float64] +tests/test_statistics.py::test_median[16-int32] +tests/test_statistics.py::test_median[16-int64] +tests/test_statistics.py::test_median[16-float32] +tests/test_statistics.py::test_median[16-float64] +tests/test_statistics.py::test_median[3-int32] +tests/test_statistics.py::test_median[3-int64] +tests/test_statistics.py::test_median[3-float32] +tests/test_statistics.py::test_median[3-float64] +tests/test_statistics.py::test_median[9-int32] +tests/test_statistics.py::test_median[9-int64] +tests/test_statistics.py::test_median[9-float32] +tests/test_statistics.py::test_median[9-float64] +tests/test_statistics.py::test_median[27-int32] +tests/test_statistics.py::test_median[27-int64] +tests/test_statistics.py::test_median[27-float32] +tests/test_statistics.py::test_median[27-float64] +tests/test_statistics.py::test_median[81-int32] +tests/test_statistics.py::test_median[81-int64] +tests/test_statistics.py::test_median[81-float32] +tests/test_statistics.py::test_median[81-float64] +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_noaxis +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_axis1 +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_axis2 +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_overwrite_input +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_keepdims_axis1 +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_keepdims_noaxis +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_invalid_axis +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_0_{axis=(0, 1), keepdims=True, shape=(3, 4, 5)}] +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_1_{axis=(0, 1), keepdims=False, shape=(3, 4, 5)}] +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_2_{axis=(0, -1), keepdims=True, shape=(3, 4, 5)}] +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_3_{axis=(0, -1), keepdims=False, shape=(3, 4, 5)}] +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_4_{axis=(1, 2), keepdims=True, shape=(3, 4, 5)}] +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_5_{axis=(1, 2), keepdims=False, shape=(3, 4, 5)}] +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_6_{axis=(1,), keepdims=True, shape=(3, 4, 5)}] +tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_7_{axis=(1,), keepdims=False, shape=(3, 4, 5)}] + +# choose +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_broadcast +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_broadcast2 +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_broadcast_fail +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_clip +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_wrap +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_raise +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_unknown_clip + +# correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_0_{mode='valid', shape1=(5,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_1_{mode='valid', shape1=(5,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_2_{mode='valid', shape1=(5,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_3_{mode='valid', shape1=(5,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_4_{mode='valid', shape1=(6,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_5_{mode='valid', shape1=(6,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_6_{mode='valid', shape1=(6,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_7_{mode='valid', shape1=(6,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_8_{mode='valid', shape1=(20,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_9_{mode='valid', shape1=(20,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_10_{mode='valid', shape1=(20,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_11_{mode='valid', shape1=(20,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_12_{mode='valid', shape1=(21,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_13_{mode='valid', shape1=(21,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_14_{mode='valid', shape1=(21,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_15_{mode='valid', shape1=(21,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_16_{mode='same', shape1=(5,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_17_{mode='same', shape1=(5,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_18_{mode='same', shape1=(5,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_19_{mode='same', shape1=(5,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_20_{mode='same', shape1=(6,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_21_{mode='same', shape1=(6,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_22_{mode='same', shape1=(6,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_23_{mode='same', shape1=(6,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_24_{mode='same', shape1=(20,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_25_{mode='same', shape1=(20,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_26_{mode='same', shape1=(20,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_27_{mode='same', shape1=(20,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_28_{mode='same', shape1=(21,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_29_{mode='same', shape1=(21,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_30_{mode='same', shape1=(21,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_31_{mode='same', shape1=(21,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_32_{mode='full', shape1=(5,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_33_{mode='full', shape1=(5,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_34_{mode='full', shape1=(5,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_35_{mode='full', shape1=(5,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_36_{mode='full', shape1=(6,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_37_{mode='full', shape1=(6,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_38_{mode='full', shape1=(6,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_39_{mode='full', shape1=(6,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_40_{mode='full', shape1=(20,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_41_{mode='full', shape1=(20,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_42_{mode='full', shape1=(20,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_43_{mode='full', shape1=(20,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_44_{mode='full', shape1=(21,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_45_{mode='full', shape1=(21,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_46_{mode='full', shape1=(21,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_47_{mode='full', shape1=(21,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_0_{mode='valid'}::test_correlate_diff_types +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_0_{mode='valid'}::test_correlate_large_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_0_{mode='valid'}::test_correlate_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_1_{mode='full'}::test_correlate_diff_types +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_1_{mode='full'}::test_correlate_large_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_1_{mode='full'}::test_correlate_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_2_{mode='same'}::test_correlate_diff_types +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_2_{mode='same'}::test_correlate_large_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_2_{mode='same'}::test_correlate_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_0_{mode='valid'}::test_correlate_empty +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_0_{mode='valid'}::test_correlate_ndim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_0_{mode='valid'}::test_correlate_zero_dim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_1_{mode='same'}::test_correlate_empty +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_1_{mode='same'}::test_correlate_ndim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_1_{mode='same'}::test_correlate_zero_dim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_2_{mode='full'}::test_correlate_empty +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_2_{mode='full'}::test_correlate_ndim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_2_{mode='full'}::test_correlate_zero_dim + +#random +tests/test_random.py::test_input_size[chisquare] +tests/test_random.py::test_input_shape[chisquare] +tests/test_random.py::test_seed[random] +tests/test_random.py::test_seed[random_sample] +tests/test_random.py::test_randn_normal_distribution +tests/test_random.py::TestDistributionsBeta::test_moments +tests/test_random.py::TestDistributionsBeta::test_seed +tests/test_random.py::TestDistributionsBinomial::test_moments +tests/test_random.py::TestDistributionsBinomial::test_seed +tests/test_random.py::TestDistributionsChisquare::test_seed +tests/test_random.py::TestDistributionsExponential::test_seed +tests/test_random.py::TestDistributionsF::test_moments +tests/test_random.py::TestDistributionsF::test_seed +tests/test_random.py::TestDistributionsGamma::test_moments +tests/test_random.py::TestDistributionsGamma::test_seed +tests/test_random.py::TestDistributionsGeometric::test_moments +tests/test_random.py::TestDistributionsGeometric::test_seed +tests/test_random.py::TestDistributionsGumbel::test_moments +tests/test_random.py::TestDistributionsGumbel::test_seed +tests/test_random.py::TestDistributionsHypergeometric::test_moments +tests/test_random.py::TestDistributionsHypergeometric::test_seed +tests/test_random.py::TestDistributionsLaplace::test_moments +tests/test_random.py::TestDistributionsLaplace::test_seed +tests/test_random.py::TestDistributionsLogistic::test_moments +tests/test_random.py::TestDistributionsLogistic::test_seed +tests/test_random.py::TestDistributionsLognormal::test_moments +tests/test_random.py::TestDistributionsLognormal::test_seed +tests/test_random.py::TestDistributionsMultinomial::test_seed1 +tests/test_random.py::TestDistributionsNegativeBinomial::test_seed +tests/test_random.py::TestDistributionsNormal::test_moments +tests/test_random.py::TestDistributionsNoncentralChisquare::test_moments[df_grt_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_moments[df_eq_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_moments[df_less_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_seed[df_grt_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_seed[df_eq_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_seed[df_less_1] +tests/test_random.py::TestDistributionsPareto::test_moments +tests/test_random.py::TestDistributionsPareto::test_seed +tests/test_random.py::TestDistributionsPoisson::test_moments +tests/test_random.py::TestDistributionsPoisson::test_seed +tests/test_random.py::TestDistributionsPower::test_moments +tests/test_random.py::TestDistributionsPower::test_seed +tests/test_random.py::TestDistributionsRayleigh::test_moments +tests/test_random.py::TestDistributionsRayleigh::test_seed +tests/test_random.py::TestDistributionsStandardCauchy::test_seed +tests/test_random.py::TestDistributionsStandardExponential::test_moments +tests/test_random.py::TestDistributionsStandardExponential::test_seed +tests/test_random.py::TestDistributionsStandardGamma::test_moments +tests/test_random.py::TestDistributionsStandardNormal::test_moments +tests/test_random.py::TestDistributionsStandardT::test_moments +tests/test_random.py::TestDistributionsStandardT::test_seed +tests/test_random.py::TestDistributionsTriangular::test_moments +tests/test_random.py::TestDistributionsTriangular::test_seed +tests/test_random.py::TestDistributionsUniform::test_moments +tests/test_random.py::TestDistributionsVonmises::test_moments[large_kappa] +tests/test_random.py::TestDistributionsVonmises::test_moments[small_kappa] +tests/test_random.py::TestDistributionsVonmises::test_seed[large_kappa] +tests/test_random.py::TestDistributionsVonmises::test_seed[small_kappa] +tests/test_random.py::TestDistributionsWald::test_moments +tests/test_random.py::TestDistributionsWald::test_seed +tests/test_random.py::TestDistributionsWeibull::test_seed +tests/test_random.py::TestDistributionsZipf::test_seed +tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1[lambda x: dpnp.array([])] +tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1[lambda x: dpnp.astype(dpnp.asarray(x), dpnp.float32)] +tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1[lambda x: dpnp.asarray([[i, i] for i in x])] +tests/test_random_state.py::TestNormal::test_distr[host-float32] +tests/test_random_state.py::TestNormal::test_distr[host-float64] +tests/test_random_state.py::TestNormal::test_distr[host-None] +tests/test_random_state.py::TestNormal::test_distr[device-float32] +tests/test_random_state.py::TestNormal::test_distr[device-float64] +tests/test_random_state.py::TestNormal::test_distr[device-None] +tests/test_random_state.py::TestNormal::test_distr[shared-float32] +tests/test_random_state.py::TestNormal::test_distr[shared-float64] +tests/test_random_state.py::TestNormal::test_distr[shared-None] +tests/test_random_state.py::TestNormal::test_inf_loc[numpy.inf] +tests/test_random_state.py::TestNormal::test_inf_loc[-numpy.inf] +tests/test_random_state.py::TestNormal::test_inf_loc[nextafter(max, 0)] +tests/test_random_state.py::TestNormal::test_inf_loc[nextafter(min, 0)] +tests/test_random_state.py::TestNormal::test_inf_scale +tests/test_random_state.py::TestNormal::test_inf_loc_scale[numpy.inf] +tests/test_random_state.py::TestNormal::test_inf_loc_scale[-numpy.inf] +tests/test_random_state.py::TestRand::test_distr[host] +tests/test_random_state.py::TestRand::test_distr[device] +tests/test_random_state.py::TestRand::test_distr[shared] +tests/test_random_state.py::TestRandInt::test_distr[host-int] +tests/test_random_state.py::TestRandInt::test_distr[host-dpnp.int32] +tests/test_random_state.py::TestRandInt::test_distr[device-int] +tests/test_random_state.py::TestRandInt::test_distr[device-dpnp.int32] +tests/test_random_state.py::TestRandInt::test_distr[shared-int] +tests/test_random_state.py::TestRandInt::test_distr[shared-dpnp.int32] +tests/test_random_state.py::TestRandInt::test_float_bounds +tests/test_random_state.py::TestRandInt::test_negative_bounds +tests/test_random_state.py::TestRandInt::test_negative_interval +tests/test_random_state.py::TestRandInt::test_rng_zero_and_extremes +tests/test_random_state.py::TestRandInt::test_in_bounds_fuzz +tests/test_random_state.py::TestRandN::test_distr[host] +tests/test_random_state.py::TestRandN::test_distr[device] +tests/test_random_state.py::TestRandN::test_distr[shared] +tests/test_random_state.py::TestStandardNormal::test_distr[host] +tests/test_random_state.py::TestStandardNormal::test_distr[device] +tests/test_random_state.py::TestStandardNormal::test_distr[shared] +tests/test_random_state.py::TestRandSample::test_distr[host] +tests/test_random_state.py::TestRandSample::test_distr[device] +tests/test_random_state.py::TestRandSample::test_distr[shared] +tests/test_random_state.py::TestUniform::test_distr[host-float32-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[host-float32-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[host-float64-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[host-float64-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[host-int32-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[host-int32-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[host-None-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[host-None-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[device-float32-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[device-float32-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[device-float64-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[device-float64-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[device-int32-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[device-int32-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[device-None-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[device-None-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[shared-float32-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[shared-float32-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[shared-float64-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[shared-float64-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[shared-int32-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[shared-int32-(low, high)=[10.54, 1.23]] +tests/test_random_state.py::TestUniform::test_distr[shared-None-(low, high)=[1.23, 10.54]] +tests/test_random_state.py::TestUniform::test_distr[shared-None-(low, high)=[10.54, 1.23]] +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardCauchy_param_0_{shape=(4, 3, 2)}::test_standard_cauchy +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardCauchy_param_1_{shape=(3, 2)}::test_standard_cauchy +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardExponential_param_0_{shape=(4, 3, 2)}::test_standard_exponential +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardExponential_param_1_{shape=(3, 2)}::test_standard_exponential +tests/third_party/cupy/random_tests/test_sample.py::TestRandint::test_lo_hi_nonrandom +tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_1 +tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_2 +tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_float2 +tests/test_mathematical.py::TestUnwrap::test_rand[int64] +tests/test_random.py::test_check_output[random] +tests/test_random.py::test_check_output[random_sample] +tests/test_random.py::test_check_output[ranf] +tests/test_random.py::test_check_output[sample] +tests/test_random.py::test_seed[ranf] +tests/test_random.py::test_seed[sample] +tests/test_random.py::test_seed[rand] +tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_overflow +tests/test_random.py::test_check_output[rand] +tests/test_random.py::TestDistributionsNormal::test_seed +tests/test_random_state.py::TestSeed::test_scalar[normal] +tests/test_random_state.py::TestSeed::test_scalar[standard_normal] +tests/test_random_state.py::TestSeed::test_scalar[random_sample] +tests/test_random_state.py::TestSeed::test_scalar[uniform] +tests/third_party/cupy/math_tests/test_matmul.py::TestMatmul_param_18_{shape_pair=((1, 3, 2), (5, 2, 4))}::test_cupy_matmul +tests/third_party/cupy/math_tests/test_matmul.py::TestMatmul_param_28_{shape_pair=((3, 2), (6, 5, 2, 4))}::test_cupy_matmul +tests/third_party/cupy/math_tests/test_matmul.py::TestMatmul_param_28_{shape_pair=((3, 2), (6, 5, 2, 4))}::test_operator_matmul +tests/test_fft.py::TestFft::test_fft_inplace_out[0] +tests/test_fft.py::TestFft::test_fft_inplace_out[1] diff --git a/tests/test_sycl_queue.py b/tests/test_sycl_queue.py index c598d45c61e..e705f809ea3 100644 --- a/tests/test_sycl_queue.py +++ b/tests/test_sycl_queue.py @@ -39,6 +39,9 @@ for device in available_devices: if device.default_selector_score < 0: pass + elif device.backend.name in "cuda": + valid_devices = [device] + break elif device.backend.name not in list_of_backend_str: pass elif device.device_type.name not in list_of_device_type_str: From 5f1b08379fffb56e2a0c7640697c1a176c529e5a Mon Sep 17 00:00:00 2001 From: Natalia Polina Date: Tue, 24 Sep 2024 11:50:57 -0700 Subject: [PATCH 02/23] Apply fallback to numpy for all unsupported functions on cuda device. --- dpnp/dpnp_iface.py | 48 ++++++++++++++-------- dpnp/dpnp_iface_indexing.py | 4 +- dpnp/dpnp_iface_libmath.py | 4 +- dpnp/dpnp_iface_mathematical.py | 11 ++++-- dpnp/dpnp_iface_sorting.py | 4 +- dpnp/dpnp_iface_statistics.py | 8 ++-- dpnp/random/dpnp_iface_random.py | 68 +++++++++++++++++++++++++++++++- dpnp/random/dpnp_random_state.py | 9 +++++ tests/skipped_tests_cuda.tbl | 5 --- tests/test_fft.py | 4 +- 10 files changed, 125 insertions(+), 40 deletions(-) diff --git a/dpnp/dpnp_iface.py b/dpnp/dpnp_iface.py index 15802a470c6..a2f86783791 100644 --- a/dpnp/dpnp_iface.py +++ b/dpnp/dpnp_iface.py @@ -69,10 +69,10 @@ "get_normalized_queue_device", "get_result_array", "get_usm_ndarray", + "is_cuda_backend", "get_usm_ndarray_or_scalar", "is_supported_array_or_scalar", "is_supported_array_type", - "not_implemented_for_cuda_backend", "synchronize_array_data", ] @@ -758,6 +758,37 @@ def get_usm_ndarray_or_scalar(a): return a if dpnp.isscalar(a) else get_usm_ndarray(a) +def is_cuda_backend(obj=None): + """ + Checks that object has a cuda backend. + + Parameters + ---------- + obj : {Device, SyclDevice, SyclQueue, dpnp.ndarray, usm_ndarray, None}, + optional + An input object with sycl_device property to check device backend. + If obj is ``None``, device backend will be checked for the default + queue. + Default: ``None``. + + Returns + ------- + out : bool + Return ``True`` if object has a cuda backend, otherwise``False``. + + """ + + if obj is None: + sycl_device = dpctl.SyclQueue().sycl_device + elif isinstance(obj, dpctl.SyclDevice): + sycl_device = obj + else: + sycl_device = getattr(obj, "sycl_device", None) + if sycl_device is not None and "cuda" in sycl_device.backend.name: + return True + return False + + def is_supported_array_or_scalar(a): """ Return ``True`` if `a` is a scalar or an array of either @@ -801,21 +832,6 @@ def is_supported_array_type(a): return isinstance(a, (dpnp_array, dpt.usm_ndarray)) -def not_implemented_for_cuda_backend(obj): - """ - Raise NotImplementedError for cuda devices. - - Parameters - ---------- - obj : {SyclDevice, SyclQueue, dpnp.ndarray, usm_ndarray} - An input object with sycl_device property to check device backend. - - """ - sycl_device = getattr(obj, "sycl_device", None) - if sycl_device is not None and "cuda" in sycl_device.backend.name: - raise NotImplementedError("function not implemented for cuda backend") - - def synchronize_array_data(a): """ The dpctl interface was reworked to make asynchronous execution. diff --git a/dpnp/dpnp_iface_indexing.py b/dpnp/dpnp_iface_indexing.py index 148e8b86f6c..7fde25d897e 100644 --- a/dpnp/dpnp_iface_indexing.py +++ b/dpnp/dpnp_iface_indexing.py @@ -174,8 +174,6 @@ def choose(x1, choices, out=None, mode="raise"): """ - dpnp.not_implemented_for_cuda_backend(x1) - x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) choices_list = [] @@ -195,6 +193,8 @@ def choose(x1, choices, out=None, mode="raise"): pass elif not choices_list: pass + elif dpnp.is_cuda_backend(x1): + pass else: size = x1_desc.size choices_size = choices_list[0].size diff --git a/dpnp/dpnp_iface_libmath.py b/dpnp/dpnp_iface_libmath.py index b9e7e9daf69..3ce4201c039 100644 --- a/dpnp/dpnp_iface_libmath.py +++ b/dpnp/dpnp_iface_libmath.py @@ -78,12 +78,10 @@ def erf(in_array1): """ - dpnp.not_implemented_for_cuda_backend(in_array1) - x1_desc = dpnp.get_dpnp_descriptor( in_array1, copy_when_strides=False, copy_when_nondefault_queue=False ) - if x1_desc: + if x1_desc and dpnp.is_cuda_backend(in_array1): return dpnp_erf(x1_desc).get_pyobj() result = create_output_descriptor_py( diff --git a/dpnp/dpnp_iface_mathematical.py b/dpnp/dpnp_iface_mathematical.py index d3809610518..e267c9cdbbf 100644 --- a/dpnp/dpnp_iface_mathematical.py +++ b/dpnp/dpnp_iface_mathematical.py @@ -2477,11 +2477,14 @@ def modf(x1, **kwargs): """ - dpnp.not_implemented_for_cuda_backend(x1) - x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) - if x1_desc and not kwargs: - return dpnp_modf(x1_desc) + if x1_desc: + if not kwargs: + pass + elif dpnp.is_cuda_backend(x1): + pass + else: + return dpnp_modf(x1_desc) return call_origin(numpy.modf, x1, **kwargs) diff --git a/dpnp/dpnp_iface_sorting.py b/dpnp/dpnp_iface_sorting.py index 1ae92bddf2b..16533fb1a27 100644 --- a/dpnp/dpnp_iface_sorting.py +++ b/dpnp/dpnp_iface_sorting.py @@ -174,8 +174,6 @@ def partition(x1, kth, axis=-1, kind="introselect", order=None): """ - dpnp.not_implemented_for_cuda_backend(x1) - x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) if x1_desc: if not isinstance(kth, int): @@ -190,6 +188,8 @@ def partition(x1, kth, axis=-1, kind="introselect", order=None): pass elif order is not None: pass + elif dpnp.is_cuda_backend(x1): + pass else: return dpnp_partition(x1_desc, kth, axis, kind, order).get_pyobj() diff --git a/dpnp/dpnp_iface_statistics.py b/dpnp/dpnp_iface_statistics.py index 00bf5c47e72..38f2f7ec796 100644 --- a/dpnp/dpnp_iface_statistics.py +++ b/dpnp/dpnp_iface_statistics.py @@ -371,8 +371,6 @@ def correlate(x1, x2, mode="valid"): """ - dpnp.not_implemented_for_cuda_backend(x1) - x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) x2_desc = dpnp.get_dpnp_descriptor(x2, copy_when_nondefault_queue=False) if x1_desc and x2_desc: @@ -382,6 +380,8 @@ def correlate(x1, x2, mode="valid"): pass elif mode != "valid": pass + elif dpnp.is_cuda_backend(x1) or dpnp.is_cuda_backend(x2): + pass else: return dpnp_correlate(x1_desc, x2_desc).get_pyobj() @@ -657,8 +657,6 @@ def median(x1, axis=None, out=None, overwrite_input=False, keepdims=False): """ - dpnp.not_implemented_for_cuda_backend(x1) - x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) if x1_desc: if axis is not None: @@ -669,6 +667,8 @@ def median(x1, axis=None, out=None, overwrite_input=False, keepdims=False): pass elif keepdims: pass + elif dpnp.is_cuda_backend(x1): + pass else: result_obj = dpnp_median(x1_desc).get_pyobj() result = dpnp.convert_single_elem_array_to_scalar(result_obj) diff --git a/dpnp/random/dpnp_iface_random.py b/dpnp/random/dpnp_iface_random.py index 49d2adad2c2..ee4af1df25d 100644 --- a/dpnp/random/dpnp_iface_random.py +++ b/dpnp/random/dpnp_iface_random.py @@ -150,6 +150,8 @@ def beta(a, b, size=None): pass elif b <= 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_beta(a, b, size).get_pyobj() @@ -196,6 +198,8 @@ def binomial(n, p, size=None): pass elif n < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_binomial(int(n), p, size).get_pyobj() @@ -244,6 +248,8 @@ def chisquare(df, size=None): pass elif df <= 0: pass + elif dpnp.is_cuda_backend(): + pass else: # TODO: # float to int, safe @@ -312,6 +318,8 @@ def exponential(scale=1.0, size=None): pass elif scale < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_exponential(scale, size).get_pyobj() @@ -348,6 +356,8 @@ def f(dfnum, dfden, size=None): pass elif dfden <= 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_f(dfnum, dfden, size).get_pyobj() @@ -386,6 +396,8 @@ def gamma(shape, scale=1.0, size=None): pass elif shape < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_gamma(shape, scale, size).get_pyobj() @@ -420,6 +432,8 @@ def geometric(p, size=None): pass elif p > 1 or p <= 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_geometric(p, size).get_pyobj() @@ -456,6 +470,8 @@ def gumbel(loc=0.0, scale=1.0, size=None): pass elif scale < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_gumbel(loc, scale, size).get_pyobj() @@ -504,6 +520,8 @@ def hypergeometric(ngood, nbad, nsample, size=None): pass elif nsample < 1: pass + elif dpnp.is_cuda_backend(): + pass else: _m = int(ngood) _l = int(ngood) + int(nbad) @@ -542,6 +560,8 @@ def laplace(loc=0.0, scale=1.0, size=None): pass elif scale < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_laplace(loc, scale, size).get_pyobj() @@ -576,6 +596,8 @@ def logistic(loc=0.0, scale=1.0, size=None): pass elif scale < 0: pass + elif dpnp.is_cuda_backend(): + pass else: result = dpnp_rng_logistic(loc, scale, size).get_pyobj() if size is None or size == 1: @@ -617,6 +639,8 @@ def lognormal(mean=0.0, sigma=1.0, size=None): pass elif sigma < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_lognormal(mean, sigma, size).get_pyobj() @@ -674,6 +698,8 @@ def multinomial(n, pvals, size=None): pass elif pvals_sum < 0.0: pass + elif dpnp.is_cuda_backend(): + pass else: if size is None: shape = (d,) @@ -725,6 +751,8 @@ def multivariate_normal(mean, cov, size=None, check_valid="warn", tol=1e-8): pass elif mean_.shape[0] != cov_.shape[0]: pass + elif dpnp.is_cuda_backend(): + pass else: final_shape = list(shape[:]) final_shape.append(mean_.shape[0]) @@ -777,6 +805,8 @@ def negative_binomial(n, p, size=None): pass elif n <= 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_negative_binomial(n, p, size).get_pyobj() @@ -862,6 +892,8 @@ def noncentral_chisquare(df, nonc, size=None): pass elif nonc < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_noncentral_chisquare(df, nonc, size).get_pyobj() @@ -912,6 +944,8 @@ def pareto(a, size=None): pass elif a <= 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_pareto(a, size).get_pyobj() @@ -981,6 +1015,8 @@ def poisson(lam=1.0, size=None): pass elif lam < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_poisson(lam, size).get_pyobj() @@ -1016,6 +1052,8 @@ def power(a, size=None): pass elif a <= 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_power(a, size).get_pyobj() @@ -1423,6 +1461,8 @@ def rayleigh(scale=1.0, size=None): pass elif scale < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_rayleigh(scale, size).get_pyobj() @@ -1495,6 +1535,8 @@ def shuffle(x1): if x1_desc: if not dpnp.is_type_supported(x1_desc.dtype): pass + elif dpnp.is_cuda_backend(x1): + pass else: dpnp_rng_shuffle(x1_desc).get_pyobj() return @@ -1545,6 +1587,8 @@ def seed(seed=None, device=None, sycl_queue=None): pass elif seed < 0: pass + elif dpnp.is_cuda_backend(): + pass else: # TODO: # migrate to a single approach with RandomState class @@ -1577,7 +1621,10 @@ def standard_cauchy(size=None): """ if not use_origin_backend(size): - return dpnp_rng_standard_cauchy(size).get_pyobj() + if dpnp.is_cuda_backend(): + pass + else: + return dpnp_rng_standard_cauchy(size).get_pyobj() return call_origin(numpy.random.standard_cauchy, size) @@ -1602,7 +1649,10 @@ def standard_exponential(size=None): """ if not use_origin_backend(size): - return dpnp_rng_standard_exponential(size).get_pyobj() + if dpnp.is_cuda_backend(): + pass + else: + return dpnp_rng_standard_exponential(size).get_pyobj() return call_origin(numpy.random.standard_exponential, size) @@ -1636,6 +1686,8 @@ def standard_gamma(shape, size=None): pass elif shape < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_standard_gamma(shape, size).get_pyobj() @@ -1714,6 +1766,8 @@ def standard_t(df, size=None): pass elif df <= 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_standard_t(df, size).get_pyobj() @@ -1758,6 +1812,8 @@ def triangular(left, mode, right, size=None): pass elif left == right: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_triangular(left, mode, right, size).get_pyobj() @@ -1862,6 +1918,8 @@ def vonmises(mu, kappa, size=None): return dpnp.nan elif kappa < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_vonmises(mu, kappa, size).get_pyobj() @@ -1898,6 +1956,8 @@ def wald(mean, scale, size=None): pass elif scale <= 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_wald(mean, scale, size).get_pyobj() @@ -1930,6 +1990,8 @@ def weibull(a, size=None): pass elif a < 0: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_weibull(a, size).get_pyobj() @@ -1962,6 +2024,8 @@ def zipf(a, size=None): pass elif a <= 1: pass + elif dpnp.is_cuda_backend(): + pass else: return dpnp_rng_zipf(a, size).get_pyobj() diff --git a/dpnp/random/dpnp_random_state.py b/dpnp/random/dpnp_random_state.py index 21bafdd9194..0da54c57c61 100644 --- a/dpnp/random/dpnp_random_state.py +++ b/dpnp/random/dpnp_random_state.py @@ -81,6 +81,9 @@ def __init__(self, seed=None, device=None, sycl_queue=None): self._sycl_queue = dpnp.get_normalized_queue_device( device=device, sycl_queue=sycl_queue ) + + dpnp.not_implemented_for_cuda_backend(self._sycl_queue) + self._sycl_device = self._sycl_queue.sycl_device is_cpu = self._sycl_device.is_cpu @@ -238,6 +241,8 @@ def normal( pass elif not dpnp.isscalar(scale): pass + elif dpnp.is_cuda_backend(): + pass else: dtype = self._validate_float_dtype( dtype, (dpnp.float32, dpnp.float64) @@ -367,6 +372,8 @@ def randint(self, low, high=None, size=None, dtype=int, usm_type="device"): pass elif not (high is None or dpnp.isscalar(high)): pass + elif dpnp.is_cuda_backend(): + pass else: _dtype = dpnp.int32 if dtype is int else dpnp.dtype(dtype) if _dtype != dpnp.int32: @@ -591,6 +598,8 @@ def uniform( pass elif not dpnp.isscalar(high): pass + elif dpnp.is_cuda_backend(): + pass else: min_double = dpnp.finfo("double").min max_double = dpnp.finfo("double").max diff --git a/tests/skipped_tests_cuda.tbl b/tests/skipped_tests_cuda.tbl index 9762232f585..d6f7d74bec5 100644 --- a/tests/skipped_tests_cuda.tbl +++ b/tests/skipped_tests_cuda.tbl @@ -813,8 +813,3 @@ tests/test_random_state.py::TestSeed::test_scalar[normal] tests/test_random_state.py::TestSeed::test_scalar[standard_normal] tests/test_random_state.py::TestSeed::test_scalar[random_sample] tests/test_random_state.py::TestSeed::test_scalar[uniform] -tests/third_party/cupy/math_tests/test_matmul.py::TestMatmul_param_18_{shape_pair=((1, 3, 2), (5, 2, 4))}::test_cupy_matmul -tests/third_party/cupy/math_tests/test_matmul.py::TestMatmul_param_28_{shape_pair=((3, 2), (6, 5, 2, 4))}::test_cupy_matmul -tests/third_party/cupy/math_tests/test_matmul.py::TestMatmul_param_28_{shape_pair=((3, 2), (6, 5, 2, 4))}::test_operator_matmul -tests/test_fft.py::TestFft::test_fft_inplace_out[0] -tests/test_fft.py::TestFft::test_fft_inplace_out[1] diff --git a/tests/test_fft.py b/tests/test_fft.py index c6f33fb71f7..4351892bb3b 100644 --- a/tests/test_fft.py +++ b/tests/test_fft.py @@ -197,8 +197,8 @@ def test_fft_1D_out(self, dtype, n, norm): @pytest.mark.parametrize("axis", [0, 1]) def test_fft_inplace_out(self, axis): # Test some weirder in-place combinations - y = dpnp.random.rand(20, 20) + 1j * dpnp.random.rand(20, 20) - y_np = y.asnumpy() + y_np = numpy.random.rand(20, 20) + 1j * numpy.random.rand(20, 20) + y = dpnp.asarray(y_np) # Fully in-place. y1 = y.copy() expected1 = numpy.fft.fft(y1.asnumpy(), axis=axis) From fe8fe114692b84f93bdd22c7a25ee6cd314c2aeb Mon Sep 17 00:00:00 2001 From: Natalia Polina Date: Wed, 25 Sep 2024 01:40:10 -0700 Subject: [PATCH 03/23] update tests --- dpnp/dpnp_iface_libmath.py | 2 +- dpnp/random/dpnp_random_state.py | 2 - tests/skipped_tests_cuda.tbl | 512 +++++------------- tests/test_arithmetic.py | 3 + tests/test_indexing.py | 2 +- tests/test_logic.py | 7 +- tests/test_random.py | 11 + tests/test_sort.py | 1 + tests/test_statistics.py | 1 + tests/test_sycl_queue.py | 1 + .../cupy/core_tests/test_dlpack.py | 18 +- .../cupy/indexing_tests/test_indexing.py | 8 +- .../cupy/linalg_tests/test_solve.py | 18 +- .../cupy/math_tests/test_arithmetic.py | 1 + .../cupy/random_tests/test_distributions.py | 3 + .../cupy/random_tests/test_sample.py | 8 +- .../cupy/statistics_tests/test_histogram.py | 2 +- .../cupy/statistics_tests/test_meanvar.py | 7 +- 18 files changed, 186 insertions(+), 421 deletions(-) diff --git a/dpnp/dpnp_iface_libmath.py b/dpnp/dpnp_iface_libmath.py index 3ce4201c039..e726d1b0172 100644 --- a/dpnp/dpnp_iface_libmath.py +++ b/dpnp/dpnp_iface_libmath.py @@ -81,7 +81,7 @@ def erf(in_array1): x1_desc = dpnp.get_dpnp_descriptor( in_array1, copy_when_strides=False, copy_when_nondefault_queue=False ) - if x1_desc and dpnp.is_cuda_backend(in_array1): + if x1_desc and not dpnp.is_cuda_backend(in_array1): return dpnp_erf(x1_desc).get_pyobj() result = create_output_descriptor_py( diff --git a/dpnp/random/dpnp_random_state.py b/dpnp/random/dpnp_random_state.py index 0da54c57c61..5425f8f820d 100644 --- a/dpnp/random/dpnp_random_state.py +++ b/dpnp/random/dpnp_random_state.py @@ -82,8 +82,6 @@ def __init__(self, seed=None, device=None, sycl_queue=None): device=device, sycl_queue=sycl_queue ) - dpnp.not_implemented_for_cuda_backend(self._sycl_queue) - self._sycl_device = self._sycl_queue.sycl_device is_cpu = self._sycl_device.is_cpu diff --git a/tests/skipped_tests_cuda.tbl b/tests/skipped_tests_cuda.tbl index d6f7d74bec5..377cfe57ac3 100644 --- a/tests/skipped_tests_cuda.tbl +++ b/tests/skipped_tests_cuda.tbl @@ -1,4 +1,3 @@ -# FAILED # fft tests/test_fft.py::TestFftn::test_fftn[C-forward-None-complex64] tests/test_fft.py::TestFftn::test_fftn[C-forward-None-complex128] @@ -375,367 +374,25 @@ tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch:: tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_operator_matmul[shape10-shape20] tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_operator_matmul[shape11-shape21] - -# NotImplementedError -# modf -tests/test_arithmetic.py::TestArithmetic::test_modf_part1 -tests/test_arithmetic.py::TestArithmetic::test_modf_part2 -tests/test_umath.py::test_umaths[('modf', 'f')] -tests/test_umath.py::test_umaths[('modf', 'd')] -tests/third_party/cupy/math_tests/test_arithmetic.py::TestArithmeticModf::test_modf -tests/test_sycl_queue.py::test_modf[cuda:gpu:0] - -# partition -tests/test_sort.py::test_partition[[3, 4, 2, 1]-bool_-0] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-bool_-1] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-int32-0] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-int32-1] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-int64-0] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-int64-1] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-float32-0] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-float32-1] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-float64-0] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-float64-1] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex64-0] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex64-1] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex128-0] -tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex128-1] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-bool_-0] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-bool_-1] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int32-0] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int32-1] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int64-0] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int64-1] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float32-0] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float32-1] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float64-0] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float64-1] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex64-0] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex64-1] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex128-0] -tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex128-1] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-bool_-0] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-bool_-1] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int32-0] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int32-1] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int64-0] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int64-1] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float32-0] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float32-1] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float64-0] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float64-1] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex64-0] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex64-1] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex128-0] -tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex128-1] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-bool_-0] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-bool_-1] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int32-0] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int32-1] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int64-0] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int64-1] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float32-0] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float32-1] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float64-0] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float64-1] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex64-0] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex64-1] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex128-0] -tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex128-1] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-bool_-0] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-bool_-1] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int32-0] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int32-1] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int64-0] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int64-1] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float32-0] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float32-1] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float64-0] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float64-1] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex64-0] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex64-1] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex128-0] -tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex128-1] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-bool_-0] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-bool_-1] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int32-0] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int32-1] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int64-0] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int64-1] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float32-0] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float32-1] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float64-0] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float64-1] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex64-0] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex64-1] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex128-0] -tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex128-1] -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_axis1 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_axis2 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_negative_axis1 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_negative_axis2 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_negative_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_negative_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_negative_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_non_contiguous -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_one_dim -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_sequence_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_zero_dim -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_axis1 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_axis2 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_negative_axis1 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_negative_axis2 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_negative_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_negative_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_negative_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_non_contiguous -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_one_dim -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_sequence_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_zero_dim -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_axis1 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_axis2 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_negative_axis1 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_negative_axis2 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_negative_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_negative_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_negative_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_non_contiguous -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_none_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_one_dim -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_sequence_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_zero_dim -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_axis1 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_axis2 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_negative_axis1 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_negative_axis2 -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_negative_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_negative_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_negative_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_non_contiguous -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_none_axis -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_one_dim -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_sequence_kth -tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_zero_dim - -# erf -tests/test_special.py::test_erf -tests/test_special.py::test_erf_fallback -tests/test_strides.py::test_strides_erf[(10,)-int32] -tests/test_strides.py::test_strides_erf[(10,)-int64] -tests/test_strides.py::test_strides_erf[(10,)-float32] -tests/test_strides.py::test_strides_erf[(10,)-float64] -tests/test_strides.py::test_strides_erf[(10,)-None] - -# median -tests/test_statistics.py::test_median[2-int32] -tests/test_statistics.py::test_median[2-int64] -tests/test_statistics.py::test_median[2-float32] -tests/test_statistics.py::test_median[2-float64] -tests/test_statistics.py::test_median[4-int32] -tests/test_statistics.py::test_median[4-int64] -tests/test_statistics.py::test_median[4-float32] -tests/test_statistics.py::test_median[4-float64] -tests/test_statistics.py::test_median[8-int32] -tests/test_statistics.py::test_median[8-int64] -tests/test_statistics.py::test_median[8-float32] -tests/test_statistics.py::test_median[8-float64] -tests/test_statistics.py::test_median[16-int32] -tests/test_statistics.py::test_median[16-int64] -tests/test_statistics.py::test_median[16-float32] -tests/test_statistics.py::test_median[16-float64] -tests/test_statistics.py::test_median[3-int32] -tests/test_statistics.py::test_median[3-int64] -tests/test_statistics.py::test_median[3-float32] -tests/test_statistics.py::test_median[3-float64] -tests/test_statistics.py::test_median[9-int32] -tests/test_statistics.py::test_median[9-int64] -tests/test_statistics.py::test_median[9-float32] -tests/test_statistics.py::test_median[9-float64] -tests/test_statistics.py::test_median[27-int32] -tests/test_statistics.py::test_median[27-int64] -tests/test_statistics.py::test_median[27-float32] -tests/test_statistics.py::test_median[27-float64] -tests/test_statistics.py::test_median[81-int32] -tests/test_statistics.py::test_median[81-int64] -tests/test_statistics.py::test_median[81-float32] -tests/test_statistics.py::test_median[81-float64] -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_noaxis -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_axis1 -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_axis2 -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_overwrite_input -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_keepdims_axis1 -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_keepdims_noaxis -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedian::test_median_invalid_axis -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_0_{axis=(0, 1), keepdims=True, shape=(3, 4, 5)}] -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_1_{axis=(0, 1), keepdims=False, shape=(3, 4, 5)}] -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_2_{axis=(0, -1), keepdims=True, shape=(3, 4, 5)}] -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_3_{axis=(0, -1), keepdims=False, shape=(3, 4, 5)}] -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_4_{axis=(1, 2), keepdims=True, shape=(3, 4, 5)}] -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_5_{axis=(1, 2), keepdims=False, shape=(3, 4, 5)}] -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_6_{axis=(1,), keepdims=True, shape=(3, 4, 5)}] -tests/third_party/cupy/statistics_tests/test_meanvar.py::TestMedianAxis::test_median_axis_sequence[_param_7_{axis=(1,), keepdims=False, shape=(3, 4, 5)}] - -# choose -tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose -tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_broadcast -tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_broadcast2 -tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_broadcast_fail -tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_clip -tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_wrap -tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_raise -tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_unknown_clip - -# correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_0_{mode='valid', shape1=(5,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_1_{mode='valid', shape1=(5,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_2_{mode='valid', shape1=(5,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_3_{mode='valid', shape1=(5,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_4_{mode='valid', shape1=(6,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_5_{mode='valid', shape1=(6,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_6_{mode='valid', shape1=(6,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_7_{mode='valid', shape1=(6,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_8_{mode='valid', shape1=(20,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_9_{mode='valid', shape1=(20,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_10_{mode='valid', shape1=(20,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_11_{mode='valid', shape1=(20,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_12_{mode='valid', shape1=(21,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_13_{mode='valid', shape1=(21,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_14_{mode='valid', shape1=(21,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_15_{mode='valid', shape1=(21,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_16_{mode='same', shape1=(5,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_17_{mode='same', shape1=(5,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_18_{mode='same', shape1=(5,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_19_{mode='same', shape1=(5,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_20_{mode='same', shape1=(6,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_21_{mode='same', shape1=(6,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_22_{mode='same', shape1=(6,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_23_{mode='same', shape1=(6,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_24_{mode='same', shape1=(20,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_25_{mode='same', shape1=(20,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_26_{mode='same', shape1=(20,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_27_{mode='same', shape1=(20,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_28_{mode='same', shape1=(21,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_29_{mode='same', shape1=(21,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_30_{mode='same', shape1=(21,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_31_{mode='same', shape1=(21,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_32_{mode='full', shape1=(5,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_33_{mode='full', shape1=(5,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_34_{mode='full', shape1=(5,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_35_{mode='full', shape1=(5,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_36_{mode='full', shape1=(6,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_37_{mode='full', shape1=(6,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_38_{mode='full', shape1=(6,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_39_{mode='full', shape1=(6,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_40_{mode='full', shape1=(20,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_41_{mode='full', shape1=(20,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_42_{mode='full', shape1=(20,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_43_{mode='full', shape1=(20,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_44_{mode='full', shape1=(21,), shape2=(5,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_45_{mode='full', shape1=(21,), shape2=(6,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_46_{mode='full', shape1=(21,), shape2=(20,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_47_{mode='full', shape1=(21,), shape2=(21,)}::test_correlate -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_0_{mode='valid'}::test_correlate_diff_types -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_0_{mode='valid'}::test_correlate_large_non_contiguous -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_0_{mode='valid'}::test_correlate_non_contiguous -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_1_{mode='full'}::test_correlate_diff_types -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_1_{mode='full'}::test_correlate_large_non_contiguous -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_1_{mode='full'}::test_correlate_non_contiguous -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_2_{mode='same'}::test_correlate_diff_types -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_2_{mode='same'}::test_correlate_large_non_contiguous -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_2_{mode='same'}::test_correlate_non_contiguous -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_0_{mode='valid'}::test_correlate_empty -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_0_{mode='valid'}::test_correlate_ndim -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_0_{mode='valid'}::test_correlate_zero_dim -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_1_{mode='same'}::test_correlate_empty -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_1_{mode='same'}::test_correlate_ndim -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_1_{mode='same'}::test_correlate_zero_dim -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_2_{mode='full'}::test_correlate_empty -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_2_{mode='full'}::test_correlate_ndim -tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_2_{mode='full'}::test_correlate_zero_dim - -#random -tests/test_random.py::test_input_size[chisquare] -tests/test_random.py::test_input_shape[chisquare] -tests/test_random.py::test_seed[random] -tests/test_random.py::test_seed[random_sample] -tests/test_random.py::test_randn_normal_distribution -tests/test_random.py::TestDistributionsBeta::test_moments -tests/test_random.py::TestDistributionsBeta::test_seed -tests/test_random.py::TestDistributionsBinomial::test_moments -tests/test_random.py::TestDistributionsBinomial::test_seed -tests/test_random.py::TestDistributionsChisquare::test_seed -tests/test_random.py::TestDistributionsExponential::test_seed -tests/test_random.py::TestDistributionsF::test_moments -tests/test_random.py::TestDistributionsF::test_seed -tests/test_random.py::TestDistributionsGamma::test_moments -tests/test_random.py::TestDistributionsGamma::test_seed -tests/test_random.py::TestDistributionsGeometric::test_moments -tests/test_random.py::TestDistributionsGeometric::test_seed -tests/test_random.py::TestDistributionsGumbel::test_moments -tests/test_random.py::TestDistributionsGumbel::test_seed -tests/test_random.py::TestDistributionsHypergeometric::test_moments -tests/test_random.py::TestDistributionsHypergeometric::test_seed -tests/test_random.py::TestDistributionsLaplace::test_moments -tests/test_random.py::TestDistributionsLaplace::test_seed -tests/test_random.py::TestDistributionsLogistic::test_moments -tests/test_random.py::TestDistributionsLogistic::test_seed -tests/test_random.py::TestDistributionsLognormal::test_moments -tests/test_random.py::TestDistributionsLognormal::test_seed -tests/test_random.py::TestDistributionsMultinomial::test_seed1 -tests/test_random.py::TestDistributionsNegativeBinomial::test_seed -tests/test_random.py::TestDistributionsNormal::test_moments -tests/test_random.py::TestDistributionsNoncentralChisquare::test_moments[df_grt_1] -tests/test_random.py::TestDistributionsNoncentralChisquare::test_moments[df_eq_1] -tests/test_random.py::TestDistributionsNoncentralChisquare::test_moments[df_less_1] -tests/test_random.py::TestDistributionsNoncentralChisquare::test_seed[df_grt_1] -tests/test_random.py::TestDistributionsNoncentralChisquare::test_seed[df_eq_1] -tests/test_random.py::TestDistributionsNoncentralChisquare::test_seed[df_less_1] -tests/test_random.py::TestDistributionsPareto::test_moments -tests/test_random.py::TestDistributionsPareto::test_seed -tests/test_random.py::TestDistributionsPoisson::test_moments -tests/test_random.py::TestDistributionsPoisson::test_seed -tests/test_random.py::TestDistributionsPower::test_moments -tests/test_random.py::TestDistributionsPower::test_seed -tests/test_random.py::TestDistributionsRayleigh::test_moments -tests/test_random.py::TestDistributionsRayleigh::test_seed -tests/test_random.py::TestDistributionsStandardCauchy::test_seed -tests/test_random.py::TestDistributionsStandardExponential::test_moments -tests/test_random.py::TestDistributionsStandardExponential::test_seed -tests/test_random.py::TestDistributionsStandardGamma::test_moments -tests/test_random.py::TestDistributionsStandardNormal::test_moments -tests/test_random.py::TestDistributionsStandardT::test_moments -tests/test_random.py::TestDistributionsStandardT::test_seed -tests/test_random.py::TestDistributionsTriangular::test_moments -tests/test_random.py::TestDistributionsTriangular::test_seed -tests/test_random.py::TestDistributionsUniform::test_moments -tests/test_random.py::TestDistributionsVonmises::test_moments[large_kappa] -tests/test_random.py::TestDistributionsVonmises::test_moments[small_kappa] -tests/test_random.py::TestDistributionsVonmises::test_seed[large_kappa] -tests/test_random.py::TestDistributionsVonmises::test_seed[small_kappa] -tests/test_random.py::TestDistributionsWald::test_moments -tests/test_random.py::TestDistributionsWald::test_seed -tests/test_random.py::TestDistributionsWeibull::test_seed -tests/test_random.py::TestDistributionsZipf::test_seed -tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1[lambda x: dpnp.array([])] -tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1[lambda x: dpnp.astype(dpnp.asarray(x), dpnp.float32)] -tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1[lambda x: dpnp.asarray([[i, i] for i in x])] +# random state tests/test_random_state.py::TestNormal::test_distr[host-float32] tests/test_random_state.py::TestNormal::test_distr[host-float64] tests/test_random_state.py::TestNormal::test_distr[host-None] tests/test_random_state.py::TestNormal::test_distr[device-float32] -tests/test_random_state.py::TestNormal::test_distr[device-float64] +tests/test_random_state.py::TestNormal::test_distr[device-float64] tests/test_random_state.py::TestNormal::test_distr[device-None] tests/test_random_state.py::TestNormal::test_distr[shared-float32] tests/test_random_state.py::TestNormal::test_distr[shared-float64] tests/test_random_state.py::TestNormal::test_distr[shared-None] +tests/test_random_state.py::TestNormal::test_scale[host-float32] +tests/test_random_state.py::TestNormal::test_scale[host-float64] +tests/test_random_state.py::TestNormal::test_scale[host-None] +tests/test_random_state.py::TestNormal::test_scale[device-float32] +tests/test_random_state.py::TestNormal::test_scale[device-float64] +tests/test_random_state.py::TestNormal::test_scale[device-None] +tests/test_random_state.py::TestNormal::test_scale[shared-float32] +tests/test_random_state.py::TestNormal::test_scale[shared-float64] +tests/test_random_state.py::TestNormal::test_scale[shared-None] tests/test_random_state.py::TestNormal::test_inf_loc[numpy.inf] tests/test_random_state.py::TestNormal::test_inf_loc[-numpy.inf] tests/test_random_state.py::TestNormal::test_inf_loc[nextafter(max, 0)] @@ -743,29 +400,65 @@ tests/test_random_state.py::TestNormal::test_inf_loc[nextafter(min, 0)] tests/test_random_state.py::TestNormal::test_inf_scale tests/test_random_state.py::TestNormal::test_inf_loc_scale[numpy.inf] tests/test_random_state.py::TestNormal::test_inf_loc_scale[-numpy.inf] +tests/test_random_state.py::TestNormal::test_extreme_bounds +tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.float16] +tests/test_random_state.py::TestNormal::test_invalid_dtype[float] +tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.int64] +tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.int32] +tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.int] +tests/test_random_state.py::TestNormal::test_invalid_dtype[int] +tests/test_random_state.py::TestNormal::test_invalid_dtype[numpy.clongdouble] +tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.complex128] +tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.complex64] +tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.bool] +tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.bool_] +tests/test_random_state.py::TestNormal::test_invalid_usm_type[Empty] +tests/test_random_state.py::TestNormal::test_invalid_usm_type[Unknown] tests/test_random_state.py::TestRand::test_distr[host] tests/test_random_state.py::TestRand::test_distr[device] tests/test_random_state.py::TestRand::test_distr[shared] +tests/test_random_state.py::TestRand::test_zero_dims[(0,)] +tests/test_random_state.py::TestRand::test_zero_dims[(3, 0)] +tests/test_random_state.py::TestRand::test_zero_dims[(3, 0, 10)] +tests/test_random_state.py::TestRand::test_zero_dims[()] +tests/test_random_state.py::TestRand::test_wrong_dims tests/test_random_state.py::TestRandInt::test_distr[host-int] tests/test_random_state.py::TestRandInt::test_distr[host-dpnp.int32] tests/test_random_state.py::TestRandInt::test_distr[device-int] tests/test_random_state.py::TestRandInt::test_distr[device-dpnp.int32] tests/test_random_state.py::TestRandInt::test_distr[shared-int] tests/test_random_state.py::TestRandInt::test_distr[shared-dpnp.int32] -tests/test_random_state.py::TestRandInt::test_float_bounds +tests/test_random_state.py::TestRandInt::test_float_bounds randint tests/test_random_state.py::TestRandInt::test_negative_bounds tests/test_random_state.py::TestRandInt::test_negative_interval +tests/test_random_state.py::TestRandInt::test_bounds_checking tests/test_random_state.py::TestRandInt::test_rng_zero_and_extremes -tests/test_random_state.py::TestRandInt::test_in_bounds_fuzz +tests/test_random_state.py::TestRandInt::test_zero_size[(3, 0, 4)] +tests/test_random_state.py::TestRandInt::test_zero_size[0] +tests/test_random_state.py::TestRandInt::test_zero_size[(0,)] +tests/test_random_state.py::TestRandInt::test_zero_size[()] +tests/test_random_state.py::TestRandInt::test_invalid_usm_type[Empty] +tests/test_random_state.py::TestRandInt::test_invalid_usm_type[Unknown] tests/test_random_state.py::TestRandN::test_distr[host] tests/test_random_state.py::TestRandN::test_distr[device] tests/test_random_state.py::TestRandN::test_distr[shared] +tests/test_random_state.py::TestRandN::test_zero_dims[(0,)] +tests/test_random_state.py::TestRandN::test_zero_dims[(3, 0)] +tests/test_random_state.py::TestRandN::test_zero_dims[(3, 0, 10)] +tests/test_random_state.py::TestRandN::test_zero_dims[()] +tests/test_random_state.py::TestRandN::test_wrong_dims +tests/test_random_state.py::TestSeed::test_scalar[normal] +tests/test_random_state.py::TestSeed::test_scalar[standard_normal] +tests/test_random_state.py::TestSeed::test_scalar[random_sample] +tests/test_random_state.py::TestSeed::test_scalar[uniform] tests/test_random_state.py::TestStandardNormal::test_distr[host] tests/test_random_state.py::TestStandardNormal::test_distr[device] tests/test_random_state.py::TestStandardNormal::test_distr[shared] +tests/test_random_state.py::TestStandardNormal::test_wrong_dims tests/test_random_state.py::TestRandSample::test_distr[host] tests/test_random_state.py::TestRandSample::test_distr[device] tests/test_random_state.py::TestRandSample::test_distr[shared] +tests/test_random_state.py::TestRandSample::test_wrong_dims tests/test_random_state.py::TestUniform::test_distr[host-float32-(low, high)=[1.23, 10.54]] tests/test_random_state.py::TestUniform::test_distr[host-float32-(low, high)=[10.54, 1.23]] tests/test_random_state.py::TestUniform::test_distr[host-float64-(low, high)=[1.23, 10.54]] @@ -790,26 +483,87 @@ tests/test_random_state.py::TestUniform::test_distr[shared-int32-(low, high)=[1. tests/test_random_state.py::TestUniform::test_distr[shared-int32-(low, high)=[10.54, 1.23]] tests/test_random_state.py::TestUniform::test_distr[shared-None-(low, high)=[1.23, 10.54]] tests/test_random_state.py::TestUniform::test_distr[shared-None-(low, high)=[10.54, 1.23]] -tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardCauchy_param_0_{shape=(4, 3, 2)}::test_standard_cauchy -tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardCauchy_param_1_{shape=(3, 2)}::test_standard_cauchy -tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardExponential_param_0_{shape=(4, 3, 2)}::test_standard_exponential -tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardExponential_param_1_{shape=(3, 2)}::test_standard_exponential -tests/third_party/cupy/random_tests/test_sample.py::TestRandint::test_lo_hi_nonrandom -tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_1 -tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_2 -tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_float2 -tests/test_mathematical.py::TestUnwrap::test_rand[int64] -tests/test_random.py::test_check_output[random] -tests/test_random.py::test_check_output[random_sample] -tests/test_random.py::test_check_output[ranf] -tests/test_random.py::test_check_output[sample] -tests/test_random.py::test_seed[ranf] -tests/test_random.py::test_seed[sample] -tests/test_random.py::test_seed[rand] -tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_overflow -tests/test_random.py::test_check_output[rand] -tests/test_random.py::TestDistributionsNormal::test_seed -tests/test_random_state.py::TestSeed::test_scalar[normal] -tests/test_random_state.py::TestSeed::test_scalar[standard_normal] -tests/test_random_state.py::TestSeed::test_scalar[random_sample] -tests/test_random_state.py::TestSeed::test_scalar[uniform] +tests/test_random_state.py::TestUniform::test_low_high_equal[host-float32] +tests/test_random_state.py::TestUniform::test_low_high_equal[host-float64] +tests/test_random_state.py::TestUniform::test_low_high_equal[host-int32] +tests/test_random_state.py::TestUniform::test_low_high_equal[host-None] +tests/test_random_state.py::TestUniform::test_low_high_equal[device-float32] +tests/test_random_state.py::TestUniform::test_low_high_equal[device-float64] +tests/test_random_state.py::TestUniform::test_low_high_equal[device-int32] +tests/test_random_state.py::TestUniform::test_low_high_equal[device-None] +tests/test_random_state.py::TestUniform::test_low_high_equal[shared-float32] +tests/test_random_state.py::TestUniform::test_low_high_equal[shared-float64] +tests/test_random_state.py::TestUniform::test_low_high_equal[shared-int32] +tests/test_random_state.py::TestUniform::test_low_high_equal[shared-None] +tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.float16] +tests/test_random_state.py::TestUniform::test_invalid_dtype[float] +tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.int64] +tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.int] +tests/test_random_state.py::TestUniform::test_invalid_dtype[int] +tests/test_random_state.py::TestUniform::test_invalid_dtype[numpy.clongdouble] +tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.complex128] +tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.complex64] +tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.bool] +tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.bool_] +tests/test_random_state.py::TestUniform::test_invalid_usm_type[Empty] +tests/test_random_state.py::TestUniform::test_invalid_usm_type[Unknown] +tests/test_random_state.py::TestRandInt::test_float_bounds +tests/test_random_state.py::TestRandInt::test_full_range +tests/test_random_state.py::TestUniform::test_range_bounds +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-normal-kwargs0] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-rand-kwargs1] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-randint-kwargs2] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-randn-kwargs3] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-random-kwargs4] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-random_integers-kwargs5] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-random_sample-kwargs6] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-ranf-kwargs7] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-sample-kwargs8] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-standard_normal-kwargs9] +tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-uniform-kwargs10] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-normal-kwargs0] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-rand-kwargs1] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-randint-kwargs2] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-randn-kwargs3] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-random-kwargs4] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-random_integers-kwargs5] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-random_sample-kwargs6] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-ranf-kwargs7] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-sample-kwargs8] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-standard_normal-kwargs9] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-uniform-kwargs10] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-normal-kwargs0] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-rand-kwargs1] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-randint-kwargs2] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-randn-kwargs3] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-random-kwargs4] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-random_integers-kwargs5] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-random_sample-kwargs6] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-ranf-kwargs7] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-sample-kwargs8] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-standard_normal-kwargs9] +tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-uniform-kwargs10] +tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-normal-args0-kwargs0] +tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-rand-args1-kwargs1] +tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-randint-args2-kwargs2] +tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-randn-args3-kwargs3] +tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-random_sample-args4-kwargs4] +tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-standard_normal-args5-kwargs5] +tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-uniform-args6-kwargs6] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-normal-args0-kwargs0] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-rand-args1-kwargs1] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-randint-args2-kwargs2] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-randn-args3-kwargs3] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-random_sample-args4-kwargs4] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-standard_normal-args5-kwargs5] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-uniform-args6-kwargs6] +tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-normal-args0-kwargs0] +tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-rand-args1-kwargs1] +tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-randint-args2-kwargs2] +tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-randn-args3-kwargs3] +tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-random_sample-args4-kwargs4] +tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-standard_normal-args5-kwargs5] +tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-uniform-args6-kwargs6] +tests/test_random.py::TestDistributionsGeometric::test_moments +tests/test_random.py::TestDistributionsLaplace::test_extreme_value +tests/test_random.py::TestDistributionsPareto::test_moments diff --git a/tests/test_arithmetic.py b/tests/test_arithmetic.py index 3e4e3162991..187c7aded56 100644 --- a/tests/test_arithmetic.py +++ b/tests/test_arithmetic.py @@ -1,6 +1,7 @@ import unittest import numpy +import pytest from tests.helper import has_support_aspect64 from tests.third_party.cupy import testing @@ -9,6 +10,7 @@ class TestArithmetic(unittest.TestCase): @testing.for_float_dtypes() @testing.numpy_cupy_allclose() + @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_modf_part1(self, xp, dtype): a = xp.array([-2.5, -1.5, -0.5, 0, 0.5, 1.5, 2.5], dtype=dtype) b, _ = xp.modf(a) @@ -17,6 +19,7 @@ def test_modf_part1(self, xp, dtype): @testing.for_float_dtypes() @testing.numpy_cupy_allclose() + @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_modf_part2(self, xp, dtype): a = xp.array([-2.5, -1.5, -0.5, 0, 0.5, 1.5, 2.5], dtype=dtype) _, c = xp.modf(a) diff --git a/tests/test_indexing.py b/tests/test_indexing.py index cf694ff0357..575aa871c89 100644 --- a/tests/test_indexing.py +++ b/tests/test_indexing.py @@ -718,7 +718,7 @@ class TestTakeAlongAxis: ], ) def test_argequivalent(self, func, argfunc, kwargs): - a = dpnp.random.random(size=(3, 4, 5)) + a = dpnp.asarray(numpy.random.random(size=(3, 4, 5))) for axis in list(range(a.ndim)) + [None]: a_func = func(a, axis=axis, **kwargs) diff --git a/tests/test_logic.py b/tests/test_logic.py index c52aba89aa7..ab6925ae923 100644 --- a/tests/test_logic.py +++ b/tests/test_logic.py @@ -396,12 +396,15 @@ def test_elemwise_comparison(op, x1, x2, dtype): "sh2", [[12], [4, 8], [1, 8, 6]], ids=["(12,)", "(4, 8)", "(1, 8, 6)"] ) def test_comparison_no_broadcast_with_shapes(op, sh1, sh2): - x1, x2 = dpnp.random.randn(*sh1), dpnp.random.randn(*sh2) + x1_np = numpy.random.randn(*sh1) + x2_np = numpy.random.randn(*sh2) + x1 = dpnp.asarray(x1_np) + x2 = dpnp.asarray(x2_np) # x1 OP x2 with pytest.raises(ValueError): getattr(dpnp, op)(x1, x2) - getattr(numpy, op)(x1.asnumpy(), x2.asnumpy()) + getattr(numpy, op)(x1_np, x2_np) @pytest.mark.parametrize( diff --git a/tests/test_random.py b/tests/test_random.py index 36323ae51b2..1d601bdd7ae 100644 --- a/tests/test_random.py +++ b/tests/test_random.py @@ -45,6 +45,7 @@ def check_seed(self, dist_name, params): assert_allclose(a1, a2, rtol=1e-07, atol=0) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "func", [dpnp.random.chisquare, dpnp.random.rand, dpnp.random.randn], @@ -61,6 +62,7 @@ def test_input_size(func): assert output_shape == res.shape +@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "func", [ @@ -82,6 +84,7 @@ def test_input_shape(func): assert shape == res.shape +@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "func", [ @@ -104,6 +107,7 @@ def test_check_output(func): assert dpnp.all(res < 1) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "func", [ @@ -130,6 +134,7 @@ def test_seed(func): assert_allclose(a1, a2, rtol=1e-07, atol=0) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_randn_normal_distribution(): """ Check the moments of the normal distribution sample obtained @@ -667,6 +672,7 @@ def test_seed(self): @pytest.mark.skipif(not has_support_aspect64(), reason="Failed on Iris Xe") +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsNormal(TestDistribution): def test_extreme_value(self): loc = 5 @@ -827,11 +833,13 @@ def test_seed(self): self.check_seed("rayleigh", {"scale": scale}) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsStandardCauchy(TestDistribution): def test_seed(self): self.check_seed("standard_cauchy", {}) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsStandardExponential(TestDistribution): def test_moments(self): shape = 0.8 @@ -867,6 +875,7 @@ def test_seed(self): self.check_seed("standard_gamma", {"shape": 0.0}) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsStandardNormal(TestDistribution): def test_moments(self): expected_mean = 0.0 @@ -944,6 +953,7 @@ def test_seed(self): @pytest.mark.skipif(not has_support_aspect64(), reason="Failed on Iris Xe") +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsUniform(TestDistribution): def test_extreme_value(self): low = 1.0 @@ -1070,6 +1080,7 @@ def test_seed(self): self.check_seed("zipf", {"a": a}) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestPermutationsTestShuffle: @pytest.mark.parametrize( "dtype", diff --git a/tests/test_sort.py b/tests/test_sort.py index b12889a674f..d60a27d2745 100644 --- a/tests/test_sort.py +++ b/tests/test_sort.py @@ -366,6 +366,7 @@ def test_complex(self, dtype): assert result.dtype == expected.dtype +@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize("kth", [0, 1], ids=["0", "1"]) @pytest.mark.parametrize("dtype", get_all_dtypes(no_none=True)) @pytest.mark.parametrize( diff --git a/tests/test_statistics.py b/tests/test_statistics.py index ad617752d04..b508e98d9ad 100644 --- a/tests/test_statistics.py +++ b/tests/test_statistics.py @@ -18,6 +18,7 @@ ) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "dtype", get_all_dtypes(no_none=True, no_bool=True, no_complex=True) ) diff --git a/tests/test_sycl_queue.py b/tests/test_sycl_queue.py index e705f809ea3..cd7bdec555c 100644 --- a/tests/test_sycl_queue.py +++ b/tests/test_sycl_queue.py @@ -1190,6 +1190,7 @@ def test_out_2in_1out(func, data1, data2, device): assert_sycl_queue_equal(result.sycl_queue, x2.sycl_queue) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "device", valid_devices, diff --git a/tests/third_party/cupy/core_tests/test_dlpack.py b/tests/third_party/cupy/core_tests/test_dlpack.py index 18eba557409..77d346d7bd6 100644 --- a/tests/third_party/cupy/core_tests/test_dlpack.py +++ b/tests/third_party/cupy/core_tests/test_dlpack.py @@ -11,24 +11,18 @@ def _gen_array(dtype, alloc_q=None): if cupy.issubdtype(dtype, numpy.unsignedinteger): - array = cupy.random.randint( - 0, 10, size=(2, 3), sycl_queue=alloc_q - ).astype(dtype) + array = numpy.random.randint(0, 10, size=(2, 3)) elif cupy.issubdtype(dtype, cupy.integer): - array = cupy.random.randint( - -10, 10, size=(2, 3), sycl_queue=alloc_q - ).astype(dtype) + array = numpy.random.randint(-10, 10, size=(2, 3)) elif cupy.issubdtype(dtype, cupy.floating): - array = cupy.random.rand(2, 3, sycl_queue=alloc_q).astype(dtype) + array = numpy.random.rand(2, 3) elif cupy.issubdtype(dtype, cupy.complexfloating): - array = cupy.random.random((2, 3), sycl_queue=alloc_q).astype(dtype) + array = numpy.random.random((2, 3)) elif dtype == cupy.bool_: - array = cupy.random.randint( - 0, 2, size=(2, 3), sycl_queue=alloc_q - ).astype(cupy.bool_) + array = numpy.random.randint(0, 2, size=(2, 3)) else: assert False, f"unrecognized dtype: {dtype}" - return array + return cupy.asarray(array, sycl_queue=alloc_q).astype(dtype) class TestDLPackConversion(unittest.TestCase): diff --git a/tests/third_party/cupy/indexing_tests/test_indexing.py b/tests/third_party/cupy/indexing_tests/test_indexing.py index ca2f9a9cc6c..a74495cba04 100644 --- a/tests/third_party/cupy/indexing_tests/test_indexing.py +++ b/tests/third_party/cupy/indexing_tests/test_indexing.py @@ -205,6 +205,7 @@ def test_extract_empty_1dim(self, xp): return xp.extract(b, a) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestChoose(unittest.TestCase): @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() @@ -213,7 +214,6 @@ def test_choose(self, xp, dtype): c = testing.shaped_arange((3, 4), xp, dtype) return a.choose(c) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() def test_choose_broadcast(self, xp, dtype): @@ -221,7 +221,6 @@ def test_choose_broadcast(self, xp, dtype): c = xp.array([-10, 10]).astype(dtype) return a.choose(c) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() def test_choose_broadcast2(self, xp, dtype): @@ -229,7 +228,6 @@ def test_choose_broadcast2(self, xp, dtype): c = testing.shaped_arange((3, 5, 2), xp, dtype) return a.choose(c) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() def test_choose_wrap(self, xp, dtype): @@ -237,7 +235,6 @@ def test_choose_wrap(self, xp, dtype): c = testing.shaped_arange((3, 4), xp, dtype) return a.choose(c, mode="wrap") - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() def test_choose_clip(self, xp, dtype): @@ -245,7 +242,6 @@ def test_choose_clip(self, xp, dtype): c = testing.shaped_arange((3, 4), xp, dtype) return a.choose(c, mode="clip") - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.with_requires("numpy>=1.19") def test_unknown_clip(self): for xp in (numpy, cupy): @@ -254,14 +250,12 @@ def test_unknown_clip(self): with pytest.raises(ValueError): a.choose(c, mode="unknown") - @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_raise(self): a = cupy.array([2]) c = cupy.array([[0, 1]]) with self.assertRaises(ValueError): a.choose(c) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() def test_choose_broadcast_fail(self, dtype): for xp in (numpy, cupy): diff --git a/tests/third_party/cupy/linalg_tests/test_solve.py b/tests/third_party/cupy/linalg_tests/test_solve.py index dd15e8303af..35315b8d78b 100644 --- a/tests/third_party/cupy/linalg_tests/test_solve.py +++ b/tests/third_party/cupy/linalg_tests/test_solve.py @@ -61,8 +61,12 @@ def test_solve(self): def check_shape(self, a_shape, b_shape, error_types): for xp, error_type in error_types.items(): - a = xp.random.rand(*a_shape) - b = xp.random.rand(*b_shape) + if xp is cupy and cupy.is_cuda_backend(): + a = xp.asarray(numpy.random.rand(*a_shape)) + b = xp.asarray(numpy.random.rand(*b_shape)) + else: + a = xp.random.rand(*a_shape) + b = xp.random.rand(*b_shape) with pytest.raises(error_type): xp.linalg.solve(a, b) @@ -137,7 +141,7 @@ def check_x(self, a_shape, dtype): testing.assert_array_equal(a_gpu_copy, a_gpu) def check_shape(self, a_shape): - a = cupy.random.rand(*a_shape) + a = cupy.asarray(numpy.random.rand(*a_shape)) with self.assertRaises(cupy.linalg.LinAlgError): cupy.linalg.inv(a) @@ -254,8 +258,8 @@ def check_lstsq_solution( return results def check_invalid_shapes(self, a_shape, b_shape): - a = cupy.random.rand(*a_shape) - b = cupy.random.rand(*b_shape) + a = cupy.asarray(numpy.random.rand(*a_shape)) + b = cupy.asarray(numpy.random.rand(*b_shape)) with pytest.raises(cupy.linalg.LinAlgError): cupy.linalg.lstsq(a, b, rcond=None) @@ -330,12 +334,12 @@ def check_x(self, a_shape, ind, dtype): testing.assert_array_equal(a_gpu_copy, a_gpu) def check_shape(self, a_shape, ind): - a = cupy.random.rand(*a_shape) + a = cupy.asarray(numpy.random.rand(*a_shape)) with self.assertRaises(cupy.linalg.LinAlgError): cupy.linalg.tensorinv(a, ind=ind) def check_ind(self, a_shape, ind): - a = cupy.random.rand(*a_shape) + a = cupy.asarray(numpy.random.rand(*a_shape)) with self.assertRaises(ValueError): cupy.linalg.tensorinv(a, ind=ind) diff --git a/tests/third_party/cupy/math_tests/test_arithmetic.py b/tests/third_party/cupy/math_tests/test_arithmetic.py index ffbad20aadf..91bba92f733 100644 --- a/tests/third_party/cupy/math_tests/test_arithmetic.py +++ b/tests/third_party/cupy/math_tests/test_arithmetic.py @@ -685,6 +685,7 @@ def test_casting_dtype_unsafe_ignore_warnings( class TestArithmeticModf: @testing.for_float_dtypes() @testing.numpy_cupy_allclose() + @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_modf(self, xp, dtype): a = xp.array([-2.5, -1.5, -0.5, 0, 0.5, 1.5, 2.5], dtype=dtype) b, c = xp.modf(a) diff --git a/tests/third_party/cupy/random_tests/test_distributions.py b/tests/third_party/cupy/random_tests/test_distributions.py index d73fa996139..47fa6058aec 100644 --- a/tests/third_party/cupy/random_tests/test_distributions.py +++ b/tests/third_party/cupy/random_tests/test_distributions.py @@ -599,6 +599,7 @@ def test_rayleigh_for_negative_scale(self, scale_dtype): ) ) class TestDistributionsStandardCauchy(RandomDistributionsTestCase): + @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_standard_cauchy(self): self.check_distribution("standard_cauchy", {}) @@ -611,6 +612,7 @@ def test_standard_cauchy(self): ) ) class TestDistributionsStandardExponential(RandomDistributionsTestCase): + @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_standard_exponential(self): self.check_distribution("standard_exponential", {}) @@ -639,6 +641,7 @@ def test_standard_gamma(self, shape_dtype): ) ) class TestDistributionsStandardNormal(RandomDistributionsTestCase): + @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_standard_normal(self): self.check_distribution("standard_normal", {}) diff --git a/tests/third_party/cupy/random_tests/test_sample.py b/tests/third_party/cupy/random_tests/test_sample.py index 2ef8f2605e5..14be32ea13d 100644 --- a/tests/third_party/cupy/random_tests/test_sample.py +++ b/tests/third_party/cupy/random_tests/test_sample.py @@ -10,6 +10,7 @@ from tests.third_party.cupy.testing import _condition, _hypothesis +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestRandint(unittest.TestCase): def test_lo_hi_reversed(self): with self.assertRaises(ValueError): @@ -52,7 +53,7 @@ def test_bound_1(self): @pytest.mark.usefixtures("allow_fall_back_on_numpy") @_condition.repeat(3, 10) def test_bound_2(self): - vals = [random.randint(0, 2) for _ in range(20)] + vals = [random.randint(0, 2, ()) for _ in range(20)] for val in vals: self.assertEqual(val.shape, ()) self.assertEqual(min(_.min() for _ in vals), 0) @@ -106,6 +107,7 @@ def test_goodness_of_fit_2(self): self.assertTrue(_hypothesis.chi_square_test(counts, expected)) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestRandintDtype(unittest.TestCase): # numpy.int8, numpy.uint8, numpy.int16, numpy.uint16, numpy.int32]) @testing.for_dtypes([numpy.int32]) @@ -131,11 +133,11 @@ def test_dtype2(self, dtype): self.assertLessEqual(max(x), iinfo.max) # Lower bound check - with self.assertRaises(OverflowError): + with self.assertRaises((OverflowError, ValueError)): random.randint(iinfo.min - 1, iinfo.min + 10, size, dtype) # Upper bound check - with self.assertRaises(OverflowError): + with self.assertRaises((OverflowError, ValueError)): random.randint(iinfo.max - 10, iinfo.max + 2, size, dtype) diff --git a/tests/third_party/cupy/statistics_tests/test_histogram.py b/tests/third_party/cupy/statistics_tests/test_histogram.py index 521bd4062fb..c416a8123ee 100644 --- a/tests/third_party/cupy/statistics_tests/test_histogram.py +++ b/tests/third_party/cupy/statistics_tests/test_histogram.py @@ -140,7 +140,7 @@ def test_histogram_float_weights_dtype(self, xp, dtype): return h def test_histogram_weights_basic(self): - v = cupy.random.rand(100) + v = cupy.asarray(numpy.random.rand(100)) w = cupy.ones(100) * 5 a, b = cupy.histogram(v) na, nb = cupy.histogram(v, density=True) diff --git a/tests/third_party/cupy/statistics_tests/test_meanvar.py b/tests/third_party/cupy/statistics_tests/test_meanvar.py index ce5de823d61..d74ab3005ed 100644 --- a/tests/third_party/cupy/statistics_tests/test_meanvar.py +++ b/tests/third_party/cupy/statistics_tests/test_meanvar.py @@ -11,6 +11,7 @@ ) +@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestMedian: @testing.for_all_dtypes() @testing.numpy_cupy_allclose(type_check=has_support_aspect64()) @@ -18,42 +19,36 @@ def test_median_noaxis(self, xp, dtype): a = testing.shaped_random((3, 4, 5), xp, dtype) return xp.median(a) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_allclose(type_check=has_support_aspect64()) def test_median_axis1(self, xp, dtype): a = testing.shaped_random((3, 4, 5), xp, dtype) return xp.median(a, axis=1) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_allclose(type_check=has_support_aspect64()) def test_median_axis2(self, xp, dtype): a = testing.shaped_random((3, 4, 5), xp, dtype) return xp.median(a, axis=2) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_allclose() def test_median_overwrite_input(self, xp, dtype): a = testing.shaped_random((3, 4, 5), xp, dtype) return xp.median(a, overwrite_input=True) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_allclose(type_check=has_support_aspect64()) def test_median_keepdims_axis1(self, xp, dtype): a = testing.shaped_random((3, 4, 5), xp, dtype) return xp.median(a, axis=1, keepdims=True) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_allclose(type_check=has_support_aspect64()) def test_median_keepdims_noaxis(self, xp, dtype): a = testing.shaped_random((3, 4, 5), xp, dtype) return xp.median(a, keepdims=True) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_median_invalid_axis(self): for xp in [numpy, cupy]: a = testing.shaped_random((3, 4, 5), xp) From 0c64722f898ef146362253b151d0f657de902962 Mon Sep 17 00:00:00 2001 From: Natalia Polina Date: Thu, 26 Sep 2024 13:10:51 -0700 Subject: [PATCH 04/23] Applied review comments --- dpnp/dpnp_iface.py | 9 ++++++--- tests/conftest.py | 10 +++------- tests/skipped_tests_cuda.tbl | 4 ++-- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/dpnp/dpnp_iface.py b/dpnp/dpnp_iface.py index a2f86783791..1643dae4e6f 100644 --- a/dpnp/dpnp_iface.py +++ b/dpnp/dpnp_iface.py @@ -760,14 +760,14 @@ def get_usm_ndarray_or_scalar(a): def is_cuda_backend(obj=None): """ - Checks that object has a cuda backend. + Checks that object has a CUDA backend. Parameters ---------- obj : {Device, SyclDevice, SyclQueue, dpnp.ndarray, usm_ndarray, None}, optional An input object with sycl_device property to check device backend. - If obj is ``None``, device backend will be checked for the default + If `obj` is ``None``, device backend will be checked for the default queue. Default: ``None``. @@ -784,7 +784,10 @@ def is_cuda_backend(obj=None): sycl_device = obj else: sycl_device = getattr(obj, "sycl_device", None) - if sycl_device is not None and "cuda" in sycl_device.backend.name: + if ( + sycl_device is not None + and sycl_device.backend == dpctl.backend_type.cuda + ): return True return False diff --git a/tests/conftest.py b/tests/conftest.py index a8b4c4e1dca..1608970061d 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -65,14 +65,12 @@ def pytest_collection_modifyitems(config, items): ) # global skip file for cuda backend - test_exclude_file_cuda = os.path.join( - test_path, "skipped_tests_cuda.tbl" - ) + test_exclude_file_cuda = os.path.join(test_path, "skipped_tests_cuda.tbl") dev = dpctl.select_default_device() is_cpu = dev.is_cpu is_gpu_no_fp64 = not dev.has_aspect_fp64 - is_cuda = "cuda" in str(dev.backend.name) + is_cuda = dpnp.is_cuda_backend(dev) print("") print(f"DPNP current device is CPU: {is_cpu}") @@ -89,9 +87,7 @@ def pytest_collection_modifyitems(config, items): get_excluded_tests(test_exclude_file_gpu_no_fp64) ) if is_cuda: - excluded_tests.extend( - get_excluded_tests(test_exclude_file_cuda) - ) + excluded_tests.extend(get_excluded_tests(test_exclude_file_cuda)) else: excluded_tests.extend(get_excluded_tests(test_exclude_file)) diff --git a/tests/skipped_tests_cuda.tbl b/tests/skipped_tests_cuda.tbl index 377cfe57ac3..2d4860a6dd4 100644 --- a/tests/skipped_tests_cuda.tbl +++ b/tests/skipped_tests_cuda.tbl @@ -379,7 +379,7 @@ tests/test_random_state.py::TestNormal::test_distr[host-float32] tests/test_random_state.py::TestNormal::test_distr[host-float64] tests/test_random_state.py::TestNormal::test_distr[host-None] tests/test_random_state.py::TestNormal::test_distr[device-float32] -tests/test_random_state.py::TestNormal::test_distr[device-float64] +tests/test_random_state.py::TestNormal::test_distr[device-float64] tests/test_random_state.py::TestNormal::test_distr[device-None] tests/test_random_state.py::TestNormal::test_distr[shared-float32] tests/test_random_state.py::TestNormal::test_distr[shared-float64] @@ -391,7 +391,7 @@ tests/test_random_state.py::TestNormal::test_scale[device-float32] tests/test_random_state.py::TestNormal::test_scale[device-float64] tests/test_random_state.py::TestNormal::test_scale[device-None] tests/test_random_state.py::TestNormal::test_scale[shared-float32] -tests/test_random_state.py::TestNormal::test_scale[shared-float64] +tests/test_random_state.py::TestNormal::test_scale[shared-float64] tests/test_random_state.py::TestNormal::test_scale[shared-None] tests/test_random_state.py::TestNormal::test_inf_loc[numpy.inf] tests/test_random_state.py::TestNormal::test_inf_loc[-numpy.inf] From 6e2c3c72b112927895c4c7226237c974796acee7 Mon Sep 17 00:00:00 2001 From: Natalia Polina Date: Fri, 25 Oct 2024 00:45:46 -0700 Subject: [PATCH 05/23] Update test_indexing.py --- tests/test_indexing.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/test_indexing.py b/tests/test_indexing.py index 9538f07d15c..dd4e42112c3 100644 --- a/tests/test_indexing.py +++ b/tests/test_indexing.py @@ -728,6 +728,8 @@ class TestTakeAlongAxis: ], ) def test_argequivalent(self, func, argfunc, kwargs): + # TODO: to roll back the change once the issue with CUDA support is resolved for random + # a = dpnp.random.random(size=(3, 4, 5)) a = dpnp.asarray(numpy.random.random(size=(3, 4, 5))) for axis in list(range(a.ndim)) + [None]: From 4e3c87c6a450e6bd749b52552687e83a1591dbff Mon Sep 17 00:00:00 2001 From: Natalia Polina Date: Fri, 25 Oct 2024 00:50:05 -0700 Subject: [PATCH 06/23] Update test_solve.py --- tests/third_party/cupy/linalg_tests/test_solve.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/tests/third_party/cupy/linalg_tests/test_solve.py b/tests/third_party/cupy/linalg_tests/test_solve.py index 8a04ed21104..8f98a85f077 100644 --- a/tests/third_party/cupy/linalg_tests/test_solve.py +++ b/tests/third_party/cupy/linalg_tests/test_solve.py @@ -67,6 +67,9 @@ def test_solve(self): def check_shape(self, a_shape, b_shape, error_types): for xp, error_type in error_types.items(): + # TODO: to roll back the change once the issue with CUDA support is resolved for random + # a = xp.random.rand(*a_shape) + # b = xp.random.rand(*b_shape) if xp is cupy and cupy.is_cuda_backend(): a = xp.asarray(numpy.random.rand(*a_shape)) b = xp.asarray(numpy.random.rand(*b_shape)) @@ -149,6 +152,8 @@ def check_x(self, a_shape, dtype): testing.assert_array_equal(a_gpu_copy, a_gpu) def check_shape(self, a_shape): + # TODO: to roll back the change once the issue with CUDA support is resolved for random + # a = cupy.random.rand(*a_shape) a = cupy.asarray(numpy.random.rand(*a_shape)) with self.assertRaises(cupy.linalg.LinAlgError): cupy.linalg.inv(a) @@ -266,6 +271,9 @@ def check_lstsq_solution( return results def check_invalid_shapes(self, a_shape, b_shape): + # TODO: to roll back the change once the issue with CUDA support is resolved for random + # a = cupy.random.rand(*a_shape) + # b = cupy.random.rand(*b_shape) a = cupy.asarray(numpy.random.rand(*a_shape)) b = cupy.asarray(numpy.random.rand(*b_shape)) with pytest.raises(cupy.linalg.LinAlgError): @@ -342,11 +350,15 @@ def check_x(self, a_shape, ind, dtype): testing.assert_array_equal(a_gpu_copy, a_gpu) def check_shape(self, a_shape, ind): + # TODO: to roll back the change once the issue with CUDA support is resolved for random + # a = cupy.random.rand(*a_shape) a = cupy.asarray(numpy.random.rand(*a_shape)) with self.assertRaises(cupy.linalg.LinAlgError): cupy.linalg.tensorinv(a, ind=ind) def check_ind(self, a_shape, ind): + # TODO: to roll back the change once the issue with CUDA support is resolved for random + # a = cupy.random.rand(*a_shape) a = cupy.asarray(numpy.random.rand(*a_shape)) with self.assertRaises(ValueError): cupy.linalg.tensorinv(a, ind=ind) From 94a418ed6b923e7b7ab7d01c0bc22b04d39d5585 Mon Sep 17 00:00:00 2001 From: Natalia Polina Date: Fri, 25 Oct 2024 00:50:46 -0700 Subject: [PATCH 07/23] Update test_histogram.py --- tests/third_party/cupy/statistics_tests/test_histogram.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/third_party/cupy/statistics_tests/test_histogram.py b/tests/third_party/cupy/statistics_tests/test_histogram.py index c416a8123ee..b917d9115df 100644 --- a/tests/third_party/cupy/statistics_tests/test_histogram.py +++ b/tests/third_party/cupy/statistics_tests/test_histogram.py @@ -140,6 +140,8 @@ def test_histogram_float_weights_dtype(self, xp, dtype): return h def test_histogram_weights_basic(self): + # TODO: to roll back the change once the issue with CUDA support is resolved for random + # v = cupy.random.rand(100)) v = cupy.asarray(numpy.random.rand(100)) w = cupy.ones(100) * 5 a, b = cupy.histogram(v) From 1461e812c66f6f49a076c78d11c2c053b9b3635c Mon Sep 17 00:00:00 2001 From: Natalia Polina Date: Fri, 25 Oct 2024 00:52:08 -0700 Subject: [PATCH 08/23] Update test_histogram.py --- tests/third_party/cupy/statistics_tests/test_histogram.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/third_party/cupy/statistics_tests/test_histogram.py b/tests/third_party/cupy/statistics_tests/test_histogram.py index b917d9115df..10984fe0f0e 100644 --- a/tests/third_party/cupy/statistics_tests/test_histogram.py +++ b/tests/third_party/cupy/statistics_tests/test_histogram.py @@ -141,7 +141,7 @@ def test_histogram_float_weights_dtype(self, xp, dtype): def test_histogram_weights_basic(self): # TODO: to roll back the change once the issue with CUDA support is resolved for random - # v = cupy.random.rand(100)) + # v = cupy.random.rand(100) v = cupy.asarray(numpy.random.rand(100)) w = cupy.ones(100) * 5 a, b = cupy.histogram(v) From 519008e555a11358a030bcd6009322fbb6dbc73a Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Thu, 14 Nov 2024 07:40:49 -0800 Subject: [PATCH 09/23] Update skipped_tests_cuda.tbl --- tests/skipped_tests_cuda.tbl | 205 ++++++++++++++++++----------------- 1 file changed, 107 insertions(+), 98 deletions(-) diff --git a/tests/skipped_tests_cuda.tbl b/tests/skipped_tests_cuda.tbl index 2d4860a6dd4..99201a47740 100644 --- a/tests/skipped_tests_cuda.tbl +++ b/tests/skipped_tests_cuda.tbl @@ -41,7 +41,6 @@ tests/test_fft.py::TestFftn::test_fftn_out[s1-axes0] tests/test_fft.py::TestFftn::test_fftn_out[s2-axes0] tests/test_fft.py::TestFftn::test_fftn_out[s2-axes1] tests/test_fft.py::TestFftn::test_fftn_out[s2-axes2] -tests/test_fft.py::TestRfftn::test_rfftn_out[s1-axes1] tests/test_fft.py::TestRfftn::test_rfftn_out[s2-axes0] tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_50_{axes=None, norm=None, s=None, shape=(2, 3, 4, 5)}] tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_51_{axes=None, norm='backward', s=None, shape=(2, 3, 4, 5)}] @@ -60,7 +59,7 @@ tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_61_{ax tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_62_{axes=None, norm='ortho', s=None, shape=(2, 3, 4, 5)}] tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_63_{axes=None, norm='forward', s=None, shape=(2, 3, 4, 5)}] -# std +# linalg tests/test_linalg.py::TestCond::test_cond_nan_input[-dpnp.inf] tests/test_linalg.py::TestCond::test_cond_nan_input[-1] tests/test_linalg.py::TestCond::test_cond_nan_input[1] @@ -71,7 +70,7 @@ tests/test_linalg.py::TestCond::test_cond_nan[-1] tests/test_linalg.py::TestCond::test_cond_nan[1] tests/test_linalg.py::TestCond::test_cond_nan[dpnp.inf] tests/test_linalg.py::TestCond::test_cond_nan[fro] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-bool_] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-bool] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-int32] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-int64] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-float32] @@ -79,7 +78,7 @@ tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-float64] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-complex64] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-complex128] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-None] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-bool_] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-bool] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-int32] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-int64] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-float32] @@ -87,7 +86,7 @@ tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-float64] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-complex64] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-complex128] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-None] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-bool_] +tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-bool] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-int32] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-int64] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-float32] @@ -95,103 +94,109 @@ tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-float64] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-complex64] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-complex128] tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-None] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-bool_] +tests/test_linalg.py::TestNorm::test_matrix_norm[True--2] +tests/test_linalg.py::TestNorm::test_matrix_norm[True-2] +tests/test_linalg.py::TestNorm::test_matrix_norm[True-nuc] +tests/test_linalg.py::TestNorm::test_matrix_norm[False--2] +tests/test_linalg.py::TestNorm::test_matrix_norm[False-2] +tests/test_linalg.py::TestNorm::test_matrix_norm[False-nuc] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-bool] tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-int32] tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-int64] tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-float32] tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-float64] tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-None] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-bool] tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-int32] tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-int64] tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-float32] tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-float64] tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-None] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-bool_] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-int32] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-int64] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-float32] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-float64] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-"nuc"-None] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-bool] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-int32] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-int64] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-float32] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-float64] +tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-None] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-bool] tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-int32] tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-int64] tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-float32] tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-float64] tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-None] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-bool] tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-int32] tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-int64] tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-float32] tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-float64] tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-None] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-bool_] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-int32] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-int64] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-float32] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-float64] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-bool] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-int32] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-int64] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-float32] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-float64] +tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-None] tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None--2-complex64] tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None--2-complex128] tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-2-complex64] tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-"nuc"-complex64] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-nuc-complex64] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-nuc-complex128] tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None--2-complex64] tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None--2-complex128] tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-2-complex64] tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-"nuc"-complex64] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-"nuc"-complex128] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-nuc-complex64] +tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-nuc-complex128] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-bool] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-int32] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-int64] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-float32] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-float64] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-bool] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-int32] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-int64] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-float32] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-float64] tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-bool_] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-int32] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-int64] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-float32] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-float64] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-"nuc"-None] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-bool] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-int32] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-int64] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-float32] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-float64] +tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-None] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-bool] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-int32] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-int64] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-float32] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-float64] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-bool] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-int32] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-int64] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-float32] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-float64] tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-bool_] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-int32] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-int64] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-float32] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-float64] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-bool] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-int32] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-int64] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-float32] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-float64] +tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-None] tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)--2-complex64] tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)--2-complex128] tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-2-complex64] tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-"nuc"-complex64] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-"nuc"-complex128] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-nuc-complex64] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-nuc-complex128] tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)--2-complex64] tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)--2-complex128] tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-2-complex64] tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-"nuc"-complex64] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-"nuc"-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-nuc-complex64] +tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-nuc-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-bool] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-int32] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-int64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-float32] @@ -199,7 +204,7 @@ tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-float64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-complex64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-complex128] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-bool] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-int32] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-int64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-float32] @@ -207,15 +212,15 @@ tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-float64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-complex64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-complex128] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-bool_] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-"nuc"-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-bool] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-bool] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-int32] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-int64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-float32] @@ -223,7 +228,7 @@ tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-float64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-complex64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-complex128] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-bool] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-int32] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-int64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-float32] @@ -231,15 +236,15 @@ tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-float64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-complex64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-complex128] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-bool_] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-"nuc"-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-bool] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-bool] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-int32] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-int64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-float32] @@ -247,7 +252,7 @@ tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-float64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-complex64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-complex128] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-bool] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-int32] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-int64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-float32] @@ -255,15 +260,15 @@ tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-float64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-complex64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-complex128] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-bool_] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-"nuc"-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-bool] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-bool] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-int32] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-int64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-float32] @@ -271,7 +276,7 @@ tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-float64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-complex64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-complex128] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-bool_] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-bool] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-int32] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-int64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-float32] @@ -279,14 +284,14 @@ tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-float64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-complex64] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-complex128] tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-bool_] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-"nuc"-None] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-bool] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-int32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-int64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-float32] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-float64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-complex64] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-complex128] +tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-None] tests/test_linalg.py::TestSvd::test_svd[(3,4)-int32] tests/test_linalg.py::TestSvd::test_svd[(3,4)-int64] tests/test_linalg.py::TestSvd::test_svd[(3,4)-float32] @@ -294,6 +299,13 @@ tests/test_linalg.py::TestSvd::test_svd[(3,4)-float64] tests/test_linalg.py::TestSvd::test_svd[(3,4)-complex64] tests/test_linalg.py::TestSvd::test_svd[(3,4)-complex128] tests/test_linalg.py::TestSvd::test_svd[(3,4)-None] +tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-int32] +tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-int64] +tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-float32] +tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-float64] +tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-complex64] +tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-complex128] +tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-None] tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-int32] tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-int64] tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-float32] @@ -308,27 +320,27 @@ tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-float64] tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-complex64] tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-complex128] tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-None] -tests/test_usm_type.py::test_cond[-dpnp.inf-device] -tests/test_usm_type.py::test_cond[-dpnp.inf-shared] -tests/test_usm_type.py::test_cond[-dpnp.inf-host] +tests/test_usm_type.py::test_cond[-inf-device] +tests/test_usm_type.py::test_cond[-inf-shared] +tests/test_usm_type.py::test_cond[-inf-host] tests/test_usm_type.py::test_cond[-1-device] tests/test_usm_type.py::test_cond[-1-shared] tests/test_usm_type.py::test_cond[-1-host] tests/test_usm_type.py::test_cond[1-device] tests/test_usm_type.py::test_cond[1-shared] tests/test_usm_type.py::test_cond[1-host] -tests/test_usm_type.py::test_cond[dpnp.inf-device] -tests/test_usm_type.py::test_cond[dpnp.inf-shared] -tests/test_usm_type.py::test_cond[dpnp.inf-host] +tests/test_usm_type.py::test_cond[inf-device] +tests/test_usm_type.py::test_cond[inf-shared] +tests/test_usm_type.py::test_cond[inf-host] tests/test_usm_type.py::test_cond[fro-device] tests/test_usm_type.py::test_cond[fro-shared] tests/test_usm_type.py::test_cond[fro-host] tests/test_sycl_queue.py::test_norm[(0, 1)--2-cuda:gpu:0] tests/test_sycl_queue.py::test_norm[(0, 1)-2-cuda:gpu:0] -tests/test_sycl_queue.py::test_norm[(0, 1)-"nuc"-cuda:gpu:0] +tests/test_sycl_queue.py::test_norm[(0, 1)-nuc-cuda:gpu:0] tests/test_sycl_queue.py::test_norm[(-2, -1)--2-cuda:gpu:0] tests/test_sycl_queue.py::test_norm[(-2, -1)-2-cuda:gpu:0] -tests/test_sycl_queue.py::test_norm[(-2, -1)-"nuc"-cuda:gpu:0] +tests/test_sycl_queue.py::test_norm[(-2, -1)-nuc-cuda:gpu:0] tests/test_sycl_queue.py::test_pinv[cuda:gpu:0-(2, 2, 3)] tests/test_sycl_queue.py::test_pinv[cuda:gpu:0-(2, 2, 3), rcond_as_array] tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank2 @@ -368,11 +380,8 @@ tests/third_party/cupy/linalg_tests/test_solve.py::TestPinv::test_pinv_batched tests/third_party/cupy/linalg_tests/test_solve.py::TestPinv::test_pinv_batched_vector_rcond tests/third_party/cupy/linalg_tests/test_solve.py::TestLstsq::test_lstsq_solutions -# matmul -tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_cupy_matmul[shape10-shape20] -tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_cupy_matmul[shape11-shape21] -tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_operator_matmul[shape10-shape20] -tests/third_party/cupy/math_tests/test_matmul.py::TestMatmulIntegralLargeBatch::test_operator_matmul[shape11-shape21] +# spacing +tests/test_mathematical.py::TestSpacing::test_zeros[float32] # random state tests/test_random_state.py::TestNormal::test_distr[host-float32] From a38949d7dbd81d51aa1c45bb4f0d0e17e6817c19 Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Thu, 14 Nov 2024 07:44:57 -0800 Subject: [PATCH 10/23] Apply fallback to numpy for TestRational and test_copy_multigpu --- tests/third_party/cupy/creation_tests/test_from_data.py | 1 + tests/third_party/cupy/math_tests/test_rational.py | 2 ++ 2 files changed, 3 insertions(+) diff --git a/tests/third_party/cupy/creation_tests/test_from_data.py b/tests/third_party/cupy/creation_tests/test_from_data.py index a2abbf608c7..ce5c489c5c4 100644 --- a/tests/third_party/cupy/creation_tests/test_from_data.py +++ b/tests/third_party/cupy/creation_tests/test_from_data.py @@ -516,6 +516,7 @@ def test_copy(self, xp, dtype, order): @testing.for_CF_orders() @testing.for_all_dtypes() + @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_copy_multigpu(self, dtype, order): q1 = dpctl.SyclQueue() q2 = dpctl.SyclQueue() diff --git a/tests/third_party/cupy/math_tests/test_rational.py b/tests/third_party/cupy/math_tests/test_rational.py index 6dd2a863a4c..594530d739b 100644 --- a/tests/third_party/cupy/math_tests/test_rational.py +++ b/tests/third_party/cupy/math_tests/test_rational.py @@ -7,6 +7,7 @@ class TestRational(unittest.TestCase): + @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_dtypes(["?", "e", "f", "d", "F", "D"]) def test_gcd_dtype_check(self, dtype): a = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) @@ -21,6 +22,7 @@ def test_gcd_check_boundary_cases(self, xp, dtype): b = xp.array([0, 5, -10, -5, 20, 51, 6, 42]) return xp.gcd(a, b) + @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_dtypes(["?", "e", "f", "d", "F", "D"]) def test_lcm_dtype_check(self, dtype): a = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) From 139c7843f253bd8b66a957a9db3e29ddd9888746 Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Thu, 14 Nov 2024 07:56:30 -0800 Subject: [PATCH 11/23] Address remarks --- dpnp/dpnp_iface.py | 2 +- tests/third_party/cupy/core_tests/test_dlpack.py | 1 + tests/third_party/cupy/statistics_tests/test_meanvar.py | 1 - 3 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dpnp/dpnp_iface.py b/dpnp/dpnp_iface.py index a2b4478d9ee..c2c30d007cb 100644 --- a/dpnp/dpnp_iface.py +++ b/dpnp/dpnp_iface.py @@ -750,7 +750,7 @@ def is_cuda_backend(obj=None): Returns ------- out : bool - Return ``True`` if object has a cuda backend, otherwise``False``. + Return ``True`` if object has a CUDA backend, otherwise ``False``. """ diff --git a/tests/third_party/cupy/core_tests/test_dlpack.py b/tests/third_party/cupy/core_tests/test_dlpack.py index 77d346d7bd6..8e4e9c05917 100644 --- a/tests/third_party/cupy/core_tests/test_dlpack.py +++ b/tests/third_party/cupy/core_tests/test_dlpack.py @@ -9,6 +9,7 @@ from tests.third_party.cupy import testing +# TODO: to roll back the changes once the issue with CUDA support is resolved for random def _gen_array(dtype, alloc_q=None): if cupy.issubdtype(dtype, numpy.unsignedinteger): array = numpy.random.randint(0, 10, size=(2, 3)) diff --git a/tests/third_party/cupy/statistics_tests/test_meanvar.py b/tests/third_party/cupy/statistics_tests/test_meanvar.py index 30f6e9f8bba..465d0e8e511 100644 --- a/tests/third_party/cupy/statistics_tests/test_meanvar.py +++ b/tests/third_party/cupy/statistics_tests/test_meanvar.py @@ -11,7 +11,6 @@ ) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestMedian: @testing.for_all_dtypes() @testing.numpy_cupy_allclose(type_check=has_support_aspect64()) From 351e12d6537db84a2e427bdd159a8449673c79cb Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Fri, 29 Nov 2024 05:02:57 -0800 Subject: [PATCH 12/23] Use dpctl.select_default_device() in is_cuda_backend() func --- dpnp/dpnp_iface.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dpnp/dpnp_iface.py b/dpnp/dpnp_iface.py index be2a119a4c8..a8aa5237f27 100644 --- a/dpnp/dpnp_iface.py +++ b/dpnp/dpnp_iface.py @@ -758,7 +758,7 @@ def is_cuda_backend(obj=None): """ if obj is None: - sycl_device = dpctl.SyclQueue().sycl_device + sycl_device = dpctl.select_default_device() elif isinstance(obj, dpctl.SyclDevice): sycl_device = obj else: From 590dbc853d46040683a7e6c9c4f61533bdeb142c Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Fri, 29 Nov 2024 06:03:52 -0800 Subject: [PATCH 13/23] Raise NotImplementedError in unsupported functions on CUDA --- dpnp/dpnp_iface_indexing.py | 7 +- dpnp/dpnp_iface_libmath.py | 6 +- dpnp/dpnp_iface_mathematical.py | 7 +- dpnp/dpnp_iface_sorting.py | 7 +- dpnp/dpnp_iface_statistics.py | 9 +- dpnp/random/dpnp_iface_random.py | 220 ++++++++++++++++++++++--------- dpnp/random/dpnp_random_state.py | 21 ++- 7 files changed, 198 insertions(+), 79 deletions(-) diff --git a/dpnp/dpnp_iface_indexing.py b/dpnp/dpnp_iface_indexing.py index 2ff552fcf71..a8656006be2 100644 --- a/dpnp/dpnp_iface_indexing.py +++ b/dpnp/dpnp_iface_indexing.py @@ -137,6 +137,11 @@ def choose(x1, choices, out=None, mode="raise"): ) if x1_desc: + if dpnp.is_cuda_backend(x1_desc.get_array()): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if any(not desc for desc in choices_list): pass elif out is not None: @@ -147,8 +152,6 @@ def choose(x1, choices, out=None, mode="raise"): pass elif not choices_list: pass - elif dpnp.is_cuda_backend(x1): - pass else: size = x1_desc.size choices_size = choices_list[0].size diff --git a/dpnp/dpnp_iface_libmath.py b/dpnp/dpnp_iface_libmath.py index e726d1b0172..6889cab5fc2 100644 --- a/dpnp/dpnp_iface_libmath.py +++ b/dpnp/dpnp_iface_libmath.py @@ -81,7 +81,11 @@ def erf(in_array1): x1_desc = dpnp.get_dpnp_descriptor( in_array1, copy_when_strides=False, copy_when_nondefault_queue=False ) - if x1_desc and not dpnp.is_cuda_backend(in_array1): + if x1_desc: + if dpnp.is_cuda_backend(x1_desc.get_array()): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) return dpnp_erf(x1_desc).get_pyobj() result = create_output_descriptor_py( diff --git a/dpnp/dpnp_iface_mathematical.py b/dpnp/dpnp_iface_mathematical.py index 6ccfeaa3e7c..7a5b5b790f5 100644 --- a/dpnp/dpnp_iface_mathematical.py +++ b/dpnp/dpnp_iface_mathematical.py @@ -2924,10 +2924,13 @@ def modf(x1, **kwargs): x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) if x1_desc: + if dpnp.is_cuda_backend(x1_desc.get_array()): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if not kwargs: pass - elif dpnp.is_cuda_backend(x1): - pass else: return dpnp_modf(x1_desc) diff --git a/dpnp/dpnp_iface_sorting.py b/dpnp/dpnp_iface_sorting.py index c1966f35b45..9ca48e34764 100644 --- a/dpnp/dpnp_iface_sorting.py +++ b/dpnp/dpnp_iface_sorting.py @@ -187,6 +187,11 @@ def partition(x1, kth, axis=-1, kind="introselect", order=None): x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) if x1_desc: + if dpnp.is_cuda_backend(x1_desc.get_array()): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if not isinstance(kth, int): pass elif x1_desc.ndim == 0: @@ -199,8 +204,6 @@ def partition(x1, kth, axis=-1, kind="introselect", order=None): pass elif order is not None: pass - elif dpnp.is_cuda_backend(x1): - pass else: return dpnp_partition(x1_desc, kth, axis, kind, order).get_pyobj() diff --git a/dpnp/dpnp_iface_statistics.py b/dpnp/dpnp_iface_statistics.py index 64156a1bffc..d64f616da8e 100644 --- a/dpnp/dpnp_iface_statistics.py +++ b/dpnp/dpnp_iface_statistics.py @@ -484,14 +484,19 @@ def correlate(x1, x2, mode="valid"): x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_nondefault_queue=False) x2_desc = dpnp.get_dpnp_descriptor(x2, copy_when_nondefault_queue=False) if x1_desc and x2_desc: + if dpnp.is_cuda_backend(x1_desc.get_array()) or dpnp.is_cuda_backend( + x2_desc.get_array() + ): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if x1_desc.size != x2_desc.size or x1_desc.size == 0: pass elif x1_desc.shape != x2_desc.shape: pass elif mode != "valid": pass - elif dpnp.is_cuda_backend(x1) or dpnp.is_cuda_backend(x2): - pass else: return dpnp_correlate(x1_desc, x2_desc).get_pyobj() diff --git a/dpnp/random/dpnp_iface_random.py b/dpnp/random/dpnp_iface_random.py index ee4af1df25d..a0c00bd50eb 100644 --- a/dpnp/random/dpnp_iface_random.py +++ b/dpnp/random/dpnp_iface_random.py @@ -140,6 +140,11 @@ def beta(a, b, size=None): """ if not use_origin_backend(a): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `a`, `b` if not dpnp.isscalar(a): @@ -150,8 +155,6 @@ def beta(a, b, size=None): pass elif b <= 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_beta(a, b, size).get_pyobj() @@ -188,6 +191,11 @@ def binomial(n, p, size=None): """ if not use_origin_backend(n): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `p` param if not dpnp.isscalar(n): @@ -198,8 +206,6 @@ def binomial(n, p, size=None): pass elif n < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_binomial(int(n), p, size).get_pyobj() @@ -242,14 +248,17 @@ def chisquare(df, size=None): """ if not use_origin_backend(df): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `df` if not dpnp.isscalar(df): pass elif df <= 0: pass - elif dpnp.is_cuda_backend(): - pass else: # TODO: # float to int, safe @@ -312,14 +321,17 @@ def exponential(scale=1.0, size=None): """ if not use_origin_backend(scale): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `scale` if not dpnp.isscalar(scale): pass elif scale < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_exponential(scale, size).get_pyobj() @@ -346,6 +358,11 @@ def f(dfnum, dfden, size=None): """ if not use_origin_backend(dfnum): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `dfnum` and `dfden` if not dpnp.isscalar(dfnum): @@ -356,8 +373,6 @@ def f(dfnum, dfden, size=None): pass elif dfden <= 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_f(dfnum, dfden, size).get_pyobj() @@ -386,6 +401,11 @@ def gamma(shape, scale=1.0, size=None): """ if not use_origin_backend(scale): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `scale` and `shape` if not dpnp.isscalar(scale): @@ -396,8 +416,6 @@ def gamma(shape, scale=1.0, size=None): pass elif shape < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_gamma(shape, scale, size).get_pyobj() @@ -426,14 +444,17 @@ def geometric(p, size=None): """ if not use_origin_backend(p): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `p` param if not dpnp.isscalar(p): pass elif p > 1 or p <= 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_geometric(p, size).get_pyobj() @@ -462,6 +483,11 @@ def gumbel(loc=0.0, scale=1.0, size=None): """ if not use_origin_backend(loc): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `loc` and `scale` params if not dpnp.isscalar(scale): @@ -470,8 +496,6 @@ def gumbel(loc=0.0, scale=1.0, size=None): pass elif scale < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_gumbel(loc, scale, size).get_pyobj() @@ -502,6 +526,11 @@ def hypergeometric(ngood, nbad, nsample, size=None): """ if not use_origin_backend(ngood): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of ints for `ngood`, `nbad`, `nsample` param if not dpnp.isscalar(ngood): @@ -520,8 +549,6 @@ def hypergeometric(ngood, nbad, nsample, size=None): pass elif nsample < 1: pass - elif dpnp.is_cuda_backend(): - pass else: _m = int(ngood) _l = int(ngood) + int(nbad) @@ -552,6 +579,11 @@ def laplace(loc=0.0, scale=1.0, size=None): """ if not use_origin_backend(loc): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `loc` and `scale` if not dpnp.isscalar(loc): @@ -560,8 +592,6 @@ def laplace(loc=0.0, scale=1.0, size=None): pass elif scale < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_laplace(loc, scale, size).get_pyobj() @@ -588,6 +618,11 @@ def logistic(loc=0.0, scale=1.0, size=None): """ if not use_origin_backend(loc): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `loc` and `scale` if not dpnp.isscalar(loc): @@ -596,8 +631,6 @@ def logistic(loc=0.0, scale=1.0, size=None): pass elif scale < 0: pass - elif dpnp.is_cuda_backend(): - pass else: result = dpnp_rng_logistic(loc, scale, size).get_pyobj() if size is None or size == 1: @@ -631,6 +664,11 @@ def lognormal(mean=0.0, sigma=1.0, size=None): """ if not use_origin_backend(mean): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `mean` and `sigma` params if not dpnp.isscalar(mean): @@ -639,8 +677,6 @@ def lognormal(mean=0.0, sigma=1.0, size=None): pass elif sigma < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_lognormal(mean, sigma, size).get_pyobj() @@ -690,6 +726,11 @@ def multinomial(n, pvals, size=None): pvals_sum = sum(pvals) pvals_desc = dpnp.get_dpnp_descriptor(dpnp.array(pvals)) d = len(pvals) + if dpnp.is_cuda_backend(pvals_desc.get_array()): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if n < 0: pass elif n > dpnp.iinfo(dpnp.int32).max: @@ -698,8 +739,6 @@ def multinomial(n, pvals, size=None): pass elif pvals_sum < 0.0: pass - elif dpnp.is_cuda_backend(): - pass else: if size is None: shape = (d,) @@ -739,6 +778,13 @@ def multivariate_normal(mean, cov, size=None, check_valid="warn", tol=1e-8): if not use_origin_backend(mean): mean_ = dpnp.get_dpnp_descriptor(dpnp.array(mean, dtype=dpnp.float64)) cov_ = dpnp.get_dpnp_descriptor(dpnp.array(cov, dtype=dpnp.float64)) + if dpnp.is_cuda_backend(mean_.get_array()) or dpnp.is_cuda_backend( + cov_.get_array() + ): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if size is None: shape = [] elif isinstance(size, (int, dpnp.integer)): @@ -751,8 +797,6 @@ def multivariate_normal(mean, cov, size=None, check_valid="warn", tol=1e-8): pass elif mean_.shape[0] != cov_.shape[0]: pass - elif dpnp.is_cuda_backend(): - pass else: final_shape = list(shape[:]) final_shape.append(mean_.shape[0]) @@ -795,6 +839,11 @@ def negative_binomial(n, p, size=None): """ if not use_origin_backend(n): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `p` and `n` params if not dpnp.isscalar(n): @@ -805,8 +854,6 @@ def negative_binomial(n, p, size=None): pass elif n <= 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_negative_binomial(n, p, size).get_pyobj() @@ -882,6 +929,11 @@ def noncentral_chisquare(df, nonc, size=None): """ if not use_origin_backend(df): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `mean` and `scale` if not dpnp.isscalar(df): @@ -892,8 +944,6 @@ def noncentral_chisquare(df, nonc, size=None): pass elif nonc < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_noncentral_chisquare(df, nonc, size).get_pyobj() @@ -938,14 +988,17 @@ def pareto(a, size=None): """ if not use_origin_backend(a): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `a` if not dpnp.isscalar(a): pass elif a <= 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_pareto(a, size).get_pyobj() @@ -1009,14 +1062,17 @@ def poisson(lam=1.0, size=None): """ if not use_origin_backend(lam): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `lam` param if not dpnp.isscalar(lam): pass elif lam < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_poisson(lam, size).get_pyobj() @@ -1046,14 +1102,17 @@ def power(a, size=None): """ if not use_origin_backend(a): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `a` if not dpnp.isscalar(a): pass elif a <= 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_power(a, size).get_pyobj() @@ -1455,14 +1514,17 @@ def rayleigh(scale=1.0, size=None): """ if not use_origin_backend(scale): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `scale` params if not dpnp.isscalar(scale): pass elif scale < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_rayleigh(scale, size).get_pyobj() @@ -1533,10 +1595,14 @@ def shuffle(x1): x1_desc = dpnp.get_dpnp_descriptor(x1, copy_when_strides=False) if x1_desc: + + if dpnp.is_cuda_backend(x1_desc.get_array()): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if not dpnp.is_type_supported(x1_desc.dtype): pass - elif dpnp.is_cuda_backend(x1): - pass else: dpnp_rng_shuffle(x1_desc).get_pyobj() return @@ -1579,6 +1645,11 @@ def seed(seed=None, device=None, sycl_queue=None): ) if not use_origin_backend(seed): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of ints for `seed` if seed is None: @@ -1587,8 +1658,6 @@ def seed(seed=None, device=None, sycl_queue=None): pass elif seed < 0: pass - elif dpnp.is_cuda_backend(): - pass else: # TODO: # migrate to a single approach with RandomState class @@ -1622,9 +1691,10 @@ def standard_cauchy(size=None): if not use_origin_backend(size): if dpnp.is_cuda_backend(): - pass - else: - return dpnp_rng_standard_cauchy(size).get_pyobj() + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + return dpnp_rng_standard_cauchy(size).get_pyobj() return call_origin(numpy.random.standard_cauchy, size) @@ -1650,9 +1720,10 @@ def standard_exponential(size=None): if not use_origin_backend(size): if dpnp.is_cuda_backend(): - pass - else: - return dpnp_rng_standard_exponential(size).get_pyobj() + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + return dpnp_rng_standard_exponential(size).get_pyobj() return call_origin(numpy.random.standard_exponential, size) @@ -1680,14 +1751,17 @@ def standard_gamma(shape, size=None): """ if not use_origin_backend(shape): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `shape` if not dpnp.isscalar(shape): pass elif shape < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_standard_gamma(shape, size).get_pyobj() @@ -1760,14 +1834,17 @@ def standard_t(df, size=None): """ if not use_origin_backend(df): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `df` if not dpnp.isscalar(df): pass elif df <= 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_standard_t(df, size).get_pyobj() @@ -1798,6 +1875,11 @@ def triangular(left, mode, right, size=None): """ if not use_origin_backend(left): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `left`, `mode`, `right`. if not dpnp.isscalar(left): @@ -1812,8 +1894,6 @@ def triangular(left, mode, right, size=None): pass elif left == right: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_triangular(left, mode, right, size).get_pyobj() @@ -1908,6 +1988,11 @@ def vonmises(mu, kappa, size=None): """ if not use_origin_backend(mu): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `mu`, `kappa`. if not dpnp.isscalar(mu): @@ -1918,8 +2003,6 @@ def vonmises(mu, kappa, size=None): return dpnp.nan elif kappa < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_vonmises(mu, kappa, size).get_pyobj() @@ -1946,6 +2029,11 @@ def wald(mean, scale, size=None): """ if not use_origin_backend(mean): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `mean` and `scale` if not dpnp.isscalar(mean): @@ -1956,8 +2044,6 @@ def wald(mean, scale, size=None): pass elif scale <= 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_wald(mean, scale, size).get_pyobj() @@ -1984,14 +2070,17 @@ def weibull(a, size=None): """ if not use_origin_backend(a): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `a` param if not dpnp.isscalar(a): pass elif a < 0: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_weibull(a, size).get_pyobj() @@ -2018,14 +2107,17 @@ def zipf(a, size=None): """ if not use_origin_backend(a): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + # TODO: # array_like of floats for `a` param if not dpnp.isscalar(a): pass elif a <= 1: pass - elif dpnp.is_cuda_backend(): - pass else: return dpnp_rng_zipf(a, size).get_pyobj() diff --git a/dpnp/random/dpnp_random_state.py b/dpnp/random/dpnp_random_state.py index 5425f8f820d..83888dee43e 100644 --- a/dpnp/random/dpnp_random_state.py +++ b/dpnp/random/dpnp_random_state.py @@ -235,12 +235,15 @@ def normal( """ if not use_origin_backend(): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if not dpnp.isscalar(loc): pass elif not dpnp.isscalar(scale): pass - elif dpnp.is_cuda_backend(): - pass else: dtype = self._validate_float_dtype( dtype, (dpnp.float32, dpnp.float64) @@ -366,12 +369,15 @@ def randint(self, low, high=None, size=None, dtype=int, usm_type="device"): """ if not use_origin_backend(low): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if not dpnp.isscalar(low): pass elif not (high is None or dpnp.isscalar(high)): pass - elif dpnp.is_cuda_backend(): - pass else: _dtype = dpnp.int32 if dtype is int else dpnp.dtype(dtype) if _dtype != dpnp.int32: @@ -592,12 +598,15 @@ def uniform( """ if not use_origin_backend(): + if dpnp.is_cuda_backend(): + raise NotImplementedError( + "Running on CUDA is currently not supported" + ) + if not dpnp.isscalar(low): pass elif not dpnp.isscalar(high): pass - elif dpnp.is_cuda_backend(): - pass else: min_double = dpnp.finfo("double").min max_double = dpnp.finfo("double").max From cc485333447e098f4a2732d77f0543b9f32506af Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Fri, 29 Nov 2024 06:05:33 -0800 Subject: [PATCH 14/23] Implement is_cuda_device() func for tests in helper.py --- dpnp/tests/helper.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/dpnp/tests/helper.py b/dpnp/tests/helper.py index 2db95fdeb77..2404bec60dd 100644 --- a/dpnp/tests/helper.py +++ b/dpnp/tests/helper.py @@ -225,6 +225,14 @@ def is_cpu_device(device=None): return dev.has_aspect_cpu +def is_cuda_device(device=None): + """ + Return True if a test is running on CUDA device, False otherwise. + """ + dev = dpctl.select_default_device() if device is None else device + return dev.backend == dpctl.backend_type.cuda + + def is_win_platform(): """ Return True if a test is running on Windows OS, False otherwise. From 645c6d97285da15a816a0c6f86420928ad7d192d Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Fri, 29 Nov 2024 07:28:20 -0800 Subject: [PATCH 15/23] Skipped tests for unsupported functions on CUDA --- dpnp/tests/skipped_tests_cuda.tbl | 950 +++++++++++++++++------------- 1 file changed, 541 insertions(+), 409 deletions(-) diff --git a/dpnp/tests/skipped_tests_cuda.tbl b/dpnp/tests/skipped_tests_cuda.tbl index 99201a47740..456b268f903 100644 --- a/dpnp/tests/skipped_tests_cuda.tbl +++ b/dpnp/tests/skipped_tests_cuda.tbl @@ -1,389 +1,14 @@ -# fft -tests/test_fft.py::TestFftn::test_fftn[C-forward-None-complex64] -tests/test_fft.py::TestFftn::test_fftn[C-forward-None-complex128] -tests/test_fft.py::TestFftn::test_fftn[C-forward-axes2-complex64] -tests/test_fft.py::TestFftn::test_fftn[C-forward-axes2-complex128] -tests/test_fft.py::TestFftn::test_fftn[C-forward-axes3-complex64] -tests/test_fft.py::TestFftn::test_fftn[C-forward-axes3-complex128] -tests/test_fft.py::TestFftn::test_fftn[C-backward-None-complex64] -tests/test_fft.py::TestFftn::test_fftn[C-backward-None-complex128] -tests/test_fft.py::TestFftn::test_fftn[C-backward-axes2-complex64] -tests/test_fft.py::TestFftn::test_fftn[C-backward-axes2-complex128] -tests/test_fft.py::TestFftn::test_fftn[C-backward-axes3-complex64] -tests/test_fft.py::TestFftn::test_fftn[C-backward-axes3-complex128] -tests/test_fft.py::TestFftn::test_fftn[C-ortho-None-complex64] -tests/test_fft.py::TestFftn::test_fftn[C-ortho-None-complex128] -tests/test_fft.py::TestFftn::test_fftn[C-ortho-axes2-complex64] -tests/test_fft.py::TestFftn::test_fftn[C-ortho-axes2-complex128] -tests/test_fft.py::TestFftn::test_fftn[C-ortho-axes3-complex64] -tests/test_fft.py::TestFftn::test_fftn[C-ortho-axes3-complex128] -tests/test_fft.py::TestFftn::test_fftn[F-forward-None-complex64] -tests/test_fft.py::TestFftn::test_fftn[F-forward-None-complex128] -tests/test_fft.py::TestFftn::test_fftn[F-forward-axes1-complex64] -tests/test_fft.py::TestFftn::test_fftn[F-forward-axes1-complex128] -tests/test_fft.py::TestFftn::test_fftn[F-forward-axes3-complex64] -tests/test_fft.py::TestFftn::test_fftn[F-forward-axes3-complex128] -tests/test_fft.py::TestFftn::test_fftn[F-backward-None-complex64] -tests/test_fft.py::TestFftn::test_fftn[F-backward-None-complex128] -tests/test_fft.py::TestFftn::test_fftn[F-backward-axes1-complex64] -tests/test_fft.py::TestFftn::test_fftn[F-backward-axes1-complex128] -tests/test_fft.py::TestFftn::test_fftn[F-backward-axes3-complex64] -tests/test_fft.py::TestFftn::test_fftn[F-backward-axes3-complex128] -tests/test_fft.py::TestFftn::test_fftn[F-ortho-None-complex64] -tests/test_fft.py::TestFftn::test_fftn[F-ortho-None-complex128] -tests/test_fft.py::TestFftn::test_fftn[F-ortho-axes1-complex64] -tests/test_fft.py::TestFftn::test_fftn[F-ortho-axes1-complex128] -tests/test_fft.py::TestFftn::test_fftn[F-ortho-axes3-complex64] -tests/test_fft.py::TestFftn::test_fftn[F-ortho-axes3-complex128] -tests/test_fft.py::TestFftn::test_fftn_repeated_axes_with_s[s1-axes1] -tests/test_fft.py::TestFftn::test_fftn_out[s0-axes0] -tests/test_fft.py::TestFftn::test_fftn_out[s1-axes0] -tests/test_fft.py::TestFftn::test_fftn_out[s2-axes0] -tests/test_fft.py::TestFftn::test_fftn_out[s2-axes1] -tests/test_fft.py::TestFftn::test_fftn_out[s2-axes2] -tests/test_fft.py::TestRfftn::test_rfftn_out[s2-axes0] -tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_50_{axes=None, norm=None, s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_51_{axes=None, norm='backward', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_52_{axes=None, norm='ortho', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_fft2[_param_53_{axes=None, norm='forward', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_ifft2[_param_50_{axes=None, norm=None, s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_ifft2[_param_51_{axes=None, norm='backward', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_ifft2[_param_52_{axes=None, norm='ortho', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFft2::test_ifft2[_param_53_{axes=None, norm='forward', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_fftn[_param_60_{axes=None, norm=None, s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_fftn[_param_61_{axes=None, norm='backward', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_fftn[_param_62_{axes=None, norm='ortho', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_fftn[_param_63_{axes=None, norm='forward', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_60_{axes=None, norm=None, s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_61_{axes=None, norm='backward', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_62_{axes=None, norm='ortho', s=None, shape=(2, 3, 4, 5)}] -tests/third_party/cupy/fft_tests/test_fft.py::TestFftn::test_ifftn[_param_63_{axes=None, norm='forward', s=None, shape=(2, 3, 4, 5)}] +# NotImplementedError -# linalg -tests/test_linalg.py::TestCond::test_cond_nan_input[-dpnp.inf] -tests/test_linalg.py::TestCond::test_cond_nan_input[-1] -tests/test_linalg.py::TestCond::test_cond_nan_input[1] -tests/test_linalg.py::TestCond::test_cond_nan_input[dpnp.inf] -tests/test_linalg.py::TestCond::test_cond_nan_input[fro] -tests/test_linalg.py::TestCond::test_cond_nan[-dpnp.inf] -tests/test_linalg.py::TestCond::test_cond_nan[-1] -tests/test_linalg.py::TestCond::test_cond_nan[1] -tests/test_linalg.py::TestCond::test_cond_nan[dpnp.inf] -tests/test_linalg.py::TestCond::test_cond_nan[fro] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-bool] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-int32] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-int64] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-float32] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-float64] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-complex64] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-complex128] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape6-b_shape6-None] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-bool] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-int32] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-int64] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-float32] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-float64] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-complex64] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-complex128] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape7-b_shape7-None] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-bool] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-int32] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-int64] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-float32] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-float64] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-complex64] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-complex128] -tests/test_linalg.py::TestLstsq::test_lstsq[a_shape8-b_shape8-None] -tests/test_linalg.py::TestNorm::test_matrix_norm[True--2] -tests/test_linalg.py::TestNorm::test_matrix_norm[True-2] -tests/test_linalg.py::TestNorm::test_matrix_norm[True-nuc] -tests/test_linalg.py::TestNorm::test_matrix_norm[False--2] -tests/test_linalg.py::TestNorm::test_matrix_norm[False-2] -tests/test_linalg.py::TestNorm::test_matrix_norm[False-nuc] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-bool] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-int32] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-int64] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-float32] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-float64] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None--2-None] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-bool] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-int32] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-int64] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-float32] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-float64] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-2-None] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-bool] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-int32] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-int64] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-float32] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-float64] -tests/test_linalg.py::TestNorm::test_norm_2D[True-None-nuc-None] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-bool] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-int32] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-int64] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-float32] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-float64] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None--2-None] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-bool] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-int32] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-int64] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-float32] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-float64] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-2-None] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-bool] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-int32] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-int64] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-float32] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-float64] -tests/test_linalg.py::TestNorm::test_norm_2D[False-None-nuc-None] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None--2-complex64] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None--2-complex128] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-2-complex64] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-nuc-complex64] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[True-None-nuc-complex128] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None--2-complex64] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None--2-complex128] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-2-complex64] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-nuc-complex64] -tests/test_linalg.py::TestNorm::test_norm_2D_complex[False-None-nuc-complex128] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-bool] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-int32] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-int64] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-float32] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-float64] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-bool] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-int32] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-int64] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-float32] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-float64] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-bool] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-int32] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-int64] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-float32] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-float64] -tests/test_linalg.py::TestNorm::test_norm_ND[True-(0, 1)-nuc-None] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-bool] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-int32] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-int64] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-float32] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-float64] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-bool] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-int32] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-int64] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-float32] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-float64] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-bool] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-int32] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-int64] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-float32] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-float64] -tests/test_linalg.py::TestNorm::test_norm_ND[False-(0, 1)-nuc-None] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)--2-complex64] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)--2-complex128] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-2-complex64] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-nuc-complex64] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[True-(0, 1)-nuc-complex128] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)--2-complex64] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)--2-complex128] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-2-complex64] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-nuc-complex64] -tests/test_linalg.py::TestNorm::test_norm_ND_complex[False-(0, 1)-nuc-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(0, 1)-nuc-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[True-(-2, -1)-nuc-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(0, 1)-nuc-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)--2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-2-None] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-bool] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-int32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-int64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-float32] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-float64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-complex64] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-complex128] -tests/test_linalg.py::TestNorm::test_norm_usm_ndarray[False-(-2, -1)-nuc-None] -tests/test_linalg.py::TestSvd::test_svd[(3,4)-int32] -tests/test_linalg.py::TestSvd::test_svd[(3,4)-int64] -tests/test_linalg.py::TestSvd::test_svd[(3,4)-float32] -tests/test_linalg.py::TestSvd::test_svd[(3,4)-float64] -tests/test_linalg.py::TestSvd::test_svd[(3,4)-complex64] -tests/test_linalg.py::TestSvd::test_svd[(3,4)-complex128] -tests/test_linalg.py::TestSvd::test_svd[(3,4)-None] -tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-int32] -tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-int64] -tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-float32] -tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-float64] -tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-complex64] -tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-complex128] -tests/test_linalg.py::TestSvdvals::test_svdvals[(3,5)-None] -tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-int32] -tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-int64] -tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-float32] -tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-float64] -tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-complex64] -tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-complex128] -tests/test_linalg.py::TestPinv::test_pinv[(3, 4)-None] -tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-int32] -tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-int64] -tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-float32] -tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-float64] -tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-complex64] -tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-complex128] -tests/test_linalg.py::TestPinv::test_pinv[(2, 2, 4)-None] -tests/test_usm_type.py::test_cond[-inf-device] -tests/test_usm_type.py::test_cond[-inf-shared] -tests/test_usm_type.py::test_cond[-inf-host] -tests/test_usm_type.py::test_cond[-1-device] -tests/test_usm_type.py::test_cond[-1-shared] -tests/test_usm_type.py::test_cond[-1-host] -tests/test_usm_type.py::test_cond[1-device] -tests/test_usm_type.py::test_cond[1-shared] -tests/test_usm_type.py::test_cond[1-host] -tests/test_usm_type.py::test_cond[inf-device] -tests/test_usm_type.py::test_cond[inf-shared] -tests/test_usm_type.py::test_cond[inf-host] -tests/test_usm_type.py::test_cond[fro-device] -tests/test_usm_type.py::test_cond[fro-shared] -tests/test_usm_type.py::test_cond[fro-host] -tests/test_sycl_queue.py::test_norm[(0, 1)--2-cuda:gpu:0] -tests/test_sycl_queue.py::test_norm[(0, 1)-2-cuda:gpu:0] -tests/test_sycl_queue.py::test_norm[(0, 1)-nuc-cuda:gpu:0] -tests/test_sycl_queue.py::test_norm[(-2, -1)--2-cuda:gpu:0] -tests/test_sycl_queue.py::test_norm[(-2, -1)-2-cuda:gpu:0] -tests/test_sycl_queue.py::test_norm[(-2, -1)-nuc-cuda:gpu:0] -tests/test_sycl_queue.py::test_pinv[cuda:gpu:0-(2, 2, 3)] -tests/test_sycl_queue.py::test_pinv[cuda:gpu:0-(2, 2, 3), rcond_as_array] -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank2 -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank2_no_uv -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank3 -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank3_loop -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank3_no_uv -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank3_no_uv_loop -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank4 -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank4_loop -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank4_no_uv -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_0_{full_matrices=True}::test_svd_rank4_no_uv_loop -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank2 -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank2_no_uv -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank3 -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank3_loop -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank3_no_uv -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank3_no_uv_loop -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank4 -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank4_loop -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank4_no_uv -tests/third_party/cupy/linalg_tests/test_decomposition.py::TestSVD_param_1_{full_matrices=False}::test_svd_rank4_no_uv_loop -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_66_{axis=(0, 1), keepdims=True, ord=-2, shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_72_{axis=(0, 1), keepdims=True, ord=2, shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_78_{axis=(0, 1), keepdims=True, ord='nuc', shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_82_{axis=(0, 1), keepdims=False, ord=-2, shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_88_{axis=(0, 1), keepdims=False, ord=2, shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_94_{axis=(0, 1), keepdims=False, ord='nuc', shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_98_{axis=None, keepdims=True, ord=-2, shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_104_{axis=None, keepdims=True, ord=2, shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_110_{axis=None, keepdims=True, ord='nuc', shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_114_{axis=None, keepdims=False, ord=-2, shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_120_{axis=None, keepdims=False, ord=2, shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_norms.py::TestNorm_param_126_{axis=None, keepdims=False, ord='nuc', shape=(1, 2)}::test_norm -tests/third_party/cupy/linalg_tests/test_solve.py::TestPinv::test_pinv -tests/third_party/cupy/linalg_tests/test_solve.py::TestPinv::test_pinv_batched -tests/third_party/cupy/linalg_tests/test_solve.py::TestPinv::test_pinv_batched_vector_rcond -tests/third_party/cupy/linalg_tests/test_solve.py::TestLstsq::test_lstsq_solutions +# modf +tests/test_arithmetic.py::TestArithmetic::test_modf_part1 +tests/test_arithmetic.py::TestArithmetic::test_modf_part2 +tests/test_sycl_queue.py::test_modf[cuda:gpu:0] +tests/test_umath.py::test_umaths[('modf', 'f')] +tests/test_umath.py::test_umaths[('modf', 'd')] +tests/third_party/cupy/math_tests/test_arithmetic.py::TestArithmeticModf::test_modf -# spacing -tests/test_mathematical.py::TestSpacing::test_zeros[float32] - -# random state +# random tests/test_random_state.py::TestNormal::test_distr[host-float32] tests/test_random_state.py::TestNormal::test_distr[host-float64] tests/test_random_state.py::TestNormal::test_distr[host-None] @@ -410,6 +35,12 @@ tests/test_random_state.py::TestNormal::test_inf_scale tests/test_random_state.py::TestNormal::test_inf_loc_scale[numpy.inf] tests/test_random_state.py::TestNormal::test_inf_loc_scale[-numpy.inf] tests/test_random_state.py::TestNormal::test_extreme_bounds +tests/test_random_state.py::TestNormal::test_fallback[[2]-dpnp.array([3])] +tests/test_random_state.py::TestNormal::test_fallback[[2]-numpy.array([3])] +tests/test_random_state.py::TestNormal::test_fallback[dpnp.array([2])-dpnp.array([3])] +tests/test_random_state.py::TestNormal::test_fallback[dpnp.array([2])-numpy.array([3])] +tests/test_random_state.py::TestNormal::test_fallback[numpy.array([2])-dpnp.array([3])] +tests/test_random_state.py::TestNormal::test_fallback[numpy.array([2])-numpy.array([3])] tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.float16] tests/test_random_state.py::TestNormal::test_invalid_dtype[float] tests/test_random_state.py::TestNormal::test_invalid_dtype[dpnp.int64] @@ -437,15 +68,28 @@ tests/test_random_state.py::TestRandInt::test_distr[device-int] tests/test_random_state.py::TestRandInt::test_distr[device-dpnp.int32] tests/test_random_state.py::TestRandInt::test_distr[shared-int] tests/test_random_state.py::TestRandInt::test_distr[shared-dpnp.int32] -tests/test_random_state.py::TestRandInt::test_float_bounds randint +tests/test_random_state.py::TestRandInt::test_float_bounds tests/test_random_state.py::TestRandInt::test_negative_bounds tests/test_random_state.py::TestRandInt::test_negative_interval tests/test_random_state.py::TestRandInt::test_bounds_checking tests/test_random_state.py::TestRandInt::test_rng_zero_and_extremes +tests/test_random_state.py::TestRandInt::test_full_range +tests/test_random_state.py::TestRandInt::test_in_bounds_fuzz tests/test_random_state.py::TestRandInt::test_zero_size[(3, 0, 4)] tests/test_random_state.py::TestRandInt::test_zero_size[0] tests/test_random_state.py::TestRandInt::test_zero_size[(0,)] tests/test_random_state.py::TestRandInt::test_zero_size[()] +tests/test_random_state.py::TestRandInt::test_bounds_fallback[[2]-dpnp.array([3])] +tests/test_random_state.py::TestRandInt::test_bounds_fallback[[2]-numpy.array([3])] +tests/test_random_state.py::TestRandInt::test_bounds_fallback[dpnp.array([2])-dpnp.array([3])] +tests/test_random_state.py::TestRandInt::test_bounds_fallback[dpnp.array([2])-numpy.array([3])] +tests/test_random_state.py::TestRandInt::test_bounds_fallback[numpy.array([2])-dpnp.array([3])] +tests/test_random_state.py::TestRandInt::test_bounds_fallback[numpy.array([2])-numpy.array([3])] +tests/test_random_state.py::TestRandInt::test_dtype_fallback[dpnp.int64] +tests/test_random_state.py::TestRandInt::test_dtype_fallback[dpnp.int] +tests/test_random_state.py::TestRandInt::test_dtype_fallback[dpnp.bool] +tests/test_random_state.py::TestRandInt::test_dtype_fallback[dpnp.bool_] +tests/test_random_state.py::TestRandInt::test_dtype_fallback[bool] tests/test_random_state.py::TestRandInt::test_invalid_usm_type[Empty] tests/test_random_state.py::TestRandInt::test_invalid_usm_type[Unknown] tests/test_random_state.py::TestRandN::test_distr[host] @@ -504,6 +148,13 @@ tests/test_random_state.py::TestUniform::test_low_high_equal[shared-float32] tests/test_random_state.py::TestUniform::test_low_high_equal[shared-float64] tests/test_random_state.py::TestUniform::test_low_high_equal[shared-int32] tests/test_random_state.py::TestUniform::test_low_high_equal[shared-None] +tests/test_random_state.py::TestUniform::test_range_bounds +tests/test_random_state.py::TestUniform::test_fallback[[2]-dpnp.array([3])] +tests/test_random_state.py::TestUniform::test_fallback[[2]-numpy.array([3])] +tests/test_random_state.py::TestUniform::test_fallback[dpnp.array([2])-dpnp.array([3])] +tests/test_random_state.py::TestUniform::test_fallback[dpnp.array([2])-numpy.array([3])] +tests/test_random_state.py::TestUniform::test_fallback[numpy.array([2])-dpnp.array([3])] +tests/test_random_state.py::TestUniform::test_fallback[numpy.array([2])-numpy.array([3])] tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.float16] tests/test_random_state.py::TestUniform::test_invalid_dtype[float] tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.int64] @@ -516,9 +167,138 @@ tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.bool] tests/test_random_state.py::TestUniform::test_invalid_dtype[dpnp.bool_] tests/test_random_state.py::TestUniform::test_invalid_usm_type[Empty] tests/test_random_state.py::TestUniform::test_invalid_usm_type[Unknown] -tests/test_random_state.py::TestRandInt::test_float_bounds -tests/test_random_state.py::TestRandInt::test_full_range -tests/test_random_state.py::TestUniform::test_range_bounds + +tests/test_random.py::test_input_size[chisquare] +tests/test_random.py::test_input_size[rand] +tests/test_random.py::test_input_size[randn] +tests/test_random.py::test_input_shape[chisquare] +tests/test_random.py::test_input_shape[random] +tests/test_random.py::test_input_shape[random_sample] +tests/test_random.py::test_input_shape[ranf] +tests/test_random.py::test_input_shape[sample] +tests/test_random.py::test_check_output[random] +tests/test_random.py::test_check_output[random_sample] +tests/test_random.py::test_check_output[ranf] +tests/test_random.py::test_check_output[sample] +tests/test_random.py::test_check_output[rand] +tests/test_random.py::test_seed[random] +tests/test_random.py::test_seed[random_sample] +tests/test_random.py::test_seed[ranf] +tests/test_random.py::test_seed[sample] +tests/test_random.py::test_seed[rand] +tests/test_random.py::test_randn_normal_distribution +tests/test_random.py::TestDistributionsBeta::test_invalid_args +tests/test_random.py::TestDistributionsBeta::test_moments +tests/test_random.py::TestDistributionsBeta::test_seed +tests/test_random.py::TestDistributionsBinomial::test_extreme_value +tests/test_random.py::TestDistributionsBinomial::test_invalid_args +tests/test_random.py::TestDistributionsBinomial::test_moments +tests/test_random.py::TestDistributionsBinomial::test_seed +tests/test_random.py::TestDistributionsChisquare::test_invalid_args +tests/test_random.py::TestDistributionsChisquare::test_seed +tests/test_random.py::TestDistributionsExponential::test_invalid_args +tests/test_random.py::TestDistributionsExponential::test_seed +tests/test_random.py::TestDistributionsF::test_invalid_args +tests/test_random.py::TestDistributionsF::test_moments +tests/test_random.py::TestDistributionsF::test_seed +tests/test_random.py::TestDistributionsGamma::test_invalid_args +tests/test_random.py::TestDistributionsGamma::test_moments +tests/test_random.py::TestDistributionsGamma::test_seed +tests/test_random.py::TestDistributionsGeometric::test_extreme_value +tests/test_random.py::TestDistributionsGeometric::test_invalid_args +tests/test_random.py::TestDistributionsGeometric::test_moments +tests/test_random.py::TestDistributionsGeometric::test_seed +tests/test_random.py::TestDistributionsGumbel::test_extreme_value +tests/test_random.py::TestDistributionsGumbel::test_invalid_args +tests/test_random.py::TestDistributionsGumbel::test_moments +tests/test_random.py::TestDistributionsGumbel::test_seed +tests/test_random.py::TestDistributionsHypergeometric::test_extreme_value +tests/test_random.py::TestDistributionsHypergeometric::test_invalid_args +tests/test_random.py::TestDistributionsHypergeometric::test_moments +tests/test_random.py::TestDistributionsHypergeometric::test_seed +tests/test_random.py::TestDistributionsLaplace::test_extreme_value +tests/test_random.py::TestDistributionsLaplace::test_invalid_args +tests/test_random.py::TestDistributionsLaplace::test_moments +tests/test_random.py::TestDistributionsLaplace::test_seed +tests/test_random.py::TestDistributionsLogistic::test_invalid_args +tests/test_random.py::TestDistributionsLogistic::test_moments +tests/test_random.py::TestDistributionsLogistic::test_seed +tests/test_random.py::TestDistributionsLognormal::test_extreme_value +tests/test_random.py::TestDistributionsLognormal::test_invalid_args +tests/test_random.py::TestDistributionsLognormal::test_moments +tests/test_random.py::TestDistributionsLognormal::test_seed +tests/test_random.py::TestDistributionsMultinomial::test_check_sum +tests/test_random.py::TestDistributionsMultinomial::test_extreme_value +tests/test_random.py::TestDistributionsMultinomial::test_invalid_args +tests/test_random.py::TestDistributionsMultinomial::test_moments +tests/test_random.py::TestDistributionsMultinomial::test_seed +tests/test_random.py::TestDistributionsMultinomial::test_seed1 +tests/test_random.py::TestDistributionsMultivariateNormal::test_invalid_args +tests/test_random.py::TestDistributionsNegativeBinomial::test_extreme_value +tests/test_random.py::TestDistributionsNegativeBinomial::test_invalid_args +tests/test_random.py::TestDistributionsNegativeBinomial::test_seed +tests/test_random.py::TestDistributionsNormal::test_extreme_value +tests/test_random.py::TestDistributionsNormal::test_invalid_args +tests/test_random.py::TestDistributionsNormal::test_moments +tests/test_random.py::TestDistributionsNormal::test_seed +tests/test_random.py::TestDistributionsNoncentralChisquare::test_moments[df_grt_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_moments[df_eq_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_moments[df_less_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_invalid_args +tests/test_random.py::TestDistributionsNoncentralChisquare::test_seed[df_grt_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_seed[df_eq_1] +tests/test_random.py::TestDistributionsNoncentralChisquare::test_seed[df_less_1] +tests/test_random.py::TestDistributionsPareto::test_invalid_args +tests/test_random.py::TestDistributionsPareto::test_moments +tests/test_random.py::TestDistributionsPareto::test_seed +tests/test_random.py::TestDistributionsPoisson::test_extreme_value +tests/test_random.py::TestDistributionsPoisson::test_invalid_args +tests/test_random.py::TestDistributionsPoisson::test_moments +tests/test_random.py::TestDistributionsPoisson::test_seed +tests/test_random.py::TestDistributionsPower::test_invalid_args +tests/test_random.py::TestDistributionsPower::test_moments +tests/test_random.py::TestDistributionsPower::test_seed +tests/test_random.py::TestDistributionsRayleigh::test_extreme_value +tests/test_random.py::TestDistributionsRayleigh::test_invalid_args +tests/test_random.py::TestDistributionsRayleigh::test_moments +tests/test_random.py::TestDistributionsRayleigh::test_seed +tests/test_random.py::TestDistributionsStandardCauchy::test_seed +tests/test_random.py::TestDistributionsStandardExponential::test_moments +tests/test_random.py::TestDistributionsStandardExponential::test_seed +tests/test_random.py::TestDistributionsStandardGamma::test_extreme_value +tests/test_random.py::TestDistributionsStandardGamma::test_invalid_args +tests/test_random.py::TestDistributionsStandardGamma::test_moments +tests/test_random.py::TestDistributionsStandardGamma::test_seed +tests/test_random.py::TestDistributionsStandardNormal::test_moments +tests/test_random.py::TestDistributionsStandardNormal::test_seed +tests/test_random.py::TestDistributionsStandardT::test_invalid_args +tests/test_random.py::TestDistributionsStandardT::test_moments +tests/test_random.py::TestDistributionsStandardT::test_seed +tests/test_random.py::TestDistributionsTriangular::test_invalid_args +tests/test_random.py::TestDistributionsTriangular::test_moments +tests/test_random.py::TestDistributionsTriangular::test_seed +tests/test_random.py::TestDistributionsUniform::test_extreme_value +tests/test_random.py::TestDistributionsUniform::test_moments +tests/test_random.py::TestDistributionsUniform::test_seed +tests/test_random.py::TestDistributionsVonmises::test_moments[large_kappa] +tests/test_random.py::TestDistributionsVonmises::test_moments[small_kappa] +tests/test_random.py::TestDistributionsVonmises::test_invalid_args +tests/test_random.py::TestDistributionsVonmises::test_seed[large_kappa] +tests/test_random.py::TestDistributionsVonmises::test_seed[small_kappa] +tests/test_random.py::TestDistributionsWald::test_invalid_args +tests/test_random.py::TestDistributionsWald::test_moments +tests/test_random.py::TestDistributionsWald::test_seed +tests/test_random.py::TestDistributionsWeibull::test_extreme_value +tests/test_random.py::TestDistributionsWeibull::test_invalid_args +tests/test_random.py::TestDistributionsWeibull::test_seed +tests/test_random.py::TestDistributionsZipf::test_invalid_args +tests/test_random.py::TestDistributionsZipf::test_seed +tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1[lambda x: dpnp.array([])] +tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1[lambda x: dpnp.astype(dpnp.asarray(x), dpnp.float32)] +tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1[lambda x: dpnp.asarray([[i, i] for i in x])] +tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1_fallback[lambda x: x] +tests/test_random.py::TestPermutationsTestShuffle::test_shuffle1_fallback[lambda x: [(i, i) for i in x]] + tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-normal-kwargs0] tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-rand-kwargs1] tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-randint-kwargs2] @@ -530,17 +310,6 @@ tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-ranf-kwargs7] tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-sample-kwargs8] tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-standard_normal-kwargs9] tests/test_sycl_queue.py::test_random[host-cuda:gpu:0-uniform-kwargs10] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-normal-kwargs0] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-rand-kwargs1] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-randint-kwargs2] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-randn-kwargs3] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-random-kwargs4] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-random_integers-kwargs5] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-random_sample-kwargs6] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-ranf-kwargs7] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-sample-kwargs8] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-standard_normal-kwargs9] -tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-uniform-kwargs10] tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-normal-kwargs0] tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-rand-kwargs1] tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-randint-kwargs2] @@ -552,6 +321,17 @@ tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-ranf-kwargs7] tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-sample-kwargs8] tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-standard_normal-kwargs9] tests/test_sycl_queue.py::test_random[device-cuda:gpu:0-uniform-kwargs10] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-normal-kwargs0] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-rand-kwargs1] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-randint-kwargs2] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-randn-kwargs3] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-random-kwargs4] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-random_integers-kwargs5] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-random_sample-kwargs6] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-ranf-kwargs7] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-sample-kwargs8] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-standard_normal-kwargs9] +tests/test_sycl_queue.py::test_random[shared-cuda:gpu:0-uniform-kwargs10] tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-normal-args0-kwargs0] tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-rand-args1-kwargs1] tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-randint-args2-kwargs2] @@ -559,13 +339,6 @@ tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-randn-args3-kwargs3] tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-random_sample-args4-kwargs4] tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-standard_normal-args5-kwargs5] tests/test_sycl_queue.py::test_random_state[host-cuda:gpu:0-uniform-args6-kwargs6] -tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-normal-args0-kwargs0] -tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-rand-args1-kwargs1] -tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-randint-args2-kwargs2] -tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-randn-args3-kwargs3] -tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-random_sample-args4-kwargs4] -tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-standard_normal-args5-kwargs5] -tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-uniform-args6-kwargs6] tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-normal-args0-kwargs0] tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-rand-args1-kwargs1] tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-randint-args2-kwargs2] @@ -573,6 +346,365 @@ tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-randn-args3-kwargs tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-random_sample-args4-kwargs4] tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-standard_normal-args5-kwargs5] tests/test_sycl_queue.py::test_random_state[device-cuda:gpu:0-uniform-args6-kwargs6] -tests/test_random.py::TestDistributionsGeometric::test_moments -tests/test_random.py::TestDistributionsLaplace::test_extreme_value -tests/test_random.py::TestDistributionsPareto::test_moments +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-normal-args0-kwargs0] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-rand-args1-kwargs1] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-randint-args2-kwargs2] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-randn-args3-kwargs3] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-random_sample-args4-kwargs4] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-standard_normal-args5-kwargs5] +tests/test_sycl_queue.py::test_random_state[shared-cuda:gpu:0-uniform-args6-kwargs6] + +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsBeta_param_6_{a_shape=(3, 2), b_shape=(3, 2), shape=(4, 3, 2)}::test_beta +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsBeta_param_7_{a_shape=(3, 2), b_shape=(3, 2), shape=(3, 2)}::test_beta +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsChisquare_param_0_{df_shape=(), shape=(4, 3, 2)}::test_chisquare +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsChisquare_param_1_{df_shape=(), shape=(3, 2)}::test_chisquare +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsChisquare_param_2_{df_shape=(3, 2), shape=(4, 3, 2)}::test_chisquare +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsChisquare_param_3_{df_shape=(3, 2), shape=(3, 2)}::test_chisquare +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsExponential_param_3_{scale_shape=(3, 2), shape=(4, 3, 2)}::test_exponential +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsExponential_param_4_{scale_shape=(3, 2), shape=(3, 2)}::test_exponential +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsExponential_param_5_{scale_shape=(3, 2), shape=None}::test_exponential +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsExponentialError::test_negative_scale +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsF_param_0_{dfden_shape=(), dfnum_shape=(), shape=(4, 3, 2)}::test_f +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsF_param_1_{dfden_shape=(), dfnum_shape=(), shape=(3, 2)}::test_f +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsF_param_2_{dfden_shape=(), dfnum_shape=(3, 2), shape=(4, 3, 2)}::test_f +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsF_param_3_{dfden_shape=(), dfnum_shape=(3, 2), shape=(3, 2)}::test_f +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsF_param_4_{dfden_shape=(3, 2), dfnum_shape=(), shape=(4, 3, 2)}::test_f +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsF_param_5_{dfden_shape=(3, 2), dfnum_shape=(), shape=(3, 2)}::test_f +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsF_param_6_{dfden_shape=(3, 2), dfnum_shape=(3, 2), shape=(4, 3, 2)}::test_f +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsF_param_7_{dfden_shape=(3, 2), dfnum_shape=(3, 2), shape=(3, 2)}::test_f +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGamma_param_0_{scale_shape=(), shape=(4, 3, 2), shape_shape=()}::test_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGamma_param_1_{scale_shape=(), shape=(4, 3, 2), shape_shape=(3, 2)}::test_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGamma_param_2_{scale_shape=(), shape=(3, 2), shape_shape=()}::test_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGamma_param_3_{scale_shape=(), shape=(3, 2), shape_shape=(3, 2)}::test_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGamma_param_4_{scale_shape=(3, 2), shape=(4, 3, 2), shape_shape=()}::test_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGamma_param_5_{scale_shape=(3, 2), shape=(4, 3, 2), shape_shape=(3, 2)}::test_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGamma_param_6_{scale_shape=(3, 2), shape=(3, 2), shape_shape=()}::test_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGamma_param_7_{scale_shape=(3, 2), shape=(3, 2), shape_shape=(3, 2)}::test_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGumbel_param_6_{loc_shape=(3, 2), scale_shape=(3, 2), shape=(4, 3, 2)}::test_gumbel +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsGumbel_param_7_{loc_shape=(3, 2), scale_shape=(3, 2), shape=(3, 2)}::test_gumbel +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsuLaplace_param_6_{loc_shape=(3, 2), scale_shape=(3, 2), shape=(4, 3, 2)}::test_laplace +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsuLaplace_param_7_{loc_shape=(3, 2), scale_shape=(3, 2), shape=(3, 2)}::test_laplace +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsLogistic_param_6_{loc_shape=(3, 2), scale_shape=(3, 2), shape=(4, 3, 2)}::test_logistic +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsLogistic_param_7_{loc_shape=(3, 2), scale_shape=(3, 2), shape=(3, 2)}::test_logistic +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNegativeBinomial_param_6_{n_shape=(3, 2), p_shape=(3, 2), shape=(4, 3, 2)}::test_negative_binomial +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNegativeBinomial_param_6_{n_shape=(3, 2), p_shape=(3, 2), shape=(4, 3, 2)}::test_negative_binomial_for_noninteger_n +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNegativeBinomial_param_7_{n_shape=(3, 2), p_shape=(3, 2), shape=(3, 2)}::test_negative_binomial +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNegativeBinomial_param_7_{n_shape=(3, 2), p_shape=(3, 2), shape=(3, 2)}::test_negative_binomial_for_noninteger_n +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_0_{df_shape=(), nonc_shape=(), shape=(4, 3, 2)}::test_noncentral_chisquare_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_1_{df_shape=(), nonc_shape=(), shape=(3, 2)}::test_noncentral_chisquare_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_2_{df_shape=(), nonc_shape=(3, 2), shape=(4, 3, 2)}::test_noncentral_chisquare_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_3_{df_shape=(), nonc_shape=(3, 2), shape=(3, 2)}::test_noncentral_chisquare_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_4_{df_shape=(3, 2), nonc_shape=(), shape=(4, 3, 2)}::test_noncentral_chisquare_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_5_{df_shape=(3, 2), nonc_shape=(), shape=(3, 2)}::test_noncentral_chisquare_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_6_{df_shape=(3, 2), nonc_shape=(3, 2), shape=(4, 3, 2)}::test_noncentral_chisquare +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_6_{df_shape=(3, 2), nonc_shape=(3, 2), shape=(4, 3, 2)}::test_noncentral_chisquare_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_7_{df_shape=(3, 2), nonc_shape=(3, 2), shape=(3, 2)}::test_noncentral_chisquare +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNoncentralChisquare_param_7_{df_shape=(3, 2), nonc_shape=(3, 2), shape=(3, 2)}::test_noncentral_chisquare_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNormal_param_0_{loc_shape=(), scale_shape=(), shape=(4, 3, 2)}::test_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNormal_param_1_{loc_shape=(), scale_shape=(), shape=(3, 2)}::test_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNormal_param_2_{loc_shape=(), scale_shape=(3, 2), shape=(4, 3, 2)}::test_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNormal_param_3_{loc_shape=(), scale_shape=(3, 2), shape=(3, 2)}::test_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNormal_param_4_{loc_shape=(3, 2), scale_shape=(), shape=(4, 3, 2)}::test_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNormal_param_5_{loc_shape=(3, 2), scale_shape=(), shape=(3, 2)}::test_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNormal_param_6_{loc_shape=(3, 2), scale_shape=(3, 2), shape=(4, 3, 2)}::test_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsNormal_param_7_{loc_shape=(3, 2), scale_shape=(3, 2), shape=(3, 2)}::test_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsPareto_param_0_{a_shape=(), shape=(4, 3, 2)}::test_pareto +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsPareto_param_1_{a_shape=(), shape=(3, 2)}::test_pareto +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsPareto_param_2_{a_shape=(3, 2), shape=(4, 3, 2)}::test_pareto +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsPareto_param_3_{a_shape=(3, 2), shape=(3, 2)}::test_pareto +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsRayleigh_param_2_{scale_shape=(3, 2), shape=(4, 3, 2)}::test_rayleigh +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsRayleigh_param_2_{scale_shape=(3, 2), shape=(4, 3, 2)}::test_rayleigh_for_negative_scale +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsRayleigh_param_2_{scale_shape=(3, 2), shape=(4, 3, 2)}::test_rayleigh_for_zero_scale +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsRayleigh_param_3_{scale_shape=(3, 2), shape=(3, 2)}::test_rayleigh +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsRayleigh_param_3_{scale_shape=(3, 2), shape=(3, 2)}::test_rayleigh_for_negative_scale +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsRayleigh_param_3_{scale_shape=(3, 2), shape=(3, 2)}::test_rayleigh_for_zero_scale +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardCauchy_param_0_{shape=(4, 3, 2)}::test_standard_cauchy +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardCauchy_param_1_{shape=(3, 2)}::test_standard_cauchy +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardExponential_param_0_{shape=(4, 3, 2)}::test_standard_exponential +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardExponential_param_1_{shape=(3, 2)}::test_standard_exponential +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardGamma_param_1_{shape=(4, 3, 2), shape_shape=(3, 2)}::test_standard_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardGamma_param_3_{shape=(3, 2), shape_shape=(3, 2)}::test_standard_gamma +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardNormal_param_0_{shape=(4, 3, 2)}::test_standard_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardNormal_param_1_{shape=(3, 2)}::test_standard_normal +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardT_param_0_{df_shape=(), shape=(4, 3, 2)}::test_standard_t +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardT_param_1_{df_shape=(), shape=(3, 2)}::test_standard_t +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardT_param_2_{df_shape=(3, 2), shape=(4, 3, 2)}::test_standard_t +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsStandardT_param_3_{df_shape=(3, 2), shape=(3, 2)}::test_standard_t +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_0_{left_shape=(), mode_shape=(), right_shape=(), shape=(4, 3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_1_{left_shape=(), mode_shape=(), right_shape=(), shape=(3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_2_{left_shape=(), mode_shape=(), right_shape=(3, 2), shape=(4, 3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_3_{left_shape=(), mode_shape=(), right_shape=(3, 2), shape=(3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_4_{left_shape=(), mode_shape=(3, 2), right_shape=(), shape=(4, 3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_5_{left_shape=(), mode_shape=(3, 2), right_shape=(), shape=(3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_6_{left_shape=(), mode_shape=(3, 2), right_shape=(3, 2), shape=(4, 3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_7_{left_shape=(), mode_shape=(3, 2), right_shape=(3, 2), shape=(3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_8_{left_shape=(3, 2), mode_shape=(), right_shape=(), shape=(4, 3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_9_{left_shape=(3, 2), mode_shape=(), right_shape=(), shape=(3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_10_{left_shape=(3, 2), mode_shape=(), right_shape=(3, 2), shape=(4, 3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_11_{left_shape=(3, 2), mode_shape=(), right_shape=(3, 2), shape=(3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_12_{left_shape=(3, 2), mode_shape=(3, 2), right_shape=(), shape=(4, 3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_13_{left_shape=(3, 2), mode_shape=(3, 2), right_shape=(), shape=(3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_14_{left_shape=(3, 2), mode_shape=(3, 2), right_shape=(3, 2), shape=(4, 3, 2)}::test_triangular +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_14_{left_shape=(3, 2), mode_shape=(3, 2), right_shape=(3, 2), shape=(4, 3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_15_{left_shape=(3, 2), mode_shape=(3, 2), right_shape=(3, 2), shape=(3, 2)}::test_triangular +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsTriangular_param_15_{left_shape=(3, 2), mode_shape=(3, 2), right_shape=(3, 2), shape=(3, 2)}::test_triangular_for_invalid_params +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsUniform_param_2_{high_shape=(), low_shape=(3, 2), shape=(4, 3, 2)}::test_uniform +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsUniform_param_3_{high_shape=(), low_shape=(3, 2), shape=(3, 2)}::test_uniform +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsUniform_param_6_{high_shape=(3, 2), low_shape=(3, 2), shape=(4, 3, 2)}::test_uniform +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsUniform_param_7_{high_shape=(3, 2), low_shape=(3, 2), shape=(3, 2)}::test_uniform +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsVonmises_param_0_{kappa_shape=(), mu_shape=(), shape=(4, 3, 2)}::test_vonmises +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsVonmises_param_1_{kappa_shape=(), mu_shape=(), shape=(3, 2)}::test_vonmises +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsVonmises_param_2_{kappa_shape=(), mu_shape=(3, 2), shape=(4, 3, 2)}::test_vonmises +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsVonmises_param_3_{kappa_shape=(), mu_shape=(3, 2), shape=(3, 2)}::test_vonmises +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsVonmises_param_4_{kappa_shape=(3, 2), mu_shape=(), shape=(4, 3, 2)}::test_vonmises +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsVonmises_param_5_{kappa_shape=(3, 2), mu_shape=(), shape=(3, 2)}::test_vonmises +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsVonmises_param_6_{kappa_shape=(3, 2), mu_shape=(3, 2), shape=(4, 3, 2)}::test_vonmises +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsVonmises_param_7_{kappa_shape=(3, 2), mu_shape=(3, 2), shape=(3, 2)}::test_vonmises +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsWald_param_6_{mean_shape=(3, 2), scale_shape=(3, 2), shape=(4, 3, 2)}::test_wald +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsWald_param_7_{mean_shape=(3, 2), scale_shape=(3, 2), shape=(3, 2)}::test_wald +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsWeibull_param_2_{a_shape=(3, 2), shape=(4, 3, 2)}::test_weibull +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsWeibull_param_2_{a_shape=(3, 2), shape=(4, 3, 2)}::test_weibull_for_inf_a +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsWeibull_param_2_{a_shape=(3, 2), shape=(4, 3, 2)}::test_weibull_for_negative_a +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsWeibull_param_3_{a_shape=(3, 2), shape=(3, 2)}::test_weibull +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsWeibull_param_3_{a_shape=(3, 2), shape=(3, 2)}::test_weibull_for_inf_a +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsWeibull_param_3_{a_shape=(3, 2), shape=(3, 2)}::test_weibull_for_negative_a +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsZipf_param_2_{a_shape=(3, 2), shape=(4, 3, 2)}::test_zipf +tests/third_party/cupy/random_tests/test_distributions.py::TestDistributionsZipf_param_3_{a_shape=(3, 2), shape=(3, 2)}::test_zipf +tests/third_party/cupy/random_tests/test_sample.py::TestRandint::test_lo_hi_equal +tests/third_party/cupy/random_tests/test_sample.py::TestRandint::test_lo_hi_nonrandom +tests/third_party/cupy/random_tests/test_sample.py::TestRandint::test_lo_hi_reversed +tests/third_party/cupy/random_tests/test_sample.py::TestRandint::test_zero_sizes +tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_1 +tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_2 +tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_float2 +tests/third_party/cupy/random_tests/test_sample.py::TestRandint2::test_bound_overflow +tests/third_party/cupy/random_tests/test_sample.py::TestRandintDtype::test_dtype +tests/third_party/cupy/random_tests/test_sample.py::TestRandintDtype::test_dtype2 + +# partition +tests/test_sort.py::test_partition[[3, 4, 2, 1]-bool-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-bool-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-int32-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-int32-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-int64-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-int64-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-float32-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-float32-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-float64-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-float64-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex64-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex64-1] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex128-0] +tests/test_sort.py::test_partition[[3, 4, 2, 1]-complex128-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-bool-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-bool-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int32-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int32-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int64-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-int64-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float32-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float32-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float64-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-float64-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex64-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex64-1] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex128-0] +tests/test_sort.py::test_partition[[[1, 0], [3, 0]]-complex128-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-bool-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-bool-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int32-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int32-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int64-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-int64-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float32-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float32-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float64-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-float64-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex64-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex64-1] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex128-0] +tests/test_sort.py::test_partition[[[3, 2], [1, 6]]-complex128-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-bool-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-bool-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int32-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int32-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int64-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-int64-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float32-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float32-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float64-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-float64-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex64-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex64-1] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex128-0] +tests/test_sort.py::test_partition[[[4, 2, 3], [3, 4, 1]]-complex128-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-bool-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-bool-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int32-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int32-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int64-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-int64-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float32-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float32-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float64-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-float64-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex64-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex64-1] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex128-0] +tests/test_sort.py::test_partition[[[[1, -3], [3, 0]], [[5, 2], [0, 1]], [[1, 0], [0, 1]]]-complex128-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-bool-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-bool-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int32-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int32-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int64-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-int64-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float32-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float32-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float64-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-float64-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex64-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex64-1] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex128-0] +tests/test_sort.py::test_partition[[[[[8, 2], [3, 0]], [[5, 2], [0, 1]]], [[[1, 3], [3, 1]], [[5, 2], [0, 1]]]]-complex128-1] + +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_negative_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_negative_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_invalid_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_negative_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_non_contiguous +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_one_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_sequence_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_0_{external=False, length=10}::test_partition_zero_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_negative_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_negative_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_invalid_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_negative_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_non_contiguous +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_one_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_sequence_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_1_{external=False, length=20000}::test_partition_zero_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_negative_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_negative_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_invalid_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_negative_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_non_contiguous +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_none_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_one_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_sequence_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_2_{external=True, length=10}::test_partition_zero_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_negative_axis1 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_negative_axis2 +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_invalid_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_negative_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_negative_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_non_contiguous +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_none_axis +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_one_dim +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_sequence_kth +tests/third_party/cupy/sorting_tests/test_sort.py::TestPartition_param_3_{external=True, length=20000}::test_partition_zero_dim + +# erf +tests/test_special.py::test_erf +tests/test_special.py::test_erf_fallback +tests/test_strides.py::test_strides_erf[(10,)-int32] +tests/test_strides.py::test_strides_erf[(10,)-int64] +tests/test_strides.py::test_strides_erf[(10,)-float32] +tests/test_strides.py::test_strides_erf[(10,)-float64] +tests/test_strides.py::test_strides_erf[(10,)-None] + +# choose +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_broadcast +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_broadcast2 +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_broadcast_fail +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_clip +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_choose_wrap +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_raise +tests/third_party/cupy/indexing_tests/test_indexing.py::TestChoose::test_unknown_clip + +# correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_0_{mode='valid', shape1=(5,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_1_{mode='valid', shape1=(5,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_2_{mode='valid', shape1=(5,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_3_{mode='valid', shape1=(5,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_4_{mode='valid', shape1=(6,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_5_{mode='valid', shape1=(6,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_6_{mode='valid', shape1=(6,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_7_{mode='valid', shape1=(6,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_8_{mode='valid', shape1=(20,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_9_{mode='valid', shape1=(20,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_10_{mode='valid', shape1=(20,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_11_{mode='valid', shape1=(20,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_12_{mode='valid', shape1=(21,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_13_{mode='valid', shape1=(21,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_14_{mode='valid', shape1=(21,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_15_{mode='valid', shape1=(21,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_16_{mode='same', shape1=(5,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_17_{mode='same', shape1=(5,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_18_{mode='same', shape1=(5,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_19_{mode='same', shape1=(5,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_20_{mode='same', shape1=(6,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_21_{mode='same', shape1=(6,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_22_{mode='same', shape1=(6,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_23_{mode='same', shape1=(6,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_24_{mode='same', shape1=(20,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_25_{mode='same', shape1=(20,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_26_{mode='same', shape1=(20,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_27_{mode='same', shape1=(20,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_28_{mode='same', shape1=(21,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_29_{mode='same', shape1=(21,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_30_{mode='same', shape1=(21,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_31_{mode='same', shape1=(21,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_32_{mode='full', shape1=(5,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_33_{mode='full', shape1=(5,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_34_{mode='full', shape1=(5,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_35_{mode='full', shape1=(5,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_36_{mode='full', shape1=(6,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_37_{mode='full', shape1=(6,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_38_{mode='full', shape1=(6,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_39_{mode='full', shape1=(6,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_40_{mode='full', shape1=(20,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_41_{mode='full', shape1=(20,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_42_{mode='full', shape1=(20,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_43_{mode='full', shape1=(20,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_44_{mode='full', shape1=(21,), shape2=(5,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_45_{mode='full', shape1=(21,), shape2=(6,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_46_{mode='full', shape1=(21,), shape2=(20,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateShapeCombination_param_47_{mode='full', shape1=(21,), shape2=(21,)}::test_correlate +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_0_{mode='valid'}::test_correlate_diff_types +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_0_{mode='valid'}::test_correlate_large_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_0_{mode='valid'}::test_correlate_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_1_{mode='full'}::test_correlate_diff_types +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_1_{mode='full'}::test_correlate_large_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_1_{mode='full'}::test_correlate_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_2_{mode='same'}::test_correlate_diff_types +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_2_{mode='same'}::test_correlate_large_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelate_param_2_{mode='same'}::test_correlate_non_contiguous +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_0_{mode='valid'}::test_correlate_empty +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_0_{mode='valid'}::test_correlate_ndim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_0_{mode='valid'}::test_correlate_zero_dim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_1_{mode='same'}::test_correlate_empty +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_1_{mode='same'}::test_correlate_ndim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_1_{mode='same'}::test_correlate_zero_dim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_2_{mode='full'}::test_correlate_empty +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_2_{mode='full'}::test_correlate_ndim +tests/third_party/cupy/statistics_tests/test_correlation.py::TestCorrelateInvalid_param_2_{mode='full'}::test_correlate_zero_dim From 6f688fef8d2aa6088e1094cbb30a7221fe68a901 Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Fri, 29 Nov 2024 07:29:56 -0800 Subject: [PATCH 16/23] Update test_arithmetic.py --- dpnp/tests/test_arithmetic.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/dpnp/tests/test_arithmetic.py b/dpnp/tests/test_arithmetic.py index 5b2455242eb..2d1741b9d22 100644 --- a/dpnp/tests/test_arithmetic.py +++ b/dpnp/tests/test_arithmetic.py @@ -6,20 +6,16 @@ class TestArithmetic(unittest.TestCase): @testing.for_float_dtypes() @testing.numpy_cupy_allclose() - @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_modf_part1(self, xp, dtype): a = xp.array([-2.5, -1.5, -0.5, 0, 0.5, 1.5, 2.5], dtype=dtype) b, _ = xp.modf(a) - return b @testing.for_float_dtypes() @testing.numpy_cupy_allclose() - @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_modf_part2(self, xp, dtype): a = xp.array([-2.5, -1.5, -0.5, 0, 0.5, 1.5, 2.5], dtype=dtype) _, c = xp.modf(a) - return c @testing.for_float_dtypes() @@ -39,5 +35,4 @@ def test_nansum(self, xp, dtype): def test_remainder(self, xp, dtype): a = xp.array([5, -3, -2, -1, -5], dtype=dtype) b = xp.full(a.size, 3, dtype=dtype) - return xp.remainder(a, b) From b217cc5b1f97cd2053a33ba373d1add5c54c0261 Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Fri, 29 Nov 2024 07:40:00 -0800 Subject: [PATCH 17/23] Handle TestSpacing to run on CUDA --- dpnp/tests/test_mathematical.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/dpnp/tests/test_mathematical.py b/dpnp/tests/test_mathematical.py index baa9c60310c..211b949d3e9 100644 --- a/dpnp/tests/test_mathematical.py +++ b/dpnp/tests/test_mathematical.py @@ -30,6 +30,7 @@ get_integer_dtypes, has_support_aspect16, has_support_aspect64, + is_cuda_device, ) from .test_umath import ( _get_numpy_arrays_1in_1out, @@ -2129,6 +2130,9 @@ def test_basic(self, sign, dt): @pytest.mark.parametrize("dt", get_float_dtypes()) def test_zeros(self, dt): + if is_cuda_device(): + if dt is dpnp.float32: + pytest.skip("SAT-7588") a = numpy.array([0.0, -0.0], dtype=dt) ia = dpnp.array(a) From 5179c066fa866c9f17eadb0f1aac0fe0e30e2af9 Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Fri, 29 Nov 2024 07:45:49 -0800 Subject: [PATCH 18/23] Update fft tests to run on CUDA --- dpnp/tests/test_fft.py | 19 +++++++++++++++++++ .../third_party/cupy/fft_tests/test_fft.py | 10 +++++++++- 2 files changed, 28 insertions(+), 1 deletion(-) diff --git a/dpnp/tests/test_fft.py b/dpnp/tests/test_fft.py index a6e9f720f1f..7f9cfa3d1a8 100644 --- a/dpnp/tests/test_fft.py +++ b/dpnp/tests/test_fft.py @@ -13,6 +13,7 @@ get_all_dtypes, get_complex_dtypes, get_float_dtypes, + is_cuda_device, ) @@ -470,6 +471,13 @@ def setup_method(self): @pytest.mark.parametrize("norm", ["forward", "backward", "ortho"]) @pytest.mark.parametrize("order", ["C", "F"]) def test_fftn(self, dtype, axes, norm, order): + if is_cuda_device(): + if order == "C" and axes == (0, 1, 2): + pass + elif order == "F" and axes == (-1, -4, -2): + pass + else: + pytest.skip("SAT-7587") x1 = numpy.random.uniform(-10, 10, 120) x2 = numpy.random.uniform(-10, 10, 120) a_np = numpy.array(x1 + 1j * x2, dtype=dtype).reshape( @@ -512,6 +520,9 @@ def test_fftn_repeated_axes(self, axes): @pytest.mark.parametrize("axes", [(2, 3, 3, 2), (0, 0, 3, 3)]) @pytest.mark.parametrize("s", [(5, 4, 3, 3), (7, 8, 10, 9)]) def test_fftn_repeated_axes_with_s(self, axes, s): + if is_cuda_device(): + if axes == (0, 0, 3, 3) and s == (7, 8, 10, 9): + pytest.skip("SAT-7587") x1 = numpy.random.uniform(-10, 10, 120) x2 = numpy.random.uniform(-10, 10, 120) a_np = numpy.array(x1 + 1j * x2, dtype=numpy.complex64).reshape( @@ -535,6 +546,11 @@ def test_fftn_repeated_axes_with_s(self, axes, s): @pytest.mark.parametrize("axes", [(0, 1, 2, 3), (1, 2, 1, 2), (2, 2, 2, 3)]) @pytest.mark.parametrize("s", [(2, 3, 4, 5), (5, 4, 7, 8), (2, 5, 1, 2)]) def test_fftn_out(self, axes, s): + if is_cuda_device(): + if axes == (0, 1, 2, 3): + pytest.skip("SAT-7587") + elif s == (2, 5, 1, 2) and axes in [(1, 2, 1, 2), (2, 2, 2, 3)]: + pytest.skip("SAT-7587") x1 = numpy.random.uniform(-10, 10, 120) x2 = numpy.random.uniform(-10, 10, 120) a_np = numpy.array(x1 + 1j * x2, dtype=numpy.complex64).reshape( @@ -1141,6 +1157,9 @@ def test_rfftn_repeated_axes_with_s(self, axes, s): @pytest.mark.parametrize("axes", [(0, 1, 2, 3), (1, 2, 1, 2), (2, 2, 2, 3)]) @pytest.mark.parametrize("s", [(2, 3, 4, 5), (5, 6, 7, 9), (2, 5, 1, 2)]) def test_rfftn_out(self, axes, s): + if is_cuda_device(): + if axes == (0, 1, 2, 3) and s == (2, 5, 1, 2): + pytest.skip("SAT-7587") x1 = numpy.random.uniform(-10, 10, 120) a_np = numpy.array(x1, dtype=numpy.float32).reshape(2, 3, 4, 5) a = dpnp.asarray(a_np) diff --git a/dpnp/tests/third_party/cupy/fft_tests/test_fft.py b/dpnp/tests/third_party/cupy/fft_tests/test_fft.py index 918b6e2a23f..0989029b60d 100644 --- a/dpnp/tests/third_party/cupy/fft_tests/test_fft.py +++ b/dpnp/tests/third_party/cupy/fft_tests/test_fft.py @@ -4,7 +4,7 @@ import pytest import dpnp as cupy -from dpnp.tests.helper import has_support_aspect64 +from dpnp.tests.helper import has_support_aspect64, is_cuda_device from dpnp.tests.third_party.cupy import testing @@ -162,6 +162,8 @@ class TestFft2: type_check=has_support_aspect64(), ) def test_fft2(self, xp, dtype, order): + if is_cuda_device() and self.shape == (2, 3, 4, 5): + pytest.skip("SAT-7587") a = testing.shaped_random(self.shape, xp, dtype) if order == "F": a = xp.asfortranarray(a) @@ -186,6 +188,8 @@ def test_fft2(self, xp, dtype, order): type_check=has_support_aspect64(), ) def test_ifft2(self, xp, dtype, order): + if is_cuda_device() and self.shape == (2, 3, 4, 5): + pytest.skip("SAT-7587") a = testing.shaped_random(self.shape, xp, dtype) if order == "F": a = xp.asfortranarray(a) @@ -249,6 +253,8 @@ class TestFftn: type_check=has_support_aspect64(), ) def test_fftn(self, xp, dtype, order): + if is_cuda_device() and self.shape == (2, 3, 4, 5): + pytest.skip("SAT-7587") a = testing.shaped_random(self.shape, xp, dtype) if order == "F": a = xp.asfortranarray(a) @@ -273,6 +279,8 @@ def test_fftn(self, xp, dtype, order): type_check=has_support_aspect64(), ) def test_ifftn(self, xp, dtype, order): + if is_cuda_device() and self.shape == (2, 3, 4, 5): + pytest.skip("SAT-7587") a = testing.shaped_random(self.shape, xp, dtype) if order == "F": a = xp.asfortranarray(a) From f1c5eaf65d4aeb98f93a210ce3d6cd80cabdab87 Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Mon, 2 Dec 2024 02:50:12 -0800 Subject: [PATCH 19/23] Update linalg tests to run on CUDA --- dpnp/tests/test_linalg.py | 41 ++++++++++++++ dpnp/tests/test_sycl_queue.py | 10 ++++ dpnp/tests/test_usm_type.py | 20 ++++++- .../cupy/linalg_tests/test_decomposition.py | 56 ++++++++++++++----- .../cupy/linalg_tests/test_norms.py | 8 ++- .../cupy/linalg_tests/test_solve.py | 12 +++- 6 files changed, 129 insertions(+), 18 deletions(-) diff --git a/dpnp/tests/test_linalg.py b/dpnp/tests/test_linalg.py index 76ce7989c8c..b9aefe7bfd0 100644 --- a/dpnp/tests/test_linalg.py +++ b/dpnp/tests/test_linalg.py @@ -23,6 +23,7 @@ get_float_complex_dtypes, has_support_aspect64, is_cpu_device, + is_cuda_device, ) from .third_party.cupy import testing @@ -367,6 +368,7 @@ def test_cond_complex(self, dtype, shape, p): expected = numpy.linalg.cond(a, p=p) assert_dtype_allclose(result, expected) + @pytest.mark.skipif(is_cuda_device(), reason="SAT-7589") @pytest.mark.parametrize( "p", [-inp.inf, -1, 1, inp.inf, "fro"], @@ -387,6 +389,9 @@ def test_cond_nan_input(self, p): ids=["None", "-dpnp.inf", "-2", "-1", "1", "2", "dpnp.inf", "fro"], ) def test_cond_nan(self, p): + if is_cuda_device(): + if p in [-inp.inf, -1, 1, inp.inf, "fro"]: + pytest.skip("SAT-7589") a = numpy.array(numpy.random.uniform(-5, 5, 16)).reshape(2, 2, 2, 2) a[0, 0] = 0 a[1, 1] = 0 @@ -1893,6 +1898,9 @@ class TestLstsq: ], ) def test_lstsq(self, a_shape, b_shape, dtype): + if is_cuda_device(): + if a_shape == (2, 4): + pytest.skip("SAT-7589") a_np = numpy.random.rand(*a_shape).astype(dtype) b_np = numpy.random.rand(*b_shape).astype(dtype) @@ -2272,6 +2280,9 @@ def test_norm_1D_complex(self, dtype, ord, axis, keepdims): ) @pytest.mark.parametrize("keepdims", [True, False]) def test_norm_2D(self, dtype, ord, axis, keepdims): + if is_cuda_device(): + if ord in [-2, 2, "nuc"] and axis == None: + pytest.skip("SAT-7589") a = numpy.array(numpy.random.uniform(-5, 5, 15), dtype=dtype).reshape( 3, 5 ) @@ -2299,6 +2310,9 @@ def test_norm_2D(self, dtype, ord, axis, keepdims): ) @pytest.mark.parametrize("keepdims", [True, False]) def test_norm_2D_complex(self, dtype, ord, axis, keepdims): + if is_cuda_device(): + if ord in [-2, 2, "nuc"] and axis == None: + pytest.skip("SAT-7589") x1 = numpy.random.uniform(-5, 5, 15) x2 = numpy.random.uniform(-5, 5, 15) a = numpy.array(x1 + 1j * x2, dtype=dtype).reshape(3, 5) @@ -2328,6 +2342,9 @@ def test_norm_2D_complex(self, dtype, ord, axis, keepdims): ) @pytest.mark.parametrize("keepdims", [True, False]) def test_norm_ND(self, dtype, ord, axis, keepdims): + if is_cuda_device(): + if ord in [-2, 2, "nuc"] and axis == (0, 1): + pytest.skip("SAT-7589") a = numpy.array(numpy.random.uniform(-5, 5, 120), dtype=dtype).reshape( 2, 3, 4, 5 ) @@ -2361,6 +2378,9 @@ def test_norm_ND(self, dtype, ord, axis, keepdims): ) @pytest.mark.parametrize("keepdims", [True, False]) def test_norm_ND_complex(self, dtype, ord, axis, keepdims): + if is_cuda_device(): + if ord in [-2, 2, "nuc"] and axis == (0, 1): + pytest.skip("SAT-7589") x1 = numpy.random.uniform(-5, 5, 120) x2 = numpy.random.uniform(-5, 5, 120) a = numpy.array(x1 + 1j * x2, dtype=dtype).reshape(2, 3, 4, 5) @@ -2394,6 +2414,9 @@ def test_norm_ND_complex(self, dtype, ord, axis, keepdims): ) @pytest.mark.parametrize("keepdims", [True, False]) def test_norm_usm_ndarray(self, dtype, ord, axis, keepdims): + if is_cuda_device(): + if ord in [-2, 2, "nuc"] and axis in [(0, 1), (-2, -1)]: + pytest.skip("SAT-7589") a = numpy.array(numpy.random.uniform(-5, 5, 120), dtype=dtype).reshape( 2, 3, 4, 5 ) @@ -2473,6 +2496,9 @@ def test_norm_strided_ND(self, axis, stride): ) @pytest.mark.parametrize("keepdims", [True, False]) def test_matrix_norm(self, ord, keepdims): + if is_cuda_device(): + if ord in [-2, 2, "nuc"]: + pytest.skip("SAT-7589") a = numpy.array(numpy.random.uniform(-5, 5, 15)).reshape(3, 5) ia = inp.array(a) @@ -2570,6 +2596,12 @@ class TestQr: ids=["r", "raw", "complete", "reduced"], ) def test_qr(self, dtype, shape, mode): + if ( + is_cuda_device() + and mode in ["complete", "reduced"] + and shape in [(16, 16), (2, 2, 4)] + ): + pytest.skip("SAT-7589") # Set seed_value=81 to prevent # random generation of the input singular matrix a = generate_random_numpy_array(shape, dtype, seed_value=81) @@ -2987,6 +3019,9 @@ def check_decomposition( ids=["(2,2)", "(3,4)", "(5,3)", "(16,16)"], ) def test_svd(self, dtype, shape): + if is_cuda_device(): + if shape == (3, 4): + pytest.skip("SAT-7589") a = numpy.arange(shape[0] * shape[1], dtype=dtype).reshape(shape) dp_a = inp.array(a) @@ -3058,6 +3093,9 @@ class TestSvdvals: ids=["(3,5)", "(4,2)", "(2,3,3)", "(3,5,2)"], ) def test_svdvals(self, dtype, shape): + if is_cuda_device(): + if shape == (3, 5): + pytest.skip("SAT-7589") a = numpy.arange(numpy.prod(shape), dtype=dtype).reshape(shape) dp_a = inp.array(a) @@ -3128,6 +3166,9 @@ def check_types_shapes(self, dp_B, np_B): ], ) def test_pinv(self, dtype, shape): + if is_cuda_device(): + if shape in [(3, 4), (2, 2, 4)]: + pytest.skip("SAT-7589") # Set seed_value=81 to prevent # random generation of the input singular matrix a = generate_random_numpy_array(shape, dtype, seed_value=81) diff --git a/dpnp/tests/test_sycl_queue.py b/dpnp/tests/test_sycl_queue.py index 50a87010f8c..c61f34f611a 100644 --- a/dpnp/tests/test_sycl_queue.py +++ b/dpnp/tests/test_sycl_queue.py @@ -16,6 +16,7 @@ assert_dtype_allclose, generate_random_numpy_array, get_all_dtypes, + is_cuda_device, is_win_platform, ) @@ -1802,6 +1803,9 @@ def test_matrix_rank(data, tol, device): ids=["-1", "0", "1", "(0, 1)", "(-2, -1)", "None"], ) def test_norm(device, ord, axis): + if is_cuda_device(): + if axis in [(0, 1), (-2, -1)] and ord in [-2, 2, "nuc"]: + pytest.skip("SAT-7589") a = numpy.arange(120).reshape(2, 3, 4, 5) ia = dpnp.array(a, device=device) if (axis in [-1, 0, 1] and ord in ["nuc", "fro"]) or ( @@ -1901,6 +1905,9 @@ def test_qr(shape, mode, device): ], ) def test_svd(shape, full_matrices, compute_uv, device): + if is_cuda_device(): + if shape in [(1, 4), (2, 2, 3)]: + pytest.skip("SAT-7589") dtype = dpnp.default_float_type(device) count_elems = numpy.prod(shape) @@ -2514,6 +2521,9 @@ def test_slogdet(shape, is_empty, device): ids=[device.filter_string for device in valid_devices], ) def test_pinv(shape, hermitian, rcond_as_array, device): + if is_cuda_device(): + if shape == (2, 2, 3): + pytest.skip("SAT-7589") dtype = dpnp.default_float_type(device) # Set seed_value=81 to prevent # random generation of the input singular matrix diff --git a/dpnp/tests/test_usm_type.py b/dpnp/tests/test_usm_type.py index d14604be725..6e7c5a75ead 100644 --- a/dpnp/tests/test_usm_type.py +++ b/dpnp/tests/test_usm_type.py @@ -10,7 +10,11 @@ import dpnp as dp from dpnp.dpnp_utils import get_usm_allocations -from .helper import assert_dtype_allclose, generate_random_numpy_array +from .helper import ( + assert_dtype_allclose, + generate_random_numpy_array, + is_cuda_device, +) list_of_usm_types = ["device", "shared", "host"] @@ -542,6 +546,9 @@ def test_meshgrid(usm_type_x, usm_type_y): ids=["-1", "0", "1", "(0, 1)", "(-2, -1)", "None"], ) def test_norm(usm_type, ord, axis): + if is_cuda_device(): + if axis in [(0, 1), (-2, -1)] and ord in [-2, 2, "nuc"]: + pytest.skip("SAT-7589") ia = dp.arange(120, usm_type=usm_type).reshape(2, 3, 4, 5) if (axis in [-1, 0, 1] and ord in ["nuc", "fro"]) or ( isinstance(axis, tuple) and ord == 3 @@ -862,6 +869,11 @@ def test_split(func, data1, usm_type): @pytest.mark.parametrize("usm_type", list_of_usm_types, ids=list_of_usm_types) @pytest.mark.parametrize("p", [None, -dp.inf, -2, -1, 1, 2, dp.inf, "fro"]) def test_cond(usm_type, p): + if is_cuda_device(): + if p in [None, -2, 2]: + pass + else: + pytest.skip("SAT-7589") ia = dp.arange(32, usm_type=usm_type).reshape(2, 4, 4) result = dp.linalg.cond(ia, p=p) @@ -1443,6 +1455,9 @@ def test_inv(shape, is_empty, usm_type): ], ) def test_svd(usm_type, shape, full_matrices_param, compute_uv_param): + if is_cuda_device(): + if shape in [(1, 4), (2, 2, 3)]: + pytest.skip("SAT-7589") x = dp.ones(shape, usm_type=usm_type) if compute_uv_param: @@ -1511,6 +1526,9 @@ def test_matrix_rank(data, tol, usm_type): ], ) def test_pinv(shape, hermitian, usm_type): + if is_cuda_device(): + if shape == (2, 2, 3): + pytest.skip("SAT-7589") a_np = generate_random_numpy_array(shape, hermitian=hermitian) a = dp.array(a_np, usm_type=usm_type) diff --git a/dpnp/tests/third_party/cupy/linalg_tests/test_decomposition.py b/dpnp/tests/third_party/cupy/linalg_tests/test_decomposition.py index d2c3ac69aac..6960c1e628b 100644 --- a/dpnp/tests/third_party/cupy/linalg_tests/test_decomposition.py +++ b/dpnp/tests/third_party/cupy/linalg_tests/test_decomposition.py @@ -7,6 +7,7 @@ from dpnp.tests.helper import ( has_support_aspect64, is_cpu_device, + is_cuda_device, is_win_platform, ) from dpnp.tests.third_party.cupy import testing @@ -256,13 +257,17 @@ def check_singular(self, shape, xp, dtype): @_condition.repeat(3, 10) def test_svd_rank2(self): - self.check_usv((3, 7)) + # skip case where n < m on CUDA (SAT-7589) + if not is_cuda_device(): + self.check_usv((3, 7)) self.check_usv((2, 2)) self.check_usv((7, 3)) @_condition.repeat(3, 10) def test_svd_rank2_no_uv(self): - self.check_singular((3, 7)) + # SAT-7589 + if not is_cuda_device(): + self.check_singular((3, 7)) self.check_singular((2, 2)) self.check_singular((7, 3)) @@ -288,8 +293,10 @@ def test_svd_rank2_empty_array_compute_uv_false(self, xp): ) @_condition.repeat(3, 10) def test_svd_rank3(self): - self.check_usv((2, 3, 4)) - self.check_usv((2, 3, 7)) + # SAT-7589 + if not is_cuda_device(): + self.check_usv((2, 3, 4)) + self.check_usv((2, 3, 7)) self.check_usv((2, 4, 4)) self.check_usv((2, 7, 3)) self.check_usv((2, 4, 3)) @@ -303,12 +310,16 @@ def test_svd_rank3_loop(self): # This tests the loop-based batched gesvd on CUDA (_gesvd_batched) self.check_usv((2, 64, 64)) self.check_usv((2, 64, 32)) - self.check_usv((2, 32, 64)) + # SAT-7589 + if not is_cuda_device(): + self.check_usv((2, 32, 64)) @_condition.repeat(3, 10) def test_svd_rank3_no_uv(self): - self.check_singular((2, 3, 4)) - self.check_singular((2, 3, 7)) + # SAT-7589 + if not is_cuda_device(): + self.check_singular((2, 3, 4)) + self.check_singular((2, 3, 7)) self.check_singular((2, 4, 4)) self.check_singular((2, 7, 3)) self.check_singular((2, 4, 3)) @@ -318,7 +329,9 @@ def test_svd_rank3_no_uv_loop(self): # This tests the loop-based batched gesvd on CUDA (_gesvd_batched) self.check_singular((2, 64, 64)) self.check_singular((2, 64, 32)) - self.check_singular((2, 32, 64)) + # SAT-7589 + if not is_cuda_device(): + self.check_singular((2, 32, 64)) @testing.with_requires("numpy>=1.16") def test_svd_rank3_empty_array(self): @@ -350,8 +363,10 @@ def test_svd_rank3_empty_array_compute_uv_false2(self, xp): ) @_condition.repeat(3, 10) def test_svd_rank4(self): - self.check_usv((2, 2, 3, 4)) - self.check_usv((2, 2, 3, 7)) + # SAT-7589 + if not is_cuda_device(): + self.check_usv((2, 2, 3, 4)) + self.check_usv((2, 2, 3, 7)) self.check_usv((2, 2, 4, 4)) self.check_usv((2, 2, 7, 3)) self.check_usv((2, 2, 4, 3)) @@ -365,12 +380,16 @@ def test_svd_rank4_loop(self): # This tests the loop-based batched gesvd on CUDA (_gesvd_batched) self.check_usv((3, 2, 64, 64)) self.check_usv((3, 2, 64, 32)) - self.check_usv((3, 2, 32, 64)) + # SAT-7589 + if not is_cuda_device(): + self.check_usv((3, 2, 32, 64)) @_condition.repeat(3, 10) def test_svd_rank4_no_uv(self): - self.check_singular((2, 2, 3, 4)) - self.check_singular((2, 2, 3, 7)) + # SAT-7589 + if not is_cuda_device(): + self.check_singular((2, 2, 3, 4)) + self.check_singular((2, 2, 3, 7)) self.check_singular((2, 2, 4, 4)) self.check_singular((2, 2, 7, 3)) self.check_singular((2, 2, 4, 3)) @@ -380,7 +399,9 @@ def test_svd_rank4_no_uv_loop(self): # This tests the loop-based batched gesvd on CUDA (_gesvd_batched) self.check_singular((3, 2, 64, 64)) self.check_singular((3, 2, 64, 32)) - self.check_singular((3, 2, 32, 64)) + # SAT-7589 + if not is_cuda_device(): + self.check_singular((3, 2, 32, 64)) @testing.with_requires("numpy>=1.16") def test_svd_rank4_empty_array(self): @@ -398,7 +419,14 @@ def test_svd_rank4_empty_array(self): ) class TestQRDecomposition(unittest.TestCase): @testing.for_dtypes("fdFD") + # skip cases with 'complete' and 'reduce' modes on CUDA (SAT-7589) def check_mode(self, array, mode, dtype): + if ( + is_cuda_device() + and array.size > 0 + and mode in ["complete", "reduced"] + ): + return a_cpu = numpy.asarray(array, dtype=dtype) a_gpu = cupy.asarray(array, dtype=dtype) result_gpu = cupy.linalg.qr(a_gpu, mode=mode) diff --git a/dpnp/tests/third_party/cupy/linalg_tests/test_norms.py b/dpnp/tests/third_party/cupy/linalg_tests/test_norms.py index 786428707a8..07b583b1c63 100644 --- a/dpnp/tests/third_party/cupy/linalg_tests/test_norms.py +++ b/dpnp/tests/third_party/cupy/linalg_tests/test_norms.py @@ -4,7 +4,7 @@ import pytest import dpnp as cupy -from dpnp.tests.helper import is_cpu_device +from dpnp.tests.helper import is_cpu_device, is_cuda_device from dpnp.tests.third_party.cupy import testing @@ -62,6 +62,12 @@ class TestNorm(unittest.TestCase): @testing.numpy_cupy_allclose(rtol=1e-3, atol=1e-4, type_check=False) # since dtype of sum is different in dpnp and NumPy, type_check=False def test_norm(self, xp, dtype): + if ( + is_cuda_device() + and self.shape == (1, 2) + and self.ord in [-2, 2, "nuc"] + ): + pytest.skip("SAT-7589") a = testing.shaped_arange(self.shape, xp, dtype) res = xp.linalg.norm(a, self.ord, self.axis, self.keepdims) if xp == numpy and not isinstance(res, numpy.ndarray): diff --git a/dpnp/tests/third_party/cupy/linalg_tests/test_solve.py b/dpnp/tests/third_party/cupy/linalg_tests/test_solve.py index f6f60528588..1f40c5e7094 100644 --- a/dpnp/tests/third_party/cupy/linalg_tests/test_solve.py +++ b/dpnp/tests/third_party/cupy/linalg_tests/test_solve.py @@ -7,6 +7,7 @@ from dpnp.tests.helper import ( assert_dtype_allclose, has_support_aspect64, + is_cuda_device, ) from dpnp.tests.third_party.cupy import testing from dpnp.tests.third_party.cupy.testing import _condition @@ -219,17 +220,23 @@ def check_x(self, a_shape, rcond, dtype): def test_pinv(self): self.check_x((3, 3), rcond=1e-15) - self.check_x((2, 4), rcond=1e-15) + # skip case where n < m on CUDA (SAT-7589) + if not is_cuda_device(): + self.check_x((2, 4), rcond=1e-15) self.check_x((3, 2), rcond=1e-15) self.check_x((4, 4), rcond=0.3) - self.check_x((2, 5), rcond=0.5) + # SAT-7589 + if not is_cuda_device(): + self.check_x((2, 5), rcond=0.5) self.check_x((5, 3), rcond=0.6) + @pytest.mark.skipif(is_cuda_device(), reason="SAT-7589") def test_pinv_batched(self): self.check_x((2, 3, 4), rcond=1e-15) self.check_x((2, 3, 4, 5), rcond=1e-15) + @pytest.mark.skipif(is_cuda_device(), reason="SAT-7589") def test_pinv_batched_vector_rcond(self): self.check_x((2, 3, 4), rcond=[0.2, 0.8]) self.check_x((2, 3, 4, 5), rcond=[[0.2, 0.9, 0.1], [0.7, 0.2, 0.5]]) @@ -279,6 +286,7 @@ def check_invalid_shapes(self, a_shape, b_shape): with pytest.raises(cupy.linalg.LinAlgError): cupy.linalg.lstsq(a, b, rcond=None) + @pytest.mark.skipif(is_cuda_device(), reason="SAT-7589") def test_lstsq_solutions(self): # Compares numpy.linalg.lstsq and cupy.linalg.lstsq solutions for: # a shapes range from (3, 3) to (5, 3) and (3, 5) From 0a79e669139668b96d6dee0b64004d9bc2be3899 Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Mon, 2 Dec 2024 03:07:06 -0800 Subject: [PATCH 20/23] Avoid using dpnp.random in cupy tests on CUDA --- .../cupy/creation_tests/test_from_data.py | 10 +++++-- .../cupy/math_tests/test_rational.py | 28 ++++++++++++++++--- .../tests/third_party/cupy/testing/_random.py | 9 ++++-- 3 files changed, 39 insertions(+), 8 deletions(-) diff --git a/dpnp/tests/third_party/cupy/creation_tests/test_from_data.py b/dpnp/tests/third_party/cupy/creation_tests/test_from_data.py index a3b928d984f..f8f8aa998db 100644 --- a/dpnp/tests/third_party/cupy/creation_tests/test_from_data.py +++ b/dpnp/tests/third_party/cupy/creation_tests/test_from_data.py @@ -6,7 +6,7 @@ import pytest import dpnp as cupy -from dpnp.tests.helper import has_support_aspect64 +from dpnp.tests.helper import has_support_aspect64, is_cuda_device from dpnp.tests.third_party.cupy import testing @@ -521,7 +521,13 @@ def test_copy_multigpu(self, dtype, order): q1 = dpctl.SyclQueue() q2 = dpctl.SyclQueue() - src = cupy.random.uniform(-1, 1, (2, 3), device=q1).astype(dtype) + # TODO: remove it once the issue with CUDA support is resolved + # for dpnp.random + if is_cuda_device(): + src_np = numpy.random.uniform(-1, 1, (2, 3)).astype(dtype) + src = cupy.array(src_np, device=q1) + else: + src = cupy.random.uniform(-1, 1, (2, 3), device=q1).astype(dtype) dst = cupy.copy(src, order, device=q2) testing.assert_allclose(src, dst, rtol=0, atol=0) diff --git a/dpnp/tests/third_party/cupy/math_tests/test_rational.py b/dpnp/tests/third_party/cupy/math_tests/test_rational.py index bc583f644f2..38d7420c8ae 100644 --- a/dpnp/tests/third_party/cupy/math_tests/test_rational.py +++ b/dpnp/tests/third_party/cupy/math_tests/test_rational.py @@ -1,8 +1,10 @@ import unittest +import numpy import pytest import dpnp as cupy +from dpnp.tests.helper import is_cuda_device from dpnp.tests.third_party.cupy import testing @@ -10,8 +12,18 @@ class TestRational(unittest.TestCase): @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_dtypes(["?", "e", "f", "d", "F", "D"]) def test_gcd_dtype_check(self, dtype): - a = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) - b = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) + # TODO: remove it once the issue with CUDA support is resolved + # for dpnp.random + if is_cuda_device(): + a = cupy.asarray( + numpy.random.randint(-10, 10, size=(10, 10)).astype(dtype) + ) + b = cupy.asarray( + numpy.random.randint(-10, 10, size=(10, 10)).astype(dtype) + ) + else: + a = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) + b = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) with pytest.raises(ValueError): cupy.gcd(a, b) @@ -25,8 +37,16 @@ def test_gcd_check_boundary_cases(self, xp, dtype): @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_dtypes(["?", "e", "f", "d", "F", "D"]) def test_lcm_dtype_check(self, dtype): - a = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) - b = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) + if is_cuda_device(): + a = cupy.asarray( + numpy.random.randint(-10, 10, size=(10, 10)).astype(dtype) + ) + b = cupy.asarray( + numpy.random.randint(-10, 10, size=(10, 10)).astype(dtype) + ) + else: + a = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) + b = cupy.random.randint(-10, 10, size=(10, 10)).astype(dtype) with pytest.raises(ValueError): cupy.lcm(a, b) diff --git a/dpnp/tests/third_party/cupy/testing/_random.py b/dpnp/tests/third_party/cupy/testing/_random.py index a4dc897bb9c..4f7e529afb5 100644 --- a/dpnp/tests/third_party/cupy/testing/_random.py +++ b/dpnp/tests/third_party/cupy/testing/_random.py @@ -8,6 +8,7 @@ import numpy import dpnp as cupy +from dpnp.tests.helper import is_cuda_device _old_python_random_state = None _old_numpy_random_state = None @@ -33,11 +34,15 @@ def do_setup(deterministic=True): if not deterministic: random.seed() numpy.random.seed() - cupy.random.seed() + # TODO: remove it once the issue with CUDA support is resolved + # for dpnp.random + if not is_cuda_device(): + cupy.random.seed() else: random.seed(99) numpy.random.seed(100) - cupy.random.seed(101) + if not is_cuda_device(): + cupy.random.seed(101) def do_teardown(): From e3e9afeaa037a42086045e8f955d9aa22cfef94c Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Mon, 2 Dec 2024 03:28:31 -0800 Subject: [PATCH 21/23] Remove previously added fixtures for unsupported funcs on CUDA --- dpnp/tests/test_random.py | 11 ----------- dpnp/tests/test_sort.py | 1 - dpnp/tests/test_sycl_queue.py | 1 - .../third_party/cupy/creation_tests/test_from_data.py | 1 - .../third_party/cupy/indexing_tests/test_indexing.py | 1 - .../third_party/cupy/math_tests/test_arithmetic.py | 1 - .../third_party/cupy/math_tests/test_rational.py | 2 -- .../cupy/random_tests/test_distributions.py | 3 --- .../third_party/cupy/random_tests/test_sample.py | 2 -- 9 files changed, 23 deletions(-) diff --git a/dpnp/tests/test_random.py b/dpnp/tests/test_random.py index 1d601bdd7ae..36323ae51b2 100644 --- a/dpnp/tests/test_random.py +++ b/dpnp/tests/test_random.py @@ -45,7 +45,6 @@ def check_seed(self, dist_name, params): assert_allclose(a1, a2, rtol=1e-07, atol=0) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "func", [dpnp.random.chisquare, dpnp.random.rand, dpnp.random.randn], @@ -62,7 +61,6 @@ def test_input_size(func): assert output_shape == res.shape -@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "func", [ @@ -84,7 +82,6 @@ def test_input_shape(func): assert shape == res.shape -@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "func", [ @@ -107,7 +104,6 @@ def test_check_output(func): assert dpnp.all(res < 1) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "func", [ @@ -134,7 +130,6 @@ def test_seed(func): assert_allclose(a1, a2, rtol=1e-07, atol=0) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_randn_normal_distribution(): """ Check the moments of the normal distribution sample obtained @@ -672,7 +667,6 @@ def test_seed(self): @pytest.mark.skipif(not has_support_aspect64(), reason="Failed on Iris Xe") -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsNormal(TestDistribution): def test_extreme_value(self): loc = 5 @@ -833,13 +827,11 @@ def test_seed(self): self.check_seed("rayleigh", {"scale": scale}) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsStandardCauchy(TestDistribution): def test_seed(self): self.check_seed("standard_cauchy", {}) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsStandardExponential(TestDistribution): def test_moments(self): shape = 0.8 @@ -875,7 +867,6 @@ def test_seed(self): self.check_seed("standard_gamma", {"shape": 0.0}) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsStandardNormal(TestDistribution): def test_moments(self): expected_mean = 0.0 @@ -953,7 +944,6 @@ def test_seed(self): @pytest.mark.skipif(not has_support_aspect64(), reason="Failed on Iris Xe") -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestDistributionsUniform(TestDistribution): def test_extreme_value(self): low = 1.0 @@ -1080,7 +1070,6 @@ def test_seed(self): self.check_seed("zipf", {"a": a}) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestPermutationsTestShuffle: @pytest.mark.parametrize( "dtype", diff --git a/dpnp/tests/test_sort.py b/dpnp/tests/test_sort.py index d8b428b06be..4735e1747de 100644 --- a/dpnp/tests/test_sort.py +++ b/dpnp/tests/test_sort.py @@ -399,7 +399,6 @@ def test_complex(self, dtype): assert result.dtype == expected.dtype -@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize("kth", [0, 1], ids=["0", "1"]) @pytest.mark.parametrize("dtype", get_all_dtypes(no_none=True)) @pytest.mark.parametrize( diff --git a/dpnp/tests/test_sycl_queue.py b/dpnp/tests/test_sycl_queue.py index c61f34f611a..620eaf16ffe 100644 --- a/dpnp/tests/test_sycl_queue.py +++ b/dpnp/tests/test_sycl_queue.py @@ -1277,7 +1277,6 @@ def test_out_2in_1out(func, data1, data2, device): assert_sycl_queue_equal(result.sycl_queue, x2.sycl_queue) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") @pytest.mark.parametrize( "device", valid_devices, diff --git a/dpnp/tests/third_party/cupy/creation_tests/test_from_data.py b/dpnp/tests/third_party/cupy/creation_tests/test_from_data.py index f8f8aa998db..995b443186f 100644 --- a/dpnp/tests/third_party/cupy/creation_tests/test_from_data.py +++ b/dpnp/tests/third_party/cupy/creation_tests/test_from_data.py @@ -516,7 +516,6 @@ def test_copy(self, xp, dtype, order): @testing.for_CF_orders() @testing.for_all_dtypes() - @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_copy_multigpu(self, dtype, order): q1 = dpctl.SyclQueue() q2 = dpctl.SyclQueue() diff --git a/dpnp/tests/third_party/cupy/indexing_tests/test_indexing.py b/dpnp/tests/third_party/cupy/indexing_tests/test_indexing.py index 11ce10f5308..f08d035fdd7 100644 --- a/dpnp/tests/third_party/cupy/indexing_tests/test_indexing.py +++ b/dpnp/tests/third_party/cupy/indexing_tests/test_indexing.py @@ -198,7 +198,6 @@ def test_extract_empty_1dim(self, xp): return xp.extract(b, a) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestChoose(unittest.TestCase): @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() diff --git a/dpnp/tests/third_party/cupy/math_tests/test_arithmetic.py b/dpnp/tests/third_party/cupy/math_tests/test_arithmetic.py index 7d77d46c614..924c72c7cce 100644 --- a/dpnp/tests/third_party/cupy/math_tests/test_arithmetic.py +++ b/dpnp/tests/third_party/cupy/math_tests/test_arithmetic.py @@ -685,7 +685,6 @@ def test_casting_dtype_unsafe_ignore_warnings( class TestArithmeticModf: @testing.for_float_dtypes() @testing.numpy_cupy_allclose() - @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_modf(self, xp, dtype): a = xp.array([-2.5, -1.5, -0.5, 0, 0.5, 1.5, 2.5], dtype=dtype) b, c = xp.modf(a) diff --git a/dpnp/tests/third_party/cupy/math_tests/test_rational.py b/dpnp/tests/third_party/cupy/math_tests/test_rational.py index 38d7420c8ae..9895b39ab01 100644 --- a/dpnp/tests/third_party/cupy/math_tests/test_rational.py +++ b/dpnp/tests/third_party/cupy/math_tests/test_rational.py @@ -9,7 +9,6 @@ class TestRational(unittest.TestCase): - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_dtypes(["?", "e", "f", "d", "F", "D"]) def test_gcd_dtype_check(self, dtype): # TODO: remove it once the issue with CUDA support is resolved @@ -34,7 +33,6 @@ def test_gcd_check_boundary_cases(self, xp, dtype): b = xp.array([0, 5, -10, -5, 20, 51, 6, 42]) return xp.gcd(a, b) - @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_dtypes(["?", "e", "f", "d", "F", "D"]) def test_lcm_dtype_check(self, dtype): if is_cuda_device(): diff --git a/dpnp/tests/third_party/cupy/random_tests/test_distributions.py b/dpnp/tests/third_party/cupy/random_tests/test_distributions.py index c8abff61877..feda42d6ead 100644 --- a/dpnp/tests/third_party/cupy/random_tests/test_distributions.py +++ b/dpnp/tests/third_party/cupy/random_tests/test_distributions.py @@ -599,7 +599,6 @@ def test_rayleigh_for_negative_scale(self, scale_dtype): ) ) class TestDistributionsStandardCauchy(RandomDistributionsTestCase): - @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_standard_cauchy(self): self.check_distribution("standard_cauchy", {}) @@ -612,7 +611,6 @@ def test_standard_cauchy(self): ) ) class TestDistributionsStandardExponential(RandomDistributionsTestCase): - @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_standard_exponential(self): self.check_distribution("standard_exponential", {}) @@ -641,7 +639,6 @@ def test_standard_gamma(self, shape_dtype): ) ) class TestDistributionsStandardNormal(RandomDistributionsTestCase): - @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_standard_normal(self): self.check_distribution("standard_normal", {}) diff --git a/dpnp/tests/third_party/cupy/random_tests/test_sample.py b/dpnp/tests/third_party/cupy/random_tests/test_sample.py index 4d33e31a66d..868602afa88 100644 --- a/dpnp/tests/third_party/cupy/random_tests/test_sample.py +++ b/dpnp/tests/third_party/cupy/random_tests/test_sample.py @@ -10,7 +10,6 @@ from dpnp.tests.third_party.cupy.testing import _condition, _hypothesis -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestRandint(unittest.TestCase): def test_lo_hi_reversed(self): with self.assertRaises(ValueError): @@ -107,7 +106,6 @@ def test_goodness_of_fit_2(self): self.assertTrue(_hypothesis.chi_square_test(counts, expected)) -@pytest.mark.usefixtures("allow_fall_back_on_numpy") class TestRandintDtype(unittest.TestCase): # numpy.int8, numpy.uint8, numpy.int16, numpy.uint16, numpy.int32]) @testing.for_dtypes([numpy.int32]) From 58fba44772fbd76f7e2ca75dc9989049dcff4e29 Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Mon, 2 Dec 2024 05:21:09 -0800 Subject: [PATCH 22/23] Fix logic for modf() --- dpnp/dpnp_iface_mathematical.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/dpnp/dpnp_iface_mathematical.py b/dpnp/dpnp_iface_mathematical.py index 9e21cecd500..67261896053 100644 --- a/dpnp/dpnp_iface_mathematical.py +++ b/dpnp/dpnp_iface_mathematical.py @@ -2956,8 +2956,6 @@ def modf(x1, **kwargs): ) if not kwargs: - pass - else: return dpnp_modf(x1_desc) return call_origin(numpy.modf, x1, **kwargs) From c995da4d7560607197e07fd40296ba99ebb73d67 Mon Sep 17 00:00:00 2001 From: Vladislav Perevezentsev Date: Mon, 2 Dec 2024 05:23:26 -0800 Subject: [PATCH 23/23] Use fallback on numpy for TestChoose --- .../tests/third_party/cupy/indexing_tests/test_indexing.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/dpnp/tests/third_party/cupy/indexing_tests/test_indexing.py b/dpnp/tests/third_party/cupy/indexing_tests/test_indexing.py index f08d035fdd7..4e858cb0acd 100644 --- a/dpnp/tests/third_party/cupy/indexing_tests/test_indexing.py +++ b/dpnp/tests/third_party/cupy/indexing_tests/test_indexing.py @@ -206,6 +206,7 @@ def test_choose(self, xp, dtype): c = testing.shaped_arange((3, 4), xp, dtype) return a.choose(c) + @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() def test_choose_broadcast(self, xp, dtype): @@ -213,6 +214,7 @@ def test_choose_broadcast(self, xp, dtype): c = xp.array([-10, 10]).astype(dtype) return a.choose(c) + @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() def test_choose_broadcast2(self, xp, dtype): @@ -220,6 +222,7 @@ def test_choose_broadcast2(self, xp, dtype): c = testing.shaped_arange((3, 5, 2), xp, dtype) return a.choose(c) + @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() def test_choose_wrap(self, xp, dtype): @@ -227,6 +230,7 @@ def test_choose_wrap(self, xp, dtype): c = testing.shaped_arange((3, 4), xp, dtype) return a.choose(c, mode="wrap") + @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() @testing.numpy_cupy_array_equal() def test_choose_clip(self, xp, dtype): @@ -234,6 +238,7 @@ def test_choose_clip(self, xp, dtype): c = testing.shaped_arange((3, 4), xp, dtype) return a.choose(c, mode="clip") + @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.with_requires("numpy>=1.19") def test_unknown_clip(self): for xp in (numpy, cupy): @@ -242,12 +247,14 @@ def test_unknown_clip(self): with pytest.raises(ValueError): a.choose(c, mode="unknown") + @pytest.mark.usefixtures("allow_fall_back_on_numpy") def test_raise(self): a = cupy.array([2]) c = cupy.array([[0, 1]]) with self.assertRaises(ValueError): a.choose(c) + @pytest.mark.usefixtures("allow_fall_back_on_numpy") @testing.for_all_dtypes() def test_choose_broadcast_fail(self, dtype): for xp in (numpy, cupy):