Skip to content

About

Event-based Diffusion Modeling for Image Reconstruction

Resources

Stars

0 stars

Watchers

1 watching

Forks

Latest commit

 

History

33 Commits

Folders and files

Repository files navigation


Event-based Diffusion Modeling for Image Reconstruction.

Memoria para optar al título de Ingeniero Civil Industrial.

Getting Started

These instructions will give you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

Before you can run this project, ensure that you have the following installed:

  • Anaconda or Miniconda: Download and install either Anaconda or Miniconda, which provides the conda package and environment management system.

Setting Up the Environment

Once Conda is installed, you can set up the environment for this project by following these steps:

  1. Clone the repository:
    git clone https://github.com/uoh-rislab/fv_event-based_diffusion_modeling_image_reconstruction.git
    
  2. Create the Conda environment from the environment.yml file:
    conda env create -f environment.yml
    
  3. Activate the newly created environment:
    conda activate EVDiff
    
  4. Verify that the environment is activated and the dependencies are installed:
    conda list
    

Training Base U-Net

The following code provides the training for the base Unet Model needed to get the weights given unconditional image inputs.

  1. Go to MNIST_Model folder:
    cd your_route/MNIST_Model
    
  2. Run Train file:
    python3 Train.py --config 'your_route/default.yaml'
    

You must remember to configure the yaml file.

Training Conditional U-Net

The following code provides the training for the Conditional Unet Model needed to get the weights given unconditional image inputs.

  1. Go to MNIST_Model folder:
    cd your_route/MNIST_Model
    
  2. Run Conditional Train file:
    python3 Conditional_Train.py --config 'your_route/default.yaml'
    

You must remember to configure the yaml file.

Running the Base Unet Sampling

The following code provides the use for the sampling process.

  1. Go to MNIST_Model folder:
    cd your_route/MNIST_Model
    
  2. Run sample ddpm file:
    python3 sample_ddpm.py --config 'your_route/default.yaml'
    

You must remember to configure the yaml file.

Running the Conditional Unet Sampling

The following code provides the use for the sampling process with an event condition input.

  1. Go to MNIST_Model folder:
    cd your_route/MNIST_Model
    
  2. Run DualSample file:
    python3 DualSample.py --config 'your_route/default.yaml'
    

You must remember to configure the yaml file and save the .pth files in default folder.

Sample Tests

Authors

License

This project is licensed under the MIT License

Acknowledgments

About

Event-based Diffusion Modeling for Image Reconstruction

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages