MCPcopy Create free account
hub / github.com/OrangeInSouth/DeePEn / is_correct

Function is_correct

utils/evaluate/utils/eval_utils.py:65–72  ·  view source on GitHub ↗
(answers, prediction,
               is_regex)

Source from the content-addressed store, hash-verified

63
64
65def is_correct(answers, prediction,
66 is_regex):
67 if is_regex:
68 metric_fn = regex_match_score
69 else:
70 metric_fn = exact_match_score
71 return metric_max_over_ground_truths(
72 metric_fn=metric_fn, prediction=prediction, ground_truths=answers)
73
74
75def evaluate_predictions_impl(references,

Callers 1

Calls 1

Tested by

no test coverage detected