gather

open override fun <T : DType, V> gather(input: Tensor<T, V>, indices: Tensor<DType, *>, dim: Int = 0): Tensor<T, V>(source)

Gather rows from input along dim using integer indices. Primary use: embedding lookup (dim=0, indices=token IDs).