WisconsinAIVision / few-shot-gan-adaptation

[CVPR '21] Official repository for Few-shot Image Generation via Cross-domain Correspondence
https://utkarshojha.github.io/few-shot-gan-adaptation/
Other
290 stars 47 forks source link

Training with other pretrained StyleGAN2 error #35

Open SaranchaiAng opened 2 years ago

SaranchaiAng commented 2 years ago

I trained successfully with pretrained ffhq as example code.

However I tried to trained using other pretrained model as a source model for example Anime portraits from https://github.com/justinpinkney/awesome-pretrained-stylegan2 (I already convert the pretrained model from .pkl to .pt) but I got an error it said

load model: /content/drive/MyDrive/FEWSHOTGAN/data/checkpoints/anime.pt Traceback (most recent call last): File "/content/drive/MyDrive/FEWSHOTGAN/few-shot-gan-adaptation-main/train.py", line 551, in <module> assert args.source_key in args.ckpt #comment AssertionError

Anyone know how to fix this? Thank you

giddyyupp commented 2 years ago

Hi, afai see this line does nothing. you could just comment it out. you don't have to load the ffhq model, it should be any pretrained model.

li-car-fei commented 2 years ago

Hi, afai see this line does nothing. you could just comment it out. you don't have to load the ffhq model, it should be any pretrained model.

If I want to fine-tune on a trained stylegan, should I load on generator or g_ema? Or should both be loaded?