MCPcopy Create free account
hub / github.com/dask/dask / sparse_take

Function sparse_take

dask/array/backends.py:159–163  ·  view source on GitHub ↗
(array, idx, axis=0)

Source from the content-addressed store, hash-verified

157
158
159def sparse_take(array, idx, axis=0):
160 if axis not in {0, 1}: # pragma: no cover
161 raise ValueError("Sparse matrices can only be concatenated along axis 0 or 1")
162 indexer = (slice(None), idx) if axis else (idx, slice(None))
163 return array[indexer]
164
165
166@tensordot_lookup.register_lazy("cupyx")

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected