Advanced Osteoporosis Prediction Using Transformer Models and Genetically Optimized Recurrent Neural Networks
iacs CAI

Computing and Algorithm Insight

Computing and Algorithm Insight serves as a dynamic platform for researchers, scholars, and industry professionals,...

Publishing Model

Open Access
This journal published by Integra Academic Press

Abstract

While artificial intelligence has revolutionized medical diagnostics, osteoporosis prediction remains constrained by the non-personalized nature of conventional DXA scans and traditional risk assessments. This study addresses these limitations by developing a comparative machine learning framework utilizing datasets from Kaggle and NHANES, each comprising approximately 2,000 patient records. The data were standardized to encompass multifaceted risk factors, including physiological metrics, family history, and lifestyle habits. Ten distinct architectures ranging from traditional classifiers to deep learning models (CNN and RNN) and the BERT transformer were evaluated using 10-fold cross-validation. To handle data imbalance in the NHANES set, the SMOTE technique was applied. Notably, the BERT model demonstrated superior efficacy on the Kaggle dataset, achieving 92% accuracy and an AUC of 0.92. Furthermore, integrating a Genetic Algorithm for parameter optimization significantly enhanced the RNN’s performance, elevating its AUC to 0.932 and matching the transformer’s accuracy. These results suggest that combining deep learning with evolutionary optimization offers a robust, personalized approach for early osteoporosis detection, potentially improving long-term bone health management and preventive strategies.

Keywords: Osteoporosis Prediction BERT Transformer Genetic Algorithms Deep Learning Bone Health


References

I. El Naqa and M. J. Murphy, “What is machine learning?” in Machine Learning in Radiation Oncology: Theory and Applications. Cham, Switzerland: Springer, 2015.

D. A. R. Wati and D. Abadianto, “Design of face detection and recognition system for smart home security application,” in Proc. 2nd Int. Conf. Inf. Technol., Inf. Syst. Electr. Eng. (ICITISEE), Nov. 2017, pp. 342–347.

G. Battineni, G. G. Sagaro, N. Chinatalapudi, and F. Amenta, “Applications of machine learning predictive models in the chronic disease diagnosis,” J. Personalized Med., vol. 10, no. 2, p. 21, Mar. 2020.

E. M. Curtis, R. J. Moon, N. C. Harvey, and C. Cooper, “Reprint of: The impact of fragility fracture and approaches to osteoporosis risk assessment worldwide,” Int. J. Orthopaedic Trauma Nursing, vol. 26, pp. 7–17, Aug. 2017.

O. Johnell and J. A. Kanis, “An estimate of the worldwide prevalence and disability associated with osteoporotic fractures,” Osteoporosis Int., vol. 17, no. 12, pp. 1726–1733, Oct. 2006.

J. Barnsley, G. Buckland, P. E. Chan, A. Ong, A. S. Ramos, M. Baxter, F. Laskou, E. M. Dennison, C. Cooper, and H. P. Patel, “Pathophysiology and treatment of osteoporosis: Challenges for clinical practice in older people,” Aging Clin. Experim. Res., vol. 33, no. 4, pp. 759–773, Apr. 2021.

L.-P. Lin, W.-J. Lai, S.-W. Hsu, and J.-D. Lin, “Early osteoporosis risks and associated factors among caregivers working in disability institutions: IOF one-minute osteoporosis risk check,” Int. J. Environ. Res. Public Health, vol. 17, no. 9, p. 3319, May 2020.

P.-L. Xiao, A.-Y. Cui, C.-J. Hsu, R. Peng, N. Jiang, X.-H. Xu, Y.-G. Ma, D. Liu, and H.-D. Lu, “Global, regional prevalence, and risk factors of osteoporosis according to the world health organization diagnostic criteria: A systematic review and meta-analysis,” Osteoporosis Int., vol. 33, no. 10, pp. 2137–2153, Oct. 2022.

