Giter VIP home page Giter VIP logo

sepsis-detection's Introduction

sepsis-detection

This repository is initially developed for a group project from a Gatech OMSCS class. The version delivered during the class is tagged as v0.1.

The implementation pipeline is summarized in the following figure.

Data

In order to access MIMIC-III database on Google Cloud, please follow the instructions in https://physionet.org/content/mimiciii/1.4/.

Run sql and python code in following orders to recreate the csv files used in modeling.

Cohort.sql
hourly_cohort.sql
static-query.sql
match-control.py
extract-48h-of-hourly-case-lab-series.sql
extract-48h-of-hourly-case-vital-series.sql
extract-48h-of-hourly-control-lab-series.sql
extract-48h-of-hourly-control-vital-series.sql
data_prep_step1.py

All sql codes can be run on GCP BigQuery console by changing project and data names to your own location accordingly. Alternatively, one can run the first three queries with get_cohort.sh on cloud shell with project id as the lone argument. Similarly, the other four sequence queries can be run with extract_sequence.sh.

The two python files can be run as follows assuming you are in the top level folder

python Python/match-control.py -c <bigquery credential json filename> -t <bigquery table reference>
python Python/data_prep_step1.py -c <bigquery credential json filename> -t <bigquery table reference> -w <prediction window hours(default is 3)>

and an example would be

python Python/match-control.py -c bdfh.json -t cdcproject.BDFH
python Python/data_prep_step1.py -c bdfh.json -t cdcproject.BDFH -w 3

The data will be saved in the Data folder.

Note: while we tried to set the random seed whenever possible for reproducibility, there still might be some factors we overlooked which might cause differences in model input data.

Models

Final model data processing is done in Python/model_data.py.

  • Logistic regression: trained and evaluated in LR.ipynb
  • SVM: trained and evaluated in SVM_Model.ipynb
  • LightGBM: trained and evaluated in Lightgbm_Model.ipynb
  • RNN: trained using python Python/rnn_main.py, evaluated in RNN_evaluation.ipynb

Results

Resource

sepsis-detection's People

Contributors

acmilannesta avatar am071092 avatar csabatini avatar kewellcjj avatar

Watchers

 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.