Pytorch installation under windows--download the corresponding whl file first, and then install it locally
AuthorRJ
1. Create environment (anaconda)
conda create -n torch37 python=3.7
2. Select the corresponding torch version (whl file)
https://download.pytorch.org/whl/torch_stable.html
3. Installation
3.1 View cuda
terminal input
nvidia-smi
Displayed as follows:
The CUDA version displayed on my computer is10.2
Choose what you need to installGPUVersion
here i choosetorch(1.7.0)
As shown in the figure below:
Click to download, the default path I save here is
C:\Users\rongjian\Downloads
3.2 Installation
(base) C:\Users\rongjian>conda activate torch37
(torch37) C:\Users\rongjian>cd C:\Users\rongjian\Downloads
(torch37) C:\Users\rongjian\Downloads>pip install "torch-1.7.0+cu110-cp37-cp37m-win_amd64.whl