I am trying to understand and debug my code. I try to predict with a CNN model developed under tf2.0/tf.keras on GPU, but get those error messages. could someone help me to
Check the instructions on this TensorFlow GPU instruction page for your OS. It resolved issue for me on Ubuntu 16.04.6 LTS and Tensorflow 2.0
You have to check that you have the right version of CUDA + CUDNN + TensorFlow(also ensure that you have all installed.
A couple of examples of running configurations are presented below(UPDATE FOR LATEST VERSION OF TENSORFLOW)
Cuda 10.1
+ CuDNN 7.6.5
(normally > 7.6
) + TensorFlow 2.2.0
/TensorFlow 2.3.0
(TF >= 2.1
requires CUDA >=10.1
)
Cuda 10.1
+ CuDNN 7.6.5
(normally > 7.6
) + TensorFlow 2.1.0
(TF >= 2.1
requires CUDA >=
10.1
)
Cuda 10.0
+ CuDNN 7.6.3
+ / TensorFlow 1.13
/1.14
/ TensorFlow 2.0
.
Cuda 9.0
+ CuDNN 7.0.5
+ TensorFlow 1.10
works
Usually this error appears when you have an incompatible version of TensorFlow/CuDNN installed. In my case, this appeared when I tried using an older TensorFlow with a newer version of CuDNN.
**If for some reason you get an error message like(and nothing happens afterwards) :
Relying on the driver to perform ptx compilation
Solution : Install the latest nvidia driver