@@ -216,13 +216,7 @@ More details about the algorithm used is given in the following note.
216216 :any: `ot.smooth.smooth_ot_semi_dual ` with parameter :code: `reg_type='kl' ` to
217217 choose entropic/Kullbach Leibler regularization.
218218
219- .. hint ::
220- Examples of use for :any: `ot.sinkhorn ` are available in the following examples:
221219
222- - :any: `auto_examples/plot_OT_2D_samples `
223- - :any: `auto_examples/plot_OT_1D `
224- - :any: `auto_examples/plot_OT_1D_smooth `
225- - :any: `auto_examples/plot_stochastic `
226220
227221
228222Recently [23 ]_ introduced the sinkhorn divergence that build from entropic
@@ -234,6 +228,15 @@ empirical distributions.
234228Finally note that we also provide in :any: `ot.stochastic ` several implementation
235229of stochastic solvers for entropic regularized OT [18 ]_ [19 ]_.
236230
231+ .. hint ::
232+ Examples of use for :any: `ot.sinkhorn ` are available in the following examples:
233+
234+ - :any: `auto_examples/plot_OT_2D_samples `
235+ - :any: `auto_examples/plot_OT_1D `
236+ - :any: `auto_examples/plot_OT_1D_smooth `
237+ - :any: `auto_examples/plot_stochastic `
238+
239+
237240Other regularization
238241^^^^^^^^^^^^^^^^^^^^
239242
@@ -335,10 +338,79 @@ relies on :any:`ot.sinkhorn` for its iterations.
335338 - :any: `auto_examples/plot_optim_OTreg `
336339
337340
338-
339341Wasserstein Barycenters
340342-----------------------
341343
344+ A Wasserstein barycenter is a distribution that minimize its Wasserstein
345+ distance with respect to other distributions [16 ]_. It corresponds to minimizing the
346+ following problem by seaching a distribution :math: `\mu `
347+
348+ .. math ::
349+ \min _\mu \quad \sum _{k} w_kW(\mu ,\mu _k)
350+
351+
352+ In practice we model a distribution with a finite number of support position:
353+
354+ .. math ::
355+ \mu =\sum _{i=1 }^n a_i\delta _{x_i}
356+
357+ where :math: `a` is an histogram on the simplex and the :math: `\{ x_i\}` are the
358+ position of the support. We can clearly see here that optimizing :math: `\mu ` can
359+ be done by searching for optimal weights :math: `a` or optimal support
360+ :math: `\{ x_i\}` (optimizing both is also an option).
361+ We provide in POT solvers to estimate a discrete
362+ Wasserstein barycenter in both cases.
363+
364+ Barycenters with fixed support
365+ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
366+
367+ When optimizing a barycenter with a fixed support, the optimization problem can
368+ be expressed as
369+
370+
371+ .. math ::
372+ \min _a \quad \sum _{k} w_k W(a,b_k)
373+
374+ where :math: `b_k` are also weights in the simplex. In the non-regularized case,
375+ the problem above is a classical linear program. In this case we propose a
376+ solver :any: `ot.lp.barycenter ` that rely on generic LP solvers. By default the
377+ function uses :any: `scipy.optimize.linprog `, but more efficient LP solvers from
378+ cvxopt can be also used by changing parameter :code: `solver `. Note that these
379+ solver require to solve a very large linear program and can be very slow in
380+ practice.
381+
382+ Similarly to the OT problem, OT barycenters can be computed in the regularized
383+ case. When using entropic regularization the problem can be solved with a
384+ generalization of the sinkhorn algorithm based on bregman projections [3 ]_. This
385+ algorithm is provided in function :any: `ot.bregman.barycenter ` also available as
386+ :any: `ot.barycenter `. In this case, the algorithm scales better to large
387+ distributions and rely only on matrix multiplications that can be performed in
388+ parallel.
389+
390+ In addition to teh speedup brought by regularization, one can also greatly
391+ accelerate the estimation of Wasserstein barycenter when the support has a
392+ separable structure [21 ]_. In teh case of 2D images for instance one can replace
393+ the matrix vector production in teh bregman projections by convolution
394+ operators. We provide an implementation of this algorithm in function
395+ :any: `ot.bregman.convolutional_barycenter2d `.
396+
397+ .. hint ::
398+ Example of Wasserstein (:any: `ot.lp.barycenter `) and regularized wassrestein
399+ barycenter (:any: `ot.bregman.barycenter `) computation are available in the following examples:
400+
401+ - :any: `auto_examples/plot_barycenter_1D `
402+ - :any: `auto_examples/plot_barycenter_lp_vs_entropic `
403+
404+ Example of convolutional barycenter (:any: `ot.bregman.convolutional_barycenter2d `) computation for 2D images is available
405+ in the following example:
406+
407+ - :any: `auto_examples/plot_convolutional_barycenter `
408+
409+
410+
411+ Barycenters with free support
412+ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
413+
342414
343415
344416
0 commit comments