GAN理解与实现
2025-2-6
| 2025-2-6
Words 1373Read Time 4 min
type
Post
status
Published
date
Feb 6, 2025
slug
summary
GAN算法的个人理解笔记
tags
category
技术分享
icon
password
GAN是generative advertisal network的简称,中文唤做生成式对抗网络。在常规的理解中,generator和discriminator是对抗的关系,包括GAN的原始论文中将generator比做一个做假钞的坏人,将discriminator比做警察,generator产生的假钞越来越逼真,导致警察无法进行判断,两个之间的关系是对抗。
然而李宏毅老师的教程中,YouTubeYouTubeGAN Lecture 1 (2018): Introduction,给了一个更peace and love的例子,将generator比做一个学画画的学生,discriminator会指出这个学生画的画和真实的作品之间的区别,然后generator画的会越来越逼真,真是因吹斯汀呀。
notion image
notion image
notion image

Structed Learning

让机器输出的是一个序列的任务,称作Structed Learning。
 

代码实现

参考代码:
KaggleKaggleGAN implementation from scratch using PyTorch
伪代码:
训练:
推理:
随便random一个符合维度的向量,都可以生成猫猫图片
Qanything 2.0源码解析系列6: PDF解析逻辑Pycharm远程debug出现Couldn't apply path mapping to the remote file.解决方案和原理。
Loading...