Skip to main page content
U.S. flag

An official website of the United States government

Dot gov

The .gov means it’s official.
Federal government websites often end in .gov or .mil. Before sharing sensitive information, make sure you’re on a federal government site.

Https

The site is secure.
The https:// ensures that you are connecting to the official website and that any information you provide is encrypted and transmitted securely.

Access keys NCBI Homepage MyNCBI Homepage Main Content Main Navigation
. 2025 Apr;47(2):336-342.
doi: 10.1111/ics.13030. Epub 2024 Nov 17.

Estimating hair density with XGBoost

Affiliations

Estimating hair density with XGBoost

Yi-Fan Wang et al. Int J Cosmet Sci. 2025 Apr.

Abstract

Objectives: Hair density estimation is crucial in dermatology and trichology; however, manual counting is time-consuming and error-prone. Although automated approaches have been developed using image processing, neural networks, and deep learning, creating a robust and widely applicable method remains challenging. This study explored the use of XGBoost to estimate hair density with the aim of developing a more accurate and versatile approach.

Methods: The study utilized 895 scalp images to extract features and developed an XGBoost model for hair density estimation using 745 images to train the model and testing its performance on 150 images to evaluate the accuracy, error rate, and scatter plot.

Results: The XGBoost model outperformed previous methods, achieving 89.5% accuracy on the training set and 95.3% accuracy on the test set. This surpassed the results of Kim et al. (52.4%), Urban et al. (79.6%), and Sacha et al. (88.2%) for the test set.

Conclusion: The XGBoost algorithm proved to be effective for automated hair density estimation, achieving an accuracy of 95.3% on the test set. This approach, which focusses on scalp coverage and erosion features, can streamline and improve the objectivity of clinical hair analysis.

Objectifs: l'estimation de la densité des cheveux est. cruciale en dermatologie et en trichologie; cependant, le comptage manuel est. chronophage et sujet à erreurs. Bien que des approches automatisées aient été développées à l'aide du traitement d'image, des réseaux neuronaux et de l'apprentissage profond, la création d'une méthode robuste et largement applicable reste difficile. Cette étude a porté sur l'utilisation de XGBoost pour estimer la densité des cheveux dans le but de développer une approche plus précise et plus polyvalente. MÉTHODES: l'étude a utilisé 895 images du cuir chevelu pour extraire les caractéristiques et a développé un modèle XGBoost pour l'estimation de la densité des cheveux en utilisant 745 images pour former le modèle et tester ses performances sur 150 images afin d'évaluer l'exactitude, le taux d'erreur et le diagramme de dispersion. RÉSULTATS: le modèle XGBoost a surpassé les méthodes précédentes, avec une exactitude de 89.5% sur la série de formations et de 95.3% sur la série de tests. Cela a dépassé les résultats de Kim et al. (52.4%), Urban et al. (79.6%), et Sacha et al. (88.2%) pour la série de tests.

Conclusion: l'algorithme XGBoost s'est. avéré efficace pour l'estimation automatique de la densité des cheveux, en obtenant une exactitude de 95.3% sur la série de tests. Cette approche, qui se concentre sur la couverture du cuir chevelu et les caractéristiques d'érosion, peut rationaliser et améliorer l'objectivité de l'analyse clinique des cheveux.

Keywords: computer‐aided detection and diagnosis; hair density; machine learning; pattern recognition and classification; skin.

PubMed Disclaimer

References

REFERENCES

    1. Kim H, Kim W, Rew J, Rho S, Park J, Hwang E. Evaluation of hair and scalp condition based on microscopy image analysis. International conference on platform technology and service (PlatCon). Busan, South Korea: IEEE; 2017. p. 1–4.
    1. Urban G, Feil N, Csuka E, Hashemi K, Ekelem C, Choi F, et al. Combining deep learning with optical coherence tomography imaging to determine scalp hair and follicle counts. Lasers Surg Med. 2021;53(1):171–178.
    1. Sacha JP, Caterino TL, Fisher BK, Carr GJ, Youngquist RS, D'Alessandro BM, et al. Development and qualification of a machine learning algorithm for automated hair counting. Int J Cosmet Sci. 2021;43:34–41.
    1. Chen T, Guestrin C. XGBoost: A scalable tree boosting system. In Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining. 2016 (pp. 785–794).
    1. Bradley D, Roth G. Adaptive thresholding using the integral image. J Graphics Tools. 2007;12(2):13–21.

LinkOut - more resources