尝试在python中加载gdal时找不到图像

时间:2016-04-27 04:16:02

标签: python numpy gdal

    import gdal
  File "/Users/rit/anaconda2/lib/python2.7/site-packages/gdal.py", line 2, in <module>
    from osgeo.gdal import deprecation_warn
  File "/Users/rit/anaconda2/lib/python2.7/site-packages/osgeo/__init__.py", line 21, in <module>
    _gdal = swig_import_helper()
  File "/Users/rit/anaconda2/lib/python2.7/site-packages/osgeo/__init__.py", line 17, in swig_import_helper
    _mod = imp.load_module('_gdal', fp, pathname, description)
ImportError: dlopen(/Users/rit/anaconda2/lib/python2.7/site-packages/osgeo/_gdal.so, 2): Library not loaded: @rpath/libmfhdf.0.dylib
  Referenced from: /Users/rit/anaconda2/lib/libgdal.1.dylib
  Reason: image not found

我在运行使用gdal的python脚本时遇到问题,得到上面的错误。我该如何解决?我使用的是python 2.7.11

0 个答案:

没有答案