Skip to content

Commit f98698e

Browse files
[MRG] Improve gromov doc and address convention issues (#497)
* fix gromov doc * fix pep8 + update RELEASE * improve doc * merge --------- Co-authored-by: Rémi Flamary <[email protected]>
1 parent 0b520f1 commit f98698e

File tree

5 files changed

+76
-50
lines changed

5 files changed

+76
-50
lines changed

RELEASES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ Many other bugs and issues have been fixed and we want to thank all the contribu
3333

3434
#### Closed issues
3535

36+
- Fix gromov conventions (PR #497)
3637
- Fix change in scipy API for `cdist` (PR #487)
3738
- More permissive check_backend (PR #494)
3839
- Fix circleci-redirector action and codecov (PR #460)

ot/gromov/_bregman.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -225,8 +225,8 @@ def entropic_gromov_wasserstein2(
225225
C1, C2, p=None, q=None, loss_fun='square_loss', epsilon=0.1, symmetric=None, G0=None, max_iter=1000,
226226
tol=1e-9, solver='PGD', warmstart=False, verbose=False, log=False, **kwargs):
227227
r"""
228-
Returns the Gromov-Wasserstein discrepancy between :math:`(\mathbf{C_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{q})`
229-
estimated using Sinkhorn projections.
228+
Returns the Gromov-Wasserstein loss :math:`\mathbf{GW}` between :math:`(\mathbf{C_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{q})`
229+
estimated using Sinkhorn projections. To recover the Gromov-Wasserstein distance as defined in [13] compute :math:`d_{GW} = \frac{1}{2} \sqrt{\mathbf{GW}}`.
230230
231231
If `solver="PGD"`, the function solves the following entropic-regularized
232232
Gromov-Wasserstein optimization problem using Projected Gradient Descent [12]:
@@ -351,7 +351,7 @@ def entropic_gromov_barycenters(
351351
352352
.. math::
353353
354-
\mathbf{C} = \mathop{\arg \min}_{\mathbf{C}\in \mathbb{R}^{N \times N}} \quad \sum_s \lambda_s \mathrm{GW}(\mathbf{C}, \mathbf{C}_s, \mathbf{p}, \mathbf{p}_s)
354+
\mathbf{C}^* = \mathop{\arg \min}_{\mathbf{C}\in \mathbb{R}^{N \times N}} \quad \sum_s \lambda_s \mathrm{GW}(\mathbf{C}, \mathbf{C}_s, \mathbf{p}, \mathbf{p}_s)
355355
356356
Where :
357357
@@ -700,7 +700,7 @@ def entropic_fused_gromov_wasserstein2(
700700
symmetric=None, alpha=0.5, G0=None, max_iter=1000, tol=1e-9,
701701
solver='PGD', warmstart=False, verbose=False, log=False, **kwargs):
702702
r"""
703-
Returns the Fused Gromov-Wasserstein transport between :math:`(\mathbf{C_1}, \mathbf{Y_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{Y_2}, \mathbf{q})`
703+
Returns the Fused Gromov-Wasserstein distance between :math:`(\mathbf{C_1}, \mathbf{Y_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{Y_2}, \mathbf{q})`
704704
with pairwise distance matrix :math:`\mathbf{M}` between node feature matrices :math:`\mathbf{Y_1}` and :math:`\mathbf{Y_2}`,
705705
estimated using Sinkhorn projections.
706706
@@ -832,7 +832,7 @@ def entropic_fused_gromov_barycenters(
832832
833833
.. math::
834834
835-
\mathbf{C}, \mathbf{Y} = \mathop{\arg \min}_{\mathbf{C}\in \mathbb{R}^{N \times N}, \mathbf{Y}\in \mathbb{Y}^{N \times d}} \quad \sum_s \lambda_s \mathrm{FGW}_{\alpha}(\mathbf{C}, \mathbf{C}_s, \mathbf{Y}, \mathbf{Y}_s, \mathbf{p}, \mathbf{p}_s)
835+
\mathbf{C}^*, \mathbf{Y}^* = \mathop{\arg \min}_{\mathbf{C}\in \mathbb{R}^{N \times N}, \mathbf{Y}\in \mathbb{Y}^{N \times d}} \quad \sum_s \lambda_s \mathrm{FGW}_{\alpha}(\mathbf{C}, \mathbf{C}_s, \mathbf{Y}, \mathbf{Y}_s, \mathbf{p}, \mathbf{p}_s)
836836
837837
Where :
838838

ot/gromov/_estimators.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,14 @@
2020
def GW_distance_estimation(C1, C2, p, q, loss_fun, T,
2121
nb_samples_p=None, nb_samples_q=None, std=True, random_state=None):
2222
r"""
23-
Returns an approximation of the gromov-wasserstein cost between :math:`(\mathbf{C_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{q})`
24-
with a fixed transport plan :math:`\mathbf{T}`.
23+
Returns an approximation of the Gromov-Wasserstein loss between :math:`(\mathbf{C_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{q})`
24+
with a fixed transport plan :math:`\mathbf{T}`. To recover an approximation of the Gromov-Wasserstein distance as defined in [13] compute :math:`d_{GW} = \frac{1}{2} \sqrt{\mathbf{GW}}`.
2525
2626
The function gives an unbiased approximation of the following equation:
2727
2828
.. math::
2929
30-
GW = \sum_{i,j,k,l} L(\mathbf{C_{1}}_{i,k}, \mathbf{C_{2}}_{j,l}) \mathbf{T}_{i,j} \mathbf{T}_{k,l}
30+
\mathbf{GW} = \sum_{i,j,k,l} L(\mathbf{C_{1}}_{i,k}, \mathbf{C_{2}}_{j,l}) \mathbf{T}_{i,j} \mathbf{T}_{k,l}
3131
3232
Where :
3333

ot/gromov/_gw.py

Lines changed: 54 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@
2626
def gromov_wasserstein(C1, C2, p=None, q=None, loss_fun='square_loss', symmetric=None, log=False, armijo=False, G0=None,
2727
max_iter=1e4, tol_rel=1e-9, tol_abs=1e-9, **kwargs):
2828
r"""
29-
Returns the Gromov-Wasserstein transport between :math:`(\mathbf{C_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{q})`
29+
Returns the Gromov-Wasserstein transport between :math:`(\mathbf{C_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{q})`.
3030
31-
The function solves the following optimization problem:
31+
The function solves the following optimization problem using Conditional Gradient:
3232
3333
.. math::
3434
\mathbf{T}^* \in \mathop{\arg \min}_\mathbf{T} \quad \sum_{i,j,k,l}
@@ -182,9 +182,10 @@ def line_search(cost, G, deltaG, Mi, cost_G, **kwargs):
182182
def gromov_wasserstein2(C1, C2, p=None, q=None, loss_fun='square_loss', symmetric=None, log=False, armijo=False, G0=None,
183183
max_iter=1e4, tol_rel=1e-9, tol_abs=1e-9, **kwargs):
184184
r"""
185-
Returns the Gromov-Wasserstein discrepancy between :math:`(\mathbf{C_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{q})`
185+
Returns the Gromov-Wasserstein loss :math:`\mathbf{GW}` between :math:`(\mathbf{C_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{q})`.
186+
To recover the Gromov-Wasserstein distance as defined in [13] compute :math:`d_{GW} = \frac{1}{2} \sqrt{\mathbf{GW}}`.
186187
187-
The function solves the following optimization problem:
188+
The function solves the following optimization problem using Conditional Gradient:
188189
189190
.. math::
190191
\mathbf{GW} = \min_\mathbf{T} \quad \sum_{i,j,k,l}
@@ -308,31 +309,36 @@ def gromov_wasserstein2(C1, C2, p=None, q=None, loss_fun='square_loss', symmetri
308309
def fused_gromov_wasserstein(M, C1, C2, p=None, q=None, loss_fun='square_loss', symmetric=None, alpha=0.5,
309310
armijo=False, G0=None, log=False, max_iter=1e4, tol_rel=1e-9, tol_abs=1e-9, **kwargs):
310311
r"""
311-
Computes the FGW transport between two graphs (see :ref:`[24] <references-fused-gromov-wasserstein>`)
312+
Returns the Fused Gromov-Wasserstein transport between :math:`(\mathbf{C_1}, \mathbf{Y_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{Y_2}, \mathbf{q})`
313+
with pairwise distance matrix :math:`\mathbf{M}` between node feature matrices :math:`\mathbf{Y_1}` and :math:`\mathbf{Y_2}` (see :ref:`[24] <references-fused-gromov-wasserstein>`).
314+
315+
The function solves the following optimization problem using Conditional Gradient:
312316
313317
.. math::
314-
\mathbf{T}^* \in \mathop{\arg \min}_\mathbf{T} \quad (1 - \alpha) \langle \mathbf{T}, \mathbf{M} \rangle_F +
318+
\mathbf{T}^* \in\mathop{\arg\min}_\mathbf{T} \quad (1 - \alpha) \langle \mathbf{T}, \mathbf{M} \rangle_F +
315319
\alpha \sum_{i,j,k,l} L(\mathbf{C_1}_{i,k}, \mathbf{C_2}_{j,l}) \mathbf{T}_{i,j} \mathbf{T}_{k,l}
316320
317321
s.t. \ \mathbf{T} \mathbf{1} &= \mathbf{p}
318322
319323
\mathbf{T}^T \mathbf{1} &= \mathbf{q}
320324
321325
\mathbf{T} &\geq 0
326+
Where :
322327
323-
where :
324-
325-
- :math:`\mathbf{M}` is the (`ns`, `nt`) metric cost matrix
326-
- :math:`\mathbf{p}` and :math:`\mathbf{q}` are source and target weights (sum to 1)
327-
- `L` is a loss function to account for the misfit between the similarity matrices
328+
- :math:`\mathbf{M}`: metric cost matrix between features across domains
329+
- :math:`\mathbf{C_1}`: Metric cost matrix in the source space
330+
- :math:`\mathbf{C_2}`: Metric cost matrix in the target space
331+
- :math:`\mathbf{p}`: distribution in the source space
332+
- :math:`\mathbf{q}`: distribution in the target space
333+
- `L`: loss function to account for the misfit between the similarity and feature matrices
334+
- :math:`\alpha`: trade-off parameter
328335
329336
.. note:: This function is backend-compatible and will work on arrays
330337
from all compatible backends. But the algorithm uses the C++ CPU backend
331338
which can lead to copy overhead on GPU arrays.
332339
.. note:: All computations in the conjugate gradient solver are done with
333340
numpy to limit memory overhead.
334341
335-
The algorithm used for solving the problem is conditional gradient as discussed in :ref:`[24] <references-fused-gromov-wasserstein>`
336342
337343
Parameters
338344
----------
@@ -465,36 +471,39 @@ def line_search(cost, G, deltaG, Mi, cost_G, **kwargs):
465471
def fused_gromov_wasserstein2(M, C1, C2, p=None, q=None, loss_fun='square_loss', symmetric=None, alpha=0.5,
466472
armijo=False, G0=None, log=False, max_iter=1e4, tol_rel=1e-9, tol_abs=1e-9, **kwargs):
467473
r"""
468-
Computes the FGW distance between two graphs see (see :ref:`[24] <references-fused-gromov-wasserstein2>`)
474+
Returns the Fused Gromov-Wasserstein distance between :math:`(\mathbf{C_1}, \mathbf{Y_1}, \mathbf{p})` and :math:`(\mathbf{C_2}, \mathbf{Y_2}, \mathbf{q})`
475+
with pairwise distance matrix :math:`\mathbf{M}` between node feature matrices :math:`\mathbf{Y_1}` and :math:`\mathbf{Y_2}` (see :ref:`[24] <references-fused-gromov-wasserstein>`).
469476
470-
.. math::
471-
\mathbf{GW} = \min_\mathbf{T} \quad (1 - \alpha) \langle \mathbf(T), \mathbf{M} \rangle_F + \alpha \sum_{i,j,k,l}
472-
L(\mathbf{C_1}_{i,k}, \mathbf{C_2}_{j,l}) \mathbf{T}_{i,j} \mathbf{T}_{k,l}
477+
The function solves the following optimization problem using Conditional Gradient:
473478
474-
s.t. \ \mathbf(T)\mathbf{1} &= \mathbf{p}
479+
.. math::
480+
\mathbf{FGW} = \mathop{\min}_\mathbf{T} \quad (1 - \alpha) \langle \mathbf{T}, \mathbf{M} \rangle_F +
481+
\alpha \sum_{i,j,k,l} L(\mathbf{C_1}_{i,k}, \mathbf{C_2}_{j,l}) \mathbf{T}_{i,j} \mathbf{T}_{k,l}
475482
476-
\mathbf(T)^T \mathbf{1} &= \mathbf{q}
483+
s.t. \ \mathbf{T} \mathbf{1} &= \mathbf{p}
477484
478-
\mathbf(T) &\geq 0
485+
\mathbf{T}^T \mathbf{1} &= \mathbf{q}
479486
480-
where :
487+
\mathbf{T} &\geq 0
488+
Where :
481489
482-
- :math:`\mathbf{M}` is the (`ns`, `nt`) metric cost matrix
483-
- :math:`\mathbf{p}` and :math:`\mathbf{q}` are source and target weights (sum to 1)
484-
- `L` is a loss function to account for the misfit between the similarity matrices
490+
- :math:`\mathbf{M}`: metric cost matrix between features across domains
491+
- :math:`\mathbf{C_1}`: Metric cost matrix in the source space
492+
- :math:`\mathbf{C_2}`: Metric cost matrix in the target space
493+
- :math:`\mathbf{p}`: distribution in the source space
494+
- :math:`\mathbf{q}`: distribution in the target space
495+
- `L`: loss function to account for the misfit between the similarity and feature matrices
496+
- :math:`\alpha`: trade-off parameter
485497
486-
The algorithm used for solving the problem is conditional gradient as
487-
discussed in :ref:`[24] <references-fused-gromov-wasserstein2>`
498+
Note that when using backends, this loss function is differentiable wrt the
499+
matrices (C1, C2, M) and weights (p, q) for quadratic loss using the gradients from [38]_.
488500
489501
.. note:: This function is backend-compatible and will work on arrays
490502
from all compatible backends. But the algorithm uses the C++ CPU backend
491503
which can lead to copy overhead on GPU arrays.
492504
.. note:: All computations in the conjugate gradient solver are done with
493505
numpy to limit memory overhead.
494506
495-
Note that when using backends, this loss function is differentiable wrt the
496-
matrices (C1, C2, M) and weights (p, q) for quadratic loss using the gradients from [38]_.
497-
498507
Parameters
499508
----------
500509
M : array-like, shape (ns, nt)
@@ -668,13 +677,13 @@ def gromov_barycenters(
668677
max_iter=1000, tol=1e-9, warmstartT=False, verbose=False, log=False,
669678
init_C=None, random_state=None, **kwargs):
670679
r"""
671-
Returns the gromov-wasserstein barycenters of `S` measured similarity matrices :math:`(\mathbf{C}_s)_{1 \leq s \leq S}`
680+
Returns the Gromov-Wasserstein barycenters of `S` measured similarity matrices :math:`(\mathbf{C}_s)_{1 \leq s \leq S}`
672681
673682
The function solves the following optimization problem with block coordinate descent:
674683
675684
.. math::
676685
677-
\mathbf{C} = \mathop{\arg \min}_{\mathbf{C}\in \mathbb{R}^{N \times N}} \quad \sum_s \lambda_s \mathrm{GW}(\mathbf{C}, \mathbf{C}_s, \mathbf{p}, \mathbf{p}_s)
686+
\mathbf{C}^* = \mathop{\arg \min}_{\mathbf{C}\in \mathbb{R}^{N \times N}} \quad \sum_s \lambda_s \mathrm{GW}(\mathbf{C}, \mathbf{C}_s, \mathbf{p}, \mathbf{p}_s)
678687
679688
Where :
680689
@@ -812,7 +821,21 @@ def fgw_barycenters(
812821
fixed_features=False, p=None, loss_fun='square_loss', armijo=False,
813822
symmetric=True, max_iter=100, tol=1e-9, warmstartT=False, verbose=False,
814823
log=False, init_C=None, init_X=None, random_state=None, **kwargs):
815-
r"""Compute the fgw barycenter as presented eq (5) in :ref:`[24] <references-fgw-barycenters>`
824+
r"""
825+
Returns the Fused Gromov-Wasserstein barycenters of `S` measurable networks with node features :math:`(\mathbf{C}_s, \mathbf{Y}_s, \mathbf{p}_s)_{1 \leq s \leq S}`
826+
(see eq (5) in :ref:`[24] <references-fgw-barycenters>`), estimated using Fused Gromov-Wasserstein transports from Conditional Gradient solvers.
827+
828+
The function solves the following optimization problem:
829+
830+
.. math::
831+
832+
\mathbf{C}^*, \mathbf{Y}^* = \mathop{\arg \min}_{\mathbf{C}\in \mathbb{R}^{N \times N}, \mathbf{Y}\in \mathbb{Y}^{N \times d}} \quad \sum_s \lambda_s \mathrm{FGW}_{\alpha}(\mathbf{C}, \mathbf{C}_s, \mathbf{Y}, \mathbf{Y}_s, \mathbf{p}, \mathbf{p}_s)
833+
834+
Where :
835+
836+
- :math:`\mathbf{Y}_s`: feature matrix
837+
- :math:`\mathbf{C}_s`: metric cost matrix
838+
- :math:`\mathbf{p}_s`: distribution
816839
817840
Parameters
818841
----------

ot/gromov/_semirelaxed.py

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@
2121
def semirelaxed_gromov_wasserstein(C1, C2, p=None, loss_fun='square_loss', symmetric=None, log=False, G0=None,
2222
max_iter=1e4, tol_rel=1e-9, tol_abs=1e-9, **kwargs):
2323
r"""
24-
Returns the semi-relaxed Gromov-Wasserstein divergence transport from :math:`(\mathbf{C_1}, \mathbf{p})` to :math:`\mathbf{C_2}`
24+
Returns the semi-relaxed Gromov-Wasserstein divergence transport from :math:`(\mathbf{C_1}, \mathbf{p})` to :math:`\mathbf{C_2}` (see [48]).
2525
26-
The function solves the following optimization problem:
26+
The function solves the following optimization problem using Conditional Gradient:
2727
2828
.. math::
29-
\mathbf{T}^^* \in \mathop{\arg \min}_{\mathbf{T}} \quad \sum_{i,j,k,l}
29+
\mathbf{T}^* \in \mathop{\arg \min}_{\mathbf{T}} \quad \sum_{i,j,k,l}
3030
L(\mathbf{C_1}_{i,k}, \mathbf{C_2}_{j,l}) \mathbf{T}_{i,j} \mathbf{T}_{k,l}
3131
3232
s.t. \ \mathbf{T} \mathbf{1} &= \mathbf{p}
@@ -152,9 +152,9 @@ def line_search(cost, G, deltaG, Mi, cost_G, **kwargs):
152152
def semirelaxed_gromov_wasserstein2(C1, C2, p=None, loss_fun='square_loss', symmetric=None, log=False, G0=None,
153153
max_iter=1e4, tol_rel=1e-9, tol_abs=1e-9, **kwargs):
154154
r"""
155-
Returns the semi-relaxed gromov-wasserstein divergence from :math:`(\mathbf{C_1}, \mathbf{p})` to :math:`\mathbf{C_2}`
155+
Returns the semi-relaxed Gromov-Wasserstein divergence from :math:`(\mathbf{C_1}, \mathbf{p})` to :math:`\mathbf{C_2}` (see [48]).
156156
157-
The function solves the following optimization problem:
157+
The function solves the following optimization problem using Conditional Gradient:
158158
159159
.. math::
160160
\text{srGW} = \min_{\mathbf{T}} \quad \sum_{i,j,k,l}
@@ -255,7 +255,7 @@ def semirelaxed_fused_gromov_wasserstein(
255255
M, C1, C2, p=None, loss_fun='square_loss', symmetric=None, alpha=0.5,
256256
G0=None, log=False, max_iter=1e4, tol_rel=1e-9, tol_abs=1e-9, **kwargs):
257257
r"""
258-
Computes the semi-relaxed FGW transport between two graphs (see :ref:`[48] <references-semirelaxed-fused-gromov-wasserstein>`)
258+
Computes the semi-relaxed Fused Gromov-Wasserstein transport between two graphs (see [48]).
259259
260260
.. math::
261261
\mathbf{T}^* \in \mathop{\arg \min}_{\mathbf{T}} \quad (1 - \alpha) \langle \mathbf{T}, \mathbf{M} \rangle_F +
@@ -395,10 +395,10 @@ def line_search(cost, G, deltaG, Mi, cost_G, **kwargs):
395395
def semirelaxed_fused_gromov_wasserstein2(M, C1, C2, p=None, loss_fun='square_loss', symmetric=None, alpha=0.5, G0=None, log=False,
396396
max_iter=1e4, tol_rel=1e-9, tol_abs=1e-9, **kwargs):
397397
r"""
398-
Computes the semi-relaxed FGW divergence between two graphs (see :ref:`[48] <references-semirelaxed-fused-gromov-wasserstein2>`)
398+
Computes the semi-relaxed FGW divergence between two graphs (see [48]).
399399
400400
.. math::
401-
\mathbf{srFGW} = \min_{\mathbf{T}} \quad (1 - \alpha) \langle \mathbf{T}, \mathbf{M} \rangle_F +
401+
\mathbf{srFGW}_{\alpha} = \min_{\mathbf{T}} \quad (1 - \alpha) \langle \mathbf{T}, \mathbf{M} \rangle_F +
402402
\alpha \sum_{i,j,k,l} L(\mathbf{C_1}_{i,k}, \mathbf{C_2}_{j,l}) T_{i,j} T_{k,l}
403403
404404
s.t. \ \mathbf{T} \mathbf{1} &= \mathbf{p}
@@ -511,7 +511,7 @@ def semirelaxed_fused_gromov_wasserstein2(M, C1, C2, p=None, loss_fun='square_lo
511511
def solve_semirelaxed_gromov_linesearch(G, deltaG, cost_G, C1, C2, ones_p,
512512
M, reg, alpha_min=None, alpha_max=None, nx=None, **kwargs):
513513
"""
514-
Solve the linesearch in the FW iterations
514+
Solve the linesearch in the Conditional Gradient iterations for the semi-relaxed Gromov-Wasserstein divergence.
515515
516516
Parameters
517517
----------
@@ -829,6 +829,7 @@ def entropic_semirelaxed_fused_gromov_wasserstein(
829829
alpha=0.5, G0=None, max_iter=1e4, tol=1e-9, log=False, verbose=False, **kwargs):
830830
r"""
831831
Computes the entropic-regularized semi-relaxed FGW transport between two graphs (see :ref:`[48] <references-semirelaxed-fused-gromov-wasserstein>`)
832+
estimated using a Mirror Descent algorithm following the KL geometry.
832833
833834
.. math::
834835
\mathbf{T}^* \in \mathop{\arg \min}_{\mathbf{T}} \quad (1 - \alpha) \langle \mathbf{T}, \mathbf{M} \rangle_F +
@@ -988,10 +989,11 @@ def entropic_semirelaxed_fused_gromov_wasserstein2(
988989
M, C1, C2, p=None, loss_fun='square_loss', symmetric=None, epsilon=0.1,
989990
alpha=0.5, G0=None, max_iter=1e4, tol=1e-9, log=False, verbose=False, **kwargs):
990991
r"""
991-
Computes the entropic-regularized semi-relaxed FGW transport between two graphs (see :ref:`[48] <references-semirelaxed-fused-gromov-wasserstein>`)
992+
Computes the entropic-regularized semi-relaxed FGW divergence between two graphs (see :ref:`[48] <references-semirelaxed-fused-gromov-wasserstein>`)
993+
estimated using a Mirror Descent algorithm following the KL geometry.
992994
993995
.. math::
994-
\mathbf{srFGW} = \min_{\mathbf{T}} \quad (1 - \alpha) \langle \mathbf{T}, \mathbf{M} \rangle_F +
996+
\mathbf{srFGW}_{\alpha} = \min_{\mathbf{T}} \quad (1 - \alpha) \langle \mathbf{T}, \mathbf{M} \rangle_F +
995997
\alpha \sum_{i,j,k,l} L(\mathbf{C_1}_{i,k}, \mathbf{C_2}_{j,l}) \mathbf{T}_{i,j} \mathbf{T}_{k,l}
996998
997999
s.t. \ \mathbf{T} \mathbf{1} &= \mathbf{p}

0 commit comments

Comments
 (0)