[Numpy-discussion] tensordot?

Neal Becker ndbecker2@gmail....
Tue Mar 1 06:50:06 CST 2011


Neal Becker wrote:

> Can tensordot do this (or some other operator?)
> 
> r[l,i,j] = \sum_k w[i,j,k] y[l,k]

Looks like

r = tensordot (w, y, axes=(2,1)) will produce r[i,j,l], so

transpose (r, (2,0,1))

will do it.



More information about the NumPy-Discussion mailing list