MD: GPU Temp Protect
Auto-pause your queue before the card hits the throttle wall
- latent_in
- image_in
- audio_in
- pass_through_generic
- latent_out
- image_out
- audio_out
- passthrough_generic_out
- temp_status_string
If you leave ComfyUI running long batch jobs - overnight queues, multi-hundred-image runs, or audio pipelines that keep the GPU pinned for an hour - you've probably watched your card ride the 83°C throttle line and thought "this is how cards die young." GPUTemperatureProtectionEnhanced is the node that watches the temperature for you and pauses the queue when things get hot, then resumes when it's cooled down. It's the hardware equivalent of the pack's VRAM manager: set-and-forget insurance for long unsupervised renders.
How it works
Every few seconds the node shells out to nvidia-smi and reads the GPU temperature (plus, optionally, VRAM and utilization stats). If the temp crosses your sleep_temp threshold, it enters cooling mode: sleep for a bit, re-check, and keep cooling until the temp drops back to wake_temp or a max_sleep_time force-resume kicks in. That last one matters - without it, a stubbornly hot card would pause your queue forever.
Two details make it more than a dumb watchdog:
adaptive_cooling- adjusts sleep time based on the temperature trend. Cooling fast? Sleep less. Cooling slow? Sleep more. It's a simple proportional response and it works.cooling_profile- balanced / aggressive / conservative, which just scales the sleep cycle (aggressive checks 0.5x as long, conservative 2x).
It's an output node, and like the pack's other safety nodes, the way you force it to execute is by threading a pass-through through it: latent_in, image_in, audio_in, or the generic pass_through_generic all exist purely to establish execution order, and they all come back out the other side.
The inputs that matter
The full list is long, so here's what you actually set:
enabled- master switch (True/False). Keep it on.gpu_id- which GPU to monitor via nvidia-smi indexing. 0 for single-GPU systems.sleep_temp(default 79°C) - pause the queue above this. The default is conservative-safe; 83–85 is fine if you want fewer interruptions.wake_temp(default 65°C) - resume below this. Must be lower than sleep_temp.min_interval(default 5s) - how often to check. Lower = more responsive, tiny CPU cost.max_sleep_time(default 180s) - force resume after this long even if still hot.
The optional diagnostics are nice: print_enabled and show_all_gpus dump status to console, monitor_memory shows VRAM usage, show_stats prints a session summary after cooling cycles, and log_enabled writes a CSV temperature history to gpu_temp_logs. If you're diagnosing cooling problems, that CSV is genuinely useful.
Gotchas
This relies on nvidia-smi, which means NVIDIA GPUs with the driver installed - it will log a clear error if the command is missing. It pauses ComfyUI's queue, not other processes; if you're also running Ollama on the same card, that's a different node's problem. And it's not a substitute for proper cooling, just a safety net that stops a hot card from staying hot. Also: pass-through or it won't run, same lazy-execution gotcha as the VRAM manager.
Installing
It's part of MD Nodes:
cd path/to/ComfyUI/custom_nodes
git clone https://github.com/MDMAchine/ComfyUI_MD_Nodes.git
cd ComfyUI_MD_Nodes && pip install -r requirements.txt
Or via ComfyUI Manager (search MD Nodes), then restart. It's a rare pack node that earns its keep mostly through discipline - the value is entirely "you won't kill your card on a 3am queue," which is exactly the kind of insurance you don't appreciate until you need it.
Inputs (19)
| Name | Type | Default | Description |
|---|---|---|---|
| enabled | COMBO | True | ENABLE PROTECTION • Purpose: Master switch for hardware protection logic. ⭐ Recommended: True |
| gpu_id | INT | 00–15 | GPU ID • Purpose: Target specific GPU via nvidia-smi indexing. • Range: 0 to 15. ⭐ Recommended: 0 for single-GPU systems. |
| sleep_temp | INT | 7940–110 | SLEEP THRESHOLD • Purpose: Temperature (°C) that triggers a queue pause. • Trade-offs: Lower values protect hardware but interrupt renders more often. ⭐ Recommended: 79 |
| wake_temp | INT | 6530–100 | WAKE THRESHOLD • Purpose: Temperature (°C) at which the queue resumes. • Note: Must be lower than sleep_temp. ⭐ Recommended: 65 |
| min_interval | INT | 51–300 | CHECK INTERVAL • Purpose: Minimum seconds between temperature checks. • Trade-offs: Frequent checks increase CPU overhead slightly. ⭐ Recommended: 5 |
| sleep_time | FLOAT | 5.00.5–60 | COOLING DURATION • Purpose: Base duration for each cooling sleep cycle (s). ⭐ Recommended: 5.0 |
| max_sleep_time | INT | 1800–3600 | MAX COOLING TIME • Purpose: Force resume after this duration (s), even if still hot. • Note: Prevents permanent workflow lockups. ⭐ Recommended: 180 |
| latent_inopt | LATENT | PASS-THROUGH (LATENT) • Connect LATENT here to enforce execution order. | |
| image_inopt | IMAGE | PASS-THROUGH (IMAGE) • Connect IMAGE here to enforce execution order. | |
| audio_inopt | AUDIO | PASS-THROUGH (AUDIO) • Connect AUDIO here to enforce execution order. | |
| pass_through_genericopt | * | PASS-THROUGH (GENERIC) • Connect any other data type here to enforce order. | |
| print_enabledopt | COMBO | True | PRINT TO CONSOLE • Purpose: Show status messages in ComfyUI console. |
| show_all_gpusopt | COMBO | False | SHOW ALL GPUS • Purpose: List temps for all detected cards in console. |
| monitor_memoryopt | COMBO | True | MONITOR VRAM • Purpose: Show VRAM usage stats in console. |
| show_statsopt | COMBO | False | SHOW STATS • Purpose: Print session summary after cooling cycles. |
| cooling_profileopt | COMBO | balanced | COOLING PROFILE • Purpose: Adjusts sleep cycle aggressiveness. • Balanced: Standard behavior. • Aggressive: Faster checks (0.5x sleep). • Conservative: Slower checks (2.0x sleep). |
| adaptive_coolingopt | COMBO | True | ADAPTIVE COOLING • Purpose: Adjust sleep time based on temp trend. • Note: Cooling fast? Sleep less. Cooling slow? Sleep more. |
| log_enabledopt | COMBO | False | CSV LOGGING • Purpose: Save temp history to /gpu_temp_logs directory. |
| debug_modeopt | COMBO | 0 - Silent | LOGGING VERBOSITY • Controls hardware I/O profiling display. |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| latent_out | LATENT | — |
| image_out | IMAGE | — |
| audio_out | AUDIO | — |
| passthrough_generic_out | * | — |
| temp_status_string | STRING | — |