Two Gaussians,
one number.
Where FID gets its mathematics, before we ask whether it deserves our trust.
The number we are trying to explain
Location
Covariance
By the end of this lecture every symbol here should have a reason to be here.
Covariance describes spread and correlation, not arbitrary distribution shape.
FID does not compare images
No canonical pair
real image × generated image
Nothing says which generated image answers which real one.
What we have instead
Two sets, and a question about the sets.
P ↔ Q
We need a distance between distributions, not a matching between individual samples.
Same marginals. Different couplings.
P and Q say where X and Y live. They do not say how to pair them.
Wasserstein as a search
Π(P, Q) every joint distribution with marginals P and Q
‖X − Y‖² the transport cost
inf choose the cheapest admissible coupling
Why this is hard
General distributions
An entire joint density.
Infinite-dimensional optimisation.
Gaussians
Four objects, all finite.
Finite-dimensional structure.
This lecture works because Gaussians are unusually cooperative.
Start in one dimension
Couple them through the same standard normal:
Two things are being measured
mean mismatch is location
variance mismatch is spread
Now go to d dimensions
In multiple dimensions, spread is no longer one number. It is scale, orientation and correlation at once.
The derivation board
Everything is known except the cross-covariance C.
The problem has collapsed
Joint covariance
The block must stay positive semi-definite.
What is left to do
- minimise cost
- maximise Tr(C)
- subject to a valid joint covariance
The infinite-dimensional coupling problem is now a structured matrix problem.
The Gaussian solution
Sanity check, in one dimension or whenever the covariances commute, the covariance term collapses:
FID adds an instrument
The Gaussian distance is the mathematics. Everything before it is a measurement decision.
Why people believed the number
Worse images, larger FID.
In the original experiments the score rose monotonically as each of these disturbances grew stronger.
Schematic trends, not measured values · original experiment identified in speaker notes
Four assumptions enter the number
1 · Representation
Inception-v3 decides which visual differences are visible at all.
→ week 03
2 · Compression
A high-dimensional feature distribution becomes a mean and a covariance.
→ week 03 / 07
3 · Gaussianisation
Only the first two moments survive the fit.
→ week 07
4 · Estimation
Finite samples estimate those moments.
→ week 05
The formula is exact for Gaussians. FID is an engineered pipeline built around that formula.
Which model is closer?
Reference R, candidates A and B, scored by the closed form rather than by sampling.
A / mean shift
2,048 × 0.05²
B / wider spread
2,048 × (√1.1 − 1)²
B wins. We will spend the rest of the course asking whether that ranking survives the measurement pipeline.
The distance is clean.
The instrument is not.
Mathematics
A closed form. Geometrically meaningful. Exact for Gaussians.
Instrument
images → preprocessing → encoder → finite sample → estimated moments → Gaussian fit → one scalar
Next: what exactly is Inception measuring?