การเปรียบเทียบตัวแบบการเรียนรู้ของเครื่องและการเรียนรู้เชิงลึกสำหรับการพยากรณ์การเผาผลาญแคลอรี
โครงการจัดตั้งศูนย์วิจัยวิทยาการข้อมูล และ ภาควิชาสถิติ คณะวิทยาศาสตร์ มหาวิทยาลัยเชียงใหม่
In today's fast-paced society, regular exercise is vital for both physical health and cognitive function. Physical activity triggers the release of BDNF, which enhances focus and daily productivity (Festa, 2023). But strict time constraints mean a workout has to be efficient, and accurately tracking calorie expenditure is the metric a personalised, time-effective routine is designed around — turning exercise into a sustainable habit rather than another burden.
Predicted calorie burn with seven models. The neural network reached 98.87% accuracy — the strongest of the set.
Compared five machine learning models. CatBoost came first and XGBoost second, both around 99%.
15,000 records of calorie burn from physical activity.
Categorical values are encoded numerically, every variable is scaled to a common range so no single one biases the model, and forward selection keeps only the inputs that actually move the prediction.
The selected data is split 80 / 20 — 12,000 records to learn the patterns and 3,000 held back to measure accuracy. Three metrics judge the result: MSE (average squared difference between predicted and actual), MAE (average absolute difference) and R² (how much of the variation the model explains). Learning curves check for under- and overfitting; residual plots check the errors are random rather than patterned.
Trees are added one at a time, each fitted to the error the ones before it left behind; the predictions are summed.
Also boosting, but ordered so a row's own target never leaks into the tree that predicts it, which keeps the loss from drifting.
An input layer, hidden layers and an output layer. The hidden layers are what let it bend to the non-linear relationship between duration and heart rate.
| Model | MAE (train) | MAE (test) | MSE | R² |
|---|---|---|---|---|
| XGBoost | 0.9445 | 1.0991 | 2.4315 | 99.9398% |
| CatBoost | 0.8909 | 0.9139 | 1.5665 | 99.9612% |
| Multi-Layer Perceptron | 0.3091 | 0.3220 | 0.1652 | 99.9959% |
The MLP's training and testing MAE sit within 0.013 of each other, so the gap it wins by is not memorised training data.



Predicted calories against the true value. The tighter the points hug the diagonal, the better.
The Multi-Layer Perceptron emerged as the most effective model, validated by all three metrics: an MSE of 0.1652, an MAE of 0.3220 and 99.9959% accuracy.
The MLP captures the non-linear relationship between duration and heart rate better than XGBoost or CatBoost, which is where its higher accuracy comes from.
This is consistent with Beebireddy (2025), where a neural network — the same underlying algorithm — reached 98.87%. The MLP here goes further, and forward feature selection plus data scaling are what account for the difference.
A foundation for health support technology: fitness applications and smart activity tracking devices.
A basic tool for analysing and designing exercise programmes, and for nutrition specialists planning systematic weight management.