MiniDiffuser

A basic diffusion model based on IADB

MiniDiffuser

MiniDiffuser is a mini diffusion model based on IADB (See paper, blog post and, 2D tutorial).

Quick start

If you want to setup a new conda environment, download a dataset (celeba) and launch a training, you can follow this:

conda env create -f environment.yml
conda activate minid
python3 minid.py

Replace python3 minid.py with python3 minid.py --e 10 for a quicker training process (this set epoch size to 10 instead the default 100).

Exit

Press crt+c to exit training.

To exit your environment run:

conda deactivate

Help

To see all features flags use:

python3 minid.py -h

Mini Diffuser currently support celeba and cifar10 (default) as dataset, modify minid.py to add yours.

Update you environment

To update your environment run:

conda env update -f environment.yml

Cuda

By default, our environment configuration for PyTorch supports Cuda version 12.1. Run nvidia-smi to see your Cuda version. And consult the officical PyTorch website for optimize version. And configure environment.yml or install dependencies manually.

Setup

Python 3 dependencies:

This code has been tested with Python 3.8 on Ubuntu 22.04. We recommend setting up a dedicated Conda environment using Python 3.8 and Pytorch 2.0.1.

Code description

The iadb.py contains a simple training loop.

It demonstrates how to train a new MiniDiffuser model and how to generate results.

Name Commit Messages