PyTorch 安装问题- 使用 Jupyter notebook 和 Conda navigator 找不到包
PyTorch installation problem- package not found using Jupyter notebook and Conda navigator
我尝试使用 PyTorch 官方网站上的安装代码来安装 PyTorch。
我 运行 在 Conda 导航器上的 Jupyter notebook 本地
conda install pytorch torchvision cudatoolkit=10.2 -c pytorch
我收到以下错误
PackagesNotFoundError: The following packages are not available from current channels:
- pytorch
- cudatoolkit=10.2
Current channels:
- https://conda.anaconda.org/pytorch/win-32
- https://conda.anaconda.org/pytorch/noarch
- https://repo.anaconda.com/pkgs/main/win-32
- https://repo.anaconda.com/pkgs/main/noarch
- https://repo.anaconda.com/pkgs/r/win-32
- https://repo.anaconda.com/pkgs/r/noarch
- https://repo.anaconda.com/pkgs/msys2/win-32
- https://repo.anaconda.com/pkgs/msys2/noarch
To search for alternate channels that may provide the conda package you're
looking for, navigate to
https://anaconda.org
and use the search bar at the top of the page.
怎么办?
TL;DR 使用 64 位 Anaconda
conda
管理一个平台和架构的包。
您似乎安装了 32 位 (x86) Win Anaconda 版本,此处:
- https://conda.anaconda.org/pytorch/win-32
你可以在link下查看那个频道(https://conda.anaconda.org/pytorch/win-32) does not contain any pytorch
package, and same is for this one: https://conda.anaconda.org/pytorch/noarch
如果您查看 win64
:https://conda.anaconda.org/pytorch/win-64 它实际上包含 pytorch
个包。
因此,pytorch
频道中没有 pytorch
x86
软件包,而且无法创建其他架构的环境,这意味着您需要安装 64-位 Anaconda 以使用 pytorch
.
我尝试使用 PyTorch 官方网站上的安装代码来安装 PyTorch。 我 运行 在 Conda 导航器上的 Jupyter notebook 本地
conda install pytorch torchvision cudatoolkit=10.2 -c pytorch
我收到以下错误
PackagesNotFoundError: The following packages are not available from current channels:
- pytorch
- cudatoolkit=10.2
Current channels:
- https://conda.anaconda.org/pytorch/win-32
- https://conda.anaconda.org/pytorch/noarch
- https://repo.anaconda.com/pkgs/main/win-32
- https://repo.anaconda.com/pkgs/main/noarch
- https://repo.anaconda.com/pkgs/r/win-32
- https://repo.anaconda.com/pkgs/r/noarch
- https://repo.anaconda.com/pkgs/msys2/win-32
- https://repo.anaconda.com/pkgs/msys2/noarch
To search for alternate channels that may provide the conda package you're
looking for, navigate to
https://anaconda.org
and use the search bar at the top of the page.
怎么办?
TL;DR 使用 64 位 Anaconda
conda
管理一个平台和架构的包。
您似乎安装了 32 位 (x86) Win Anaconda 版本,此处:
- https://conda.anaconda.org/pytorch/win-32
你可以在link下查看那个频道(https://conda.anaconda.org/pytorch/win-32) does not contain any pytorch
package, and same is for this one: https://conda.anaconda.org/pytorch/noarch
如果您查看 win64
:https://conda.anaconda.org/pytorch/win-64 它实际上包含 pytorch
个包。
因此,pytorch
频道中没有 pytorch
x86
软件包,而且无法创建其他架构的环境,这意味着您需要安装 64-位 Anaconda 以使用 pytorch
.