CodeFormer icon indicating copy to clipboard operation
CodeFormer copied to clipboard

Predicted face problem in Stage1

Open HualeiZhuu opened this issue 2 years ago • 5 comments

I trained 80000 steps in Stage1, and I found that the output faces were very strange, is it OK ? prediction: 00000000_80000 gt: 00000000_gold

So I used the pre-trained model vqgan_code1024.pth to predict, the faces were also strange. prediction: 00000000_pred

HualeiZhuu avatar Apr 26 '23 13:04 HualeiZhuu

Imet the similar problem when input the following image using released vqgan_code1024.pth image the output is image

The brightness and color changes are too obvious?

hailsham avatar May 08 '23 09:05 hailsham

Imet the similar problem when input the following image using released vqgan_code1024.pth image the output is image

The brightness and color changes are too obvious?

I found the problem. it caused by my wrong normalizion.

hailsham avatar May 08 '23 10:05 hailsham

Yes, the problem is the normalization. In function nondist_validation, I change sr_img = tensor2img([visuals['result']]) to sr_img = tensor2img([visuals['result']], rgb2bgr=True, min_max=(-1, 1)), then the output becomes normal.

HualeiZhuu avatar May 08 '23 10:05 HualeiZhuu

How do you run inference for model from the first part?

heorhiikalaichev avatar Sep 25 '23 12:09 heorhiikalaichev

Imet the similar problem when input the following image using released vqgan_code1024.pth image the output is image The brightness and color changes are too obvious?

I found the problem. it caused by my wrong normalizion.

Hi, could you please twll how to solve this bright issue? What did you change for the normalization? Thanks.

YunanwuNancy avatar Sep 25 '24 14:09 YunanwuNancy