[Numpy-discussion] Proposed deprecations for 1.10: dot corner cases

Alan G Isaac alan.isaac at gmail.com
Mon May 11 15:43:51 EDT 2015

On 5/9/2015 4:26 PM, Nathaniel Smith wrote:
> dot(A, B) where one of the argument is a scalar: currently, this
> does scalar multiplication. There is no logically consistent
> motivation for this, it violates TOOWTDI, and again it is inconsistent
> with the PEP semantics for @ (which are that this case should be an
> error).

Do I recall incorrectly: I thought that reconciliation of `@` and `dot`
was explicitly not part of the project on getting a `@` operator?

I do not mean this to speak for or against the change above, which I only
moderately oppose, but rather to the argument offered.

As for the "logic" of the current behavior, can it not be given a
tensor product motivation?  (Otoh, it conflicts with the current
behavior of `vdot`.)


More information about the NumPy-Discussion mailing list