Pick a concrete input and say what the equation should give before you read the math.
Foundation reference
Optimal Transport & Wasserstein Distance
Wasserstein distances measure how far probability mass must move to turn one distribution into another, so they respect the geometry of the space the data live in.
Study guide
Where to start
Why is the KL divergence infinite when two distributions have disjoint supports, while the Wasserstein distance stays finite and measures how far the mass must move?
How to study this pagePredict · Check · Generalize · Continue
Work through the math, then read the cited papers for the original argument.
Identify the part of the idea that survives a change of notation or model, so you can recognize it in another paper or system.
Use the prerequisites and related concepts at the end of the page to fill the next gap.
Why It Matters for Modern Models
- Wasserstein distances measure how far probability mass must move to turn one distribution into another, so they respect the geometry of the space the data live in.
- Arjovsky et al. (2017) argue that the Wasserstein-1 distance gives useful gradients even when the generated and real distributions do not overlap, which motivated the Wasserstein GAN.
- Flow matching with straight-line paths between independently paired noise and data samples does not learn the optimal transport map; pairing the samples with a minibatch optimal transport plan gives simpler flows that are faster to sample (Tong et al., 2024).
Questions to Think About
- How does the "earth mover" picture, with distributions as piles of earth, map onto couplings and costs, and where does the picture break down?
- Why does entropic regularization make optimal transport fast and differentiable, and what happens to the transport plan as ε grows?
Core Math
Optimal transport finds the cheapest way to move probability mass from a distribution to a distribution :
where is the set of joint distributions (couplings) with marginals and . A coupling says how much mass goes from to .
Kantorovich–Rubinstein duality (for ) turns the problem into a maximization over 1-Lipschitz functions :
This is the form the Wasserstein GAN critic approximates (Arjovsky et al., 2017).
Brenier's theorem. For the squared Euclidean cost () and an absolutely continuous , the optimal coupling is given by a map for some convex function .
Entropic regularization. Adding to the transport cost gives a strictly convex problem that the Sinkhorn algorithm solves by alternately rescaling rows and columns, which is fast on GPUs and differentiable (Cuturi, 2013).