Wednesday, December 18, 2019

PyTorch - Installation through Conda

1. Install Anaconda Python 3.7
   64-Bit Graphical Installer (Download, Run)

2. Install PyTorch (
Windows 64 CUDA 10.1 Python 3.7)
   Launch Anaconda Prompt

   conda install pytorch torchvision cudatoolkit=10.1 -c pytorch

3. Test Installation
   from __future__ import print_function
   import torch
   x = torch.rand(5, 3)
   print(x)

   import torch
   torch.cuda.is_available()

   *if ModuleNotFoundError: with "import torch"

   example: Windows 64 CUDA 10.1 Python 3.7
   pip install https://download.pytorch.org/whl/cu101/torch-1.3.1-cp37-cp37m-win_amd64.whl

   *if torch.cuda.is_available() is FALSE
    then try update the GPU driver

4. Launch jupyter notebook in Anacoda Prompt

5. test jupyter
   at the right corner of Files click New|Python 3



No comments:

Post a Comment