Giter VIP home page Giter VIP logo

chexpert-keras's Introduction

CheXpert-Keras

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

What is CheXpert?

CheXpert is a large dataset of chest X-rays and competition for automated chest x-ray interpretation, which features uncertainty labels and radiologist-labeled reference standard evaluation sets.

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, train.csv and valid.csv of CheXpert dataset from Stanford Mirror. Put them under ./data/default_split 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.

Important notice for CUDA 9 users

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

Author

Bruce Chou ([email protected])

Editor

Ali Gholami ([email protected])

License

MIT

chexpert-keras's People

Contributors

neeland avatar

Watchers

 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.