arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2302.06130cs.CV
收藏

图像修补中掩蔽自我注意的温度刻度学习

Learning to Scale Temperature in Masked Self-Attention for Image Inpainting

Southern University of Science and Technology(南方科技大学)

Xiang Zhou, Yuan Zeng, Yi Gong

摘要:

深度生成对抗网络(GAN)和自注意力机制的最新进展使得修复图像中大缺失区域的挑战性任务得到了显着改进。这些方法在神经网络中集成了自注意力机制,以基于它们的相关性来利用周围的神经元素,并帮助网络捕获长程依赖性。温度是自我注意中使用的Softmax函数中的一个参数,它可以使注意力分数的分布偏向少数类似的补丁。现有的图像修补中的自注意力机制大多是基于卷积的,并且将温度设置为常数,在有限的特征空间中执行块匹配。在这项工作中,我们分析了以前的自我注意力机制的工件和训练问题,并重新设计了温度学习网络以及自我注意力机制,以解决这些问题。我们提出了一个图像修补框架,该框架具有多头温度掩蔽自注意力机制,该机制提供稳定和有效的温度学习,并使用多个远距离上下文信息来进行高质量的图像修补。除了提高图像质量的修复结果,我们推广所提出的模型,以用户引导的图像编辑,通过引入一个新的草图生成方法。在Paris StreetView、CelebA-HQ和Places 2等数据集上的大量实验清楚地表明,我们的方法不仅在感知图像质量和定量指标方面比以前的作品生成更自然的修复结果,而且还能够帮助用户生成与草图指导相关的更灵活的结果。

英文摘要:

Recent advances in deep generative adversarial networks (GAN) and self-attention mechanism have led to significant improvements in the challenging task of inpainting large missing regions in an image. These methods integrate self-attention mechanism in neural networks to utilize surrounding neural elements based on their correlation and help the networks capture long-range dependencies. Temperature is a parameter in the Softmax function used in the self-attention, and it enables biasing the distribution of attention scores towards a handful of similar patches. Most existing self-attention mechanisms in image inpainting are convolution-based and set the temperature as a constant, performing patch matching in a limited feature space. In this work, we analyze the artifacts and training problems in previous self-attention mechanisms, and redesign the temperature learning network as well as the self-attention mechanism to address them. We present an image inpainting framework with a multi-head temperature masked self-attention mechanism, which provides stable and efficient temperature learning and uses multiple distant contextual information for high quality image inpainting. In addition to improving image quality of inpainting results, we generalize the proposed model to user-guided image editing by introducing a new sketch generation method. Extensive experiments on various datasets such as Paris StreetView, CelebA-HQ and Places2 clearly demonstrate that our method not only generates more natural inpainting results than previous works both in terms of perception image quality and quantitative metrics, but also enables to help users to generate more flexible results that are related to their sketch guidance.

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

↑