Exporting ONMT embeddings

Is there a way to export ONMT embeddings to use/analyse them with some tools ?

It is possible with a small scripts to extract them from a saved model.

Let me know what format you expect as output. Or if you feel motivated, I could give you some pointers to write it yourself.

I’m not already a lua developer. This language is still a bit strange for me.

It would be nice to get a format that DL4J can import.

:slight_smile:

I need this too. I will write it.

My plan is to take in a model file and export two CSV files with the words in the GLoVE Format i.e.

“of 0.70853 0.57088 -0.4716 0.18048 0.54449…”

Let me know if this works for you.

1 Like

Yes !
:slight_smile:

I would also enjoy the pointers, to have a look… as far as I may understand the code. Sooner or later, I will have to really put my hand in lua.
:stuck_out_tongue:

https://github.com/OpenNMT/OpenNMT/pull/150/files

2 Likes