Spaces:
Running
Running
Update evaluation/evaluator.py
Browse files- evaluation/evaluator.py +1 -1
evaluation/evaluator.py
CHANGED
@@ -98,7 +98,7 @@ def question_scorer(prediction, gold_answer):
|
|
98 |
prediction, run_eval = fix_prediction(prediction, gold_answer, evaluator)
|
99 |
|
100 |
has_ans = 1.
|
101 |
-
if ((prediction) != float and len(prediction) == 0) or find_isnan(prediction):
|
102 |
has_ans = 0.
|
103 |
|
104 |
if not run_eval:
|
|
|
98 |
prediction, run_eval = fix_prediction(prediction, gold_answer, evaluator)
|
99 |
|
100 |
has_ans = 1.
|
101 |
+
if (type(prediction) != float and len(prediction) == 0) or find_isnan(prediction):
|
102 |
has_ans = 0.
|
103 |
|
104 |
if not run_eval:
|