课程: TensorFlow 2.0: Working with Images

今天就学习课程吧!

今天就开通帐号,24,700 门业界名师课程任您挑!

Working with EarlyStopping

Working with EarlyStopping

- The early stopping callback object enables you to stop the training process before it reaches the final epoch. Usually you do this to save training time if the model isn't improving. So we track a certain metric, say the validation accuracy, and if this doesn't improve after a certain number of epochs the training will stop. Let's head over to our notebook. What's new here is that we set the patient's parameter as part of the early stopping callback. This means that if the validation accuracy does not improve within three epochs, the training stops. Now this time round, we're training with 15 epochs and you can see that since there wasn't an improvement in the validation accuracy over five epochs, our training has stopped at this point.

内容