GithubHelp home page GithubHelp logo

teapearce / conditional_diffusion_mnist Goto Github PK

View Code? Open in Web Editor NEW
540.0 540.0 62.0 24.97 MB

Conditional diffusion model to generate MNIST. Minimal script. Based on 'Classifier-Free Diffusion Guidance'.

License: MIT License

Python 100.00%

conditional_diffusion_mnist's People

Contributors

gudgud96 avatar mmdalix avatar teapearce avatar xiaosheng-zhao avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

conditional_diffusion_mnist's Issues

Memory consumption issue and solution

Hi,

Thank you so much for the code!

I am working with this code these days and I found that sampling from a trained model consumes significant memory. I looked into this problem and I found that it is helpful to add a line "x_i = x_i.detach()" at the end of the for loop in function DDPM.sample in script.py.

I hope it helps!

Thanks,
Harry

Line 284

Hi,

Thanks for your code. I have one question about the reason why we need to caculate 'z' caculated in line 284: z = torch.randn(n_sample, *size).to(device) if i > 1 else 0.

About performance improvement

Hello, thank you for your excellent work!
I am a green hand in diffusion model.
If I want to further improve the performance of model, what parameters and network structure do I need to modify? Do you have any suggestions? Thank you!

minimal evaluation

Hi
Thanks for this code.
What you suggest for evaluating this conditional generation?
E.g. what is the easiest code change to get a meaningful evaluation with some metrics (e.g. what about FID)
Any suggestion on which metric could be suitable here

Best regards

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.