Skip to content

Commit ee46bef

Browse files
Make --cpu have priority over everything else.
1 parent 0e836d5 commit ee46bef

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

comfy/model_management.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,6 @@
5050
XFORMERS_IS_AVAILBLE = False
5151

5252

53-
if "--cpu" in sys.argv:
54-
vram_state = CPU
5553
if "--lowvram" in sys.argv:
5654
set_vram_to = LOW_VRAM
5755
if "--novram" in sys.argv:
@@ -73,6 +71,8 @@
7371
total_vram_available_mb = (total_vram - 1024) // 2
7472
total_vram_available_mb = int(max(256, total_vram_available_mb))
7573

74+
if "--cpu" in sys.argv:
75+
vram_state = CPU
7676

7777
print("Set vram state to:", ["CPU", "NO VRAM", "LOW VRAM", "NORMAL VRAM", "HIGH VRAM"][vram_state])
7878

0 commit comments

Comments
 (0)