From a0e46871e6be9cfa4af4f5a8b6fa2e6eb41cf67f Mon Sep 17 00:00:00 2001 From: Connor Olding Date: Fri, 19 May 2023 20:56:03 -0700 Subject: [PATCH] add option to scoring to return values before averaging --- thursday/utilities/scoring.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/thursday/utilities/scoring.py b/thursday/utilities/scoring.py index c7a1ddf..c5c5481 100644 --- a/thursday/utilities/scoring.py +++ b/thursday/utilities/scoring.py @@ -29,7 +29,7 @@ def prune_results(results, multiple, _check=False): return results -def perform_another_experimental_scoring_method(results): +def perform_another_experimental_scoring_method(results, many_raw=False): if len(results) and len(something := next(iter(results.values()))[0]) == 3: history_length = len(something[2]) each = {} @@ -39,7 +39,7 @@ def perform_another_experimental_scoring_method(results): l = {k: [(res[2][i], res[1]) for res in v] for k, v in results.items()} for k, v in perform_another_experimental_scoring_method(l).items(): each.setdefault(k, []).append(v) - return {k: sum(v) / len(v) for k, v in each.items()} + return each if many_raw else {k: sum(v) / len(v) for k, v in each.items()} new_results = {} all_opt_names = set()