tensor.gather
Gather entries of the axis dimension of data.
Args
self
(@Tensor<T>
) - The input tensor.indices
(Tensor<i32>
) - Tensor of indices.axis
(Option<i32>
) - Axis to gather on. Default: axis=0.
Panics
Panics if index values are not within bounds [-s, s-1] along axis of size s.
Returns
A new Tensor<T>
.
Example
Last updated