3

I don't know how to install Pytorch with pip on windows. No commands I do will work. I tried:

pip install torch

pip3 install torch

pip install pytorch

pip3 install pytorch

pip install torch torchvisual torchaudio

pip3 install torch torchvisual torchaudio

pip3 install torch==1.10.1+cu102 torchvision==0.11.2+cu102 torchaudio===0.10.1+cu102 -f https://download.pytorch.org/whl/cu102/torch_stable.html

and I used the website to try and install it but they all have this error:

ERROR: Could not find a version that satisfies the requirement torch (from versions: none)
ERROR: No matching distribution found for torch
Beso
  • 1,176
  • 5
  • 12
  • 26
Red Dog324
  • 49
  • 2

2 Answers2

5

You probably tried this on Python 3.10, there isn't a build for PyTorch on PyPI for 3.10 yet. Just install Python 3.9 for the time being and you'll be fine with pip install torch.

(note, this was posted on 2021-12-25; hello people from the future, it seems likely that this won't last too long, so your problem may be a different one)

Grismar
  • 27,561
  • 4
  • 31
  • 54
  • FWIW, pytorch is not compatible with 3.11.1 despite what the docs say, so this issue stills applies today. (At least, it isn't compatible on macOS. Might be on other OSs). –  Dec 29 '22 at 03:00
0

You can install torch for python 3.7 to 3.9 using this page. I have tried installing torch for python V3.11,3.10, but failed. If you do not have a GPU, use this link.