1
00:00:00,410 --> 00:00:02,510
Before we go, let's have

2
00:00:02,510 --> 00:00:03,830
a quick look at plotting

3
00:00:03,830 --> 00:00:05,735
the learning history
of this model.

4
00:00:05,735 --> 00:00:08,930
The object has training accuracy
and loss values as

5
00:00:08,930 --> 00:00:11,960
well as validation accuracy
and validation loss values.

6
00:00:11,960 --> 00:00:14,270
So let's iterate over
these and plot them.

7
00:00:14,270 --> 00:00:15,860
Now, if you look closely,

8
00:00:15,860 --> 00:00:17,975
we didn't just call model.fit,

9
00:00:17,975 --> 00:00:20,570
we said history equals model.fit.

10
00:00:20,570 --> 00:00:21,820
So we now have

11
00:00:21,820 --> 00:00:24,705
a history object that
we can query for data.

12
00:00:24,705 --> 00:00:28,000
Here you can see I'm using
the same history object,

13
00:00:28,000 --> 00:00:30,625
and I'm calling its history
property passing at

14
00:00:30,625 --> 00:00:33,700
ACC which gets me
the model accuracy.

15
00:00:33,700 --> 00:00:35,290
When I run it and plot

16
00:00:35,290 --> 00:00:37,480
the training and
validation accuracy,

17
00:00:37,480 --> 00:00:40,690
we can see that my training
went towards one while

18
00:00:40,690 --> 00:00:44,860
my validation leveled out
into 0.7 to 0.75 range.

19
00:00:44,860 --> 00:00:47,515
That shows that
my model isn't bad,

20
00:00:47,515 --> 00:00:51,325
but I didn't really earn
anything after just two epochs.

21
00:00:51,325 --> 00:00:53,020
It fits the training data very

22
00:00:53,020 --> 00:00:56,005
well with the validation
data needed work.

23
00:00:56,005 --> 00:00:57,760
These results are borne out in

24
00:00:57,760 --> 00:01:00,715
the loss where we can see
that after two epochs,

25
00:01:00,715 --> 00:01:02,785
my training loss
went down nicely,

26
00:01:02,785 --> 00:01:05,025
but my validation loss climbed.

27
00:01:05,025 --> 00:01:06,800
So as it is, my model is

28
00:01:06,800 --> 00:01:10,634
about 75 percent accurate-ish
after two epochs,

29
00:01:10,634 --> 00:01:12,820
and I don't really need
to train any further.

30
00:01:12,820 --> 00:01:14,715
Remember also that we just

31
00:01:14,715 --> 00:01:16,730
used a subset of the full data.

32
00:01:16,730 --> 00:01:18,610
Using the entire dataset would

33
00:01:18,610 --> 00:01:20,575
likely yield better results.

34
00:01:20,575 --> 00:01:21,730
But before we do that,

35
00:01:21,730 --> 00:01:23,439
let's look at
a few other options,

36
00:01:23,439 --> 00:01:25,730
and we'll do that
in the next lesson.