如何解决 64 位 anaconda 中的 Import gdal 错误?

How to solve Import gdal error in 64-bit anaconda?

我已经安装了64位anaconda,但是当我想在Spyder中导入gdal时弹出错误?错误信息如下,我有搜索堆栈溢出并尝试了他们的解决方案,但都失败了。那么,我想查询一下具体报错的原因?谢谢。

Traceback (most recent call last):

  File "<ipython-input-4-ee38efafc30b>", line 1, in <module>
    import gdal

  File "D:\Anaconda2\lib\site-packages\gdal.py", line 2, in <module>
    from osgeo.gdal import deprecation_warn

  File "D:\Anaconda2\lib\site-packages\osgeo\__init__.py", line 25, in <module>
    _gdal = swig_import_helper()

  File "D:\Anaconda2\lib\site-packages\osgeo\__init__.py", line 21, in swig_import_helper
    _mod = imp.load_module('_gdal', fp, pathname, description)

ImportError: DLL load failed: The specified procedure could not be found.

我解决了困扰很久的问题

方法:

我在 Anaconda Prompt 中键入了以下命令语句。

conda install -c conda-forge georasters

结果:

spyder Ipython 控制台没有错误。如下图。

enter image description here

安装了几十个包,一些升级了,删除了一个包,一些降级了。部分包安装情况截图如下

enter image description here