Zhendong-Wang / Diffusion-GAN

Official PyTorch implementation for paper: Diffusion-GAN: Training GANs with Diffusion
MIT License
625 stars 67 forks source link

training time #4

Closed 49xxy closed 2 years ago

49xxy commented 2 years ago

Thank you for your excellent work. Since I have been studying StyleGAN2 before, I want to know how is the training time of diffusion-Gan compared with StyleGAN2?

Zhendong-Wang commented 2 years ago

Hi there, thanks for your interest! The training time is almost the same as the original StyleGAN2 and even slightly faster than StyleGAN2-ADA, though the times are all similar.

49xxy commented 2 years ago

您好,感谢您的关注!训练时间与原始 StyleGAN2 几乎相同,甚至比 StyleGAN2-ADA 稍快,尽管时间都差不多。

Hello, I see "augment_pipe" replaced with "diffusion" in many places in the code of diffuse-stylegan2. What does this mean? Is "augment_pipe" deleted? I wonder if you know a job named as deceive D . I want to combine this pseudo-enhancement method with diffuse-Stylegan2, but I don't know how to start. I would like to ask for your help!

49xxy commented 2 years ago

What I understand is to add diffusion in an adaptive way to D, is that right?

Zhendong-Wang commented 2 years ago

Yes, diffusion object replaces the original augment_pipe object, while they have similar functionality just with different name. The original ADA augment_pipe is moved to the `training/adaaug.py`` file, which could be combined with diffusion.

To combine diffusion with other augmentation method, you could have a look at the training/diffusion.py file, https://github.com/Zhendong-Wang/Diffusion-GAN/blob/main/diffusion-stylegan2/training/diffusion.py#L137-L144 https://github.com/Zhendong-Wang/Diffusion-GAN/blob/main/diffusion-stylegan2/training/diffusion.py#L186.

Yes, adding diffusion in an adaptive way to D is the simplest plug-in, which we found also have good performance. You could also try to add the t embedding from diffusion into the discriminator input.

49xxy commented 2 years ago

Thank you again for your guidance on my study and work, and thank you very much for your excellent work.

I was able to successfully apply the diffusion to my baseline work, although the diffusion might conflict with the work (https://github.com/genforce/insgen) .

I wonder if you could add a training option such as -- Diffuion =false/true

Zhendong-Wang commented 2 years ago

 I think you could add that easily by yourself. :)