解决pip install torch出现的问题:Running setup.py install for torch ... error no module name tools.nnwrap

直接本地安装,官方网速慢推荐国内源

https://download.pytorch.org/whl/torch_stable.html

下载两个文件,按照自己的电脑版本下载

cu92: cuda9.2

torch-1.4.0 : torch版本 1.4.0

cp37 : python版本3.7

win: windows 系统

cu92/torch-1.4.0%2Bcu92-cp37-cp37m-win_amd64.whl

cu92/torchvision-0.5.0%2Bcu92-cp37-cp37m-win_amd64.whl

之后直接pip install 位置    就可以了

中间有模块安装还超时的加上源如pip install numpy -i https://pypi.doubanio.com/simple/

然后重新安装上面两文件

 

你可能感兴趣的:(Python)