FoundationVision / VAR

[GPT beats diffusion🔥] [scaling laws in visual generation📈] Official impl. of "Visual Autoregressive Modeling: Scalable Image Generation via Next-Scale Prediction". An *ultra-simple, user-friendly yet state-of-the-art* codebase for autoregressive image generation!
MIT License
4.03k stars 303 forks source link

Inference code keeps generating the same image #61

Closed moeinheidari7829 closed 4 months ago

moeinheidari7829 commented 4 months ago

Dear everyone,

Has anyone had the experience of generating images using "recon_B3HW = var.autoregressive_infer_cfg(B=1, label_B=torch.tensor([label], device=device), cfg=cfg, top_k=900, top_p=0.96, g_seed=seed, more_smooth=more_smooth)"?

When running the code, it keeps producing the same images for each class! I do not know what is causing the problem!

Jvanlo commented 4 months ago

Did you modify the seed?

moeinheidari7829 commented 4 months ago

Yes, I solved it. Thank you very much.