Regularization

19 min read

A big network can memorise its training data and then fail on new data. Regularization is a set of tricks that stop this. In this lesson you learn weight decay, dropout and early stopping, and you see how to choose between them.

New words

Overfitting
The model does well on training data but badly on new data.
Regularization
Any trick that keeps a model from memorising the training data.
Weight decay (L2)
A small penalty added to the loss for large weights.
Dropout
Switching off random neurons during training.
Early stopping
Stopping training when validation loss starts to rise.
Validation set
Data kept aside to check the model while you train.
Data augmentation
Making new training examples by changing the old ones a little.

What you will learn

  1. Why does a big network memorise?
  2. What is weight decay (L2)?
  3. What is dropout?
  4. What is early stopping?
  5. Does it help on real data? A curve-fitting test
  6. Try it: the training curves
  7. How do you choose what to use?
  8. Common mistakes
  9. Explain it to a friend
  10. Key takeaways

10 quiz questions at the end.

Start this lesson

The full lesson, with interactive demos and the quiz, opens after you sign in with Google. It is free.

All lessons · Back to the roadmap