sidak / context-mover-distance-and-barycenters

Code accompanying our paper at AISTATS 2020
21 stars 1 forks source link

What is the "meaningful metric Gg" used in computing CMD of two word? #2

Closed heslowen closed 4 years ago

heslowen commented 5 years ago

In paper image

How to choose image ? Another way,when I get two word embeddings(e.g. both 200 dimension vector), how can I get the matrix M? image

Thx!!!~~~

sidak commented 4 years ago

You can use L2 distance or angular distance or something of your own choice as well. See https://github.com/context-mover/context-mover-distance-and-barycenters/blob/master/wasserstein.py#L402 for the corresponding code.