Nodes/Nynxz H3/H3 Row Chunk
ComfyUI Node

H3 Row Chunk

An illegal memory access' on long clips

By Nynxz·Created about a month ago·Updated 25 days ago· 4
H3 Row Chunk
  • model
  • MODEL
  • report
chunk_rows0

The scariest error in H3 is not the one that tells you you're out of VRAM. It's CUDA error: an illegal memory access was encountered - which usually surfaces at some later, unrelated allocation and makes you suspect your GPU is dying. More often than not, it's an integer overflow: past roughly 75k rows, a projection's intermediate exceeds CUDA's int32 element limit. H3 Row Chunk splits the qkv projection and MLP into row chunks so that can't happen. It's the node you install for the moment you push past ~10.5 seconds at 1344×768.

How it works

The node takes a model and chunk_rows (default 0 = auto). At 0 it picks a size from the sequence: small enough to stay under the int32 limit with margin, and sized to hold each widened intermediate near 1 GiB. The key claim, and it's a good one: these projections are row-wise, so chunking computes the same function. It's not an approximation and costs no quality - it's just doing the matrix product in slices that fit CUDA's counting.

When do you need it? The README's line is "past roughly 10.5s at 1344×768." Under that, H3 fits inside int32 and this node changes nothing. Over it, this is the difference between a running workflow and a session-killing crash. The report output tells you where the int32 ceiling falls for your model and what chunking does at a few clip lengths - worth reading once so you know the shape of the problem you're solving.

The inputs that matter

Just two: model (passes through patched) and chunk_rows. Set a smaller number than auto only if a run still faults - some kernels allocate workspace beyond their output, and the auto pick can't always see that. The tooltip says it plainly: don't tune it preemptively.

The honest take

This is the most "boring" node in the pack, and that's the compliment. It doesn't trade quality for speed, it doesn't change your schedule - it just removes a crash that would otherwise end your run. If you only make short clips, you may never need it. The day you try a 15-second H3 piece and the run dies with an illegal-memory-access at a random point, you'll be very glad it exists.

Install

Pack install: ComfyUI Manager → "Nynxz H3", or:

cd ComfyUI/custom_nodes
git clone https://github.com/Nynxz/ComfyUI-NynxzH3

Restart. Pure Python, no dependencies, ComfyUI 0.30.0+.

The one-liner

Leave chunk_rows at 0, chain it in before the sampler on long-clip workflows, and let auto do its job. If you're still hitting illegal-memory-access after this, then it's time to suspect the GPU.

CategoryNynxz/H3/Sampling

Inputs (2)

NameTypeDefaultDescription
modelMODELA MiniMax H3 model.
chunk_rowsINT00–1000000Rows per chunk. 0 picks a size from the sequence: small enough to stay under the int32 limit with margin AND to hold each widened intermediate near 1 GiB. Set a smaller number only if a run still faults — some kernels allocate workspace beyond their output.

Outputs (2)

NameTypeDescription
MODELMODEL
reportSTRINGWhere the int32 ceiling falls for this model, and what chunking does at a few clip lengths.