Skip to content
Home ↗
Slide 16 direction matters

Direction matters: coverage, not symmetric distance

Two directed nearest-neighbor distances answer different questions. Chamfer combines them; Wasserstein and Gaussian Fréchet compare distributions in other ways. Define each before asking which one predicts transfer.

S is the training-source bag and T the target-benchmark bag. A point is a feature vector: a 4-D BFV correspondence for motion, or an appearance embedding. The demo below uses 2-D points so the same definitions can be seen directly.

COVERAGE · TARGET → SOURCE

What does the target need that the source is missing?

d(T→S) = 1|T| t ∈ T mins ∈ S ‖t − s‖22

For each target point, find the nearest source example; square the Euclidean distance; then average over the target. A target mode without nearby source support makes this term large.

OFF-TARGET · SOURCE → TARGET

What does the source supply that the target does not use?

d(S→T) = 1|S| s ∈ S mint ∈ T ‖s − t‖22

Reverse the query and reference sets. Extra source modes can make this term large even when every target mode is covered. Whether that extra motion helps or hurts training is an empirical question.

These are distances, not percentages. Lower means closer. “Coverage” and “off-target” are names for the two directed discrepancies, not literal recall and precision scores. Nearest neighbors can be reused: many queries may choose the same reference point. Squaring happens before averaging.
CHAMFER · COMBINE THE TWO HALVES
C(S, T) = d(T→S) + d(S→T)

The paper uses the sum of the two mean squared nearest-neighbor terms. Swapping source and target leaves that sum unchanged, so Chamfer alone cannot tell missing target support from extra source support. Other conventions average the halves or use unsquared distances; the equations, slide and demo here all use the paper’s squared/sum convention.

Wasserstein-2: transport mass, rather than reuse neighbors
W22(S, T) = minπ ∈ Π(a, b)i,j πij ‖si − tj22

Assign masses ai and bj to the samples; for uniform empirical bags, these are 1/|S| and 1/|T|. A transport plan π must satisfy ∑jπij = ai and ∑iπij = bj. It moves all the mass with the least total squared cost. W₂ is the square root of that cost.

This constraint distinguishes transport from nearest-neighbor matching. If two datasets have the same point locations but different proportions at those locations, both Chamfer halves can be zero while W₂ remains positive. Like Chamfer, W₂ is symmetric and does not identify a source–target direction.

The paper uses sliced W₂

SW22(S, T) ≈ 1Kk=1…K W22kS, θkT)

Project the clouds onto unit directions θ, solve a one-dimensional transport problem along each direction, and average the squared costs. Take the square root for sliced W₂. This is a distinct projection-based distance, not an exact solution of full multidimensional W₂.

The demo uses 64 fixed, evenly spaced directions in 2-D and exact weighted quantile matching along each projection, including unequal point counts. The bar shows SW₂² to keep squared units with the other bars; the SW₂ value appears underneath. It illustrates the metric, rather than reproducing the research pipeline’s projection count or sampled quantile approximation. Sliced Wasserstein reference ↗

FID / Gaussian Fréchet: compare means and covariances
F(S, T) = ‖μS − μT22+ tr[ΣS + ΣT − 2(ΣS½ΣTΣS½)½]

Replace each feature distribution by a Gaussian with its mean μ and covariance Σ. The expression is the squared W₂ distance between those two Gaussian approximations; the matrix square root captures the covariance mismatch.

FID originally applies this formula to Inception image features. In the paper, the analogous comparison is applied in the chosen motion or appearance representation. Here, Gaussian Fréchet uses only the toy coordinates and their population covariances, without an image encoder. It is symmetric and retains only the first two moments: different multimodal shapes can have zero Fréchet distance if their means and covariances match. Original FID paper ↗

Read changes within a metric. These distances summarize different properties, so a smaller numerical bar does not make one metric a better transfer predictor. The following slides test prediction against trained models. This toy demonstrates geometry and symmetry; it cannot establish a training outcome.
Interactive · try it hereOpen standalone ↗
Direction Matters
Move the extra cluster with the plot or sliders. Coverage d(T→S) and off-target d(S→T) update live. Compare the two directed nearest-neighbor terms with Chamfer, Gaussian Fréchet distance and sliced Wasserstein. Swap source and target: the directed terms exchange values, while the symmetric distances stay fixed.
spread 0.22

What changes when the roles swap?

Bars use one shared scale in squared feature units. Lower means closer by that definition; sizes across metrics are not performance rankings.

Source (train) Target (benchmark) Coverage distance d(T→S): mean over target points of the squared distance to the nearest source point Off-target distance d(S→T): mean over source points of the squared distance to the nearest target point
This is a 2-D illustration using the paper’s squared nearest-neighbor definition and Chamfer sum. Each displayed point has equal mass within its dataset. Gaussian Fréchet uses the point clouds’ means and population covariances—the FID formula, without an Inception encoder. Sliced W₂² averages exact 1-D transport costs over 64 fixed projection directions; its square root is also shown. The paper reports sliced W₂, not full multidimensional W₂. These toy values are not research-result scores. Read the definitions and equations →