From a73025f08247cada2f7cb2f0662d463f94b2acc5 Mon Sep 17 00:00:00 2001 From: Felix Ocker Date: Mon, 19 Aug 2024 21:29:07 +0200 Subject: [PATCH] fix(log_analysis): plot file extension --- src/eval/math_eval/log_analysis.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/eval/math_eval/log_analysis.py b/src/eval/math_eval/log_analysis.py index 63a158d..50a74ee 100644 --- a/src/eval/math_eval/log_analysis.py +++ b/src/eval/math_eval/log_analysis.py @@ -799,9 +799,9 @@ def sanity_check_results( print(f"{agent}: {mean_val:.4f} {relative_val:.4f} {values}") if benchmark_type == "math": - img_name = "_".join(ln[:-3] for ln in log_names) + "_math_bench.png" + img_name = "_".join(ln[:-4] for ln in log_names) + "_math_bench.png" elif benchmark_type in ("custom", "reduced"): - img_name = log_name[:-3] + ".png" + img_name = log_name[:-4] + ".png" else: raise ValueError(f"Unknown benchmark type `{benchmark_type}`.") shutil.copy("math.eval.png", f"{log_folder}/{img_name}")