PainAttnNet Model Extended Version on Motion Detection based on Signals.
In this report, we adapt our previous work PainAttnNet model
The workflow is designed to handle multimodal data features such as timestamps, raw channel data, high-pass filtered channel data, quaternion, gyroscope, accelerometer data, body movement labels, and repetition numbers from Pison Wrist Motion Data (PWMD).
A crucial step in our preprocessing pipeline was the standardization of sample lengths across the dataset. This was achieved by either truncating or padding the data samples to achieve a uniform target length (we used truncating for the experiment). In our procedure, the length of each sample was truncated upon on the minimum sample length 967 in the first step. While we also noticed that there is a couple timestamps of inactivity at the begining of each motion, we also tested on the length of 900.
Next, we have implemented a strategy to segregate data based on body movement labels and repetition numbers. Each unique combination of body movement label and repetition number was treated as a separate subject, e.g. Standing 2 with repetition number 1 as one subject. In total we have 15 subjects from the original dataset. This approach lends itself to a more practical and realistic representation of the data. For instance, in a real-world scenario, a subject may perform different wrist motions with the different body movements. Therefore, the data should be treated as a collection of unique subjects, each with a distinct body movement label and repetition number. Whereas, we found out that the wrist motion classes are based on the repetition numbers, e.g. 1, 2, 3, as three different wrist classes repeatedly performed during different body movement. During the training, the dataset was split into $k$-fold cross validation, where $k$ is 5, each fold has three samples, each one has a unique body movement label with one unique repetition number.
Please check out our previous work PainAttnNet model
In our experiment, we used the PWMD for modeling. This dataset consists of 17 columns provided in the dataset. 14 of them are features we used in our model for prediction of the repetition number (wrist motion), e.g. {1, 2, 3} among body movements. The results with different settings showed in above figure. We have the best performance with the following settings: 5 encoder layers, 5 attention heads, and minimum length 967. The performance is 100% accuracy, 100% macro F1, and 100% Cohen’s Kappa.
The wrist motion data is provided by Pison Technology.