|
|
Index an array using another array. More...
Functions | |
| AFAPI array | lookup (const array &in, const array &idx, const int dim=-1) |
| Lookup the values of input array based on index. More... | |
| AFAPI af_err | af_lookup (af_array *out, const af_array in, const af_array indices, const unsigned dim) |
| Lookup the values of input array based on index. More... | |
Index an array using another array.
Lets look at an example of how af::lookup function does indexing.
| AFAPI af_err af_lookup | ( | af_array * | out, |
| const af_array | in, | ||
| const af_array | indices, | ||
| const unsigned | dim | ||
| ) |
Lookup the values of input array based on index.
| [out] | out | output array containing values at locations specified by index |
| [in] | in | is input lookup array |
| [in] | indices | is lookup indices |
| [in] | dim | specifies the dimension for indexing |
Lookup the values of input array based on index.
| [in] | in | is input lookup array |
| [in] | idx | is lookup indices |
| [in] | dim | specifies the dimension for indexing |
index