## 4 Result
Figure 8c shows improved performance, particularly in identifying no-activity, sitting, and walking, but it still has issues with misclassifying lying instances. Figure 8d exhibits the best overall performance, with high accuracy in predicting falling, no-activity, sitting, and walking, though it still faces some challenges with lying instances. Overall, the HOG-LSTM-Attention model appears to be the most effective model for fall detection, providing the highest accuracy across most activities. Figure 8: \(Cont\). Table 2 shows the _Sensitivity_, _Precision_, _Accuracy_, and _F1-Score_ obtained from the confusion matrix of the four types of fall detection systems shown in Figure 8. The Raw-LSTM architecture demonstrates perfect _Sensitivity_, correctly identifying all instances of falls (100%). However, its _Precision_ is significantly lower at 50%, indicating that the model struggles to correctly identify ADLs, leading to a high rate of FPs. The overall _Accuracy_ of this model is also 50%, reflecting its balanced but mediocre performance, which is heavily influenced by the high number of false alarms. The _F1-Score_, which is the harmonic mean of _Precision_ and _Sensitivity_, stands at 66.7%, suggesting that while the model is excellent at detecting falls, it is less reliable in distinguishing between falls and ADLs. The Raw-LSTM-Attention architecture yields performance metrics equivalent to those of the Raw-LSTM model, indicating no significant improvement from the addition of the attention mechanism. The HOG-LSTM architecture shows a marked improvement in performance. Its _Sensitivity_ is slightly lower than the Raw-LSTM and Raw-LSTM-Attention models at 94.5%, but it still performs well in detecting falls. The _Precision_ is significantly higher at 88.9%, indicating that the model is much better at correctly identifying ADLs and reducing FPs. The overall _Accuracy_ of this model is 91.4%, demonstrating a balanced and reliable performance. The _F1-Score_ is 91.6%, reflecting the model's strong ability to detect falls while maintaining a  
Figure 8: Confusion matrix applying the four types of proposed fall detection systems. (**a**) Raw-LSTM, (**b**) Raw-LSTM-Attention, (**c**) HOG-LSTM, (**d**) HOG-LSTM-Attention. high level of _Precision_. The HOG-LSTM-Attention architecture exhibits the best overall performance among the four models. It achieves a high _Sensitivity_ of 98.2%, indicating that it is very effective at detecting falls. The _Precision_ is also high at 92.9%, showing that the model is proficient at correctly identifying ADLs and minimizing FPs. The overall _Accuracy_ of this model is 95.3%, reflecting its superior performance in both detecting falls and distinguishing between falls and ADLs. The _F1-Score_ is 95.5%, indicating a well-balanced and highly reliable model, benefiting from the attention mechanism's ability to focus on critical temporal cues. In summary, the Raw-LSTM and Raw-LSTM-Attention models excel in _Sensitivity_ but fall short in _Precision_ and _Accuracy_. The HOG-LSTM model offers a more balanced performance with high _Sensitivity_ and _Precision_. The HOG-LSTM-Attention model provides the best results across all metrics, making it the most effective architecture for fall detection by combining robust feature extraction with dynamic temporal focus. Table 3 presents various evaluation metrics for different ratios of the number of Attention heads (NumHeads) to the number of channels of keys and queries (NumKeyChannels) of self-attention mechanism in a HOG-LSTM-Attention model for the fall detection system. These metrics include _Accuracy_, _Sensitivity_, _Precision_, and _F1-Score_, each expressed as a percentage. The _Accuracy_ metric measures the overall correctness of the model's predictions. The highest _Accuracy_ is observed at the 2:64 ratio, with a value of 95.3%, indicating that this configuration provides the most accurate predictions.