Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Update src/leaderboard/read_evals.py
Browse files
src/leaderboard/read_evals.py
CHANGED
@@ -33,7 +33,7 @@ class EvalResult:
|
|
33 |
num_params: int = 0
|
34 |
date: str = "" # submission date of request file
|
35 |
still_on_hub: bool = False
|
36 |
-
num_few_shots:
|
37 |
|
38 |
@classmethod
|
39 |
def init_from_json_file(self, json_filepath):
|
@@ -52,7 +52,7 @@ class EvalResult:
|
|
52 |
print("model_type", model_type)
|
53 |
|
54 |
# Get num_few_shots from metainfo
|
55 |
-
num_few_shots =
|
56 |
|
57 |
# Precision
|
58 |
# precision = Precision.from_str(config.get("dtype"))
|
@@ -217,4 +217,4 @@ def get_raw_eval_results(results_path: str, requests_path: str) -> list[EvalResu
|
|
217 |
except KeyError: # not all eval values present
|
218 |
continue
|
219 |
|
220 |
-
return results
|
|
|
33 |
num_params: int = 0
|
34 |
date: str = "" # submission date of request file
|
35 |
still_on_hub: bool = False
|
36 |
+
num_few_shots: int = 0
|
37 |
|
38 |
@classmethod
|
39 |
def init_from_json_file(self, json_filepath):
|
|
|
52 |
print("model_type", model_type)
|
53 |
|
54 |
# Get num_few_shots from metainfo
|
55 |
+
num_few_shots = metainfo.get("num_few_shots", 0)
|
56 |
|
57 |
# Precision
|
58 |
# precision = Precision.from_str(config.get("dtype"))
|
|
|
217 |
except KeyError: # not all eval values present
|
218 |
continue
|
219 |
|
220 |
+
return results
|