Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
lm-evaluation-harness
Commits
cdc1d8ec
Commit
cdc1d8ec
authored
Feb 20, 2024
by
haileyschoelkopf
Browse files
cleanup
parent
ceaef430
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
22 deletions
+2
-22
scripts/make_table_tasks.py
scripts/make_table_tasks.py
+2
-22
No files found.
scripts/make_table_tasks.py
View file @
cdc1d8ec
...
@@ -67,6 +67,8 @@ def check(tf):
...
@@ -67,6 +67,8 @@ def check(tf):
def
maketable
(
df
):
def
maketable
(
df
):
headers
=
[
headers
=
[
# For now, we restrict to presenting data
# That can be collected statically.
"Task Name"
,
"Task Name"
,
"Group"
,
"Group"
,
# "Train",
# "Train",
...
@@ -85,20 +87,6 @@ def maketable(df):
...
@@ -85,20 +87,6 @@ def maketable(df):
# _tasks = [(x, task_manager.load_task_or_group(x)) for x in task_classes]
# _tasks = [(x, task_manager.load_task_or_group(x)) for x in task_classes]
# count = 0
# count = 0
for
tname
in
tqdm
(
_tasks
):
for
tname
in
tqdm
(
_tasks
):
print
(
tname
)
# try:
# if not tname in ["advanced_ai_risk", "arithmetic", "bbh_fewshot", "bbh_cot_fewshot", "bbh_cot_zeroshot"]:
# task = task_manager.load_task_or_group(tname)
# else:
# continue
# if isinstance(list(task.values())[0], tuple): # is group, not a solo task
# del task
# continue
# else:
# task = task[tname]
# # except Exception as e:
# # print(e)
# # continue
task_config
=
task_manager
.
_get_config
(
tname
)
task_config
=
task_manager
.
_get_config
(
tname
)
if
not
task_config
:
if
not
task_config
:
continue
continue
...
@@ -110,10 +98,6 @@ def maketable(df):
...
@@ -110,10 +98,6 @@ def maketable(df):
v
=
[
v
=
[
tname
,
tname
,
task_config
.
get
(
"group"
,
None
),
task_config
.
get
(
"group"
,
None
),
# check(True),
# check(True),
# check(True),
# -1,
task_config
.
get
(
"output_type"
,
"greedy_until"
),
task_config
.
get
(
"output_type"
,
"greedy_until"
),
", "
.
join
(
", "
.
join
(
str
(
f
[
"name"
])
str
(
f
[
"name"
])
...
@@ -141,11 +125,7 @@ def maketable(df):
...
@@ -141,11 +125,7 @@ def maketable(df):
# ]
# ]
logger
.
info
(
v
)
logger
.
info
(
v
)
values
.
append
(
v
)
values
.
append
(
v
)
# count += 1
# if count >= 20:
# break
# del task
if
df
is
None
:
if
df
is
None
:
df
=
pd
.
DataFrame
(
values
,
columns
=
headers
)
df
=
pd
.
DataFrame
(
values
,
columns
=
headers
)
table
=
df
.
to_markdown
(
index
=
False
)
table
=
df
.
to_markdown
(
index
=
False
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment