liveBook · Manning

Evaluation dataset

As explained in Grokking AI Algorithms, Second Edition

A validation set is a held-out dataset used to assess a model during development without using it to fit the model's learned parameters.

An evaluation dataset is held-out data used to check how well a model generalizes while it is being developed. The model does not train on it, so its results are more meaningful than scores from the training data. section 11.34 section 8.12

Use the evaluation set as a practical feedback loop:

  • Set aside part of the available data before training; an illustrative split uses 80% for training and 20% for testing. section 8.10 section 8.12
  • Periodically run the developing model on held-out examples and calculate its loss or another performance measure. section 11.34 section 8.18
  • Compare training and evaluation trends: falling training loss alongside rising validation loss signals overfitting. section 11.34
  • Stop training when validation loss no longer improves; patience specifies how many unimproved evaluation cycles to wait. section 11.34

Diamonds: checking predictions

For a regression model, compare predicted diamond prices with actual prices from held-out carat examples and measure the difference, such as with R². For a decision tree, feed ten new diamond records through the tree: seven correct classifications give 70% accuracy, while the errors can be summarized with a confusion matrix. section 8.12 section 8.18

Figure 8.14 A regression line plotted with the data points
08_14

Plot held-out data points against the trained regression line to make prediction accuracy visible. section 8.12

How Grokking AI Algorithms, Second Edition covers it

How deep it goes
Explains held-out evaluation, loss trends, overfitting, early stopping, and patience without detailing implementation internals.
Examples
Uses diamond-price regression, diamond-cut classification, confusion matrices, validation loss, FID scores, and saved model checkpoints.
What it assumes
Assumes training data, model predictions, and performance measures such as accuracy or loss.
What you can do after
Diagnose overfitting and choose when to stop training using validation loss and patience.
How it connects
Connects training data, testing data, generalization, overfitting, validation loss, early stopping, and model evaluation metrics.

Also explained in

Compare how 27 books explain evaluation dataset →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Grokking AI Algorithms, Second Edition. The section links point to the parts of the book it draws on.