Learning curve · machine learning

On this page 7

A learning curve in machine learning is a plot that shows how a model’s performance on training and validation data changes as the amount of training data or training time grows. In model evaluation, it is one of the most direct tools for deciding whether a model suffers from high bias, high variance or a shortage of data, and therefore whether more data, more capacity or more regularization is the right next step.

The term here refers only to the diagnostic plot used to evaluate models. It is not the everyday sense of how quickly a person masters a skill, although the two ideas share the intuition that performance improves with experience.

How a learning curve is built

A learning curve is built by training the same model repeatedly on growing subsets of the training data and measuring a metric on each subset and on a fixed validation set. A typical run uses five to ten subset sizes, for example 10%, 20%, 40%, 70% and 100% of the available examples, often on a logarithmic spacing so that small sizes are well represented.

Two lines appear on the plot. The training score shows how well the model fits the data it saw, and the validation score shows how well it generalizes to unseen data. Because a single split can be noisy, careful practitioners repeat each point with cross-validation and draw the mean with a band of plus or minus one standard deviation.

The following table summarizes the elements of a standard learning curve and the choices that shape it.

ElementTypical choiceWhy it matters
Horizontal axisTraining examples or epochsDefines which question the plot answers
Vertical axisLoss, error rate, accuracy or F1 scoreMust match the business objective
Training lineScore on the fitted subsetReveals how well the model fits
Validation lineScore on held-out dataReveals generalization
Variance bandSpread across folds or seedsSeparates real trends from noise
Elements of a learning curve

Two kinds of learning curves

Practitioners use the term for two related but distinct plots, and confusing them leads to wrong conclusions. The sample-size learning curve varies the amount of training data, while the training-progress curve tracks the metric across epochs or optimizer steps for a single run.

PropertySample-size curveTraining-progress curve
Horizontal axisNumber of training examplesEpochs or optimization steps
Main questionWill more data helpWhen should training stop
Cost to produceSeveral full training runsOne run with periodic evaluation
Typical decisionCollect data or change the modelChoose a checkpoint or apply early stopping
Common inClassical machine learning and data planningDeep learning and large model training
Sample-size curves and training-progress curves

In deep learning, the training-progress version is often called a loss curve. It is closely tied to early stopping, which picks the checkpoint where validation loss reaches its minimum.

Reading the curve to diagnose bias and variance

The value of a learning curve lies in the gap and the slope of its two lines. A large gap between a high training score and a lower validation score signals overfitting, while two lines that converge at a poor score signal underfitting.

PatternDiagnosisRecommended action
Both lines low and close togetherHigh biasIncrease capacity or add features
High training score, low validation scoreHigh varianceAdd data, regularize or simplify
Validation line still rising at full dataData-limited modelCollecting more data is likely to pay off
Both lines flat and close at a good scoreConverged modelMore data adds little value
Validation loss rising after many epochsLate overfittingStop earlier or strengthen regularization
Learning curve patterns and what they mean

The slope at the right end is especially useful for planning. If the validation curve is still climbing steeply, doubling the data set is likely to improve results; if it has flattened, the bottleneck lies in the model, the features or the label quality.

Relationship to other evaluation tools

A learning curve complements rather than replaces single-number metrics. Precision, recall or an ROC curve describe how good a model is at one point, while a learning curve describes how that quality depends on data or time. It is related to the validation curve, which varies a single hyperparameter instead of data size, and to neural scaling laws, which fit power-law trends to learning curves across many model sizes.

  • Use a validation curve to tune regularization strength or tree depth.
  • Use a sample-size learning curve to decide whether labeling more data is worth the cost.
  • Use a training-progress curve to choose checkpoints and detect instability.
  • Use scaling-law fits when planning compute budgets for large models.

Pitfalls when using learning curves

Learning curves are easy to misread when the experimental setup is careless. The most damaging error is data leakage, where validation examples or near-duplicates appear in training subsets and make the validation line look unrealistically good.

  • Unstratified subsets can change the class balance at small sizes and distort the left end of the curve.
  • Single random seeds produce noisy points that look like trends; average several runs.
  • Changing hyperparameters between sizes mixes two effects; keep the configuration fixed or tune per size consistently.
  • Validation sets that differ from production data hide distribution shift, so the curve can promise gains that never appear in deployment.
  • Extrapolating far beyond observed sizes is risky, because curves often bend in ways a simple fit does not capture.

The simple explanation

A learning curve is a chart that shows how a computer model improves as it gets more practice. One line shows how well it does on examples it has already seen. The other line shows how it does on new examples it has never seen.

If both lines stay low, the model is too simple. If the first line is high and the second is low, the model is memorizing instead of learning. The space between the two lines tells you what to fix next.

How it is used in practice

A hospital analytics team builds a model that flags chest X-ray reports needing urgent review. They have 8,000 labeled reports, and labeling more costs radiologist time. Before asking for budget, they train the model on 1,000, 2,000, 4,000 and 8,000 reports with five-fold cross-validation at each size and plot the F1 score.

The training score sits near 0.95 throughout, while the validation score rises from 0.71 to 0.84 and is still climbing at 8,000 examples. The team concludes that the model is data-limited rather than capacity-limited. They request labels for another 6,000 reports, and the retrained model reaches a validation F1 of about 0.88, close to what the curve suggested.