🌊hua_gradio_UNET Loader
The UNet loader for Flux-style workflows, with fp8 built in
- MODEL
Hua_UNETLoader (🌊hua_gradio_UNET Loader) is the pack's version of the stock UNETLoader - the loader for Flux-style workflows where the model ships as a separate diffusion_models file instead of a single combined checkpoint. The unet_name dropdown is driven by the pack's Gradio frontend, so your webui users can pick the diffusion model themselves, and it carries the fp8 weight-dtype options that matter for running these big models on consumer cards.
Mechanically it's a thin wrapper around ComfyUI's own load_diffusion_model. You give it unet_name (populated from models/diffusion_models), weight_dtype, and a name label, and it returns a single MODEL output. The dtype dropdown maps to ComfyUI's fp8 paths: default loads the file as-is, fp8_e4m3fn and fp8_e5m2 are the two common fp8 formats, and fp8_e4m3fn_fast additionally enables ComfyUI's fp8 optimizations. In practice: fp8_e4m3fn is the one most people reach for with Flux - it's the solid middle ground, roughly half the VRAM of the full model with minimal visible quality loss. fast shaves a bit more time if your card can take it. If a model was already quantized on disk, default keeps whatever precision it shipped in.
Inputs:
unet_name- dropdown frommodels/diffusion_models(this is what the webui controls).weight_dtype-default,fp8_e4m3fn,fp8_e4m3fn_fast,fp8_e5m2.name- label.
Output: MODEL, which feeds your sampler - same as any UNet loader. Note the schema has no CLIP output: Flux's text encoders (T5, CLIP-L) load separately, and its VAE comes from its own file. That's normal for this node type, not a bug.
Install: ComfyUI Manager → "ComfyUI_to_webui", or
cd ComfyUI/custom_nodes
git clone https://github.com/kungful/ComfyUI_to_webui.git
restart. The pack downloads nothing itself; whatever diffusion_models you've already got is what shows up in the dropdown. If the webui's model list looks stale, hit the refresh-model button.
The trap to watch: this is a singleton in the frontend like the checkpoint loader - one UNet dropdown, no matter how many instances. And remember the README's standing warning about the random-seed node applies doubly here: Flux workflows are slow, so you really don't want ComfyUI deciding "same JSON, nothing to do" after a long run. If you're packaging a Flux text-to-image graph for a friend, this node plus the seed, resolution, and output nodes is the core skeleton - and fp8 is what keeps it running on a mid-range card.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| unet_name | COMBO | 0 options: | |
| weight_dtype | COMBO | 4 options: default, fp8_e4m3fn, fp8_e4m3fn_fast, fp8_e5m2 | |
| name | STRING | Hua_UNETLoader | 节点名称 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| MODEL | MODEL | — |