简体   繁体   中英

When using Pytorch-GPU in Anaconda, is it not necessary to install CUDA?

I found that after installing Pytorch 0.4 GPU version in Anaconda, you don't need to install CUDA locally to call gpu acceleration. When running code, the GPU core can be used at more than 90%.

Edit:I used it in Windows 10. Don't know if it works in Linux.

@talonmies

Thanks for your url. It seems that pytorch don't need cuda in Windows, since its dependencies are cffi, mkl, numpy, and python.

I entered this command conda search -c pytorch pytorch=0.4.0 --info in Anaconda Prompt and it says

Loading channels: done
pytorch 0.4.0 py35_cuda80_cudnn7he774522_1
------------------------------------------
file name   : pytorch-0.4.0-py35_cuda80_cudnn7he774522_1.tar.bz2
name        : pytorch
version     : 0.4.0
build string: py35_cuda80_cudnn7he774522_1
build number: 1
size        : 528.5 MB
arch        : x86_64
constrains  : ()
platform    : Platform.win
license     : BSD 3-Clause
subdir      : win-64
url         : https://conda.anaconda.org/pytorch/win-64/pytorch-0.4.0-py35_cuda80_cudnn7he774522_1.tar.bz2
md5         : 7db3971bb054079d7c7ff84b6286c58e
dependencies:
  - cffi
  - mkl >=2018
  - numpy >=1.11
  - python >=3.5,<3.6.0a0


pytorch 0.4.0 py35_cuda90_cudnn7he774522_1
------------------------------------------
file name   : pytorch-0.4.0-py35_cuda90_cudnn7he774522_1.tar.bz2
name        : pytorch
version     : 0.4.0
build string: py35_cuda90_cudnn7he774522_1
build number: 1
size        : 578.5 MB
arch        : x86_64
constrains  : ()
platform    : Platform.win
license     : BSD 3-Clause
subdir      : win-64
url         : https://conda.anaconda.org/pytorch/win-64/pytorch-0.4.0-py35_cuda90_cudnn7he774522_1.tar.bz2
md5         : 8200c9841f9cad6f2e605015812aa3f2
dependencies:
  - cffi
  - mkl >=2018
  - numpy >=1.11
  - python >=3.5,<3.6.0a0


pytorch 0.4.0 py35_cuda91_cudnn7he774522_1
------------------------------------------
file name   : pytorch-0.4.0-py35_cuda91_cudnn7he774522_1.tar.bz2
name        : pytorch
version     : 0.4.0
build string: py35_cuda91_cudnn7he774522_1
build number: 1
size        : 546.1 MB
arch        : x86_64
constrains  : ()
platform    : Platform.win
license     : BSD 3-Clause
subdir      : win-64
url         : https://conda.anaconda.org/pytorch/win-64/pytorch-0.4.0-py35_cuda91_cudnn7he774522_1.tar.bz2
md5         : 79d99a825f66b55b1aa6f04d22d68aac
dependencies:
  - cffi
  - mkl >=2018
  - numpy >=1.11
  - python >=3.5,<3.6.0a0


pytorch 0.4.0 py36_cuda80_cudnn7he774522_1
------------------------------------------
file name   : pytorch-0.4.0-py36_cuda80_cudnn7he774522_1.tar.bz2
name        : pytorch
version     : 0.4.0
build string: py36_cuda80_cudnn7he774522_1
build number: 1
size        : 529.2 MB
arch        : x86_64
constrains  : ()
platform    : Platform.win
license     : BSD 3-Clause
subdir      : win-64
url         : https://conda.anaconda.org/pytorch/win-64/pytorch-0.4.0-py36_cuda80_cudnn7he774522_1.tar.bz2
md5         : 27d20c9869fb57ffe0d6d014cf348855
dependencies:
  - cffi
  - mkl >=2018
  - numpy >=1.11
  - python >=3.6,<3.7.0a0


pytorch 0.4.0 py36_cuda90_cudnn7he774522_1
------------------------------------------
file name   : pytorch-0.4.0-py36_cuda90_cudnn7he774522_1.tar.bz2
name        : pytorch
version     : 0.4.0
build string: py36_cuda90_cudnn7he774522_1
build number: 1
size        : 577.6 MB
arch        : x86_64
constrains  : ()
platform    : Platform.win
license     : BSD 3-Clause
subdir      : win-64
url         : https://conda.anaconda.org/pytorch/win-64/pytorch-0.4.0-py36_cuda90_cudnn7he774522_1.tar.bz2
md5         : 138dcca8eeff1d58a8fd9b1febf702f6
dependencies:
  - cffi
  - mkl >=2018
  - numpy >=1.11
  - python >=3.6,<3.7.0a0


pytorch 0.4.0 py36_cuda91_cudnn7he774522_1
------------------------------------------
file name   : pytorch-0.4.0-py36_cuda91_cudnn7he774522_1.tar.bz2
name        : pytorch
version     : 0.4.0
build string: py36_cuda91_cudnn7he774522_1
build number: 1
size        : 546.4 MB
arch        : x86_64
constrains  : ()
platform    : Platform.win
license     : BSD 3-Clause
subdir      : win-64
url         : https://conda.anaconda.org/pytorch/win-64/pytorch-0.4.0-py36_cuda91_cudnn7he774522_1.tar.bz2
md5         : 326265665000de6f7501160b10b089c8
dependencies:
  - cffi
  - mkl >=2018
  - numpy >=1.11
  - python >=3.6,<3.7.0a0

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM