NVlabs / SPADE

Semantic Image Synthesis with SPADE
https://nvlabs.github.io/SPADE/
Other
7.61k stars 982 forks source link

How do I change the style of the generated image #25

Closed vincentgc closed 5 years ago

vincentgc commented 5 years ago

Hi, you did a great job. I know that the generated images can show different style using gauGAN, but how can I reproduce the function?

vincentgc commented 5 years ago

Do I need to train different models from scratch if I want to obtain some images with different styles?

code-de commented 5 years ago

And how to change a style of a generated image if I trained a model with VAE?

taesungp commented 5 years ago

To produce outputs with different styles, you need to train with VAE by using --use_vae flag. It it was not trained with VAE, it cannot generate different styles.

The pretrained models of COCO, ADE20K and Cityscapes are all without VAE, because we actually didn't want random generation of styles, in order to keep the evaluation metric reproducible.

As you know. for GauGAN video, we trained with VAE.

Once you finish training with VAE, to produce different styles for the same semantic layout input, simply run the model multiple times. It will always generate different results.