Latent Upscale by 32 / 32整除潜空间放大 (T8)
Upscale your H3 latent without wrecking the aspect ratio
- latent
- latent
- width
- height
- report_json
Every H3 user eventually hits the same wall: you want to upscale your latent before the final decode, and the stock ComfyUI upscale node hands you back a width and height that aren't multiples of 32. Then the decode warps, or H3 refuses, or you get a silent aspect shift and only notice when the person's head looks wrong. This node exists to make that class of bug impossible. It's one of the pack's stable nodes - no Experimental tag - and the README lists it as one of the core nodes people actually use, which tells you it's a workhorse rather than a toy.
The job is narrow and it's done well: upscale a plain latent or the video part of a MiniMax H3 joint AV latent, and guarantee the returned pixel width and height are always divisible by 32.
How it works
The key fact about H3 is in the pixels_per_latent input: an H3 video latent uses 16 pixels per latent cell, not the 8 that plain SD/SDXL latents use. Get this wrong and your "2x" upscale is actually a 4x in pixel terms. The default is 16 - MiniMax H3, and you only drop to 8 when feeding a plain SD-style latent - which is a corner case this pack mostly doesn't care about.
The alignment_policy input is the aspect-ratio savior. Because the 32-pixel grid doesn't divide evenly into most target sizes, an upscale to "1.5x" of a 1000px-wide latent can't land on 1500 exactly - 1500 isn't a multiple of 32. best_aspect (default) checks the four closest legal size pairs and picks the one with the smallest aspect-ratio error. nearest/floor/ceil instead prioritize the requested size over aspect fidelity. If you've been fighting slightly squished H3 outputs from other upscalers, best_aspect is the setting that fixes it.
The inputs that matter
scale_by(default 1.5, 1–8) - how much to grow it. 1.5 and 2 are the sensible homes; past 3 you're asking a latent resample to do generative work it isn't built for.alignment_policy-best_aspectis the one you want. Leave it.pixels_per_latent-16 - MiniMax H3. Only touch it for plain SD-style latents.upscale_method-bicubicdefault; the standard ladder of ComfyUI methods is here if you have a preference.
Outputs
latent (upscaled, 32-aligned), width and height (the actual resolved integers - check these against what you asked for, because 1.5x doesn't always give 1.5x), and report_json with the alignment decision spelled out.
Installing it
Pack install, and it's the same every time: ComfyUI Manager → search "MiniMax H3 Audio T8", or:
cd ComfyUI/custom_nodes
git clone https://github.com/T8mars/comfyui-minimax-h3-audio-T8
restart. No models, no extra pip deps - this is a pure math node, which is why it's stable. (The learned upscaler in the same category is the one that needs a model file; this one doesn't.)
Common issues
Output width isn't the scale_by you asked for. That's the 32-grid being honest. 1.5x of a non-grid-friendly size lands on the nearest legal pair - that's what best_aspect does, and it's the right trade. If you need an exact width, set alignment_policy to ceil or floor and accept the aspect drift.
Audio sounds off after upscaling the AV latent. This node upscales the video part of a joint latent; the audio latent is a different clock (40Hz vs 24fps) and isn't what you're resampling. If your pipeline has the audio moving, that's a muxing step, not this node.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| latent | LATENT | — | |
| upscale_method | COMBO | bicubic | 5 options: nearest-exact, bilinear, area, bicubic, bislerp |
| scale_by | FLOAT | 1.501–8 | — |
| pixels_per_latent | COMBO | 16 - MiniMax H3 | MiniMax H3 video latent uses 16 pixels per latent cell. Choose 8 only for a plain SD/SDXL-style latent. |
| alignment_policy | COMBO | best_aspect | best_aspect checks the four closest legal size pairs and minimizes aspect-ratio error. nearest/floor/ceil prioritize the requested size. |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| latent | LATENT | — |
| width | INT | — |
| height | INT | — |
| report_json | STRING | — |