OpenNMT / OpenNMT/CTranslate2

Error when converting NMT model with ALiBi or RoPe

Open
#1,657 15 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement question
Dominant language
C++
Stars
4.7k
Forks
536
Avg merge
12h 12m
Merged PRs (30d)
4

Description

Hello, thank you for a great project!

I am getting this error when using ALiBi or RoPe positional encoding in a tranformer NMT model from OpenNMT-py:

KeyError: 'encoder.embeddings.make_embedding.pe.pe'

Absolute and relative positional encodings are working with the converter script.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the converter script and reproduce conversion of an OpenNMT-py Transformer NMT model using ALiBi or RoPe positional encoding. Compare this path with the working absolute and relative positional encodings, and trace the reported KeyError for encoder.embeddings.make_embedding.pe.pe. Done means the affected models convert without that error.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, python
Domain
machine-learning, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.