Introduction to
Convolutional
Neural Network
Data Science
Applications
Neural Network
Shallow learning
Deep learning
Neural Network
Artificial Neural Network
(ANN)
Regression and classification
Convolutional Neural Network
(CNN)
Computer Vision
Recurrent Neural Network
(RNN)
Time series analysis
Artificial Neural Network
Single layer perceptron Multi-layer perceptron
Convolutional
Neural
Network
Convolutional Neural Networks (CNNs) learns multi-level features and
classifier in a joint fashion and performs much better than traditional
approaches for various image classification and segmentation problems.
Introduction
Low
Level
Features
Mid
Level
Features
Output
(e.g. car, train)
High
Level
Features
Trainable
Classifier
CNN – What do they learn?
Convolutional layers Fully connected layers
There are four main components in the CNN:
1. Convolution
2. Non-Linearity
3. Pooling or Sub Sampling
4. Classification (Fully Connected Layer)
CNN - Components
Input
• An Image is a matrix of pixel values.
• If we consider a gray scale image,
the value of each pixel in the
matrix will range from 0 to 255.
• If we consider an RGB image, each
pixel will have the combined values
of R, G and B.
Convolution
The primary purpose of Convolution in case of a CNN is to extract
features from the input image.
Convolved Feature /
Activation Map /
Feature Map
Image
Filter / Kernel / Feature detector
Convolution…
• The size of the output volume is controlled by three parameters that we
need to decide before the convolution step is performed:
Depth: Depth corresponds to the number of filters we use for the convolution
operation.
Stride: Stride is the number of pixels by which we slide our filter matrix over the
input matrix.
Zero-padding: Sometimes, it is convenient to pad the input matrix with zeros
around the border, so that we can apply the filter to bordering elements of our
input image matrix.
• With zero-padding wide convolution
• Without zero-padding narrow convolution
Convolution...
• Replaces all negative pixel values in the feature
map by zero.
• The purpose of ReLU is to introduce non-
linearity in CNN, since most of the real-world
data would be non-linear.
• Other non-linear functions such as tanh (-1,1)
or sigmoid (0,1) can also be used instead of
ReLU (0,input).
Non-Linearity (ReLU)
Pooling
Reduces the dimensionality of each feature map but retains the most important
information. Pooling can be of different types: Max, Average, Sum etc.
2×2 region
• Together these layers extract the useful features from the images.
• The output from the convolutional and pooling layers represent high-level
features of the input image.
Story so far
High-level features
• A traditional Multi-Layer Perceptron.
• The term “Fully Connected” implies that every neuron in the previous layer is
connected to every neuron on the next layer.
• Their activations can hence be computed with a matrix multiplication followed by a
bias offset.
• The purpose of the Fully Connected layer is to use the high-level features for
classifying the input image into various classes based on the training dataset.
Fully Connected Layer
Fully Connected Layer…
Introduction to
Convolutional
Neural Network
Overall CNN Architecture
Putting it all together – Training using Backpropagation
• Step 1: We initialize all filters and parameters / weights with random values.
• Step 2: The network takes a training image as input, goes through the forward
propagation step (convolution, ReLU and pooling operations along with forward
propagation in the Fully Connected layer) and finds the output
probabilities for each class.
• Let’s say the output probabilities for the boat image above are [0.2, 0.4, 0.1, 0.3].
• Since weights are randomly assigned for the first training example, output probabilities are also
random.
• Step 3: Calculate the total error at the output layer (summation over all 4
classes).
• Step 4: Use Backpropagation to calculate the gradients of the error with respect to
all weights in the network and use gradient descent to update all filter values/
weights and parameter values to minimize the output error.
• The weights are adjusted in proportion to their contribution to the total error.
• When the same image is input again, output probabilities might now be [0.1, 0.1, 0.7, 0.1], which is
closer to the target vector [0, 0, 1, 0].
• This means that the network has learnt to classify this particular image correctly by adjusting its
weights / filters such that the output error is reduced.
• Parameters like number of filters, filter sizes, architecture of the network etc. have all been fixed
before Step 1 and do not change during training process – only the values of the filter matrix and
connection weights get updated.
• Step 5: Repeat steps 2-4 with all images in the training set.
CNN Architectures
Year CNN Architecture Developed By
1998 LeNet Yann LeCun et al.
2012 AlexNet Alex Krizhevsky, Geoffrey Hinton, and Ilya Sutskever
2013 ZFNet Matthew Zeiler and Rob Fergus
2014 GoogleNet Google
2014 VGGNet Simonyan and Zisserman
2015 ResNet Kaiming He
2017 DenseNet Gao Huang, Zhuang Liu, Laurens van der Maaten, and Kilian Q. Weinberger
AlexNet LeNet
GoogleNet
ResNet
VGG-16
DenseNet
Recurrent Neural Network - RNN
What are the differences among ANN, CNN and RNN?
Visualizing a CNN
• Adam Harley created amazing visualizations of a Convolutional Neural
Network trained on the MNIST Database of handwritten digits
• 2D Visualisation of a CNN - http://scs.ryerson.ca/~aharley/vis/conv/flat.html
• 3D Visualisation of a CNN - http://scs.ryerson.ca/~aharley/vis/conv/
Thank You!

