Skip to main content

outer_product

Function outer_product 

Source
pub fn outer_product(a: &Tensor, b: &Tensor) -> Result<Tensor>
Expand description

Flat outer product of two [B, N, d] tensors.

Each (i,j) entry is the flattened outer product of row i from a and row j from b.

ยงReturns

[B, N, N, da * db]