GAN学习笔记

1.原始的GAN

1.1原始的损失函数

1.1.1写法1参考1参考2

1.1.2 写法2

where,

  • G = Generator
  • D = Discriminator
  • Pdata(x) = distribution of real data
  • P(z) = distribution of generator
  • x = sample from Pdata(x)
  • z = sample from P(z)
  • D(x) = Discriminator network
  • G(z) = Generator network

1.1.3 写法3: 参考3

1.2Wasserstein损失 参考

2.**Conditional GAN (**CGAN)

2.1 写法1:

The Discriminator has two task

  • Discriminator has tocorrectly label real images which are coming from training data set as "real".
  • Discriminator has to correctly label generated images which are coming from Generator as "fake".

We need to calculate two losses for the Discriminator. The sum of the "fake" image and "real" image loss is the overall Discriminator loss.** So the loss function of the Discriminator is aiming at minimizing the error of predicting real images coming from the dataset and fake images coming from the Generator given their one-hot labels.

The Generator network has one task

  • To create an image that looks as "real" as possible to fool the Discriminator.

The loss function of the Generator minimizes the correct prediction of the Discriminator on fake images conditioned on the specified one-hot labels.

  • The conditioning is performed by feeding y into the both the discriminator and generator as additional input layer.
  • In the generator the prior input noise p_z (z ), and y are combined in joint hidden representation.
  • In the discriminator x and y are presented as inputs and to a discriminative function.
  • The objective function of a two-player minimax game become:

2.2 写法2:

where is a probability distribution over classes, is the probability distribution of real images of class C, and the probability distribution of images generated by the generator when given class label C.

2.3 写法3:参考

相关推荐
sakoba10 分钟前
MySQL常见问题学习
数据库·学习·mysql
想不明白的过度思考者17 分钟前
Unity学习笔记——虚拟摇杆实现笔记(事件触发器的使用、UGUI 坐标转换)
笔记·学习·unity
晓py18 分钟前
音视频基础概念入门_FFmpeg学习笔记
学习·ffmpeg·音视频
red_redemption19 分钟前
自由学习记录(196)
学习
踏着七彩祥云的小丑44 分钟前
AI学习——记忆系统
人工智能·学习·ai
xcLeigh1 小时前
Python入门:Python3 operator模块全面学习教程
开发语言·python·学习·教程·python3·operator
Dest1ny-安全1 小时前
2026最新CTF知识库:12大Web漏洞深度文章+1156篇历年大赛WP+50+脚本+Payload速查 +AI/RAG离线在线知识库
java·学习·安全·web安全·servlet
魔法阵维护师1 小时前
从零开发游戏需要学习的c#模块,第三十二章(Boss 战系统)
学习·游戏·c#
洵有兮1 小时前
Shell 脚本编程学习总结(基础 + 变量 + 条件 + 流程控制 + 函数数组)
linux·学习
疯狂打码的少年1 小时前
流水线冒险(结构冒险/数据冒险/控制冒险)
笔记