N. Salari, H. Ghasemi, L. Mohammadi, M. H. Behzadi, E. Rabieenia, S. Shohaimi, and M. Mohammadi, “The global prevalence of osteoporosis in the world: A comprehensive systematic review and meta-analysis,” J. Orthopaedic Surgery Res., vol. 16, no. 1, pp. 1–20, Oct. 2021.

T. Tanphiriyakun, S. Rojanasthien, and P. Khumrin, “Bone mineral density response prediction following osteoporosis treatment using machine learning to aid personalized therapy,” Sci. Rep., vol. 11, no. 1, p. 13811, Jul. 2021.

A. Prentice, “Diet, nutrition and the prevention of osteoporosis,” Public Health Nutrition, vol. 7, no. 1a, pp. 227–243, Feb. 2004.

E. Canalis, J. P. Bilezikian, A. Angeli, and A. Giustina, “Perspectives on glucocorticoid-induced osteoporosis,” Bone, vol. 34, no. 4, pp. 593–598, Apr. 2004.

E. M. Lewiecki, “Benefits and limitations of bone mineral density and bone turnover markers to monitor patients treated for osteoporosis,” Current Osteoporosis Rep., vol. 8, no. 1, pp. 15–22, Mar. 2010.

O. Bruyere and J.-Y. Reginster, “Monitoring of osteoporosis therapy,” Best Pract. Res. Clin. Endocrinology Metabolism, vol. 28, no. 6, pp. 835–841, 2014.

D. Mueller and A. Gandjour, “Cost-effectiveness of using clinical risk factors with and without DXA for osteoporosis screening in postmenopausal women,” Value Health, vol. 12, no. 8, pp. 1106–1117, Nov. 2009.

J. Kanis, C. Cooper, R. Rizzoli, and J.-Y. Reginster, “Correction to: European guidance for the diagnosis and management of osteoporosis in postmenopausal women,” Osteoporosis Int., vol. 31, p. 801, Feb. 2020.

J. J. Carey and M. F. Delaney, “Utility of DXA for monitoring, technical aspects of DXABMDmeasurement and precision testing,” Bone, vol. 104, pp. 44–53, Nov. 2017.

A. Qaseem, M. A. Forciea, R. M. McLean, and T. D. Denberg, “Treatment of low bone density or osteoporosis to prevent fractures in men and women: A clinical practice guideline update from the American college of physicians,” Ann. Internal Med., vol. 166, no. 11, pp. 818–839, Jun. 2017.

M. A. D. Oliveira, R. Moraes, E. B. Castanha, A. S. Prevedello, J. Vieira Filho, F. A. Bussolaro, and D. García Cava, “Osteoporosis screening: Applied methods and technological trends,” Med. Eng. Phys., vol. 108, Oct. 2022, Art. no. 103887.

G. C. Pereira, M. M. F. D. Oliveira, and N. F. F. Ebecken, “Genetic optimization of artificial neural networks to forecast virioplankton abundance from cytometric data,” J. Intell. Learn. Syst. Appl., vol. 5, no. 1, pp. 57–66, 2013.

M. Liu, X. Wei, X. Xing, Y. Cheng, Z. Ma, J. Ren, X. Gao, and A. Xu, “Predicting fracture risk for elderly osteoporosis patients by hybrid machine learning model,” Digit. HEALTH, vol. 10, Jan. 2024, Art. no. 20552076241257456.

V. J. S. Araújo, A. J. Guimarães, P. V. De Campos Souza, T. S. Rezende, and V. S. Araújo, “Using resistin, glucose, age and BMI and pruning fuzzy neural network for the construction of expert systems in the prediction of breast cancer,” Mach. Learn. Knowl. Extraction, vol. 1, no. 1, pp. 466–482, Feb. 2019.

S. S. Sikarwar, A. K. Rana, and S. S. Sengar, “Entropy-driven deep learning framework for epilepsy detection using electro encephalogram signals,” Neuroscience, vol. 577, pp. 12–24, Jun. 2025.

