arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2501.14524cs.CV
收藏

利用 Stable Diffusion 中 U-Net 跳跃连接的免训练风格与内容迁移

Training-Free Style and Content Transfer by Leveraging U-Net Skip Connections in Stable Diffusion

Max Planck Society(马克斯·普朗克学会);University of Zurich(苏黎世大学);Sapienza University of Rome(罗马第一大学);University of Cambridge(剑桥大学)

Ludovica Schaerf, Andrea Alfarano, Fabrizio Silvestri, Leonardo Impett

AI总结:

本文分析了Stable Diffusion中U-Net跳跃连接的作用,发现第三个编码器块的残差连接携带空间信息并分离内容与风格,据此提出SkipInject方法,实现了免训练的图像编辑与风格迁移,在内容对齐与结构保留上达到最优权衡。

摘要:

用于图像生成的扩散模型的最新进展,促使人们对 U-Net 架构内若干组件在图像编辑中的作用进行了详细研究。尽管以往的研究主要关注瓶颈层(h-space)、交叉注意力、自注意力以及解码层,但 U-Net 自身跳跃连接的整体作用尚未得到专门探讨。我们对跳跃连接的作用进行了深入分析,发现由第三个编码器块传递的残差连接携带了重建图像的大部分空间信息,从而将内容与风格分离开来,风格则由相对的解码层中剩余的流传递。我们表明,注入来自该块的表示可用于基于文本的编辑、精确修改和风格迁移。我们将我们的方法 SkipInject 与最先进的风格迁移和图像编辑方法进行了比较,并证明我们的方法获得了最佳的内容对齐和最优的结构保留权衡。

英文摘要:

Recent advances in diffusion models for image generation have led to detailed examinations of several components within the U-Net architecture for image editing. While previous studies have focused on the bottleneck layer (h-space), cross-attention, self-attention, and decoding layers, the overall role of the skip connections of the U-Net itself has not been specifically addressed. We conduct thorough analyses on the role of the skip connections and find that the residual connections passed by the third encoder block carry most of the spatial information of the reconstructed image, splitting the content from the style, passed by the remaining stream in the opposed decoding layer. We show that injecting the representations from this block can be used for text-based editing, precise modifications, and style transfer. We compare our method, SkipInject, to state-of-the-art style transfer and image editing methods and demonstrate that our method obtains the best content alignment and optimal structural preservation tradeoff.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