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

Function get_indexes_rand

benchmarks/benchmarks/common.py:99–105  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

97
98@lru_cache(typed=True)
99def get_indexes_rand():
100 rnd = random.Random(1)
101
102 indexes_rand = get_indexes().tolist() # copy
103 rnd.shuffle(indexes_rand) # in-place shuffle
104 indexes_rand = np.array(indexes_rand)
105 return indexes_rand
106
107
108@lru_cache(typed=True)

Callers 2

get_indexes_rand_Function · 0.85
setupMethod · 0.85

Calls 2

get_indexesFunction · 0.85
tolistMethod · 0.45

Tested by

no test coverage detected