Nodes/ComfyUI-piFlow/Pixel Preview
ComfyUI Node

Pixel Preview

See what AsymFlow is actually drawing before the render finishes

By Lakonik·Created 10 months ago·Updated 23 days ago· 186
Pixel Preview
  • model
  • vae
  • MODEL

If you've run an AsymFlow workflow in this pack and seen a noisy static-filled preview that never looks like your image, this node is the fix. Pixel Preview patches the model so ComfyUI's built-in preview system decodes the "latent" as actual pixels instead of trying to color-map Oklab data as if it were a normal diffusion latent.

The reason it exists: AsymFlow models don't denoise in latent space. They generate pixels directly, in the Oklab color space, so the tensor ComfyUI is happily denoising is the image. ComfyUI's default preview path assumes a latent with a latent2rgb mapping, and feeding it pixel-space Oklab data produces garbage. This node tells the sampler "no, decode this through the Oklab codec," and suddenly you get a live, accurate preview of the image as it emerges.

How it works

Mechanically it's two parts. First, the node itself: it takes your model and the Oklab VAE (the Oklab Color Encoder node's output), clones the model, and attaches a custom latent format that marks the model as a pixel-space model and hands the previewer your VAE as the decode codec. Second, the pack monkeypatches ComfyUI's latent_preview machinery at import time so it knows to use that codec. It's a global patch, but it's inert on normal latent-space models - it only activates when a model carries the pixel-latent marker, so it won't disturb your Flux or SDXL workflows.

Two inputs, both required: model and vae. You wire your loaded AsymFlow model in, plug the Oklab Color Encoder's VAE output into vae, and take the returned MODEL on into the sampler (in the shipped workflow it sits between Load AsymFlow Model and the sampler, alongside Clamp Denoised). That's the whole node.

Enabling the previews

The preview only fires when ComfyUI's preview method is set to auto (or latent2rgb). Launch ComfyUI with:

./main.py --preview-method auto --preview-size 1024

The docs call out exactly this command. Without --preview-method auto, the monkeypatch has nothing to hook and you'll get no preview at all.

Install and gotchas

Install comes with the pack:

cd ComfyUI/custom_nodes
git clone https://github.com/Lakonik/ComfyUI-piFlow

…then restart ComfyUI (or use ComfyUI Manager and search "ComfyUI-piFlow"). The pack needs ComfyUI 0.17.0 or newer and tracks latest releases closely, so update ComfyUI before you chase preview bugs. Because the previewer patch runs at import time, you must restart ComfyUI after installing - a fresh reload of the workflow isn't enough.

Where people get burned: forgetting the launch args and assuming the node is broken, or dropping the node into a pi-Flow (latent-space) workflow where it's pointless - pi-Flow models preview fine through the normal path. This node is strictly for AsymFlow pixel-space generation, where the preview is otherwise unusable.

CategoryLakonLab

Inputs (2)

NameTypeDefaultDescription
modelMODEL
vaeVAE

Outputs (1)

NameTypeDescription
MODELMODEL