Giter Club home page Giter Club logo

patchbased_3dcyclegan_ct_synthesis's Introduction

3D Cycle-GAN TensorFlow

Cycle-consistent generative adversarial network (Cycle-GAN) is an unsupervised approach for image synthesis. In medical imaging, it promises to provide a tool for intricate data augmentation. Although some clinical studies report that GANs may generate unrealistic features in some cases, they are still promising tools for image generation with high visual fidelity. This repository provides the code for 3D patch-based synthesis of medical images using Cycle-GAN.

Architecture

Contrast removal from CT

Usage

Create a virtual environment to install the prerequisites. If there are issues with tensorflow-gpu, cuda and cuDNN version mismatch, use Anaconda or conda-forge to install the requirements. The working versions of the Nvidia cuda driver, tensorflow-gpu, cudatoolkit and cudnn can be found here.

conda create -n tfgpu
conda activate tfgpu
conda install tensorflow-gpu -c conda-forge

The code benefits from Monai which is a Torch-based medical imaging library for custom preprocessing and caching of medical images. The preprocessing operations are performed in the dataloader.py file with specifications defned in the config.py file. The training specifications can be defined via the arguments defiend in the main.py file.

The expected directories are as follows:

|--directory
       |----train
              |----A
                   |----xxx.nii.gz, xxx.nii.gz, ...
              |----B
                   |----xxx.nii.gz, xxx.nii.gz, ...
       |----test
              |----A
                   |----xxx.nii.gz, xxx.nii.gz, ...
              |----B
                   |----xxx.nii.gz, xxx.nii.gz, ...

For using other image formats, make the desired changes in the dataloader.py file.

Train:

python main.py path/to/data/directory path/to/save/results

The inference code will be released soon.

patchbased_3dcyclegan_ct_synthesis's People

Contributors

rekalantar avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  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.