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
0d663b6b
Unverified
Commit
0d663b6b
authored
Mar 27, 2021
by
Leo Gao
Committed by
GitHub
Mar 27, 2021
Browse files
Update write_out.py
parent
c445e56b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
scripts/write_out.py
scripts/write_out.py
+3
-3
No files found.
scripts/write_out.py
View file @
0d663b6b
...
@@ -15,7 +15,7 @@ def parse_args():
...
@@ -15,7 +15,7 @@ def parse_args():
parser
.
add_argument
(
'--provide_description'
,
action
=
"store_true"
)
parser
.
add_argument
(
'--provide_description'
,
action
=
"store_true"
)
parser
.
add_argument
(
'--sets'
,
type
=
str
,
default
=
"val"
)
# example: val,test
parser
.
add_argument
(
'--sets'
,
type
=
str
,
default
=
"val"
)
# example: val,test
parser
.
add_argument
(
'--num_fewshot'
,
type
=
int
,
default
=
1
)
parser
.
add_argument
(
'--num_fewshot'
,
type
=
int
,
default
=
1
)
parser
.
add_argument
(
'--seed'
,
type
=
int
,
default
=
123
4
)
parser
.
add_argument
(
'--seed'
,
type
=
int
,
default
=
4
2
)
parser
.
add_argument
(
'--num_examples'
,
type
=
int
,
default
=
1
)
parser
.
add_argument
(
'--num_examples'
,
type
=
int
,
default
=
1
)
return
parser
.
parse_args
()
return
parser
.
parse_args
()
...
@@ -23,8 +23,6 @@ def parse_args():
...
@@ -23,8 +23,6 @@ def parse_args():
def
main
():
def
main
():
args
=
parse_args
()
args
=
parse_args
()
np
.
random
.
seed
(
args
.
seed
)
np
.
random
.
seed
(
args
.
seed
)
rnd
=
random
.
Random
()
rnd
.
seed
(
args
.
seed
)
if
args
.
tasks
==
"all_tasks"
:
if
args
.
tasks
==
"all_tasks"
:
task_names
=
tasks
.
ALL_TASKS
task_names
=
tasks
.
ALL_TASKS
...
@@ -33,6 +31,8 @@ def main():
...
@@ -33,6 +31,8 @@ def main():
task_dict
=
tasks
.
get_task_dict
(
task_names
)
task_dict
=
tasks
.
get_task_dict
(
task_names
)
os
.
makedirs
(
args
.
output_base_path
,
exist_ok
=
True
)
os
.
makedirs
(
args
.
output_base_path
,
exist_ok
=
True
)
for
task_name
,
task
in
task_dict
.
items
():
for
task_name
,
task
in
task_dict
.
items
():
rnd
=
random
.
Random
()
rnd
.
seed
(
args
.
seed
)
iters
=
[]
iters
=
[]
...
...
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