Created
December 20, 2022 17:56
-
-
Save piercelamb/8531abd0dea5bf232045727fb050d272 to your computer and use it in GitHub Desktop.
init_model_stats
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def init_model_stats(id2label): | |
return { | |
label: { | |
'total': 0, | |
'true_positives': 0, | |
'false_positives': 0, | |
'false_negatives': 0, | |
'accuracy': 0.0, | |
'f1': 0.0 | |
} | |
for label_id, label in id2label.items() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment