安装Shapely时,“python setup.py egg_info”失败,错误代码为1

问题描述 投票:1回答:1

通过PyCharm安装Shapely我收到以下错误信息:

Command "python setup.py egg_info" failed with error code 1 in C:\Users\Anwender\AppData\Local\Temp\pip-install-h4bpp30v\Shapely\

C:\WINDOWS\system32>pip install Shapely
Collecting Shapely
  Using cached https://files.pythonhosted.org/packages/a2/fb/7a7af9ef7a35d16fa23b127abee272cfc483ca89029b73e92e93cdf36e6b/Shapely-1.6.4.post2.tar.gz
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Users\Anwender\AppData\Local\Temp\pip-install-h4bpp30v\Shapely\setup.py", line 80, in <module>
        from shapely._buildcfg import geos_version_string, geos_version, \
      File "C:\Users\Anwender\AppData\Local\Temp\pip-install-h4bpp30v\Shapely\shapely\_buildcfg.py", line 200, in <module>
        lgeos = CDLL("geos_c.dll")
      File "c:\program files (x86)\python37-32\lib\ctypes\__init__.py", line 356, in __init__
        self._handle = _dlopen(self._name, mode)
    OSError: [WinError 126] Das angegebene Modul wurde nicht gefunden

我已经尝试更新pip和setuptools但它仍然无法正常工作。

有没有人可以尝试让它运行?

python pip shapely
1个回答
2
投票

通过点子无法获得Shapely。你需要下载Shapely Wheel here并运行: pip install Shapely-1.6.4.post1-cp37-cp37m-win_amd64.whl (取决于您决定下载的软件包的名称.'37'表示python 3.7版本。您可以使用python --version检查您的python版本)。

© www.soinside.com 2019 - 2024. All rights reserved.