# Human Activity Recognition by the Image Type Encoding Method of 3-Axial Sensor Data
## 3 Image Type Encoding Method of the 3-Axial Sensor Data
### Walking-Activity-Based Data Argumentation  
Among the 18 activities of the WISDM dataset, the \"Walking\" activity in the given time unit was the easiest to analyze. \"Walking\" is among the most common human activities, and a healthy person can normally walk 4.5 km/h, and approximately 8 km can be covered in 10,000 steps [26; 27; 28; 29; 30]. This shows that about 800 ms is required for a movement of 1 m. In addition, it can be inferred that about 6,400,000 ms (=1 h 46 m 40 s) is required for an 8 km walk, which amounts to 10,000 steps. The time required for one step, denoted as \(T_{w}\), corresponds to about 640 ms of time. Therefore, this study sets the data segment size (\(DSS\)) as shown in Equation (1) for the raw sensor data of the WISDM generated at 50 ms intervals based on \(T_{w}\), which equals one human step.  
\[DSS=\frac{T_{w}}{T_{R}}+\textit{bias} \tag{1}\]  
where, \(T_{w}\): one step time; \(T_{R}\): sampling time of the WISDM dataset.  
In Equation (1), \(T_{R}=50\) ms indicates the interval of data collection of the WISDM dataset, and \(T_{w}=640\) ms indicates the time consumed per step taken. The \(DSS\) was set to 15 with a bias value of 2.2. One input pattern for neural network training corresponds to 15 raw sensor data points, and the raw WISDM dataset segments the data repetitively by moving by one each. Ultimately, 910 physical activity data points were increased to 2,896,476 as a result of using the data segmentation method proposed in this study. These data were divided into training data and test data in a ratio of 8:2 (2,317,180 data points in the training set and 579,296 in the test set).  
\begin{table}
\begin{tabular}{c c c c c c c} \hline \hline \multirow{2}{*}{**Label**} & \multirow{2}{*}{**Activity**} & \multicolumn{2}{c}{**No. of Columns**} & \multicolumn{2}{c}{**No. of Merged**} & \multirow{2}{*}{**No. of Data**} & \multirow{2}{*}{**Grouping Type**} \\  & & **Accel** & & & & \\ \hline
0 & Walking & 279,817 & 203,919 & 152,114 & 51 & A \\
1 & Jogging & 268,409 & 200,252 & 154,020 & 49 & A \\
2 & Stairs & 255,645 & 197,857 & 160,430 & 50 & A \\
3 & Sitting & 264,592 & 202,370 & 180,315 & 51 & A \\
4 & Standing & 269,604 & 202,351 & 165,068 & 51 & A \\
5 & Typing & 246,356 & 194,540 & 166,646 & 49 & B \\
6 & Brushing teeth & 269,609 & 202,622 & 168,771 & 51 & B \\
7 & Eating soup & 270,756 & 202,408 & 164,177 & 51 & C \\
8 & Eating chips & 261,360 & 197,905 & 160,237 & 50 & C \\
9 & Eating pasta & 249,793 & 197,844 & 170,598 & 50 & C \\
10 & Drinking & 285,190 & 202,395 & 149,138 & 51 & C \\
11 & Eating & 265,781 & 197,915 & 164,635 & 51 & C \\  & sandwich & & & & & \\
12 & Kicking & 278,766 & 202,625 & 150,651 & 51 & A \\
13 & Catching & 272,219 & 198,756 & 146,675 & 50 & B \\
14 & Dribbling & 272,730 & 202,331 & 150,333 & 51 & B \\
15 & Writing & 260,497 & 197,894 & 175,638 & 51 & B \\
16 & Clapping & 268,065 & 202,330 & 165,304 & 51 & B \\
17 & Folding clothes & 265,214 & 202,321 & 164,006 & 51 & B \\ \hline \hline \end{tabular}
\end{table}
Table 1: Smartphone acceleration and gyroscope data from the WISDM database.