0
我在運行OS X 10.9.5的Mac上安裝了底圖版本1.0.7-5和pyproj 1.9.3-1版本的Enthought Canopy版本1.5.2730。當我嘗試導入底圖時,出現以下錯誤消息。Enthought Canopy底圖導入失敗
from mpl_toolkits.basemap import Basemap
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
<ipython-input-4-5e6824321d57> in <module>()
----> 1 from mpl_toolkits.basemap import Basemap
/Users/wiltbemj/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/mpl_toolkits/basemap/__init__.py in <module>()
28 from matplotlib.lines import Line2D
29 from matplotlib.transforms import Bbox
---> 30 from mpl_toolkits.basemap import pyproj
31 from mpl_toolkits.axes_grid1 import make_axes_locatable
32 from matplotlib.image import imread
ImportError: cannot import name pyproj
如果我嘗試導入pyproj直接出現以下錯誤mesage
ImportError Traceback (most recent call last)
<ipython-input-1-0cc08144b629> in <module>()
----> 1 from mpl_toolkits.basemap import pyproj
/Users/wiltbemj/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/mpl_toolkits/basemap/__init__.py in <module>()
35 import numpy as np
36 import numpy.ma as ma
---> 37 import _geoslib
38 import functools
39
ImportError: dlopen(/Users/wiltbemj/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-package /_geoslib.so, 2): Library not loaded: @rpath/lib/libgeos_c.1.dylib
Referenced from: /Users/wiltbemj/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/_geoslib.so
Reason: image not found
我已經試過卸載並沒有成功重新安裝的軟件包。缺少的dylib在/ opt/local/lib目錄中的計算機上。不知道這是路徑問題還是更復雜的問題。非常感謝有關如何開始調試問題的任何提示。
感謝 - 這似乎解決了這一問題。 –