π¨ Eric Load Image with Layers
Opening PSDs in ComfyUI Without Losing the Layers
- image
- mask
- filename
- full_path
- layer_info
ComfyUI treats images as flat tensors, and that's the end of the story for most people. But if you live in the Adobe world - or you're generating images meant to be finished in Photoshop - you've hit the wall where a PSD just won't open properly. Eric Load Image with Layers is the pack's answer: it loads the usual formats and reads actual Photoshop layers, so you can pull a single layer out of a file and feed it into your graph as its own image.
The extra power lives in load_mode. Your options are composite (flattened, like the Extended loader), all_layers (every layer comes back as a batch), layer_by_name, layer_by_index, and visible_only. Two optional inputs back that up: layer_name (a string, for the by-name mode) and layer_index (an integer, 0 = first layer, for by-index). Everything else matches its simpler sibling - the same format list (JPG, PNG, BMP, GIF, TIFF, WebP, PSD, SVG) and the same useful extra outputs.
Outputs are where this node earns its keep: image and mask for the pipeline, filename and full_path strings for the metadata system, and a bonus layer_info string that describes what's actually in the file. That last one is genuinely handy the first time you grab a PSD and have no idea how many layers it has or what they're called - run the node, read layer_info, then switch to layer_by_name with the exact name you saw.
The mechanism is psd-tools, which is a hard dependency of the pack (not optional), so if the pack installed cleanly this just works. Two practical notes: layer_by_name is exact-match - "Background" with a capital B is not "background" - and SVG input still gets rasterized, so it's vector on the way in, pixels on the way out. This isn't a node for round-tripping a PSD unchanged; it's for extracting layers into your workflow.
The realistic use case: you generated a batch in ComfyUI, dropped the results into Photoshop for cleanup, saved as PSD, and now want to re-run a specific layer through an upscaler or a detail pass. This node makes that a two-node workflow instead of a manual export dance. It's niche, and it's from a one-author pack with almost no community footprint, so don't expect it in prebuilt workflows - but if your pipeline touches PSDs, it's the rare ComfyUI node that speaks their language.
Install is the pack standard:
cd ComfyUI/custom_nodes
git clone https://github.com/EricRollei/AAA_Metadata_System
cd AAA_Metadata_System
pip install -r requirements.txt
Then restart ComfyUI. From there it's just: pick the PSD, choose your mode, and read the outputs. If layer_info comes back empty, you've grabbed a flattened PSD - there are no layers to find, which is itself useful information.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| image | COMBO | 1 options: example.png | |
| load_mode | COMBO | composite | How to load layers from PSD files |
| layer_nameopt | STRING | Layer name to load (for layer_by_name mode) | |
| layer_indexopt | INT | 00β100 | Layer index to load (for layer_by_index mode, 0 = first layer) |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | β |
| mask | MASK | β |
| filename | STRING | β |
| full_path | STRING | β |
| layer_info | STRING | β |