Analysis of online and offline classification algorithms for human activity recognition using IMU sensors
Resumo
Physical activity monitoring through machine learning, using data collected from wearable devices equipped with motion sensors and vital signs monitoring, such as heart rate, temperature, and blood oxygenation, has gained significant attention in sports and medical fields. This advancement enables real-time performance tracking and early detection of motor conditions. While offline classifiers achieve high accuracy, they cannot adapt to novel motion patterns; online (incremental) learners overcome this limitation. Although there are online learning algorithms, their application to Human Activity Recognition (HAR) remains limited. The challenge for offline and online approaches is generalizing activity detection based on time-series segments, relying solely on sensor data without additional information. This study analyzes the performance of offline and online algorithms for HAR by applying segmentation and feature extraction techniques and evaluating the adaptability of incremental learning models over time. The research follows a quantitative and prescriptive approach, employing various classifiers to address the problem of HAR. The results highlight the performance of the offline Autogluon Predictor applied to the PAMAP2 dataset, which the five best algorithms nearly tied and achieved average scores of 94% accuracy, 93% F1-score, 94% precision, and 94% recall, followed by CIF with lower results. For online learning the algorithms XGBoost Incremental performed best with 78% accuracy, 77% f1-score, 81% precision and 78% recall. While Adaptive Random Forest and BiLSTM also nearly tied in the online setting, achieving lower results compared to XGBI, this study shows promising results for both scenarios. It highlights that determining the most suitable learning paradigm (online or offline) is a decision for the data scientist, guided by the particularities of the problem and the necessary dynamism required for the scenario. By exploring different learning approaches for HAR and evaluating their effectiveness, this research contributes to the development of more adaptive and personalized systems with applications in health monitoring, sports, and medical diagnostics, fostering advancements in continuous and adaptive user data analysis.
Palavras-chave:
machine learning, supervised learning, continual learning, automated machine learning, inertial sensors, HAR
Referências
Akiba, T., Sano, S., Yanase, T., Ohta, T., and Koyama, M. (2019). Optuna: A nextgeneration hyperparameter optimization framework. In Proceedings of the 25th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, KDD ’19, page 2623–2631, New York, NY, USA. Association for Computing Machinery.
Bukhari, A., Hosseinimotlagh, S., and Kim, H. (2024). Opensense: An open-world sensing framework for incremental learning and dynamic sensor scheduling on embedded edge devices. IEEE Internet of Things Journal, 11(15):25880–25894.
Erickson, N., Mueller, J., Shirkov, A., Zhang, H., Larroy, P., Li, M., and Smola, A. (2020). Autogluon-tabular.
Guo, S., Gu, Y., Wen, S., Ma, Y., Chen, Y., Wang, J., and Hu, C. (2022). Kici: A knowledge importance based class incremental learning method for wearable activity recognition. In Proceedings of the 31st ACM International Conference on Information & Knowledge Management, CIKM ’22, page 646–655, New York, NY, USA. Association for Computing Machinery.
Helmi, A. M., Al-qaness, M. A. A., Dahou, A., Damaševičius, R., Krilavičius , T., and Elaziz, M. A. (2021). A novel hybrid gradient-based optimizer and grey wolf optimizer feature selection method for human activity recognition using smartphone sensors. Entropy, 23(8).
Kwapisz, J. R., Weiss, G. M., and Moore, S. A. (2011). Activity recognition using cell phone accelerometers. SIGKDD Explor. Newsl., 12(2):74–82.
Liu, M., Bian, S., Zhou, B., and Lukowicz, P. (2024). ikan: Global incremental learning with kan for human activity recognition across heterogeneous datasets. page 89–95.
Lubba, C. H., Sethi, S. S., Knaute, P., Schultz, S. R., Fulcher, B. D., and Jones, N. S. (2019). catch22: Canonical time-series characteristics. Data Mining and Knowledge Discovery, 33(6):1821–1852.
Middlehurst, M., Large, J., and Bagnall, A. (2020). The canonical interval forest (cif) classifier for time series classification. In 2020 IEEE international conference on big data (big data), pages 188–195. IEEE.
Niedoba, T., Surowiak, A., Hassanzadeh, A., and Khoshdast, H. (2023). Evaluation of the effects of coal jigging by means of kruskal–wallis and friedman tests. Energies, 16(4).
Ohwosoro, I., Edje, A., and Ogeh, C. (2024). A hybrid assault detection system using random forest enabled xgboost-lightgbm technique. Nigerian Journal of Science and Environment, 22(2):177–189.
Pedregosa, F., Varoquaux, G., Gramfort, A., Michel, V., Thirion, B., Grisel, O., Blondel, M., Prettenhofer, P., Weiss, R., Dubourg, V., Vanderplas, J., Passos, A., Cournapeau, D., Brucher, M., Perrot, M., and Duchesnay, E. (2011). Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12:2825–2830.
Reiss, A. (2012). PAMAP2 Physical Activity Monitoring. UCI Machine Learning Repository. DOI: 10.24432/C5NW2H.
Sousa, T., Cruz, L., Souza, C., Magalhães, R., and Macêdo, J. (2025). Enhancing har novelty detection with activity confusion analysis and clustering. In Anais do XXV Simpósio Brasileiro de Computação Aplicada à Saúde, pages 12–23, Porto Alegre, RS, Brasil. SBC.
Tahir, S. B. u. d., Dogar, A. B., Fatima, R., Yasin, A., Shafiq, M., Khan, J. A., Assam, M., Mohamed, A., and Attia, E.-A. (2022). Stochastic recognition of human physical activities via augmented feature descriptors and random forest model. Sensors, 22(17).
Tseng, Y.-H. and Wen, C.-Y. (2023). Hybrid learning models for imu-based har with feature analysis and data correction. Sensors, 23(18).
Valerio, A., Demarchi, D., O’Flynn, B., and Tedesco, S. (2024). Development of a personalized anomaly detection model to detect motion artifacts over ppg data using catch22 features. In 2024 IEEE SENSORS, pages 1–4.
Bukhari, A., Hosseinimotlagh, S., and Kim, H. (2024). Opensense: An open-world sensing framework for incremental learning and dynamic sensor scheduling on embedded edge devices. IEEE Internet of Things Journal, 11(15):25880–25894.
Erickson, N., Mueller, J., Shirkov, A., Zhang, H., Larroy, P., Li, M., and Smola, A. (2020). Autogluon-tabular.
Guo, S., Gu, Y., Wen, S., Ma, Y., Chen, Y., Wang, J., and Hu, C. (2022). Kici: A knowledge importance based class incremental learning method for wearable activity recognition. In Proceedings of the 31st ACM International Conference on Information & Knowledge Management, CIKM ’22, page 646–655, New York, NY, USA. Association for Computing Machinery.
Helmi, A. M., Al-qaness, M. A. A., Dahou, A., Damaševičius, R., Krilavičius , T., and Elaziz, M. A. (2021). A novel hybrid gradient-based optimizer and grey wolf optimizer feature selection method for human activity recognition using smartphone sensors. Entropy, 23(8).
Kwapisz, J. R., Weiss, G. M., and Moore, S. A. (2011). Activity recognition using cell phone accelerometers. SIGKDD Explor. Newsl., 12(2):74–82.
Liu, M., Bian, S., Zhou, B., and Lukowicz, P. (2024). ikan: Global incremental learning with kan for human activity recognition across heterogeneous datasets. page 89–95.
Lubba, C. H., Sethi, S. S., Knaute, P., Schultz, S. R., Fulcher, B. D., and Jones, N. S. (2019). catch22: Canonical time-series characteristics. Data Mining and Knowledge Discovery, 33(6):1821–1852.
Middlehurst, M., Large, J., and Bagnall, A. (2020). The canonical interval forest (cif) classifier for time series classification. In 2020 IEEE international conference on big data (big data), pages 188–195. IEEE.
Niedoba, T., Surowiak, A., Hassanzadeh, A., and Khoshdast, H. (2023). Evaluation of the effects of coal jigging by means of kruskal–wallis and friedman tests. Energies, 16(4).
Ohwosoro, I., Edje, A., and Ogeh, C. (2024). A hybrid assault detection system using random forest enabled xgboost-lightgbm technique. Nigerian Journal of Science and Environment, 22(2):177–189.
Pedregosa, F., Varoquaux, G., Gramfort, A., Michel, V., Thirion, B., Grisel, O., Blondel, M., Prettenhofer, P., Weiss, R., Dubourg, V., Vanderplas, J., Passos, A., Cournapeau, D., Brucher, M., Perrot, M., and Duchesnay, E. (2011). Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12:2825–2830.
Reiss, A. (2012). PAMAP2 Physical Activity Monitoring. UCI Machine Learning Repository. DOI: 10.24432/C5NW2H.
Sousa, T., Cruz, L., Souza, C., Magalhães, R., and Macêdo, J. (2025). Enhancing har novelty detection with activity confusion analysis and clustering. In Anais do XXV Simpósio Brasileiro de Computação Aplicada à Saúde, pages 12–23, Porto Alegre, RS, Brasil. SBC.
Tahir, S. B. u. d., Dogar, A. B., Fatima, R., Yasin, A., Shafiq, M., Khan, J. A., Assam, M., Mohamed, A., and Attia, E.-A. (2022). Stochastic recognition of human physical activities via augmented feature descriptors and random forest model. Sensors, 22(17).
Tseng, Y.-H. and Wen, C.-Y. (2023). Hybrid learning models for imu-based har with feature analysis and data correction. Sensors, 23(18).
Valerio, A., Demarchi, D., O’Flynn, B., and Tedesco, S. (2024). Development of a personalized anomaly detection model to detect motion artifacts over ppg data using catch22 features. In 2024 IEEE SENSORS, pages 1–4.
Publicado
29/09/2025
Como Citar
MACHADO, Brena Rodrigues; MAGALHÃES, Regis Pires; CRUZ, Lívia Almada; DE SOUZA, Criston Pereira; CAVALCANTE MATTOS, César Lincoln; MACEDO, José Antônio Fernandes de.
Analysis of online and offline classification algorithms for human activity recognition using IMU sensors. In: SIMPÓSIO BRASILEIRO DE BANCO DE DADOS (SBBD), 40. , 2025, Fortaleza/CE.
Anais [...].
Porto Alegre: Sociedade Brasileira de Computação,
2025
.
p. 112-125.
ISSN 2763-8979.
DOI: https://doi.org/10.5753/sbbd.2025.247033.
