RameenAbdal / StyleFlow

StyleFlow: Attribute-conditioned Exploration of StyleGAN-generated Images using Conditional Continuous Normalizing Flows (ACM TOG 2021)
http://rameenabdal.github.io/StyleFlow
2.42k stars 342 forks source link

Realization of other dataset #85

Closed luobo1995 closed 3 years ago

luobo1995 commented 3 years ago

Hi~

It's great work of your Styleflow on human face image experiment. But i want to know how you guys work it on other dataset like cars. I think the procedure is like:

1.download LSNU car dataset and transform it into latent code following guide in StyleGAN2 2.using classifier to label the attributes of car dataset (or is there an existing one?) 3.train StyleFlow model with car dataset and its attributes, obtain the flow_weight like modellarge10.pt of human face? 4.use car_latent_code, car_attribute, car_flow_weight, stylegan2-car-config-f.pkl to edit the attributes and generate images?

I would appreciate your guidance and advice. Thx~!

RameenAbdal commented 3 years ago

Yes, but in the first step, you would require a projection step. There are many projection papers, but you would have to move away from the original distribution (W space) to fit the image into the latent space. This would cause other problems like the complex features may be encoded in the latter Style layers in W+ space, making the distribution difficult to model. A safe strategy is using the sampled StyleGAN images for the dataset.

Brainerd95 commented 2 years ago

Hey, I retrained the FFHQ stylegan model with my own dataset and I'm trying to get it running with StyleFlow now. Since the model differs significantly from ther original FFHQ model because of the training process, the given StyleFlow model doesn't fit anymore and yields bad results. I've read your paper and tried to understand how to train the StyleFlow model with my own dataset, but I'm still not sure how to implement each of the described steps. Is there any further explanation or tutorial available on how to generate/prepare a custom dataset to train StyleFlow? Thanks in advance for your help.