Stable Diffusion使用ControlNet:IP-Adapter实现图片风格迁移

IP-Adapter 全称是 Text Compatible Image Prompt Adapter for Text-to-Image Diffusion Models(文本到图像扩散模型的文本兼容图像提示适配器),是腾讯研究院出品的一个新的ControlNet模型,旨在使预训练的文本到图像扩散模型能够生成具有图像提示的图像。

IP-Adapter是一种有效的轻量级适配器,用于实现预训练文本到图像扩散模型的图像提示能力。

IP-Adapter实现图片风格迁移示例

1、选择文生图

2、设置ControlNet unit 0的参数

添加一张图片作为参考风格。

  • Control Type:选择IP-Adapter
  • Preprocessor:选择ip-adapter_clip_sd15
  • Model:选择ip-adapter_sd15_plus
  • Control Weight:设置为1。

3、设置ControlNet unit 1的参数

这里选择Depth控制图片的结构,也可以使用lineart、canny、softedge等线条类模型。

  • Control Type:选择Depth
  • Preprocessor:选择depth_midas
  • Model:选择control_v11f1p_sd15_depth
  • Control Weight:设置为1。

4、文生图参数设置

  • 采样方式:选择DPM++ 2M Karras
  • 迭代步数:设置为20
  • 高度和宽度与ControlNet unit 1上传的图片保持一致

效果展示

Depth Lineart Canny SoftEdge

相关推荐
武子康8 天前
不要问模型是 Transformer 还是 Diffusion:一套五层技术栈检查法(系统角色 / 表示空间 / 网络骨架 / 训练范式 / 推理算法)
人工智能·stable diffusion·llm
武子康10 天前
从随机动作块到真实闭环:Diffusion 与 Flow 策略的执行账本
人工智能·stable diffusion·agent
chenment11 天前
ComfyUI 自定义节点开发:从零扩展你的图像生成工作流
python·stable diffusion
Lifangyun_WD18 天前
RTX 5090跑Stable Diffusion XL:生图速度、显存占用与商业应用边界
人工智能·stable diffusion·gpu算力·rtx 5090·gpu容器·gpu租赁
承渊政道19 天前
把家里的显卡变成远程AI画室:Stable Diffusion WebUI部署实战
人工智能·stable diffusion·内网穿透·cpolar·web ui·ai画室
老刘说AI2 个月前
类Sora模型:解锁动态视觉艺术的密码
人工智能·stable diffusion·架构·embedding
python-码博士2 个月前
Stable Diffusion 3 / FLUX 类模型中的 Flow Matching:怎么用、怎么调、怎么避坑
stable diffusion
Rocky Ding*2 个月前
Latent Consistency Models:一篇读懂扩散模型的少步生成核心基础知识
人工智能·深度学习·机器学习·ai作画·stable diffusion·aigc·ai-native
Asimov_Liu2 个月前
Diffusion 与 Flow Matching 数学原理及其在 VLA Action 生成中的应用
stable diffusion·自动驾驶·具身智能·vla·flow matching
Rocky Ding*2 个月前
Token Merging for Fast Stable Diffusion:一篇读懂 Stable Diffusion 的免训练加速机制
论文阅读·人工智能·深度学习·机器学习·stable diffusion·aigc·ai-native