1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

PyTorch×GPU セットアップ手順

Posted at

目次

1. はじめに
2. セットアップ
3. 動作確認

はじめに

自分用のメモとして、ディープラーニングフレームワークPyTorchをGPUで利用する際のセットアップ手順を記します。

インストール

  • PyTorchPythonCUDAそれぞれのバージョンによって相性問題があるため注意
    • 例えば3000番台のGPUであれば PyTorch 1.7 以上・Python 3.8 以上・CUDA 11.x
  • AnacondaのGUIからPyTorchをインストールしない

下記リンクからインストールするコマンドを確認しておく

Untitled.png
アーカイブから必要なバージョンのCUDA Toolkitをダウンロードしておく

PyTorch用の環境をつくって、Anaconda promptでPyTorchをインストールする

Poweshell Prompt
conda install pytorch torchvision torchaudio cudatoolkit=11.3 -c pytorch

動作確認

最後にJupyter NotebookでGPUの動作確認をする
Untitled (1).png

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?