1

I have been trying to use Tensorflow GPU, but apparently, Tersorflow is not identifying my GPUs.

When I run:

from tensorflow.python.client import device_lib
print(device_lib.list_local_devices())

As an output, only my CPU shows up. I have checked all of the versions of everything and they seem to be compatible. I have CUDA 10.1 with CUDA Toolkit, cuDNN 7.5 and Tensorflow 1.13.1. I am running everything on Ubuntu 18.xx

What am I doing wrong?

talonmies
  • 70,661
  • 34
  • 192
  • 269
user3368101
  • 73
  • 1
  • 1
  • 6
  • Do you actually have a CUDA compatible GPU? – talonmies Mar 11 '19 at 10:12
  • Yes. I have a NVIDIA GM200 (GeForce GTX Titan X). The computing capability is also above the one required by Tensorflow – user3368101 Mar 11 '19 at 10:42
  • What is the output of `nvidia-smi`? – o-90 Mar 11 '19 at 15:18
  • This is the output: | NVIDIA-SMI 418.43 Driver Version: 418.43 CUDA Version: 10.1 | |-------------------------------+----------------------+----------------------+ | GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC | | Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. | |===============================+======================+======================| | 0 GeForce GTX TIT... Off | 00000000:01:00.0 Off | N/A | | 17% 56C P0 62W / 250W | 0MiB / 12210MiB | 0% Default | – user3368101 Mar 11 '19 at 16:05

1 Answers1

0

what is the output of:

from tensorflow.python.client import device_lib

device_lib.list_local_devices()

On my system, tensorflow is not recognizing GPU because it is a XLA_GPU. I'm not really sure why a XLA_GPU is not also a GPU, seems there is a OR statement missing somewhere in the tensorflow-gpu code.

If above code does not list any GPUs (and you have one):

pip uninstall tensorflow
pip uninstall tensorflow-gpu
pip install tensorflow-gpu 

… worked for me.

Obsidian
  • 3,719
  • 8
  • 17
  • 30
tak
  • 21
  • 7