Skip to content

xiaobin-xs/EEG-competing-risks

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

42 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Neurological Prognostication of Post-Cardiac-Arrest Coma Patients Using EEG Data: A Dynamic Survival Analysis Framework with Competing Risks

This repository contains the demonstration code for the manuscript arXiv (this arXiv version includes minor corrections over the original MLHC draft):

Xiaobin Shen, Jonathan Elmer, and George H. Chen. "Neurological Prognostication of Post-Cardiac-Arrest Coma Patients Using EEG Data: A Dynamic Survival Analysis Framework with Competing Risks." Machine Learning for Healthcare Conference. PMLR, 2023.

Note that the dynamic survival analysis framework we propose is compatible with any dynamic competing risks (DCR) models, and we include the code to train and evaluate three DCR models discussed in the paper. See code under the directory of examples/ of how to train and evaluate the model, and generate the visualizations displayed in the paper. Specifically, DDH-Torch-cr3.ipynb and eval-ddh.ipynb would be the most relevant ones.

We use Python 3.9.7 to test our code.

Data Prep

To see how we prepare the competing risks dataset from raw data, please see prepare-competing-risks-data.ipynb

Some DCR Models

  • Fine and Gray competing risks model, 1999.
  • Dynamic-DeepHit, 2019
    • Original implementation by the authors in Tensorflow
    • PyTorch implementation available here. This repo has an open issue by the code author saying "Does not match original paper's performances" and it's also listed as a TODO to "Further testing to ensure the model is reproducing the original paper's performance".
    • Our implementation combines the two versions, see files under the directory scr/. Specifically, we use the model structure code from the PyTorch implementation, while for data preparation, loss function, and training procedure, we refer back to the Tensorflow implementation by the original paper authors.
    • To see how to train and evaluate the model with single event, two competing risks, and three competing risks, please refer to DDH-Torch-cr1.ipynb, DDH-Torch-cr2.ipynb, DDH-Torch-cr3.ipynb, respectively
    • To get the visualization in the manuscript, see eval-ddh.ipynb
  • dynamic deep recurrent survival analysis (DDRSA), 2022
    • No implementation by the original author; see ddrsa.py for our implementation of the model architecture with some modifications
    • To see how to train and evaluate the model with three competing risks, please refer to ddrsa-cr3.ipynb and eval-ddrsa.ipynb

To-Do:

  • add sample/synthetic data

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published