You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

14 lines
243 B
Python

#!/usr/bin/python3
import os
import tensorflow as tf
os.system('nvidia-smi')
hello = tf.constant('Hello, TensorFlow!')
sess = tf.compat.v1.Session()
print(sess.run(hello))
print('GPU available:', tf.test.is_gpu_available(cuda_only=True))