H3 AdaLN LoRA Fix
Make those 51 'ERROR lora' lines go away
- model
- MODEL
You know the feeling: you load a MiniMax-H3 turbo LoRA, hit queue, and the console floods with ERROR lora ... adaln_proj lines - 51 of them, one per DiT block plus the final layer. Generation still runs, but the AdaLN half of your LoRA is being silently skipped. H3AdaLNLoRAFix is the node that stops that, and it exists because of a real fork in how H3 checkpoints ship.
H3 (MiniMax's video model, the Hailuo line) comes in two shapes. The full checkpoint computes adaln_proj.linear(silu(t_emb)) over a 2688-wide time embedding. Pruned "curve-form" builds drop the time embedder entirely and instead look up a row of a shared adaln_t_table [1025, 8] - a tiny curve basis. A LoRA trained on the dense base carries weights sized for that 2688-wide embedding, so when ComfyUI tries to reshape them onto an [out, 8] weight it fails, logs one ERROR lora ... line per key, and drops all 51. For a step-distillation ("turbo") LoRA that's exactly the wrong half to lose, because the timestep-modulation weights are the ones that make few-step sampling work.
The fix is genuinely clever and cheap. The pruned table spans the same 1025-point grid as the dense curve, and the dense curve turns out to be an affine function of the table: silu_grid = c + V @ table. The node recovers c and V with one least-squares solve, then rewrites the LoRA's A/B matrices into ordinary ("diff",) patches on both the weight and its bias. No forward hooks, no per-step cost, nothing for the dynamic-VRAM loader to trip over - just two patches that ComfyUI already knows how to apply. If the fit is bad (residual above a threshold), it strips instead of porting garbage.
The inputs that matter
Only two inputs, and the one you'll touch is mode:
- model - a
MODEL, taken after your LoRA loader(s). The node works on the patches the loader already attached, so it doesn't care which loader you used or which LoRAs you picked. - mode -
port(default) rebases the AdaLN weights onto the basis the model actually uses, so the errors go quiet and the timestep modulation is restored.stripjust drops the incompatible weights - same quiet log, but the output is identical to having no fix at all.offis a passthrough that leaves the errors in place.
One output, a MODEL, which wires straight on to your sampler exactly as the model would have.
Install
Standard pack install - it's part of PlagueKind-Nodes, so search "PlagueKind-Nodes" in ComfyUI Manager, or:
cd ComfyUI/custom_nodes
git clone https://github.com/PlagueKind/ComfyUI-PlagueKind-Nodes.git
Then restart ComfyUI. No extra dependencies: just torch and ComfyUI's own LoRA machinery.
Be honest about what this does
Here's the part the README won't oversell: measured on real H3 turbo LoRAs, the restored AdaLN contribution is only ~0.02% of the modulation signal. So this is a log-hygiene and correctness node, not a visible-quality upgrade. If you're chasing a quality difference, you'll be disappointed; if you want your console clean and your LoRA actually applied instead of dropped, this is the node. It works in both directions - dense LoRA on a pruned base, or curve-form LoRA on a full one - and if anything goes wrong it catches the exception and passes the model through unchanged, so it can't take down a run. The derived basis gets cached under models/h3_adaln, so the first run does the heavy math once and later runs are instant.
Pair it with the pack's sibling H3 node (the SLA attention one) if you're running the lightx2v turbo path - that's where this pack's H3 story really comes together.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | MODEL, after the LoRA loader(s). | |
| mode | COMBO | port | port: rebase the AdaLN weights onto the basis the model actually uses - quiet log, and the timestep modulation is restored. strip: just drop the incompatible weights - quiet log, output identical to having no fix at all. off: passthrough, leaves the errors in place. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| MODEL | MODEL | — |