Pro
Pro lesson

Overfitting

Why a model that aces its homework can still fail the exam.

This one’s part of How Models Learn Pro — every lesson, every interactive, and new ones as they land. About 9 minutes.

Already Pro? Sign in and you’ll go straight in.

Inside “Overfitting”

What you’ll learn

  1. A pattern, seen through noise
  2. Curves that can bend
  3. The test set tells the truth
  4. Too simple, too flexible, just right
  5. More data calms the wiggles
  6. Regularisation: a penalty for wiggling

Key terms

Noise
Random variation in measurements that is not part of the underlying pattern, like the day-to-day weather on top of the seasons.
Polynomial
A curve built from powers of x, such as a + bx + cx². Its degree is the highest power used.
Training error
How far a model’s predictions are from the examples it was fitted to.
Test error
How far a model’s predictions are from held-out examples it never saw during fitting.
Underfitting
When a model is too simple to capture the pattern, so it does poorly even on its training data.
Overfitting
When a model fits the noise in its training data, doing well there but badly on new data.
Regularisation
A penalty added during training that discourages overly complex models, such as large coefficients.

Sources