Pytorch 1.6.0 installation process record Pip+Cuda on Windows 10-One pass operation is fierce

Pytorch selection

The official portal
chooses the installation platform Windows
Package. Generally, those who have installed python know Pip
Language. Life is short. I choose
the version of Python Cuda to view. It is easy to check. Look at the picture below to know from top to bottom, such as my CUDA selection. 10.2
Insert picture description here

Insert picture description here

Pip install

pip3 paused. .

When I opened the cmd console and inputted it with great interest, the
Insert picture description here
pip command alone reported an error. . So I chose to add a 3 after pip, and it did start downloading. . But the download was suspended at 10%. . . . .
At this time, I usually choose to uninstall python and then reinstall it. . . In fact, I did the same. After downloading Python 3.7.9, running pip directly in cmd did not report an error.
Insert picture description here

Where is the file downloaded? Just curious, you can skip here

This time I am particularly curious about where to download these packages, so a lot of searching, found by this
Insert picture description here
last conclusion is downloaded to install py Lib's site-packages directory of the file folder below, as shown in Figure
Insert picture description here
if I do not know Where is py installed? You can run it in the consolewhere python

have a test

from __future__ import print_function
import torch
x = torch.empty(5, 3)
print(x)

If the following things appear after running, it means that everything went well and the installation was successful

tensor([[-5.0307e-28,  5.2549e-43, -5.0307e-28],
        [ 5.2549e-43, -5.0302e-28,  5.2549e-43],
        [-5.0302e-28,  5.2549e-43, -5.0294e-28],
        [ 5.2549e-43, -5.0294e-28,  5.2549e-43],
        [-5.0296e-28,  5.2549e-43, -5.0296e-28]])

Pytorch learning

The official tutorial portal , the disadvantage is that it is a bit stuck. . Can't load it for a long time. .
Chinese Tutorial & Documentation V1.4
Translator's Github

References

  • https://blog.csdn.net/u011628215/article/details/104615190
  • https://blog.csdn.net/qq_43402639/article/details/94974178
  • https://blog.csdn.net/lanchunhui/article/details/62240333
  • https://blog.csdn.net/qq_36652619/article/details/82971104
  • Where are the files downloaded by pip? ? https://blog.csdn.net/weixin_44345862/article/details/87003478
  • https://pytorch.org/tutorials/
  • https://pytorch.apachecn.org/docs/1.4/

Guess you like

Origin blog.csdn.net/weixin_43031092/article/details/108415314