π§© Egregora Spatial Tensor Pack
The advanced plumbing for injecting spatial data into ARMD at runtime
- image_a
- image_b
- latent_a
- latent_b
- runtime_payload_adapter
Here's the honest version: if you're reading this because a beginner guide told you to install Egregora-ARMD, you almost certainly do not need Egregora Spatial Tensor Pack yet. This is one of the pack's three "runtime payload" nodes - advanced plumbing that lets you feed extra spatial data (images, latents) into the regional denoising engine mid-run. You'll reach for it only when you understand why, and the good news is it's easy to understand.
What "runtime payload adapter" means
When Egregora Adaptive Diffusion Apply runs, each denoising pass slices the latent into region crops and processes them in batches. The mixer can also inject extra per-region data into those passes - but it has a contract: anything you want injected has to come in as a runtime_payload_adapter that implements build_payload(latent, timestep, cond_dict). That adapter is the optional input on Adaptive Diffusion Apply. These pack/merge nodes exist to build that adapter without hard-coding one workflow's assumptions.
Egregora Spatial Tensor Pack builds an adapter that carries spatial tensors - IMAGE and LATENT data. The reason that's useful: the mixer checks whether a payload value is a spatial tensor and, if so, slices it to match each region batch's context bboxes using the same plan geometry that drives everything else. So a control-like image you pack here gets region-sliced in lockstep with the latent, which is how you'd get structural guidance (think ControlNet-flavored conditioning) into a regional run without fighting the pack's internals.
The inputs
Four string name fields and four optional tensors:
name_image_a,name_image_b,name_latent_a,name_latent_b- the keys your tensors travel under inside the payload. Defaults likespatial_image_aare fine until you need a specific key to match what the runtime expects.image_a,image_b,latent_a,latent_b- the actual data. All optional; leave a slot empty and it simply doesn't get packed.
Output is a single runtime_payload_adapter.
A warning about ControlNet
The README is careful here and you should be too: ARMD can regionalize compatible spatial tensors and precomputed residual dictionaries, but it does not guarantee support for every native ControlNet chain - in particular, some Z-Image-specific ControlNet Union workflows need separate integration. So don't assume that packing a ControlNet output here makes it work; treat it as the pack's sanctioned route for spatial conditions and check whether your specific control chain is one of the compatible ones.
Installing
Same pack, same drill:
cd ComfyUI/custom_nodes
git clone https://github.com/lucasgattas/ComfyUI-Egregora-ARMD
restart, or install "ComfyUI-Egregora-ARMD" via ComfyUI Manager. No models to download; the dependencies are numpy, opencv-python, PyWavelets and torch. Like the whole pack - a small, honest, research-flavored family of nodes from Lucas Gattas (mrgattax) - this node is cleanly scoped: pack spatial data, hand the adapter to Adaptive Diffusion Apply, and let the mixer handle slicing. If you don't need structural guidance per region, skip it without guilt.
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| name_image_a | STRING | spatial_image_a | β |
| name_image_b | STRING | spatial_image_b | β |
| name_latent_a | STRING | spatial_latent_a | β |
| name_latent_b | STRING | spatial_latent_b | β |
| image_aopt | IMAGE | β | |
| image_bopt | IMAGE | β | |
| latent_aopt | LATENT | β | |
| latent_bopt | LATENT | β |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| runtime_payload_adapter | EGREGORA_RUNTIME_PAYLOAD_ADAPTER | β |