SD1.5 To SDXL Hypernetwork Converter
Lifting a classic SD1.5 one up to SDXL
- hypernetwork_name
- hypernetwork_path
- report
Before LoRA took over, "hypernetwork" was the word. Automatic1111-era hypernetworks were small MLPs that sat inside cross-attention and rescaled the K/V features - the middle child between a textual inversion (a vector) and a LoRA (a matrix patch). Today they're a niche of a niche, and on SDXL they don't work at all, because the layer widths don't match. This node is a transplant: it takes a classic linear SD1.5 hypernetwork and lifts its branches up to SDXL-sized dimensions.
Be clear about what it isn't: it's experimental, and the author says so in both the README and the code. It only accepts legacy Automatic1111-style payloads that are pure linear - two-layer MLP branches, no activation function, no layer norm, no dropout - and that carry the four source dimensions 320, 640, 768 and 1280. Anything else throws an error rather than silently producing garbage, which is exactly the right behavior for an experimental converter.
How the lifting works: each two-layer linear branch is flattened into a single affine transform (matrix plus bias), which is a lossless rearrangement. Then the small branches get projected up to SDXL sizes - 640, 1280 and 2048 - using a tiled partial isometry. That's a careful near-orthogonal lift: it spreads the signal across the bigger space without just padding with zeros or smearing it into noise. The native and lifted branches are combined, and the result is re-encoded back into the legacy two-layer structure so ComfyUI can load it as a hypernetwork. The payload gets SDXL-oriented metadata, a .pt extension, and lands in your active hypernetworks folder with a _SDXL_projected fallback name.
Inputs are short: sd15_hypernetwork (dropdown from your hypernetworks folder), output_name (optional), and overwrite. Outputs are hypernetwork_name, hypernetwork_path, and a report. That's the whole surface area - no validation toggles, no fit scores, because there's no checkpoint involved. Unlike the embedding converters in this pack, there's no alignment fit to cache; this one is purely shape surgery on the weights.
Which makes the honest verdict important: treat the result as best-effort, not faithful. The projection assumes a linear branch, and the partial-isometry lift is a reasonable geometric guess, not a guarantee that the SDXL version behaves like the original. The README literally says "should be treated as a best-effort conversion path, not a guaranteed faithful transfer." If you care about a specific hypernetwork's exact behavior, converting to a LoRA is the surer route - but there's no such converter here, so this is the only local option on offer.
Install, same as its siblings: ComfyUI Manager (search "ComfyUI-BridgeLab"), or clone into custom_nodes and restart. No pip dependencies, no model downloads - it runs on the torch ComfyUI already ships, and it sits under "embed_converter" in the menu.
The realistic use: you have a single beloved A1111-era hypernetwork you've been mourning since you switched to SDXL, and you want to know if it survives the move. That's a ten-minute experiment. If it doesn't behave, no harm done - you're out one small .pt file. If it works, you just rescued a piece of your old setup that every other path told you to give up on.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| sd15_hypernetwork | COMBO | 0 options: | |
| output_name | STRING | — | |
| overwrite | BOOLEAN | false | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| hypernetwork_name | STRING | — |
| hypernetwork_path | STRING | — |
| report | STRING | — |