@Xiaote 謝謝。不過不知道哪個是對的, Gemini如此說:
By default, ComfyUI does not load full model weights into system RAM as a complete duplicate before copying them to VRAM. Instead, it uses PyTorch's memory mapping (mmap) or meta-devices to inspect and stage weights directly, dynamically streaming or moving only the necessary components into VRAM as execution demands.How ComfyUI Manages MemoryMemory Mapping (mmap): For formats like safetensors, ComfyUI maps files via pointers rather than performing deep copies into system RAM.Dynamic Loading: Individual model parts are paged or transferred to the GPU device context selectively during processing.Startup Flags: Behavior changes depending on arguments like --highvram (which keeps models resident on the GPU) or --gpu-only (which attempts to bypass system memory staging entirely).
