oneflow.dot¶
-
oneflow.
dot
()¶ This operator computes the dot product of tensor input and other.
The equation is:
$$ \sum_{i=1}^{n}(x[i] * y[i]) $$
- Parameters
- Shape:
input: Input must be 1D.
other: Other must be 1D.
For example:
>>> import oneflow as flow >>> flow.dot(flow.Tensor([2, 3]), flow.Tensor([2, 1])) tensor(7., dtype=oneflow.float32)