[Numpy-discussion] dot() instead of tensordot()
Charles R Harris
Mon Mar 10 06:43:46 CDT 2008
On Mon, Mar 10, 2008 at 1:17 AM, royG <firstname.lastname@example.org> wrote:
> can numpy.dot() be used instead of tensordot()? is there any
> performance difference? I am talking about multipln btw numpy arrays
> of dimensions 50 X 20,000 where elements are of float type.
Dot is the usual matrix multiplication operator, tensordot extends it to
allow contraction on an arbitrary set of indices. If you don't need that
capability just use dot. I suspect dot might be a bit faster, but in your
case the call overhead is probably negligible relative to the computation
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Numpy-discussion