Code Monkey home page Code Monkey logo

adadiff's Introduction

AdaDiff

Official PyTorch implementation of AdaDiff described in the paper.

Salman UH Dar, Şaban Öztürk, Yilmaz Korkmaz, Gokberk Elmas, Muzaffer Özbey, Alper Güngör, Tolga Çukur, "Adaptive Diffusion Priors for Accelerated MRI Reconstruction", arXiv 2022.

Dependencies

python>=3.6.9
torch>=1.7.1
torchvision>=0.8.2
cuda=>11.2
ninja
python3.x-dev (apt install, x should match your python3 version, ex: 3.8)

Installation

  • Clone this repo:
git clone https://github.com/icon-lab/AdaDiff
cd AdaDiff

Train


For Single-Coil

python3 train_adadiff_singlecoil.py --dataset brain --image_size 256 --exp experiment_name_for_singlecoil --num_channels 1 --num_channels_dae 64 --ch_mult 1 1 2 2 4 4 --num_timesteps 8 --num_res_blocks 2 --batch_size 2 --num_epoch 500 --ngf 64 --embedding_type positional --use_ema --ema_decay 0.999 --r1_gamma 1. --z_emb_dim 256 --lr_d 1e-4 --lr_g 1.6e-4 --lazy_reg 10 --num_process_per_node 1 --save_content --local_rank 0

Inference


For Single-Coil

python3 inference_adadiff_singlecoil.py --dataset brain --image_size 256 --exp content_folder_for_singlecoil --num_channels 1 --num_channels_dae 64 --ch_mult 1 1 2 2 4 4 --num_timesteps 8 --num_res_blocks 2 --epoch_id 1000 --batch_size 1 --lr_g 1e-3 --itr_inf 1000 --local_rank 0 --contrast T1 --phase test --save_inter True --R 4 --extra_string lr_1e3_opt_reset_ --reset_opt True


Citation

You are encouraged to modify/distribute this code. However, please acknowledge this code and cite the paper appropriately.

@article{dar2022adaptive,
  title={Adaptive Diffusion Priors for Accelerated MRI Reconstruction},
  author={Dar, Salman UH and {\"O}zt{\"u}rk, {\c{S}}aban and Korkmaz, Yilmaz and Elmas, Gokberk and {\"O}zbey, Muzaffer and G{\"u}ng{\"o}r, Alper and {\c{C}}ukur, Tolga},
  journal={arXiv preprint arXiv:2207.05876},
  year={2022}
}

(c) ICON Lab 2022


Acknowledgements

This code uses libraries from, pGAN, StyleGAN-2, and DD-GAN repositories.

adadiff's People

Contributors

jaylee2000 avatar sabanozturk avatar

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.