Flux Sampler
The entire sampling stage in one node — width, height, scheduler, decode and all
- model
- positive
- negative
- vae
- image
- latent
A stock Flux.2 sampling stage is five or six nodes: RandomNoise, a guider, KSamplerSelect, a scheduler, an empty-latent node, SamplerCustomAdvanced, and a VAEDecode on the far side. Flux Sampler (class DiztraidoProcessingBundle) replaces that whole block with one node. Feed it a model, positive and negative conditioning, and (optionally) a VAE, and it returns an image and the raw latent. If the pack's loaders shrink the front of a Flux graph, this is what shrinks the middle.
The important thing to know before you reach for it: the pipeline inside is Flux.2-native. It calls ComfyUI's RandomNoise, CFGGuider, KSamplerSelect, Flux2Scheduler, EmptyFlux2LatentImage, SamplerCustomAdvanced, and optional VAEDecode - the Flux2Scheduler and EmptyFlux2LatentImage nodes are the ones ComfyUI added specifically for Flux.2/Klein. So this isn't a generic KSampler substitute; it's a sampler for the Flux.2 family (dev and Klein), and if you use it with a Flux.1 model you're likely to get odd results. It also fuses in the pack's resolution math: the aspect_ratio and megapixels inputs compute width/height for you using the same logic as the pack's Resolution Selector, rounded to the multiple you set.
The inputs that matter
model,positive,negative- the standard trio from your loaders and text encoding. For Flux.2,negativeis typically a blank conditioning; the guidance lives in the schedule, not CFG.noise_seed,steps,cfg(default 4.0),sampler_name(defaulteuler, from the full sampler list) - familiar KSampler territory. TheFlux2Schedulersets the schedule from steps, so sampler and steps are the main dials.aspect_ratio,megapixels,multiple- the resolution selector trio. Pick an aspect ratio and a megapixel target (1.0 = 1024²), and width/height get computed and rounded tomultiple(default 8).width/height- only used whenaspect_ratioisCustom.batch_size- how many images per run.decode_image- on by default. Turn it off to skip VAE decoding if you only need the latent.
Optional: vae. It's lazy-loaded, and here's the gotcha: if decode_image is on and you use the image output, you must connect a VAE or the node raises a clear error ("Connect a VAE to Flux Sampler…"). If you only use the latent output, you can leave it disconnected and the pack won't touch the VAE at all.
Outputs: image (IMAGE) and latent (LATENT). latent is great for chaining to an upscaler for a second pass.
How to install
Part of Diztraido Nodes. ComfyUI Manager → search "Diztraido Nodes" → install diztraido-nodes → restart. Or:
cd ComfyUI/custom_nodes
git clone https://github.com/jadervasque/ComyUI-Diztraido.git
Restart and it's under the Diztraido flux category. No extra dependencies - it calls ComfyUI's native sampling nodes, which means it needs a reasonably current ComfyUI (the Flux.2-native scheduler and latent nodes are newer additions).
Common issues
Three things to watch. First, the VAE requirement above - the error message tells you exactly what to do, but it's the most common stumble on first use. Second, Flux2Scheduler is tuned for Flux.2 dev; Klein is guidance-distilled and behaves differently, so if your Klein output looks off on the default schedule, the community answer is a custom/Klein-tuned schedule, not cranking CFG. Third, because the node computes resolution from aspect ratio + megapixels, your width/height widgets are ignored unless you're in Custom mode - if you change width and nothing happens, that's why. And remember the resolution math only guarantees multiples of multiple; for Flux, keeping dimensions at multiples of 16 (or 32 for some quantizations) is still a good habit.
Inputs (15)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| positive | CONDITIONING | — | |
| negative | CONDITIONING | — | |
| noise_seed | INT | 00–9223372036854776000 | — |
| cfg | FLOAT | 4.00–100 | — |
| sampler_name | COMBO | euler | 44 options: euler, euler_cfg_pp, euler_ancestral, euler_ancestral_cfg_pp, heun, heunpp2, +38 |
| steps | INT | 501–10000 | — |
| aspect_ratio | COMBO | 1:1 (Square) | 23 options: 1:1 (Square), 2:3 (Portrait Photo), 3:2 (Photo), 3:4 (Portrait Standard), 4:3 (Standard), 9:16 (Portrait Widescreen), +17 |
| megapixels | FLOAT | 1.00.1–16 | — |
| multiple | INT | 88–128 | — |
| width | INT | 10248–16384 | — |
| height | INT | 10248–16384 | — |
| batch_size | INT | 11–4096 | — |
| decode_image | BOOLEAN | true | — |
| vaeopt | VAE | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| latent | LATENT | — |