diff options
author | Daniel Smith <malorian@me.com> | 2016-09-09 14:47:21 -0400 |
---|---|---|
committer | Daniel Smith <malorian@me.com> | 2016-09-26 12:21:42 -0400 |
commit | 4c788f4e7f6f5af6b1c3cda98388768912349b46 (patch) | |
tree | f000cfc7c48cee1a93f9cbefec6bdb363dde7db0 /doc | |
parent | 0887da9386e812d2769744afd6c58a927d6cbb45 (diff) | |
download | numpy-4c788f4e7f6f5af6b1c3cda98388768912349b46.tar.gz |
ENH: Allows contraction order optimization in einsum function.
Diffstat (limited to 'doc')
-rw-r--r-- | doc/release/1.12.0-notes.rst | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/doc/release/1.12.0-notes.rst b/doc/release/1.12.0-notes.rst index 8f32f8da9..83c1f1320 100644 --- a/doc/release/1.12.0-notes.rst +++ b/doc/release/1.12.0-notes.rst @@ -6,6 +6,7 @@ This release supports Python 2.7 and 3.4 - 3.5. Highlights ========== +* Order of operations in ``np.einsum`` now can be optimized for large speed improvements. Dropped Support =============== @@ -316,6 +317,17 @@ Integer ufuncs vectorized with AVX2 If the cpu supports it at runtime the basic integer ufuncs now use AVX2 instructions. This feature is currently only available when compiled with GCC. +Order of operations optimization in ``np.einsum`` +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +``np.einsum`` now supports the ``optimize`` argument which will optimize the +order of contraction. For example, ``np.einsum`` would complete the chain dot +example ``np.einsum(‘ij,jk,kl->il’, a, b, c)`` in a single pass which would +scale like ``N^4``; however, when ``optimize=True`` ``np.einsum`` will create +an intermediate array to reduce this scaling to ``N^3`` or effectively +``np.dot(a, b).dot(c)``. Usage of intermediate tensors to reduce scaling has +been applied to the general einsum summation notation. See ``np.einsum_path`` +for more details. + Changes ======= |