Since we are manipulating empirical probability distributions, p and q are vectors of probability masses
per samples in your distribution. Indeed, it is generally a common choice to consider them as equal
and set them as 1/(number of samples in the distribution).
Hope this helps,
I'm using OT package for GW, and I have a question regarding two arguments of the
What is p and q? I couldn't see them in the objective function of the GW.
p = ot.unif(n_samples)
q = ot.unif(n_samples)
gw0, log0 = ot.gromov.gromov_wasserstein(
C1, C2, p, q, 'square_loss', verbose=True, log=True)
gw, log = ot.gromov.entropic_gromov_wasserstein(
C1, C2, p, q, 'square_loss', epsilon=5e-4, log=True, verbose=True)
print('Gromov-Wasserstein distances: ' + str(log0['gw_dist']))
print('Entropic Gromov-Wasserstein distances: ' + str(log['gw_dist']))
POT mailing list -- email@example.com
To unsubscribe send an email to firstname.lastname@example.org://mail.python.org/mailman3/lists/pot.python.org/