Conditional image generation is the task of generating diverse images using class label information. Although many conditional Generative Adversarial Networks (GAN) have shown realistic results, such methods consider pairwise relations between the embedding of an image and the embedding of the corresponding label (data-to-class relations) as the conditioning losses. In this paper, we propose ContraGAN that considers relations between multiple image embeddings in the same batch (data-to-data relations) as well as the data-to-class relations by using a conditional contrastive loss. The discriminator of ContraGAN discriminates the authenticity of given samples and minimizes a contrastive objective to learn the relations between training images. Simultaneously, the generator tries to generate realistic images that deceive the authenticity and have a low contrastive loss. The experimental results show that ContraGAN outperforms state-of-the-art-models by 7.3% and 7.7% on Tiny ImageNet and ImageNet datasets, respectively. Besides, we experimentally demonstrate that contrastive learning helps to relieve the overfitting of the discriminator. For a fair comparison, we re-implement twelve state-of-the-art GANs using the PyTorch library. The software package is available at https://github.com/POSTECH-CVLab/PyTorch-StudioGAN.
翻译:有条件的图像生成是使用类类标签信息生成不同图像的任务。 虽然许多有条件的基因反反差网络(GAN)已经展示了现实的结果, 但这种方法将嵌入图像和嵌入相应标签(数据到类关系)之间的对称关系视为调节性损失。 在本文中, 我们提出 ContraGAN, 考虑在同一批( 数据到数据关系) 中嵌入多个图像之间的关系, 以及通过使用有条件的对比性损失来考虑数据到分类关系。 ContraGAN 的歧视问题歧视了给定样本的真实性, 并尽量减少了学习培训图像之间关系的对比目标。 同时, 生成者试图生成真实图像, 欺骗真实性, 并造成低对比性损失。 实验结果显示, ContraGAN 分别用7.3% 和 7. 7 % 在Tiniy 图像网络和图像网络数据集中, 以及数据到 7.7 % 。 此外, 我们实验性地证明, 对比性学习有助于缓解歧视者对 AN 的过度配置。 为了公平比较, 我们重新使用 GST- Storch-Toto AStototo ASto ASy ASto.