check if int types are problematic on Windows
+import sys
import unittest
-from numpy.lib import NumpyVersion as Version
-
from cupy import testing
import cupyx.scipy.signal # NOQA
try:
- import scipy
import scipy.signal # NOQA
except ImportError:
pass
@@ -25,9 +23,8 @@ class TestSepFIR2d(unittest.TestCase):
@testing.for_all_dtypes()
@testing.numpy_cupy_allclose(atol=1e-5, rtol=1e-5, scipy_name='scp')
def test_sepfir2d(self, xp, scp, dtype):
- if Version(scipy.version.version) < Version('1.6.0'):
- if dtype in (xp.complex64, xp.complex128):
- self.skipTest('complex support is added since SciPy 1.6')
+ if sys.platform.startswith('win32') and xp.dtype(dtype).kind in 'iu':
+ self.skipTest('Avoid "incorrect type" error')
input = testing.shaped_random(self.input, xp, dtype)
hrow = testing.shaped_random((self.hrow,), xp, dtype)