F. Khan, G. Katsagannis, and S. S. Sengar, “RepSE-CBAMNet: A hybrid attention-enhanced CNN for brain tumor detection,” in Intelligent Health Systems—From Technology to Data and Knowledge. Amsterdam, The Netherlands: IOS Press, 2025, pp. 567–571.

T. Balakrishnan and S. S. Sengar, “RepVGG-GELAN: Enhanced GELAN with VGG-STYLE ConvNets for brain tumour detection,” in Proc. Int. Conf. Comput. Vis. Image Process., 2024, pp. 417–430.

S. S. Sengar, C. Meulengracht, M. P. Boesen, A. F. Overgaard, H. Gudbergsen, J. D. Nybing, M. Perslev, and E. B. Dam, “Multi-planar 3D knee MRI segmentation via UNet inspired architectures,” Int. J. Imag. Syst. Technol., vol. 33, no. 3, pp. 985–998, May 2023.

F. M. Ulivieri, L. Rinaudo, C. Messina, L. P. Piodi, D. Capra, B. Lupi, C. Meneguzzo, L. M. Sconfienza, F. Sardanelli, A. Giustina, and E. Grossi, “Bone strain index predicts fragility fracture in osteoporotic women: An artificial intelligence-based study,” Eur. Radiol. Experim., vol. 5, no. 1, pp. 1–11, Dec. 2021.

U. Ferizi, H. Besser, P. Hysi, J. Jacobs, C. S. Rajapakse, C. Chen, P. K. Saha, S. Honig, and G. Chang, “Artificial intelligence applied to osteoporosis: A performance comparison of machine learning algorithms in predicting fragility fractures from MRI data,” J. Magn. Reson. Imag., vol. 49, no. 4, pp. 1029–1038, Apr. 2019.

H. K. Lim, H. I. Ha, S.-Y. Park, and J. Han, “Prediction of femoral osteoporosis using machine-learning analysis with radiomics features and abdomen-pelvic CT: A retrospective single center preliminary study,” PLoS ONE, vol. 16, no. 3, Mar. 2021, Art. no. e0247330.

D. Lis-Studniarska, M. Lipnicka, M. Studniarski, and R. Irzmański, “Applications of artificial intelligence methods for the prediction of osteoporotic fractures,” Life, vol. 13, no. 8, p. 1738, Aug. 2023.

W.-Y. OuYang, C.-C. Lai, M.-T. Tsou, and L.-C. Hwang, “Development of machine learning models for prediction of osteoporosis from clinical health examination data,” Int. J. Environ. Res. Public Health, vol. 18, no. 14, p. 7635, Jul. 2021.

Z. N. A. M. S. Alden and O. Ata, “A comprehensive analysis and performance evaluation for osteoporosis prediction models,” PeerJ Comput. Sci., vol. 10, p. e2338, Dec. 2024.

A. V. Kulkarni. (2025). Lifestyle Factors Influencing Osteoporosis [Dataset]. Kaggle Datasets. Accessed: Oct. 19, 2025. [Online]. Available: https://www.kaggle.com/datasets/amitvkulkarni/lifestylefactors-influencing-osteoporosis

C. for Disease Control, P. C. N. C. Health Statistics. (2025). National Health and Nutrition Examination Survey (NHANES)—Questionnaires, Datasets, and Related Documentation. Accessed: Oct. 20, 2025. [Online]. Available: https://wwwn.cdc.gov/nchs/nhanes/

C. M. Bishop and N. M. Nasrabadi, Pattern Recognition and Machine Learning, vol. 4. Cham, Switzerland: Springer, 2006.

B. Charbuty and A. Abdulazeez, “Classification based on decision tree algorithm for machine learning,” J. Appl. Sci. Technol. Trends, vol. 2, no. 1, pp. 20–28, Mar. 2021.

R. Guido, S. Ferrisi, D. Lofaro, and D. Conforti, “An overview on the advancements of support vector machine models in healthcare applications: A review,” Information, vol. 15, no. 4, p. 235, Apr. 2024.

L. Breiman, “Random forests,” Mach. Learn., vol. 45, pp. 5–32, Mar. 2001.

