首页 > 解决方案 > 手电筒安装导致此平台上不支持车轮

问题描述

首先尝试运行pip3 install torch===1.4.0 torchvision===0.5.0 -f https://download.pytorch.org/whl/torch_stable.html,取自PyTorch 网站
结果是 No matching distribution found for torch===1.4.0 Could not find a version that satisfies the requirement torch===1.4.0 (from versions: 0.1.2, 0.1.2.post1, 0.1.2.post2)

最后从下载页面下载了 .whl 文件并尝试像这样在本地安装,'C:\Users\Raf\AppData\Local\Programs\Python\Python38\Scripts\pip.exe' install torch-1.4.0+cpu-cp37-cp37m-win_amd64.whl
之后我得到了torch-1.4.0+cpu-cp37-cp37m-win_amd64.whl is not a supported wheel on this platform.

在 64 位 Windows 上使用 64 Python 3.8

标签: pythonpippytorch

解决方案


使用 64 位 Python 3.8

但是您下载了适用于 python 3.7cp37的whl 。目前没有可用于 python 3.8 的 whl 文件。所以要么从源代码安装(可能不推荐),安装不同的python版本或使用python 3.7创建一个虚拟环境

更新

现在有:https ://download.pytorch.org/whl/cpu/torch-1.4.0%2Bcpu-cp38-cp38-win_amd64.whl


推荐阅读