模板概述
工作流结构
节点流程图(Mermaid)
graph TD
A[CheckpointLoaderSimple] -->|MODEL| B[KSampler]
A -->|CLIP| C[CLIPTextEncode]
A -->|CLIP| D[CLIPTextEncode]
A -->|VAE| E[VAEDecode]
C -->|CONDITIONING| F[ControlNetApply1]
F -->|CONDITIONING| G[ControlNetApply2]
G -->|CONDITIONING| B
D -->|CONDITIONING| B
H[ControlNetLoader1] -->|CONTROL_NET| F
I[LoadImage1] -->|IMAGE| F
J[ControlNetLoader2] -->|CONTROL_NET| G
K[LoadImage2] -->|IMAGE| G
L[EmptyLatentImage] -->|LATENT| B
B -->|LATENT| E
E -->|IMAGE| M[SaveImage]
style A fill:#e1f5ff
style B fill:#fff4e1
style C fill:#ffe1f5
style D fill:#ffe1f5
style E fill:#e1ffe1
style F fill:#ffe1f5
style G fill:#ffe1f5
style H fill:#e1f5ff
style I fill:#e1ffe1
style J fill:#e1f5ff
style K fill:#e1ffe1
style L fill:#e1ffe1
style M fill:#ffe1e1
多ControlNet组合流程
graph LR
A[ControlNet1] --> B[组合控制]
C[ControlNet2] --> B
B --> D[采样器]
D --> E[多重控制生成]
style A fill:#e1ffe1
style B fill:#fff4e1
style C fill:#e1ffe1
style D fill:#fff4e1
style E fill:#fff4e1
节点配置
1. CheckpointLoaderSimple
{
"inputs": {
"ckpt_name": "v1-5-pruned-emaonly.ckpt"
},
"class_type": "CheckpointLoaderSimple"
}
2. ControlNetLoader1
{
"inputs": {
"control_net_name": "control_v11p_sd15_canny.safetensors"
},
"class_type": "ControlNetLoader"
}
3. LoadImage1
{
"inputs": {
"image": "canny_image.png"
},
"class_type": "LoadImage"
}
4. ControlNetLoader2
{
"inputs": {
"control_net_name": "control_v11p_sd15_depth.safetensors"
},
"class_type": "ControlNetLoader"
}
5. LoadImage2
{
"inputs": {
"image": "depth_image.png"
},
"class_type": "LoadImage"
}
6. CLIPTextEncode (正向)
{
"inputs": {
"text": "beautiful woman, detailed, high quality",
"clip": ["1", 1]
},
"class_type": "CLIPTextEncode"
}
7. CLIPTextEncode (负向)
{
"inputs": {
"text": "ugly, blurry, low quality",
"clip": ["1", 1]
},
"class_type": "CLIPTextEncode"
}
8. ControlNetApply1
{
"inputs": {
"strength": 0.8,
"condition": ["6", 0],
"control_net": ["2", 0],
"image": ["3", 0]
},
"class_type": "ControlNetApply"
}
9. ControlNetApply2
{
"inputs": {
"strength": 0.6,
"condition": ["8", 0],
"control_net": ["4", 0],
"image": ["5", 0]
},
"class_type": "ControlNetApply"
}
10. EmptyLatentImage
{
"inputs": {
"width": 512,
"height": 512,
"batch_size": 1
},
"class_type": "EmptyLatentImage"
}
11. KSampler
{
"inputs": {
"seed": 123456789,
"steps": 25,
"cfg": 7.5,
"sampler_name": "euler",
"scheduler": "normal",
"denoise": 1.0,
"model": ["1", 0],
"positive": ["9", 0],
"negative": ["7", 0],
"latent_image": ["10", 0]
},
"class_type": "KSampler"
}
12. VAEDecode
{
"inputs": {
"samples": ["11", 0],
"vae": ["1", 2]
},
"class_type": "VAEDecode"
}
13. SaveImage
{
"inputs": {
"filename_prefix": "multi_controlnet_",
"images": ["12", 0]
},
"class_type": "SaveImage"
}
完整工作流JSON
{
"1": {
"inputs": {
"ckpt_name": "v1-5-pruned-emaonly.ckpt"
},
"class_type": "CheckpointLoaderSimple"
},
"2": {
"inputs": {
"control_net_name": "control_v11p_sd15_canny.safetensors"
},
"class_type": "ControlNetLoader"
},
"3": {
"inputs": {
"image": "canny_image.png"
},
"class_type": "LoadImage"
},
"4": {
"inputs": {
"control_net_name": "control_v11p_sd15_depth.safetensors"
},
"class_type": "ControlNetLoader"
},
"5": {
"inputs": {
"image": "depth_image.png"
},
"class_type": "LoadImage"
},
"6": {
"inputs": {
"text": "beautiful woman, detailed, high quality",
"clip": ["1", 1]
},
"class_type": "CLIPTextEncode"
},
"7": {
"inputs": {
"text": "ugly, blurry, low quality",
"clip": ["1", 1]
},
"class_type": "CLIPTextEncode"
},
"8": {
"inputs": {
"strength": 0.8,
"condition": ["6", 0],
"control_net": ["2", 0],
"image": ["3", 0]
},
"class_type": "ControlNetApply"
},
"9": {
"inputs": {
"strength": 0.6,
"condition": ["8", 0],
"control_net": ["4", 0],
"image": ["5", 0]
},
"class_type": "ControlNetApply"
},
"10": {
"inputs": {
"width": 512,
"height": 512,
"batch_size": 1
},
"class_type": "EmptyLatentImage"
},
"11": {
"inputs": {
"seed": 123456789,
"steps": 25,
"cfg": 7.5,
"sampler_name": "euler",
"scheduler": "normal",
"denoise": 1.0,
"model": ["1", 0],
"positive": ["9", 0],
"negative": ["7", 0],
"latent_image": ["10", 0]
},
"class_type": "KSampler"
},
"12": {
"inputs": {
"samples": ["11", 0],
"vae": ["1", 2]
},
"class_type": "VAEDecode"
},
"13": {
"inputs": {
"filename_prefix": "multi_controlnet_",
"images": ["12", 0]
},
"class_type": "SaveImage"
}
}
ControlNet组合策略
策略1: 结构+深度
graph TD
A[主模型] --> B[Canny<br/>strength: 0.8]
B --> C[Depth<br/>strength: 0.6]
C --> D[采样器]
style A fill:#e1ffe1
style B fill:#fff4e1
style C fill:#fff4e1
style D fill:#fff4e1
策略2: 姿态+分割
graph TD
A[主模型] --> B[OpenPose<br/>strength: 0.8]
B --> C[Segmentation<br/>strength: 0.6]
C --> D[采样器]
style A fill:#e1ffe1
style B fill:#fff4e1
style C fill:#fff4e1
style D fill:#fff4e1
参数说明
Strength设置
graph TD
A[多ControlNet] --> B[主ControlNet: 0.8]
A --> C[次ControlNet: 0.6]
A --> D[总强度<1.5]
B --> B1[主要控制]
C --> C1[辅助控制]
D --> D1[避免过强]
style A fill:#e1f5ff
style B fill:#fff4e1
style C fill:#ffe1f5
style D fill:#e1ffe1
使用步骤
多ControlNet组合流程
graph LR
A[准备控制图像1] --> B[准备控制图像2]
B --> C[加载ControlNet1]
C --> D[加载ControlNet2]
D --> E[组合控制]
E --> F[执行生成]
F --> G[查看结果]
style A fill:#e1ffe1
style B fill:#fff4e1
style C fill:#fff4e1
style D fill:#fff4e1
style E fill:#fff4e1
style F fill:#fff4e1
style G fill:#fff4e1
示例结果
示例1: 边缘+深度
- ControlNet1: Canny (0.8)
- ControlNet2: Depth (0.6)
- 提示词: beautiful woman, detailed
- 结果: 同时保持边缘和深度的图像
示例2: 姿态+分割
- ControlNet1: OpenPose (0.8)
- ControlNet2: Segmentation (0.6)
- 提示词: portrait, detailed
- 结果: 同时控制姿态和区域分配的图像
常见问题
Q1: 可以使用多少个ControlNet?
A: 理论上不限,但建议2-3个,避免过强控制。
Q2: ControlNet冲突怎么办?
A: 调整strength值,选择兼容的ControlNet类型。
Q3: 如何设置strength?
A: 主ControlNet设置高,次ControlNet设置低,总强度<1.5。
Q4: 多ControlNet影响速度吗?
A: 轻微影响,但通常可以接受。
Q5: 如何测试组合?
A: 逐步添加ControlNet,测试每个组合的效果。
相关模板
更新日志
- 2026-01-26: 初始版本创建