Deep Learning Frameworks
Dr. Dinesh K. Vishwakarma
PROFESSOR, DEPARTMENT OF INFORMATION TECHNOLOGY
DELHI TECHNOLOGICAL UNIVERSITY, DELHI.
Webpage: http://www.dtu.ac.in/Web/Departments/InformationTechnology/faculty/dkvishwakarma.php
Email: dinesh@dtu.ac.in
Outline
2
11/13/2026
Objectives
3
11/13/2026
Why Do We Need Frameworks?
4
Without a framework
With a framework
→
11/11/2026
Anatomy of a Deep Learning Stack
5
Your model & experiment code
(classifier, detector, language model)
High-level API
Keras · torch.nn · Lightning · Hugging Face
Core framework
Tensors · autograd · graph compiler · optimisers
Math / GPU libraries
CUDA · cuDNN · cuBLAS · XLA · oneDNN
Hardware
CPU · NVIDIA GPU · Google TPU · Apple/AMD accelerators
Higher abstraction
Easier to write, less control
Closer to hardware
Faster, more control
11/11/2026
A Short History of Frameworks
6
2007
Theano
Symbolic graphs, auto-diff (Montréal)
2013
Caffe
Fast CNNs, config files (Berkeley)
2015
TensorFlow 1.x
Keras
Static graphs, sessions (Google)
2016
PyTorch
Dynamic graphs, Pythonic (Facebook/Meta)
2019
TensorFlow 2
Eager mode + Keras built in
2018+
JAX
NumPy + autograd + XLA (Google)
2023
Keras 3
One API on TF, JAX, PyTorch
Trend: from static, hard-to-debug graphs to define-by-run Python code.
11/11/2026
Tensors: The Basic Data Structure
7
Scalar
rank 0-D
3.5
Vector
rank 1-D
[1, 2, 3]
Matrix
rank 2-D
[[1,2],[3,4]]
3-D+ tensor
rank 3-D…
images, video
Every tensor has a shape, a dtype and a device (CPU or GPU).
import torch
x = torch.randn(32, 3, 224, 224) # batch of 32 RGB images
print(x.shape, x.dtype) # torch.Size([32,3,224,224]) float32
x = x.to("cuda") # move to GPU (if available)
y = x.mean(dim=(2, 3)) # shape (32, 3)
Layout conventions
11/11/2026
Introduction
8
11/13/2026
TensorFlow | Google Brain, 2015 (rewritten DistBelief) |
Keras | François Chollet, 2015 (now at Google) |
PyTorch/Torch | |
Caffe | Berkeley Vision and Learning Center (BVLC), 2013 |
Apache MXNet |
TensorFlow: Introduction
9
11/13/2026
TensorFlow: Architecture
10
11/13/2026
TensorFlow: Graphs
11
11/13/2026
TensorBoard
Why is TensorFlow popular?
12
11/13/2026
Keras
13
11/13/2026
Keras: Simplicity
kernel = tf.Variable(tf.truncated_normal([3, 3, 64, 64], dtype=tf.float32,stddev=1e-1), name='weights')
conv = tf.nn.conv2d(self.conv1_1, kernel, [1, 1, 1, 1], padding='SAME')
biases = tf.Variable(tf.constant(0.0, shape=[64], dtype=tf.float32), trainable=True, name='biases')
out = tf.nn.bias_add(conv, biases)
self.conv1_2 = tf.nn.relu(out, name='block1_conv2')
x = Convolution2D(64, 3, 3, activation='relu', border_mode='same', name='block1_conv2')(x)
14
11/13/2026
Keras: Advantages and Limits
15
11/13/2026
PyTorch
16
11/13/2026
Used by: Facebook (Meta) and Twitter
Caffe
17
11/13/2026
Caffe: Strengths and Limitations
18
11/13/2026
Apache MXNet
19
11/13/2026
Apache MXNet: Key Facts
20
11/13/2026
Apache MXNet: Benefits
21
11/13/2026
Comparison of Frameworks
DL Library | K80/CUDA 8/CuDNN 6 | P100/CUDA 8/CuDNN 6 |
148 | 54 | |
162 | 69 | |
163 | 53 | |
152 | 57 | |
194 | 76 | |
241 | 76 | |
269 | 93 | |
173 | 57 | |
253 | 65 | |
145 | 52 | |
169 | 51 | |
159 | ?? | |
205 | 72 |
Training Time: CNN (VGG-style, 32bit) on CIFAR-10
DL Library | K80/CUDA 8/CuDNN 6 | P100/CUDA 8/CuDNN 6 |
14.1 | 7.9 | |
9.3 | 2.7 | |
8.5 | 1.6 | |
| 1.7 | |
21.7 | 5.9 | |
10.2 | 2.9 | |
6.5 | 1.8 | |
7.7 | 1.6 | |
7.7 | 1.9 | |
6.3 | ??? | |
??? | ??? | |
17 | 7.4 |
Avg. Feature Extraction Time: ResNet-50; 1000 Images
Source: https://github.com/ilkarman/DeepLearningFrameworks
Choosing a Framework
23
11/13/2026
Choosing a Framework (continued)
24
11/13/2026
Good deep learning framework
25
11/13/2026
Conclusion
26
11/13/2026
References
27
11/13/2026
Thank You�Contact: dinesh@dtu.ac.in �Mobile: +91-9971339840
28
11/13/2026