我在官方的64位安装程序上在Macos上安装了python 2.7.14。 我可以使用pip轻松安装numpy,matplotlib和其他一些软件包。 但是,当我安装scipy并尝试使用它时,我遇到了错误。
安装instructions:
python --version # 2.7.14
python -m pip install --user numpy scipy
Bhishan:python
Python 2.7.14 (v2.7.14:84471935ed, Sep 16 2017, 12:01:12)
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from scipy.optimize import fsolve
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/poudel/Library/Python/2.7/lib/python/site-packages/scipy/optimize/__init__.py", line 240, in <module>
from .optimize import *
File "/Users/poudel/Library/Python/2.7/lib/python/site-packages/scipy/optimize/optimize.py", line 37, in <module>
from .linesearch import (line_search_wolfe1, line_search_wolfe2,
File "/Users/poudel/Library/Python/2.7/lib/python/site-packages/scipy/optimize/linesearch.py", line 18, in <module>
from scipy.optimize import minpack2
ImportError: dlopen(/Users/poudel/Library/Python/2.7/lib/python/site-packages/scipy/optimize/minpack2.so, 2): Symbol not found: ___addtf3
Referenced from: /Users/poudel/Library/Python/2.7/lib/python/site-packages/scipy/optimize/../.dylibs/libquadmath.0.dylib
Expected in: /usr/lib/libSystem.B.dylib
in /Users/poudel/Library/Python/2.7/lib/python/site-packages/scipy/optimize/../.dylibs/libquadmath.0.dylib
平台:OSX优胜美地10.10.5
更新
pip list # has scipy
import scipy # gives no error
from scipy.optimize import fsolve # gives error