跳至內容

生成對抗網絡

本頁使用了標題或全文手工轉換
維基百科,自由的百科全書

生成對抗網絡(英語:Generative Adversarial Network,簡稱GAN)是非監督式學習的一種方法,通過兩個神經網路相互博弈的方式進行學習。該方法由伊恩·古德費洛等人於2014年提出。[1] 生成對抗網絡由一個生成網絡與一個判別網絡組成。生成網絡從潛在空間(latent space)中隨機取樣作為輸入,其輸出結果需要盡量模仿訓練集中的真實樣本。判別網絡的輸入則為真實樣本或生成網絡的輸出,其目的是將生成網絡的輸出從真實樣本中盡可能分辨出來。而生成網絡則要盡可能地欺騙判別網絡。兩個網絡相互對抗、不斷調整參數,最終目的是使判別網絡無法判斷生成網絡的輸出結果是否真實。[1][2][3]

由GAN deepfake生成的人臉

生成對抗網絡常用於生成以假亂真的圖片。[4]此外,該方法還被用於視頻幀預測[5]、三維物體模型[6]等。

生成對抗網絡雖然最開始提出是為了無監督學習,但經證明對半監督學習[4]完全監督學習[7]強化學習[8]GAIL(Generative Adversarial Imitation Learning)通過逆強化學習框架實現策略優化[9]也有效。 在2016年的一個研討會上,楊立昆稱生成式對抗網絡為「機器學習這二十年來最酷的想法」[10]

核心定義

[編輯]
  1. 數學形式 minG​maxDV(D,G)=Expdata​​[logD(x)]+Ezpz​​[log(1−D(G(z)))] 其中G為生成器,D為判別器[11]
  2. 潛在空間說明,潛在空間z通常服從高斯分布N(0,I),維度需人工設定(如DCGAN中z∈R100)[12]

現代基準數據[13]

[編輯]
模型 數據集 評價指標 (FID↓) 參數量
StyleGAN2 FFHQ 2.84 30M
BigGAN-deep ImageNet 3.45 50M
VQ-VAE-2 CelebA-HQ 5.18 13M

重要子類說明

[編輯]
  1. Wasserstein GAN改進 使用Earth-Mover距離替代JS散度: W(pr,pg​)=infγ∈Π(pr,pg​)​E(x,y)∼γ​[∣∣xy∣∣] 需滿足判別器Lipschitz約束[14]
  2. 漸進式訓練策略 ProGAN採用分層訓練模式,從低分辨率(4×4)開始逐步加倍分辨率至1024×1024[15]

應用

[編輯]

生成對抗網路的應用範圍正在大幅增加。[16][17]

時尚和廣告

[編輯]

生成對抗網路可用於創建虛構時裝模特的照片,無需聘請模特、攝影師、化妝師,也省下工作室和交通的開銷[18]。 生成對抗網路可用於時尚廣告活動,創建來自不同群體的模特兒,這可能會增加這些群體的人的購買意圖[19]

科學

[編輯]

生成對抗網路可以改善天文圖像[20],並模擬重力透鏡以進行暗物質研究[21][22][23]

在2019年,生成對抗網路成功地模擬了暗物質在太空中特定方向的分布,並預測將要發生的引​​力透鏡。[24][25]

電子遊戲

[編輯]

在2018年,生成對抗網路進入了電子遊戲改造社區。對舊的電子遊戲透過圖像訓練,以4k或更高分辨率重新創建低分辨率2D紋理,然後對它們進行下取樣以適應遊戲的原始分辨率(結果類似於抗鋸齒的超級取樣方法)[26]。通過適當的訓練,生成對抗網路提供更清晰、高於原始的2D紋理圖像品質,同時完全保留原始的細節、顏色。

參見

[編輯]

參考文獻

