- ott.solvers.linear.discrete_barycenter.discrete_barycenter(geom, a, weights=None, dual_initialization=None, threshold=0.01, norm_error=1, inner_iterations=10, min_iterations=0, max_iterations=2000, lse_mode=True, debiased=False)#
Compute discrete barycenter [Janati et al., 2020].
Geometry) – geometry object.
Array) – batch of histograms of shape
Array]) – positive weights in the probability simplex.
Array]) – array of shape
[batch, num_b]for the initialization of g_v.
float) – tolerance to monitor convergence.
int) – power used to define p-norm of error for marginal/target.
float) – the Sinkhorn error is not recomputed at each iteration but every inner_num_iter instead to avoid computational overhead.
int) – the minimum number of Sinkhorn iterations carried out before the error is computed and monitored.
int) – the maximum number of Sinkhorn iterations.
bool) – True for log-sum-exp computations, False for kernel multiply.
bool) – whether to run the debiased version of the Sinkhorn divergence.
- Return type
SinkhornBarycenterOutput, which contains two arrays of potentials, each of size
geom.num_a, summarizing the OT between each histogram in the database onto the barycenter, described in
histogram, as well as a sequence of errors that monitors convergence.