rename node category

This commit is contained in:
Tung Nguyen
2025-11-04 15:43:03 +07:00
parent f37981bffb
commit 1138a1f4d9
15 changed files with 105 additions and 102 deletions
+5 -5
View File
@@ -66,7 +66,7 @@ class AVControlNetLoader(ControlNetLoader):
RETURN_TYPES = ("CONTROL_NET",)
FUNCTION = "load_controlnet"
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
def load_controlnet(self, control_net_name, control_net_override="None", timestep_keyframe=None):
return load_controlnet(control_net_name, control_net_override, timestep_keyframe=timestep_keyframe)
@@ -90,7 +90,7 @@ class AV_ControlNetPreprocessor:
RETURN_TYPES = ("IMAGE", "STRING")
RETURN_NAMES = ("IMAGE", "CNET_NAME")
FUNCTION = "detect_controlnet"
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
DESCRIPTION = "DEPRECATED: Use comfyui_controlnet_aux's AIO Preprocessor instead"
def detect_controlnet(self, image, preprocessor, sd_version, resolution=512, preprocessor_override="None"):
@@ -137,7 +137,7 @@ class AVControlNetEfficientStacker:
RETURN_TYPES = ("CONTROL_NET_STACK",)
RETURN_NAMES = ("CNET_STACK",)
FUNCTION = "control_net_stacker"
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
def control_net_stacker(
self,
@@ -234,7 +234,7 @@ class AVControlNetEfficientLoader(ControlNetApply):
RETURN_TYPES = ("CONDITIONING",)
FUNCTION = "load_controlnet"
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
def load_controlnet(
self,
@@ -290,7 +290,7 @@ class AVControlNetEfficientLoaderAdvanced(ControlNetApplyAdvanced):
RETURN_TYPES = ("CONDITIONING", "CONDITIONING")
RETURN_NAMES = ("positive", "negative")
FUNCTION = "load_controlnet"
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
def load_controlnet(
self,
+2 -2
View File
@@ -20,7 +20,7 @@ class KSamplerWithSharpness(KSampler):
return inputs
CATEGORY = "Art Venture/Sampling"
CATEGORY = "ArtVenture/Sampling"
def sample(self, *args, sharpness=2.0, **kwargs):
patch.sharpness = sharpness
@@ -43,7 +43,7 @@ class KSamplerAdvancedWithSharpness(KSamplerAdvanced):
return inputs
CATEGORY = "Art Venture/Sampling"
CATEGORY = "ArtVenture/Sampling"
def sample(self, *args, sharpness=2.0, **kwargs):
patch.sharpness = sharpness
+3 -3
View File
@@ -45,7 +45,7 @@ try:
return inputs
CATEGORY = "Art Venture/Sampling"
CATEGORY = "ArtVenture/Sampling"
def sample(self, *args, sharpness=2.0, **kwargs):
patch.sharpness = sharpness
@@ -65,7 +65,7 @@ try:
return inputs
CATEGORY = "Art Venture/Sampling"
CATEGORY = "ArtVenture/Sampling"
def sampleadv(self, *args, sharpness=2.0, **kwargs):
patch.sharpness = sharpness
@@ -83,7 +83,7 @@ try:
inputs["optional"]["lora_override"] = ("STRING", {"default": "None"})
return inputs
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
def efficientloader(
self,
+1 -1
View File
@@ -55,7 +55,7 @@ class LoadLaMaModel:
}
RETURN_TYPES = ("LAMA",)
CATEGORY = "Art Venture/Inpainting"
CATEGORY = "ArtVenture/Inpainting"
FUNCTION = "load_model"
def load_model(self, model_name: str):
+16 -13
View File
@@ -27,12 +27,12 @@ class PrepareImageAndMaskForInpaint:
},
"optional": {
"controlnet_image": ("IMAGE",),
}
},
}
RETURN_TYPES = ("IMAGE", "MASK", "IMAGE", "CROP_REGION", "IMAGE")
RETURN_NAMES = ("inpaint_image", "inpaint_mask", "overlay_image", "crop_region", "controlnet_image")
CATEGORY = "Art Venture/Inpainting"
CATEGORY = "ArtVenture/Inpainting"
FUNCTION = "prepare"
def prepare(
@@ -77,39 +77,43 @@ class PrepareImageAndMaskForInpaint:
pil_mask = numpy2pil(np_mask, "L")
pil_img = tensor2pil(img)
# --- LOGIC SEPARATION ---
if inpaint_masked:
# --- MODE 1: CROP AND RESIZE ---
crop_region = get_crop_region(np_mask, mask_padding)
crop_region = expand_crop_region(crop_region, out_width, out_height, source_width, source_height)
cropped_img = pil_img.crop(crop_region)
cropped_mask = pil_mask.crop(crop_region)
final_pil_img = resize_image(cropped_img, out_width, out_height, ResizeMode.RESIZE_TO_FIT)
final_pil_mask = resize_image(cropped_mask, out_width, out_height, ResizeMode.RESIZE_TO_FIT).convert("L")
final_pil_mask = resize_image(cropped_mask, out_width, out_height, ResizeMode.RESIZE_TO_FIT).convert(
"L"
)
if controlnet_image is not None:
pil_cimg = tensor2pil(controlnet_image[idx])
cn_source_width, cn_source_height = pil_cimg.size
scale_x = cn_source_width / source_width
scale_y = cn_source_height / source_height
cn_target_width = int(out_width * scale_x)
cn_target_height = int(out_height * scale_y)
x1, y1, x2, y2 = crop_region
cn_crop_region = (int(x1 * scale_x), int(y1 * scale_y), int(x2 * scale_x), int(y2 * scale_y))
cropped_cn_img = pil_cimg.crop(cn_crop_region)
final_cn_img = resize_image(cropped_cn_img, cn_target_width, cn_target_height, ResizeMode.RESIZE_TO_FIT)
final_cn_img = resize_image(
cropped_cn_img, cn_target_width, cn_target_height, ResizeMode.RESIZE_TO_FIT
)
processed_controlnet_images.append(pil2tensor(final_cn_img))
else:
# --- MODE 2: PASS-THROUGH (NO RESIZING) ---
final_pil_img = pil_img
final_pil_mask = pil_mask # Already blurred if requested
final_pil_mask = pil_mask # Already blurred if requested
crop_region = (0, 0, source_width, source_height)
if controlnet_image is not None:
@@ -118,7 +122,7 @@ class PrepareImageAndMaskForInpaint:
processed_controlnet_images.append(pil2tensor(final_cn_img))
# --- COMMON LOGIC FOR BOTH MODES ---
# The overlay/preview should always be based on the original full-size image
image_masked = Image.new("RGBa", (pil_img.width, pil_img.height))
# The mask used here is the potentially blurred one, but before any cropping/resizing
@@ -129,7 +133,6 @@ class PrepareImageAndMaskForInpaint:
masks.append(pil2tensor(final_pil_mask))
crop_regions.append(torch.tensor(crop_region, dtype=torch.int64))
if processed_controlnet_images:
final_controlnet_tensor = torch.cat(processed_controlnet_images, dim=0)
else:
@@ -158,7 +161,7 @@ class OverlayInpaintedLatent:
}
RETURN_TYPES = ("LATENT",)
CATEGORY = "Art Venture/Inpainting"
CATEGORY = "ArtVenture/Inpainting"
FUNCTION = "overlay"
def overlay(self, original: Dict, inpainted: Dict, mask: torch.Tensor):
@@ -202,7 +205,7 @@ class OverlayInpaintedImage:
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Inpainting"
CATEGORY = "ArtVenture/Inpainting"
FUNCTION = "overlay"
def overlay(self, inpainted: torch.Tensor, overlay_image: torch.Tensor, crop_region: torch.Tensor):
+3 -3
View File
@@ -33,7 +33,7 @@ class SAMLoader:
RETURN_TYPES = ("AV_SAM_MODEL",)
RETURN_NAMES = ("sam_model",)
FUNCTION = "load_model"
CATEGORY = "Art Venture/Segmentation"
CATEGORY = "ArtVenture/Segmentation"
def load_model(self, model_name):
modelname = folder_paths.get_full_path("sams", model_name)
@@ -69,7 +69,7 @@ class GetSAMEmbedding:
}
RETURN_TYPES = ("SAM_EMBEDDING",)
CATEGORY = "Art Venture/Segmentation"
CATEGORY = "ArtVenture/Segmentation"
FUNCTION = "get_sam_embedding"
def get_sam_embedding(self, image, sam_model, device_mode="AUTO"):
@@ -103,7 +103,7 @@ class SAMEmbeddingToImage:
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Segmentation"
CATEGORY = "ArtVenture/Segmentation"
FUNCTION = "sam_embedding_to_noise_image"
def sam_embedding_to_noise_image(self, embedding: np.ndarray):
+3 -3
View File
@@ -122,7 +122,7 @@ class BlipLoader:
RETURN_TYPES = ("BLIP_MODEL",)
FUNCTION = "load_blip"
CATEGORY = "Art Venture/Captioning"
CATEGORY = "ArtVenture/Captioning"
def load_blip(self, model_name):
return (load_blip(model_name),)
@@ -139,7 +139,7 @@ class DownloadAndLoadBlip:
RETURN_TYPES = ("BLIP_MODEL",)
FUNCTION = "download_and_load_blip"
CATEGORY = "Art Venture/Captioning"
CATEGORY = "ArtVenture/Captioning"
def download_and_load_blip(self, model_name):
if model_name not in folder_paths.get_filename_list("blip"):
@@ -191,7 +191,7 @@ class BlipCaption:
RETURN_NAMES = ("caption",)
OUTPUT_IS_LIST = (True,)
FUNCTION = "blip_caption"
CATEGORY = "Art Venture/Captioning"
CATEGORY = "ArtVenture/Captioning"
def blip_caption(
self, image, min_length, max_length, device_mode="AUTO", prefix="", suffix="", enabled=True, blip_model=None
+1 -1
View File
@@ -79,7 +79,7 @@ class DeepDanbooruCaption:
RETURN_NAMES = ("caption",)
OUTPUT_IS_LIST = (True,)
FUNCTION = "caption"
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
def caption(
self,
+2 -2
View File
@@ -50,7 +50,7 @@ try:
RETURN_TYPES = ("IPADAPTER",)
RETURN_NAMES = ("pipeline",)
CATEGORY = "Art Venture/IP Adapter"
CATEGORY = "ArtVenture/IP Adapter"
FUNCTION = "load_ip_adapter"
def load_ip_adapter(self, ip_adapter_name, clip_name):
@@ -88,7 +88,7 @@ try:
RETURN_TYPES = ("MODEL", "IPADAPTER", "CLIP_VISION")
RETURN_NAMES = ("model", "pipeline", "clip_vision")
CATEGORY = "Art Venture/IP Adapter"
CATEGORY = "ArtVenture/IP Adapter"
FUNCTION = "apply_ip_adapter"
def apply_ip_adapter(
+3 -3
View File
@@ -152,7 +152,7 @@ class ISNetLoader:
RETURN_TYPES = ("ISNET_MODEL",)
FUNCTION = "load_isnet"
CATEGORY = "Art Venture/Segmentation"
CATEGORY = "ArtVenture/Segmentation"
def load_isnet(self, model_name):
return (load_isnet_model(model_name),)
@@ -169,7 +169,7 @@ class DownloadISNetModel:
RETURN_TYPES = ("ISNET_MODEL",)
FUNCTION = "download_isnet"
CATEGORY = "Art Venture/Segmentation"
CATEGORY = "ArtVenture/Segmentation"
def download_isnet(self, model_name):
if model_name not in folder_paths.get_filename_list("isnet"):
@@ -200,7 +200,7 @@ class ISNetSegment:
RETURN_TYPES = ("IMAGE", "MASK")
RETURN_NAMES = ("segmented", "mask")
CATEGORY = "Art Venture/Segmentation"
CATEGORY = "ArtVenture/Segmentation"
FUNCTION = "segment_isnet"
def segment_isnet(self, images: torch.Tensor, threshold, device_mode="AUTO", enabled=True, isnet_model=None):
+9 -9
View File
@@ -70,7 +70,7 @@ class AVVAELoader(VAELoader):
inputs["optional"] = {"vae_override": ("STRING", {"default": "None"})}
return inputs
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
def load_vae(self, vae_name, vae_override="None"):
if vae_override != "None":
@@ -92,7 +92,7 @@ class AVLoraLoader(LoraLoader):
}
return inputs
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
def load_lora(self, model, clip, lora_name, *args, lora_override="None", enabled=True, **kwargs):
if not enabled:
@@ -119,7 +119,7 @@ class AVLoraListStacker:
RETURN_TYPES = ("LORA_STACK",)
FUNCTION = "load_list_lora"
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
def parse_lora_list(self, data: str):
# data is a list of lora model (lora_name, strength_model, strength_clip, url) in json format
@@ -213,7 +213,7 @@ class AVCheckpointModelsToParametersPipe:
}
RETURN_TYPES = ("PIPE",)
CATEGORY = "Art Venture/Parameters"
CATEGORY = "ArtVenture/Parameters"
FUNCTION = "checkpoint_models_to_parameter_pipe"
def checkpoint_models_to_parameter_pipe(
@@ -255,7 +255,7 @@ class AVPromptsToParametersPipe:
}
RETURN_TYPES = ("PIPE",)
CATEGORY = "Art Venture/Parameters"
CATEGORY = "ArtVenture/Parameters"
FUNCTION = "prompt_to_parameter_pipe"
def prompt_to_parameter_pipe(self, positive, negative, pipe: Dict = {}, image=None, mask=None):
@@ -297,7 +297,7 @@ class AVParametersPipeToCheckpointModels:
"lora_2_name",
"lora_3_name",
)
CATEGORY = "Art Venture/Parameters"
CATEGORY = "ArtVenture/Parameters"
FUNCTION = "parameter_pipe_to_checkpoint_models"
def parameter_pipe_to_checkpoint_models(self, pipe: Dict = {}):
@@ -346,7 +346,7 @@ class AVParametersPipeToPrompts:
"image",
"mask",
)
CATEGORY = "Art Venture/Parameters"
CATEGORY = "ArtVenture/Parameters"
FUNCTION = "parameter_pipe_to_prompt"
def parameter_pipe_to_prompt(self, pipe: Dict = {}):
@@ -378,7 +378,7 @@ class AVCheckpointMerge:
RETURN_TYPES = ("MODEL",)
FUNCTION = "merge"
CATEGORY = "Art Venture/Model Merging"
CATEGORY = "ArtVenture/Model Merging"
DESCRIPTION = "DEPRECATED: Use ComfyUI's native ModelMergeSimple instead"
def merge(self, model1, model2, model1_weight):
@@ -406,7 +406,7 @@ class AVCheckpointMerge:
class AVCheckpointSave(CheckpointSave):
CATEGORY = "Art Venture/Model Merging"
CATEGORY = "ArtVenture/Model Merging"
@classmethod
def INPUT_TYPES(s):
+4 -10
View File
@@ -37,17 +37,13 @@ class ColorBlend:
RETURN_TYPES = ("IMAGE",)
FUNCTION = "color_blending_mode"
CATEGORY = "Art Venture/Post Processing"
CATEGORY = "ArtVenture/Post Processing"
def color_blending_mode(self, bw_layer, color_layer):
if bw_layer.shape[0] < color_layer.shape[0]:
bw_layer = bw_layer.repeat(color_layer.shape[0], 1, 1, 1)[
: color_layer.shape[0]
]
bw_layer = bw_layer.repeat(color_layer.shape[0], 1, 1, 1)[: color_layer.shape[0]]
if bw_layer.shape[0] > color_layer.shape[0]:
color_layer = color_layer.repeat(bw_layer.shape[0], 1, 1, 1)[
: bw_layer.shape[0]
]
color_layer = color_layer.repeat(bw_layer.shape[0], 1, 1, 1)[: bw_layer.shape[0]]
batch_size, *_ = bw_layer.shape
tensor_output = torch.empty_like(bw_layer)
@@ -70,8 +66,6 @@ class ColorBlend:
for i in range(batch_size):
blend = color_blend(image1[i], image2[i])
blend = np.stack([blend])
tensor_output[i : i + 1] = (
torch.from_numpy(blend.transpose(0, 3, 1, 2)) / 255.0
).permute(0, 2, 3, 1)
tensor_output[i : i + 1] = (torch.from_numpy(blend.transpose(0, 3, 1, 2)) / 255.0).permute(0, 2, 3, 1)
return (tensor_output,)
+1 -1
View File
@@ -36,7 +36,7 @@ class ColorCorrect:
RETURN_TYPES = ("IMAGE",)
FUNCTION = "color_correct"
CATEGORY = "Art Venture/Post Processing"
CATEGORY = "ArtVenture/Post Processing"
def color_correct(
self,
+50 -44
View File
@@ -161,12 +161,15 @@ class UtilLoadImageFromUrl:
def INPUT_TYPES(cls):
return {
"required": {
"image": ("STRING", {
"default": "",
"placeholder": "Input image paths or URLS one per line. Eg:\nhttps://example.com/image.png\nfile:///path/to/local/image.jpg\ndata:image/png;base64,...",
"multiline": True,
"dynamicPrompts": False,
}),
"image": (
"STRING",
{
"default": "",
"placeholder": "Input image paths or URLS one per line. Eg:\nhttps://example.com/image.png\nfile:///path/to/local/image.jpg\ndata:image/png;base64,...",
"multiline": True,
"dynamicPrompts": False,
},
),
},
"optional": {
"keep_alpha_channel": (
@@ -183,7 +186,7 @@ class UtilLoadImageFromUrl:
RETURN_TYPES = ("IMAGE", "MASK", "BOOLEAN")
OUTPUT_IS_LIST = (True, True, False)
RETURN_NAMES = ("images", "masks", "has_image")
CATEGORY = "Art Venture/Image"
CATEGORY = "ArtVenture/Image"
FUNCTION = "load_image"
def load_image(self, image: str, keep_alpha_channel=False, output_mode=False):
@@ -243,12 +246,15 @@ class UtilLoadImageAsMaskFromUrl(UtilLoadImageFromUrl):
def INPUT_TYPES(cls):
return {
"required": {
"image": ("STRING", {
"default": "",
"placeholder": "Input image paths or URLS one per line. Eg:\nhttps://example.com/image.png\nfile:///path/to/local/image.jpg\ndata:image/png;base64,...",
"multiline": True,
"dynamicPrompts": False,
}),
"image": (
"STRING",
{
"default": "",
"placeholder": "Input image paths or URLS one per line. Eg:\nhttps://example.com/image.png\nfile:///path/to/local/image.jpg\ndata:image/png;base64,...",
"multiline": True,
"dynamicPrompts": False,
},
),
"channel": (["alpha", "red", "green", "blue"],),
},
"optional": {
@@ -316,7 +322,7 @@ class UtilLoadJsonFromText:
}
RETURN_TYPES = ("JSON",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "load_json"
def load_json(self, data: str):
@@ -336,7 +342,7 @@ class UtilLoadJsonFromUrl:
}
RETURN_TYPES = ("JSON",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "load_json"
def load_json(self, url: str, print_to_console=False):
@@ -362,7 +368,7 @@ class UtilGetObjectFromJson:
}
RETURN_TYPES = ("JSON",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "get_objects_from_json"
OUTPUT_NODE = True
@@ -381,7 +387,7 @@ class UtilGetTextFromJson:
}
RETURN_TYPES = ("STRING",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "get_string_from_json"
OUTPUT_NODE = True
@@ -400,7 +406,7 @@ class UtilGetFloatFromJson:
}
RETURN_TYPES = ("FLOAT",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "get_float_from_json"
OUTPUT_NODE = True
@@ -419,7 +425,7 @@ class UtilGetIntFromJson:
}
RETURN_TYPES = ("INT",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "get_int_from_json"
OUTPUT_NODE = True
@@ -438,7 +444,7 @@ class UtilGetBoolFromJson:
}
RETURN_TYPES = ("BOOLEAN",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "get_bool_from_json"
OUTPUT_NODE = True
@@ -457,7 +463,7 @@ class UtilRandomInt:
}
RETURN_TYPES = ("INT", "STRING")
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "random_int"
@classmethod
@@ -480,7 +486,7 @@ class UtilRandomFloat:
}
RETURN_TYPES = ("FLOAT", "STRING")
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "random_float"
@classmethod
@@ -500,7 +506,7 @@ class UtilStringToInt:
}
RETURN_TYPES = ("INT",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "string_to_int"
def string_to_int(self, string: str):
@@ -518,7 +524,7 @@ class UtilStringToNumber:
}
RETURN_TYPES = ("INT", "FLOAT")
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "string_to_numbers"
def string_to_numbers(self, string: str, rounding):
@@ -546,7 +552,7 @@ class UtilNumberScaler:
}
RETURN_TYPES = ("FLOAT",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "scale_number"
def scale_number(self, min: float, max: float, scale_to_min: float, scale_to_max: float, value: float):
@@ -565,7 +571,7 @@ class UtilBooleanPrimitive:
}
RETURN_TYPES = ("BOOLEAN", "STRING")
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "boolean_primitive"
def boolean_primitive(self, value: bool, reverse: bool):
@@ -596,7 +602,7 @@ class UtilTextSwitchCase:
}
RETURN_TYPES = ("STRING",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "text_switch_case"
def text_switch_case(self, switch_cases: str, condition: str, default_value: str, delimiter: str = ":"):
@@ -637,7 +643,7 @@ class UtilImageMuxer:
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "image_muxer"
def image_muxer(self, image_1, image_2, input_selector, image_3=None, image_4=None):
@@ -673,7 +679,7 @@ class UtilSDXLAspectRatioSelector:
RETURN_TYPES = ("STRING", "INT", "INT")
RETURN_NAMES = ("ratio", "width", "height")
FUNCTION = "get_aspect_ratio"
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
def get_aspect_ratio(self, aspect_ratio):
width, height = 1024, 1024
@@ -766,7 +772,7 @@ class UtilDependenciesEdit:
}
RETURN_TYPES = ("DEPENDENCIES",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "edit_dependencies"
def edit_dependencies(
@@ -846,7 +852,7 @@ class UtilImageScaleDown:
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "image_scale_down"
def image_scale_down(self, images, width, height, crop):
@@ -888,7 +894,7 @@ class UtilImageScaleDownBy(UtilImageScaleDown):
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "image_scale_down_by"
def image_scale_down_by(self, images, scale_by):
@@ -911,7 +917,7 @@ class UtilImageScaleDownToSize(UtilImageScaleDownBy):
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "image_scale_down_to_size"
def image_scale_down_to_size(self, images, size, mode):
@@ -941,7 +947,7 @@ class UtilImageScaleToTotalPixels(UtilImageScaleDownBy, ImageUpscaleWithModel):
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "image_scale_down_to_total_pixels"
def image_scale_up_by(self, images: torch.Tensor, scale_by, upscale_model_opt):
@@ -979,7 +985,7 @@ class UtilImageAlphaComposite:
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "image_alpha_composite"
def image_alpha_composite(self, image_1: torch.Tensor, image_2: torch.Tensor):
@@ -1011,7 +1017,7 @@ class UtilImageGaussianBlur:
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "image_gaussian_blur"
def image_gaussian_blur(self, images, radius):
@@ -1036,7 +1042,7 @@ class UtilImageExtractChannel:
RETURN_TYPES = ("MASK",)
RETURN_NAMES = ("channel_data",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "image_extract_alpha"
def image_extract_alpha(self, images: torch.Tensor, channel):
@@ -1066,7 +1072,7 @@ class UtilImageApplyChannel:
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "image_apply_channel"
def image_apply_channel(self, images: torch.Tensor, channel_data: torch.Tensor, channel):
@@ -1108,7 +1114,7 @@ class UtillQRCodeGenerator:
RETURN_TYPES = ("IMAGE",)
FUNCTION = "create_qr_code"
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
def create_qr_code(self, text, size, qr_version, error_correction, box_size, border):
ensure_package("qrcode", install_package_name="qrcode[pil]")
@@ -1143,7 +1149,7 @@ class UtilRepeatImages:
}
RETURN_TYPES = ("IMAGE",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "rebatch"
def rebatch(self, images: torch.Tensor, amount):
@@ -1166,7 +1172,7 @@ class UtilSeedSelector:
RETURN_TYPES = ("INT",)
RETURN_NAMES = ("seed",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "get_seed"
def get_seed(self, mode, seed, fixed_seed):
@@ -1184,7 +1190,7 @@ class UtilCheckpointSelector:
RETURN_TYPES = (folder_paths.get_filename_list("checkpoints"), "STRING")
RETURN_NAMES = ("ckpt_name", "ckpt_name_str")
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "get_ckpt_name"
@classmethod
@@ -1207,7 +1213,7 @@ class UtilModelMerge:
}
RETURN_TYPES = ("MODEL",)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "merge_models"
def merge_models(self, model1, model2, ratio=1.0):
@@ -1241,7 +1247,7 @@ class UtilTextRandomMultiline:
RETURN_TYPES = ("STRING",)
RETURN_NAMES = ("lines",)
OUTPUT_IS_LIST = (True,)
CATEGORY = "Art Venture/Utils"
CATEGORY = "ArtVenture/Utils"
FUNCTION = "random_multiline"
def random_multiline(self, text: str, amount=1, seed=0):
+2 -2
View File
@@ -55,7 +55,7 @@ try:
inputs["required"]["video"] = ("STRING", {"default": ""})
return inputs
CATEGORY = "Art Venture/Loaders"
CATEGORY = "ArtVenture/Loaders"
FUNCTION = "load"
RETURN_TYPES = ("IMAGE", "INT", "BOOLEAN")
RETURN_NAMES = ("frames", "frame_count", "has_video")
@@ -164,7 +164,7 @@ try:
from urllib.parse import parse_qs
qs_idx = url.find("?")
qs = parse_qs(url[qs_idx + 1:])
qs = parse_qs(url[qs_idx + 1 :])
filename = qs.get("name", qs.get("filename", None))
if filename is None:
raise Exception(f"Invalid url: {url}")