MCPcopy Create free account
hub / github.com/numpy/numpy / assert_arg_sorted

Function assert_arg_sorted

numpy/core/tests/test_multiarray.py:44–47  ·  view source on GitHub ↗
(arr, arg)

Source from the content-addressed store, hash-verified

42
43
44def assert_arg_sorted(arr, arg):
45 # resulting array should be sorted and arg values should be unique
46 assert_equal(arr[arg], np.sort(arr))
47 assert_equal(np.sort(arg), np.arange(len(arg)))
48
49
50def _aligned_zeros(shape, dtype=float, order="C", align=None):

Callers 2

test_argsort_floatFunction · 0.85
test_argsort_intFunction · 0.85

Calls 2

assert_equalFunction · 0.90
sortMethod · 0.80

Tested by

no test coverage detected