StyleAvatar icon indicating copy to clipboard operation
StyleAvatar copied to clipboard

StyleAvatar Training Resizes Image Wrong

Open oijoijcoiejoijce opened this issue 2 years ago • 4 comments

Running full style avatar but it seems to resize images the wrong way. It zooms out a lot on the face for each image (even though it was 1536 crop size from faceverse and there is a lot of space around the face). This makes most of the input images off.

Is there a mistake or is this normal?

oijoijcoiejoijce avatar Jul 27 '23 04:07 oijoijcoiejoijce

Maybe it's normal. Full styleavatar will crop the image randomly. Can you show me an example image?

LizhenWangT avatar Jul 27 '23 04:07 LizhenWangT

Please check if your back image is 1536. The preprocessing code has also been updated.

LizhenWangT avatar Jul 27 '23 04:07 LizhenWangT

Here is an example; the back image is 1536 - I used the updated code. Thanks in advance!

video_siebel_007500

oijoijcoiejoijce avatar Jul 27 '23 06:07 oijoijcoiejoijce

It seems normal, and you can adjust the crop range in Line 18 of FaceVerse/faceversev3_jittor/util_functions.py. The scale 1.25 can be adjust to 1.5 if you need a larger range. And I forgot to adjust the loss term weights in this version. Please change the line for vgg_loss: vgg_loss = vgg(F.upsample(fake_img, size=(512, 512), mode='bilinear'), image_512) * 0.01 New code will be updated soon.

LizhenWangT avatar Jul 27 '23 06:07 LizhenWangT