diff --git a/python/cucim/src/cucim/skimage/_vendored/_ndimage_filters.py b/python/cucim/src/cucim/skimage/_vendored/_ndimage_filters.py index b7e2ab4a3..e98fb3eb8 100644 --- a/python/cucim/src/cucim/skimage/_vendored/_ndimage_filters.py +++ b/python/cucim/src/cucim/skimage/_vendored/_ndimage_filters.py @@ -1,5 +1,6 @@ """A vendored subset of cupyx.scipy.ndimage._filters""" import math +import platform import warnings import cupy @@ -22,6 +23,8 @@ except ImportError: compile_errors = (ResourceLimitError,) +_is_not_windows = platform.system() != "Windows" + def correlate(input, weights, output=None, mode="reflect", cval=0.0, origin=0): """Multi-dimensional correlate. @@ -231,7 +234,7 @@ def _correlate_or_convolve1d( default_algorithm = False if algorithm is None: default_algorithm = True - if input.ndim == 2 and weights.size <= 256: + if _is_not_windows and input.ndim == 2 and weights.size <= 256: algorithm = "shared_memory" else: algorithm = "elementwise" diff --git a/python/cucim/src/cucim/skimage/filters/tests/test_separable_filtering.py b/python/cucim/src/cucim/skimage/filters/tests/test_separable_filtering.py index 026b8c84b..186eb529d 100644 --- a/python/cucim/src/cucim/skimage/filters/tests/test_separable_filtering.py +++ b/python/cucim/src/cucim/skimage/filters/tests/test_separable_filtering.py @@ -1,3 +1,5 @@ +import platform + import cupy as cp import pytest @@ -227,6 +229,13 @@ def test_separable_image_shapes_and_modes(shape, axis, kernel_size, mode): ) +@pytest.mark.skipif( + platform.system() == "Windows", + reason=( + "custom separable kernels disabled on Windows until dtype-related " + "test failures can be resolved" + ), +) @pytest.mark.parametrize("axis", (0, 1)) @pytest.mark.parametrize("image_dtype", image_dtypes_tested) @pytest.mark.parametrize( @@ -246,6 +255,13 @@ def test_separable_image_and_kernel_dtypes(axis, image_dtype, kernel_dtype): ) +@pytest.mark.skipif( + platform.system() == "Windows", + reason=( + "custom separable kernels disabled on Windows until dtype-related " + "test failures can be resolved" + ), +) @pytest.mark.parametrize("axis", (0, 1)) @pytest.mark.parametrize("image_dtype", image_dtypes_tested) @pytest.mark.parametrize(