The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface. The fastest local inference engine in the world.
Make minimum_inference_memory() depend on --reserve-vram
comfyanonymousb643eae08b7f
diff --git a/comfy/model_management.py b/comfy/model_management.pyindex 59dce4dac..f6a76a572 100644--- a/comfy/model_management.py+++ b/comfy/model_management.py@@ -370,12 +370,9 @@ def offloaded_memory(loaded_models, device):offloaded_mem += m.model_offloaded_memory()return offloaded_mem-def minimum_inference_memory():- return (1024 * 1024 * 1024) * 1.2--EXTRA_RESERVED_VRAM = 200 * 1024 * 1024+EXTRA_RESERVED_VRAM = 400 * 1024 * 1024if any(platform.win32_ver()):- EXTRA_RESERVED_VRAM = 500 * 1024 * 1024 #Windows is higher because of the shared vram issue+ EXTRA_RESERVED_VRAM = 600 * 1024 * 1024 #Windows is higher because of the shared vram issueif args.reserve_vram is not None:EXTRA_RESERVED_VRAM = args.reserve_vram * 1024 * 1024 * 1024@@ -384,6 +381,9 @@ if args.reserve_vram is not None:def extra_reserved_memory():return EXTRA_RESERVED_VRAM+def minimum_inference_memory():+ return (1024 * 1024 * 1024) * 0.8 + extra_reserved_memory()+def unload_model_clones(model, unload_weights_only=True, force_unload=True):to_unload = []for i in range(len(current_loaded_models)):