code quality fixes
Formatting Check / formatting-check (push) Successful in 9s
Python Code Quality / python-code-quality (push) Successful in 18s
Python Test / python-test (push) Successful in 30s
Sync Label Studio Annotations / sync_storage (push) Successful in 57s

This commit is contained in:
Brian Bjarke Jensen
2025-09-26 00:02:02 +02:00
parent d804cc4a13
commit 007161a927
+4 -3
View File
@@ -278,7 +278,6 @@ if __name__ == "__main__":
experiment = mlflow.get_experiment_by_name("visual-semiotic-ai-analysis")
experiment_id = experiment.experiment_id if experiment else None
# Calculate accuracy
category_events = {}
for category, initial_prompt in CATEGORY_PROMPT_MAP.items():
step = 0
run = mlflow.start_run(
@@ -309,8 +308,10 @@ if __name__ == "__main__":
continue
try:
# Calculate accuracy for refined prompt
accuracy = calculate_model_prompt_accuracy(MODEL, refined_prompt, category)
mlflow.log_metric(f"accuracy", accuracy, step=step)
accuracy = calculate_model_prompt_accuracy(
MODEL, refined_prompt, category
)
mlflow.log_metric("accuracy", accuracy, step=step)
except Exception as e:
print(f"Error calculating accuracy: {e}")
continue