by jpeanuts · 6y ago · 0 comments
E.g. this (Latex):
$C_{ml} = A_{ijkl} B_{ijkm}$
becomes (in Python):
C = einsum('ijkl,ijkm->ml', A, B)
[1] https://docs.scipy.org/doc/numpy/reference/generated/numpy.e... [2] https://en.wikipedia.org/wiki/Einstein_notation
No comments yet.