ComfyUI > Nodes > ComfyUI-ArchAi3d-Qwen > 🧠 Memory Cleanup

ComfyUI Node: 🧠 Memory Cleanup

Class Name

ArchAi3D_Memory_Cleanup

Category
ArchAi3d/Memory
Author
Amir Ferdos (ArchAi3d) (Account age: 1109days)
Extension
ComfyUI-ArchAi3d-Qwen
Latest Updated
2026-04-17
Github Stars
0.05K

How to Install ComfyUI-ArchAi3d-Qwen

Install this extension via the ComfyUI Manager by searching for ComfyUI-ArchAi3d-Qwen
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter ComfyUI-ArchAi3d-Qwen in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • 16GB VRAM to 80GB VRAM GPU machines
  • 400+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 200+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

🧠 Memory Cleanup Description

Optimizes AI workflow memory by clearing DRAM, VRAM, and CUDA caches to prevent bottlenecks.

🧠 Memory Cleanup:

The ArchAi3D_Memory_Cleanup node is designed to efficiently manage and optimize memory usage within your AI-driven workflows. Its primary function is to clear various types of memory caches, including DRAM cache, VRAM, and CUDA cache, which can become fragmented or overloaded during intensive processing tasks. By strategically placing this node at the beginning or end of your workflow, you can ensure that memory resources are freed up, allowing for smoother transitions between different tasks or workflows. This is particularly beneficial when switching between workflows that have significantly different memory requirements or when your system's RAM is running low. The node's ability to unpin VRAM, clear caches, and unload models helps maintain optimal performance and prevents memory-related bottlenecks, making it an essential tool for AI artists who need to manage memory resources effectively.

🧠 Memory Cleanup Input Parameters:

unpin_all_vram

This parameter determines whether all VRAM pins should be removed. When set to True, it makes pinned models eligible for auto-eviction, which can help free up VRAM for other tasks. The default value is True, and it is a boolean option.

clear_dram_cache

This parameter controls whether the DRAM cache should be cleared. Clearing the DRAM cache forces models to be reloaded from disk the next time they are used, which can be useful for freeing up system RAM. The default value is True, and it is a boolean option.

clear_vram

This parameter specifies whether all models should be unloaded from GPU VRAM. Unloading models can help free up VRAM, especially when switching between different workflows. The default value is True, and it is a boolean option.

clear_cuda_cache

This parameter indicates whether the PyTorch CUDA cache should be cleared. Clearing the CUDA cache can help reclaim fragmented VRAM, improving memory efficiency. The default value is True, and it is a boolean option.

🧠 Memory Cleanup Output Parameters:

memory_stats

This output provides a string representation of the memory status after the cleanup process. It gives you an overview of the memory resources that have been freed, helping you understand the impact of the cleanup operation.

trigger

This output is a boolean value that can be used to control the execution order of nodes in your workflow. It ensures that subsequent nodes are executed only after the memory cleanup process is complete.

🧠 Memory Cleanup Usage Tips:

  • Use the ArchAi3D_Memory_Cleanup node at the end of a workflow to free up memory resources before starting a new task, ensuring optimal performance.
  • Consider enabling all cleanup options when switching between workflows with different memory requirements to prevent memory-related issues.

🧠 Memory Cleanup Common Errors and Solutions:

No actions selected

  • Explanation: This message appears when none of the cleanup options are enabled, resulting in no memory cleanup actions being performed.
  • Solution: Ensure that at least one of the cleanup options (unpin_all_vram, clear_dram_cache, clear_vram, clear_cuda_cache) is set to True to perform a memory cleanup.

CUDA out of memory

  • Explanation: This error occurs when there is insufficient VRAM available for the current task, often due to fragmented or occupied memory.
  • Solution: Use the ArchAi3D_Memory_Cleanup node with clear_cuda_cache and clear_vram options enabled to free up VRAM before executing memory-intensive tasks.

🧠 Memory Cleanup Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI-ArchAi3d-Qwen
RunComfy
Copyright 2025 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Models, enabling artists to harness the latest AI tools to create incredible art.

🧠 Memory Cleanup