Extensions/LCM_Inpaint_Outpaint_Comfy
ComfyUI Extension

LCM_Inpaint_Outpaint_Comfy

ComfyUI custom nodes for inpainting/outpainting using the new latent consistency model (LCM)

By taabata·Created 3 years ago·Updated 2 years ago· 259
taabata/LCM_Inpaint-Outpaint_Comfy
Nodes42
On cloudLocal install
Categoryimage, LCM_Nodes/nodes
Stars259
Updated2 years ago

Nodes (42)

ComfyNodesToSaveCanvas

Push ComfyUI output into the canvas tool

image
FloatNumber

A manual float dial for the pack's settings

image
FreeU_LCM

Better detail from the fast model, one node

image
ImageDims

The node that tells you an image's width and height

LCM_Nodes/nodes
ImageOutputToComfyNodes

Hand a canvas image back to ComfyUI

image
ImageResize

Image Resize (ComfyUI Essentials)

image
ImageShuffle

Randomly reorder four images (and read this before trusting the seed)

image
ImageSwitch

A two-way image swap, with a naming twist

image
LCMGenerate

This pack's main inpaint/outpaint workhorse

LCM_Nodes/nodes
LCMGenerate_img2img

Fast img2img with loopback and a T2I adapter

LCM_Nodes/nodes
LCMGenerate_img2img_controlnet

Img2img steered by a ControlNet

LCM_Nodes/nodes
LCMGenerate_img2img_IPAdapter

Image-prompted variations at 4 steps

LCM_Nodes/nodes
LCMGenerate_inpaintv2

The everything-node for inpaint

LCM_Nodes/nodes
LCMGenerate_inpaintv3

Reference + ControlNet + IP-Adapter in one inpaint node

LCM_Nodes/nodes
LCMGenerate_ReferenceOnly

Steer LCM with a reference, prompt optional

LCM_Nodes/nodes
LCMGenerate_SDTurbo

The pack's SD-Turbo img2img sampler

LCM_Nodes/nodes
LCM_IPAdapter

Image-prompting on the fast LCM pipeline

LCM_Nodes/nodes
LCM_IPAdapter_inpaint

IP-Adapter plus ControlNet in one LCM loader

LCM_Nodes/nodes
LCMLoader

The one node that actually loads the LCM model here

LCM_Nodes/nodes
LCMLoader_controlnet

An LCM pipeline with ControlNet bolted in

LCM_Nodes/nodes
LCMLoader_controlnet_inpaint

The whole LCM + ControlNet inpaint rig in one node

LCM_Nodes/nodes
LCMLoader_img2img

The no-frills LCM img2img loader

LCM_Nodes/nodes
LCMLoader_ReferenceOnly

Style transfer and promptless edits, reference-style

LCM_Nodes/nodes
LCMLoader_RefInpaint

Restyle a masked region by example, at LCM speed

LCM_Nodes/nodes
LCMLoader_SDTurbo

The pack's sideways turn into SD-Turbo

LCM_Nodes/nodes
LCMLora_inpaint

The generate node that does everything in the Lora line

LCM_Nodes/nodes
LCMLora_inpaintV2

The same workhorse, but its size inputs take wires

LCM_Nodes/nodes
LCMLora_ipadapter

Controlnet + reference + IP-Adapter, all on one generate node

LCM_Nodes/nodes
LCMLoraLoader_inpaint

Turns any diffusers SD 1.5 model into a fast LCM inpaint rig

LCM_Nodes/nodes
LCMLoraLoader_ipadapter

The loader with an LCM on/off switch

LCM_Nodes/nodes
LCM_outpaint_prep

Grow your canvas one side at a time

image
LCMT2IAdapter

Drop a T2I-Adapter into the LCM pipeline

LCM_Nodes/nodes
Loader_SegmindVega

SDXL speed the pack's own way

LCM_Nodes/nodes
LoadImageNode_LCM

An image loader that takes a plain path

image
OutpaintCanvasTool

Pull your canvas state into the graph

sd
SaveImage_Canvas

Save the result and tell the canvas app about it

image
SaveImage_LCM

The plain save node the pack's workflows use

image
SaveImage_Puzzle

Save the piece, tell the jigsaw app it's ready

image
SaveImage_PuzzleV2

The puzzle saver's near-identical sequel

image
SegmindVega

The pack's SDXL generation node, quirks included

LCM_Nodes/nodes
SettingsSwitch

Three saved presets for the ipadapter node's four dials

image
stitch

The Stitch Node Is the Glue Nobody Searches For — Here's What It Actually Does

sd
Readme

Important

Errors may occur on Windows due to paths being formatted for linux without accounting for Windows. Let me know if you face any error in the issues page.

LCM_Inpaint-Outpaint_Comfy

ComfyUI custom nodes for inpainting/outpainting using the new latent consistency model (LCM)

Mix Images

<img src='https://github.com/taabata/LCM_Inpaint_Outpaint_Comfy/blob/main/LCM/instructions.png'>

Inpaint

<img src='https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-10-24%2022-38-53.png'>

Outpaint

<img src='https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-10-24%2022-42-53.png'>

Prompt Weighting

Note: Requires CPU inference (select CPU in LCMLoader Node). (facing error that i dont know how to fix when using GPU)

Add '+' for more effect and '-' for less effect. Adding more '+' or '-' increases the effects.

<img src='https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-10-26%2020-18-11.png'>

FreeU

<img src='https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-10-26%2020-39-33.png'>

ReferenceOnly

<img src='https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-10-29%2000-09-32.png'>

Style Transfer

<img src='https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-10-29%2020-08-52.png'>

Image Variations

<img src='https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-10-29%2002-33-23.png'>

Promptless Outpainting

<img src='https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-10-29%2003-32-29.png'>

Image Blending

<img src='https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-10-29%2022-46-43.png'>

ControlNet/T2I Adapter

<img src='https://github.com/taabata/LCM_Inpaint_Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-11-02%2023-41-10.png'>

T2IAdapter thanks to Michael Poutre https://github.com/M1kep

Place model folders inside 'ComfyUI/models/controlnet'

IP Adapter

<img src='https://github.com/taabata/LCM_Inpaint_Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-11-06%2020-37-20.png'>

Place model folders inside 'ComfyUI/models/controlnet'

Canvas Inpaint/Outpaint/img2img

<img src='https://github.com/taabata/LCM_Inpaint_Outpaint_Comfy/blob/main/LCM/Screenshot%20from%202023-11-15%2002-51-12.png'>

In your Terminal/cmd at the directory where your ComfyUI folder is:

cd ComfyUI/custom_nodes/LCM_Inpaint_Outpaint_Comfy/CanvasTool

python setup.py

How to Use:

Clone into custom_nodes folder inside your ComfyUI directory

git clone https://github.com/taabata/LCM_Inpaint-Outpaint_Comfy

Install requirements after changing directory to LCM_Inpaint-Outpaint_Comfy folder

cd LCM_Inpaint-Outpaint_Comfy
pip install -r requirements.txt

Download the model in diffusers format from https://huggingface.co/SimianLuo/LCM_Dreamshaper_v7/tree/main and place it inside model/diffusers folder in your ComfyUI directory. (The name of the model folder should be "LCM_Dreamshaper_v7")

Load the workflow by choosing the .json file for inpainting or outpainting.

Credits

nagolinc's img2img script

Michael Poutre https://github.com/M1kep T2IAdapters