MCPcopy Create free account
hub / github.com/NVIDIA/DALI / asnumpy

Function asnumpy

dali/test/python/test_external_source_impl.py:49–56  ·  view source on GitHub ↗
(x)

Source from the content-addressed store, hash-verified

47
48
49def asnumpy(x):
50 if x is None:
51 return None
52 if isinstance(x, list):
53 return [asnumpy(y) for y in x]
54 if isinstance(x, np.ndarray):
55 return x
56 return _to_numpy(x)
57
58
59def use_cupy():

Calls 1

_to_numpyFunction · 0.85

Tested by

no test coverage detected