Open baiHR17 opened 3 years ago
The [18, 512] latent code is actually repeating one [512] latent code 18 times. Or, you can directly vectorize it to an 18*512=9216-dimensional latent code if you want.
Hey @baiHR17, I'm using the encoder from this repo https://github.com/pender/stylegan-encoder to encode custom images into the latent vectors, it is generating the latent vectors in the shape of 1x512 by default you may give it a try.
The [18, 512] latent code is actually repeating one [512] latent code 18 times. Or, you can directly vectorize it to an 18*512=9216-dimensional latent code if you want.
hey, I'm using the train_boundary file to train a custom boundary, inside this file, there is a remaining_data variable other than train and validation data. what was that exactly?
one more question, when we were trying to edit the custom image by using the given boundaries available inside this repo, first we have to convert it into the corresponding latent vectors but these vectors after editing, are not similar to the original images, so is there any way to get the edited images same as the original with changes?
Can you @ShenYujun please prefer, any approach to generate the latent vector in a faster way for the custom images because generating latent vectors taking lots of time, and also approximately how many images are needed to generate a custom boundary? Please reply if you got time. Thanks in advance ,
About the remaining_data
. Let's say we have 10000 images in total. 1000 with the highest scores and 1000 with the lowest scores are used for training and validation (for example, if we split the train-validation set with a ratio of 0.7, there will be 2000 * 0.7 = 1400 training data and 600 validation data). The remaining 8000 images, whose scores are with a relatively low degree of confidence, are treated as remaining_data
.
Please try this repo for real image editing. Using an encoder would be the fastest way to get the inverted latent code. That repo also provides some boundaries.
If you want your customized boundary to be accurate, I would recommend generating more than 500K images and using the 10K with the highest scores and 10K with the lowest scores as the training-validation dataset.
One more thing is that I'm following steps as you have mentioned, my concern is that I've collected the attribute score for say 100k images. After that, I need the latent vector corresponding to all the images, I'm using this repo https://github.com/pender/stylegan-encoder to find the latent vectors for the images. But the problem is in 7 days iv generated the vectors for only 6k images on Tesla K80 GPU, is they any other way or faster way to generate the latent vectors. Would using a better GPU than K80 will help? Please reply I stuck in this phase, Thanks
Hi, thanks for uploading this repo. I would like to train to get the remaining boundaries existed in FFHQ dataset (apart from gender, smile, glasses, position provided in your repo) on StyleGAN. However, when reading the descriptions for the function train_boundary(), it seems that the latent_codes for the training image encodings must be only 1 dimension. So how should I process the [18, 512] dimension encoding vector corresponds to StyleGAN to be able to feed it to this function to train for the boundries? I am basically wondering how to get the boundaries files you provided with stylegan and ffhq in the names.
Many thanks!