# LIMUNet: A Lightweight Neural Network for Human Activity Recognition Using Smartwatches
## 4 Experiment and Evaluation
### Parameter Evaluation  
**Size of the sliding window:** In LIMUNet, we input a tensor of size \(L\times 9\), where \(L\) is the size of the sliding window used when preparing the training data. Human activities generally have a frequency of 1-15 Hz, and many studies suggest selecting a larger window size to encompass as many cycles of behavior as possible within a window, thereby facilitating feature extraction by the neural network. Although adopting a larger size is a prudent choice, it increases the complexity of the network, raising the computational and time costs for model training and inference, which conflicts with the lightweight intention of this paper. Due to the high cost of collecting labeled data from users wearing smartwatches, a value that is too large can lead to a reduction in the available data. Here, the same experimental setup as in Section 4.2.2 is adopted to test the impact of different values on recognition accuracy, with results shown in Figure 10a. In addition, Figure 10b illustrates the changes in FLOPS under different values, which to some extent reflects the impact  
\begin{table}
\begin{tabular}{c c c c c} \hline \hline \multirow{2}{*}{**Model**} & \multicolumn{3}{c}{**Accuracy**} & \multirow{2}{*}{**Parameter Count**} & \multirow{2}{*}{**FLOPS**} \\ \cline{2-2} \cline{4-5}  & **PAMAP2** & & & \\ \hline CNN & 0.923 & 0.949 & 5.96 M & 320 M \\ DWCNN [34] & 0.913 & 0.963 & 4.57 M & 213 M \\ ResNet [33] & 0.906 & 0.892 & 6.66 M & 373 M \\ SqueezeNet [48] & 0.930 & 0.956 & 1.37 M & 245 M \\ GTSNet [38] & 0.891 & 0.849 & 0.10 M & 45 M \\ Channel Atte & 0.930 & 0.943 & 0.16 M & 102 M \\ Sensor Atte & 0.943 & 0.959 & 0.14 M & 102 M \\ LIMUNet & **0.959** & **0.977** & 0.16 M & 102 M \\ LIMUNet-Tiny & 0.937 & 0.945 & **0.04 M** & **19 M** \\ \hline \hline \end{tabular}
\end{table}
Table 3: Recognition accuracy and lightweight degree of different deep learning algorithms.  
of window size on the degree of lightweighting. According to the experimental results, the increase in the size of the sliding window initially brings a significant improvement in accuracy, but after 171, the improvement effect is not obvious. Therefore, this paper chooses 171 as the sliding window size during data segmentation.  
**LIMUNet number of lightweight modules**: The LIMUNet lightweight modules serve as the main components of the network, significantly impacting both the feature extraction capability and the degree of lightweight design. If the number of modules is small, the feature extraction capability may weaken; however, a larger number may lead to redundancy in parameters and computation, negatively affecting the degree of lightweight design. To verify the impact of the number of lightweight module layers on accuracy, parameter count, and computational complexity, this paper designs three different networks, where the stacking layers of the LIMUNet modules are 1, 2, and 3 layers, and the channel expansion factors of the residual bottleneck layers are 8, 32, and 128, respectively. Figure 11 shows the relationship between model recognition accuracy and the degree of lightweight design with the number of LIMUNet modules. It can be observed that, at this time, both the degree of lightweight design and the effectiveness of activity recognition can be balanced.  
Figure 11: LIMUNet (N = 2), LIMUNet-Tiny (N = 1), and LIMUNet-More (N = 3) the accuracy and degree of lightweight design.  
Figure 10: The impact of window size. (**a**) The impact of window size on accuracy in the PAMAPL2 and LIMU datasets. (**b**) The impact of window size \(L\) on FLOPS for the LIMU datasets.