Nodes/WAS Affine/KSampler Affine
ComfyUI Node

KSampler Affine

A ComfyUI node in sampling/ksampler with 21 inputs and 2 outputs.

By WASasquatch·Created 12 months ago·Updated 4 months ago· 5
KSampler Affine
  • model
  • positive
  • negative
  • latent_image
  • affine_schedule
  • external_mask
  • options
  • noise_options
  • LATENT
  • MASK
seed0
steps20
cfg4.5
sampler_name
scheduler
denoise1.00
affine_interval1
max_scale1.200
max_bias0.000
patternwhite_noise
affine_seed0
affine_seed_incrementfalse
merge_inactive_stepstrue
Categorysampling/ksampler

Inputs (21)

NameTypeDefaultDescription
modelMODELDiffusion model to sample with.
positiveCONDITIONINGPositive prompt conditioning.
negativeCONDITIONINGNegative prompt conditioning.
latent_imageLATENTInput latent to continue sampling from.
seedINT00–2147483647Random seed for the sampler.
stepsINT201–200Number of denoising steps.
cfgFLOAT4.50–100Classifier-free guidance scale. Can be a single float value or a list of float values for per-step CFG. If list is shorter than total steps, the last value will be repeated for remaining steps.
sampler_nameCOMBOThe algorithm used when sampling, this can affect the quality, speed, and style of the generated output.
schedulerCOMBOThe scheduler controls how noise is gradually removed to form the image.
denoiseFLOAT1.000–1Fraction of noise to remove (lower = stronger preserve).
affine_intervalINT11–100Interval in steps to apply affine (1 = every step). Does not change total steps.
max_scaleFLOAT1.2000–2Upper bound on multiplicative affine strength applied at schedule peak.
max_biasFLOAT0.000-2–2Upper bound on additive bias applied at schedule peak.
patternCOMBOwhite_noiseMask/noise pattern used when applying affine between sampling steps.
affine_seedINT00–2147483647Seed for affine mask generation (separate from sampler seed).
affine_seed_incrementBOOLEANfalseIf enabled, increment affine seed for each group application (temporal masks).
affine_scheduleDICTUse WASAffineScheduleOptions (interpreted over total steps).
external_maskoptIMAGEOptional external mask image; when provided and pattern != external_mask, it gates where affine applies.
optionsoptDICTBase options DICT for affine (e.g., common or full options).
noise_optionsoptDICTPattern-specific overrides that layer onto 'options'.
merge_inactive_stepsoptBOOLEANtrueGreedily merge steps outside the active schedule window into larger batches.

Outputs (2)

NameTypeDescription
LATENTLATENT
MASKMASK