安装时报错
Collecting Rtree
Using cached Rtree-0.8.2.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File “”, line 1, in
File “C:\Users\dellpc\AppData\Local\Temp\pip-build-zq00u5gn\Rtree\setup.py”, line 4, in
import rtree
File “C:\Users\dellpc\AppData\Local\Temp\pip-build-zq00u5gn\Rtree\rtree_init_.py”, line 1, in
from .index import Rtree
File “C:\Users\dellpc\AppData\Local\Temp\pip-build-zq00u5gn\Rtree\rtree\index.py”, line 6, in
from . import core
File “C:\Users\dellpc\AppData\Local\Temp\pip-build-zq00u5gn\Rtree\rtree\core.py”, line 101, in
raise OSError(“could not find or load spatialindex_c.dll”)
OSError: could not find or load spatialindex_c.dll
下载了安装包之后又报错
-whl is not a supported wheel on this platform.
挠头
求助万能的百度,根据网友的提示:
安装了python3,直接输入
import wheel.pep425tags as w
print(w.get_supported())
查看当前支持的格式,我的是
在https://www.lfd.uci.edu/~gohlke/pythonlibs/#rtree网站下载相应格式的Rtree模块,比如我下载的是Rtree-0.9.4-cp37-cp37m-win_amd64.whl,因为我是64位系统,支持cp37
随后导入jupyter
!pip install E:\software\Rtree-0.9.4-cp37-cp37m-win_amd64.whl
注意install后面的是你存放该文件的路径,我的是E:\software
Done