Giter Site home page Giter Site logo

corazonlabs / lemonpie Goto Github PK

View Code? Open in Web Editor NEW
3.0 2.0 1.0 19.02 MB

A deep learning library for Electronic Health Record (EHR) data

Home Page: https://corazonlabs.github.io/lemonpie/

License: Apache License 2.0

Jupyter Notebook 97.00% Python 2.98% Makefile 0.01%
deep-learning fastai pytorch nbdev synthea fhir ehr health-data healthcare

lemonpie's Introduction

lemonpie

An open source deep learning library for Electronic Health Record (EHR) data.

In this initial release of the library ..

  • it implements 2 deep learning models (an LSTM and a CNN) based on popular papers
  • that can be trained on synthetic EHR data, created using the open source Synthea Patient Generator
  • to predict conditions that are on the CDC's list of top chronic diseases that contribute most to healthcare costs
    • and is easily configurable to train on and predict any conditions in the dataset

The end goal is to

  • keep adding more model implementations
  • keep adding different publicly available datasets
  • and have a leaderboard to track which models and configurations work best on these datasets

Install

With conda

  • conda install -c corazonlabs -c fastai -c conda-forge lemonpie

With pip

  • pip install lemonpie

Or ..

  1. Git clone the repo
    • https://github.com/corazonlabs/lemonpie.git
  2. Create a new conda env using the environment.yml file
    • cd lemonpie
    • conda env create --name lemonpie --file environment.yml

How to use

  1. Read through and then run the following Quick Start guides to get a general idea.
    • if using the cloned repo, run these noteboooks
      • 99_quick_walkthru.ipynb
      • 99_running_exps.ipynb
    • if using installed lib, just open a jupyter notebook and copy, paste & run cell-by-cell from these guides
  2. Setup Synthea
  3. Run experiments
    • Refer to Detailed Docs for customizations

Roadmap

  • A leader-board to track which models and configurations work best on different publicly available datasets.

  • Callbacks, Mixed Precision, etc

    • Either upgrade the library to use fastai v2.
    • Or as a minimum, build functionality for fastai-style callbacks & PyTorch AMP.
  • More models

    • Pick some of the best EHR models out there and implement them.
    • Ideas are welcome - please use Github discussions for suggestions.
  • More datasets

  • NLP on clinical notes

    • Synthea does not have clinical notes, so this can only be done with other datasets.
  • Predicting different conditions

    • Again different datasets will allow this - e.g. hospitalization data (length of stay, in-patient mortality), ER data, etc.
  • Integraion with Experiment management tools like W&B, Comet, etc,.

Known Issues & Limitations

  1. num_workers > 0 not working yet, under investigation
  2. Test coverage
    • Need to write more tests for more comprehensive coverage

Look at Issues for details about these and others.

References

This library is created using the awesome nbdev

Synthea Synthetic Patient Population Simulator

Jason Walonoski, Mark Kramer, Joseph Nichols, Andre Quina, Chris Moesel, Dylan Hall, Carlton Duffett, Kudakwashe Dube, Thomas Gallagher, Scott McLachlan, Synthea:An approach, method, and software mechanism for generating synthetic patients and the synthetic electronic health care record, Journal of the American Medical Informatics Association, Volume 25, Issue 3, March 2018, Pages 230โ€“238, https://doi.org/10.1093/jamia/ocx079

LSTM Model based on this paper - Scalable and accurate deep learning for electronic health records

Rajkomar, A., Oren, E., Chen, K. et al. Scalable and accurate deep learning with electronic health records. npj Digital Med 1, 18 (2018). https://doi.org/10.1038/s41746-018-0029-1

CNN Model based on this paper - Deepr: A Convolutional Net for Medical Records

Nguyen, P., Tran, T., Wickramasinghe, N., & Venkatesh, S. (2017). $\mathtt {Deepr}$:A Convolutional Net for Medical Records. IEEE Journal of Biomedical and Health Informatics, 21, 22-30.

lemonpie's People

Contributors

vin00d avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

vin00d

lemonpie's Issues

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.