From 854402c0de23b1cea11d8d4588a9dca096c8fcba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=A7=E9=A3=8E=E8=BD=A6=E6=BB=B4=E5=91=80=E6=BB=B4?= =?UTF-8?q?=E6=BA=9C=E6=BA=9C=E5=9C=B0=E8=BD=AC?= <45281765+koking0@users.noreply.github.com> Date: Sun, 10 Mar 2024 13:34:39 +0800 Subject: [PATCH] Update apps.py fix error: local variable 'level' referenced before assignment --- bigcode_eval/tasks/apps.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/bigcode_eval/tasks/apps.py b/bigcode_eval/tasks/apps.py index 9be6d242b..a338295cd 100644 --- a/bigcode_eval/tasks/apps.py +++ b/bigcode_eval/tasks/apps.py @@ -116,8 +116,6 @@ def process_results(self, generations, references): list of str containing refrences (not needed for APPS Task) """ code_metric = load("codeparrot/apps_metric") - if level is None: - level = self.DATASET_NAME results = code_metric.compute( predictions=generations, k_list=self.k_list, level=self.DATASET_NAME )