Which ComfyUI samplers inject fresh noise at every step, where does that noise come from (CPU or GPU), and what does that mean for the claim that ComfyUI seeds are reproducible across hardware?
At the pinned commit the sampler functions receive the KSampler seed through extra_args. Ancestral samplers (e.g. euler_ancestral, dpm_2_ancestral, dpmpp_2s_ancestral) draw per-step noise from default_noise_sampler, which builds a torch.Generator on the latent's own device (seed+1 if that device is CPU) and samples in the latent dtype. SDE samplers use a Brownian-tree sampler on the CPU for dpmpp_sde, dpmpp_2m_sde and dpmpp_3m_sde and on the accelerator for the *_gpu variants. So the FAQ's CPU-noise argument covers the initial latent; for ancestral and *_gpu sampler runs the per-step noise comes from the sampling device's RNG, for which PyTorch gives no CPU/GPU equality promise.
Structured fields
{
"citations": [
{
"url": "https://github.com/Comfy-Org/ComfyUI",
"note": "ComfyUI 1a82e6d0 comfy/k_diffusion/sampling.py lines 78-88, 806-814, 1043-1048; comfy/samplers.py lines 971-990 (KSAMPLER_NAMES; inpaint random noise), 1226-1230 (extra_args seed)"
},
{
"url": "https://github.com/pytorch/pytorch/blob/b40a4f2c025f42d1c2d4ece32daa39295b436f72/docs/source/notes/randomness.md",
"note": "ComfyUI 1a82e6d0 comfy/k_diffusion/sampling.py lines 78-88, 806-814, 1043-1048; comfy/samplers.py lines 971-990 (KSAMPLER_NAMES; inpaint random noise), 1226-1230 (extra_args seed)"
},
{
"url": "https://github.com/AUTOMATIC1111/stable-diffusion-webui/blob/82a973c04367123ae98bd9abdf80d9eda9b910e2/modules/shared_options.py",
"note": "ComfyUI 1a82e6d0 comfy/k_diffusion/sampling.py lines 78-88, 806-814, 1043-1048; comfy/samplers.py lines 971-990 (KSAMPLER_NAMES; inpaint random noise), 1226-1230 (extra_args seed)"
},
{
"url": "https://github.com/comfyanonymous/ComfyUI_examples/blob/f9431bb000ce792094ff345446e22cac1ea6cef3/faq/README.md",
"note": "ComfyUI 1a82e6d0 comfy/k_diffusion/sampling.py lines 78-88, 806-814, 1043-1048; comfy/samplers.py lines 971-990 (KSAMPLER_NAMES; inpaint random noise), 1226-1230 (extra_args seed)"
}
]
}Evidence claims
- [inference] At the pinned commit the sampler functions receive the KSampler seed through extra_args. Ancestral samplers (e.g. euler_ancestral, dpm_2_ancestral, dpmpp_2s_ancestral) draw per-step noise from default_noise_sampler, which builds a torch.Generator on the latent's own device (seed+1 if that device is CPU) and samples in the latent dtype. SDE samplers use a Brownian-tree sampler on the CPU for dpmpp_sde, dpmpp_2m_sde and dpmpp_3m_sde and on the accelerator for the *_gpu variants. So the FAQ's CPU-noise argument covers the initial latent; for ancestral and *_gpu sampler runs the per-step noise comes from the sampling device's RNG, for which PyTorch gives no CPU/GPU equality promise. · locator: ComfyUI 1a82e6d0 comfy/k_diffusion/sampling.py lines 78-88, 806-814, 1043-1048; comfy/samplers.py lines 971-990 (KSAMPLER_NAMES; inpaint random noise), 1226-1230 (extra_args seed) source
Rights
| component | license | hosting | redistribution | modification | training | Evidence and notes |
|---|---|---|---|---|---|---|
| documentation | unknown | permitted | permitted | unknown | unknown | Applies to this original summary only, not to the cited sources. |
Linked records
- cites → https://github.com/AUTOMATIC1111/stable-diffusion-webui/blob/82a973c04367123ae98bd9abdf80d9eda9b910e2/modules/shared_options.py
- cites → https://github.com/comfy-org/comfyui
- cites → https://github.com/comfyanonymous/ComfyUI_examples/blob/f9431bb000ce792094ff345446e22cac1ea6cef3/faq/README.md
- cites → https://github.com/pytorch/pytorch/blob/b40a4f2c025f42d1c2d4ece32daa39295b436f72/docs/source/notes/randomness.md