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
a0c1dbbd
"...lm-evaluation-harness.git" did not exist on "4748281bcc40843dca083fdd00621ec00662afd7"
Commit
a0c1dbbd
authored
Jun 09, 2023
by
FarzanehNakhaee
Browse files
add resps and filter_resps to the example logger
parent
b7cfed19
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
lm_eval/evaluator.py
lm_eval/evaluator.py
+7
-1
No files found.
lm_eval/evaluator.py
View file @
a0c1dbbd
...
...
@@ -238,7 +238,13 @@ def evaluate(
doc
,
[
req
.
filtered_resps
[
key
]
for
req
in
requests
]
)
target
=
task
.
doc_to_target
(
doc
)
example
=
{
"doc_id"
:
doc_id
,
"doc"
:
doc
[
'text'
],
"target"
:
target
}
example
=
{
"doc_id"
:
doc_id
,
"doc"
:
doc
,
"target"
:
target
,
"resps"
:
[
req
.
resps
for
req
in
requests
],
"filtered_resps"
:
[
req
.
filtered_resps
[
key
]
for
req
in
requests
]
}
example
.
update
(
metrics
)
example_logger
.
info
(
json
.
dumps
(
example
))
for
metric
,
value
in
metrics
.
items
():
...
...
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