PyTorch 1.2 (GPU) and PyTorch-geometric (PyG) recording installation Win10

  1. You need to install Visual Studio 2017, and selected C++/CLI supportand VC++ 2015.3 v14.00(v140) toolset for Desktoptwo visual C +++ build tools in the following package
  2. The second step is to re-install CUDA, this step is to make nvcc can call the command line. It will later be used to compile torch-scatter / torch-cluster / torch-sparse.
  3. The third step is to create a Python Anaconda management environment and installation PyTorch 1.2 cudatoolkit, command conda install PyTorch=1.2 cudatoolkit=10.0 torchvision -c pytorch. It should be noted that, to make the best version and the version of the CUDA cudatoolkit second step of the installation is the same .
    1. Tensorflow version, the second step can generally be omitted, the CUDA need not necessarily be installed, mounted in cudatoolkit like the anaconda.
  4. The fourth step is to pip install --verbose, respectively, the following package:

     1. torch-scatter
     2. torch-cluster
     3. torch-sparse

    Nvcc these packages are required to compile each package in the compilation process has multiple .cufiles, the installation process errors may come from:

    1. cl.exePath selection not in the system PATH environment variable, is added D:\Program Files (x86)\VisualStudio\VC\Tools\MSVC\14.16.27023\bin\Hostx64\x64, generally in the command line clwill be output. Do not select arm64 and x86 versions. At the same time put 14.16.27023\bin\in Hostx86and other folders deleted, or in my compilation torch-sparseprocess, in PATHthe case of a correctly configured, but there are still invoked Hostx86under cl.exe.
    2. No call --verboseoption, direct pip install torch-scatter, or not properly compiled whl cache directly installed, you need to pay attention to the output of the installation process, if there appeared install cache ..../..../.../torch-scatter.whlcase, then had to carry whl cache deleted.
  5. The fifth step is pip install --verbose, are the following package:

     1. pylfile
     2. rdflib
  6. pip install --verbose torch-geometric

Guess you like

Origin www.cnblogs.com/Tancred-kPro/p/11630999.html