What cuDNN is
cuDNN, the CUDA Deep Neural Network library, is NVIDIA’s library of GPU-accelerated building blocks for deep learning. First released in 2014, it provides fast implementations of the operations neural networks are built from, tuned for each NVIDIA GPU architecture.
Frameworks such as PyTorch, TensorFlow and JAX call cuDNN underneath, so they do not have to write and tune those operations themselves for every GPU. You rarely call it directly: you benefit from it through the framework you use. It is one layer of the NVIDIA stack, sitting above CUDA and below the frameworks.
What cuDNN accelerates
Most of the work in a neural network is a handful of operations repeated millions of times. cuDNN supplies optimized versions of those operations.
-
//
Convolutions. The core of image and video models, in many algorithm variants chosen to suit the layer shape and GPU.
-
//
Attention. Fused scaled dot-product attention, including flash-attention style kernels, for transformer models.
-
//
Matrix multiplication. Fused matmul operations, often combined with bias and activation in one step.
-
//
Normalization and pooling. Batch, layer and instance normalization, plus max and average pooling.
-
//
Activations and recurrent layers. ReLU, GELU, sigmoid and other activations, and recurrent layers such as LSTM and GRU.
Where cuDNN sits in the NVIDIA stack
It helps to see cuDNN as one layer in a stack, with each layer relying on the one below.
| Layer | Examples | Job |
|---|---|---|
| Application | Vision, robotics or analytics software | Uses the model’s results |
| Framework or inference engine | PyTorch, TensorFlow, TensorRT | Defines, trains or runs the model |
| Deep learning libraries | cuDNN, cuBLAS | Run individual layers fast on the GPU |
| CUDA runtime and driver | CUDA Toolkit, NVIDIA driver | Launch work on the GPU and manage memory |
| GPU hardware | CUDA cores, Tensor Cores | Do the maths |
cuDNN uses Tensor Cores automatically when the precision and layer shapes allow, which is where much of its speed comes from on recent GPUs. Our guide to common terms in AI GPU computing explains the rest of the vocabulary.
The cuDNN graph API and fusion
Early versions of cuDNN offered one function per operation. Since cuDNN 8, a graph API lets a framework describe several operations together, such as a convolution followed by a bias add and an activation, so cuDNN can fuse them into one GPU kernel. Fusion avoids writing intermediate results to memory and back, which often matters more for speed than the maths itself. cuDNN 9, released in 2024, built on this with faster attention kernels for transformer models, and NVIDIA publishes an open-source C++ and Python front end that makes the graph API easier to use.
cuDNN versions and compatibility
Each cuDNN release is built for particular CUDA major versions, and each framework build expects particular cuDNN and CUDA versions. A mismatch is one of the most common reasons a GPU-accelerated application fails to start or quietly falls back to the CPU. Pip and conda packages of PyTorch now bundle their own cuDNN, which avoids most conflicts on servers.
On a Jetson, cuDNN comes with JetPack, so its version is set by the JetPack release flashed onto the module, and frameworks have to be built against it. We configure these versions together so the deployed software is consistent from the development system to every system in the field. Our Jetson Orin computers and workstation GPUs both run cuDNN-accelerated frameworks.
cuDNN on edge AI computers
At the edge, cuDNN matters most during development and for models that run inside a framework. Teams often prototype on an industrial PC with a discrete GPU, running PyTorch with cuDNN, before converting the model to TensorRT for deployment. Some applications keep the framework in production, for example when models change often or use layers TensorRT does not yet support, and then cuDNN does the work.
Our industrial GPU computers suit that development and on-site training role, with RTX cards whose Tensor Cores cuDNN uses for FP16 and BF16 layers. Matching the cuDNN version on the development system to the one on the deployed system avoids surprises in accuracy and speed.
Installing and checking cuDNN
There are three common routes. On a Jetson, it is installed as part of JetPack. On an x86 server or industrial PC, framework packages from pip or conda usually bring their own copy, and NVIDIA also publishes cuDNN as system packages and archives for developers who build their own software. Use the same route on every system in a fleet, so versions stay identical. To check which version a framework is using, PyTorch reports it with torch.backends.cudnn.version(), and on Jetson the installed packages show it.
Quick answers on cuDNN
cuDNN: common questions
What is the difference between CUDA and cuDNN?
CUDA is the platform; cuDNN is a library built on it. CUDA lets any software run on an NVIDIA GPU. cuDNN uses CUDA to provide ready-made, optimized neural network operations for deep learning frameworks.
Do I have cuDNN installed?
Check from your framework. In PyTorch, torch.backends.cudnn.is_available() and torch.backends.cudnn.version() report it. On Jetson, it is installed with JetPack.
Is cuDNN free?
Yes. cuDNN is free to download and use under NVIDIA’s license, and it is bundled with most GPU builds of PyTorch and TensorFlow.
Does TensorRT need cuDNN?
Less and less. Older TensorRT releases used cuDNN for some layers. Recent releases implement almost all layers themselves, so cuDNN is optional for most models.
Does cuDNN work on AMD GPUs?
No. cuDNN is NVIDIA-only. AMD’s equivalent library for its GPUs is MIOpen, part of the ROCm software stack.
We supply GPU and Jetson computers with matched CUDA, cuDNN and framework versions installed and validated as standard, so your models run as they did in development. Tell us your framework and versions, and we will build the system to match.