More Related Content

PPTX
Raspberry Pi
PPTX
Unit 1 computer architecture (1)
PPTX
Optical memory
PPTX
BASIC COMPUTER ARCHITECTURE
PPTX
Memory organization (Computer architecture)
PPTX
Introduction to the Arduino
PDF
Computer organiztion5
PPTX
IPV6 Header format.pptx
Raspberry Pi
Unit 1 computer architecture (1)
Optical memory
BASIC COMPUTER ARCHITECTURE
Memory organization (Computer architecture)
Introduction to the Arduino
Computer organiztion5
IPV6 Header format.pptx

What's hot (20)

PPTX
Multithreading computer architecture
PDF
Array linear data_structure_2 (1)
PPT
Sensor Protocols for Information via Negotiation (SPIN)
PPTX
Neural network
PPTX
Control Strategies in AI
PPTX
Deep learning
PPTX
Single Layer Rosenblatt Perceptron
PDF
Intermediate code generation in Compiler Design
PDF
Difference between OSI Layer & TCP/IP Layer
PDF
PDF
PDF
Deep learning
PPT
Error detection and correction
PPTX
06 floating point
PPTX
Presentation on cyclic redundancy check (crc)
PPTX
Priority_Scheduling.pptx
PPTX
Binary Class and Multi Class Strategies for Machine Learning
PPTX
Control Function - Computer Architecture
PPTX
Computer organization and architecture
Multithreading computer architecture
Array linear data_structure_2 (1)
Sensor Protocols for Information via Negotiation (SPIN)
Neural network
Control Strategies in AI
Deep learning
Single Layer Rosenblatt Perceptron
Intermediate code generation in Compiler Design
Difference between OSI Layer & TCP/IP Layer
Deep learning
Error detection and correction
06 floating point
Presentation on cyclic redundancy check (crc)
Priority_Scheduling.pptx
Binary Class and Multi Class Strategies for Machine Learning
Control Function - Computer Architecture
Computer organization and architecture
Ad

Similar to cnn.pdf (20)

