# Time-series classification of Kinect data using Keras

For my PhD project I recorded using Kinect and Myo 11 people performing Cardiopulmonary Resuscitation (CPR), repeatedly doing chest compressions to a manikin (one person per time). I collected in total around 5000 chest compressions.

The dataset includes 53 time series such as ElbowRightX, ShoulderLeftZ etc. Each body jointure for Kinect is a 3D vector.

All the 5000 chest compressions are labelled according the CompressionRate with 0 - too slow, 1 - correct, 2 - too fast.

Since I know via the manikin precisely when the compression starts and ends, my approach is to mask the time series and consider the time-intervals as a sample (each of them resampled in 11 bins).

This visualization shows an example https://i.imgur.com/IVNsNXr.png, in yellow the chest compressions as time-interval in which a compression start and ends.

So I ended up with a tensor of shape (5254, 11, 53) And corresponding 1D output vector of labels of size 5254. I tried LSTM as follows and got around .80% accuracy with 2/3 training and 1/3 test.

model = keras.Sequential([
keras.layers.LSTM(128, input_shape=(11, 53)),
keras.layers.Dense(3, activation='softmax')
])


QUESTION: Is the masking/windowing of the original time series a good approach and is LSTM the most appropriate model for parallel Multivariate Time Series classification? Or do you think I should try Convolution?