Help Needed: Converting OpenNMT Model to Hugging Face Format

I’ve trained a model using OpenNMT-py (version 2.2.0) and saved it as a .pt file. I’m now looking to convert this model into a Hugging Face format, so I can use it within the Hugging Face Transformers library.

Has anyone successfully done this kind of conversion, or are there any tools/methods recommended to map the weights from an OpenNMT model to a compatible Hugging Face model? I’d appreciate any guidance or advice on how to approach this.

Thank you!

1 Like

It seems that other people who have asked about it have been told that it’s impossible…
Is it that special a format…?:thinking: