Robust Multi-Sensor Machine Learning Models for Goat Barn Microclimate Automation

Authors

  • Citra Dewi Megawati Universitas Brawijaya
  • Bima Romadhon Parada Dian Palevi Institut Teknologi Nasional Malang, Indonesia
  • Teo Pei Kian Southern University of College, Malaysia

DOI:

10.33395/sinkron.v10i4.16481

Keywords:

Ammonia, Edge Computing, ESP32, Gaussian Noise, Random Forest, Temperature-Humidity Index

Abstract

Conventional goat barn management faces critical productivity drawbacks due to unmonitored microclimatic fluctuations, where environmental heat stress and toxic gas accumulations suppress livestock welfare. This study proposes "CapraFarm," a proactive thermal control architecture that integrates ambient temperature, relative humidity, and ammonia gas monitoring into a multi-criteria predictive automation pipeline. To stress-test algorithmic resilience against physical hardware degradation, a 5,000-entry dataset derived from sensor calibration error margins was injected with 5% to 10% Additive Gaussian White Noise. Six machine learning algorithms—including Random Forest, Extra Trees, LightGBM, XGBoost, Support Vector Machines, and Gaussian Naive Bayes—alongside conventional and hysteresis-enhanced rule-based baselines were evaluated using Stratified 10-Fold Cross-Validation. Experimental results revealed that Random Forest achieved the highest predictive performance, maintaining a classification accuracy of 97.12% ± 0.89%, a macro F1-score of 0.9354, and an Area Under Curve of 0.9941. This performance significantly outperformed the hysteresis-enhanced rule-based baseline (94.58% accuracy) under McNemar’s statistical test (). Feature importance attribution using SHapley Additive exPlanations confirmed that ammonia gas spikes exert critical non-linear overrides for instant hazard mitigation. Hardware-in-the-Loop profiling established that while Random Forest is optimal for centralized cloud optimization, Gaussian Naive Bayes excels in edge microcontroller environments with a minimal memory footprint of 45 Kilobytes and an execution latency of 1.94 milliseconds. This study solidifies a dual-layer Hybrid Edge-Cloud Paradigm for continuous climate control, laying a validated computational foundation for future long-term in-vivo physical field deployments in smart livestock facilities.

GS Cited Analysis

Downloads

Download data is not yet available.

Author Biography

Citra Dewi Megawati, Universitas Brawijaya

References

Azmi, F. et all. (2025). Intelligent Actuator Control in Smart Agriculture through Machine Learning and Sensor Data Integration. Zero : Jurnal Sains, Matematika, Dan Terapan, 9(1), 150–161. https://doi.org/10.30829/zero.v9i1.24421

Bafdal, N., Ardiansah, I., & Asmara, S. (2022). Application of Internet of Things ( IoT ) on Microclimate Monitoring System in The ALG Unpad Greenhouse Based on Raspberry Pi. Jurnal Teknik Pertanian Lampung, 11(3), 518–530.

Barsagadea, A. G., & Rumaleb, A. S. (2024). INTELLIGENT SYSTEMS AND APPLICATIONS IN ENGINEERING Internet of Things Based Intelligent monitoring and Controlling of Poultry System on using Artificial Intelligence. International Journal of INTELLIGENT SYSTEMS AND APPLICATIONS IN ENGINEERING, 12, 456–467.

Bhattacharyya, D., & Kundu, U. K. (2025). The Role of Industrial IoT and Machine Learning in Reshaping Predictive Maintenance Strategies. Journal of Emerging Trends in Computer Science and Applications, 1(1), 41–54.

Boateng, F. L., Effah, E., & Abdel-fatao, H. (2026). Turkish Journal of Agriculture - Food Science and Technology Comprehensive Review of Multi-Sensor IoT Applications in Modern Agriculture. 14(5), 1387–1398.

Brocklehurst, S., Fang, Z., & Butler, A. (2025). Real-Time Auto-Monitoring of Livestock : Quantitative Framework and Challenges. Sensors, 25(5871), 1–58.

Candra, A. P. (2025). Analisis Data Menggunakan Python : Memperkenalkan Pandas dan NumPy. Journal of Information System and Education Development, 3(1), 11–16.

Chundawat; et all. (2024). Intelligent IoT based Temperature and Humidity Monitoring System for Tobacco Curing Barn. 2024 International Conference on IoT Based Control Networks and Intelligent Systems (ICICNIS), 419–423. https://doi.org/10.1109/ICICNIS64247.2024.10823279

Fauza, A., Hidayat, S., Ikhsan, A., & Wulandari, B. (2022). Sistem Informasi Monitoring Integrasi Program pada Direktorat PMPUPO Badan POM. Jurnal Informatika Universitas Pamulang, 7(1), 9–20.

Japit, S., Risyani, Y., Bombongan, C., & Selamat, T. (2025). Pemanfaatan Pandas , NumPy , Spark , dan TableauPower BI dalam Pengolahan dan Visualisasi Big Data untuk Mendukung Pengambilan Keputusan. Jurnal Minfo Polgan, 14(1), 452–456.

Jauhari Lutfi1, D. I. (2026). Sistem otomatisasi ventilasi, pemanas, dan pembersihan kotoran berbasis iot menggunakan esp-32 iot-based ventilation, heating, and cleaning automation system using esp-32. Journal of Information Technology and Computer Science (INTECOMS), 9(2), 172–181.

Jebari, H., Rekiek, S., & Reklaoui, K. (2025). Advancing Precision Livestock Farming : Integrating Hybrid AI , IoT , Cloud and Edge Computing for Enhanced Welfare and Efficiency. International Journal of Advanced Computer Science and Applications, 16(7), 302–311.

