[论文解读] Training-Free Layout Control with Cross-Attention Guidance
本文通过操作跨注意力实现扩散模型的训练无关布局控制,显示向后引导在使生成布局与用户指定框对齐方面优于前向引导。
Recent diffusion-based generators can produce high-quality images from textual prompts. However, they often disregard textual instructions that specify the spatial layout of the composition. We propose a simple approach that achieves robust layout control without the need for training or fine-tuning of the image generator. Our technique manipulates the cross-attention layers that the model uses to interface textual and visual information and steers the generation in the desired direction given, e.g., a user-specified layout. To determine how to best guide attention, we study the role of attention maps and explore two alternative strategies, forward and backward guidance. We thoroughly evaluate our approach on three benchmarks and provide several qualitative examples and a comparative analysis of the two strategies that demonstrate the superiority of backward guidance compared to forward guidance, as well as prior work. We further demonstrate the versatility of layout guidance by extending it to applications such as editing the layout and context of real images.
研究动机与目标
- 在不对模型进行微调的情况下,推动文本到图像生成的鲁棒空间布局控制。
- 研究跨注意力映射如何影响布局,并比较前向引导与向后引导。
- 开发一种训练无关的机制,通过用户指定的包围框来引导布局。
- 证明对真实图像的布局编辑的适用性,并与个性化管线整合。
提出的方法
- 将布局控制问题表示为从 p(x|y,B,i) 的采样,其中 B 为标记 i 的边界框。
- 探测跨注意力层 where A^{( Gamma)}_{ui} 将空间位置 u 与文本标记 i 连接起来。
- 将前向引导形式化为通过窗口函数 g^{( Gamma)}_{u} 对跨注意力映射进行偏置。
- 提出向后引导,通过定义能量函数 E(A^{( Gamma)},B,i) 来激励 B 内的注意力,并通过反向传播更新潜变量 z_t(z_t ← z_t − σ_t^2 η ∇_{z_t} Σγ E(A^{( Gamma)},B,i))。
- 表明向后引导通过更新潜变量间接对齐所有标记的注意力,与直接偏置单个标记注意力的前向引导不同。
- 在三个基准上进行评估,并分析标记的角色,包括起始标记和填充标记,以及初始扩散噪声的影响。

实验结果
研究问题
- RQ1如何在不重新训练的情况下,利用预训练扩散模型实现布局条件的图像生成?
- RQ2向后引导在通过跨注意力强制空间布局方面是否比前向引导更有效?
- RQ3在多大程度上训练无关的布局引导能编辑真实图像或与个性化技术整合?
- RQ4哪些因素(标记、初始噪声)在扩散生成过程中的布局形成中起关键作用?
主要发现
- 向后引导在对象组装准确性(OA)和基于 VISOR 的指标上均高于前向引导。
- 带噪声选择的向后引导在三个基准上显著提升 OA 和 VISOR 得分。
- 起始标记和填充标记的跨注意力映射携带有意义的布局信息,可辅助引导策略。
- 在 COCO 和 Flickr30K 上,向后引导在 mAP 和 AP@0.5 上优于其他对布局进行条件化的方法。
- 该方法与 Textual Inversion 或 Dreambooth 结合时,能够实现对真实图像的布局编辑,同时保持身份特征。

更好的研究,从现在开始
从论文设计到论文写作,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。