workflows.utils.record_scores.validate_overall_scores#

workflows.utils.record_scores.validate_overall_scores(overall_scores)#

Given a dictionary of overall scores (see load_overall_scores()), the following are validated:

  • There is a score for every test set.

  • Each score is parsable as a float.

Otherwise, a ValueError is raised.

Parameters:

overall_scores (dict) – A dictionary from test set filenames (excluding file extensions) to strings representing scores.

Returns:

Boolean for whether overall_scores is valid or not, and a string for an error message.

Return type:

bool, str