C. Ying, Q.-G. Miao, J.-C. Liu, and G. Lin, “Advance and prospects of AdaBoost algorithm,” Acta Automatica Sinica, vol. 39, no. 6, pp. 745–758, Mar. 2014.

Z. Zhang, “Introduction to machine learning: K-nearest neighbors,” Ann. Translational Med., vol. 4, no. 11, p. 218, Jun. 2016.

J. Naskath, G. Sivakamasundari, and A. A. S. Begum, “A study on different deep learning algorithms used in deep neural nets: MLP SOM and DBN,” Wireless Pers. Commun., vol. 128, no. 4, pp. 2913–2936, Feb. 2023.

A. Natekin and A. Knoll, “Gradient boosting machines, a tutorial,” Frontiers Neurorobotics, vol. 7, p. 21, Mar. 2013.

H.-C. Shin, H. R. Roth, M. Gao, L. Lu, Z. Xu, I. Nogues, J. Yao, D. Mollura, and R. M. Summers, “Deep convolutional neural networks for computer-aided detection: CNN architectures, dataset characteristics and transfer learning,” IEEE Trans. Med. Imag., vol. 35, no. 5, pp. 1285–1298, May 2016.

M. Jogin, Mohana, M. S. Madhulika, G. D. Divya, R. K. Meghana, and S. Apoorva, “Feature extraction using convolution neural networks (CNN) and deep learning,” in Proc. 3rd IEEE Int. Conf. Recent Trends Electron., Inf. Commun. Technol. (RTEICT), May 2018, pp. 2319–2323.

W. Wang, F. Bu, Z. Lin, and S. Zhai, “Learning methods of convolutional neural network combined with image feature extraction in brain tumor detection,” IEEE Access, vol. 8, pp. 152659–152668, 2020.

H. Apaydin, H. Feizi, M. T. Sattari, M. S. Colak, S. Shamshirband, and K.-W. Chau, “Comparative analysis of recurrent neural network architectures for reservoir inflow forecasting,” Water, vol. 12, no. 5, p. 1500, May 2020.

R. Vinayakumar, K. P. Soman, and P. Poornachandran, “Evaluation of recurrent neural network and its variants for intrusion detection system (IDS),” Int. J. Inf. Syst. Model. Design, vol. 8, no. 3, pp. 43–63, Jul. 2017.

J. Devlin, M.-W. Chang, K. Lee, and K. Toutanova, “BERT: Pre-training of deep bidirectional transformers for language understanding,” in Proc. Conf. North Amer. Chapter Assoc. Comput. Linguistics, Hum. Lang. Technol., vol. 1, 2019, pp. 4171–4186.

Z. Su, “Applications of BERT in sentimental analysis,” Appl. Comput. Eng., vol. 92, no. 1, pp. 147–152, Oct. 2024.

J. Jeyaranjani and D. Devaraj, “Improved genetic algorithm for optimal demand response in smart grid,” Sustain. Computing: Informat. Syst., vol. 35, Sep. 2022, Art. no. 100710.

R. Kohavi, A Study of Cross-Validation and Bootstrap for Accuracy Estimation and Model Selection. San Mateo, CA, USA: Morgan Kaufmann, 1995.

K. J. van Stralen, V. S. Stel, J. B. Reitsma, F. W. Dekker, C. Zoccali, and K. J. Jager, “Diagnostic methods I: Sensitivity, specificity, and other measures of accuracy,” Kidney Int., vol. 75, no. 12, pp. 1257–1263, Jun. 2009.

J. Huang and C. X. Ling, “Using AUC and accuracy in evaluating learning algorithms,” IEEE Trans. Knowl. Data Eng., vol. 17, no. 3, pp. 299–310, Mar. 2005.

N. V. Chawla, K. W. Bowyer, L. O. Hall, and W. P. Kegelmeyer, “SMOTE: Synthetic minority over-sampling technique,” J. Artif. Intell. Res., vol. 16, pp. 321–357, Jun. 2002.