Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
disable not working filters
Browse files- app.py +3 -0
- src/leaderboard/read_evals.py +17 -0
app.py
CHANGED
@@ -189,6 +189,7 @@ with demo:
|
|
189 |
value=[t.to_str() for t in ModelType],
|
190 |
interactive=True,
|
191 |
elem_id="filter-columns-type",
|
|
|
192 |
)
|
193 |
filter_columns_precision = gr.CheckboxGroup(
|
194 |
label="Precision",
|
@@ -196,6 +197,7 @@ with demo:
|
|
196 |
value=[i.value.name for i in Precision],
|
197 |
interactive=True,
|
198 |
elem_id="filter-columns-precision",
|
|
|
199 |
)
|
200 |
filter_columns_size = gr.CheckboxGroup(
|
201 |
label="Model sizes (in billions of parameters)",
|
@@ -203,6 +205,7 @@ with demo:
|
|
203 |
value=list(NUMERIC_INTERVALS.keys()),
|
204 |
interactive=True,
|
205 |
elem_id="filter-columns-size",
|
|
|
206 |
)
|
207 |
filter_columns_nshot = gr.CheckboxGroup(
|
208 |
label="N-shot",
|
|
|
189 |
value=[t.to_str() for t in ModelType],
|
190 |
interactive=True,
|
191 |
elem_id="filter-columns-type",
|
192 |
+
visible=False,
|
193 |
)
|
194 |
filter_columns_precision = gr.CheckboxGroup(
|
195 |
label="Precision",
|
|
|
197 |
value=[i.value.name for i in Precision],
|
198 |
interactive=True,
|
199 |
elem_id="filter-columns-precision",
|
200 |
+
visible=False,
|
201 |
)
|
202 |
filter_columns_size = gr.CheckboxGroup(
|
203 |
label="Model sizes (in billions of parameters)",
|
|
|
205 |
value=list(NUMERIC_INTERVALS.keys()),
|
206 |
interactive=True,
|
207 |
elem_id="filter-columns-size",
|
208 |
+
visible=False,
|
209 |
)
|
210 |
filter_columns_nshot = gr.CheckboxGroup(
|
211 |
label="N-shot",
|
src/leaderboard/read_evals.py
CHANGED
@@ -141,16 +141,21 @@ class EvalResult:
|
|
141 |
data_dict[AutoEvalColumn.precision.name] = self.precision.value.name
|
142 |
except KeyError:
|
143 |
print(f"Could not find precision")
|
|
|
|
|
144 |
|
145 |
try:
|
146 |
data_dict[AutoEvalColumn.model_type.name] = self.model_type.value.name
|
147 |
except KeyError:
|
148 |
print(f"Could not find model type")
|
149 |
|
|
|
150 |
try:
|
151 |
data_dict[AutoEvalColumn.model_type_symbol.name] = self.model_type.value.symbol
|
152 |
except KeyError:
|
153 |
print(f"Could not find model type symbol")
|
|
|
|
|
154 |
|
155 |
try:
|
156 |
data_dict[AutoEvalColumn.weight_type.name] = self.weight_type.value.name
|
@@ -161,6 +166,8 @@ class EvalResult:
|
|
161 |
data_dict[AutoEvalColumn.architecture.name] = self.architecture
|
162 |
except KeyError:
|
163 |
print(f"Could not find architecture")
|
|
|
|
|
164 |
|
165 |
try:
|
166 |
data_dict[AutoEvalColumn.model.name] = make_clickable_model(self.full_model) if self.still_on_hub else self.full_model
|
@@ -176,6 +183,8 @@ class EvalResult:
|
|
176 |
data_dict[AutoEvalColumn.revision.name] = self.revision
|
177 |
except KeyError:
|
178 |
print(f"Could not find revision")
|
|
|
|
|
179 |
|
180 |
try:
|
181 |
data_dict[AutoEvalColumn.average.name] = average
|
@@ -186,21 +195,29 @@ class EvalResult:
|
|
186 |
data_dict[AutoEvalColumn.license.name] = self.license
|
187 |
except KeyError:
|
188 |
print(f"Could not find license")
|
|
|
|
|
189 |
|
190 |
try:
|
191 |
data_dict[AutoEvalColumn.likes.name] = self.likes
|
192 |
except KeyError:
|
193 |
print(f"Could not find likes")
|
|
|
|
|
194 |
|
195 |
try:
|
196 |
data_dict[AutoEvalColumn.params.name] = self.num_params
|
197 |
except KeyError:
|
198 |
print(f"Could not find params")
|
|
|
|
|
199 |
|
200 |
try:
|
201 |
data_dict[AutoEvalColumn.still_on_hub.name] = self.still_on_hub
|
202 |
except KeyError:
|
203 |
print(f"Could not find still on hub")
|
|
|
|
|
204 |
|
205 |
try:
|
206 |
data_dict[AutoEvalColumn.n_shot.name] = self.n_shot.value.name
|
|
|
141 |
data_dict[AutoEvalColumn.precision.name] = self.precision.value.name
|
142 |
except KeyError:
|
143 |
print(f"Could not find precision")
|
144 |
+
except AttributeError:
|
145 |
+
print(f"AttributeError precision")
|
146 |
|
147 |
try:
|
148 |
data_dict[AutoEvalColumn.model_type.name] = self.model_type.value.name
|
149 |
except KeyError:
|
150 |
print(f"Could not find model type")
|
151 |
|
152 |
+
|
153 |
try:
|
154 |
data_dict[AutoEvalColumn.model_type_symbol.name] = self.model_type.value.symbol
|
155 |
except KeyError:
|
156 |
print(f"Could not find model type symbol")
|
157 |
+
except AttributeError:
|
158 |
+
print(f"AttributeError model_type")
|
159 |
|
160 |
try:
|
161 |
data_dict[AutoEvalColumn.weight_type.name] = self.weight_type.value.name
|
|
|
166 |
data_dict[AutoEvalColumn.architecture.name] = self.architecture
|
167 |
except KeyError:
|
168 |
print(f"Could not find architecture")
|
169 |
+
except AttributeError:
|
170 |
+
print(f"AttributeError architecture")
|
171 |
|
172 |
try:
|
173 |
data_dict[AutoEvalColumn.model.name] = make_clickable_model(self.full_model) if self.still_on_hub else self.full_model
|
|
|
183 |
data_dict[AutoEvalColumn.revision.name] = self.revision
|
184 |
except KeyError:
|
185 |
print(f"Could not find revision")
|
186 |
+
except AttributeError:
|
187 |
+
print(f"AttributeError revision")
|
188 |
|
189 |
try:
|
190 |
data_dict[AutoEvalColumn.average.name] = average
|
|
|
195 |
data_dict[AutoEvalColumn.license.name] = self.license
|
196 |
except KeyError:
|
197 |
print(f"Could not find license")
|
198 |
+
except AttributeError:
|
199 |
+
print(f"AttributeError license")
|
200 |
|
201 |
try:
|
202 |
data_dict[AutoEvalColumn.likes.name] = self.likes
|
203 |
except KeyError:
|
204 |
print(f"Could not find likes")
|
205 |
+
except AttributeError:
|
206 |
+
print(f"AttributeError likes")
|
207 |
|
208 |
try:
|
209 |
data_dict[AutoEvalColumn.params.name] = self.num_params
|
210 |
except KeyError:
|
211 |
print(f"Could not find params")
|
212 |
+
except AttributeError:
|
213 |
+
print(f"AttributeError params")
|
214 |
|
215 |
try:
|
216 |
data_dict[AutoEvalColumn.still_on_hub.name] = self.still_on_hub
|
217 |
except KeyError:
|
218 |
print(f"Could not find still on hub")
|
219 |
+
except AttributeError:
|
220 |
+
print(f"AttributeError stillonhub")
|
221 |
|
222 |
try:
|
223 |
data_dict[AutoEvalColumn.n_shot.name] = self.n_shot.value.name
|