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
84191b83
Commit
84191b83
authored
Apr 28, 2023
by
lintangsutawika
Browse files
registries for metrics
parent
7ad96ded
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
0 deletions
+25
-0
lm_eval/api/__init__.py
lm_eval/api/__init__.py
+25
-0
No files found.
lm_eval/api/__init__.py
View file @
84191b83
from
.
import
metrics
METRIC_REGISTRY
=
{
"matthews_corrcoef"
:
metrics
.
matthews_corrcoef
,
"f1_score"
:
metrics
.
f1_score
,
"perplexity"
:
metrics
.
perplexity
,
"bleu"
:
metrics
.
bleu
,
"chrf"
:
metrics
.
chrf
,
"ter"
:
metrics
.
ter
,
}
AGGREGATION_REGISTRY
=
{
"mean"
:
metrics
.
mean
,
"median"
:
metrics
.
median
,
"perplexity"
:
metrics
.
perplexity
,
}
HIGHER_IS_BETTER_REGISTRY
=
{
"matthews_corrcoef"
:
True
,
"f1_score"
:
True
,
"perplexity"
:
False
,
"bleu"
:
True
,
"chrf"
:
True
,
"ter"
:
False
,
}
\ No newline at end of file
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