InstaSD - Load image from local folder
Load an image from ComfyUI's input folder — with alpha as a mask
- IMAGE
- MASK
InstaLoadImageLocal is ComfyUI's familiar "load an image from your input folder" node, reimplemented for the InstaSD pack - with the useful extra that it hands you both the image and a mask built from its alpha channel. If you've used the built-in LoadImage, nothing here will surprise you; that's kind of the point.
The input image is a dropdown of every file sitting in ComfyUI/input. Pick one, and the node reads it, handles EXIF rotation, converts to a float tensor between 0 and 1, and returns two things:
- IMAGE - the image itself, ready for a VAE encode, img2img, ControlNet, whatever.
- MASK - a mask derived from the image's alpha channel. Transparent pixels become
1(masked), opaque pixels become0. If the image has no alpha, you get a blank 64×64 mask instead.
That alpha-to-mask behavior is the genuinely useful part. Load a PNG with transparency and you instantly have a ready-made inpaint mask - exactly what you want for background replacement or "fill the transparent area" workflows, which is a big chunk of what InstaSD demos end up doing.
Mechanically it's the standard ComfyUI load path: the code hashes the file content for IS_CHANGED, so if you overwrite the file on disk the node re-runs instead of serving a cached load, and it validates the path before execution. Multi-frame images (GIFs, etc.) are supported and get batched - frames that don't match the first frame's dimensions are skipped.
Install
cd ComfyUI/custom_nodes
git clone https://github.com/WaddingtonHoldings/ComfyUI-InstaSD
Restart ComfyUI, or install via ComfyUI Manager (search "InstaSD"). Requirements are boto3, Pillow, requests, numpy; no model downloads, no credentials.
Gotchas
- The dropdown lists every file in
input, not just images - the source doesn't filter by extension. You'll see non-image files in there; just don't pick one. - If your workflow needs the person on the other end to draw a mask rather than rely on alpha, this is the wrong node - that's what
InstaLoadImageWithMaskin this pack is for. - Locally it's a straight swap for the built-in LoadImage. The only reason to prefer this one is consistency inside a workflow you're going to publish via InstaSD.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| image | COMBO | 1 options: example.png |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |
| MASK | MASK | — |