summaryrefslogtreecommitdiff
path: root/numpy/core/numeric.py
diff options
context:
space:
mode:
authorCharles Harris <charlesr.harris@gmail.com>2014-08-20 12:39:40 -0600
committerJulian Taylor <jtaylor.debian@googlemail.com>2014-09-04 21:47:14 +0200
commit9c1d5538b5bf8682b82f0290615d3e9d7f97d746 (patch)
treeca1cfd222cf5b822511cec0ae223804c95faa80f /numpy/core/numeric.py
parent2079469b151fa4719fdce10d4324497aad45ded5 (diff)
downloadnumpy-9c1d5538b5bf8682b82f0290615d3e9d7f97d746.tar.gz
ENH: Move vdot to multiarray.
Remove vdot from _dotblas and implement it in multiarray. Remove the files in core/blasdot as they are no longer needed. Fix tests and build to reflect the changes. The vdot function is now a bit faster in the common case as ravel is used instead of flatten. There is also no need to conjugate the files for clongdouble.
Diffstat (limited to 'numpy/core/numeric.py')
-rw-r--r--numpy/core/numeric.py19
1 files changed, 1 insertions, 18 deletions
diff --git a/numpy/core/numeric.py b/numpy/core/numeric.py
index 8db3705f7..e472f1d3f 100644
--- a/numpy/core/numeric.py
+++ b/numpy/core/numeric.py
@@ -1077,26 +1077,9 @@ def outer(a, b, out=None):
# try to import blas optimized dot if available
envbak = os.environ.copy()
-try:
- # disables openblas affinity setting of the main thread that limits
- # python threads or processes to one core
- if 'openblas_main_free' not in os.environ:
- os.environ['openblas_main_free'] = '1'
- if 'gotoblas_main_free' not in os.environ:
- os.environ['gotoblas_main_free'] = '1'
- from ._dotblas import vdot
-except ImportError:
- # docstrings are in add_newdocs.py
- inner = multiarray.inner
- def vdot(a, b):
- return dot(asarray(a).ravel().conj(), asarray(b).ravel())
-finally:
- os.environ.clear()
- os.environ.update(envbak)
- del envbak
-
dot = multiarray.dot
inner = multiarray.inner
+vdot = multiarray.vdot
def alterdot():
warnings.warn("alterdot no longer does anything.", DeprecationWarning)