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
4155ec7f
Unverified
Commit
4155ec7f
authored
Nov 07, 2024
by
Baber Abbasi
Committed by
GitHub
Nov 07, 2024
Browse files
pass device_map other than auto for parallelize (#2457)
* pass device_map other than auto for parallelize
parent
901053f6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
lm_eval/models/huggingface.py
lm_eval/models/huggingface.py
+2
-2
No files found.
lm_eval/models/huggingface.py
View file @
4155ec7f
...
@@ -346,9 +346,9 @@ class HFLM(TemplateLM):
...
@@ -346,9 +346,9 @@ class HFLM(TemplateLM):
==
(
self
.
accelerator
.
process_index
%
num_local_processes
)
==
(
self
.
accelerator
.
process_index
%
num_local_processes
)
}
}
args
[
"max_memory"
]
=
max_memory_per_gpu_map
args
[
"max_memory"
]
=
max_memory_per_gpu_map
args
[
"device_map"
]
=
"auto"
args
[
"device_map"
]
=
"auto"
if
device_map
is
None
else
device_map
eval_logger
.
info
(
eval_logger
.
info
(
f
"Model parallel was set to True, setting max memory per GPU to
{
max_memory_per_gpu_map
}
and device map to
'auto'
"
f
"Model parallel was set to True, setting max memory per GPU to
{
max_memory_per_gpu_map
}
and device map to
{
args
.
get
(
'device_map'
)
}
"
)
)
if
max_cpu_memory
is
not
None
:
if
max_cpu_memory
is
not
None
:
...
...
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