Universal FP8 / NVFP4 Quantizer (Legacy ID)
The 'Wan' NVFP4 node that isn't actually Wan-only
- output_path
- log
If you loaded a saved workflow and it's complaining about a missing node called NVFP4WanQuantizer, relax - that's not a different tool, it's this pack's old name. The display name even tells you: "Universal FP8 / NVFP4 Quantizer (Legacy ID)". In the source, this class and NVFP4UniversalQuantizer map to the same node, and the Wan-named ID is kept registered purely so workflows saved under the old name still load. There is nothing Wan-specific left in it.
What you actually got
The node is a self-contained converter (category model/quantization, an output node - you don't wire it into your generation graph). Pick a .safetensors from your models/diffusion_models folder, run it, and it writes a mixed FP8/NVFP4 quantized copy next to the original. It supports SDXL, Wan 2.2, Qwen Image and Edit, Z-Image, FLUX and FLUX.2, plus a generic transformer fallback - the architecture dropdown has nine entries, and auto detects which you've loaded from the tensor names.
Worth saying once, plainly: if you're here specifically for Wan, don't assume NVFP4 is the answer. The legacy name suggests the pack started life aimed at Wan - and Wan 2.2's 14B is exactly the model that makes people desperate for VRAM - but the community's early NVFP4 experiments on Wan 2.2 came back noisy with only ~5% speedup, a world away from Qwen Image Edit where NVFP4 roughly halved generation time. FP8 is the proven baseline for running Wan 2.2 on consumer cards. On a 50-series, run estimate_only first and A/B the result before you commit to NVFP4 for video.
How it works (same machinery)
The node shells out to the pack's quantizer.py, which opens the safetensors, classifies each weight as attention/FFN/other-linear/sensitive/nonquant, and applies ComfyUI's TensorCoreFP8E4M3Layout or TensorCoreNVFP4Layout on GPU. Sensitive layers (embedders, final projection, modulation) and anything under min_elements stay bf16; convolutions, norms, and biases always stay bf16, since NVFP4 here only handles 2D linear weights. Output is <source>_nvfp4.safetensors in the same folder unless you set output_filename (a filename only - no paths, it must sit beside the source).
The one input a beginner actually sets is preset: balanced (attention FP8, FFN NVFP4, other linear FP8) is the default and a fine place to start; quality keeps more at bf16; aggressive pushes attention and FFN both to NVFP4; fp8_all is the safe call on pre-Blackwell cards. And flip estimate_only on once before saving anything - it reports the detected architecture and the size reduction in log without writing a file. Outputs are two strings: output_path and log.
Install
Same pack, two IDs - one install covers both:
cd ComfyUI/custom_nodes
git clone https://github.com/thepororo/ComfyUI-NVFP4-Quantizer.git
or grab it from ComfyUI Manager (search "ComfyUI-NVFP4-Quantizer"), then restart. No requirements.txt to worry about; the heavy lifting is ComfyUI's own comfy/quant_ops, so the real prerequisites are CUDA and a ComfyUI/comfy-kitchen build that includes TensorCoreNVFP4Layout.
If you're stuck with this ID
If a workflow requires it and you have the pack installed, it just works - that's the point of the alias. Adding a node fresh and see both names? Pick NVFP4UniversalQuantizer; the Wan one is a legacy bookmark. And the usual warnings apply here too: start from an original BF16/FP16 file, never re-quantize an existing quant, keep the source, and don't panic when the canvas looks frozen while the subprocess churns - the log only shows up when it's done.
Inputs (11)
| Name | Type | Default | Description |
|---|---|---|---|
| model_name | COMBO | 0 options: | |
| output_filename | STRING | — | |
| architecture | COMBO | auto | 9 options: auto, sdxl, wan22, qwen_image, qwen_image_edit, z_image, +3 |
| preset | COMBO | balanced | 5 options: balanced, quality, aggressive, fp8_all, custom |
| attention | COMBO | fp8 | 6 options: keep, bf16, fp16, fp32, fp8, nvfp4 |
| ffn | COMBO | nvfp4 | 6 options: keep, bf16, fp16, fp32, fp8, nvfp4 |
| other_linear | COMBO | fp8 | 6 options: keep, bf16, fp16, fp32, fp8, nvfp4 |
| sensitive | COMBO | bf16 | 4 options: keep, bf16, fp16, fp32 |
| nonquant | COMBO | bf16 | 4 options: keep, bf16, fp16, fp32 |
| min_elements | INT | 655360–100000000 | — |
| estimate_only | BOOLEAN | false | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| output_path | STRING | — |
| log | STRING | — |