Nodes/comfyui_jankdiffusehigh/DiffuseHighSampler
ComfyUI Node

DiffuseHighSampler

Jank DiffuseHigh sampler node, used for generating directly to resolutions higher than what the model was trained for. Can be connected to a SamplerCustom or other sampler node that supports a SAMPLER input.

By blepping·Created 2 years ago·Updated about a year ago· 37
DiffuseHighSampler
  • highres_sigmas
  • sampler
  • reference_image_opt
  • guidance_sampler_opt
  • reference_sampler_opt
  • vae_opt
  • upscale_model_opt
  • input_params_opt
  • SAMPLER
guidance_steps5
guidance_modeimage
guidance_factor1.00
fadeout_factor0.00
scale_factor2.00
renoise_factor1.00
iterations1
vae_modenormal
yaml_parameters
Categorysampling/custom_sampling/JankDiffuseHigh

Inputs (17)

NameTypeDefaultDescription
guidance_stepsINT5Number of guidance steps after an upscale.
guidance_modeCOMBOimageThe original implementation uses image guidance. This requires a VAE encode/decode per guidance step. Alternatively, you can try using guidance via the latent instead which is much faster.
guidance_factorFLOAT1.000–1Mix factor used on guidance steps. 1.0 means use 100% DiffuseHigh guidance for those steps (like the original implementation).
fadeout_factorFLOAT0.00Can be enabled to fade out guidance_factor. For example, if guidance_factor is 1 and guidance_steps is 4 then fadeout_factor would use these guidance_factors for the guidance steps: 1.00, 0.75, 0.50, 0.25
scale_factorFLOAT2.000.01–1000Upscale factor per iteration.
renoise_factorFLOAT1.00-1000–1000Strength of noise added at the start of each iteration. The default of 1.0 (100%) is the normal amount, but you can increase this slightly to add more detail.
iterationsINT1Number of upscale iterations to run. Be careful, this can add up fast - if you start at 512x512 with a 2.0 scale factor then 3 iterations will get you to 4096x4096.
vae_modeCOMBOnormalMode used for encoding/decoding images. TAESD is fast/low VRAM but may reduce quality (you will also need the TAESD encoders installed). Normal will just use the normal VAE node, tiled with use the tiled VAE node. Alternatively, if you have ComfyUI-TiledDiffusion installed you can use tiled_diffusion here.
highres_sigmasoptSIGMASSigmas used for steps after upscaling. Generally should be around 0.3-0.5 denoise. NOTE: I do not recommend plugging in raw 1.0 denoise sigmas here.
sampleroptSAMPLERDefault sampler used for steps. If not specified the sampler will default to non-ancestral Euler.
reference_image_optoptIMAGEOptional: Image used for the initial pass. If not connected, a low-res initial reference will be generated using the schedule from the normal sigmas.
guidance_sampler_optoptSAMPLEROptional: Sampler used for guidance steps. If not specified, will fallback to the base sampler. Note: The sampler is called on individual steps, samplers that keep history will not work well here.
reference_sampler_optoptSAMPLEROptional: Sampler used to generate the initial low-resolution reference. Only used if reference_image_opt is not connected.
vae_optoptVAEOptional when vae_mode is set to `taesd`, otherwise this is the VAE that will be used for encoding/decoding images.
upscale_model_optoptUPSCALE_MODELOptional: Model used for upscaling. When not attached, simple image scaling will be used. Regardless, the image will be scaled to match the size expected based on scale_factor. For example, if you use scale_factor 2 and a 4x upscale model, the image will get scaled down after the upscale model runs.
input_params_optoptDIFFUSEHIGH_PARAMSOptional: You can use a DiffuseHighParam node to specify additional parameters such as VAEs or upscale models.
yaml_parametersoptSTRINGAllows specifying custom parameters via YAML. You can also override any of the normal parameters by key. Note: When specifying paramaters this way, there is very little error checking.

Outputs (1)

NameTypeDescription
SAMPLERSAMPLERSAMPLER that can be connected to a SamplerCustom or other sampler node that supports a SAMPLER input.