Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 

Repository files navigation

Sleep Classification With Artificial Synthetic Imaging Data Using Convolutional Neural Networks

Data

Abstract

Data considered in this paper are collected with the Empatica E4 wristband during the Health Data Science class study conducted at the University of Michigan. In the study, 24 users aged 22-to-35 years old wore the E4 device on the wrist of their non-dominant hand for approximately 48 hours in January-March 2020. The device tracked 4 physiological modalities including heart rate (HR), acceleration (ACC), electrodermal activity (EDA), and skin temperature (TEMP) with sampling frequency as 1Hz, 32Hz, 4Hz, and 4Hz respectively.

Availability

Due to confidentiality reasons the data cannot be made publicly available. We make publicly available a simulated dataset that mimics the real data.

Simulated data

The simulated data “5min_permute.csv” is simulated by permuting 24 subjects’ 5-minute epoch Empatica E4 data (D-5min-HR) from 3 - 5AM. We permute the following variables: sex, age, first quartile, median, third quartile, standard deviation, and arithmetic mean of HR, ACC, and TEMP and median and categorical EDA. We do not permute the response variable (i.e., sleep labels of each subject). Note that we only permute values of these variables when subjects indicate they were asleep in the specified time range of 3-5AM. In this way the sleep labels of each subject remain unchanged. Demographic features (sex and age) in this dataset are simulated by randomly sampling subjects’ original values with replacement. Then “5min_permute_norm.csv” is generated by centering and standardizing the “5min_permute.csv” within individuals and across all subjects.

Code

This folder includes files and data necessary to run and reproduce the results of the paper. Note that the results are produced for simulated, non-proprietary data are saved in the sample_result folder, while the original results (selected) from our experiment are saved in the original_result folder. In general, we have included a collection of code and data files:

  • ./E4 ASID Example/reproducibility.R: general script to reproduce the results, it will source the following files
  • ./E4 ASID Example/functions.R: all functions needed for the experiment
  • ./E4 ASID Example/Train_ASID.R: ASID Workflow’s training process, sourcing following 3 files:
    1. ./E4 ASID Example/variable_order_rf.R: get the alignment of modalities and order for tunning
    1. ./E4 ASID Example/generate_config_table.R: generate 1-layer CNN configuration table
    1. ./E4 ASID Example/generate_config_table_layer2.R: generate 2-layer CNN configuration table
  • ./E4 ASID Example/Test_ASID.R: ASID Workflow’s testing process
  • ./E4 ASID Example/5min_permute.csv: simulated 5min data (D-5min-HR)
  • ./E4 ASID Example/5min_permute_norm.csv: normalized simulated 5min data
  • ./E4 ASID Example/sleep_tag.csv: the start/end time of sleep of each subject, collected from individuals’ self-reported sleep diaries (This data can be used for image plotting)

Codes for competing workflows are uploaded to the repository but not run in this example.

  • ./E4 ASID Example/Competing_workflow.R: Competing Workflow’s training and testing processes (except LSTM)

  • ./E4 ASID Example/LSTM.R: LSTM's training and testing processes.

  • ./README.md: README file containing instructions on how to run the code

To reproduce the results, run “reproducibility.R”.

STAY TUNED.

About

Sample Codes and Tables for Paper "Sleep Classification With Artificial Synthetic Imaging Data Using Convolutional Neural Networks"

Resources

Stars

0 stars

Watchers

3 watching

Forks

Releases

Packages

Contributors

Languages