Download lib/python3.12/site-packages/numpy/array_api/tests/test_set_functions.py from parallel-reasoner/env-full: direct link, hf CLI and curl.
- Browser
- Download file 546 Bytes
-
https://huggingface.co/parallel-reasoner/env-full/resolve/b9918be14658eb32f7f27abe8daee683afea2901/lib/python3.12/site-packages/numpy/array_api/tests/test_set_functions.py
- Command line
-
hf download hf://parallel-reasoner/env-full@b9918be14658eb32f7f27abe8daee683afea2901/lib/python3.12/site-packages/numpy/array_api/tests/test_set_functions.py
-
curl -L -o test_set_functions.py https://huggingface.co/parallel-reasoner/env-full/resolve/b9918be14658eb32f7f27abe8daee683afea2901/lib/python3.12/site-packages/numpy/array_api/tests/test_set_functions.py
546 Bytes
| import pytest | |
| from hypothesis import given | |
| from hypothesis.extra.array_api import make_strategies_namespace | |
| from numpy import array_api as xp | |
| xps = make_strategies_namespace(xp) | |
| def test_inverse_indices_shape(func, x): | |
| """ | |
| Inverse indices share shape of input array | |
| See https://github.com/numpy/numpy/issues/20638 | |
| """ | |
| out = func(x) | |
| assert out.inverse_indices.shape == x.shape | |