To train the model.
What we will do is we will.
It's quite simple.
Just let me just take some space here.
And it will be modal equals.
Dee dee dee dee dee.
Sorry.
Will deep dot model.
Model.
And we will pass two things.
The first one is the data we have, which is this one.
And the second thing we will pass is the neural network.
So network.
And that's it.
This is the model.
Now how to train it.
We will do also the.
Model dot.
Compile.
And we're using Adam.
With with a learning rate of.
E to the power minus three.
And now we will compile it.
And we will start the training soon.
What we will do or let me start the training and then I will explain more history.
His story.
And train.
State equals model dot train.
Iterations equals 15.
Thousand.
And reasons.
Yeah.
Loss.
His two seems okay and shift enter.
So now the model is actually training and, um.
We can see.
It's like.
But I think I wanted to print this thing.
Okay, Just let me.
Stop it.
Think it didn't run the whole.
Let's run it from the beginning.
Why didn't he print these things?
I think it we didn't shift into it.
Yeah.
Okay.
Now we can see them.
We didn't.
We wrote them, but we didn't shift enter.
We didn't put them inside the, the, the ram didn't upload it so input or the actually the, the whole
thing.
Yeah.
Mainly the ram.
So the input we have this is the actual input that goes just a little bit.
We talk about this one the a.
In this issue how to change the lambda function, because I think it's a little bit confusing.
So we talked about we have an input array and we need to see the shape.
The input array is simply going to be the boundary point or in the in case of initial condition, it
will be the initial condition points and it will be given in many different time steps, of course.
So input array will be 80 to 80 rows and two columns because we have.
This one, which is basically zero and the time.
And here.
What if we do 0 to 1?
It will print it this way.
1001111 this way.
And if we change this to.
Well, we put it like if we didn't put 0 to 1, what will happen is like.
If we put it this way, the shape will be only 80 and it will look like this array, which is this is
not what we want.
So we have to be careful about the the values that we need to consider.
Anyway, it will continue to train and he passed two times, one for every boundary condition.
So he passed first time and he passed second time.
This is why he printed two times.
And basically this is finished the training itself.
The next step is going to be.
Well, basically the.
A the that we need to further improve the accuracy.
So model dot compile.
Compile.
And we will use a slash bfgs.
A B method, which is a method.
It's a limited memory.
Something it's it's it's related to.
It will give us a good accuracy in, in in kind of limited memory.
So we can of course, we can search about this, how it works more, but mainly we use it in pens for
giving getting a better accuracy.
It's not like Adam will not work.
It will work.
But this is a common practice to use this one.
So model again train we need now we we we train again the model, but this time we will not define how
many iterations it will until it will converge and then shift enter.
So again, he's took the thing and he will now start the training.
A after it will finish it.
Hopefully in the next class we will see how these models, the results generated by this model and we
will explain what's happening in these results.
So see you in next class.