We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3bcd6cc commit 2f671afCopy full SHA for 2f671af
src/diffusers/models/model_loading_utils.py
@@ -163,7 +163,7 @@ def load_state_dict(
163
if disable_mmap:
164
return safetensors.torch.load(open(checkpoint_file, "rb").read())
165
else:
166
- return safetensors.torch.load_file(checkpoint_file, device="cpu")
+ return safetensors.torch.load_file(checkpoint_file, device=map_location)
167
elif file_extension == GGUF_FILE_EXTENSION:
168
return load_gguf_checkpoint(checkpoint_file)
169
0 commit comments