Spaces:
Restarting
on
CPU Upgrade
Restarting
on
CPU Upgrade
simplify model names
Browse files
src/leaderboard/read_evals.py
CHANGED
@@ -2,6 +2,7 @@ import glob
|
|
2 |
import json
|
3 |
import math
|
4 |
import os
|
|
|
5 |
from dataclasses import dataclass
|
6 |
|
7 |
import dateutil
|
@@ -43,6 +44,7 @@ class EvalResult:
|
|
43 |
|
44 |
# Get model and org
|
45 |
org_and_model = config.get("model_name", config.get("model_args", None))
|
|
|
46 |
org_and_model = org_and_model.split("/", 1)
|
47 |
|
48 |
if len(org_and_model) == 1:
|
|
|
2 |
import json
|
3 |
import math
|
4 |
import os
|
5 |
+
import re
|
6 |
from dataclasses import dataclass
|
7 |
|
8 |
import dateutil
|
|
|
44 |
|
45 |
# Get model and org
|
46 |
org_and_model = config.get("model_name", config.get("model_args", None))
|
47 |
+
org_and_model = re.sub(r"^pretrained=(.*/(plgkwrobel|plggspkl)/)?(models/)?", "", org_and_model)
|
48 |
org_and_model = org_and_model.split("/", 1)
|
49 |
|
50 |
if len(org_and_model) == 1:
|