facebookresearch / MUSE

A library for Multilingual Unsupervised or Supervised word Embeddings
Other
3.18k stars 544 forks source link

how to mapping new embedding? #131

Open Nokeli opened 5 years ago

Nokeli commented 5 years ago

I trained chinese-english mapping.now,i have some new Chinese words,i want to map those word embeddings to english。How should i do and save those mapped Chinese word embeddings

sudoaza commented 4 years ago

This isn't explained anywhere that i could find, but when you train a language pair you end up with a 300x300 matrix that i believe transforms from one vector space to the other. Haven't yet tested but i think one needs to do a matrix multiplication between the vector in one space and the matrix to get the corresponding vector in the second space.