Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -307,7 +307,10 @@ def _discover_checkpoints() -> list[str]:
|
|
| 307 |
paths.append(p)
|
| 308 |
# Also accept HF / user-provided paths via manual input
|
| 309 |
if not paths:
|
| 310 |
-
return [
|
|
|
|
|
|
|
|
|
|
| 311 |
return sorted(paths)
|
| 312 |
|
| 313 |
|
|
@@ -1205,15 +1208,21 @@ def run_inference(
|
|
| 1205 |
"max_tokens_per_instance": int(max_tokens),
|
| 1206 |
"window_measures": window_measures,
|
| 1207 |
"hop_measures": int(hop_measures),
|
| 1208 |
-
"attention_entropy":
|
| 1209 |
-
|
| 1210 |
-
|
| 1211 |
-
|
| 1212 |
-
|
| 1213 |
-
|
| 1214 |
-
|
| 1215 |
-
|
| 1216 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1217 |
}
|
| 1218 |
|
| 1219 |
summary_md = (
|
|
|
|
| 307 |
paths.append(p)
|
| 308 |
# Also accept HF / user-provided paths via manual input
|
| 309 |
if not paths:
|
| 310 |
+
return [
|
| 311 |
+
"JacobLinCool/TaikoChartEstimator-20251228",
|
| 312 |
+
"JacobLinCool/TaikoChartEstimator-20251229",
|
| 313 |
+
]
|
| 314 |
return sorted(paths)
|
| 315 |
|
| 316 |
|
|
|
|
| 1208 |
"max_tokens_per_instance": int(max_tokens),
|
| 1209 |
"window_measures": window_measures,
|
| 1210 |
"hop_measures": int(hop_measures),
|
| 1211 |
+
"attention_entropy": (
|
| 1212 |
+
float(attn.get("entropy")[0].item())
|
| 1213 |
+
if attn.get("entropy") is not None
|
| 1214 |
+
else None
|
| 1215 |
+
),
|
| 1216 |
+
"attention_effective_n": (
|
| 1217 |
+
float(attn.get("effective_n")[0].item())
|
| 1218 |
+
if attn.get("effective_n") is not None
|
| 1219 |
+
else None
|
| 1220 |
+
),
|
| 1221 |
+
"attention_top5_mass": (
|
| 1222 |
+
float(attn.get("top5_mass")[0].item())
|
| 1223 |
+
if attn.get("top5_mass") is not None
|
| 1224 |
+
else None
|
| 1225 |
+
),
|
| 1226 |
}
|
| 1227 |
|
| 1228 |
summary_md = (
|