需要帮助解决numpy 1.9.2和scipy 0.16.0上的这些错误。输出来自numpy.test(verbose=10)
和scipy.test(verbose=10)
,但我删除了所有行“ok”。
numpy.test
# python
Python 2.6.6 (r266:84292, Sep 27 2010, 18:07:46)
[GCC 4.1.2 20080704 (Red Hat 4.1.2-48)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import numpy
>>> numpy.test(verbose=10)
Running unit tests for numpy
NumPy version 1.9.2
NumPy is installed in /data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy
Python version 2.6.6 (r266:84292, Sep 27 2010, 18:07:46) [GCC 4.1.2 20080704 (Red Hat 4.1.2-48)]
nose version 1.3.7
nose.config: INFO: Ignoring files matching ['^\\.', '^_', '^setup\\.py$']
nose.config: INFO: Excluding tests matching ['f2py_ext', 'f2py_f90_ext', 'gen_ext', 'pyrex_ext', 'swig_ext']
test_blasdot.test_blasdot_used ... SKIP: Skipping test: test_blasdot_used: Numpy is not compiled with _dotblas
test_blasdot.test_dot_override ... SKIP: Skipping test: test_dot_override: Test skipped due to test condition
Failure: SkipTest (Skipping test: test_ufunc_override_rop_precedence: Test skipped due to test condition) ... SKIP: Skipping test: test_ufunc_override_rop_precedence: Test skipped due to test condition
test_multiarray.TestBinop.test_ufunc_override_rop_simple ... SKIP: Skipping test: test_ufunc_override_rop_simple: Test skipped due to test condition
test_dot_override (test_multiarray.TestMethods) ... SKIP: Skipping test: test_dot_override: Test skipped due to test condition
test_field_names (test_multiarray.TestRecord) ... SKIP: non ascii unicode field indexing skipped; raises segfault on python 2.x
test_floating_exceptions (test_numeric.TestFloatExceptions) ... KNOWNFAIL: See ticket #2350
test_umath.TestComplexFunctions.test_branch_cuts_failing ... KNOWNFAIL: These branch cuts are known to fail
test_ufunc_override (test_umath.TestSpecialMethods) ... SKIP: Skipping test: test_ufunc_override: Test skipped due to test condition
test_ufunc_override_exception (test_umath.TestSpecialMethods) ... SKIP: Skipping test: test_ufunc_override_exception: Test skipped due to test condition
test_ufunc_override_methods (test_umath.TestSpecialMethods) ... SKIP: Skipping test: test_ufunc_override_methods: Test skipped due to test condition
test_ufunc_override_mro (test_umath.TestSpecialMethods) ... SKIP: Skipping test: test_ufunc_override_mro: Test skipped due to test condition
test_ufunc_override_out (test_umath.TestSpecialMethods) ... SKIP: Skipping test: test_ufunc_override_out: Test skipped due to test condition
test_umath_complex.TestCarg.test_zero ... KNOWNFAIL: Complex arithmetic with signed zero is buggy on most implementation
test_umath_complex.TestCexp.test_special_values2 ... KNOWNFAIL: cexp(nan + 0I) is wrong on most implementations
test_format.test_large_file_support ... SKIP: Could not create 5GB large file
Ticket 627. ... ERROR
test_simple (test_utils.TestArrayAlmostEqualNulp) ... KNOWNFAIL: Github issue #347
======================================================================
ERROR: Ticket 627.
----------------------------------------------------------------------
Traceback (most recent call last):
File "/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/linalg/tests/test_regression.py", line 51, in test_svd_build
u, s, vh = linalg.svd(a)
File "/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/linalg/linalg.py", line 1327, in svd
u, s, vt = gufunc(a, signature=signature, extobj=extobj)
ValueError: On entry to DGESDD parameter number 12 had an illegal value
----------------------------------------------------------------------
Ran 5593 tests in 53.953s
FAILED (KNOWNFAIL=5, SKIP=12, errors=1)
<nose.result.TextTestResult run=5593 errors=1 failures=0>
scipy.test
# python
Python 2.6.6 (r266:84292, Sep 27 2010, 18:07:46)
[GCC 4.1.2 20080704 (Red Hat 4.1.2-48)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import scipy
>>> scipy.test(verbose=10)
Running unit tests for scipy
NumPy version 1.9.2
NumPy is installed in /data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy
SciPy version 0.16.0
SciPy is installed in /data/python/base/lib/python2.6/site-packages/scipy-0.16.0-py2.6-linux-x86_64.egg/scipy
Python version 2.6.6 (r266:84292, Sep 27 2010, 18:07:46) [GCC 4.1.2 20080704 (Red Hat 4.1.2-48)]
nose version 1.3.7
nose.config: INFO: Ignoring files matching ['^\\.', '^_', '^setup\\.py$']
nose.config: INFO: Excluding tests matching ['f2py_ext', 'f2py_f90_ext', 'gen_ext', 'pyrex_ext', 'swig_ext']
/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/lib/utils.py:95: DeprecationWarning: `scipy.weave` is deprecated, use `weave` instead!
warnings.warn(depdoc, DeprecationWarning)
Failure: ImportError (/data/python/base/lib/python2.6/site-packages/scipy-0.16.0-py2.6-linux-x86_64.egg/scipy/linalg/cython_lapack.so: undefined symbol: zlacn2_) ... ERROR
test_notice (test_basic.TestSingleFFT) ... KNOWNFAIL: single-precision FFT implementation is partially disabled, until accuracy issues with large prime powers are resolved
test_improvement (test_quadpack.TestCtypesQuad) ... KNOWNFAIL: Unreliable test, see ticket 1684.
Failure: AttributeError ('module' object has no attribute 'qhull') ... ERROR
test_interpolate.TestInterp1D.test_bounds ... ERROR
test_interpolate.TestInterp1D.test_complex ... ERROR
test_interpolate.TestInterp1D.test_cubic ... ERROR
test_interpolate.TestInterp1D.test_nd ... ERROR
test_interpolate.TestInterp1D.test_nd_zero_spline ... KNOWNFAIL: zero-order splines fail for the last point
test_interpolate.TestInterp1D.test_validation ... ERROR
test_interpolate.TestInterp1D.test_zero ... KNOWNFAIL: zero-order splines fail for the last point
test_ndgriddata.TestGriddata.test_1d ... ERROR
test_ndgriddata.TestGriddata.test_1d_unsorted ... ERROR
/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/core/arrayprint.py:641: DeprecationWarning: elementwise comparison failed; this will raise the error in the future.
max_str_len = max(len(str(maximum.reduce(data))),
/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/core/arrayprint.py:641: DeprecationWarning: elementwise comparison failed; this will raise the error in the future.
max_str_len = max(len(str(maximum.reduce(data))),
/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/core/arrayprint.py:641: DeprecationWarning: elementwise comparison failed; this will raise the error in the future.
max_str_len = max(len(str(maximum.reduce(data))),
/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/core/arrayprint.py:641: DeprecationWarning: elementwise comparison failed; this will raise the error in the future.
max_str_len = max(len(str(maximum.reduce(data))),
/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/core/arrayprint.py:641: DeprecationWarning: elementwise comparison failed; this will raise the error in the future.
max_str_len = max(len(str(maximum.reduce(data))),
/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/core/arrayprint.py:641: DeprecationWarning: elementwise comparison failed; this will raise the error in the future.
max_str_len = max(len(str(maximum.reduce(data))),
/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/core/arrayprint.py:641: DeprecationWarning: elementwise comparison failed; this will raise the error in the future.
max_str_len = max(len(str(maximum.reduce(data))),
/data/python/base/lib/python2.6/site-packages/numpy-1.9.2-py2.6-linux-x86_64.egg/numpy/core/arrayprint.py:641: DeprecationWarning: elementwise comparison failed; this will raise the error in the future.
max_str_len = max(len(str(maximum.reduce(data))),
Failure: ImportError (cannot import name _fblas) ... ERROR
Failure: ImportError (cannot import name _flapack) ... ERROR
Failure: AttributeError ('module' object has no attribute 'cython_blas') ... ERROR
Failure: ImportError (/data/python/base/lib/python2.6/site-packages/scipy-0.16.0-py2.6-linux-x86_64.egg/scipy/linalg/cython_lapack.so: undefined symbol: zlacn2_) ... ERROR
test_decomp.TestEig.test_singular ... KNOWNFAIL: See gh-2254.
test_crash_1580 (test_decomp.TestSVD) ... ERROR
test_random (test_decomp.TestSVD) ... ERROR
test_simple_overdet (test_decomp.TestSVD) ... ERROR
test_simple_underdet (test_decomp.TestSVD) ... ERROR
test_decomp.test_lapack_misaligned ... KNOWNFAIL: Ticket #1152, triggers a segfault in rare cases.
Failure: AttributeError ('module' object has no attribute '_decomp_update') ... ERROR
Failure: ImportError (cannot import name _fblas) ... ERROR
test_interpolative.TestInterpolativeDecomposition.test_rand ... Segmentation fault
请告知我是否需要查看其他包裹,谢谢
new:我试过pip install -vvv但是没有成功 - 我不知道如何尝试rpm方法。
# pip install -vvv numpy
Starting new HTTPS connection (1): pypi.python.org
There was an error checking the latest version of pip
Traceback (most recent call last):
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/utils/outdated.py", line 126, in pip_version_check
headers={"Accept": "application/json"},
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/_vendor/requests/sessions.py", line 473, in get
return self.request('GET', url, **kwargs)
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/download.py", line 365, in request
return super(PipSession, self).request(method, url, *args, **kwargs)
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/_vendor/requests/sessions.py", line 461, in request
resp = self.send(prep, **send_kwargs)
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/_vendor/requests/sessions.py", line 573, in send
r = adapter.send(request, **kwargs)
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/_vendor/cachecontrol/adapter.py", line 43, in send
resp = super(CacheControlAdapter, self).send(request, **kw)
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/_vendor/requests/adapters.py", line 431, in send
raise SSLError(e, request=request)
SSLError: [Errno 1] _ssl.c:490: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
Collecting numpy
Getting page https://pypi.python.org/simple/numpy/
Starting new HTTPS connection (1): pypi.python.org
Could not fetch URL https://pypi.python.org/simple/numpy/: connection error: [Errno 1] _ssl.c:490: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
Will skip URL https://pypi.python.org/simple/numpy/ when looking for download links for numpy
URLs to search for versions for numpy:
* https://pypi.python.org/simple/numpy/
Getting page https://pypi.python.org/simple/numpy/
Starting new HTTPS connection (2): pypi.python.org
Could not fetch URL https://pypi.python.org/simple/numpy/: connection error: [Errno 1] _ssl.c:490: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
Will skip URL https://pypi.python.org/simple/numpy/ when looking for download links for numpy
Could not find any downloads that satisfy the requirement numpy
Cleaning up...
No distributions at all found for numpy
Exception information:
Traceback (most recent call last):
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/basecommand.py", line 232, in main
status = self.run(options, args)
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/commands/install.py", line 339, in run
requirement_set.prepare_files(finder)
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/req/req_set.py", line 333, in prepare_files
upgrade=self.upgrade,
File "/data/python/base/lib/python2.6/site-packages/pip-6.0.8-py2.6.egg/pip/index.py", line 397, in find_requirement
'No distributions at all found for %s' % req
DistributionNotFound: No distributions at all found for numpy
答案 0 :(得分:0)
终于解决了:
1)使用OpenBLAS构建解决方案路径 - 每个@ali_m解决方案:使用Compiling numpy with OpenBLAS integration
2)在本地系统上:两个问题是过时的cacerts(这台机器至少已有5年历史),以及需要更多磁盘空间的小问题(通过删除已知的旧文件解决)
3)尚未安装Cython,这可能与easy_install没有做好的原始问题有关。关于numpy和scipy的其他讨论已经提到cython对于直接从github下载的人来说是一个秘密的要求。因此,需要Cython才能完成numpy和scipy的安装。结果:numpy.test()和scipy.test()结果相对干净,更重要的是,scipy所需的import语句现在有效。