Comfy-Org / Comfy-Org/ComfyUI

[Bug] MiniMax H3 Fun ControlNet Union aborts at first sampling step; --disable-comfy-compiler completes (Windows, RTX 5080 Laptop)

Open
#16,230 3 comments 0 reactions 0 assignees View on GitHub
Potential Bug
Dominant language
Python
Stars
133k
Forks
15.7k
Avg merge
1d 7h
Merged PRs (30d)
158

Description

### Custom Node Testing

- [ ] I have tried disabling custom nodes and the issue persists (see [how to disable custom nodes](https://docs.comfy.org/troubleshooting/custom-node-issues#step-1%3A-test-with-all-custom-nodes-disabled) if you need help)

### Expected Behavior

The bundled video_minimax_h3_fun_controlnet_union pose-control workflow should complete sampling and save a video, or report a recoverable error instead of terminating Python.

### Actual Behavior

On 2026-09-10, Python exited with `Fatal Python error: Aborted` during the first sampler step (0/20, Model Initializing). SDPose extraction and drawing had completed for all 124 frames. The last model-load message was MiniMaxH3VideoVAE. The faulthandler stack ends at `comfy/ldm/minimax/model.py:586`, `del graph_out`, inside the compiler allocation path. There is no explicit Python CUDA OOM exception in the supplied crash output.

Restarting the same installation with `--disable-comfy-compiler` allowed the workflow to complete all 20 steps and save H.264 video with AAC audio in 341.31 seconds. All 124 video frames and the audio decoded successfully. Dynamic VRAM remained enabled. Models, prompt, resolution, duration, sampling settings and ControlNet strength were retained. No source edits, package updates or model replacements were made between these runs.

Evidence limits: one observed failure and one successful retry. The UI randomizes the seed on submission, so this was not a fixed-seed A/B test. Custom nodes were loaded in both runs; a `--disable-all-custom-nodes` test has NOT been performed. The compiler interaction is a hypothesis supported by the workaround, not a proven native-level root cause.

### Steps to Reproduce

1. Windows portable ComfyUI, commit `a7b1d39d3`, reporting version 0.35.0. Launch from the portable directory:
```bat
.\python_embeded\python.exe -s ComfyUI\main.py --windows-standalone-build --enable-manager
```
2. Open bundled template `video_minimax_h3_fun_controlnet_union` (workflow templates 0.11.57), using the official `dancer_field_pose.mp4` input. The inline API JSON under Other captures the settings from the successful retry.
3. Resolution Selector: 16:9, 0.4 MP, multiple 32 -> **864x480**. Duration 5 seconds -> **124 frames**, 24 fps. No reference inputs. Lightning LoRA disabled. Sampler `res_multistep`, scheduler `simple`, 20 steps, denoise 1, BasicGuider. ControlNet strength 1.0, start 0.0, end 1.0.
4. Queue the workflow. On the observed failing run, preprocessing completed and Python aborted during first-step initialization.
5. Restart with `--disable-comfy-compiler` appended. The diagnostic launcher also used `--disable-auto-launch` to avoid opening a duplicate browser. Queue the same workflow/settings. This retry completed successfully.

Models:
- diffusion: `minimax_h3_ref2va_pruned_int8_convrot.safetensors`
- text encoder: `qwen3vl_32b_minimax_h3_nvfp4_awq.safetensors`
- video VAE: `minimax_h3_video_vae_fp16.safetensors`
- audio VAE: `minimax_h3_audio_vae_fp32.safetensors`
- patch: `minimax_h3_fun_controlnet_union_pruned_int8_convrot.safetensors`
- pose checkpoint: `sdpose_wholebody_fp16.safetensors`
- detector: `rt_detr_v4-x-hgnet_fp16.safetensors`

Input: https://raw.githubusercontent.com/Comfy-Org/workflow_templates/refs/heads/main/input/dancer_field_pose.mp4

### Debug Logs

```powershell
Failure log excerpt with the complete Python call stack, followed by the successful retry excerpt. Duplicate progress output and the native extension module list are omitted. Installation paths are redacted.

Failure excerpt:
[INFO] Requested to load MiniMaxH3FunControl
[INFO] Requested to load MiniMaxH3
[INFO] 0 models unloaded.
[INFO] Model MiniMaxH3FunControl prepared for dynamic VRAM loading. 2180MB Staged. 0 patches attached. Force pre-loaded 20 weights: 107 KB.
[INFO] Model MiniMaxH3 prepared for dynamic VRAM loading. 19995MB Staged. 0 patches attached. Force pre-loaded 210 weights: 1175 KB.
0% | 0/20 | Model Initializing ...
[INFO] Requested to load MiniMaxH3VideoVAE
[INFO] Model MiniMaxH3VideoVAE prepared for dynamic VRAM loading. 4965MB Staged. 0 patches attached. Force pre-loaded 128 weights: 348 KB.
Fatal Python error: Aborted

Stack (most recent call first):
File "\ComfyUI\comfy\ldm\minimax\model.py", line 586 in forward
File "\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1789 in _call_impl
File "\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1778 in _wrapped_call_impl
File "\ComfyUI\comfy\model_base.py", line 252 in _apply_model
File "\ComfyUI\comfy\patcher_extension.py", line 113 in execute
File "\ComfyUI\comfy\model_base.py", line 208 in apply_model
File "\ComfyUI\comfy\samplers.py", line 335 in _calc_cond_batch
File "\ComfyUI\comfy\patcher_extension.py", line 113 in execute
File "\ComfyUI\comfy\samplers.py", line 219 in _calc_cond_batch_outer
File "\ComfyUI\comfy\samplers.py", line 211 in calc_cond_batch
File "\ComfyUI\comfy\samplers.py", line 620 in sampling_function
File "\ComfyUI\comfy\samplers.py", line 1218 in predict_noise
File "\ComfyUI\comfy\patcher_extension.py", line 113 in execute
File "\ComfyUI\comfy\samplers.py", line 1215 in outer_predict_noise
File "\ComfyUI\comfy\samplers.py", line 1208 in __call__
File "\ComfyUI\comfy\samplers.py", line 640 in __call__
File "\ComfyUI\comfy\k_diffusion\sampling.py", line 1486 in res_multistep
File "\python_embeded\Lib\site-packages\torch\utils\_contextlib.py", line 124 in decorate_context
File "\ComfyUI\comfy\k_diffusion\sampling.py", line 1528 in sample_res_multistep
File "\python_embeded\Lib\site-packages\torch\utils\_contextlib.py", line 124 in decorate_context
File "\ComfyUI\comfy\samplers.py", line 1005 in sample
File "\ComfyUI\comfy\patcher_extension.py", line 113 in execute
File "\ComfyUI\comfy\samplers.py", line 1237 in inner_sample
File "\ComfyUI\comfy\samplers.py", line 1262 in outer_sample
File "\ComfyUI\comfy\patcher_extension.py", line 113 in execute
File "\ComfyUI\comfy\samplers.py", line 1335 in sample
File "\ComfyUI\comfy_extras\nodes_custom_sampler.py", line 1055 in execute
File "\ComfyUI\comfy_api\latest\_io.py", line 2046 in EXECUTE_NORMALIZED
File "\ComfyUI\comfy_api\internal\__init__.py", line 149 in wrapped_func
File "\ComfyUI\execution.py", line 306 in process_inputs
File "\ComfyUI\execution.py", line 318 in _async_map_node_over_list
File "\ComfyUI\execution.py", line 344 in get_output_data
File "\ComfyUI\execution.py", line 545 in execute
File "\ComfyUI\execution.py", line 789 in execute_async
File "asyncio\events.py", line 89 in _run
File "asyncio\base_events.py", line 2060 in _run_once
File "asyncio\base_events.py", line 683 in run_forever
File "asyncio\base_events.py", line 712 in run_until_complete
File "asyncio\runners.py", line 119 in run
File "asyncio\runners.py", line 196 in run
File "\ComfyUI\execution.py", line 728 in execute
File "\ComfyUI\main.py", line 394 in prompt_worker
File "threading.py", line 995 in run
File "threading.py", line 1044 in _bootstrap_inner
File "threading.py", line 1015 in _bootstrap

Successful retry excerpt:
100% | 20/20 [03:32<00:00, 10.62s/it]
[INFO] Requested to load MiniMaxH3AudioVAE
[INFO] Model MiniMaxH3AudioVAE prepared for dynamic VRAM loading. 576MB Staged. 0 patches attached. Force pre-loaded 401 weights: 539 KB.
[INFO] Model MiniMaxH3VideoVAE prepared for dynamic VRAM loading. 4965MB Staged. 0 patches attached. Force pre-loaded 128 weights: 348 KB.
[INFO] Prompt executed in 341.31 seconds
```

### Other

### Environment
- Windows 11, portable installation
- GPU: NVIDIA GeForce RTX 5080 Laptop GPU, ~16 GB VRAM
- System RAM: 32429 MB
- NVIDIA driver: 616.64
- Python: 3.13.14
- PyTorch: 2.13.0+cu130
- ComfyUI: 0.35.0, commit `a7b1d39d3`
- comfy-aimdo: 0.5.3; comfy-kitchen: 0.2.33
- Frontend: 1.51.10; workflow templates: 0.11.57
- PyTorch attention; cudaMallocAsync; async weight offloading (2 streams); DynamicVRAM enabled
- Triton unavailable; no SageAttention or sparse-attention patch used in this workflow

### Investigation notes
At this commit, `MiniMaxH3.forward` starts the malloc graph before executing the diffusion-model wrapper; the Fun ControlNet wrapper calls `prepare_control_latent`, which VAE-encodes the control frames on first use and then restores loaded models. This may be relevant to allocation lifetimes, but it has not been proved to cause the abort.

This installation already includes #16020, #16148 and #16180. Related reports #15566 and #16150 have different configurations/symptoms; this is not a confirmed duplicate.

Custom nodes loaded include KJNodes, GGUF, Impact Pack, Crystools, ControlNet Aux, VideoHelperSuite, LayerStyle and frame interpolation. No clean custom-node-disabled repro yet; the corresponding checkbox is intentionally unchecked.

### API workflow
The captured successful retry graph is included inline below because browser attachment upload failed. It is not a minimized repro. The seed automatically changed between runs, so this is not a fixed-seed A/B comparison. No model weights or generated media are included.

workflow-api.json (save this JSON to reproduce via the ComfyUI API)

```json
{
"115": {
"inputs": {
"aspect_ratio": "16:9 (Widescreen)",
"megapixels": 0.4,
"multiple": 32
},
"class_type": "ResolutionSelector",
"_meta": {
"title": "Resolution Selector (Size)"
}
},
"119": {
"inputs": {
"vae_name": "minimax_h3_video_vae_fp16.safetensors"
},
"class_type": "VAELoader",
"_meta": {
"title": "加载VAE"
}
},
"120": {
"inputs": {
"vae_name": "minimax_h3_audio_vae_fp32.safetensors"
},
"class_type": "VAELoader",
"_meta": {
"title": "加载VAE"
}
},
"121": {
"inputs": {
"samples": [
"125",
0
],
"vae": [
"120",
0
]
},
"class_type": "VAEDecodeAudio",
"_meta": {
"title": "VAE解码(音频)"
}
},
"122": {
"inputs": {
"samples": [
"125",
0
],
"vae": [
"119",
0
]
},
"class_type": "VAEDecode",
"_meta": {
"title": "VAE解码"
}
},
"123": {
"inputs": {
"sampler_name": "res_multistep"
},
"class_type": "KSamplerSelect",
"_meta": {
"title": "K采样器选择"
}
},
"124": {
"inputs": {
"scheduler": "simple",
"steps": [
"142",
0
],
"denoise": 1,
"model": [
"172",
0
]
},
"class_type": "BasicScheduler",
"_meta": {
"title": "基本调度器"
}
},
"125": {
"inputs": {
"noise": [
"129",
0
],
"guider": [
"126",
0
],
"sampler": [
"123",
0
],
"sigmas": [
"124",
0
],
"latent_image": [
"136",
1
]
},
"class_type": "SamplerCustomAdvanced",
"_meta": {
"title": "自定义采样器(高级)"
}
},
"126": {
"inputs": {
"model": [
"172",
0
],
"conditioning": [
"136",
0
]
},
"class_type": "BasicGuider",
"_meta": {
"title": "基本引导器"
}
},
"127": {
"inputs": {
"unet_name": "minimax_h3_ref2va_pruned_int8_convrot.safetensors",
"weight_dtype": "default"
},
"class_type": "UNETLoader",
"_meta": {
"title": "UNet加载器"
}
},
"128": {
"inputs": {
"clip_name": "qwen3vl_32b_minimax_h3_nvfp4_awq.safetensors",
"type": "minimax",
"device": "default"
},
"class_type": "CLIPLoader",
"_meta": {
"title": "加载CLIP"
}
},
"129": {
"inputs": {
"noise_seed": 416256878459125
},
"class_type": "RandomNoise",
"_meta": {
"title": "随机噪波"
}
},
"130": {
"inputs": {
"fps": 24,
"bit_depth": "auto",
"color_space": "sRGB",
"images": [
"122",
0
],
"audio": [
"121",
0
]
},
"class_type": "CreateVideo",
"_meta": {
"title": "创建视频"
}
},
"131": {
"inputs": {
"expression": "max(5, round(a * 24)) + (5 - (max(5, round(a * 24)) % 17)) % 17",
"values.a": [
"132",
0
]
},
"class_type": "ComfyMathExpression",
"_meta": {
"title": "数学表达式"
}
},
"132": {
"inputs": {
"value": 5
},
"class_type": "PrimitiveFloat",
"_meta": {
"title": "Float (Duration)"
}
},
"136": {
"inputs": {
"prompt": [
"138",
0
],
"width": [
"115",
0
],
"height": [
"115",
1
],
"length": [
"131",
1
],
"ref_image_size": "match",
"clip": [
"128",
0
],
"vae": [
"119",
0
],
"audio_vae": [
"120",
0
]
},
"class_type": "MiniMaxH3ReferenceToVideo",
"_meta": {
"title": "MiniMax H3 参考转视频"
}
},
"138": {
"inputs": {
"value": "Scene: Hyperreal desert-storm aesthetic. A humanoid figure made of packed sand dances in a barren wasteland, each move shedding dust, the wind eroding and reshaping its body.\n[0s-2s] Pale desert, a sand humanoid begins to move from stillness, surface grains trickling off and dragging mist-like trails in the wind.\n[2s-4s] Spins and arm swings keep dissolving and rebuilding its edges, raised sand columns glowing gold in hard light under a searing white sky.\n[4s-5s] On the final pose, half the body has already been carried away by wind as a hanging line of sand, not yet fallen.\nCamera: medium fixed shot, focus pull from sand-grain close-up to full body.\nAudio: fine sand-scrape texture throughout, one distant desert wind call at 2s, no music.\nNegative: no dissolve transitions / no text overlays / no human face / no camera shake"
},
"class_type": "PrimitiveStringMultiline",
"_meta": {
"title": "Input Text (Prompt)"
}
},
"141": {
"inputs": {
"switch": [
"146",
0
],
"on_false": [
"127",
0
],
"on_true": [
"145",
0
]
},
"class_type": "ComfySwitchNode",
"_meta": {
"title": "If/Else Switch (model)"
}
},
"142": {
"inputs": {
"switch": [
"146",
0
],
"on_false": [
"143",
0
],
"on_true": [
"144",
0
]
},
"class_type": "ComfySwitchNode",
"_meta": {
"title": "If/Else Switch (Steps)"
}
},
"143": {
"inputs": {
"value": 20
},
"class_type": "PrimitiveInt",
"_meta": {
"title": "Int (Full)"
}
},
"144": {
"inputs": {
"value": 4
},
"class_type": "PrimitiveInt",
"_meta": {
"title": "Int (Lightning LoRA)"
}
},
"145": {
"inputs": {
"lora_name": "minimax_h3_ref2v_turbo_4step_v0.1_comfyui_bf16.safetensors",
"strength_model": 1,
"model": [
"127",
0
]
},
"class_type": "LoraLoaderModelOnly",
"_meta": {
"title": "LoRA加载器(仅模型)"
}
},
"146": {
"inputs": {
"value": false
},
"class_type": "PrimitiveBoolean",
"_meta": {
"title": "Boolean (Enable Lightning LoRA)"
}
},
"172": {
"inputs": {
"strength": 1,
"start_percent": 0,
"end_percent": 1,
"model": [
"141",
0
],
"model_patch": [
"173",
0
],
"vae": [
"119",
0
],
"control_video": [
"704",
0
]
},
"class_type": "MiniMaxH3FunControlNetApply",
"_meta": {
"title": "Apply MiniMax H3 Fun ControlNet"
}
},
"173": {
"inputs": {
"name": "minimax_h3_fun_controlnet_union_pruned_int8_convrot.safetensors"
},
"class_type": "ModelPatchLoader",
"_meta": {
"title": "加载模型补丁"
}
},
"174": {
"inputs": {
"file": "dancer_field_pose.mp4",
"video-preview": ""
},
"class_type": "LoadVideo",
"_meta": {
"title": "Load Video (Control Video)"
}
},
"704": {
"inputs": {
"images": [
"700:672",
0
]
},
"class_type": "PreviewImage",
"_meta": {
"title": "预览图像"
}
},
"705": {
"inputs": {
"start_time": 0,
"duration": 0,
"strict_duration": false,
"video": [
"174",
0
]
},
"class_type": "Video Slice",
"_meta": {
"title": "视频切片"
}
},
"707": {
"inputs": {
"filename_prefix": "video/MiniMax_H3",
"format": "auto",
"format.codec": "auto",
"codec": "auto",
"video": [
"130",
0
]
},
"class_type": "SaveVideo",
"_meta": {
"title": "保存视频"
}
},
"712": {
"inputs": {
"value": false
},
"class_type": "PrimitiveBoolean",
"_meta": {
"title": "Boolean (Enable Lightning LoRA)"
}
},
"700:671": {
"inputs": {
"batch_size": 16,
"model": [
"700:673",
0
],
"vae": [
"700:673",
2
],
"image": [
"700:674",
0
],
"bboxes": [
"700:678",
0
]
},
"class_type": "SDPoseKeypointExtractor",
"_meta": {
"title": "SDPoseKeypointExtractor"
}
},
"700:674": {
"inputs": {
"resize_type": "scale longer dimension",
"resize_type.longer_size": 1024,
"scale_method": "lanczos",
"input": [
"700:692",
0
]
},
"class_type": "ResizeImageMaskNode",
"_meta": {
"title": "调整图像/掩码大小"
}
},
"700:672": {
"inputs": {
"draw_body": true,
"draw_hands": true,
"draw_face": true,
"draw_feet": true,
"stick_width": 4,
"face_point_size": 2,
"score_threshold": 0.51,
"draw_head": true,
"keypoints": [
"700:671",
0
]
},
"class_type": "SDPoseDrawKeypoints",
"_meta": {
"title": "SDPoseDrawKeypoints"
}
},
"700:673": {
"inputs": {
"ckpt_name": "sdpose_wholebody_fp16.safetensors"
},
"class_type": "CheckpointLoaderSimple",
"_meta": {
"title": "Checkpoint加载器(简易)"
}
},
"700:677": {
"inputs": {
"unet_name": "rt_detr_v4-x-hgnet_fp16.safetensors",
"weight_dtype": "default"
},
"class_type": "UNETLoader",
"_meta": {
"title": "UNet加载器"
}
},
"700:678": {
"inputs": {
"threshold": 0.5,
"class_name": "person",
"max_detections": 2,
"model": [
"700:677",
0
],
"image": [
"700:674",
0
]
},
"class_type": "RTDETR_detect",
"_meta": {
"title": "RT-DETR 检测"
}
},
"700:692": {
"inputs": {
"video": [
"705",
0
]
},
"class_type": "GetVideoComponents",
"_meta": {
"title": "获取视频元素"
}
}
}
```

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the bundled video_minimax_h3_fun_controlnet_union workflow on Windows with the listed MiniMax H3 models, first with the compiler enabled and then with --disable-comfy-compiler. Inspect comfy/ldm/minimax/model.py around line 586 and the sampler path in comfy/samplers.py, then repeat with custom nodes disabled to separate causes. Done means the workflow completes without aborting or reports a recoverable error, with the relevant configuration documented.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
backend, machine-learning, performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.