240 likes | 491 Views
Chau Nguyen. Neural Network-based Sleep Wake Classification. Project has a dual objective. The development of an infrastructure for heart monitoring And the use of this infrastructure for sleep-wake classification. An infrastructure for heart monitoring.
E N D
Chau Nguyen Neural Network-based Sleep Wake Classification
Project has a dual objective • The development of an infrastructure for heart monitoring • And the use of this infrastructure for sleep-wake classification
An infrastructure for heart monitoring • integrate the Alive heart monitor with the BScope, a Django-based web portal which allows authorized medical specialists to manage and view the patient’s datasources securely in real-time over the internet. • programmed with Python and ChartDirector
PC/Blackberry records sensors data in .ATS .EDF -> text-> MySQL server BScope Portal Alive Heart Monitor An infrastructure for heart monitoring • Data Flow
Sleep Monitoring-Motivation • Sleep-Wake identification • Why sleep monitoring? Deteriorating sleep-wake circadian cycle has been linked to onsets of heart disease • Why ECG? Non-invasive and easier to obtain as compared to Polysomnography which has traditionally been used in sleep study research. More accurate than actigraph.
ECG – Existing Approaches • the power spectrum of the ECG or the spectrum of HRV (heart rate variability) • Characteristic spectrum different for sleep and wake. • limitations: intensive data rate and computing power is required. The ECG signals need to be quite accurate for the spectrum to be meaningful
My approach • Approach: just the heart rate in conjunction with the body acceleration data • Heart rate has been known to drop around 20% during sleep and can be accurately obtained from either a poor ECG signal or with a simple LED-based oximeter attached to the finger. • The body acceleration data is easily obtainable from MEMS-based accelerometers, an ideal candidate for inclusion in a wearable system.
Artificial Neural Network • an information processing paradigm that is inspired by the way biological nervous systems, such as the brain, process information • detect trends that are too complex to be noticed by either humans or other computer techniques • Adaptive learning; • Real Time Operation; • nonlinear class separation; • efficiently implementable on a microcontroller or special hardware
Artificial Neural Network-Detailed Background • First, it computes the total weighted input xj, using the formula: • where yi is the activity level of the jth unit in the previous layer and Wij is the weight of the connection between the ith and the jth unit.
Artificial Neural Network-Detailed Background • Next, the unit calculates the activity yj using some function of the total weighted input. Typically we use the sigmoid function:
Artificial Neural Network-Detailed Background-Back Propagation Alg. • Once the activities of all output units have been determined, the network computes the error E, which is defined by the expression: • where yj is the activity level of the jth unit in the top layer and dj is the desired output of the jth unit.
Artificial Neural Network-Detailed Background-Back Propagation Alg. • 1. Compute how fast the error changes as the activity of an output unit is changed. • 2. Compute how fast the error changes as the total input received by an output unit is changed. • 3. Compute how fast the error changes as a weight on the connection into an output unit is changed. • 4. Compute how fast the error changes as the activity of a unit in the previous layer is changed. • 5. Use this information to assign blame and adjust weights
Artificial Neural Network: Sleep-wake Classification • Implemented in Python a standard back-propagation feed-forward fully-connected artificial neural network with 1 hidden layer, 12 input neurons and 1 output neuron • The data for the past 6 minutes is divided into 6 periods of 60 seconds. The instantaneous heart rate and the magnitude of the acceleration are averaged out for each of these 60 second intervals, giving 12 inputs to be fed to the neural network.
Train using 24hours of data Desire output: 1 for wake and 0 for sleep
Discussion • my network appears to have classified the wake periods better than the sleep periods • because there are periods during sleep called REM (rapid eye movement sleep) that are characterized by the rapid movement of the eyes and the elevated heart rate, making the data similar to a wake period • REM sleep accounts for the spikes in the output of the neural net just after the subject falls asleep and just before he wakes up. • However, for the purpose of determining the circadian sleep-wake cycle, these inaccuracies can be ignored. The output of the neural network obtained can reliably be used to classify the 24 hours data into broad categories of night sleep and wake based on the wake state alone.
Posture information • three separate components of the acceleration which contain information about the body posture have been ignored because these typically depend on how the sensor is worn on the body • the sensor is worn such that the y-axis in the sensor reference frame points along the body from head to toe. Thus if the person is standing up, the y-component of the acceleration is large and if the person is lying down, the y-component of the acceleration is close to zero.
Future Work • Extend the results to predicting onsets of heart disease • investigate the accuracy of the neural network acting on cross-individual data • The effects of different neural network architectures on the accuracy of the classification • Different classifier schemes • Investigate effects of long term changes such as change in fitness level on the prediction accuracy • Train the neural net using longer periods of data (several months)