1111 from numpy .testing import assert_array_equal
1212
1313 backend = "numpy"
14- import numpy as npp
1514import pytest
1615import torch
1716
@@ -33,7 +32,7 @@ def test_TorchOperator(par):
3332 # temporarily, skip tests on mac as torch seems not to recognized
3433 # numpy when v2 is installed
3534 if platform .system () == "Darwin" :
36- return
35+ pytest . skip ( "torch not recognized on macOS with numpy v2" )
3736 device = "cpu" if backend == "numpy" else "cuda"
3837
3938 Dop = MatrixMult (np .random .normal (0.0 , 1.0 , (par ["ny" ], par ["nx" ])))
@@ -63,7 +62,7 @@ def test_TorchOperator_batch(par):
6362 # temporarily, skip tests on mac as torch seems not to recognized
6463 # numpy when v2 is installed
6564 if platform .system () == "Darwin" :
66- return
65+ pytest . skip ( "torch not recognized on macOS with numpy v2" )
6766 device = "cpu" if backend == "numpy" else "cuda"
6867
6968 Dop = MatrixMult (np .random .normal (0.0 , 1.0 , (par ["ny" ], par ["nx" ])))
@@ -85,7 +84,7 @@ def test_TorchOperator_batch_nd(par):
8584 # temporarily, skip tests on mac as torch seems not to recognized
8685 # numpy when v2 is installed
8786 if platform .system () == "Darwin" :
88- return
87+ pytest . skip ( "torch not recognized on macOS with numpy v2" )
8988 device = "cpu" if backend == "numpy" else "cuda"
9089
9190 Dop = MatrixMult (np .random .normal (0.0 , 1.0 , (par ["ny" ], par ["nx" ])), otherdims = (2 ,))
0 commit comments