djstrong commited on
Commit
0d4d8e0
1 Parent(s): 738a279
Files changed (1) hide show
  1. src/leaderboard/read_evals.py +5 -1
src/leaderboard/read_evals.py CHANGED
@@ -108,6 +108,7 @@ class EvalResult:
108
  def to_dict(self):
109
  """Converts the Eval Result to a dict compatible with our dataframe display"""
110
  average = sum([v for v in self.results.values() if v is not None]) / len(Tasks)
 
111
  data_dict={}
112
  # data_dict = {
113
  # "eval_name": self.eval_name, # not a column, just a save name,
@@ -198,7 +199,10 @@ class EvalResult:
198
 
199
 
200
  for task in Tasks:
201
- data_dict[task.value.col_name] = self.results[task.value.benchmark]
 
 
 
202
 
203
  return data_dict
204
 
 
108
  def to_dict(self):
109
  """Converts the Eval Result to a dict compatible with our dataframe display"""
110
  average = sum([v for v in self.results.values() if v is not None]) / len(Tasks)
111
+ print('average', average)
112
  data_dict={}
113
  # data_dict = {
114
  # "eval_name": self.eval_name, # not a column, just a save name,
 
199
 
200
 
201
  for task in Tasks:
202
+ try:
203
+ data_dict[task.value.col_name] = self.results[task.value.benchmark]
204
+ except KeyError:
205
+ print(f"Could not find {task.value.col_name}")
206
 
207
  return data_dict
208