TensorFlow
GPU
Machine Learning
TensorFlow 1.14.0
Deep Learning

TensorFlow 1.14.0 is not using GPU

Master System Design with Codemia

Enhance your system design skills with over 120 practice problems, detailed solutions, and hands-on exercises.

Introduction

When TensorFlow 1.14.0 does not use the GPU, the cause is usually environment mismatch rather than model code. TensorFlow 1.14 is old and expects a very specific CUDA, cuDNN, and driver combination, so one missing or incompatible component is enough to make it fall back to CPU.

Core Sections

Confirm that TensorFlow sees a GPU at all

Start with visibility checks before changing installation steps.

python
1import tensorflow as tf
2from tensorflow.python.client import device_lib
3
4print(tf.__version__)
5print(device_lib.list_local_devices())

In TensorFlow 1.14, a healthy GPU setup should show a device of type GPU. If only CPU devices appear, TensorFlow is not seeing the CUDA stack correctly.

You should also confirm that the NVIDIA driver sees the card:

bash
nvidia-smi

If nvidia-smi fails, the problem is below TensorFlow and must be fixed at the driver level first.

TensorFlow 1.14 expects old CUDA dependencies

This is where many setups fail. TensorFlow 1.14 GPU support is tied to an older CUDA stack. A common working combination is:

  • NVIDIA driver compatible with your GPU
  • CUDA 10.0
  • cuDNN 7.4 for CUDA 10.0

Installing a newer CUDA version does not automatically help. In fact, it often breaks compatibility for this TensorFlow release because 1.14 was built against older libraries.

Make sure you installed the GPU-capable package

With TensorFlow 1.x, GPU and CPU packaging differed depending on the exact release and install path. Verify what is actually installed in the environment you are running.

bash
python -m pip show tensorflow
python -m pip show tensorflow-gpu

On older setups, the GPU package might be tensorflow-gpu==1.14.0. If only a CPU-oriented package is present, no amount of CUDA debugging will make that environment use the GPU.

Watch library paths and environment variables

Even when the right CUDA and cuDNN versions are installed, TensorFlow must be able to find them. On Linux this often means checking LD_LIBRARY_PATH. On Windows it usually means checking PATH entries for CUDA and cuDNN DLLs.

A correct installation can still silently fall back to CPU if the runtime libraries are not discoverable from the current shell or IDE.

Enable logging for placement clues

If TensorFlow does see the GPU but still appears CPU-bound, turn on device placement logging.

python
1import tensorflow as tf
2
3config = tf.ConfigProto(log_device_placement=True)
4with tf.Session(config=config) as sess:
5    a = tf.constant([[1.0, 2.0]])
6    b = tf.constant([[3.0], [4.0]])
7    print(sess.run(tf.matmul(a, b)))

That helps distinguish "TensorFlow cannot see the GPU" from "TensorFlow can see it but specific ops are still placed on CPU."

In TensorFlow 1.x you may also see useful startup logs about missing CUDA libraries or failed device registration. Those warnings are often more informative than the final symptom, because they point directly at the missing dependency or incompatible runtime library.

Common Pitfalls

  • Installing TensorFlow 1.14 and pairing it with a newer CUDA version that it was not built for.
  • Debugging TensorFlow first even though nvidia-smi already shows the GPU driver stack is broken.
  • Forgetting that older environments may need tensorflow-gpu rather than a CPU-only TensorFlow package.
  • Assuming library installation is enough when the runtime cannot actually find CUDA or cuDNN on the current path.
  • Expecting modern TensorFlow GPU setup guides to apply cleanly to a legacy 1.14 environment.

Summary

  • TensorFlow 1.14 GPU problems are usually compatibility problems, not model-code problems.
  • First verify the GPU at the driver level with nvidia-smi.
  • Then confirm that TensorFlow 1.14 can enumerate a GPU device.
  • Use the CUDA and cuDNN versions that match this legacy TensorFlow release.
  • Treat TensorFlow 1.14 as an environment pinning problem: exact versions matter.

Course illustration
Course illustration

All Rights Reserved.