Efficient and Accurate Optimal Transport with Mirror Descent and Conjugate Gradients

Mete Kemertas, Allan Douglas Jepson, Amir-massoud Farahmand

TL;DR

This paper introduces MDOT, a new method for solving Optimal Transport (OT) problems that achieves high precision and speed by combining mirror descent with temperature annealing. Their approach, particularly when paired with a novel GPU-accelerated conjugate gradient solver (PNCG), significantly outperforms existing methods, especially in challenging scenarios with weak regularization.

What Problem Does This Paper Address?

Optimal Transport (OT) is a powerful tool for comparing probability distributions, finding applications in fields like computer vision, physics, and machine learning. However, computing OT distances, especially for high-dimensional data, is computationally expensive. Traditional methods like Sinkhorn iterations offer scalability but often sacrifice precision. While more advanced algorithms exist, they can be complex or not fully leverage modern hardware. This paper aims to bridge this gap by developing an efficient and accurate OT solver that is both theoretically grounded and practically performant on GPUs.

Methods

The core of the paper is the Mirror Descent Optimal Transport (MDOT) framework. MDOT unifies temperature annealing (a technique used in entropic-regularized OT) with mirror descent. The idea is to solve a sequence of increasingly less regularized OT problems, where each problem's solution is used to "warm-start" the next. This allows the method to gradually approach the solution of the original, unregularized OT problem.

A key innovation is the warm-starting strategy for the dual problems. Instead of starting from scratch at each temperature step, MDOT uses a Taylor expansion of previous solutions to predict a good initial guess for the current problem. This significantly speeds up convergence.

For solving the dual problems efficiently, the authors introduce a GPU-parallel nonlinear conjugate gradients (PNCG) algorithm. This algorithm is designed to be more effective than traditional Sinkhorn iterations, especially when the regularization is weak (i.e., at lower temperatures).

Datasets

The authors evaluate their method on:

  • Upsampled MNIST dataset: Original 28x28 images are upsampled to 64x64, resulting in $n=4096$ data points. Cost matrices are constructed using L1 and squared L2 distances.
  • Color Transfer dataset: Images are treated as point clouds, and cost matrices are derived from L1 and L2 distances. Original 1024x1024 images are downsampled to 64x64 ($n=4096$).
  • DOTmark benchmark: An additional 20 problem sets are used for benchmarking, including various image types and synthetic data.

Key Insights and Ideas

  • Warm-starting is crucial: The paper demonstrates that intelligently warm-starting the optimization at each temperature step is key to MDOT's efficiency, significantly outperforming simpler temperature decay strategies.
  • Mirror Descent + Annealing = Synergy: Unifying mirror descent with temperature annealing provides a principled way to tackle the ill-conditioning that arises as regularization decreases.
  • PNCG shines at low temperatures: The proposed PNCG algorithm offers a substantial speedup over Sinkhorn iterations when dealing with weakly regularized OT problems, which are often the most challenging.
  • Sinkhorn's theoretical potential: The authors show that by carefully tuning the stopping criterion of Sinkhorn iterations, their theoretical convergence rates can be improved, hinting at the power of adaptive strategies.

Key Results

  • Speedup: MDOT-PNCG achieves high-precision, feasible OT solutions significantly faster than existing state-of-the-art methods, including accelerated gradient methods and advanced Sinkhorn variants.
  • Scalability: For problem sizes up to $n=16,384$, MDOT-PNCG scales as $\widetilde{O}(n^2)$ for moderate precision and $\widetilde{O}(n^{5/2})$ at worst for high precision.
  • Robustness: Ablation studies show MDOT-PNCG is robust to various algorithmic parameters.
  • Comparison to IPOT: MDOT-PNCG shows comparable or superior performance to the IPOT algorithm, particularly for L2 costs, and achieves higher precision in fewer operations.

Limitations and Future Work

  • Theoretical analysis of PNCG: The paper mentions that further theoretical convergence analysis of the PNCG algorithm is an interesting direction.
  • Warm-starting bounds: Developing tighter theoretical bounds on the gradient norm of the warm-started initialization is suggested.
  • Adaptive criteria: Exploring adaptive dual problem stopping criteria and adaptive temperature decay schedules are identified as future research avenues.
  • Faster KL projection: The development of even faster KL projection algorithms could further enhance MDOT's performance.

Summary updated

Abstract

We propose Mirror Descent Optimal Transport (MDOT), a novel method for solving discrete optimal transport (OT) problems with high precision, by unifying temperature annealing in entropic-regularized OT (EOT) with mirror descent techniques. In this framework, temperature annealing produces a sequence of EOT dual problems, whose solution gradually gets closer to the solution of the original OT problem. We solve each problem efficiently using a GPU-parallel nonlinear conjugate gradients algorithm (PNCG) that outperforms traditional Sinkhorn iterations under weak regularization. Moreover, our investigation also reveals that the theoretical convergence rate of Sinkhorn iterations can exceed existing non-asymptotic bounds when its stopping criterion is tuned in a manner analogous to MDOT. Our comprehensive ablation studies of MDOT-PNCG affirm its robustness across a wide range of algorithmic parameters. Benchmarking on 24 problem sets of size $n=4096$ in a GPU environment demonstrate that our method attains high-precision, feasible solutions significantly faster than a representative set of existing OT solvers—including accelerated gradient methods and advanced Sinkhorn variants—in both wall-clock time and number of operations. Empirical convergence rates range between $O(n^2 \varepsilon^{-1/4})$ and $O(n^2 \varepsilon^{-1})$, where $\varepsilon$ is the optimality gap. For problem sizes up to $n=16\,384$, the empirical runtime scales as $\widetilde{O}(n^2)$ for moderate precision and as $\widetilde{O}(n^{5/2})$ at worst for high precision. These findings establish MDOT-PNCG as a compelling alternative to current OT solvers, particularly in challenging weak-regularization regimes.
BibTeX
@article{kemertas2025efficient,
  author = {Mete Kemertas and Allan Douglas Jepson and Amir-massoud Farahmand},
  title = {{Efficient and Accurate Optimal Transport with Mirror Descent and Conjugate Gradients}},
  journal = {Trans. Mach. Learn. Res.},
  year = {2025},
}
Figure