Skip to content

Instantly share code, notes, and snippets.

@joyk50
Created May 15, 2020 01:13
Show Gist options
  • Save joyk50/e4c144f54486853a43edba9a95a6963f to your computer and use it in GitHub Desktop.
Save joyk50/e4c144f54486853a43edba9a95a6963f to your computer and use it in GitHub Desktop.
GPU testing for Deep Learning

GPU testing for Deep Learning

  • 사용처

    • 터미널 환경 및 Jupyter에서 Tensorflow, Keras, LightGBM 등 GPU 리소스를 사용하는 라이브러리를 사용하기 전에 GPU 자원 로드가 제대로 되는지 확인하는 방법
  • CUDA 환경변수 설정 확인

import os
print(f'PATH: {os.environ["PATH"]}')
print(f'LD_LIBRARY_PATH: {os.environ["LD_LIBRARY_PATH"]}')
  • Tensorflow GPU 로드 확인
import tensorflow as tf
print(tf.__version__)
tf.test.is_gpu_available()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment