@@ -473,22 +473,24 @@ def joint_OT_mapping_kernel(xs, xt, mu=1, eta=0.001, kerneltype='gaussian',
473
473
Weight for the linear OT loss (>0)
474
474
eta : float, optional
475
475
Regularization term for the linear mapping L (>0)
476
- bias : bool,optional
477
- Estimate linear mapping with constant bias
478
476
kerneltype : str,optional
479
477
kernel used by calling function ot.utils.kernel (gaussian by default)
480
478
sigma : float, optional
481
479
Gaussian kernel bandwidth.
480
+ bias : bool,optional
481
+ Estimate linear mapping with constant bias
482
+ verbose : bool, optional
483
+ Print information along iterations
484
+ verbose2 : bool, optional
485
+ Print information along iterations
482
486
numItermax : int, optional
483
487
Max number of BCD iterations
484
- stopThr : float, optional
485
- Stop threshold on relative loss decrease (>0)
486
488
numInnerItermax : int, optional
487
489
Max number of iterations (inner CG solver)
488
490
stopInnerThr : float, optional
489
491
Stop threshold on error (inner CG solver) (>0)
490
- verbose : bool , optional
491
- Print information along iterations
492
+ stopThr : float , optional
493
+ Stop threshold on relative loss decrease (>0)
492
494
log : bool, optional
493
495
record log if True
494
496
@@ -643,7 +645,8 @@ def OT_mapping_linear(xs, xt, reg=1e-6, ws=None,
643
645
The function estimates the optimal linear operator that aligns the two
644
646
empirical distributions. This is equivalent to estimating the closed
645
647
form mapping between two Gaussian distributions :math:`N(\mu_s,\Sigma_s)`
646
- and :math:`N(\mu_t,\Sigma_t)` as proposed in [14] and discussed in remark 2.29 in [15].
648
+ and :math:`N(\mu_t,\Sigma_t)` as proposed in [14] and discussed in remark
649
+ 2.29 in [15].
647
650
648
651
The linear operator from source to target :math:`M`
649
652
@@ -1184,25 +1187,25 @@ class SinkhornTransport(BaseTransport):
1184
1187
algorithm if no it has not converged
1185
1188
tol : float, optional (default=10e-9)
1186
1189
The precision required to stop the optimization algorithm.
1187
- mapping : string, optional (default="barycentric")
1188
- The kind of mapping to apply to transport samples from a domain into
1189
- another one.
1190
- if "barycentric" only the samples used to estimate the coupling can
1191
- be transported from a domain to another one.
1190
+ verbose : bool, optional (default=False)
1191
+ Controls the verbosity of the optimization algorithm
1192
+ log : int, optional (default=False)
1193
+ Controls the logs of the optimization algorithm
1192
1194
metric : string, optional (default="sqeuclidean")
1193
1195
The ground metric for the Wasserstein problem
1194
1196
norm : string, optional (default=None)
1195
1197
If given, normalize the ground metric to avoid numerical errors that
1196
1198
can occur with large metric values.
1197
- distribution : string , optional (default=" uniform" )
1199
+ distribution_estimation : callable , optional (defaults to the uniform)
1198
1200
The kind of distribution estimation to employ
1199
- verbose : int , optional (default=0 )
1200
- Controls the verbosity of the optimization algorithm
1201
- log : int, optional (default=0)
1202
- Controls the logs of the optimization algorithm
1201
+ out_of_sample_map : string , optional (default="ferradans" )
1202
+ The kind of out of sample mapping to apply to transport samples
1203
+ from a domain into another one. Currently the only possible option is
1204
+ "ferradans" which uses the method proposed in [6].
1203
1205
limit_max: float, optional (defaul=np.infty)
1204
1206
Controls the semi supervised mode. Transport between labeled source
1205
- and target samples of different classes will exhibit an infinite cost
1207
+ and target samples of different classes will exhibit an cost defined
1208
+ by this variable
1206
1209
1207
1210
Attributes
1208
1211
----------
@@ -1287,22 +1290,19 @@ class EMDTransport(BaseTransport):
1287
1290
1288
1291
Parameters
1289
1292
----------
1290
- mapping : string, optional (default="barycentric")
1291
- The kind of mapping to apply to transport samples from a domain into
1292
- another one.
1293
- if "barycentric" only the samples used to estimate the coupling can
1294
- be transported from a domain to another one.
1295
1293
metric : string, optional (default="sqeuclidean")
1296
1294
The ground metric for the Wasserstein problem
1297
1295
norm : string, optional (default=None)
1298
1296
If given, normalize the ground metric to avoid numerical errors that
1299
1297
can occur with large metric values.
1300
- distribution : string, optional (default="uniform")
1301
- The kind of distribution estimation to employ
1302
- verbose : int, optional (default=0)
1303
- Controls the verbosity of the optimization algorithm
1304
- log : int, optional (default=0)
1298
+ log : int, optional (default=False)
1305
1299
Controls the logs of the optimization algorithm
1300
+ distribution_estimation : callable, optional (defaults to the uniform)
1301
+ The kind of distribution estimation to employ
1302
+ out_of_sample_map : string, optional (default="ferradans")
1303
+ The kind of out of sample mapping to apply to transport samples
1304
+ from a domain into another one. Currently the only possible option is
1305
+ "ferradans" which uses the method proposed in [6].
1306
1306
limit_max: float, optional (default=10)
1307
1307
Controls the semi supervised mode. Transport between labeled source
1308
1308
and target samples of different classes will exhibit an infinite cost
@@ -1387,28 +1387,32 @@ class SinkhornLpl1Transport(BaseTransport):
1387
1387
Entropic regularization parameter
1388
1388
reg_cl : float, optional (default=0.1)
1389
1389
Class regularization parameter
1390
- mapping : string, optional (default="barycentric")
1391
- The kind of mapping to apply to transport samples from a domain into
1392
- another one.
1393
- if "barycentric" only the samples used to estimate the coupling can
1394
- be transported from a domain to another one.
1395
- metric : string, optional (default="sqeuclidean")
1396
- The ground metric for the Wasserstein problem
1397
- norm : string, optional (default=None)
1398
- If given, normalize the ground metric to avoid numerical errors that
1399
- can occur with large metric values.
1400
- distribution : string, optional (default="uniform")
1401
- The kind of distribution estimation to employ
1402
1390
max_iter : int, float, optional (default=10)
1403
1391
The minimum number of iteration before stopping the optimization
1404
1392
algorithm if no it has not converged
1405
1393
max_inner_iter : int, float, optional (default=200)
1406
1394
The number of iteration in the inner loop
1407
- verbose : int, optional (default=0)
1395
+ log : bool, optional (default=False)
1396
+ Controls the logs of the optimization algorithm
1397
+ tol : float, optional (default=10e-9)
1398
+ Stop threshold on error (inner sinkhorn solver) (>0)
1399
+ verbose : bool, optional (default=False)
1408
1400
Controls the verbosity of the optimization algorithm
1401
+ metric : string, optional (default="sqeuclidean")
1402
+ The ground metric for the Wasserstein problem
1403
+ norm : string, optional (default=None)
1404
+ If given, normalize the ground metric to avoid numerical errors that
1405
+ can occur with large metric values.
1406
+ distribution_estimation : callable, optional (defaults to the uniform)
1407
+ The kind of distribution estimation to employ
1408
+ out_of_sample_map : string, optional (default="ferradans")
1409
+ The kind of out of sample mapping to apply to transport samples
1410
+ from a domain into another one. Currently the only possible option is
1411
+ "ferradans" which uses the method proposed in [6].
1409
1412
limit_max: float, optional (defaul=np.infty)
1410
1413
Controls the semi supervised mode. Transport between labeled source
1411
- and target samples of different classes will exhibit an infinite cost
1414
+ and target samples of different classes will exhibit a cost defined by
1415
+ limit_max.
1412
1416
1413
1417
Attributes
1414
1418
----------
@@ -1504,27 +1508,28 @@ class SinkhornL1l2Transport(BaseTransport):
1504
1508
Entropic regularization parameter
1505
1509
reg_cl : float, optional (default=0.1)
1506
1510
Class regularization parameter
1507
- mapping : string, optional (default="barycentric")
1508
- The kind of mapping to apply to transport samples from a domain into
1509
- another one.
1510
- if "barycentric" only the samples used to estimate the coupling can
1511
- be transported from a domain to another one.
1512
- metric : string, optional (default="sqeuclidean")
1513
- The ground metric for the Wasserstein problem
1514
- norm : string, optional (default=None)
1515
- If given, normalize the ground metric to avoid numerical errors that
1516
- can occur with large metric values.
1517
- distribution : string, optional (default="uniform")
1518
- The kind of distribution estimation to employ
1519
1511
max_iter : int, float, optional (default=10)
1520
1512
The minimum number of iteration before stopping the optimization
1521
1513
algorithm if no it has not converged
1522
1514
max_inner_iter : int, float, optional (default=200)
1523
1515
The number of iteration in the inner loop
1524
- verbose : int, optional (default=0)
1516
+ tol : float, optional (default=10e-9)
1517
+ Stop threshold on error (inner sinkhorn solver) (>0)
1518
+ verbose : bool, optional (default=False)
1525
1519
Controls the verbosity of the optimization algorithm
1526
- log : int , optional (default=0 )
1520
+ log : bool , optional (default=False )
1527
1521
Controls the logs of the optimization algorithm
1522
+ metric : string, optional (default="sqeuclidean")
1523
+ The ground metric for the Wasserstein problem
1524
+ norm : string, optional (default=None)
1525
+ If given, normalize the ground metric to avoid numerical errors that
1526
+ can occur with large metric values.
1527
+ distribution_estimation : callable, optional (defaults to the uniform)
1528
+ The kind of distribution estimation to employ
1529
+ out_of_sample_map : string, optional (default="ferradans")
1530
+ The kind of out of sample mapping to apply to transport samples
1531
+ from a domain into another one. Currently the only possible option is
1532
+ "ferradans" which uses the method proposed in [6].
1528
1533
limit_max: float, optional (default=10)
1529
1534
Controls the semi supervised mode. Transport between labeled source
1530
1535
and target samples of different classes will exhibit an infinite cost
@@ -1646,10 +1651,12 @@ class MappingTransport(BaseEstimator):
1646
1651
Max number of iterations (inner CG solver)
1647
1652
inner_tol : float, optional (default=1e-6)
1648
1653
Stop threshold on error (inner CG solver) (>0)
1649
- verbose : bool, optional (default=False)
1650
- Print information along iterations
1651
1654
log : bool, optional (default=False)
1652
1655
record log if True
1656
+ verbose : bool, optional (default=False)
1657
+ Print information along iterations
1658
+ verbose2 : bool, optional (default=False)
1659
+ Print information along iterations
1653
1660
1654
1661
Attributes
1655
1662
----------
0 commit comments