numpy.tensordot()
numpy.tensordot
-
numpy.tensordot(a, b, axes=2)
[source] -
Compute tensor dot product along specified axes for arrays >= 1-D.
Given two tensors (arrays of dimension greater than or equal to one),
a
andb
, and an array_like object containing two array_like objects,(a_axes, b_axes)
, sum the products ofa
‘s andb
‘s elements (components) over the axes specified bya_axes
andb_axes
. The third argument can be a single non-negative integer_like scalar,N
; if it is such, then the lastN
dimensions ofa
and the firstN
dimensions ofb
are s