Abstract
Human Activity Recognition (HAR) is an important research topic that aims to monitor and analyse human movements using sensor or visual data. Despite tremendous advances, HAR continues to encounter challenges in obtaining high accuracy and computing efficiency, especially in cross-domain settings. This work introduces a new Hybrid Multi-Layer Perceptron (MLP) model with a selective stacked ensemble classifier that combines Random Forest (RF), Extreme Gradient Boosting (XGBoost), and Logistic Regression. Smartphone accelerometer and gyroscope data are fused, processed via the MLP for discriminative feature extraction, and then sent to RF and XGBoost, whose outputs are concatenated and fed into LR for final classification. On the source HAR dataset, the proposed approach achieves up to 99% accuracy, outperforming conventional models such as K-Nearest Neighbours (KNN), Decision Trees (DT), standalone MLP, and Convolutional Neural Networks (CNN). To assess cross-dataset generalisation, the model trained on the HAR dataset was evaluated on the PAMAP2 dataset without retraining, and it outperformed the CNN baseline by 2% in both accuracy and F1-score. Furthermore, it achieved competitive performance to the CrossHAR method-within 0.8% F1-score-despite avoiding computationally intensive hierarchical self-supervised pretraining. These results demonstrate that the proposed method delivers high accuracy, strong cross-domain adaptability, and efficient inference, making it suitable for real-world IoT-based activity recognition systems.