Code Monkey home page Code Monkey logo

sagan's Introduction

SAGAN

This repo provides the trained denoising model and testing code for low dose CT denoising as described in our paper. Here are some randomly picked denoised results on low dose CTs from this kaggle challenge.

How to use

To better use this repo, please make sure the dose level of the LDCTs are larger than 0.71 mSv.

Prerequistites

  • Linux or OSX
  • NVIDIA GPU

Getting Started

  • Install torch7
  • Install torch packages nngraph and hdf5
luarocks install nngraph
luarocks install hdf5
  • Clone this repo:
git clone [email protected]:xinario/SAGAN.git
cd SAGAN
  • Download the pretrained denoising model from here and put it into the "checkpoints/SAGAN" folder

  • Prepare your test set with the provided python script

#make a directory inside the root SAGAN folder to store your raw dicoms, e.g. ./dicoms
mkdir dicoms
#then put all your low dose CT images of dicom format into this folder and run
python pre_process.py -s 1 -i ./dicoms -o ./datasets/experiment/test
#all your test images would now be saved as uint16 png format inside folder ./datasets/experiment/test. Arguement `-s 1` is to ensure the output images are stored in sequence.
#note: in order to use the python script, make sure you have the follwing packages installed
#opencv, pydicom, numpy, h5py
  • Test the model:
DATA_ROOT=./datasets/experiment name=SAGAN which_direction=AtoB phase=test th test.lua
#the results are saved in result/SAGAN/latest_net_G_test/result.h5
  • Display the result with a specific window, e.g. abdomen. Window type can be changed to 'abdomen', 'bone' or 'none'
python post_process.py -w 'lung'

Now you can view the result by open the html file:result/SAGAN/latest_net_G_test/index.html

Citations

If you find it useful and are using the code/model provoided here in a publication, please cite our paper:

@article{yi2017sharpness,
  title={Sharpness-aware Low dose CT denoising using conditional generative adversarial network},
  author={Yi, Xin and Babyn, Paul},
  journal={arXiv preprint arXiv:1708.06453},
  year={2017}
}

Acknowlegements

Code borrows heavily from pix2pix

sagan's People

Contributors

xinario avatar

Watchers

James Cloos avatar paper2code - bot 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.