I installed python 2.7.14 on Macos from the official 64 bit installer. I can install numpy, matplotlib and some other packages easily using pip. However, when I installed scipy and try to use it I got errors.
Installation instructions:
python --version # 2.7.14
python -m pip install --user numpy scipy
The error log produced is following
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
Platform: OSX yosemite 10.10.5
Update
pip list # has scipy
import scipy # gives no error
from scipy.optimize import fsolve # gives error