Generative AI with Python and TensorFlow by Joseph Babcock Raghav Bali
Author:Joseph Babcock, Raghav Bali
Language: eng
Format: epub
Publisher: Packt
Published: 2021-04-28T07:43:56+00:00
The training loop for CycleGAN is mostly similar to that of pix2pix with a few additions. As we have two pairs of generators and discriminators, the function takes all four models as input along with a combined gan object. The training loop starts with the generation of fake samples from both generators and then uses them to update weights for their corresponding discriminators. These are then combined to train the overall GAN model as well.
Using the components described in this section, we experimented with two sets of style transfer datasets, turning apples into oranges and turning photographs into Van Gogh paintings. Figure 7.11 shows the output of the apples to oranges experiment through different stages of training:
Figure 7.11: CycleGAN generated outputs at different stages of training for the apples to oranges experiment
Similarly, Figure 7.12 shows how CycleGAN learns to transform photographs into Van Gogh style artwork:
Figure 7.12: CycleGAN generated outputs at different stages of training for the photographs to Van Gogh style paintings experiment
As is evident from the samples above (Figures 7.11 and 7.12), CycleGAN seems to have picked up the nuances from both domains without having paired training samples. This is a good leap forward in cases where paired samples are hard to get.
Another important observation from the two experiments is the amount of training required. While both experiments used exactly the same setup and hyperparameters, the apples to oranges experiment trained much faster compared to the photograph to Van Gogh style painting setup. This could be attributed to the large number of modes in the case of the second experiment, along with diversity in the training samples.
This ends our section on unpaired style transfer. Now we're going to explore some work relating to and branching off from both paired and unpaired style transfer.
Download
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
Management Strategies for the Cloud Revolution: How Cloud Computing Is Transforming Business and Why You Can't Afford to Be Left Behind by Charles Babcock(4130)
Ego Is the Enemy by Ryan Holiday(3991)
Offensive Shellcode from Scratch by Rishalin Pillay(3663)
Exploring Deepfakes by Bryan Lyon and Matt Tora(3247)
Robo-Advisor with Python by Aki Ranin(3023)
Learning C# by Developing Games with Unity 2021 by Harrison Ferrone(2869)
Speed Up Your Python with Rust by Maxwell Flitton(2847)
Liar's Poker by Michael Lewis(2810)
Linux Command Line and Shell Scripting Techniques by Vedran Dakic and Jasmin Redzepagic(2803)
Agile Security Operations by Hinne Hettema(2802)
OPNsense Beginner to Professional by Julio Cesar Bueno de Camargo(2801)
Extreme DAX by Michiel Rozema & Henk Vlootman(2790)
Essential Cryptography for JavaScript Developers by Alessandro Segala(2740)
Elevating React Web Development with Gatsby by Samuel Larsen-Disney(2729)
AI-Powered Commerce by Andy Pandharikar & Frederik Bussler(2642)
Python for ArcGIS Pro by Silas Toms Bill Parker(2642)
Cryptography Algorithms by Massimo Bertaccini(2627)
Incident Response Techniques for Ransomware Attacks by Oleg Skulkin(2626)
Distributed .NET with Microsoft Orleans by Bhupesh Guptha Muthiyalu Suneel Kumar Kunani(2625)