## 2 Materials and Methods
### Model Architecture  
The implemented HAR model architecture is shown in Figure 2 and represents a modified version of the DNN proposed by [PERSON] et al. (2012). The main difference with the previous model consists of the substitution of the Long Short Time Memory layer with a convolutional layer: this change in architecture was introduced to simplify the model and it did not generate results significantly different from the previous DNN. The model input consists of the X-, Y-, and Z- acceleration segments of shape _(number of segments, 96, 3)_. The model includes four 1D convolutional layers interspersed with four batch normalization layers. Moreover, two max-pooling and dropout layers were added to reduce overfitting risks. After the fourth batch normalization layer, a flattening layer was added to reshape the data and to provide input for the final dense layer that computes the prediction probabilities of five classes, by means of a softmax activation function ([PERSON] et al., 2015).  
The model uses categorical cross entropy as loss function, and the 'Adam' optimizer ([PERSON] et al., 2015), considering a batch size of 100 samples. The 'Balanced Batch Generator' function was used to fit the model: it is a Keras ([PERSON], 2016) function that allows creating balanced batches during model training by specifying the desired sampler, where in this case a random sampler was applied.  
\begin{table}
\begin{tabular}{c c c c} \hline \hline
**Activity** & **Duration** & **Activity** & **Duration** \\ \hline Jump 3x (sync) ** & Self-paced & & \\ Lying in bed ** & 3 min & Physioterapy on chair ** & 2 min \\ Left side ** & 30 s & Patient transport in & 1 min \\ Right side ** & 30 s & Wheelchair self-push & Self-paced \\ Reclined ** & 30 s & Crutches ** & Self-paced \\ Upright ** & 30 s & Anterior walker ** & Self-paced \\ Sitting edge of the bed ** & 30 s & IV pole ** & Self-paced \\ Standing ** & 30 s & 4-wheel rollator ** & Self-paced \\
0.6 km/h ** & 2 min & Walk slow * & Self-paced \\
0.8 km/h ** & 2 min & Walk normal * & Self-paced \\
1.0 km/h ** & 2 min & Walk fast * & Self-paced \\
1.5 km/h ** & 2 min & Intermittent walking * & Self-paced \\
2.0 km/h ** & 2 min & Shuffling * & Self-paced \\
3.0 km/h ** & 2 min & Upstairs one leg first ** & Self-paced \\
4.0 km/h ** & 2 min & Downstairs one leg first ** & Self-paced \\
4.0 km/h inclined * & 2 min & Stairs ascent ** & Self-paced \\ Washing hands ** & 1 min & Stairs descent ** & Self-paced \\ Reading ** & 1 min & Jump 3x (sync) ** & Self-paced \\ \hline \hline \end{tabular}  
*: Activities performed only in the Wearing Position Study (WPS); **: Activities performed in the Wearing Position Study and in the Simulated Hospital Study (SHS).  
\end{table}
Table 2: Wearing Position Study and Simulated Hospital Study activities reported in chronological order.  
Figure 1: Patient monitoring device placement in the front (**a**) and side (**b**) positions ([PERSON] et al., 2015; [PERSON] et al., 2015). (**c**) The sensor settings for the Wearing Position Study data collection. Yellow squares are GENEActive sensors: two in contact with the skin, two pending from the neck and one in the clinical gown pocket.