Computes the dot product (inner product) of two tensors.

tch_dot(x, tensor)

Arguments

x

tensor object

tensor

tensor object

Examples

tch_dot(tensor(c(2,3)), tensor(c(2,1)))
#> tensor #> 7 #> [ Variable[CPUFloatType]{} ]