But what the next step is to create architecture for our model, we will be using almost the same architecture.
We will be using sequential as they appear.
And we will be adding four on layer.
We will start with 32 filters.
Then 64 filters.
Then 128 filters.
Then again, 128 filters.
And after each of this con led, we will.
We are also playing with willingly.
And as always, the activation function is the RELU for all these layers.
And after that, this thing, we are also playing Grop Otilia.
So what this lawyer will do is it will deactivate 50 percent off neurons during each epoch.
It will randomly pick for people sent off our neurons and it pretty directly with them.
And we will be training model with the remaining 50 percent off neurons during each people.
So for each epoch, we are activating randomly 50 percent of our total neurons.
We are using Grabbled here because Rubbled is a very effective leader to avoid overfitting in our more
than.
So this is of a modern architecture.
Now, the next, the surplus to come by.
For lost function, we will be using binary cross entropy.
Since we have two different classes.
If you remember earlier in Emmis, we had 10 different classes and there we were using spots categorical
across entropy.
But here, since we have one the two classes, we are using Leonetti, Cross and Groppi for optimize
it.
We are using Oremus prop with learning rate of zero point zero zero one.
And since this is a classification problem, we are calculating accuracy metrics as well.
The next step is to create our modern.
Since we are taking our data from Katrina and Rita, we have to use for generator to fit our model.
So we'll be using model dot for gender to Dan Crane, gender to.
This dirty doesn't matter, which will continuously generate butat in the batches of 32 images.
And then here we are using Insteps but Epoch as hundred.
Earlier in our last model, we were using a bad size of 20 steps.
But Epoch as hungry because we only had to pose an immediate.
For training purposes.
But this time, since we are randomly generating images from this transformation, we can use more than
2000 images as well.
This time we are using a bed size of potato and steps, but epoch as hundred.
So overall, in each epoch we are feeding at all three thousand two hundred images.
The number of epochs this time is hundred.
And similarly, we will use validation generator to get the validation data.
Now, since we are running this four hundred a box, if you are using this system with less than 16
DGP of RAM and without any graphics card, it may take up to one and half to two or worse to create
this model.
That's what I have already train this model and I have the data off or one hundred epochs here.
You can see that our validation accuracy is increasing with each book and at their own ninety two hundred
book.
We are getting the validation accuracy between 80 to 84 percent and.
A training accuracy of it before a debate, but say.
So if you compare in our last model, we were getting training accuracy of our own 95 to 98 percent
and a significantly lower valuation accuracy of our own 79 percent.
In this model, we are getting almost same regulation and lower training accuracy from it before person.
So you can see that with what image processing and creating dummy images we have created or what fitting
in our modern.
After running this, you can save your model by model lot save method and lets us create this graph
to see how our valuation, accuracy and training accuracy are changing with each epoch.
So this orange and red lines are for accuracy.
This orange line is for training accuracy and red line is for validation accuracy.
You can see here that the validation accuracy is more than 80 percent as well as the training.
Accuracy is also more than 80 percent.
And both are moving together.
So there are no evidence of overfitting.
And then what model?
And this is still increasing.
So if you run it for, say, 40 or 50 more Reeboks, the validation accuracy may reach around 85, 86
percent as well.
So that's all for this review.
v.C that by augmenting our initial dataset, by applying sheer rotation, will shift, hide, shift
and flips.
We can treat overfitting fitting in our data and we can get a higher valuation accuracy from our model.
Thank you.