PDF
DL.pdf
PPTX
Convolutional Neural Network and Its Applications
PPTX
intro-to-cnn-April_2020.pptx
PPTX
Introduction to Convolutional Neural Networks
PPTX
Deep Learning
PPTX
Introduction to convolutional networks .pptx
PPTX
build a Convolutional Neural Network (CNN) using TensorFlow in Python
PPTX
Introduction to Convolutional Neural Networks (CNNs).pptx
PDF
Convolutional Neural Networks (CNN)
PDF
Mnist report
PPTX
cnn ppt.pptx
PPTX
IMAGE CLASSIFICATION USING CONVOLUTIONAL NEURAL NETWORK.P.pptx
PPTX
Introduction to deep learning
PPTX
Mnist report ppt
PDF
Classification of Images Using CNN Model and its Variants
PPTX
Deep learning L1-CO2-session-4 CNN .pptx
PDF
A STUDY OF METHODS FOR TRAINING WITH DIFFERENT DATASETS IN IMAGE CLASSIFICATION
PPTX
Intro to NeuralNets and training of the network and shallow neural network
PPTX
Basic Introduction to Convolutional Neural Network.pptx
PPTX
A Fully Progressive approach to Single image super-resolution
DL.pdf
Convolutional Neural Network and Its Applications
intro-to-cnn-April_2020.pptx
Introduction to Convolutional Neural Networks
Deep Learning
Introduction to convolutional networks .pptx
build a Convolutional Neural Network (CNN) using TensorFlow in Python
Introduction to Convolutional Neural Networks (CNNs).pptx
Convolutional Neural Networks (CNN)
Mnist report
cnn ppt.pptx
IMAGE CLASSIFICATION USING CONVOLUTIONAL NEURAL NETWORK.P.pptx
Introduction to deep learning
Mnist report ppt
Classification of Images Using CNN Model and its Variants
Deep learning L1-CO2-session-4 CNN .pptx
A STUDY OF METHODS FOR TRAINING WITH DIFFERENT DATASETS IN IMAGE CLASSIFICATION
Intro to NeuralNets and training of the network and shallow neural network
Basic Introduction to Convolutional Neural Network.pptx
A Fully Progressive approach to Single image super-resolution
Ad

Recently uploaded (20)

PPTX
Configure Apache Mutual Authentication
PDF
Architecture types and enterprise applications.pdf
PDF
Taming the Chaos: How to Turn Unstructured Data into Decisions
PDF
Hindi spoken digit analysis for native and non-native speakers
PDF
The influence of sentiment analysis in enhancing early warning system model f...
PPTX
2018-HIPAA-Renewal-Training for executives
PDF
A Late Bloomer's Guide to GenAI: Ethics, Bias, and Effective Prompting - Boha...
PDF
A proposed approach for plagiarism detection in Myanmar Unicode text
PDF
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
PDF
1 - Historical Antecedents, Social Consideration.pdf
PDF
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
PDF
TrustArc Webinar - Click, Consent, Trust: Winning the Privacy Game
PDF
NewMind AI Weekly Chronicles – August ’25 Week III
PPTX
Custom Battery Pack Design Considerations for Performance and Safety
PPT
Geologic Time for studying geology for geologist
PDF
Getting started with AI Agents and Multi-Agent Systems
PPTX
Chapter 5: Probability Theory and Statistics
DOCX
search engine optimization ppt fir known well about this
PDF
Hybrid horned lizard optimization algorithm-aquila optimizer for DC motor
PPTX
Modernising the Digital Integration Hub
Configure Apache Mutual Authentication
Architecture types and enterprise applications.pdf
Taming the Chaos: How to Turn Unstructured Data into Decisions
Hindi spoken digit analysis for native and non-native speakers
The influence of sentiment analysis in enhancing early warning system model f...
2018-HIPAA-Renewal-Training for executives
A Late Bloomer's Guide to GenAI: Ethics, Bias, and Effective Prompting - Boha...
A proposed approach for plagiarism detection in Myanmar Unicode text
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
1 - Historical Antecedents, Social Consideration.pdf
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
TrustArc Webinar - Click, Consent, Trust: Winning the Privacy Game
NewMind AI Weekly Chronicles – August ’25 Week III
Custom Battery Pack Design Considerations for Performance and Safety
Geologic Time for studying geology for geologist
Getting started with AI Agents and Multi-Agent Systems
Chapter 5: Probability Theory and Statistics
search engine optimization ppt fir known well about this
Hybrid horned lizard optimization algorithm-aquila optimizer for DC motor
Modernising the Digital Integration Hub

