SLOP8412 / Image lab / Prototype 02
Same photograph.
A different measurement.
Changing how images are encoded can change FID without changing what they depict. Put compressed pixels beside their originals, then measure what the feature extractor sees.
Bring your own images
Select 2–8 images together
Choose JPEG or PNG files in one selection. A single image is not enough to estimate the sample covariance.
In the file picker, use Ctrl-click (Windows), Command-click (Mac), or Shift-click to select multiple files. These form the reference set; candidate copies are created automatically. Nothing is sent to a server.
Ready for one selection of 2–8 images.
Limits: 5 MB per file, 20 MB total; 4096 pixels per side, 16 MP per image, 32 MP total. Static JPEG/PNG pixels only. Transparency is composited on white. Originals are not modified or saved.
Using the supplied eight-crop example.
Can compression move FID even when the photographed subject has not changed?
Pairing is by displayed position. Shuffling changes the pairing, not the collection or its FID. Measure once, then shuffle without rerunning Inception.
Reference
01 / 8 crops







Eight fixed crops of one photograph. The same inputs are used every run.
Candidate
02 / matched crops







JPEG quality 10, decoded and saved as PNG. Compression changes the pixels; saving as PNG does not undo it.
First run downloads an 87 MB model + approximately 11 MB runtime. Runs on your device, without uploads or an inference server. Desktop recommended. Allow up to three minutes.
Ready. No model is loaded until you choose Measure.
The measured difference
03 / live browser resultMean paired feature distance / not FID
Average squared feature distance between reference i and the candidate displayed at position i. Summed across all 2,048 coordinates, then averaged across pairs. Unlike FID, this depends on the pairing; it is not a perceptual-quality verdict.
What exactly is being measured?
Each image becomes a vector of 2,048 Inception features. We estimate a mean and a full sample covariance for each set, with divisor n − 1. The score is the squared Gaussian distance between those estimated moments.
- Read the supplied 128 × 128 RGB pixels as values between 0 and 1.
- The FID-specific Inception model resizes to 299 × 299, normalises to [−1, 1], and extracts pool3 features.
- Compare both means and covariances. All 2,048 coordinates are retained; correlations are not discarded.
With n images the sample covariance has rank at most n − 1: seven for the eight-image demo. We use an exact sample-factor identity to evaluate its cross term through a small matrix, without reducing the feature space. Floating-point rounding still applies.
X = (reference_features - reference_mean) / sqrt(n_reference - 1)
Y = (candidate_features - candidate_mean) / sqrt(n_candidate - 1)
mean_term = sum((reference_mean - candidate_mean) ** 2)
covariance_term = sum(X ** 2) + sum(Y ** 2)
- 2 * sum(singular_values(X @ Y.T))
FID = mean_term + covariance_termThis calculation uses freshly extracted browser features, not a stored score. Shuffling reuses those features: the collection-level FID stays fixed, while the paired readout is recalculated. The record includes processing settings, candidate order and feature vectors in original order. Local filenames and original files are not exported, but the feature vectors are derived from your images; treat the record as private.
Carry the observation back to the bench
The Week 4 measurement contract must specify preprocessing as well as the model. The Week 5 lecture explains why a small empirical score is not the population quantity. Record which pixels changed, what stayed fixed, and what you cannot conclude in your measurement log.
Image: NASA / Eileen Collins, via scikit-image (public domain). Deterministic crops and JPEG fixtures generated by this project. Encoder: pytorch-fid, converted to ONNX; model redistribution licence. No images are uploaded. Downloaded assets may remain in your browser cache; results last until you leave or refresh unless you export them.