All Projects → brucechou1983 → Chexnet Keras

brucechou1983 / Chexnet Keras

Licence: mit
This project is a tool to build CheXNet-like models, written in Keras.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Chexnet Keras

Imagenet
Pytorch Imagenet Models Example + Transfer Learning (and fine-tuning)
Stars: ✭ 134 (-47.24%)
Mutual labels:  convolutional-neural-networks, densenet
Hyperdensenet
This repository contains the code of HyperDenseNet, a hyper-densely connected CNN to segment medical images in multi-modal image scenarios.
Stars: ✭ 124 (-51.18%)
Mutual labels:  convolutional-neural-networks, densenet
Cifar 10 Cnn
Play deep learning with CIFAR datasets
Stars: ✭ 756 (+197.64%)
Mutual labels:  convolutional-neural-networks, densenet
Chainer Cifar10
Various CNN models for CIFAR10 with Chainer
Stars: ✭ 134 (-47.24%)
Mutual labels:  convolutional-neural-networks, densenet
Mead Baseline
Deep-Learning Model Exploration and Development for NLP
Stars: ✭ 238 (-6.3%)
Mutual labels:  convolutional-neural-networks
Xsum
Topic-Aware Convolutional Neural Networks for Extreme Summarization
Stars: ✭ 221 (-12.99%)
Mutual labels:  convolutional-neural-networks
Deep Alignment Network A Convolutional Neural Network For Robust Face Alignment
This is a Tensorflow implementations of paper "Deep Alignment Network: A convolutional neural network for robust face alignment".
Stars: ✭ 219 (-13.78%)
Mutual labels:  convolutional-neural-networks
Grad cam plus plus
A generalized gradient-based CNN visualization technique
Stars: ✭ 216 (-14.96%)
Mutual labels:  convolutional-neural-networks
Stanford Cs231
Resources for students in the Udacity's Machine Learning Engineer Nanodegree to work through Stanford's Convolutional Neural Networks for Visual Recognition course (CS231n).
Stars: ✭ 249 (-1.97%)
Mutual labels:  convolutional-neural-networks
Panotti
A multi-channel neural network audio classifier using Keras
Stars: ✭ 244 (-3.94%)
Mutual labels:  convolutional-neural-networks
Cnn Text Classification Tf Chinese
CNN for Chinese Text Classification in Tensorflow
Stars: ✭ 237 (-6.69%)
Mutual labels:  convolutional-neural-networks
Master Thesis Bayesiancnn
Master Thesis on Bayesian Convolutional Neural Network using Variational Inference
Stars: ✭ 222 (-12.6%)
Mutual labels:  convolutional-neural-networks
Deeppicar
Deep Learning Autonomous Car based on Raspberry Pi, SunFounder PiCar-V Kit, TensorFlow, and Google's EdgeTPU Co-Processor
Stars: ✭ 242 (-4.72%)
Mutual labels:  convolutional-neural-networks
Retrieval 2017 Cam
Class-Weighted Convolutional Features for Image Retrieval (BMVC 2017)
Stars: ✭ 219 (-13.78%)
Mutual labels:  convolutional-neural-networks
Deepreg
Medical image registration using deep learning
Stars: ✭ 245 (-3.54%)
Mutual labels:  convolutional-neural-networks
3dmmasstn
MatConvNet implementation for incorporating a 3D Morphable Model (3DMM) into a Spatial Transformer Network (STN)
Stars: ✭ 218 (-14.17%)
Mutual labels:  convolutional-neural-networks
Super Slomo
PyTorch implementation of Super SloMo by Jiang et al.
Stars: ✭ 2,714 (+968.5%)
Mutual labels:  convolutional-neural-networks
Torchfusion
A modern deep learning framework built to accelerate research and development of AI systems
Stars: ✭ 244 (-3.94%)
Mutual labels:  convolutional-neural-networks
Tensorflow 101
TensorFlow Tutorials
Stars: ✭ 2,565 (+909.84%)
Mutual labels:  convolutional-neural-networks
Pyconv
Pyramidal Convolution: Rethinking Convolutional Neural Networks for Visual Recognition (https://arxiv.org/pdf/2006.11538.pdf)
Stars: ✭ 231 (-9.06%)
Mutual labels:  convolutional-neural-networks

ChexNet-Keras

This project is a tool to build CheXNet-like models, written in Keras.

CAM example image

What is CheXNet?

ChexNet is a deep learning algorithm that can detect and localize 14 kinds of diseases from chest X-ray images. As described in the paper, a 121-layer densely connected convolutional neural network is trained on ChestX-ray14 dataset, which contains 112,120 frontal view X-ray images from 30,805 unique patients. The result is so good that it surpasses the performance of practicing radiologists. If you are new to this project, Luke Oakden-Rayner's post is highly recommended.

TODO

  1. CheXpert updates
  2. Upgrade repo to TF 2.0 (tf.keras)
  3. Sacred experiment management
  4. Better result visualization tool
  5. Model convertion/deployment tool

In this project, you can

  1. Train/test a baseline model by following the quickstart. You can get a model with performance close to the paper.
  2. Run class activation mapping to see the localization of your model.
  3. Modify multiply parameter in config.ini or design your own class weighting to see if you can get better performance.
  4. Modify weights.py to customize your weights in loss function. If you find something useful, feel free to make that an option and fire a PR.
  5. Every time you do a new experiment, make sure you modify output_dir in config.ini otherwise previous training results might be overwritten. For more options check the parameter description in config.ini.

Quickstart

Note that currently this project can only be executed in Linux and macOS. You might run into some issues in Windows.

  1. Download all tar files, Data_Entry_2017.csv and BBox_List_2017.csv of ChestX-ray14 dataset from NIH dropbox. Put them under ./data folder and untar all tar files.
  2. Create & source a new virtualenv. Python >= 3.6 is required.
  3. Install dependencies by running pip3 install -r requirements.txt.
  4. Copy sample_config.ini to config.ini, you may customize batch_size and training parameters here. Make sure config.ini is configured before you run training or testing
  5. Run python train.py to train a new model. If you want to run the training using multiple GPUs, just prepend CUDA_VISIBLE_DEVICES=0,1,... to restrict the GPU devices. nvidia-smi command will be helpful if you don't know which device are available.
  6. Run python test.py to evaluate your model on the test set.
  7. Run python cam.py to generate images with class activation mapping overlay and the ground bbox. The ground truth comes from the BBox_List_2017.csv file so make sure you have that file in ./data folder. CAM images will be placed under the output folder.

Trained model weights

Many people are asking for a trained model, there you go. I use this model to create the CAM example images. The testing mean auroc is about 82.9. Again, before you ask about comparing results with the original paper, think about how to do that in a meaningful way.

Important notice for CUDA 9 users

If you use >= CUDA 9, make sure you set tensorflow_gpu >= 1.5.

TODO

  1. Frontend

Acknowledgement

I would like to thank Pranav Rajpurkar (Stanford ML group) and Xinyu Weng (北京大學) for sharing their experiences on this task. Also I would like to thank Felix Yu for providing DenseNet-Keras source code.

Author

Bruce Chou ([email protected])

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].