diff options
author | Kilian Fatras <kilianfatras@dhcp-206-12-53-92.eduroam.wireless.ubc.ca> | 2018-06-21 17:41:25 -0700 |
---|---|---|
committer | Kilian Fatras <kilianfatras@dhcp-206-12-53-92.eduroam.wireless.ubc.ca> | 2018-06-21 17:41:25 -0700 |
commit | af5f726f6adb52457ca6730ffb85f2ab486b2ada (patch) | |
tree | 0e593ff136138718a6754f57263b442fd80cf2db /ot/stochastic.py | |
parent | 6777ffd5c8457faac4467e58ba9edbcf2f86961b (diff) |
fixed bug
Diffstat (limited to 'ot/stochastic.py')
-rw-r--r-- | ot/stochastic.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ot/stochastic.py b/ot/stochastic.py index ab88cd0..374d1a5 100644 --- a/ot/stochastic.py +++ b/ot/stochastic.py @@ -153,7 +153,7 @@ def sag_entropic_transport(a, b, M, reg, numItermax=10000, lr=None): ''' if lr is None: - lr = 1. / max(a) + lr = 1. / max(a/reg) n_source = np.shape(M)[0] n_target = np.shape(M)[1] cur_beta = np.zeros(n_target) @@ -238,7 +238,7 @@ def averaged_sgd_entropic_transport(a, b, M, reg, numItermax=300000, lr=None): ''' if lr is None: - lr = 1. / max(a) + lr = 1. / max(a/reg) n_source = np.shape(M)[0] n_target = np.shape(M)[1] cur_beta = np.zeros(n_target) |