Calculate TER using Pyter3

Hi eveyone,

Currently, I am using decoding feature(alternative at position) of ctranslate2 model. After getting the translation from ctranslate, I want to calculate the TER (translation edit rate) score by compare the resulted translations. For this purpose, I am using Pyter library and it is working fine but the response is very long e.g when translation contains very long sentence then it takes long time (aroud 5-7 mints).

Could anyboday suggest how i can get rid of this problem. I search a lot but did not find the solution of this problem.
I am would be thankful.

Thank you.


You can try computing TER with SacreBLEU:

But if there are performance issues, you should probably raise it directly to the package authors.

I had a few performance issues with TER quite some time ago. IIRC, the most efficient at the time was the lua re-implementation of tercom from OpenNMT(lua).