Nodes/Nukun_ComfyUI_Nodes/Tiled HiRes Fix Advanced (Nukun)
ComfyUI Node

Tiled HiRes Fix Advanced (Nukun)

HiResFix that tiles the whole pipeline, not just the sampler

By OnekoSL·Created 3 months ago·Updated 11 days ago· 1
Tiled HiRes Fix Advanced (Nukun)
  • image
  • upscale_model
  • model
  • positive
  • negative
  • vae
  • final_image
  • upscaled_image
  • refined_latent
  • seed
  • settings_report
seed0
steps20
cfg3.5
sampler_nameeuler
schedulersimple
denoise0.40
tile_width1024
tile_height1024
tiling_strategysimple
vae_tile_size1024
vae_overlap64
noise_deviceauto
noise_profilegaussian
noise_strength1.00
detail_bias0.35
use_reference_latenttrue
use_differential_diffusiontrue
differential_strength0.70
previewdisable

HiResFix is the standard answer to "my image is good but low-res," and its standard failure is VRAM: a 2× upscale of a 1024×1024 image needs a 2048×2048 latent, which is where modest GPUs tap out. This node does HiResFix the tiled way - upscale the model, then refine with tiled sampling - but unlike the pack's other tiled wrapper (which needs Ultimate SD Upscale), it stays in ComfyUI core: ImageUpscaleWithModel, tiled VAE encode/decode, and the optional ComfyUI_TiledKSampler for the sampling behavior. That's the "Advanced" in the name: the whole pipeline is tiled, so the memory ceiling is per-tile, not per-image.

The upscaling doc in the KB frames the trade clearly: the tiled route is "arbitrary output size on 6GB," the classic VRAM fix for print-size or 4K goals. This node packages that into one box.

How it works

Flow: image in → upscale with upscale_model (a 4x or 2x ESRGAN-style model loaded as UPSCALE_MODEL) using the model's native scale → tiled VAE encode (vae_tile_size 1024, vae_overlap 64) → tiled KSampler refine → tiled VAE decode → final_image.

The defaults mirror the author's local Pony v7 workflow and are genuinely good starting points: steps 20, cfg 3.5, denoise 0.4, tile_width/tile_height 1024, tiling_strategy simple. Two quality toggles: use_reference_latent (on) and use_differential_diffusion (on at differential_strength 0.7) - differential diffusion tells the sampler which areas are already fine, so tiles don't over-redraw the upscaled detail. The noise side plugs into the pack's Universal profiles (noise_profile, noise_strength, detail_bias), so you can refine with pony_v7_stage2_violet or pyramid_mix instead of plain gaussian if you want a textured redraw.

Outputs: final_image, the raw upscaled_image (before refinement - great for A/B), refined_latent for further sampling, seed, and a settings_report string. Set denoise = 0 and it skips sampling entirely, returning just the upscaled tiled VAE round trip - useful for checking your VAE handles the size.

Installing it

Pack install plus one optional companion:

cd ComfyUI/custom_nodes
git clone https://github.com/OnekoSL/Nukun_ComfyUI_Nodes.git

Restart ComfyUI. For full functionality install ComfyUI_TiledKSampler via Manager (the README lists it as required for this node; the rest of the pipeline is core). You also need an upscaler model file - a 4x ESRGAN model in your models/upscale_models/ folder.

Common issues

Seams are the classic tiled failure. The simple tiling strategy is fastest and can show seams; switch tiling_strategy to random when hiding seams matters more than runtime - that's the documented trade. If tiles diverge in style, that's the "tiles not agreeing" problem the KB's upscaling doc warns about: raise denoise carefully (too high and tiles drift further apart, not less) or check use_differential_diffusion is on. FreeU, SpotDiffusion, and TiledDiffusion patches should stay external to this node - apply them as model patches before it if you want to test them, because it doesn't add its own. And if denoise looks ignored, check you didn't leave it at 0 from the round-trip test.

CategoryNukun/Sampling

Inputs (25)

NameTypeDefaultDescription
imageIMAGE
upscale_modelUPSCALE_MODEL
modelMODEL
positiveCONDITIONING
negativeCONDITIONING
vaeVAE
seedINT00–18446744073709550000Seed used by the tiled HiRes refine pass.
stepsINT201–10000
cfgFLOAT3.50–100
sampler_nameCOMBOeuler44 options: euler, euler_cfg_pp, euler_ancestral, euler_ancestral_cfg_pp, heun, heunpp2, +38
schedulerCOMBOsimple9 options: simple, sgm_uniform, karras, exponential, ddim_uniform, beta, +3
denoiseFLOAT0.400–1
tile_widthINT1024256–8192
tile_heightINT1024256–8192
tiling_strategyCOMBOsimple4 options: random, random strict, padded, simple
vae_tile_sizeINT102464–4096
vae_overlapINT640–4096
noise_deviceCOMBOautoDevice used to create Nukun noise before handing it to the tiled sampler.
noise_profileCOMBOgaussianUniversal Nukun noise profile for tiled refinement.
noise_strengthFLOAT1.000–5
detail_biasFLOAT0.350–1Only affects composite noise profiles.
use_reference_latentBOOLEANtrueAttach the encoded upscaled image to positive conditioning as reference_latents.
use_differential_diffusionBOOLEANtruePatch the refine model with Differential Diffusion.
differential_strengthFLOAT0.700–1
previewCOMBOdisableEnable tiled latent previews during sampling. Disable is much faster.

Outputs (5)

NameTypeDescription
final_imageIMAGE
upscaled_imageIMAGE
refined_latentLATENT
seedINT
settings_reportSTRING