From 03c5018c98b9dd2654dc4942a0978ac53e755900 Mon Sep 17 00:00:00 2001 From: comfyanonymous Date: Sat, 3 Aug 2024 15:14:07 -0400 Subject: [PATCH] Lower lowvram memory to 1/3 of free memory. --- comfy/model_management.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/comfy/model_management.py b/comfy/model_management.py index bb4bcbb2..c4402a8a 100644 --- a/comfy/model_management.py +++ b/comfy/model_management.py @@ -450,7 +450,7 @@ def load_models_gpu(models, memory_required=0, force_patch_weights=False, minimu if lowvram_available and (vram_set_state == VRAMState.LOW_VRAM or vram_set_state == VRAMState.NORMAL_VRAM): model_size = loaded_model.model_memory_required(torch_dev) current_free_mem = get_free_memory(torch_dev) - lowvram_model_memory = max(64 * (1024 * 1024), (current_free_mem - minimum_memory_required), current_free_mem * 0.5) + lowvram_model_memory = max(64 * (1024 * 1024), (current_free_mem - minimum_memory_required), current_free_mem * 0.33) if model_size <= lowvram_model_memory: #only switch to lowvram if really necessary lowvram_model_memory = 0