This paper presents a new adversarial training framework for image inpainting with segmentation confusion adversarial training (SCAT) and contrastive learning. SCAT plays an adversarial game between an inpainting generator and a segmentation network, which provides pixel-level local training signals and can adapt to images with free-form holes. By combining SCAT with standard global adversarial training, the new adversarial training framework exhibits the following three advantages simultaneously: (1) the global consistency of the repaired image, (2) the local fine texture details of the repaired image, and (3) the flexibility of handling images with free-form holes. Moreover, we propose the textural and semantic contrastive learning losses to stabilize and improve our inpainting model's training by exploiting the feature representation space of the discriminator, in which the inpainting images are pulled closer to the ground truth images but pushed farther from the corrupted images. The proposed contrastive losses better guide the repaired images to move from the corrupted image data points to the real image data points in the feature representation space, resulting in more realistic completed images. We conduct extensive experiments on two benchmark datasets, demonstrating our model's effectiveness and superiority both qualitatively and quantitatively.
翻译:本文提出了一种新的对比学习和分割混淆对抗训练(SCAT)的生成式图像修复对抗训练框架。SCAT通过修复生成器和分割网络之间的对抗游戏来提供像素级局部训练信号,适用于自由形状的缺口。将SCAT与标准的全局对抗训练相结合,新的对抗训练框架同时展现了以下三个优势:(1)修复图像的全局一致性,(2)修复图像的局部细节和纹理,(3)处理自由形状的缺口。此外,我们提出了文本和语义上的对比学习损失,通过利用判别器的特征表示空间来稳定和提高我们的修复模型的训练,其中修复图像被拉近到尽可能接近真实图像,但远离损坏图像。所提出的对比损失更好地引导修复图像从特征表示空间中的损坏数据点到真实数据点,从而产生更加逼真的修复图像。我们在两个基准数据集上进行了广泛的实验,定性和定量地证明了我们模型的有效性和优越性。