## 3 Experiments and Results
### Experiments
Once the model was trained, it was applied to the 25 testing EMGs for each gesture to be recognized, including the five testing EMGs of the hand relaxed, using a 66-point window, with a stride of 66 points. In this way, for each testing EMG, we obtained two vectors: a vector \(\hat{\mathbf{i}}=(\hat{l}_{1},...\hat{l}_{p})\), containing the labels predicted by the model, and a vector \(\hat{\mathbf{t}}=(\hat{l}_{1},...\hat{l}_{p})\) containing the instants of time to which these labels correspond. For evaluating the recognition accuracy, we used two sets: \(A\) and \(B\). The set \(A=\{(\hat{y}_{i},t_{i})\}_{i=1}^{k}\) is formed by the ordered pairs \((\hat{y}_{i},t_{i})\), which are obtained from the vectors \(\hat{\mathbf{i}}\) and \(\hat{\mathbf{t}}\), where \(k\) denotes the number of time points of the EMG, with \(k=1000\) for this work. For example, given the predicted vectors of labels and times \(\hat{\mathbf{i}}=(1,3,3,3,2,1,1)\) and \(\hat{\mathbf{t}}=(10,20,30,40,50,60,70)\) \begin{table}
\begin{tabular}{c c c c c} \hline \hline \multirow{2}{*}{**Experiment**} & \multicolumn{2}{c}{**Rotation of the Bracelet**} & \multicolumn{2}{c}{**Correction of Orientation**} \\ \cline{2-5}  & **Training** & **Testing** & **Training** & **Testing** \\ \hline
1 & no & no & no & no \\ \hline
2 & no & yes & no & no \\ \hline
3 & no & yes & yes & yes \\ \hline
4 & yes & yes & yes & yes \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Settings of each experiment executed in this work. respectively, the first 10 pairs of the set \(A\) will be \((1,1),(1,2),(1,3),...,(1,10)\), the next 10 pairs will be \((3,11),(3,12),(3,13),...,(3,20)\), and so on. The set \(B=\{(y_{i},t_{i})\}_{i=1}^{k}\) is the ground truth for the recognition, where the pair \((y_{i},t_{i})\) contains the actual label \(y_{i}\) for the time \(t_{i}\) of the EMG, with \(i=1,2,...,k\). The values of \(y_{i}\) and \(t_{i}\) were obtained from the manual segmentation of the EMGs. A recognition was considered successful if each of the following three conditions are met: (a) all the labels of the ordered pairs in the set \(A^{*}\) must be equal to each other, where the set \(A^{*}\) is obtained from the set \(A\) by excluding from \(A\) all the ordered pairs that contain the label _no gesture_. (b) All the ordered pairs in the set \(A^{*}\) must be connected, which means that for at least one permutation of the times of the pairs in \(A^{*}\), the absolute value of the difference between adjacent times in that permutation must be exactly equal to 1; and (c) the overlapping factor computed using the following equation must be equal to or greater than a given threshold \(\rho\):  
\[\rho=2\times\frac{|A^{*}\cap B^{*}|}{|A^{*}|+|B^{*}|} \tag{1}\]  
where the set \(B^{*}\) is obtained from the set \(B\) by excluding from \(B\) all the pairs that contain the label _no gesture_. For this work, we used a threshold \(\rho=0.25\). It is important to note that, for evaluating the recognition, we only processed the 25 testing EMGs of each of the five gestures of interest, thus excluding the class _no gesture_. An illustration of the calculation of value \(\rho\) through overlapping among ground-truth and the vector of predictions can be observed in Figure 7. At this point, it is worth emphasizing that classification and recognition are different concepts. Classification compares a predicted label with a ground true label of a given EMG sample, which allows for identifying the corresponding hand gesture class for such sample. On the other hand, recognition involves not only inferring the label of a given sample, but also requires calculating the instants of time where the gesture was performed. For this purpose, it is required to compare the vector of points related to the ground truth with the corresponding vector of predictions for a given EMG sample by using the overlapping factor \(\rho\). Figure 7: Representation of calculation process by using the overlapping factor among the ground truth and the vector of predictions.