diff options
author | RĂ©mi Flamary <remi.flamary@gmail.com> | 2019-07-03 14:34:13 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-07-03 14:34:13 +0200 |
commit | 952503e02b1fc9bdf0811b937baacca57e4a98f1 (patch) | |
tree | c5b1b8f10eaee4c2ecaa12f629255489c2481590 /ot/lp/emd_wrap.pyx | |
parent | 8b3927bb5e8935c3dbddf054f054dc0c036fbdfe (diff) | |
parent | 7402d344240ce94e33c53daff419d4356278d48f (diff) |
Merge pull request #88 from rflamary/doc_modules
[MRG] Update documentation and add quick start guide
Diffstat (limited to 'ot/lp/emd_wrap.pyx')
-rw-r--r-- | ot/lp/emd_wrap.pyx | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/ot/lp/emd_wrap.pyx b/ot/lp/emd_wrap.pyx index 8a4aec9..2b6c495 100644 --- a/ot/lp/emd_wrap.pyx +++ b/ot/lp/emd_wrap.pyx @@ -58,13 +58,16 @@ def emd_c(np.ndarray[double, ndim=1, mode="c"] a, np.ndarray[double, ndim=1, mod - M is the metric cost matrix - a and b are the sample weights + .. warning:: + Note that the M matrix needs to be a C-order :py.cls:`numpy.array` + Parameters ---------- - a : (ns,) ndarray, float64 + a : (ns,) numpy.ndarray, float64 source histogram - b : (nt,) ndarray, float64 + b : (nt,) numpy.ndarray, float64 target histogram - M : (ns,nt) ndarray, float64 + M : (ns,nt) numpy.ndarray, float64 loss matrix max_iter : int The maximum number of iterations before stopping the optimization @@ -73,7 +76,7 @@ def emd_c(np.ndarray[double, ndim=1, mode="c"] a, np.ndarray[double, ndim=1, mod Returns ------- - gamma: (ns x nt) ndarray + gamma: (ns x nt) numpy.ndarray Optimal transportation matrix for the given parameters """ |