Leveraging CycleGAN
Imagine a scenario where we ask you to perform image translation from one class to another, but without using the input and the corresponding output images to train the model. For example, change the actor present in the current scene of a movie from one actor another. However, we give you the images of both classes/actors in two distinct folders. CycleGAN comes in handy in such a scenario.
In this section, we will learn how to train CycleGAN (https://arxiv.org/abs/1703.10593) to convert an image of an apple into an image of an orange and vice versa. But first, let’s understand how CycleGAN works.
How CycleGAN works
The Cycle in CycleGAN refers to the fact that we are translating (converting) an image from one class to another and back to the original class. At a high level, we will have three separate loss values in this architecture. More details about the loss calculations in the next pages:
- Adversarial loss: This ensures that the...