clbonet / Hyperbolic_Sliced-Wasserstein_via_Geodesic_and_Horospherical_Projections

Implementation of our TAGML2023 paper "Hyperbolic Sliced-Wasserstein via Geodesic and Horospherical Projections"
5 stars 0 forks source link

About Loss Function #1

Open lsyysl9711 opened 11 months ago

lsyysl9711 commented 11 months ago

Hi, your work is great!

But I have some questions regarding to loss function.

For example in the attached picture, the matrix M is a matrix on hyperbolic but ot.emd2 and ot.sinkhorn2 are Euclidean based metric. So I would like to know whether sending a hyperbolic matrix into Euclidean metric makes sense?

Thanks!

c573b2d3de4296e2382a3df2594804a

clbonet commented 11 months ago

Hi! Thank you for your interest in our work.

The solvers from POT can take any cost matrix and solve the corresponding OT problem (either a LP for ot.emd2 or sinkhorn for the entropically regularized problem). Thus, if we want to solve the OT problem on Hyperbolic spaces, we just need to plug the right groundcost matrix M into the corresponding solvers.

lsyysl9711 commented 11 months ago

Thanks for replying me! I still have one question

The cost matrix M is located in hyperbolic space. I check the source codes of ot.emd2 and ot.sinkhorn2 and I find that the arithmetic operations used in these two APIs are totally Euclidean based. For example, in the attached picture, the sinkhorn method is divided by a term and applied by exp function. But M is a hyperbolic matrix, so I don't think this is a legal operation.

Thanks!

c940f413a4807c0a04f66eb67189dac

clbonet commented 11 months ago

These two solvers aim at finding the optimal coupling matrix, which is a matrix with constraints on the sum of the rows and on the sums of the columns to have the right marginals. The operations of these solvers are on this coupling matrix, and are therefore Euclidean, and can work with any cost matrix M.