8.8 KiB
8.8 KiB
- Top
- Node / Image Node / Text Node / XYPlot Node / Float Palet
- Workflow
Node
🍅 Sampler Nodes
D2 KSampler / D2 KSampler(Advanced)
Differences from standard KSampler
- Directly outputs images (VAE Decoder not required)
- Can input prompts in STRING format
- Supports A1111-style LoRA loading prompts
- Example:
<lora:foo.safetensors:1> - For format, refer to
D2 Load Lora - Note: When inputting
positive_cond/negative_condtoD2 KSampler Advanced, LoRA will not be applied to CLIP. It will only be applied to MODEL.
- Example:
- Has dedicated Controlnet input for simple application
- Supports
d2_pipewhich consolidates generation parameters- Can easily receive from
D2 XY Plot,D2 XY Plot Easy,D2 XY Plot Easy Mini - Can easily pass parameters to
D2 Send Eagle
- Can easily receive from
- Can change prompt weight algorithm (weight_interpretation)
Notes
- When
d2_pipeis connected,d2_pipeparameters take priority - For example, if you specify steps:20 in
D2 KSamplerand steps:15 inD2 XYPlot Easy, withd2_pipeconnected, steps:15 fromD2 XYPlot Easywill be used.
Input
- Same as standard KSampler
model/clip/latent_image/seed/steps/cfg/sampler_name/scheduler/denoise
- Added in D2 KSampler
vaecnet_stack: For connecting toD2 Controlnet Loaderd2_pipe: Consolidated generation parameters. Received from nodes likeD2 XY Plotpreview_method: Preview display method during generationpositive/negative: Prompts in STRING format
- Added in D2 KSampler Advanced
token_normalization/weight_interpretation- Methods for adjusting prompt weights. Available in D2 KSampler Advanced
- Requires Advanced CLIP Text Encode to use
Output
- Same as standard KSampler
LATENT
- Added in D2 KSampler
IMAGE: Generated imageMODEL/CLIP: With LoRA appliedpositive/negative: Input passthroughformatted_positive: Positive prompt with A1111-style LoRA format removedpositive_cond/negative_cond: CONDITIONING with Controlnet appliedd2_pipe: Consolidated generation parameters
D2 Pipe
- A node for modifying and extracting the contents of
d2_pipe d2_pipeis used to pass parameters collectively in nodes such as D2 XY Plot Easy, D2 KSampler, and D2 Send Eagle
🍅 Loader Node
D2 Checkpoint Loader
- A Checkpoint Loader that outputs the full path of model files
- Can automatically apply v_prediction settings when the filename contains "vpred"
Input
ckpt_name- Checkpoint name
auto_vpredtrue: Automatically applies v_prediction settings if the filename contains "vpred"
sampling/zsnr- Same settings as ModelSamplingDiscrete (details unknown)
multiplier- Same settings as RescaleCFG (details unknown)
Output
model/clip/vae- Same as the conventional CheckpointLoader.
ckpt_name/ckpt_hash/ckpt_fullpath- Checkpoint name, hash, and full path.
D2 Controlnet Loader
- Controlnet Loader that creates simple workflows when connected to
D2 KSampler
Input
cnet_stack- For connecting to
D2 Controlnet Loader
- For connecting to
Output
cnet_stack- For connecting to
D2 KSamplerorD2 Controlnet Loader
- For connecting to
D2 Load Lora
- A Lora loader that allows specifying Lora through text
- model_weight / clip_weight can also be specified
- There are two modes: one that uses the same format as StableDiffusion webui A1111 (a1111), and one that simply lists LoRA names (simple)
- For specific usage, refer to the sample workflow
Input
modea1111: Mode that allows using the same format as StableDiffusion webui A1111simple: Simple mode that just lists LoRA names. In this mode, theSTRINGoutput is not used
Output
MODEL/CLIP: MODEL and CLIP with LoRA appliedprompt: Outputs the input text as isformatted_prompt: Text with LoRA specification parts removed
Format differences based on mode
mode: a1111
Expressed as <lora:~>.
<lora:lora_name:1>
mode: simple No decorations needed before or after
lora_name:1
How to specify Weight
Write in the format {lora_name}:{model_weight}:{clip_weight}.
foo:0.8:1
If clip_weight is not specified, the same value as model_weight is applied. The following have the same meaning.
foo:0.8
foo:0.8:0.8
If weight is not specified, "1" is applied The following have the same meaning.
foo
foo:1:1
How to specify multiple LoRAs in simple mode
Separate with line breaks
foo:0.5
bar
When writing two types in one line, separate with ","
foo:0.5,bar
Comments
Lines that start with "//" or "#" are ignored.
//foo:0.5
#bar
🍅 Size Node
D2 Get Image Size
- Both outputs and displays size
D2 Size Selector
- Node for selecting image size from presets
- Can also get size from images
- Rounding method can be selected from
Ceil / Float / None
Input
images- Used when getting size from images
presetmust be set tocustom
preset- Size presets
- Must be set to
customwhen usingwidthheightbelow or image sizes - Edit
/custom_nodes/D2-nodes-ComfyUI/config/sizeselector_config.yamlto modify presets
width/height- Width/height dimensions
presetmust be set tocustom
swap_dimensions- Swap width/height
upscale_factor- Value passed to other resize nodes. Does nothing in this node
prescale_factor- Output width/height after resizing by this factor
round_methodRound: Round to nearestFloor: Round downNone: No rounding
batch_size- Batch size to set for empty_latent
Output
width / height- Input
width,heightmultiplied byprescale_factor
- Input
upscale_factor/prescale_factor- Passthrough of input
batch_size- Passthrough of input
empty_latent- Outputs latent created with specified size and batch size
D2 Image Resize
- Image and mask resizing and rotation
- Precision up to 3 decimal places for scaling
- Can select rounding, floor, or ceiling for decimal handling
- Capable of upscaling using upscale models
- Latent output is also possible (requires VAE)
- Rotation options: 90 / 180 / 270 degrees
D2 Resize Calculator
- Can select rounding, floor, or ceiling
🍅 Refiner Node
D2 Refiner Steps
- Node for outputting steps for Refiner
Input
steps- Total step count
start- Starting steps for first KSampler
end- Ending steps for first KSampler
Output
steps/start/end- Input passthrough
refiner_start- Starting steps for second KSampler
D2 Refiner Steps A1111
- Node that can specify denoise for Refiner in img2img
Input
steps- Total step count
denoise- Specify denoise for img2img
switch_at- What percentage of total steps to switch to next KSampler
Output
steps- Input passthrough
start- Starting steps for first KSampler
end- Ending steps for first KSampler
refiner_start- Starting steps for second KSampler
D2 Refiner Steps Tester
- Node for checking steps
🍅 Merge Node
D2 Model and CLIP Merge SDXL
- A node that combines ModelMergeSDXL and CLIPMergeSimple
- Allows comma-separated weight specifications for easier use with XYPlot
- In this figure,
0.85,0.85,1,1,0.4,0.4,1,0.4,0.4,0.4,1,0.4,0.4,0.4,0,0.55,0.85,0.85,0.85,0.85,0.85,0.85,1,1,0.65is specified