Giter Site home page Giter Site logo

Comments (7)

trenous avatar trenous commented on August 20, 2024 1

If you share the full stack trace and the config file you used, we might also be able to help.

from openkiwi.

captainvera avatar captainvera commented on August 20, 2024

Hello @BigBorg!

Can you provide a reproducible example using public data?
Ideally, a config and a small dataset that encountered this error would be amazing.

I would love to help, but it's hard to diagnose if I can't reproduce the issue :)

from openkiwi.

BigBorg avatar BigBorg commented on August 20, 2024

Sorry the dataset is private. I might try some public dataset to see if this happens again.

from openkiwi.

BigBorg avatar BigBorg commented on August 20, 2024

Sending codes out from the company i work for is restricted. Turning off sentence-ll solves the problem. Is it possible that the error is 0 then becomes inf after log? Besides, sentence scores produced by the model might be larger than 1, how do I interpret score?

from openkiwi.

captainvera avatar captainvera commented on August 20, 2024

Understandable. It could indeed be the case, but it seems weird that we never encountered this error while training with our own data or with publicly available datasets... If the reason becomes clearer, please let us know.

On the second question, sentence scores are an attempt to predict TER (Translation Error Rate), or the distance that separates the current translation from a "perfect" translation. With 1 meaning the whole sentence needs to be changed and 0 meaning the sentence is correct.

The model shouldn't produce scores above 1, what kind of scores are you seeing? Are you sure your training data contains all TER values in the range [0-1]?

from openkiwi.

BigBorg avatar BigBorg commented on August 20, 2024

Thanks for reminding me to inspect training data. It does contain hter larger than 1. I don't know why tercom is producing such result. I might try python package pyter to generate hter.

from openkiwi.

trenous avatar trenous commented on August 20, 2024

Tercom computes hter as
(Edit Distance mt - pe ) / (len(pe))

Thus if the MT is longer than the postedition, you can have an hter longer than 1 (this will typically be a case of MT repetitions / hallucinations). In the QE shared task, the scores are truncated to be at most 1.

The sentence-scores output by the model can be greater than 1 if you turn off sentence-ll.
As you can see in the code, the sentence score prediction module does not have a squashing function in the last layer.
If you enable sentence-ll, the model outputs a gaussian distribution that is truncated over the interval [0, 1]. In that case, model scores are the mean of that distribution, which will always lie within the interval itself.

from openkiwi.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.