Table of Contents |
---|
Dependencies for using GPU
...
NVIDIA driver
...
Pre-check up
Note |
---|
Firstly, You have to determine which versions you want to use for each library and NVIDA driver.
|
...
...
...
Info |
---|
You may need to update for NVIDIA driver. FYI, the required NVIDIA driver:
|
If the versions of CUDA of what you gonna use are satisfied with NVIDA driver, you can skip this page.
See the next sub-pages.
NVIDIA driver
Checking current version
Code Block | ||
---|---|---|
| ||
# Cuda $ Driver version check $ nvidia-smi TueThu DecMar 0804 1613:1800:1819 20202021 +-----------------------------------------------------------------------------+ | NVIDIA-SMI 442.62 Driver Version: 442.62 CUDA Version: 10.2 | |-------------------------------+----------------------+----------------------+ | GPU Name TCC/WDDM | Bus-Id Disp.A | Volatile Uncorr. ECC | | Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. | |===============================+======================+======================| | 0 GeForce GTX 1060 WDDM | 00000000:01:00.0 On | N/A | | N/A 49C 50C P8 P0 26W4W / N/A | 1558MiB831MiB / 6144MiB | 0% Default | +-------------------------------+----------------------+----------------------+ +-----------------------------------------------------------------------------+ | Processes: GPU Memory | | GPU PID Type Process name Usage | |=============================================================================| | 0 1384 C+G Insufficient Permissions N/A | | 0 3584 C+G ...14511.0_x64__8wekyb3d8bbwe\Video.UI.exe N/A | | 0 6700 C+G ...w5n1h2txyewy\InputApp\TextInputHost.exe N/A | | 0 9796 C+G C:\Windows\explorer.exe N/A | | 0 12024 C+G ...dows.Search_cw5n1h2txyewy\SearchApp.exe N/A | | 0 13092 C+G ...osoft.LockApp_cw5n1h2txyewy\LockApp.exe N/A | | 0 13404 C+G ...t_cw5n1h2txyewy\ShellExperienceHost.exe N/A | | 0 13652 C+G ....125.0_x64__8wekyb3d8bbwe\YourPhone.exe N/A | | 0 15252 C+G ...001.0001_1447f3a4afa4575f\X-Pointer.exe N/A | | 0 15948 C+G ...boxAlpha Messenger\BizboxAMessenger.exe N/A | | 0 16096 C+G ...ppData\Local\slack\app-4.10.3\slack.exe N/A | | 0 24692 C+G ...File Stream\44.0.12.0\GoogleDriveFS.exe N/A | | 0 29640 C+G ...cal\Programs\Microsoft VS Code\Code.exe N/A | | 0 35504 C+G ...ogram Files\Mozilla Firefox\firefox.exe N/A | | 0 38972 C+G ...5n1h2txyewy\StartMenuExperienceHost.exe N/A | | 0 39284 C+G ...mmersiveControlPanel\SystemSettings.exe N/A | | 0 46152 C+G ...6)\Google\Chrome\Application\chrome.exe N/A | | 0 61976 C+G ...10.2011.4.0_x64__8wekyb3d8bbwe\Maps.exe N/A | | 0 62280 C+G ...ta\Local\Postman\app-7.36.0\Postman.exe N/A | | 0 66980 C+G ...ogram Files\Mozilla Firefox\firefox.exe N/A | | 0 71656 C+G ...x64__8wekyb3d8bbwe\Microsoft.Photos.exe N/A | | 0 77796 C+G ...8wekyb3d8bbwe\Microsoft.Msn.Weather.exe N/A | | 0 91232 C+G ...9.4.0_x64__8wekyb3d8bbwe\Calculator.exe N/A | +-----------------------------------------------------------------------------+ |
Setting Keras Environment
Prerequisites
For your convenience, you'd better install and use git bash.
Therefore, I will test on git bash or bash terminal integrated within VSCode.
...
Warning |
---|
This Driver is included within CUDA toolkit of the next section. |
Download: https://www.nvidia.co.kr/Download/index.aspx?lang=kr
Manual installing the CUDA library.
Info |
---|
You can install CUDA library with conda. The way of using conda, you can see the next sub-pages. |
Child pages (Children Display) |
---|
CUDA Toolkit
Download: https://developer.nvidia.com/cuda-toolkit-archive
Warning |
---|
If NVIDA driver has been already installed as what is satisfied, unselect the driver into the custom install step. |
cuDNN
Download: https://
...
...
...
...
Setting Keras
Install Karas from Yaml
Code Block | ||
---|---|---|
| ||
# Make yaml file.
$ vi environment-gpu.yml
name: keras-study
dependencies:
- python=3.7
- scikit-learn
- scipy
- numpy
- matplotlib
- ipython
- jupyter
- pillow
- opencv
- graphviz
- cython
- pip:
- tensorflow-gpu==1.15
- keras==2.2.4
- pydot-ng
# Create conda env
$ conda env create -f environment-gpu.yml
# Enter karas-study env
$ conda activate karas-study |
...
If not able to activate a certain conda env, add this instruction into .bashrc
...
Installation: https://docs.nvidia.com/deeplearning/cudnn/install-guide/index.html#installwindows