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
73b2149f
Commit
73b2149f
authored
Jul 15, 2023
by
baberabb
Browse files
removed rnd from task.fewshot_context in write_out.py; add mps in huggingface.py
parent
283cad70
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
1 deletion
+4
-1
lm_eval/models/huggingface.py
lm_eval/models/huggingface.py
+4
-0
scripts/write_out.py
scripts/write_out.py
+0
-1
No files found.
lm_eval/models/huggingface.py
View file @
73b2149f
...
...
@@ -107,6 +107,10 @@ class HFLM(LM):
device
=
int
(
device
)
self
.
_device
=
torch
.
device
(
device
)
eval_logger
.
info
(
f
"Using device '
{
device
}
'"
)
if
device
==
"mps"
:
eval_logger
.
info
(
"MPS is still in beta; add ,dtype=float32 to model_args ."
)
else
:
eval_logger
.
info
(
"Device not specified"
)
eval_logger
.
info
(
f
"Cuda Available?
{
torch
.
cuda
.
is_available
()
}
"
)
...
...
scripts/write_out.py
View file @
73b2149f
...
...
@@ -58,7 +58,6 @@ def main():
ctx
=
task
.
fewshot_context
(
doc
=
doc
,
num_fewshot
=
args
.
num_fewshot
,
rnd
=
rnd
,
)
f
.
write
(
ctx
+
"
\n
"
)
...
...
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