betterze / StyleSpace

StyleSpace Analysis: Disentangled Controls for StyleGAN Image Generation
309 stars 34 forks source link

Do you have the pytorch version of this part? I don't quite understand the author's approachBy the way, zongze, can you share your pretrained face segmentation model? @betterze #28

Closed jweihe closed 2 years ago

jweihe commented 2 years ago

By the way, zongze, can you share your pretrained face segmentation model? @betterze And, how about the speed of gradient computation (I see that you use 1K images to compute gradient)? I find in my experiments, the speed of only an image using your code is very slow... (maybe 1 image need 40 minutes), thus do you have any ways to speed it up?

Originally posted by @sunpeng1996 in https://github.com/betterze/StyleSpace/issues/4#issuecomment-826317931

jweihe commented 2 years ago

Do you have the pytorch version of this part? I don't quite understand the author's approach

betterze commented 2 years ago

The pretrained face segmentation model is here. I attatch the link in the Localized channels section.

The gradient computation takes time. It also takes me around 40 mins per image since the stylegan2 in 1024x1024 is very big. I use many gpu to compute the gradient. Each gpu will be assigned with 4 images. You can change this parameter.

I have torch version of codes for single channel manipulation in S space. But I dont have gradient computation codes for torch version.

jweihe commented 2 years ago

thank you,I have implemented the code myself~

lovejing0306 commented 2 years ago

thank you,I have implemented the code myself~

Can you share your pytorch code ?

WuYufeng98 commented 1 year ago

thank you,I have implemented the code myself~ Can you share your pytorch code ?

betterze commented 1 year ago

We implement the single channel manipulation in torch, pls take a look of here.

WuYufeng98 commented 1 year ago

We implement the single channel manipulation in torch, pls take a look of here. thank you!