Function outer
pub fn outer<B, const D: usize, const R: usize, K>(
x: Tensor<B, D, K>,
y: Tensor<B, D, K>,
) -> Tensor<B, R, K>Expand description
Computes the outer product for the last columns of 2 tensors.
See also: outer_dim.
§Arguments
lhs: the “row” tensor, with shape[..., i].rhs: the “col” tensor, with shape[..., j].dim: the dimension to product.
§Returns
A tensor of rank R = D + 1, where:
result[..., i, j] = lhs[..., i] * rhs[..., j]