How to install pytorch from source for Asus GeForce 710 GT with CUDA CC 3.5 and supported CUDA Toolkit 11.0

How to install pytorch from source for Asus GeForce 710 GT with CUDA CC 3.5 and supported CUDA Toolkit 11.0?

The solution is that I have to build my own version from source. From Pytorch 1.3.1 on, 3.5 is not supported in the binaries anymore, they do this to reduce the size of the binary. See the comment at gpu - Which PyTorch version is CUDA 3.0 compatible? - Stack Overflow and Issues · pytorch/pytorch · GitHub. That means I can well use pytorch 1.3.1 and higher with CUDA cc 3.5, I simply have to compile it myself.

And this link shows how to install pytorch from source:

I need for example MSVC 2019 to compile for CUDA CC 3.5

Main help to install from source came from:

Here are the detailed steps:

install cmake from the internet
install git from the internet
MS Visual Studio 2019 16.7.1
→ Indivudual components:

if this has not worked: set USE_NINJA=OFF
(myenv) C:\Users\Admin\Downloads\Pytorch\pytorch>python setup.py install --cmake
if this has not worked:
(myenv) C:\Users\Admin\Downloads\Pytorch\pytorch>set DMSVC_Z7_OVERRIDE=OFF
(myenv) C:\Users\Admin\Downloads\Pytorch\pytorch>python setup.py install --cmake
if this has not worked (according to output):
(myenv) C:\Users\Admin\Downloads\Pytorch\pytorch>set “CUDAHOSTCXX=C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe”
(myenv) C:\Users\Admin\Downloads\Pytorch\pytorch>python setup.py install --cmake