首页 > 其他分享 >[Paper Reading] ControlNet: Adding Conditional Control to Text-to-Image Diffusion Models

[Paper Reading] ControlNet: Adding Conditional Control to Text-to-Image Diffusion Models

时间:2024-08-30 22:27:51浏览次数:3  
标签:Control Adding ControlNet FreezeNet ZeroConv Decoder Diffusion

ControlNet: Adding Conditional Control to Text-to-Image Diffusion Models

link
时间:23.11
机构:Standford

TL;DR

提出ControlNet算法模型,用来给一个预训练好的text2image的diffusion model增加空间条件控制信息。作者尝试使用5w-1M的edges/depth/segmentation/pose等信息训练ControlNet,都能得到比较好的生成效果。为下游文生图使用者提供了极大的便利。

Method

  • ZeroConv
    FreezeNet与ControlNet模型是在Decoder部分融合特征的,ControlNet Decoder都是从ZeroConv初始化的,根据下面公式来看,从ControlNet连入FreezeNet的特征一开始是全零所以融合到Freeze模型上不影响原始效果。
  • 这么设计的好处:
    效果方面:
    a) 保留了原始Encoder的参数。b) Decoder是ZeroConv相当于让ControlNet逐步学习参与进来。
    性能方面:FreezeNet不需要backward,提升速度与降低显存

As tested on a single NVIDIA A100 PCIE 40GB, optimizing Stable Diffusion with Control- Net requires only about 23% more GPU memory and 34% more time in each training iteration, compared to optimizing Stable Diffusion without ControlNet.

  • Condition \(c_f\)
    将depth/pose/edge图,通过4层stride=2的可学习卷积抽取出的特征

  • Q:ZeroConv如何反传梯度?
    根据\(y=wx + b\),只要x不为0(输入x是从ControlNet Encoder抽取出来的特征),就可以得到y反传到w的非0梯度。

Experiment

在6133 iters的时候突然收敛了

可以用来生成数据

更多可视化样本

总结与发散

相关链接

https://zhuanlan.zhihu.com/p/660924126

资料查询

折叠Title FromChatGPT(提示词:XXX)

标签:Control,Adding,ControlNet,FreezeNet,ZeroConv,Decoder,Diffusion
From: https://www.cnblogs.com/fariver/p/18377021

相关文章

  • WPF ItemsControl IsItemsHost true
    //customziecontrol//xaml<UserControlx:Class="WpfApp306.ElpTbk"xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"......
  • [跨域]Access-Control-Allow-Origin 跨域问题可能是后端接口响应超时导致
    [跨域]Access-Control-Allow-Origin跨域问题可能是后端接口响应超时导致如下,发生跨域,检查了后端 拦截器都是放开的,那可能出现这个跨域问题,有可能是 后端接口响应超时,从而导致误报了603跨域问题用arthastrace看下后端接口即可排查https://uatdepot-partner.rta-os.com/......
  • 「对比评测」标准WPF DataGrid与DevExpress WPF GridControl有何不同?(二)
    DevExpressWPF拥有120+个控件和库,将帮助您交付满足甚至超出企业需求的高性能业务应用程序。通过DevExpressWPF能创建有着强大互动功能的XAML基础应用程序,这些应用程序专注于当代客户的需求和构建未来新一代支持触摸的解决方案。无论是Office办公软件的衍伸产品,还是以数据为中心......
  • AdornerDecorator的CacheMode绑定和windows锁屏导致TableControl锁死问题
    有个wpf项目,从.netframework4.0刚出来就在用,现在慢慢的系统从win xp到win10了。升级到.net8后发现一个怪异的现象,就是当windows按Win+L锁屏后,某个TableControl里面的TableItem无法激活了,就和Disable了一样的现象。经过各种尝试,最终逐步删代码,发现一个子控件里面的依据代码删......
  • CAS server如何自定义Controller控制器
    CASserver如何自定义Controller控制器在实际开发过程中,CASServer4.0.0服务端提供了登录、认证等功能,但是我们希望加入更多的自定义功能,如自定义第三方登录服务等功能。增加一个Controller类控制器以及修改部分配置来完成CASServer4.0.0自定义Controller扩展,废话就不多说了,......
  • HandyControl 初识 第一次正确引入
    在App.xaml配置HandyControl,一个是皮肤资源,一个是主题资源完整代码:`<Application.Resources><ResourceDictionary><ResourceDictionary.MergedDictionaries><ResourceDictionarySource="pack://application:,,,/HandyControl;compone......
  • threeJs 修改TransformControls的显示位置
    有的时候模型的原点不是自身中心而是在场景的[0,0,0]位置这个时候想要让TransformControls的位置显示在模型的中心目前找的的处理方式是修改源码找到updateMatrixWorld方法updateMatrixWorld(){...for(leti=0;i<handles.length;i++){ ... if(this......
  • Access-Control-Allow- 设置 跨域资源共享 CORS 详解
    跨域访问的项目常在过滤器或者拦截器中添加如下配置   response.setHeader("Access-Control-Allow-Origin","*");response.setHeader("Access-Control-Allow-Methods","POST,OPTIONS,GET");response.setHeader("Access-Control-Max-Age&qu......
  • controlnet inpainting
    Brushnet:aplug-and-playimageinpaintingmodelwithdecomposeddual-branchdiffusion_brushnet:aplug-and-playimageinpaintingmodelw-CSDN博客文章浏览阅读671次,点赞29次,收藏18次。本文介绍了一种名为Brushnet的图像修复模型,该模型通过分离的双分支扩散来提升图像......
  • SmartDeviceControl_FreeRTOS_Hal_Zet6
    SmartDeviceControl_FreeRTOS_Hal_Zet6系统框图显示子设备框图我们不想让文件互相调用遇到的问题:OLED无响应,I2C无法工作解决:使用的是软件I2C,问题在于OLED的驱动中已经包含获取从机应答的函数更新:屏幕为2.8TFT-LCD使用FSMC来模拟8080并口驱动LCDFSMC_D0-FSMC_D......