From 2ab408e2d6f194edcdeba287d5ece2a9006d7703 Mon Sep 17 00:00:00 2001 From: SzymonOzog Date: Sun, 27 Jul 2025 08:46:54 -0700 Subject: [PATCH] Run categories in parallel --- eval/eval.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/eval/eval.py b/eval/eval.py index 6cbd3b83..e5fe01ad 100755 --- a/eval/eval.py +++ b/eval/eval.py @@ -657,11 +657,11 @@ class AsyncModelEvaluator: # Process each category sequentially to ensure proper checkpointing category_results = [] - for category in self.config.categories: - category_result = await self.evaluate_category(category) - category_results.append(category_result) + tasks = [asyncio.create_task(self.evaluate_category(category)) for category in self.config.categories] - # Update partial summary after each category + for finished_task in asyncio.as_completed(tasks): + result = await finished_task + category_results.append(result) self._update_partial_summary(category_results) # Generate results structure