Optimal transport is rarely evaluated on population measures directly. In
machine learning and statistics, the inputs are usually empirical laws,
histograms, simulated particles or minibatches, and the central question is
therefore no longer only how to compute OT, but how OT behaves as a random
estimator. This chapter studies this statistical layer: qualitative consistency
of empirical measures, non-asymptotic sample-complexity rates, and asymptotic
bias--variance decompositions for exact and regularized transport costs.
This statistical convergence is conceptually different from the algorithmic
convergence studied in the previous chapter. There the marginals and the
temperature were fixed and one asked how Sinkhorn iterates approach a
regularized optimizer. Here the number of samples grows, the empirical
measures themselves move, and the regularization parameter may either remain
fixed or be sent to zero. The resulting picture explains why exact OT is
statistically expensive in high intrinsic dimension, why fixed-temperature
Sinkhorn has smoother parametric fluctuations, and why approximating exact OT
with entropy always involves a bias--variance tradeoff.
from pathlib import Path
import sys
from IPython.display import Image as DisplayImage
from IPython.display import display
here = Path.cwd()
myst_dir = None
for candidate in [here, here.parent, here / "myst", here.parent / "myst", here.parent.parent / "myst"]:
if (candidate / "ot4ml_web.py").exists():
myst_dir = candidate.resolve()
sys.path.insert(0, str(myst_dir))
break
if myst_dir is None:
raise RuntimeError("Could not locate myst/ot4ml_web.py")
repo_root = myst_dir.parent
thumbnails = repo_root / "notebooks-figures" / "thumbnails"
def show_book_figure(name, width=760):
display(DisplayImage(filename=str(thumbnails / f"{name}.png"), width=width))
Before discussing sample complexity, it is useful to separate consistency from
rates. If X1,…,Xn are i.i.d. samples with common law α, the
associated empirical measure is the random probability measure
The ordinary law of large numbers says that empirical averages converge to
expectations. In measure language this means that α^n converges
weakly toward α, because testing α^n against a bounded
continuous function φ gives the sample average
n−1∑iφ(Xi). Wasserstein distances strengthen this statement by
also recording moment convergence. Thus, if α has a finite p-th
moment, the empirical law converges to α in Wp, almost surely and
in p-th mean in the sense that
EWp(α^n,α)p→0. This is the qualitative consistency
statement behind empirical OT plug-in estimators: empirical transport
distances converge to their population counterparts once the sampled laws
themselves converge in Wasserstein distance. It says nothing yet about the
speed, which is the topic of Sample Complexity.
Proof
Fix a reference point x0∈X, and write r(x)=d(x,x0). Since X is
Polish, the weak topology on P(X) admits a countable
convergence-determining class (φk)k≥1⊂Cb(X). For each
fixed k, the strong law of large numbers gives
almost surely. Intersecting these probability-one events over the countable set
of indices gives convergence against every φk, hence weak convergence
α^n⇀α.
The moment condition α∈Pp(X) means ∫rpdα<+∞.
Applying the strong law again to r(X1)p gives
almost surely. Weak convergence plus convergence of p-th moments is
equivalent to Wp convergence on Pp(X), so
Wp(α^n,α)→0 almost surely.
For convergence in expectation, set An=∫rpdα^n and
M=∫rpdα. The triangle inequality through the Dirac mass
δx0, followed by (a+b)p≤2p−1(ap+bp), gives
The family (An)n is uniformly integrable. By the de la Vallee--Poussin
criterion, choose a convex superlinear function Ψ such that
EΨ(r(X1)p)<+∞; Jensen’s inequality gives
The previous proposition is a law-of-large-numbers statement: a random
empirical measure converges to the law that generated it. The central limit
theorem describes a different, fluctuation-scale limit. As recalled in Remark
Remark: Central limit theorem, if (Xi)i≥1 are centered i.i.d. random vectors with
identity covariance, the law of n−1/2∑iXi converges weakly toward a
Gaussian. Equivalently, if α is the common law of the Xi, this law is
the rescaled convolution (D1/n)♯α∗n. Wasserstein
distances make this qualitative convergence quantitative. The next result is
a W1 form of the Berry--Esseen theorem: it controls the error uniformly
over all 1-Lipschitz test functions. The qualitative Bernoulli example was
visualized earlier in Figure Div.
For each such h, solve Stein’s equation
fh′(x)−xfh(x)=h(x)−Eh(G). Its solution satisfies
∥fh′∥∞+∥fh′′∥∞≤C. Writing
Sn(i)=Sn−Xi/n, independence and EXi=0 give
Taylor’s formula with integral remainder and EXi2=1 show that
this differs from n−1∑iEfh′(Sn(i)) by at most
CE∣X1∣3/n. The Lipschitz bound on fh′ replaces this
average by Efh′(Sn) at the same order. Stein’s identity and the
duality formula then prove the claim
Berry, 1941Esseen, 1942Chen et al., 2011Bobkov, 2018Rio, 2011.
The universal n−1/2 bound is sharp over broad classes of input laws, but
it need not describe the asymptotic behavior of a fixed law. For symmetric
inputs, the smooth skewness correction vanishes. What replaces it depends on
whether the law is lattice-valued or has a density.
Proof
Write Fn for the CDF of αn, and Φ and φ for the
standard Gaussian CDF and density. With
ψ(u)=21−{u}, the integrated lattice Edgeworth expansion gives
For completeness, prove this first for compactly supported step functions,
where it is a Riemann sum over periods, and conclude by L1 approximation
of φ.
The absence of a lattice correction reveals the next smooth Edgeworth term.
A density automatically satisfies Cramér’s non-lattice condition because its
characteristic function vanishes at infinity.
Proof
The non-lattice Edgeworth expansion through order n−1 has an
n−1/2 term proportional to the third cumulant, and n−1 terms
proportional to the fourth cumulant and to the square of the third one.
Symmetry makes the third cumulant vanish and gives
These two results explain the different behaviors in Figure
Div. For the symmetric Bernoulli law, the
maximal span is h=2, hence
W1(αn,γ)=1/(2n)+o(n−1/2). The density proposition
cannot be used: this law has no density and its characteristic function is
E[eitX]=cost, whose modulus returns to one at arbitrarily large
frequencies. Thus symmetry removes the smooth skewness term but not the
lattice sawtooth. Conversely, X∼Unif[−3,3] has
a density, characteristic function sin(3t)/(3t)→0, and
κ4=−6/5. Since
so that α1=α0. For Bernoulli input, the distance is evaluated by
the exact quantile formula and atom masses are divided by the current lattice
spacing in the density display. For continuous-uniform input, the normalized
convolution is an affine image of the Irwin--Hall distribution and Vallender’s
CDF formula is integrated numerically. Neither computation uses Monte Carlo
sampling.
Sharp lattice and density central-limit asymptotics in W1. The two
left panels show α0, α2, and α6 for symmetric
Bernoulli and continuous-uniform inputs; the gray curve is the standard
Gaussian density. The right panel compares the exact numerical distances
(solid) with the sharp equivalents in (17)
(dashed). The Bernoulli curve follows its lattice rate 1/(2n), while
the continuous-uniform curve approaches
(1+4e−3/2)/(102πn).
The fluctuation object used by statistical OT is the empirical law itself,
not only a normalized sum in Euclidean space. There is no canonical Gaussian
law on an unrestricted infinite-dimensional space of signed measures, so the
precise finite-dimensional statement is made through test functions. Uniform
convergence over an infinite class requires a Donsker condition
Vaart & Wellner, 1996.
Proof
Apply the multivariate central limit theorem to the centered i.i.d. vectors
(φr(Xi)−∫φrdα)r=1q.
This linear CLT is the input to the delta-method arguments in
Bias and Variance of OT. Exact OT may have only directional derivatives,
whereas fixed-temperature entropic OT is smooth in the relative interiors of
finite probability simplices.
This section compares four statistical regimes. Exact OT resolves geometry at
all scales and pays rates controlled by the intrinsic dimension. MMD replaces
transport by a kernel mean embedding and has a parametric Monte-Carlo rate for
bounded kernels. Fixed-temperature Sinkhorn divergences smooth the dual
potentials and also recover parametric fluctuations, at the price of
regularization bias. Sliced Wasserstein inherits one-dimensional empirical
rates through its projected laws.
The previous section proves qualitative convergence of empirical laws. The
sample-complexity question is how fast this convergence happens. The sample
complexity of unregularized OT suffers from the curse of
dimensionality, but the relevant dimension is geometric. If the distributions
are supported on a regular
lower-dimensional set, for instance a d′-dimensional submanifold of
Rd, the empirical rate is governed by d′ rather than by the ambient
dimension d. In the high-dimensional regime for Wp, namely
d′>2p, this gives the characteristic rate n−1/d′. Exact OT is therefore
dimension-adaptive: it sees the intrinsic dimension of the data support
through its covering numbers Dudley, 1969Weed & Bach, 2019.
Related two-sample-testing viewpoints are developed in
Ramdas et al., 2017.
Figure Div gives a numerical overview: exact OT exhibits dimension-dependent empirical fluctuations, whereas MMD and fixed-temperature Sinkhorn divergences lie much closer to the parametric n−1/2 scale.
Empirical fluctuations in dimensions three and six. For each sample size
n, two independent empirical measures are drawn from the same standard
Gaussian law. Exact OT follows a slower dimension-dependent scale, while MMD
and the fixed-ϵ Sinkhorn divergence behave closer to the parametric
n−1/2 guide. This is a statistical illustration, not a solver benchmark.
Interactive panel. Vary dimension, sample budget and temperature to compare the curse-of-dimensionality OT guide with the parametric fluctuation and bias floor of entropic OT.
Proof Sketch
Match the common mass inside the finest cells, then recursively match the
remaining common mass inside each parent cell. Mass first matched at scale
j moves by at most d,2−j, and its total amount is bounded by
the sum of the child-cell imbalances. The residual at the finest unresolved
scale has mass at most one and moves by at most d,2−J.
Proof
The triangle inequality reduces the result to
EW1(α^N,α). For each dyadic cell Q,
The high-dimensional rate is not merely a defect of the empirical plug-in
estimator. A hypercube of localized density perturbations gives the following
distribution-estimation obstruction
Singh & Póczos, 2018Weed & Bach, 2019Chewi et al., 2025.
Proof Sketch
Partition the cube into M=md cells of width h=1/m, and put an
independent signed, zero-mean bump of fixed small amplitude in each cell.
Kantorovich--Rubinstein duality gives a separation of order
hd+1 per differing sign. Neighboring experiments have one-sample KL
divergence O(hd), so choosing M≍N keeps their N-sample total
variation bounded away from one. Assouad’s lemma then gives
Mhd+1=h≍N−1/d.
Smooth densities permit a better estimator: first remove fine empirical
oscillations with a wavelet or kernel smoother, then compute OT between the
smoothed laws Niles-Weed & Berthet, 2022.
Proof Sketch
At wavelet scale J, the B1,1−1 approximation bias is
O(2−J(s+1)) and the stochastic term is
O(N−1/22J(d/2−1)). Since W1 is controlled by this negative
Besov norm for densities bounded away from zero, balancing the two terms with
2J≍N1/(d+2s) gives the rate. Projection onto nonnegative
unit-mass densities preserves its order.
This gain is statistical rather than automatically computational: a grid at
bandwidth h has O(h−d) degrees of freedom, so direct smoothing remains
expensive in high dimension. Sum-of-squares relaxations offer theoretical
dimension-free exponents but are still costly in practice
Vacher et al., 2021.
Entropic regularization keeps the transport geometry while smoothing the dual
potentials. The sharp fixed-temperature statement below has polynomial, rather
than exponential, dependence on the inverse temperature
Genevay et al., 2019Mena & Niles-Weed, 2019.
Proof Sketch
Dual optimality bounds a one-marginal perturbation by the empirical process
indexed by normalized entropic potentials. Mena--Niles-Weed prove polynomial
local Hölder bounds for these potentials under a common subgaussian proxy.
Their covering numbers have a finite Dudley integral, hence the empirical
process is O(n−1/2) with constant Cd(1+σqd) at
ϵ=1. The rescaling x↦x/ϵ gives the displayed
Λd,σ(ϵ). Perturbing both marginals and applying the
same estimate to the cross and two self terms yields the debiased result.
The preceding estimates concern transport values. For map estimation, one
solves the empirical dual problem for potentials
(fn,mϵ,gn,mϵ)∈Rn×Rm, with
ϵ=0 denoting the unregularized Kantorovich problem, and then uses the
soft c-transform as an out-of-sample extrapolator.
For the quadratic cost c2(x,y)=∥x−y∥2/2, let
Pn,mϵ=(Pijϵ) be the empirical entropic coupling and let
gn,mϵ be the target-side dual potential. Define
Equivalently, subtracting the quadratic marginal terms turns c2 into the
bilinear cost cip(x,y)=−⟨x,y⟩. With the sign convention
used here, the associated soft convex potential is
which is the barycentric projection of the entropic plan. At ϵ=0,
the hard c-transform is generally nondifferentiable: away from Laguerre
boundaries its gradient selects one target site, whereas the barycentric
projection of an optimal unregularized plan may average several target sites
when a row splits. The consistency statement is therefore formulated directly
for barycentric projections. It uses uniform empirical weights; deterministic
nonuniform weights require the corresponding entropy bound.
Proof Sketch
Compare the entropic minimizer with an unregularized empirical optimal plan.
On a uniform n×m grid, this relative entropy is the mutual information
of two uniform indices and is at most min{logn,logm}. Thus the entropic
coupling has asymptotically optimal quadratic cost when
ϵlog(min{n,m})→0. Any weak limit is therefore an optimal population
plan, hence the Brenier graph (Id,T)#α. Jensen’s
inequality applied to each conditional law reduces the claim to the convergence
of ∬∥y−T(x)∥2dPn,mϵ(x,y). This last convergence is
not a continuity tautology, because the Brenier map is only defined
α-a.e. At every differentiability point of ϕ, the subdifferential
is the singleton {∇ϕ(x)}; compactness of the target bounds the
selected subgradients, and the closed-graph property of the subdifferential
then gives continuity of any selected subgradient there. Since convex functions
are differentiable Lebesgue-a.e. and α is absolutely continuous, the
portmanteau theorem for bounded test functions continuous almost everywhere
under the limiting measure gives the desired limit.
Quantitative map rates require stronger stability assumptions on Brenier
potentials. For unregularized map estimation, Hütter--Rigollet,
Deb--Ghosal--Sen, and Manole--Balakrishnan--Niles-Weed--Wasserman obtain,
under smoothness and curvature assumptions, squared L2(α) risk of
order
with sˉ=s∧3Pooladian & Niles-Weed, 2021. The first term
is the statistical fluctuation of the entropic map, while the last two terms
are regularization-bias terms. Thus fixed ϵ gives a parametric
empirical fluctuation for the regularized map, whereas
ϵ≃n−1/(d+sˉ+1) gives a convergent estimator of the
Brenier map. The unregularized case can achieve sharper minimax rates when
combined with enough smooth extension machinery; the regularized estimator is
instead directly Sinkhorn-computable.
The interactive demo below is only a scaling guide: change the dimension to see the
exact-OT exponent flatten, and change ϵ to move the Sinkhorn bias
floor against its parametric fluctuation term.
Interactive panel. This exploratory panel is a scaling guide. Use dimension, sample size, and epsilon to compare statistical fluctuation with regularization bias.
The construction is studied in Sliced Wasserstein Distances. Statistically,
it inherits one-dimensional empirical rates rather than ambient-dimensional
matching rates Nadjahi et al., 2019Nadjahi et al., 2020Manole et al., 2022.
Proof
The triangle inequality reduces the claim to two one-sample sliced distances.
Jensen’s inequality moves expectation inside the spherical integral, after
which the assumed projected bounds apply. For p=1, use the
Dvoretzky--Kiefer--Wolfowitz inequality and
W1=∫∣Fα^n−Fα∣. For p=2, use the
one-dimensional J2 quantile-process estimate
Bobkov & Ledoux, 2019.
The previous section answered a coarse but essential question: how many samples
are needed before an empirical OT quantity is accurate, typically up to
universal constants. We now ask for a finer statistical description. Rather
than only estimating the size of the error, we seek the first expansion of the
plug-in estimator. Given empirical laws α^n and β^m, and
a scalar OT value V, this expansion separates the leading statistical bias
for values such as V(α,β)=Wpp(α,β),
V(α,β)=Lc(α,β), or their entropic analogues. This
goes beyond Proposition Proposition: Finite-Dimensional Empirical-Process CLT: the empirical
fluctuation is now pushed through a nonlinear, often nonsmooth, transport
value. The resulting law is governed by local differentiability and by the
geometry of the optimal dual face.
The shape of the limit depends sharply on the analytic regularity of the
transport value. For exact OT on a finite or countable space, the map from
empirical weights to optimal cost is convex and piecewise affine. Sommerfeld
and Munk Sommerfeld & Munk, 2018, and the countable-space extensions
of Tameling--Sommerfeld--Munk
Tameling et al., 2019, show that the natural
limit is a directional delta-method limit: often a support function of a
Gaussian process over an optimal dual face, rather than a Gaussian random
variable. For Euclidean costs, del Barrio--Loubes and collaborators obtain
central-limit theorems for empirical transportation costs under regularity and
uniqueness assumptions on the Kantorovich potentials
Barrio & Loubes, 2019Barrio et al., 2021.
Entropic regularization makes the problem smoother. For fixed ϵ>0,
the value is differentiable with respect to the marginals, and the limiting
variance is read directly from the entropic dual potentials. This is the point
of view developed by
Bigot--Cazelles--Papadakis, Klatt--Tameling--Munk, Hundrieser--Klatt--Munk, and
Mena--Niles-Weed
Bigot et al., 2019Klatt et al., 2020Hundrieser et al., 2021Mena & Niles-Weed, 2019.
More recent results clarify weak limits beyond smooth costs and second-order
null limits for Sinkhorn divergences
González-Sanz & Hundrieser, 2023Goldfeld et al., 2024. These asymptotic
statements do not replace the dimension-dependent bounds of
Sample Complexity; they explain what the leading random object is,
what constants appear, and where the bias comes from.
is elementary, but in OT it is genuinely diagnostic because the two terms may
live on different scales. For the self-distance
V(α^n,α)=Wpp(α^n,α), the population value
is zero and the deterministic bias
EWpp(α^n,α) is the leading term. On a regular
d′-dimensional support, the high-dimensional matching scale is n−p/d′
when d′>2p, with a critical logarithmic correction when d′=2p. Below this
threshold the rate is controlled by empirical-process fluctuations and can be
faster; in one dimension, smooth positive densities give the familiar
quantile-process asymptotics for Wpp, of order n−p/2 for p>1,
and in particular n−1 for W22. Thus p/d′ is the
high-dimensional matching exponent, not a universal rate formula
Dudley, 1969Fournier & Guillin, 2015Weed & Bach, 2019. By contrast, when
V(α,β) is nonzero and the OT value is differentiable at
(α,β), the centered fluctuation is often governed by an ordinary
n−1/2 central limit theorem. A ``slow OT statistic’’ can therefore have
three distinct causes: a large empirical bias, a nonsmooth directional limit,
or a regularization bias Lcϵ(α,β)−Lc(α,β) that
still has to be removed.
The dual formulation writes LC(⋅,b) as the supremum, over the feasible
polyhedron fi+gj≤Cij, of the affine functions
a↦⟨f,a⟩+⟨g,b⟩. Its directional derivative at a, in any
tangent direction h with
⟨1,h⟩=0, is therefore
which is the finite-dimensional form of Danskin’s theorem already used in
Proposition: First variations of unregularized OT. The directional delta method
gives the displayed distributional limit. After fixing a gauge, the relevant
dual face is bounded, so the support functions above have at most linear
growth in the multinomial fluctuation. Uniform integrability then yields
convergence of the first two moments, hence the bias and variance
statements. If f⋆ is unique modulo constants, the support function
reduces to the linear form ⟨f⋆,Ga⟩. Its expectation is zero, and
the covariance of Ga gives exactly the displayed variance.
The same argument gives the independent two-sample limit. If
N/(N+M)→λ∈(0,1), then, with
rN,M=NM/(N+M),
where Ga and Gb are independent multinomial Gaussian limits. When both
dual potentials are unique, the first-order bias is negligible and the
asymptotic variance of the unscaled estimator is
If the optimal face contains several dual potentials, the limit is the
supremum of a Gaussian process over that face and need not itself be Gaussian.
The leading bias is then the expectation of this supremum divided by the
square-root sample size. This nonsmoothness is the basic reason why inference
for exact OT can remain delicate even on a finite space.
Proof
For positive histograms and fixed ϵ>0, the entropic problem has a
unique optimizer, and the KL-normalized value is smooth on a neighborhood of
(a,b) inside the relative interiors of the simplices.
Proposition: First variations of entropic OT gives
Applying the ordinary delta method to the multinomial CLT
N(a^N−a)⇒Ga gives the one-sample limit
⟨fϵ,Ga⟩, whose variance is the displayed covariance formula.
Fix a relative-interior neighborhood U of a on which the Hessian is
bounded. Multinomial concentration gives
P(a^N∈/U)≤Ce−cN. On U, Taylor’s formula has a
centered linear term and a quadratic remainder bounded by
C∥a^N−a∥2, whose expectation is O(N−1). On the exponentially
unlikely complement, the value remains bounded; on a boundary face, its
natural definition simply discards zero-weight atoms. This proves the bias
bound. The same expansion and bounded multinomial moments give convergence of
the rescaled variance. The two-sample formula follows independently for the
two marginals.
The marginal entropy derivatives described after
Proposition: First variations of entropic OT must therefore be added to the
potentials. For
the debiased Sinkhorn divergence Lˉcϵ, the derivative is
instead the difference between cross and self entropic potentials. At the null
α=β, this first derivative can vanish for the debiased statistic,
and second-order limits then become relevant Goldfeld et al., 2024. This
is a useful warning: the asymptotic law is determined not only by a rate, but
also by the local geometry of the functional.
Three Error Terms When Entropy Estimates Exact OT¶
If the target is Lc(α,β) but the statistic uses
Lcϵ, three errors should be kept separate:
Although algebraic, this identity is important statistically. It is
usually read after choosing ϵ=ϵn. For fixed
ϵ, the statistical bias is typically O(n−1+m−1) in finite
dimension, and the centered fluctuation is
OP(n−1/2+m−1/2); boundary events where an empirical finite
histogram has a zero entry have exponentially small probability when the
population weights are positive. The regularization bias disappears only when
ϵ→0, whereas the variance constants usually deteriorate as
ϵ↓0. This is the asymptotic form of the bias--variance
tradeoff illustrated in Div.
The finite-dimensional formulas above are not merely toy models; they are the
cleanest template for the general mechanism. Whenever an OT value is Hadamard
differentiable and admits a unique sufficiently regular dual potential
f⋆, the empirical-process CLT and the delta method give a first-order
Gaussian limit with one-sample variance
Varα(f⋆(X)). When differentiability fails, as can
happen for exact OT because the dual optimizer is not unique or because one
studies the degenerate self-distance Lc(α,α)=0, the limit may be
non-Gaussian or may occur at a slower non-parametric scale. Entropic
regularization smooths the dual potentials and typically restores a
conventional first-order CLT for fixed ϵ, even under weak assumptions
on the cost. If the target is unregularized OT, however, this statistical
expansion must still be balanced against the bias
Lcϵ(α,β)−Lc(α,β). Thus
Sample Complexity gives dimension-dependent magnitudes, while the
present section identifies the local asymptotic constants and covariance
formulas needed for inference.
The statistical results above explain why entropic OT is attractive at fixed
temperature, but they also expose a computational tension. Sampling the
marginals replaces the input laws by empirical measures and reduces the problem
to finitely many support points; subsampling or coarsening these supports is
governed by the sample-complexity estimates of this chapter. Even after the
supports are fixed, however, a Sinkhorn sweep still costs O(nm), because it
repeatedly applies the Gibbs kernel to vectors. Kernel sketching attacks this
second bottleneck: it keeps the sampled marginals fixed and samples, or
otherwise compresses, the feature representation of the kernel used by
Sinkhorn. With a rank R factorization, Nit scaling sweeps cost
O(Nit(n+m)R), which is linear in the support sizes only when both the
required rank and the iteration count are controlled. The rank generally
depends on dimension, temperature, and target accuracy.
The RKHS/MMD section, Dual RKHS Norms and Maximum Mean Discrepancies, already used positive semidefinite
kernels to define Hilbertian discrepancies between measures. Recall that a
symmetric kernel k:X×X→R is positive semidefinite if, for every
finite family (xi)i=1n, the Gram matrix (k(xi,xj))ij is positive
semidefinite. Many scalable kernel methods start from an integral feature
representation
This is the classical random-feature principle. For data points
(xi)i=1n, the dense Gram matrix K=(k(xi,xj))ij is replaced by
K=ΦΦ⊤, where Φ∈Rn×rp is the sampled
feature matrix with entries
Φi,(ℓ,q)=r−1/2ϕq(xi,zℓ), 1≤ℓ≤r,
1≤q≤p. The number r of sampled latent variables is thus a second
sample size, distinct from the number of data points. At this stage no
positivity of ϕ is assumed; signed or oscillatory features are exactly
what make Fourier sketches useful.
For translation-invariant kernels on Rd, Bochner’s theorem gives the
standard Fourier sketch. If k(x,y)=κ(x−y) and
κ(t)=∫ei⟨ω,t⟩dΛ(ω), with Λ a
positive spectral measure, one may use real features
ϕ(x,ω)=(cos⟨ω,x⟩,sin⟨ω,x⟩). For the Gaussian
kernel kσ(x,y)=exp(−∥x−y∥2/(2σ2)), this corresponds to
ω∼N(0,σ−2Id). This random Fourier feature
construction was introduced by Rahimi and Recht to accelerate large-scale
kernel machines Rahimi & Recht, 2007; its statistical role
for kernel ridge regression and related supervised methods is analyzed, for
instance, in
Rudi & Rosasco, 2017Avron et al., 2017.
where divisions are componentwise. The factorization used by Sinkhorn is
rectangular, because the source points xi and target points yj need not
coincide. Starting from the same sketch
k(x,y)≃r−1∑ℓ=1r⟨ϕ(x,zℓ),ϕ(y,zℓ)⟩Rp, set R=rp and flatten the
pair (ℓ,q) into a single column index. Define
When the two supports are the same, one has ΦX=ΦY=Φ and this
reduces to the symmetric Gram approximation K=ΦΦ⊤. In
the rectangular case, if K is replaced by the rank-R factorization
K=ΦXΦY⊤, the two matrix-vector products are evaluated
as
so each scaling sweep costs O((n+m)R) operations and stores only
O((n+m)R) numbers. The difficulty is that Sinkhorn is not a generic kernel
method: it divides by Kv and, in dual variables, applies
logarithms. Thus one needs Kij>0, preferably with a relative
error on the entries, because −ϵlogKij is the effective cost.
This is a more stringent requirement than the usual spectral or Frobenius
approximation of a PSD Gram matrix.
The next proposition is not a substitute for the sharp low-rank Sinkhorn
theory. It is an elementary concentration lemma whose role is to isolate the
two facts that matter for Sinkhorn: positivity of the approximate kernel and
accuracy after taking logarithms. The full algorithmic statements rely on more
refined Nyström or Gaussian-kernel approximations together with stability of
Sinkhorn scaling
Altschuler et al., 2018Altschuler et al., 2019.
Proof
For a fixed pair (i,j), Hoeffding’s inequality applied to bounded variables
in [−M,M] gives
A union bound over the nm entries gives the first claim. If
maxij∣Kij−Kij∣≤η<κ, then
Kij≥κ−η>0. Writing
Kij=Kij(1+sij), one has
∣sij∣≤η/κ≤1/2, hence
∣log(1+sij)∣≤2∣sij∣, which proves the absolute logarithmic bound.
Applying the same Hoeffding argument to ζij(Z), whose expectation is
1, gives the relative estimate. On the corresponding event,
Kij=Kij(1+sij) with
∣sij∣≤δ≤1/2, so positivity and
ϵ∣log(1+sij)∣≤2ϵδ follow.
This proposition pinpoints the obstruction. When ϵ is small or the
data diameter is large, κ=minKij can be exponentially small, so an
ordinary signed sketch may need a very large r just to keep all entries
positive. What Sinkhorn really needs is relative control of the kernel,
equivalently additive control of the sketched costs. Positive features do not
solve the whole approximation problem, but they remove the most basic failure
mode, negative entries in K. The log-normal positive features
below are unbounded, so this Hoeffding proposition does not apply to them
without truncation or a different concentration argument.
Available worst-case bounds retain explicit dimension dependence. For the quadratic
cost on points contained in a radius-R ball of Rd, the Nyström analysis
of Altschuler, Bach, Rudi and Niles-Weed
Altschuler et al., 2019 studies
Kij=exp(−η∥xi−xj∥2) and bounds the effective rank by a
quantity of the form
up to universal constants and harmless logarithms. Thus the resulting Sinkhorn computation is near-linear in n once this rank
is fixed, but the required rank is polynomial in the inverse kernel bandwidth,
with exponent d and only logarithmic dependence on n in this bound. When the same machinery is used to approximate unregularized
quadratic OT to additive accuracy τ, one takes η of order
τ−1logn, so the complexity contains a factor τ−O(d), often
summarized informally as an ϵ−d-type dependence on the target
precision. The same work also explains why this can be much better on data
with lower intrinsic dimension.
Matrices in DNNn are doubly nonnegative, while matrices in
CPn are completely positive. One always has
CPn⊂DNNn, with equality for n≤4 and strict
inclusion for n≥5Berman & Shaked-Monderer, 2003Burer et al., 2009. Checking
membership in the completely positive cone is computationally hard: strong
membership is NP-hard, and weak membership for the completely positive cone and
its copositive dual is NP-hard Dickinson & Gijben, 2014.
For kernels, it is useful to distinguish the two corresponding notions. A
kernel k is doubly positive if every finite Gram matrix belongs to
DNNn, i.e. if k is PSD and pointwise nonnegative. It is totally
positive in the positive-feature sense if every finite Gram matrix belongs to
CPn. This terminology should not be confused with Karlin’s
classical total positivity, which concerns nonnegativity of all minors of an
ordered kernel Karlin, 1968; it is a
complete-positive-type condition, studied for instance in
DeCorte et al., 2022.
The positive-feature construction of Scetbon and Cuturi
Scetbon & Cuturi, 2020 makes the reason for this
definition direct. If
then every finite Gram matrix is a conic combination of rank-one matrices
vv⊤ with v≥0, and hence is completely positive. Conversely, on a
fixed finite set, K∈CPn is exactly the existence of a
nonnegative factorization K=BB⊤. Thus total positivity is the relevant
finite-sample kernel condition behind positive random features. For
rectangular source--target matrices, one applies the same statement to the
Gram matrix on the union of the sampled source and target points and then
extracts its n×m cross block.
Proof
For sums, concatenate the nonnegative features and rescale them by the square
roots of the nonnegative coefficients. For products, tensor the nonnegative
features:
The tensor feature remains entrywise nonnegative. A measurable mixture is a
limit of conic combinations in the closed completely positive cone on every
finite point set. The autocorrelation formula is already a positive feature
representation with latent variable u and scalar feature g(u−x).
The Gaussian Gibbs kernels used by Sinkhorn admit an especially simple positive
feature representation, which is the construction exploited by Scetbon and
Cuturi Scetbon & Cuturi, 2020. The same construction
extends to the generalized Gaussian kernels
e−∥x−y∥p/ϵ for 0<p≤2, because these kernels are
mixtures of Gaussian kernels. This is the Schoenberg--Bernstein mechanism
behind the positive definiteness of radial stable kernels
Schoenberg, 1938Berg et al., 1984.
Proof
The function s↦e−sa is completely monotone for 0<a≤1.
Bernstein’s theorem therefore gives the Laplace-transform representation of a
positive a-stable random variable Sa. The scaling
Λ=ϵ−1/aSa gives
Taking the expectation over Λ gives kp,ϵ. Since ϕp is
positive, this is a positive-feature representation; hence every finite Gram
matrix is completely positive. The Monte-Carlo sketch is just the empirical
average of this representation.
Choosing x0 near the data can reduce the dynamic range of the features
without changing the kernel. More generally, Gaussian scale mixtures give many
radial totally positive kernels, including standard covariance families used
in Gaussian processes Rasmussen & Williams, 2006.
The gap between doubly positive and totally positive kernels is real. On the
circle, consider
This kernel is PSD and strictly positive pointwise, since
cos2(t/2)=(1+cost)/2 has nonnegative Fourier coefficients and λ
adds a positive constant mode. For λ=1/20, however, its Gram matrix on
five equally spaced points is not completely positive. The Horn copositive
matrix H satisfies ⟨H,B⟩≥0 for every completely positive
matrix B, but the five-point Gram matrix K gives
The factor 1/p, often used in the definition of Wpp, only rescales
ϵ. For p≥1, this is the usual p-Wasserstein power cost; for
0<p<1, it should be read simply as a concave power transport cost.
Proposition Proposition: Generalized Gaussian Positive Features gives a positive
factorization of this kernel. With r draws
(Λℓ,Zℓ)∼νp/2,ϵ⊗N(0,Idd),
define the normalized features
The corresponding matrices (ΦX)iℓ=φℓ(xi) and
(ΦY)jℓ=φℓ(yj) give a positive factorization
K=ΦXΦY⊤. Sinkhorn can therefore be run safely on the
sketched kernel, and the resulting plan is represented as
The output is the exact entropic coupling for the sketched effective cost
cp,ϵ=−ϵlogkp,ϵ, and it
approximates the original Wp-type entropic problem only insofar as this
logarithmic kernel approximation is accurate. This route is complementary to
worst-case near-linear Sinkhorn analyses Altschuler et al., 2017, low-rank
Gaussian-kernel approximations for quadratic transport
Altschuler et al., 2018, and factored-coupling
models in which the coupling itself is constrained to have low rank
Scetbon et al., 2021.
Figure Notebook-code compares the exact Sinkhorn plan with positive-feature approximations and displays the associated approximation of the ground cost.
Figure Notebook-code shows the object that is
changed by this approximation. The top row shows the entropic couplings, while
the bottom row shows the matching effective costs
cϵ(x,y)=−ϵlogkϵ(x,y) with black
level sets. The dense Gaussian Gibbs kernel gives the usual entropic plan and
the quadratic cost ∣x−y∣2. A sufficiently rich rank-40 positive-feature
sketch remains visually close to both, whereas rank-10 and rank-3 sketches
still enforce the prescribed marginals after Sinkhorn scaling but progressively
lose the geometric concentration of the true coupling because the logarithmic
kernel approximation has become too coarse.
Interactive panel. Change the regularization and random seed to compare the
exact Gibbs kernel with positive low-rank sketches and their effective
logarithmic costs.
The same algebra appears in transformer attention, studied later from a
continuous-depth transport viewpoint in
Evolution in Depth of Transformers. A softmax attention matrix has entries
proportional to exp(⟨qi,kj⟩); linear-attention methods
replace this positive kernel by features Φ(qi)⊤Φ(kj), so that
attention can be applied as Φ(Q)(Φ(K)⊤V) rather than by forming
the full n×n matrix
Katharopoulos et al., 2020Choromanski et al., 2021Wang et al., 2020Xiong et al., 2021.
Sinkhorn sketching is the transport analogue of this idea: replace the Gibbs
matrix by a positive feature factorization, keep only the scaling vectors and
feature factors, and control the approximation in the logarithmic scale
relevant to entropic potentials. The transport case is more constrained,
however, since the approximate kernel is reused inside nonlinear normalizations
until the prescribed marginals are reached for the sketched problem.
Berry, A. C. (1941). The Accuracy of the Gaussian Approximation to the Sum of Independent Variates. Transactions of the American Mathematical Society, 49(1), 122–136.
Esseen, C.-G. (1942). On the Liapunoff Limit of Error in the Theory of Probability. Arkiv for Matematik, Astronomi Och Fysik, 28A(9), 1–19.
Chen, L. H. Y., Goldstein, L., & Shao, Q.-M. (2011). Normal Approximation by Stein’s Method. Springer.
Bobkov, S. G. (2018). Berry–Esseen bounds and Edgeworth expansions in the central limit theorem for transport distances. Probability Theory and Related Fields, 170, 229–262.
Rio, E. (2011). Asymptotic constants for minimal distance in the central limit theorem. Electronic Communications in Probability, 16, 96–103.
Petrov, V. V. (1975). Sums of Independent Random Variables (Vol. 82). Springer-Verlag. 10.1007/978-3-642-65809-9
Bhattacharya, R. N., & Ranga Rao, R. (2010). Normal Approximation and Asymptotic Expansions (Vol. 64). Society for Industrial. 10.1137/1.9780898719895
Kolassa, J. E., & McCullagh, P. (1990). Edgeworth Series for Lattice Distributions. The Annals of Statistics, 18(2), 981–985. 10.1214/aos/1176347637
Vallender, S. S. (1974). Calculation of the Wasserstein Distance Between Probability Distributions on the Line. Theory of Probability and Its Applications, 18(4), 784–786. 10.1137/1118101
van der Vaart, A. W., & Wellner, J. A. (1996). Weak Convergence and Empirical Processes: With Applications to Statistics. Springer. 10.1007/978-1-4757-2545-2
Dudley, R. M. (1969). The speed of mean Glivenko-Cantelli convergence. Annals of Mathematical Statistics, 40(1), 40–50.
Weed, J., & Bach, F. (2019). Sharp asymptotic and finite-sample rates of convergence of empirical measures in Wasserstein distance. Bernoulli, 25(4A), 2620–2648. 10.3150/18-BEJ1065
Ramdas, A., Trillos, N. G., & Cuturi, M. (2017). On Wasserstein two-sample testing and related families of nonparametric tests. Entropy, 19(2), 47.
Fournier, N., & Guillin, A. (2015). On the rate of convergence in Wasserstein distance of the empirical measure. Probability Theory and Related Fields, 162(3–4), 707–738.
Singh, S., & Póczos, B. (2018). Minimax Distribution Estimation in Wasserstein Distance. arXiv Preprint arXiv:1802.08855. https://arxiv.org/abs/1802.08855