mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-12-23 13:00:54 +08:00
fix: accelerate the first inference speed on low-level NPUs.
This commit is contained in:
parent
a9cf1cd249
commit
083d8aa330
@ -121,6 +121,7 @@ except:
|
|||||||
try:
|
try:
|
||||||
import torch_npu # noqa: F401
|
import torch_npu # noqa: F401
|
||||||
_ = torch.npu.device_count()
|
_ = torch.npu.device_count()
|
||||||
|
torch_npu.npu.set_compile_mode(jit_compile = False)
|
||||||
npu_available = torch.npu.is_available()
|
npu_available = torch.npu.is_available()
|
||||||
except:
|
except:
|
||||||
npu_available = False
|
npu_available = False
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user