LTXVBlockswap
Ship LTX 13B's transformer blocks to RAM and run the full model on a small card
- model
- MODEL
LTX Video's 13B (0.9.7) is the release that made the family competitive - but it's a ~26GB bf16 DiT, and if your card is 12 or 16GB, that's the whole problem. The obvious answer is a GGUF quant, and a lot of people find that path painful: quantized LTX 13B handles LoRAs poorly, and you lose the exact behavior of the base dev weights. This node goes the other direction. LTXBlockswap (listed as "LTXVBlockswap" in the menu) is a single tiny node that takes your LTX 13B model and, the moment it loads, shoves a chunk of its 47 transformer blocks off to system RAM. You keep the full-precision weights; you pay for it in PCIe bandwidth instead of VRAM.
How it actually works
It's the block-swap trick that bubbled up from Kijai's WanVideoWrapper, and the shipped code is almost embarrassingly small. The node clones the model patcher and registers an ON_LOAD callback. When ComfyUI loads the model, the callback checks that the base model is an LTXV and moves the first N transformer blocks to the offload device - your CPU RAM - then soft-empties the cache and forces a garbage-collect. ComfyUI's own low-VRAM machinery then pulls each block back across PCIe as the sampler needs it. Nothing runs through any API, nothing downloads weights, no keys. It's just a load-time relocation.
Only three inputs exist, and really only one of them matters:
- transformer_blocks_to_swap (default 10, max 47) - how many of the 13B's 47 double blocks to push to RAM. Ten blocks is roughly a third of the transformer, call it a few GB of headroom. This is the knob you'll actually turn.
- offload_txt_in and offload_img_in (both default off) - push the text and image conditioning input layers out too, for a bit of extra squeeze on tight cards.
- Output: a MODEL, which you wire between your LTX loader and the sampler. That's the whole graph.
Installing it
ComfyUI Manager → search "ComfyUI-LTX13B-Blockswap" → install, restart. Or the manual route:
cd ComfyUI/custom_nodes
git clone https://github.com/Njbx/ComfyUI-LTX13B-Blockswap
Then restart ComfyUI. There's nothing else to fetch - no model files, no extra runtime. It depends on comfy.patcher_extension (CallbacksMP), which has been in core ComfyUI for a while, so a current install just works.
Where people get burned
The classic complaint is "it doesn't change my VRAM at all," and there's a real Reddit thread (May 2025) saying exactly that. Working through it, three things bite:
- It's not actually in the model path. The node must sit between the model loader and the sampler. If you dropped it in but left the old wire running, it never touches the model - that's the "is the node even connected?" comment in that thread.
- The swap fires on load. It's an
ON_LOADhook on a clone of the patcher. If ComfyUI already has the model cached from an earlier run, the callback may not re-trigger. Force a fresh load (or restart) to see the effect. - Default 10 is conservative. A 13B on a 12GB card often needs 20-40 blocks moved before you see the VRAM needle move. Don't be shy; the node's max of 47 exists for a reason.
And set expectations before you chase memory: this is a fit, not a speedup. GPU memory bandwidth is roughly an order of magnitude higher than PCIe 4.0, so blocks living in RAM get dragged over the bus on every pass. You're trading several minutes per clip for the ability to run the unquantized model at all - worthwhile if you're feeding it LoRAs or want base dev behavior, pointless if you just want speed, in which case the distilled checkpoint or a GGUF is the better tool.
Also note the scope: it only hooks models that report as LTXV. That's the 13B it's named for (and the smaller 0.9.x models, harmlessly). It does nothing for LTX-2 / 2.3 - that's a different architecture and won't match the check. Finally, have real system RAM to spare; if Windows starts thrashing the page file, the whole thing crawls.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| transformer_blocks_to_swap | INT | 100–47 | Number of double blocks to swap |
| offload_txt_in | BOOLEAN | false | Offload txt_in layer |
| offload_img_in | BOOLEAN | false | Offload img_in layer |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| MODEL | MODEL | — |