Nodes Browser
ComfyDeploy: How ComfyUI-ppm works in ComfyUI?
What is ComfyUI-ppm?
Fixed AttentionCouple/NegPip(negative weights in prompts), more CFG++ samplers, etc.
How to install it in ComfyDeploy?
Head over to the machine page
- Click on the "Create a new machine" button
- Select the
Edit
build steps - Add a new step -> Custom Node
- Search for
ComfyUI-ppm
and select it - Close the build step dialig and then click on the "Save" button to rebuild the machine
ComfyUI-ppm
Just a bunch of random nodes modified/fixed/created by me or others. If any node starts throwing errors after an update - try to delete and re-add the node.
I'll probably add some example workflows in the future (but I'm kinda lazy, kek).
Nodes
CLIPNegPip
Modified implementation of NegPiP by laksjdjf and hako-mikan. It uses ModelPatcher instead of monkey-patching, which should increase compatibility with other nodes. Compatible with weight interpretations from Advanced CLIP Text Encode extension by BlenderNeko .
CLIPNegPip
node allows you to use negative weights in prompts. You should connect CLIPNegPip before other model/clip patches. After that, you can enter negative weights in your prompts (CTRL + arrows hotkey is capped at 0.0, will probably fix that soon).
Read more about NegPiP in the original repo. I recommend putting everything from negative prompt to positive with a negative weight of something like -1.1 or -1.3. It's also better to keep all commas inside weight braces (i.e. (worst quality,:-1.3) (sketch:-1.1,)
instead of (worst quality:-1.3), (sketch:-1.1),
).
AttentionCouplePPM
Modified implementation of AttentionCouple by laksjdjf and Haoming02. I made AttentionCouplePPM
node compatible with CLIPNegPiP
node and with default PatchModelAddDownscale (Kohya Deep Shrink)
node.
Inputs for new regions are managed automatically: when you attach cond/mask of a region to the node, a new cond_
/ mask_
input appears. Last cond_
/ mask_
inputs are always optional.
Use multiple LatentToMaskBB
nodes to set bounding box masks for AttentionCouplePPM
. The parameters are relative to your initial latent: x=0.5, y=0.0, w=0.5, h=1.0
will produce a mask covering right half of your image.
CFG++SamplerSelect
Samplers adapted to CFG++: Manifold-constrained Classifier Free Guidance for Diffusion Models by Chung et al.. Includes some samplers from Euler-Smea-Dyn-Sampler by Koishi-Star.
Should greatly reduce overexposure effect. Use together with SamplerCustom
node. Don't forget to set CFG scale to 1.0-2.0 and PAG/SEG scale (if used) to 0.5-1.0.
Tweak s_dy_pow
parameter while using *_dy_*
samplers to reduce blur artifacts (value -1
disables this feature).
Guidance Limiter
Implementation of Applying Guidance in a Limited Interval Improves Sample and Distribution Quality in Diffusion Models by Kynkäänniemi et al. (also contains RescaleCFG
functionality)
Guidance Limiter is also available as a CFGLimiterGuider
guider node for SamplerCustomAdvanced
.
Empty Latent Image (Aspect Ratio)
Empty Latent Image (Aspect Ratio)
node generates empty latent with specified aspect ratio and with respect to target resolution.
CLIPTextEncodeBREAK
A small lightweight wrapper over ConditioningConcat
node, CLIPTextEncodeBREAK
node can split prompts by BREAK
keyword into chunks and produce a single concatenated conditioning.
CLIPTokenCounter
Counts tokens in your prompt and returns them as a string. You can also print token count + individual tokens by enabling debug_print
.
Hooks/Hijacks
Schedulers
Adds AlignYourSteps scheduler modified by Extraltodeus to the default list of schedulers by replacing comfy.samplers.calculate_sigmas
function. ays
is the default AYS scheduler and ays+
is just ays
with force_sigma_min=True
.
Also adds GITS scheduler and AYS_30 scheduler (based on AYS_32 by Koitenshin)
Advanced CLIP Text Encode
Hijacks advanced_encode_from_tokens
method from Advanced CLIP Text Encode extension (if installed), making all weight interpretations compatible with NegPip.