diff options
author | Charles Harris <charlesr.harris@gmail.com> | 2015-05-30 11:04:37 -0600 |
---|---|---|
committer | Charles Harris <charlesr.harris@gmail.com> | 2015-06-04 18:00:50 -0600 |
commit | 721675e19dd3f0c798f9582f69ea153484917e34 (patch) | |
tree | ad51f8875b4904922c0a875136b8bdfb3927d562 /numpy/lib/utils.py | |
parent | 8c18581110925ebe9e2b3530d4d5fc4afefbc8b0 (diff) | |
download | numpy-721675e19dd3f0c798f9582f69ea153484917e34.tar.gz |
ENH: Add a matmul function to multiarray
This is the functional counterpart of the '@' operator that will be
available in Python 3.5 with the addition of an out keyword. It
operates like the dot function except that
- scalar multiplication is not allowed.
- multiplication of arrays with more than 2 dimensions broadcasts.
The last means that when arrays have more than 2 dimensions they are
treated as stacks of matrices and those stacks are broadcast against
each other unlike the current behavior of dot that does an outer
product. Like dot, matmul is aware of `__numpy_ufunc__` and can be
overridden.
The current version of the function uses einsum when cblas cannot be
used, hence object arrays are not yet supported.
Diffstat (limited to 'numpy/lib/utils.py')
0 files changed, 0 insertions, 0 deletions