Skip to main content

Mojo function

gather_elements

gather_elements[input_type: DType, indices_type: DType](input: TileTensor[input_type, LayoutType, origin, address_space=address_space, linear_idx_type=linear_idx_type, element_shape_types=element_shape_types], indices: TileTensor[indices_type, LayoutType, origin, address_space=address_space, linear_idx_type=linear_idx_type, element_shape_types=element_shape_types], _axis: Int, output: TileTensor[input_type, LayoutType, origin, address_space=address_space, linear_idx_type=linear_idx_type, element_shape_types=element_shape_types])

Implements ONNX GatherElements op which is equivalent to Pytorch gather.

Was this page helpful?