From 302fd1bbe61d1242fd393be1c6ffc15a325328cc Mon Sep 17 00:00:00 2001 From: kijai <40791699+kijai@users.noreply.github.com> Date: Sun, 23 Feb 2025 19:55:13 +0200 Subject: [PATCH] Update some descriptions --- nodes/image_nodes.py | 4 +++- nodes/mask_nodes.py | 1 + nodes/nodes.py | 9 +++++++-- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/nodes/image_nodes.py b/nodes/image_nodes.py index dee5158..602d167 100644 --- a/nodes/image_nodes.py +++ b/nodes/image_nodes.py @@ -2717,6 +2717,7 @@ class FastPreview: FUNCTION = "preview" CATEGORY = "KJNodes/experimental" OUTPUT_NODE = True + DESCRIPTION = "Experimental node for faster image previews by displaying through base64 it without saving to disk." def preview(self, image, format, quality): pil_image = to_pil_image(image[0].permute(2, 0, 1)) @@ -2884,6 +2885,7 @@ class ImageCropByMask: RETURN_NAMES = ("image", ) FUNCTION = "crop" CATEGORY = "KJNodes/image" + DESCRIPTION = "Crops the input images based on the provided mask." def crop(self, image, mask): B, H, W, C = image.shape @@ -3097,7 +3099,7 @@ class ImagePadKJ: RETURN_NAMES = ("images", "masks",) FUNCTION = "pad" CATEGORY = "KJNodes/image" - DESCRIPTION = "Crops the input images based on the provided masks." + DESCRIPTION = "Pad the input image and optionally mask with the specified padding." def pad(self, image, left, right, top, bottom, extra_padding, color, pad_mode, mask=None): B, H, W, C = image.shape diff --git a/nodes/mask_nodes.py b/nodes/mask_nodes.py index 3f7a2e3..73ef086 100644 --- a/nodes/mask_nodes.py +++ b/nodes/mask_nodes.py @@ -1291,6 +1291,7 @@ class SeparateMasks: FUNCTION = "separate" CATEGORY = "KJNodes/masking" OUTPUT_NODE = True + DESCRIPTION = "Separates a mask into multiple masks based on the size of the connected components." def polygon_to_mask(self, polygon, shape): mask = np.zeros((shape[0], shape[1]), dtype=np.uint8) # Fixed shape handling diff --git a/nodes/nodes.py b/nodes/nodes.py index bb90452..70a9017 100644 --- a/nodes/nodes.py +++ b/nodes/nodes.py @@ -2318,8 +2318,10 @@ class ImageNoiseAugmentation: RETURN_TYPES = ("IMAGE",) FUNCTION = "add_noise" - CATEGORY = "KJNodes/image" + DESCRIPTION = """ + Add noise to an image. + """ def add_noise(self, image, noise_aug_strength, seed): torch.manual_seed(seed) @@ -2411,7 +2413,6 @@ class VAELoaderKJ: RETURN_TYPES = ("VAE",) FUNCTION = "load_vae" - CATEGORY = "KJNodes/vae" def load_vae(self, vae_name, device, weight_dtype): @@ -2478,6 +2479,10 @@ class ScheduledCFGGuidance: RETURN_TYPES = ("GUIDER",) FUNCTION = "get_guider" CATEGORY = "KJNodes/experimental" + DESCRiPTION = """ +CFG Guider that allows for scheduled CFG changes over steps, the steps outside the range will use CFG 1.0 thus being processed faster. +cfg input can be a list of floats matching step count, or a single float for all steps. +""" def get_guider(self, model, cfg, positive, negative, start_percent, end_percent): guider = Guider_ScheduledCFG(model)