take
Returns elements of an array along an axis.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
x
|
SparseArray
|
Input array. |
required |
indices
|
ndarray
|
Array indices. The array must be one-dimensional and have an integer data type. |
required |
axis
|
int
|
Axis over which to select values. If |
None
|
Returns:
Name | Type | Description |
---|---|---|
out |
COO
|
A COO array with requested indices. |
Raises:
Type | Description |
---|---|
ValueError
|
If the input array isn't and can't be converted to COO format. |
Source code in sparse/numba_backend/_coo/common.py
1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 |
|