Checkpoint Loader 🐍¶
Documentation¶
- Class name:
CheckpointLoader_pysssss
- Category:
loaders
- Output node:
False
This node is a specialized version of the CheckpointLoaderSimple, enhanced to handle images alongside checkpoint names. It facilitates the loading of model checkpoints with an emphasis on image-related configurations, making it suitable for scenarios where visual content is a primary concern.
Input types¶
Required¶
ckpt_name
- Specifies the name of the checkpoint to be loaded. This parameter is crucial as it determines which specific checkpoint the node will attempt to load, impacting the model's configuration and its subsequent performance.
- Comfy dtype:
COMBO[STRING]
- Python dtype:
str
Output types¶
model
- Comfy dtype:
MODEL
- The loaded model object, which is the primary output of the checkpoint loading process. It represents the model in its entirety, ready for further use or analysis.
- Python dtype:
torch.nn.Module
- Comfy dtype:
clip
- Comfy dtype:
CLIP
- The CLIP model associated with the loaded checkpoint, if applicable. This is relevant for tasks involving text and image understanding or generation.
- Python dtype:
torch.nn.Module
- Comfy dtype:
vae
- Comfy dtype:
VAE
- The VAE (Variational Autoencoder) component loaded from the checkpoint. This is crucial for tasks involving image generation or manipulation.
- Python dtype:
torch.nn.Module
- Comfy dtype:
Usage tips¶
- Infra type:
CPU
- Common nodes:
- LoraLoader|pysssss
- VAEDecode
- VAEEncodeForInpaint
- CLIPTextEncode
- VAEEncode
- Anything Everywhere3
- ImpactWildcardEncode
- Anything Everywhere
- Reroute
- Junction
Source code¶
class CheckpointLoaderSimpleWithImages(CheckpointLoaderSimple):
@classmethod
def INPUT_TYPES(s):
types = super().INPUT_TYPES()
names = types["required"]["ckpt_name"][0]
populate_items(names, "checkpoints")
return types
def load_checkpoint(self, **kwargs):
kwargs["ckpt_name"] = kwargs["ckpt_name"]["content"]
return super().load_checkpoint(**kwargs)