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
777f57ce
"include/ck/ck.hpp" did not exist on "81c942cd7e198b46f55be31451d51f27459d34ab"
Commit
777f57ce
authored
Jul 17, 2023
by
haileyschoelkopf
Browse files
add comments to all vars defined in evaluate()
parent
9a4e7e7f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
5 deletions
+10
-5
lm_eval/evaluator.py
lm_eval/evaluator.py
+10
-5
No files found.
lm_eval/evaluator.py
View file @
777f57ce
...
...
@@ -185,13 +185,22 @@ def evaluate(
# decontaminate = decontamination_ngrams_path is not None
# stores the final result for each task, for each metric/filter pair.
results
=
collections
.
defaultdict
(
dict
)
# Tracks each task's version.
versions
=
collections
.
defaultdict
(
dict
)
# Tracks the YAML configs of all chosen tasks.
configs
=
collections
.
defaultdict
(
dict
)
# logs info about each document evaluated.
samples
=
collections
.
defaultdict
(
list
)
# tracks all Instances/requests a model must generate output on.
requests
=
collections
.
defaultdict
(
list
)
# ?
aggregate
=
collections
.
defaultdict
(
dict
)
# tracks if a task was chosen via user selecting a group containing it
task_groups
=
collections
.
defaultdict
(
dict
)
# stores the amount to pad out reqs per req. type so that
# number of fwd passes per distributed rank is equal
padding_requests
=
collections
.
defaultdict
(
int
)
# get lists of each type of request
...
...
@@ -200,11 +209,7 @@ def evaluate(
if
type
(
task
)
==
tuple
:
group
,
task
=
task
# if group in task_groups:
# task_groups[group].append(task_name)
# else:
# task_groups[group] = [task_name]
task_groups
[
task_name
]
=
group
task_groups
[
task_name
]
=
group
versions
[
task_name
]
=
task
.
VERSION
configs
[
task_name
]
=
dict
(
task
.
dump_config
())
...
...
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