Cycle GAN(ICCV. 2017)

image-20210629172000459

1. Motivation

  • For many tasks, paired training data will not be available.
  • We present an approach for learning to translate an image from a source domain X to a target domain Y in the absence of paired examples.

对于Cycle consistent的引入很重要,否则会出现模式崩溃的问题,所有输入图像都映射到相同的输出图像并且优化无法取得进展。

  • Moreover, in practice,where all input images map to the same output image and the optimization fails to make progress.
image-20210629200450492

2. Contribution

  • We apply our method to a wide range of applications, including collection style transfer, object transfiguration, season transfer and photo enhancement.

  • We also compare against previous approaches that rely either on hand-defined factorizations of style and content, or on shared embedding functions, and show that our method outperforms these baselines.

3. Method

image-20210629204834678

3.1 Adversarial Loss

image-20210629204927778

3.2 Cycle Consistency Loss

image-20210629205554803

3.3 Full Objective

image-20210629205635887
image-20210629205651098

Cylce GAN中的loss部分,其中与pixel2pixelGAN不同的是,CycleGAN采用的是先update G在D的方法,使用detach()。
训练的时候,是A–>B; B–>A 同时进行的,一次迭代过程需要优化G_A, G_B, D_A, D_B。

    def forward(self):
        """Run forward pass; called by both functions <optimize_parameters> and <test>."""
        self.fake_B = self.netG_A(self.real_A)  # G_A(A)
        self.rec_A = self.netG_B(self.fake_B)   # G_B(G_A(A))
        self.fake_A = self.netG_B(
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值