@@ -89,6 +89,18 @@ def test_mean_transfer_function_gpu_equals_cpu():
8989 np .testing .assert_allclose (
9090 numpy_mean .data , cupy_mean .data .get (), equal_nan = True )
9191
92+
93+ @dask_array_available
94+ @cuda_and_cupy_available
95+ def test_mean_transfer_dask_gpu_raise_not_implemented ():
96+
97+ import cupy
98+
99+ # cupy case
100+ cupy_agg = xr .DataArray (cupy .asarray (data_random ))
101+ cupy_mean = mean (cupy_agg )
102+ general_output_checks (cupy_agg , cupy_mean )
103+
92104 # dask + cupy case not implemented
93105 dask_cupy_agg = xr .DataArray (
94106 da .from_array (cupy .asarray (data_random ), chunks = (3 , 3 ))
@@ -466,6 +478,7 @@ def test_hotspots_numpy(data_hotspots):
466478 assert numpy_hotspots .attrs ['unit' ] == '%'
467479
468480
481+ @dask_array_available
469482def test_hotspots_dask_numpy (data_hotspots ):
470483 data , kernel , expected_result = data_hotspots
471484 dask_numpy_agg = create_test_raster (data , backend = 'dask' )
@@ -495,9 +508,3 @@ def test_hotspot_gpu(data_hotspots):
495508 cupy_hotspots [coord ].data , cupy_agg [coord ].data , equal_nan = True
496509 )
497510 assert cupy_hotspots .attrs ['unit' ] == '%'
498-
499- # dask + cupy case not implemented
500- dask_cupy_agg = create_test_raster (data , backend = 'dask+cupy' )
501- with pytest .raises (NotImplementedError ) as e_info :
502- hotspots (dask_cupy_agg , kernel )
503- assert e_info
0 commit comments