Tensorflow + Pytorch 安装 Cudatoolkit 11.2

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

我有一台带有 nvidia 3080 卡的 Windows 10 计算机。 11.2 使用CudaToolkit 除了 TensorFlow 之外,我还想安装 Pytorch,到目前为止它运行得 100% 正常。

如果我正确理解了描述,没有 Cuda Python env 安装的 CudaToolkit 是“独立”为 Windows 安装的 Cuda 工具包版本。

我尝试使用此命令安装 Pytorch,但它不想识别 GPU。

pip install torch==1.9.0+cu102 torchvision==0.10.0+cu102 torchaudio==0.9.0 -f https://download.pytorch.org/whl/torch_stable.html

tensorflow pytorch
1个回答
0
投票

有一些提到更高版本不起作用。

所以,我安装了python 3.8。

然后,我安装如下。

conda install -y pytorch==1.12.0 torchvision==0.13.0 -c pytorch

CUDA 11.2 与 pytorch gpu 运行良好。

我与nvidia-smi确认了。

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