如何在PyPy中使用GDAL?
我正在尝试使用pypy优化我的python代码。虽然我能够导入大多数库并成功运行,但是我却无法导入GDAL库。在Python 2.7中导入时,相同的库运行良好。 我尝试将GDAL位置添加到PYTHONPATH,甚至尝试将GDAL Python绑定下载到PyPy目录,但是pypy不想识别GDAL,并且出现以下错误。 Traceback (most recent call last): File "app_main.py", line 51, in run_toplevel File "ImportENC-P.py", line 50, in <module> from osgeo import gdal, ogr, osr File "B:\PYPY\site-packages\osgeo\__init__.py", line 21, in <module> _gdal = swig_import_helper() File "B:\PYPY\site-packages\osgeo\__init__.py", line 13, in swig_import_helper import _gdal ImportError: No module named _gdal