Add default value for clip_type in comfy.nodes.base_nodes

This commit is contained in:
Max Tretikov 2024-06-14 14:12:45 -06:00
parent 8b091f02de
commit 54e6b82d2c

View File

@ -850,9 +850,8 @@ class DualCLIPLoader:
def load_clip(self, clip_name1, clip_name2, type): def load_clip(self, clip_name1, clip_name2, type):
clip_path1 = folder_paths.get_full_path("clip", clip_name1) clip_path1 = folder_paths.get_full_path("clip", clip_name1)
clip_path2 = folder_paths.get_full_path("clip", clip_name2) clip_path2 = folder_paths.get_full_path("clip", clip_name2)
if type == "sdxl": clip_type = sd.CLIPType.STABLE_DIFFUSION
clip_type = sd.CLIPType.STABLE_DIFFUSION if type == "sd3":
elif type == "sd3":
clip_type = sd.CLIPType.SD3 clip_type = sd.CLIPType.SD3
clip = sd.load_clip(ckpt_paths=[clip_path1, clip_path2], embedding_directory=folder_paths.get_folder_paths("embeddings"), clip_type=clip_type) clip = sd.load_clip(ckpt_paths=[clip_path1, clip_path2], embedding_directory=folder_paths.get_folder_paths("embeddings"), clip_type=clip_type)