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
5c3badbe
Commit
5c3badbe
authored
Jul 21, 2025
by
Baber
Browse files
type hints
parent
17223113
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
lm_eval/config/metric.py
lm_eval/config/metric.py
+2
-2
No files found.
lm_eval/config/metric.py
View file @
5c3badbe
...
...
@@ -44,8 +44,8 @@ class MetricConfig:
raise
ValueError
(
f
"Metric function for
{
self
.
name
}
is not defined."
)
return
self
.
fn
(
*
args
,
**
{
**
(
self
.
kwargs
or
{}),
**
kwargs
})
def
compute_aggregation
(
self
,
values
:
list
[
Any
]
)
->
Any
:
def
compute_aggregation
(
self
,
*
args
,
**
kwargs
)
->
Any
:
"""Computes the aggregation of the metric values."""
if
self
.
aggregation_fn
is
None
:
raise
ValueError
(
f
"Aggregation function for
{
self
.
name
}
is not defined."
)
return
self
.
aggregation_fn
(
value
s
)
return
self
.
aggregation_fn
(
*
args
,
**
kwarg
s
)
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