Jerhamre, E., Johan, C., Carlberg, C., & Zoest, V. Van. (2022). Smart Agricultural Technology Exploring the susceptibility of smart farming : Identified opportunities and challenges. Smart Agricultural Technology, 2(August 2021), 100026. https://doi.org/10.1016/j.atech.2021.100026

Kumar, V., Vaibhav, K., Kedam, N., Patel, A., Ram, T., & Rathnayake, U. (2024). Smart Agricultural Technology A comprehensive review on smart and sustainable agriculture using IoT technologies. Smart Agricultural Technology, 8(February), 100487. https://doi.org/10.1016/j.atech.2024.100487

Mayberry, D., Ash, A., Prestwidge, D., & Herrero, M. (2018). Closing yield gaps in smallholder goat production systems in Ethiopia and India. Livestock Science, 214(January), 238–244. https://doi.org/10.1016/j.livsci.2018.06.015

Nasihin, A., & Fajar, D. M. (2026). HEAT STRESS CHALLENGES AND MITIGATION STRATEGIES IN INDONESIAN SMALLHOLDER DAIRY FARMS : A BRIEF REVIEW. Agrinimal Jurnal Ilmu Ternak Dan Tanaman, 14(177), 114–123.

Nejad, J. G., & Sung, K. (2017). Behavioral and physiological changes during heat stress in Corriedale ewes exposed to water deprivation. Journal of Animal Science and Technology, 59(13), 1–6. https://doi.org/10.1186/s40781-017-0140-x

Perumal, P. (2025). Role of housing microclimate in shaping physiological , hormonal , and productive traits in goats under tropical stress conditions. Tropical Animal Health and Production (2025), 57(522).

Purba, M. (2025). Klasifikasi Jenis Daun Tanaman Tropis Menggunakan Model ResNet50 Berbasis Transfer Learning dengan Dataset Tropical Plant Leaf. JCOSIS (Journal Computer Science and Information Syetem), 2(2), 51–57.

Rachmadani, F. N. (2024). RESPON FISIOLOGIS SAPI BALI (Bos javanicus) YANG DIPELIHARA PADA BERBAGAI LINGKUNGAN TERMAL DI INDONESIA: SEBUAH META-ANALISIS. Jurnal Nutrisi Ternak Tropis Dan Ilmu Pakan, 6(4), 178–192.

Renata Pilarczyk; Et All. (2026). The Influence of Environmental Conditions and Husbandry Practices on Goat Welfare. Animals, 16(838), 1–30.

Sahapudeen, F. F., Reyaa, K., Rubika, R., & Subhadharani, J. (2024). Live Stock Shelter Management System using IoT and ML. International Journal of Advanced Research in Science, Communication and Technology (IJARSCT), 4(7), 48175. https://doi.org/10.48175/IJARSCT-17816

Sathees, S., Priyanka, M., Renusree, T., Samyuktha, S. K., & Sandhiya, L. (2025). LIVE STOCK MONITORING AND MANAGEMENT SYSTEM USING A RENTABLE IOT FRAMEWORK FOR RURAL CATTLEOWNERS. International Research Journal of Modernization in Engineering Technology and Science, 07(05), 9048–9056.

Sejian, V., Silpa, M. V, Nair, M. R. R., Devaraj, C., Krishnan, G., Bagath, M., Chauhan, S. S., Suganthi, R. U., Fonseca, V. F. C., König, S., Gaughan, J. B., Dunshea, F. R., & Bhatta, R. (2021). Heat Stress and Goat Welfare: Adaptation and Production Considerations. Animals, 11(1021), 1–24.

Setiawan, A. A., Erwanto, E., Hartono, M., & Qisthon, A. (2021). Pengaruh Manipulasi Iklim Kandang Melalui Pengkabutan Terhadap Respon Fisiologis Dan Ketahanan Panas Kambing Sapera Dan Peranakan Ettawa. Jurnal Riset Dan Inovasi Peternakan (Journal of Research and Innovation of Animals), 5(1), 64–69. https://doi.org/10.23960/jrip.2021.5.1.64-69

Sharma, S., Sharma, C., Asenso, E., & Sharma, K. (2023). Research Constituents and Trends in Smart Farming : An Analytical Retrospection from the Lens of Text Mining. Hindawi Journal of Sensors, 2023, 21. https://doi.org/10.1155/2023/6916213

Silva, W. C. da. (2023). Evaluation of the temperature and humidity index to support the implementation of a rearing system for ruminants in the Western Amazon. Frontiers in Veterinary Science.

Syarif, M. (2022). WATERFALL SEBAGAI MODEL PENGEMBANGAN SISTEM. Jurnal Teknologi Informasi, 6(1), 44–52.

Terence, S., Immaculate, J., & Raj, A. (2024). Systematic Review on Internet of Things in Smart Livestock Management Systems. Sustainability, 16(4073), 1–37.

Zhang, L., Hang, Z., & Hu, H. (2024). Toward Large-scale Application of a Bio-inspired MEMS Optical Hair Flow Sensor Array. 2024 IEEE SENSORS, 1(d), 1–4. https://doi.org/10.1109/SENSORS60989.2024.10784825

Downloads


Crossmark Updates

How to Cite

Megawati, C. D., Palevi, B. R. P. D. ., & Kian, T. P. . (2026). Robust Multi-Sensor Machine Learning Models for Goat Barn Microclimate Automation. Sinkron : Jurnal Dan Penelitian Teknik Informatika, 10(4), 2048-2061. https://doi.org/10.33395/sinkron.v10i4.16481

Most read articles by the same author(s)