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
0d9cc5a8
You need to sign in or sign up before continuing.
Unverified
Commit
0d9cc5a8
authored
May 03, 2021
by
Leo Gao
Committed by
GitHub
May 03, 2021
Browse files
Update metrics.py
parent
45fefe9f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
lm_eval/metrics.py
lm_eval/metrics.py
+4
-4
No files found.
lm_eval/metrics.py
View file @
0d9cc5a8
...
@@ -178,10 +178,10 @@ def bootstrap_stddev(f, xs, iters=10000):
...
@@ -178,10 +178,10 @@ def bootstrap_stddev(f, xs, iters=10000):
print
(
"bootstrapping for stddev:"
,
f
.
__name__
)
print
(
"bootstrapping for stddev:"
,
f
.
__name__
)
for
i
in
trange
(
iters
):
for
i
in
trange
(
iters
):
# sample w replacement
# sample w replacement
bootstrap
=
rnd
.
choices
(
xs
,
k
=
len
(
xs
))
bootstrap
=
f
(
rnd
.
choices
(
xs
,
k
=
len
(
xs
))
)
res
.
append
(
stddev
(
bootstrap
)
)
res
.
append
(
bootstrap
)
return
mean
(
res
)
return
stddev
(
res
)
def
stderr_for_metric
(
metric
):
def
stderr_for_metric
(
metric
):
...
...
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