Learn Python

Learn Data Structure & Algorithm

Learn Numpy

Learn Pandas

Learn Matplotlib

Learn Seaborn

Learn Statistics

Learn Math

Learn MATLAB

Learn Machine learning

Learn Github

Learn OpenCV

Introduction

Setup

ANN

Working process ANN

Propagation

Bias parameter

Activation function

Loss function

Overfitting and Underfitting

Optimization function

Chain rule

Minima

Gradient problem

Weight initialization

Dropout

ANN Regression Exercise

ANN Classification Exercise

Hyper parameter tuning

CNN

CNN basics

Convolution

Padding

Pooling

Data argumentation

Flattening

Create Custom Dataset

Binary Classification Exercise

Multiclass Classification Exercise

Transfer learning

Transfer model Basic template

RNN

How RNN works

LSTM

Bidirectional RNN

Sequence to sequence

Attention model

Transformer model

Bag of words

Tokenization & Stop words

Stemming & Lemmatization

TF-IDF

N-Gram

Word embedding

Normalization

Pos tagging

Parser

semantic analysis

Regular expression

Learn MySQL

Learn MongoDB

Learn Web scraping

Learn Excel

Learn Power BI

Learn Tableau

Learn Docker

Learn Hadoop

Learn most used transfer learning model architecture

VGG16




In the image blue colored squares indicate convolution layer, red-colored squares indicate max-pooling layer and green colors indicated fully connected layers. In VGG16 all the convolution layer filter size is 3x3, the stride is 1 and padding is the same. Here we pass 224x224x3 size images. So when we pass the image we need to get the same output for the previous image. Only the number of the kernel will change. It means that we are applying a 3x3 filter and the number of filters we are using is 64. We use convolution with a relu activation function. In VGG16 all the max-pooling layer filter size is 2x2 and stride is 2.

For these properties when we pass the image through the max polling layer and because of stride 2 we will always get the half size of the previous image size and the size of the kernel will become double for the first three max-pooling layers but after three max-pooling layers the kernel size will be always same but the image size will decrease by half. Like, after passing from the first convolution layer our image size was 224x224x64 but after passing from the first max polling layer now our image becomes 112x112x128.
To calculate we use formula: {(n+2p-f)/s}+1.
Now after passing the image from the second max-pooling layer we get 56x56x256, after the third max-pooling layer 28x28x512, after four 14x14x512(kernel size is same as previous), after five 7x7x512(kernel size is same as previous). After this, we will apply three fully connected layers with relu activation function.

Alex net




Here in the image at first, we have an image whose shape is 227x227x3. Now we will pass this image in various convolution layers,max-pooling layers.

First convolution layer:
Here filter size=11x11, stride=4 and kernels=96. So here we are using 96 filters. After passing out the image from the first convolution layer our image size is 55x55x96. Now we will pass this image to a max-pooling layer.

Max pooling layer:
Here max pooling is 3x3 and stride=2. After passing out from the max-pooling layer the image size will be 27x27x96. Now we will pass this image again from a convolution layer.

Convolution layer:
Here our kernel size is=256,filter size=5x5 padding=2,stride=1. Here we use padding. After passing out from this layer our image size will be 27x27x256. Now we will pass the image to a max-pooling layer.

Max pooling layer:
Here stride=2,max pooling=3x3.Now our image size will be 13x13x256. Now we will again pass this image to a convolution layer.

Convolution layer:
Here filter size=3x3,padding=1,kernels=384.Here our image size after passing out is 13x13x13.Now we pass the image again to a convolution layer.

Convolution layer:
Here filter size=3x3,padding=1,kernels=384.Here our image size after passing out is 13x13x13.Now we pass the image again to a convolution layer.

Convolution layer:
Here filter size=3x3,padding=1,kernels=256.Here our image size after passing out is 13x13x13. Now we pass the image again to a max-pooling layer.

Max pooling layer:
Here stride=2,max pooling =3x3.Here the image size after convolution is 6x6x256.

Now we will pass the image to a fully connected layer or dense layer where we have 4096 nodes. We will use two fully connected layers. Then we will pass the output of the fully connected layer to the output layer. Here we will use the softmax activation function.

CodersAim is created for learning and training a self learner to become a professional from beginner. While using CodersAim, you agree to have read and accepted our terms of use, privacy policy, Contact Us

© Copyright All rights reserved www.CodersAim.com. Developed by CodersAim.