π Sampler Tiled Context Advanced
Sample each tile with the rest of the image in mind, not in isolation
- noise
- sampler
- sigmas
- guider
- latent_image_batch
- global_context_latent
- tile_data
- output
- denoised_output
Not in the README's node table - this one's new enough that it postdates the last documented release, and it's also the most advanced node in the whole pack. If you've done tiled diffusion before (Ultimate SD Upscale, Tiled Diffusion + ControlNet Tile), you already know the core problem it's solving: sample each tile of a large image independently, and adjacent tiles have no idea what the others are doing. They diverge - slightly different color, slightly different texture decisions - and you get a patchwork, no matter how good your blending is afterward. The community's answer for years has been ControlNet Tile, which feeds each tile a condition image so it stays faithful to a shared source. Sampler Tiled Context Advanced takes a different, more direct route: it's a custom sampler node that processes latent tiles with awareness of a shared global context latent baked into the sampling process itself, rather than fixed up after the fact.
How it works
This plugs into ComfyUI's modern custom-sampling API - the same family as SamplerCustomAdvanced, taking a noise, sampler, sigmas, and guider rather than the simpler all-in-one KSampler widgets. That means it's compatible with whatever custom schedulers, samplers, or guiders you've already built into a graph, rather than locking you into a fixed sampler choice.
The two things that make it "context-aware" instead of a plain per-tile sampler are attn_ctx_strength and adain_ctx_strength. Both default to 0.5, and they operate on different signals during sampling: attention-based context sharing lets each tile's denoising process reference information from the global context through the model's attention mechanism, which is how transformer-style models share information across spatial locations in the first place. AdaIN context sharing - Adaptive Instance Normalization - is a different, cheaper trick: it matches statistical properties (roughly, the mean and variance) of a tile's features to the global context's, the same mechanism style-transfer techniques use to make one image adopt another's "look." Applied here, it nudges each tile's color and tonal character toward matching the whole image rather than drifting independently, which is a large part of what makes tile seams visible in the first place.
use_coordinates (enable/disable) presumably controls whether the tiles' actual spatial position (from tile_data) factors into how context gets applied - worth trying both if your tiles at the image's edges behave differently from ones in the middle.
Inputs and outputs that matter
noise,sampler,sigmas,guider- the standard custom-sampling building blocks, same as you'd feedSamplerCustomAdvanced.latent_image_batch- your batch of tile latents, typically VAE-encoded from GOAT's Image Tiler output.global_context_latent- the shared reference the tiles get pulled toward; likely a latent of the whole image (or a downscaled version of it) so every tile has the same "big picture" to stay consistent with.tile_data- the bundle from Image Tiler describing where each tile sits.attn_ctx_strength/adain_ctx_strength(0β1, default 0.5 each) - how hard each context-sharing mechanism pulls. Push these up if you're still seeing divergence between tiles; pull them down if tiles are losing their own local detail in favor of matching the global context too closely.
Two outputs: output (LATENT, the raw sampler result) and denoised_output (LATENT) - decode whichever fits your pipeline, then reassemble with Image Untiler.
How to install it
ComfyUI Manager: search "GOAT Nodes", install, restart. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/AconexOfficial/ComfyUI_GOAT_Nodes.git
then restart ComfyUI. No extra models beyond whatever checkpoint you're already sampling with.
Common issues & troubleshooting
This node has real prerequisites - it's not a drop-in KSampler replacement. It expects the newer custom-sampling graph shape (separate noise/sampler/sigmas/guider nodes), not a single all-in-one KSampler. If you're used to the simple sampler widget, budget time to learn ComfyUI's custom-sampling nodes first; this isn't the place to start with them.
Tiles still visibly diverge. Raise attn_ctx_strength and adain_ctx_strength together first - at the 0.5 default they're a starting point, not guaranteed-seamless. If divergence persists, check that global_context_latent is actually representative of the full image and not, say, accidentally just one of the tiles.
Output looks flat or loses local detail across tiles. The opposite failure - context sharing pulled too hard, homogenizing tiles toward the global reference instead of letting each one contribute its own detail. Bring both context strengths down rather than up.
This is the middle of a three-node pipeline. It needs tile_data from Image Tiler going in, and its output needs to go through Image Untiler afterward to become one image again - it's not meant to run standalone.
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| noise | NOISE | β | |
| sampler | SAMPLER | β | |
| sigmas | SIGMAS | β | |
| guider | GUIDER | β | |
| latent_image_batch | LATENT | β | |
| global_context_latent | LATENT | β | |
| tile_data | TILE_DATA | β | |
| use_coordinates | COMBO | 2 options: enable, disable | |
| attn_ctx_strength | FLOAT | 0.500β1 | β |
| adain_ctx_strength | FLOAT | 0.500β1 | β |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| output | LATENT | β |
| denoised_output | LATENT | β |