Reputation: 1
I tried following the instructions on pytorch.org and ran the command provided by them for my configuration, but I get the following error
ERROR: Could not find a version that satisfies the requirement torch===1.7.0+cu110 (from versions: 0.1.2, 0.1.2.post1, 0.1.2.post2)
ERROR: No matching distribution found for torch===1.7.0+cu110
A similar error is being thrown for any other installation methods that I try, e.g. earlier cuda versions, CPU only etc. My Python version is 3.9 and was installed using the .exe installer provided at python.org, if that's relevant.
Upvotes: 0
Views: 2211
Reputation: 111
Just go to https://pytorch.org/get-started/locally/
and get PyTorch for any platform using conda or pip.
Upvotes: 1
Reputation: 11
If you look at the link in the message (https://download.pytorch.org/whl/torch_stable.html) you can see that there is no .whl file for that pytorch version with python 3.9 (cp38 in the filename refers to the python version). For now it seems that you need to downgrade to python 3.8, at least until they add support for 3.9.
Upvotes: 0
Reputation: 1
Well, I installed a new Operating System and did a fresh install of Python and CUDA. After that the commands given on pytorch.org worked just fine. For immediate reference, the command is
pip install torch==1.7.0+cu110 torchvision==0.8.1+cu110 torchaudio===0.7.0 -f https://download.pytorch.org/whl/torch_stable.html
I had to resort to this because I had messed up my python installation by tinkering around with pip, conda and anaconda all at once. The process of removing anaconda completely didn't quite work as intended and everything was just a wee bit broken.
So, I'm guessing that if anyone else is facing the same error and other documented solutions do not work, then a fresh installation of python might become necessary. In my case, it was in the form of a completely new operating system.
Upvotes: 0