Spaces:
Runtime error
Runtime error
update
Browse files- ctc_eval.py +2 -3
ctc_eval.py
CHANGED
@@ -90,9 +90,8 @@ class CTC_Eval(evaluate.EvaluationModule):
|
|
90 |
def _compute(self, predictions, references):
|
91 |
"""Returns the scores"""
|
92 |
# TODO: Compute the different scores of the module
|
93 |
-
|
94 |
-
|
95 |
-
ctc_score = self.scorer.score(doc=references, refs=[], hypo=predictions, aspect='consistency')
|
96 |
return {
|
97 |
"ctc_score": ctc_score,
|
98 |
}
|
|
|
90 |
def _compute(self, predictions, references):
|
91 |
"""Returns the scores"""
|
92 |
# TODO: Compute the different scores of the module
|
93 |
+
assert len(predictions) == len(references)
|
94 |
+
ctc_score = self.scorer.score(doc=references[0], refs=[], hypo=predictions[0], aspect='consistency')
|
|
|
95 |
return {
|
96 |
"ctc_score": ctc_score,
|
97 |
}
|