Package ai.djl.ndarray.index.dim
Class NDIndexPick
java.lang.Object
ai.djl.ndarray.index.dim.NDIndexPick
- All Implemented Interfaces:
NDIndexElement
An
NDIndexElement
that gets elements by index in the specified axis.-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
NDIndexPick
Constructs a pick.- Parameters:
index
- the index to pick
-
-
Method Details
-
getRank
public int getRank()Returns the number of dimensions occupied by this index element.- Specified by:
getRank
in interfaceNDIndexElement
- Returns:
- the number of dimensions occupied by this index element
-
getIndex
Returns the index to pick.- Returns:
- the index to pick
-