cnn.pdf

  • 6. Neural Network Artificial Neural Network (ANN) Regression and classification Convolutional Neural Network (CNN) Computer Vision Recurrent Neural Network (RNN) Time series analysis
  • 7. Artificial Neural Network Single layer perceptron Multi-layer perceptron
  • 9. Convolutional Neural Networks (CNNs) learns multi-level features and classifier in a joint fashion and performs much better than traditional approaches for various image classification and segmentation problems. Introduction
  • 10. Low Level Features Mid Level Features Output (e.g. car, train) High Level Features Trainable Classifier CNN – What do they learn? Convolutional layers Fully connected layers
  • 11. There are four main components in the CNN: 1. Convolution 2. Non-Linearity 3. Pooling or Sub Sampling 4. Classification (Fully Connected Layer) CNN - Components
  • 12. Input • An Image is a matrix of pixel values. • If we consider a gray scale image, the value of each pixel in the matrix will range from 0 to 255. • If we consider an RGB image, each pixel will have the combined values of R, G and B.
  • 13. Convolution The primary purpose of Convolution in case of a CNN is to extract features from the input image. Convolved Feature / Activation Map / Feature Map Image Filter / Kernel / Feature detector
  • 15. • The size of the output volume is controlled by three parameters that we need to decide before the convolution step is performed: Depth: Depth corresponds to the number of filters we use for the convolution operation. Stride: Stride is the number of pixels by which we slide our filter matrix over the input matrix. Zero-padding: Sometimes, it is convenient to pad the input matrix with zeros around the border, so that we can apply the filter to bordering elements of our input image matrix. • With zero-padding wide convolution • Without zero-padding narrow convolution Convolution...
  • 16. • Replaces all negative pixel values in the feature map by zero. • The purpose of ReLU is to introduce non- linearity in CNN, since most of the real-world data would be non-linear. • Other non-linear functions such as tanh (-1,1) or sigmoid (0,1) can also be used instead of ReLU (0,input). Non-Linearity (ReLU)
  • 17. Pooling Reduces the dimensionality of each feature map but retains the most important information. Pooling can be of different types: Max, Average, Sum etc. 2×2 region
  • 18. • Together these layers extract the useful features from the images. • The output from the convolutional and pooling layers represent high-level features of the input image. Story so far High-level features
  • 19. • A traditional Multi-Layer Perceptron. • The term “Fully Connected” implies that every neuron in the previous layer is connected to every neuron on the next layer. • Their activations can hence be computed with a matrix multiplication followed by a bias offset. • The purpose of the Fully Connected layer is to use the high-level features for classifying the input image into various classes based on the training dataset. Fully Connected Layer
  • 23. Putting it all together – Training using Backpropagation • Step 1: We initialize all filters and parameters / weights with random values. • Step 2: The network takes a training image as input, goes through the forward propagation step (convolution, ReLU and pooling operations along with forward propagation in the Fully Connected layer) and finds the output probabilities for each class. • Let’s say the output probabilities for the boat image above are [0.2, 0.4, 0.1, 0.3]. • Since weights are randomly assigned for the first training example, output probabilities are also random. • Step 3: Calculate the total error at the output layer (summation over all 4 classes).
  • 24. • Step 4: Use Backpropagation to calculate the gradients of the error with respect to all weights in the network and use gradient descent to update all filter values/ weights and parameter values to minimize the output error. • The weights are adjusted in proportion to their contribution to the total error. • When the same image is input again, output probabilities might now be [0.1, 0.1, 0.7, 0.1], which is closer to the target vector [0, 0, 1, 0]. • This means that the network has learnt to classify this particular image correctly by adjusting its weights / filters such that the output error is reduced. • Parameters like number of filters, filter sizes, architecture of the network etc. have all been fixed before Step 1 and do not change during training process – only the values of the filter matrix and connection weights get updated. • Step 5: Repeat steps 2-4 with all images in the training set.
  • 26. Year CNN Architecture Developed By 1998 LeNet Yann LeCun et al. 2012 AlexNet Alex Krizhevsky, Geoffrey Hinton, and Ilya Sutskever 2013 ZFNet Matthew Zeiler and Rob Fergus 2014 GoogleNet Google 2014 VGGNet Simonyan and Zisserman 2015 ResNet Kaiming He 2017 DenseNet Gao Huang, Zhuang Liu, Laurens van der Maaten, and Kilian Q. Weinberger
  • 29. What are the differences among ANN, CNN and RNN?
  • 30. Visualizing a CNN • Adam Harley created amazing visualizations of a Convolutional Neural Network trained on the MNIST Database of handwritten digits • 2D Visualisation of a CNN - http://scs.ryerson.ca/~aharley/vis/conv/flat.html • 3D Visualisation of a CNN - http://scs.ryerson.ca/~aharley/vis/conv/