1
00:00:01,860 --> 00:00:05,340
As you might remember, model has three parts.

2
00:00:05,830 --> 00:00:16,620
The model architecture, the model configuration and fitting the model first will define the model architecture.

3
00:00:17,460 --> 00:00:21,210
I've shown you the architecture that we are creating for this problem.

4
00:00:22,740 --> 00:00:28,500
After the input layer, the first layer that we will have is a convolutional to deliver

5
00:00:31,280 --> 00:00:32,310
in this layer.

6
00:00:32,490 --> 00:00:34,920
We are going to have 32 feature maps.

7
00:00:35,250 --> 00:00:45,450
So we are going to use 32 filters the city first parameter each week that has a window size or a receptive

8
00:00:45,570 --> 00:00:48,420
field of three by three pixels.

9
00:00:50,070 --> 00:00:57,300
So the first neuron in this convolutional layer will look at only three and two three.

10
00:00:57,330 --> 00:01:01,230
That is a square of nine pixels in the input image.

11
00:01:04,130 --> 00:01:12,390
So that is the kernel size or the window dimensions of our feet that the activation function for our

12
00:01:12,390 --> 00:01:13,370
convolutional layer.

13
00:01:13,920 --> 00:01:15,720
We are using here is Relu

14
00:01:18,570 --> 00:01:24,900
and the input shape of the images is 28 by 28 and one.

15
00:01:25,230 --> 00:01:29,250
So these two are the height and weight of images.

16
00:01:29,730 --> 00:01:31,500
And this is the channel.

17
00:01:35,190 --> 00:01:37,290
Next it is a max pooling layer.

18
00:01:38,400 --> 00:01:40,920
Max pulling leered has a pool size of two by two.

19
00:01:41,310 --> 00:01:49,050
That is the window of neurons in the previous layer will be of two and two two pixels out of these four

20
00:01:49,050 --> 00:01:55,970
pixels, whichever values maximum will be taken as the output value of the cell in max willingly.

21
00:01:58,380 --> 00:02:02,700
By default, this layer will have a straight off to this convolutional layer.

22
00:02:02,790 --> 00:02:07,160
We'll have a by default straight value one if you want to change these trade.

23
00:02:07,170 --> 00:02:13,530
Also, you can add additional barometer of straight is equal to two or three, whatever you want to

24
00:02:13,560 --> 00:02:20,200
set it to in the pulling layer, the default value status two.

25
00:02:21,150 --> 00:02:29,100
So this pulling layer will reduce the dimensions by two in both directions horizontally and vertically,

26
00:02:30,210 --> 00:02:37,050
which means that the output layer will have one fourth of the neurons as compared to the convolutional.

27
00:02:41,200 --> 00:02:43,150
So I separated this section.

28
00:02:43,390 --> 00:02:47,710
This is the convolutional section from our normal neural network.

29
00:02:48,670 --> 00:02:54,160
The output of this convolutional section is going into our normal neural network.

30
00:02:55,170 --> 00:02:56,460
So these are the next layers.

31
00:03:00,160 --> 00:03:06,430
You could have listed all the layers in one go only, but just to make it clear that this part is the

32
00:03:06,490 --> 00:03:07,510
convolutional part.

33
00:03:07,930 --> 00:03:11,920
And this is where we do normal neural network processing.

34
00:03:12,310 --> 00:03:13,900
I have separated these two.

35
00:03:15,790 --> 00:03:19,030
So the output of this layer will be three dimensional.

36
00:03:19,480 --> 00:03:22,450
We need to flatten it as a layer.

37
00:03:22,930 --> 00:03:24,670
So we use a flatten layer.

38
00:03:25,960 --> 00:03:33,700
The output of this flattened layer goes into a dense layer of 300 neurons with activation function relu.

39
00:03:35,350 --> 00:03:40,510
The output of these three under neutrons goes in to next to the layer of under neurons.

40
00:03:41,590 --> 00:03:43,510
These also have activation function below.

41
00:03:45,420 --> 00:03:53,650
Then the last layer, that is the output neuron layer has only 10 output neurons with activation function

42
00:03:53,680 --> 00:03:54,420
softmax.

43
00:03:57,340 --> 00:03:59,530
This part is exactly same.

44
00:03:59,980 --> 00:04:04,000
So this structure of the model is exactly same as we discussed last time.

45
00:04:07,690 --> 00:04:08,890
So let's run these two.

46
00:04:13,240 --> 00:04:14,890
Now, if you look at your model,

47
00:04:20,830 --> 00:04:22,900
we have created a sequential model.

48
00:04:23,950 --> 00:04:27,040
First layer is a convolutional to deliver.

49
00:04:31,530 --> 00:04:38,110
Its output ship is 26 by 26 input, the image was 28 by 28.

50
00:04:38,640 --> 00:04:42,290
But because by default, padding is set to valid.

51
00:04:42,720 --> 00:04:45,900
That is no additional padding is done.

52
00:04:46,500 --> 00:04:50,650
The additional boundry pixels were removed in the convolutional.

53
00:04:51,840 --> 00:04:56,160
So Vendig receptive field of convolutional layer was moving to the input layer.

54
00:04:57,360 --> 00:05:00,060
There were some pixels which could not be covered.

55
00:05:00,570 --> 00:05:02,010
So those were ignored.

56
00:05:02,250 --> 00:05:05,730
So one pixel from all of the boundaries were removed.

57
00:05:06,000 --> 00:05:11,160
That is why this ship is now 26 by 26 instead of 28 by 28.

58
00:05:13,380 --> 00:05:17,010
These 32 are defeater maps because we had 32 printers.

59
00:05:19,590 --> 00:05:26,370
Max, pulling Pullinger reduces these dimensions by two and we still have 32 feature maps.

60
00:05:27,660 --> 00:05:34,650
Then we have a flattened layer, then dense layer with 300 neurons, then another dense layer with hundred

61
00:05:34,650 --> 00:05:35,190
neurons.

62
00:05:35,700 --> 00:05:37,700
And lastly, the output layer retender.

63
00:05:37,740 --> 00:05:46,140
Don't the total number of parameters to be predicted is one point six million in the next lecture.

64
00:05:46,320 --> 00:05:54,660
When we remove the pooling layer or we try to add additional convolutional layer, we will see how this

65
00:05:54,660 --> 00:06:03,090
number of parameters changes and it will give us a hint of how pulling layer reduces the computational

66
00:06:03,210 --> 00:06:04,470
load on our system.
