mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
Update invokeai/backend/model_manager/load/model_cache/model_cache_default.py
Co-authored-by: Ryan Dick <ryanjdick3@gmail.com>
This commit is contained in:
@ -292,7 +292,7 @@ class ModelCache(ModelCacheBase[AnyModel]):
|
|||||||
try:
|
try:
|
||||||
cache_entry.model.to(target_device, non_blocking=TorchDevice.get_non_blocking(target_device))
|
cache_entry.model.to(target_device, non_blocking=TorchDevice.get_non_blocking(target_device))
|
||||||
except TypeError as e:
|
except TypeError as e:
|
||||||
if "got an unexpected keyword argument 'non_blocking' in str(e)":
|
if "got an unexpected keyword argument 'non_blocking'" in str(e):
|
||||||
cache_entry.model.to(target_device)
|
cache_entry.model.to(target_device)
|
||||||
else:
|
else:
|
||||||
raise e
|
raise e
|
||||||
|
Reference in New Issue
Block a user