Gradient LabStart the lesson

Lessons › Chapter 14: ML in practice

Experiment tracking

experiment tracking records, for every run, the settings, the data version, the results and the saved model. Tools do this automatically with a couple of lines of code.

Watch it move. This lesson is interactive on Gradient Lab: every step is an animated scene you can replay.

Start the interactive lesson

Step by step

Story

Which run was it?

Nobody can remember which settings produced last month’s best fraud model.

Problem

Which run was the good one?

After a week of experiments you have dozens of models. Which settings gave 88%? Which data version? Without notes, nobody remembers, and the best model can’t be rebuilt.

Concept

Log every run

experiment tracking records, for every run, the settings, the data version, the results and the saved model. Tools do this automatically with a couple of lines of code.

Key idea

Compare side by side

Now you can line runs up and see what changed. Run 4 wins at 88%, and the log says exactly why: lower learning rate, data version 12.

Real life

In real life: a lab notebook

Scientists write down every experiment so results can be checked and repeated. ML teams do the same with tracking tools, and in regulated areas like medicine or banking, being able to show how a model was built is often a requirement.

Quick check: What should you record for every training run?

You need all three to compare runs fairly and to reproduce the winner.

Pseudocode

for each training run:
    log settings: learning rate, layers, data version
    log results:  accuracy, loss curve, training time
    save the model file with an ID

compare runs side by side → pick the best and know why

Key terms

experiment tracking
Recording the settings, data and results of every training run so you can compare and reproduce them.