Fixed log messages that are resulting in TypeError due to too many arguments (#32017)

* Fixed log messages that are resulting in TypeErrors due to too many arguments.

* Removed un-necessary imports.
This commit is contained in:
Sai-Suraj-27
2024-07-17 15:26:44 +05:30
committed by GitHub
parent 691586b0dc
commit 72fb02c47d
10 changed files with 12 additions and 14 deletions

View File

@@ -417,7 +417,7 @@ def main():
label_to_id = {l: i for i, l in enumerate(label_list)}
else:
logger.warning(
"Your model seems to have been trained with labels, but they don't match the dataset: ",
"Your model seems to have been trained with labels, but they don't match the dataset: "
f"model labels: {sorted(model.config.label2id.keys())}, dataset labels:"
f" {sorted(label_list)}.\nIgnoring the model labels as a result.",
)