5.3.2 · D3MLOps & Deployment

Worked examples — Experiment tracking and reproducibility

4,042 words18 min readBack to topic

Before any example, we earn the four objects the whole page rests on: the function , the per-stage dial , the whole-chain number , and the tolerance .

Figure — Experiment tracking and reproducibility

Figure s01 — the pipeline as a chain of links. Read it left to right: four labelled boxes (load, shuffle, train, eval) each carry their own dial . Cyan boxes are perfect links (); the amber box is the one weak link (). The formula printed above them multiplies the four dials into a single number, here. Concrete takeaway: the chain is exactly as strong as the product of its links, so one amber link drags the whole product down while three perfect links add nothing. Almost every example below is just "spot the amber link".


The scenario matrix

We enumerate every class of case this topic throws. Each later example is tagged with the cell it covers.

# Case class Meaning Example that covers it
C1 Perfect chain every Ex 1
C2 One weak link exactly one Ex 2
C3 Many weak links several compounding Ex 3
C4 Degenerate input a truly non-deterministic stage Ex 4
C5 Limiting behaviour long pipeline, each link near-perfect Ex 5
C6a Zero variables changed identical inputs, imperfect pipeline Ex 6
C6b Confounded comparison two variables changed at once Ex 7
C6c Controlled experiment exactly one variable changed Ex 8
C7 Silent data drift inputs to changed unnoticed Ex 9
C8 Tolerance vs. bit-identity metric within , not identical weights Ex 10
C9 Real-world word problem rebuild a 6-month-old model Ex 11
C10 Exam-style twist "improve cheapest" optimisation Ex 12

The "signs / quadrants" of this subject are the values a can take (, between and , exactly ) and how many variables changed in a comparison — the three cases (C6a), (the valid controlled experiment, C6c), and more than (C6b). We visit each.


The worked examples

Ex 1 — The perfect chain (cell C1)



Figure — Experiment tracking and reproducibility

Figure s02 — compounding, as a bar chart. Each of the four stages is a bar of height (two cyan perfect stages, two amber sub-unity ones), and the tall white bar on the right is the whole-pipeline value . The dashed amber line marks that : notice the white bar sits below both amber stage bars ( and ). This is the picture of "weak links compound, they do not average" — the product dives beneath the smallest factor, not toward the mean.


Ex 4 — A degenerate stage, (cell C4)


Ex 5 — Limiting behaviour: many near-perfect stages (cell C5)

Figure — Experiment tracking and reproducibility

Figure s03 — erosion curves . The horizontal axis is the number of stages ; each curve plots for a fixed per-stage (cyan , amber , white ). Every curve slides downhill as grows — the whole point is that no value of below stays flat. The amber dot marks at the dotted line: a "99% reliable" stage, chained 50 times, is barely a coin-flip better than even. This is why CI-CD for Machine Learning pipelines pin each stage hard.


Ex 6 — Zero variables changed: identical inputs, imperfect pipeline (cell C6a)


Ex 7 — Confounded comparison: more than one variable changed (cell C6b)


Ex 8 — Controlled experiment: exactly one variable changed (cell C6c)


Ex 9 — Silent data drift (cell C7)


Ex 10 — Tolerance, not bit-identity (cell C8)


Ex 11 — Real-world: rebuild a 6-month-old model (cell C9)


Ex 12 — Exam twist: improve the cheapest way (cell C10)


Active recall

Recall Predict, then reveal.

Which single value of makes no matter the other stages? ::: (a fully non-deterministic stage annihilates the product). If all stages have , why is not ? ::: They multiply: erodes toward as grows; for it is . Two runs share all five inputs of yet differ. Bug or not? ::: Not necessarily — fixed inputs do not fix the output if some stage has ; judge the gap against tolerance . What does the tolerance mean, and how do you choose it? ::: The largest metric difference you still call "reproduced"; set it to a gap that would not change any decision you make. A comparison changed both lr and seed. Why is it invalid? ::: Two variables changed, so the metric difference cannot be attributed to lr alone — the seed is a confounder. A comparison changed only lr (seed fixed) and . Verdict? ::: Valid controlled experiment and effect beats the noise floor — the lr change genuinely helped. Given and one fix, which stage do you fix? ::: The stage (the lowest ) — it lifts from to .