Newbeeer / pfgmpp

Code for ICML 2023 paper, "PFGM++: Unlocking the Potential of Physics-Inspired Generative Models"

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

A generate.py bug for loading trained model

YYZ1021 opened this issue · comments

Hi,

When I generate images by using my model, I found it will output nothing.

I have debugded the code and I found that you didn't pass the option 'network' into the 'main' function.

def main(ckpt, end_ckpt, outdir, subdirs, seeds, class_idx, max_batch_size, save_images, pfgmpp, aug_dim, edm, use_pickle, device=torch.device('cuda'), **sampler_kwargs):

And the 'main' function will search the model checkpoint in the 'outdir' path.
stats = glob.glob(os.path.join(outdir, "training-state-*.pkl"))

Now I put the model checkpoint into the 'outdir' folder, and it works.

However, it may be confused. Please check it, thank you.

Thanks for spotting this. I will add this feature tomorrow.