[編輯]
  1. ^ 1.0 1.1 Goodfellow, Ian J.; Pouget-Abadie, Jean; Mirza, Mehdi; Xu, Bing; Warde-Farley, David; Ozair, Sherjil; Courville, Aaron; Bengio, Yoshua. Generative Adversarial Networks. 2014. arXiv:1406.2661可免費查閱 [stat.ML]. 
  2. ^ 能根據文字生成圖片的 GAN,深度學習領域的又一新星. [2018-04-15]. (原始內容存檔於2018-04-15). 
  3. ^ Andrej Karpathy, Pieter Abbeel, Greg Brockman, Peter Chen, Vicki Cheung, Rocky Duan, Ian Goodfellow, Durk Kingma, Jonathan Ho, Rein Houthooft, Tim Salimans, John Schulman, Ilya Sutskever, And Wojciech Zaremba, Generative Models, OpenAI, [2016-04-07], (原始內容存檔於2021-04-22) 
  4. ^ 4.0 4.1 Salimans, Tim; Goodfellow, Ian; Zaremba, Wojciech; Cheung, Vicki; Radford, Alec; Chen, Xi. Improved Techniques for Training GANs. 2016. arXiv:1606.03498可免費查閱 [cs.LG]. 
  5. ^ 存档副本. [2017-03-17]. (原始內容存檔於2017-03-20). 
  6. ^ 3D Generative Adversarial Network. [2017-03-17]. (原始內容存檔於2019-10-27). 
  7. ^ Isola, Phillip; Zhu, Jun-Yan; Zhou, Tinghui; Efros, Alexei. Image-to-Image Translation with Conditional Adversarial Nets. Computer Vision and Pattern Recognition. 2017 [2019-06-18]. (原始內容存檔於2020-04-14). 
  8. ^ Ho, Jonathon; Ermon, Stefano. Generative Adversarial Imitation Learning. Advances in Neural Information Processing Systems. [2019-06-18]. (原始內容存檔於2019-10-19). 
  9. ^ Ermon, Stefano, Probabilistic Inference by Hashing and Optimization, The MIT Press: 265–288, 2016-12-23 [2025-08-07], ISBN 978-0-262-33793-9 
  10. ^ LeCun, Yann. RL Seminar: The Next Frontier in AI: Unsupervised Learning. [2019-06-18]. (原始內容存檔於2020-04-30). 
  11. ^ Parker, Charles Thomas; Taylor, Dorothea; Garrity, George M. Exemplar Abstract for Rhodococcus wratislaviensis (Goodfellow et al. 1995) Goodfellow et al. 2002 emend. Nouioui et al. 2018 and Tsukamurella wratislaviensis Goodfellow et al. 1995.. The NamesforLife Abstracts. 2010-03-16 [2025-08-07]. 
  12. ^ Radford, Andrew N. Moving beyond species-specific noise-induced changes in birdsong: a comment on Roca et al.. Behavioral Ecology. 2016, 27 (5) [2025-08-07]. ISSN 1045-2249. doi:10.1093/beheco/arw103. 
  13. ^ Figure 3: Risk of bias summary (Abreu et al., 2017; Afshar et al., 2010; Ai, 2020; Bolasco et al., 2011; Cai et al., 2022; Chen, Zhao & Huang, 2019; Dai & Ma, 2021; Deng, 2011; Dong et al., 2011; Fakhrpour et al., 2020; Fang et al., 2023; Feng et al., 2020; Frih et al., 2017; Hristea et al., 2016; Jeong et al., 2019; Kozlowska et al., 2023; Leng, 2012; Li et al., 2008; Li & Feng, 2020; Liao et al., 2016; Limwannata et al., 2021; Lu, 2022; Martin-Alemañy et al., 2020, 2016, 2022; Sezer et al., 2014; Shi et al., 2021; Su et al., 2022; Sun, Sun & Yang, 2022a; Tabibi et al., 2023; Tan et al., 2015; Tayebi, Ramezani & Kashef, 2018; Vijaya et al., 2019; Wang & Liu, 2021; Wang, 2018; Wang et al., 2019; Wang, 2019; Wang et al., 2023; Wei, 2020; Wen et al., 2022; Wilund et al., 2010; Xu et al., 2022; Xu & Fang, 2016; Yan, Zhao & Peng, 2022; Yang et al., 2021; Yao et al., 2020; Yu & Cao, 2018; Zeng et al., 2020; Zhou, 2020; Zhou et al., 2016; Zhu et al., 2020).. doi.org. [2025-08-07]. 
  14. ^ Table 1: Study characteristics (Elmasri et al., 2017; Rastan et al., 2008; Ratnam et al., 2007; Deuling et al., 2008; Veasey et al., 2008; Engelbert et al., 2010; Lucatelli et al., 2017; Gonen, Hakyemez & Erdogan, 2021; Ierardi et al., 2023).. doi.org. [2025-08-07]. 
  15. ^ Indonesian Comparative Law Review https://doi.org/10.18196/iclr.2018.11. 2018, 1 (1) [2025-08-07]. ISSN 2655-2353. doi:10.18196/iclr.2018.11.  缺少或|title=為空 (幫助)
  16. ^ Caesar, Holger, A list of papers on Generative Adversarial (Neural) Networks: nightrome/really-awesome-gan, 2019-03-01 [2019-03-02], (原始內容存檔於2020-04-30) 
  17. ^ 生成式AI:缘起、机遇和挑战, 经济观察报, 2023-01-09. [2023-01-24]. (原始內容存檔於2023-01-24). 
  18. ^ Wong, Ceecee. The Rise of AI Supermodels. CDO Trends. [2019-06-18]. (原始內容存檔於2020-04-16). 
  19. ^ Dietmar, Julia. GANs and Deepfakes Could Revolutionize The Fashion Industry. Forbes. [2019-06-18]. (原始內容存檔於2019-09-04). 
  20. ^ Schawinski, Kevin; Zhang, Ce; Zhang, Hantian; Fowler, Lucas; Santhanam, Gokula Krishnan. Generative Adversarial Networks recover features in astrophysical images of galaxies beyond the deconvolution limit. Monthly Notices of the Royal Astronomical Society: Letters. 2017-02-01, 467 (1): L110–L114. Bibcode:2017MNRAS.467L.110S. arXiv:1702.00403可免費查閱. doi:10.1093/mnrasl/slx008. 
  21. ^ Kincade, Kathy. Researchers Train a Neural Network to Study Dark Matter. R&D Magazine. [2019-06-18]. (原始內容存檔於2019-05-15). 
  22. ^ Kincade, Kathy. CosmoGAN: Training a neural network to study dark matter. Phys.org. 2019-05-16 [2019-06-18]. (原始內容存檔於2020-04-14). 
  23. ^ Training a neural network to study dark matter. Science Daily. 2019-05-16 [2019-06-18]. (原始內容存檔於2020-04-30). 
  24. ^ at 06:13, Katyanna Quach 20 May 2019. Cosmoboffins use neural networks to build dark matter maps the easy way. www.theregister.co.uk. [2019-05-20]. (原始內容存檔於2020-04-23) (英語). 
  25. ^ Mustafa, Mustafa; Bard, Deborah; Bhimji, Wahid; Lukić, Zarija; Al-Rfou, Rami; Kratochvil, Jan M. CosmoGAN: creating high-fidelity weak lensing convergence maps using Generative Adversarial Networks. Computational Astrophysics and Cosmology. 2019-05-06, 6 (1): 1. ISSN 2197-7909. doi:10.1186/s40668-019-0029-9. 
  26. ^ Tang, Xiaoou; Qiao, Yu; Loy, Chen Change; Dong, Chao; Liu, Yihao; Gu, Jinjin; Wu, Shixiang; Yu, Ke; Wang, Xintao. ESRGAN: Enhanced Super-Resolution Generative Adversarial Networks. 2018-09-01 [2019-06-18]. (原始內容存檔於2019-04-13) (英語).