Skip to content

Instantly share code, notes, and snippets.

@vandbt
Created December 14, 2018 16:06
Show Gist options
  • Star 7 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vandbt/62e137881a9e2014d4ded452d3e8e8dd to your computer and use it in GitHub Desktop.
Save vandbt/62e137881a9e2014d4ded452d3e8e8dd to your computer and use it in GitHub Desktop.
How to Install PyTorch in Windows 10
1. Install Python
https://www.python.org/downloads/
2. update pip
python -m pip install --upgrade pip
3. install numpy first
according to PyTorch official guide recommand that install numpy first.
pip install numpy
4. no cuda PyTorch 0.4.1
pip install https://download.pytorch.org/whl/cpu/torch-0.4.1-cp37-cp37m-win_amd64.whl
5. Torchvision
pip install https://download.pytorch.org/whl/torchvision-0.1.6-py3-none-any.whl
@runningmanlima
Copy link

This really helps, thanks!

@Jeet0204
Copy link

Jeet0204 commented May 29, 2020

Very Helpful. Thanks!

@Madhavi-3112
Copy link

image

please help.

@dnyandeobharambe
Copy link

May be try this link ,above commands install older version. This link talk version 1.2 (not latest)
https://pytorch.org/get-started/previous-versions/

@Madhavi-3112
Copy link

Madhavi-3112 commented Jul 4, 2020 via email

@BehzadNouraniKoliji
Copy link

Thanks for the help

@benhammada
Copy link

from torch._C import *
ImportError: DLL load failed: Le module spécifié est introuvable.
i get this error can you help me!!!

@HaxThePlanet
Copy link

no cuda is nooooo

@shaica
Copy link

shaica commented Dec 9, 2020

I have tried several solutions but still, I cannot install PyTorch locally. I do not want to use Anaconda because it disturbs my existing structure.

I got this error when I tried this solution:

ERROR: torch-0.4.1-cp37-cp37m-win_amd64.whl is not a supported wheel on this platform.

I tried different versions but with the same results, "it is not a supported wheel on this platform".

My environment:
Windows 10 64bit
Python 3.8.2
pip 20.3.1

@PratikshaSh
Copy link

I suggest you to first degrade your python 3.8.2 to python 3.6.x. (or you can install Anaconda3 version 5.2.0 as python3.6 comes with it).
and then run this command :
pip install https://download.pytorch.org/whl/cpu/torch-0.4.1-cp36-cp36m-win_amd64.whl

(notice that it should be cp36 not cp37 since you'll be using python3.6.x)

(this worked for me).

@dungdo123
Copy link

I have tried several solutions but still, I cannot install PyTorch locally. I do not want to use Anaconda because it disturbs my existing structure.

I got this error when I tried this solution:

ERROR: torch-0.4.1-cp37-cp37m-win_amd64.whl is not a supported wheel on this platform.

I tried different versions but with the same results, "it is not a supported wheel on this platform".

My environment:
Windows 10 64bit
Python 3.8.2
pip 20.3.1

reinstall python3.7 may be useful!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment