An End-to-end System for Automatic Characterization of Iba1 Immunopositive Microglia in Whole Slide Imaging

  • Alexander D. Kyriazis
  • Shahriar Noroozizadeh
  • Amir Refaee
  • Woongcheol Choi
  • Lap-Tak Chu
  • Asma Bashir
  • Wai Hang Cheng
  • Rachel Zhao
  • Dhananjay R. Namjoshi
  • Septimiu E. Salcudean
  • Cheryl L. Wellington
  • Guy Nir
Original Article


Traumatic brain injury (TBI) is one of the leading causes of death and disability worldwide. Detailed studies of the microglial response after TBI require high throughput quantification of changes in microglial count and morphology in histological sections throughout the brain. In this paper, we present a fully automated end-to-end system that is capable of assessing microglial activation in white matter regions on whole slide images of Iba1 stained sections. Our approach involves the division of the full brain slides into smaller image patches that are subsequently automatically classified into white and grey matter sections. On the patches classified as white matter, we jointly apply functional minimization methods and deep learning classification to identify Iba1-immunopositive microglia. Detected cells are then automatically traced to preserve their complex branching structure after which fractal analysis is applied to determine the activation states of the cells. The resulting system detects white matter regions with 84% accuracy, detects microglia with a performance level of 0.70 (F1 score, the harmonic mean of precision and sensitivity) and performs binary microglia morphology classification with a 70% accuracy. This automated pipeline performs these analyses at a 20-fold increase in speed when compared to a human pathologist. Moreover, we have demonstrated robustness to variations in stain intensity common for Iba1 immunostaining. A preliminary analysis was conducted that indicated that this pipeline can identify differences in microglia response due to TBI. An automated solution to microglia cell analysis can greatly increase standardized analysis of brain slides, allowing pathologists and neuroscientists to focus on characterizing the associated underlying diseases and injuries.


Computer-aided detection and diagnosis Whole slide imaging Digital pathology Image analysis Classification Traumatic brain injury 



This work was supported in part by funding from Natural Sciences and Engineering Research Council of Canada (NSERC), Canadian Institutes of Health Research (CIHR), the BC Innovation Council NRAS Program, and the Weston Brain Institute. Support from Professor Salcudean’s C. A. Laszlo Chair is gratefully acknowledged. Dr. Nir is a recipient of a Prostate Cancer Canada Post-Doctoral Research Fellowship Award #PDF2016-1338.

Compliance with Ethical Standards

Ethical Approval

All applicable international, national, and/or institutional guidelines for the care and use of animals were followed. All procedures performed in studies involving animals were in accordance with the ethical standards of the institution or practice at which the studies were conducted.

Conflict of interests

The authors declare that they have no conflict of interest.

Information Sharing Statement

The data and source code utilized in this work are available at and, respectively.


  1. Abdolhoseini, M., Walker, F., Johnson, S. (2016). Automated tracing of microglia using multilevel thresholding and minimum spanning trees. In 2016 IEEE 38th annual international conference of the engineering in medicine and biology society (EMBC) (pp. 1208–1211). IEEE.Google Scholar
  2. Bae, M.H., Pan, R., Wu, T., Badea, A. (2009). Automated segmentation of mouse brain images using extended mrf. NeuroImage, 46(3), 717–725.CrossRefGoogle Scholar
  3. Balis, U., Hipp, J., Flotte, T., Monaco, J., Cheng, J., Madabhushi, A., Yagi, Y., Rodriguez-Canales, J., Emmert-Buck, M., Dugan, M., et al. (2011). Computer aided diagnostic tools aim to empower rather than replace pathologists: lessons learned from computational chess. Journal of Pathology Informatics, 2(1), 25. Scholar
  4. Bishop, C.M. (2006). Pattern recognition and machine learning (information science and statistics), 1st edn. 2006. corr. 2nd printing edn. New York: Springer.Google Scholar
  5. Breiman, L. (2001). Random forests. Machine Learning, 45(1), 5–32.CrossRefGoogle Scholar
  6. Chen, Z., Shin, D., Chen, S., Mikhail, K., Hadass, O., Tomlison, B.N., Korkin, D., Shyu, C.R., Cui, J., Anthony, D.C., et al. (2014). Histological quantitation of brain injury using whole slide imaging: a pilot validation study in mice. PloS One, 9(3), e92,133.CrossRefGoogle Scholar
  7. Cheng, W.H., Stukas, S., Martens, K.M., Namjoshi, D.R., Button, E.B., Wilkinson, A., Bashir, A., Robert, J., Cripton, P.A., Wellington, C.L. (2018). Age at injury and genotype modify acute inflammatory and neurofilament-light responses to mild chimera traumatic brain injury in wild-type and app/ps1 mice. Experimental Neurology, 301, 26–38.CrossRefGoogle Scholar
  8. Cherry, J.D., Tripodis, Y., Alvarez, V.E., Huber, B., Kiernan, P.T., Daneshvar, D.H., Mez, J., Montenigro, P.H., Solomon, T.M., Alosco, M.L., et al. (2016). Microglial neuroinflammation contributes to tau accumulation in chronic traumatic encephalopathy. Acta Neuropathologica Communications, 4(1), 112.CrossRefGoogle Scholar
  9. Cireşan, D., Giusti, A., Gambardella, L.M., Schmidhuber, J. (2012). Deep neural networks segment neuronal membranes in electron microscopy images. In Advances in neural information processing systems (pp. 2843–2851).Google Scholar
  10. Cireşan, DC, Giusti, A., Gambardella, L.M., Schmidhuber, J. (2013). Mitosis detection in breast cancer histology images with deep neural networks. In International conference on medical image computing and computer-assisted intervention (pp. 411–418). Springer.CrossRefGoogle Scholar
  11. Costa, A. (2013). Hausdorff (box-counting) fractal dimension., [Online; accessed March 2017].
  12. Coughlin, J.M., Wang, Y., Minn, I., Bienko, N., Ambinder, E.B., Xu, X., Peters, M.E., Dougherty, J.W., Vranesic, M., Koo, S.M., et al. (2017). Imaging of glial cell activation and white matter integrity in brains of active and recently retired national football league players. JAMA Neurology, 74(1), 67–74.CrossRefGoogle Scholar
  13. Cruz-Roa, A., Basavanhally, A., González, F, Gilmore, H., Feldman, M., Ganesan, S., Shih, N., Tomaszewski, J., Madabhushi, A. (2014). Automatic detection of invasive ductal carcinoma in whole slide images with convolutional neural networks. In Medical imaging 2014: digital pathology, international society for optics and photonics (Vol. 9041, p. 904103).Google Scholar
  14. Ding, Y., Pardon, M.C., Agostini, A., Faas, H., Duan, J., Ward, W.O., Easton, F., Auer, D., Bai, L. (2017). Novel methods for microglia segmentation, feature extraction, and classification. IEEE/ACM Transactions on Computational Biology and Bioinformatics, 14(6), 1366–1377.CrossRefGoogle Scholar
  15. Doi, K. (2007). Computer-aided diagnosis in medical imaging: historical review, current status and future potential. Computerized Medical Imaging and Graphics, 31(4-5), 198–211. Scholar
  16. Duda, R.O., Hart, P.E., Stork, D.G. (2012). Pattern classification. New York: Wiley.Google Scholar
  17. Ertosun, M.G., & Rubin, D.L. (2015). Automated grading of gliomas using deep learning in digital pathology images: a modular approach with ensemble of convolutional neural networks. In AMIA annual symposium proceedings, American medical informatics association (Vol. 2015, pp. 1899–1908).Google Scholar
  18. Farahani, N., Parwani, A.V., Pantanowitz, L. (2015). Whole slide imaging in pathology: advantages, limitations, and emerging perspectives. Journal of Pathology and Laboratory Medicine International, 7, 23–33.Google Scholar
  19. Finkelstein, E., Corso, P.S., Miller, T.R. (2006). The incidence and economic burden of injuries in the United States. Oxford: Oxford University Press.CrossRefGoogle Scholar
  20. Freund, Y., Schapire, R., Abe, N. (1999). A short introduction to boosting. Journal of Japanese Society for Artificial Intelligence, 14(5), 771–780.Google Scholar
  21. Ghaznavi, F., Evans, A.H., Madabhushi, A., Feldman, M.D. (2013). Digital imaging in pathology: whole-slide imaging and beyond. Annual Review of Pathology, 8(1), 331–59.CrossRefGoogle Scholar
  22. Gonzalez, R.C., & Woods, R.E. (2008). Digital image processing. Upper Saddle River: Pearson-Prentice-Hall.Google Scholar
  23. Healy, S., McMahon, J., Owens, P., FitzGerald, U. (2016). Significant glial alterations in response to iron loading in a novel organotypic hippocampal slice culture model. Scientific Reports, 6, 36,410.CrossRefGoogle Scholar
  24. Holmin, S., Söderlund, J, Biberfeld, P., Mathiesen, T. (1998). Intracerebral inflammation after human brain contusion. Neurosurgery, 42(2), 291–298.CrossRefGoogle Scholar
  25. Hosmer, D.W. Jr., Lemeshow, S., Sturdivant, R.X. (2013). Applied logistic regression, Vol. 398. New York: Wiley.CrossRefGoogle Scholar
  26. Janowczyk, A., & Madabhushi, A. (2016). Deep learning for digital pathology image analysis: a comprehensive tutorial with selected use cases. Journal of Pathology Informatics, 7(29). Scholar
  27. Johnson, S.J., & Walker, F.R. (2015). Strategies to improve quantitative assessment of immunohistochemical and immunofluorescent labelling. Scientific Reports, 5, 10,607.CrossRefGoogle Scholar
  28. Johnson, V.E., Stewart, J.E., Begbie, F.D., Trojanowski, J.Q., Smith, D.H., Stewart, W. (2013). Inflammation and white matter degeneration persist for years after a single traumatic brain injury. Brain: A Journal of Neurology, 136(1), 28–42.CrossRefGoogle Scholar
  29. Kaplan, K.J., & Rao, L.K. (2015). Digital pathology: historical perspectives, current concepts & future applications. Cham: Springer.Google Scholar
  30. Karperien, A., Ahammer, H., Jelinek, H.F. (2013). Quantitating the subtleties of microglial morphology with fractal analysis. Frontiers in Cellular Neuroscience, 7(3), 1–18. Scholar
  31. Karperien, A.L., & Jelinek, H.F. (2015). Fractal, multifractal, and lacunarity analysis of microglia in tissue engineering. Frontiers in Bioengineering and Biotechnology, 3, 51.CrossRefGoogle Scholar
  32. Kettenmann, H., Hanisch, U.K., Noda, M., Verkhratsky, A. (2011). Physiology of microglia. Physiological Reviews, 91(2), 461–553.CrossRefGoogle Scholar
  33. Kollmannsberger, P. (2009). Skeleton3d., [Online; accessed March 2017].
  34. Kozlowski, C., & Weimer, R.M. (2012). An automated method to quantify microglia morphology and application to monitor activation state longitudinally in vivo. PloS One, 7(2), e31,814.CrossRefGoogle Scholar
  35. Krizhevsky, A., Sutskever, I., Hinton, G.E. (2012). Imagenet classification with deep convolutional neural networks. In Advances in neural information processing systems (pp. 1097–1105).Google Scholar
  36. Li, J., Najmi, A., Gray, R.M. (2000). Image classification by a two-dimensional hidden markov model. IEEE Transactions on Signal Processing, 48(2), 517–533.CrossRefGoogle Scholar
  37. Li, W., Liu, H.D., You, W.C., Zhou, M.L., Ling, H.P., Shen, W., Zhu, L., Hang, C.H. (2013). Enhanced cortical expression of myeloid differentiation primary response protein 88 (myd88) in patients with traumatic brain injury. Journal of Surgical Research, 180(1), 133–139.CrossRefGoogle Scholar
  38. Lieh-Lai, M.W., Theodorou, A.A., Sarnaik, A.P., Meert, K.L., Moylan, P.M., Canady, A.I. (1992). Limitations of the glasgow coma scale in predicting outcome in children with traumatic brain injury. The Journal of Pediatrics, 120(2), 195–199.CrossRefGoogle Scholar
  39. Litjens, G., Kooi, T., Bejnordi, B.E., Setio, A.A.A., Ciompi, F., Ghafoorian, M., van der Laak, J.A., van Ginneken, B., Sánchez, C I. (2017). A survey on deep learning in medical image analysis. Medical Image Analysis, 42, 60–88.CrossRefGoogle Scholar
  40. Madabhushi, A., & Lee, G. (2016). Image analysis and machine learning in digital pathology: challenges and opportunities.Google Scholar
  41. McKee, A.C., Cantu, R.C., Nowinski, C.J., Hedley-Whyte, E.T., Gavett, B.E., Budson, A.E., Santini, V.E., Lee, H.S., Kubilus, C.A., Stern, R.A. (2009). Chronic traumatic encephalopathy in athletes: progressive tauopathy after repetitive head injury. Journal of Neuropathology & Experimental Neurology, 68(7), 709–735.CrossRefGoogle Scholar
  42. McKee, A.C., Stein, T.D., Nowinski, C.J., Stern, R.A., Daneshvar, D.H., Alvarez, V.E., Lee, H.S., Hall, G., Wojtowicz, S.M., Baugh, C.M., et al. (2013). The spectrum of disease in chronic traumatic encephalopathy. Brain: A Journal of Neurology, 136(1), 43–64.CrossRefGoogle Scholar
  43. Namjoshi, D.R., Cheng, W.H., McInnes, K.A., Martens, K.M., Carr, M., Wilkinson, A., Fan, J., Robert, J., Hayat, A., Cripton, P.A., et al. (2014). Merging pathology with biomechanics using chimera (closed-head impact model of engineered rotational acceleration): a novel, surgery-free model of traumatic brain injury. Molecular Neurodegeneration, 9(1), 55.CrossRefGoogle Scholar
  44. Namjoshi, D.R., Cheng, W.H., Bashir, A., Wilkinson, A., Stukas, S., Martens, K.M., Whyte, T., Abebe, Z.A., McInnes, K.A., Cripton, P.A., et al. (2017). Defining the biomechanical and biological threshold of murine mild traumatic brain injury using chimera (closed head impact model of engineered rotational acceleration). Experimental Neurology, 292, 80–91.CrossRefGoogle Scholar
  45. Nir, G., Hor, S., Karimi, D., Fazli, L., Skinnider, B.F., Tavassoli, P., Turbin, D., Villamil, C.F., Wang, G., Wilson, R.S., et al. (2018). Automatic grading of prostate cancer in digitized histopathology images: learning from multiple experts. Medical Image Analysis, 50(12), 167–180.CrossRefGoogle Scholar
  46. Petushi, S., Garcia, F.U., Haber, M.M., Katsinis, C., Tozeren, A. (2006). Large-scale computations on histology images reveal grade-differentiating parameters for breast cancer. BMC Medical Imaging, 6(1), 14–24. Scholar
  47. Popescu, C., Anghelescu, A., Daia, C., Onose, G. (2015). Actual data on epidemiological evolution and prevention endeavours regarding traumatic brain injury. Journal of Medicine and Life, 8(3), 272–277.PubMedPubMedCentralGoogle Scholar
  48. Ramlackhansingh, A.F., Brooks, D.J., Greenwood, R.J., Bose, S.K., Turkheimer, F.E., Kinnunen, K.M., Gentleman, S., Heckemann, R.A., Gunanayagam, K., Gelosa, G., et al. (2011). Inflammation after trauma: microglial activation and traumatic brain injury. Annals of Neurology, 70(3), 374–383.CrossRefGoogle Scholar
  49. Rashid, S., Nir, G., Fazli, L., Boag, A.H., Siemens, D.R., Goldenberg, S.L., Abolmaesumi, P., Salcudean, S.E. (2018). Automatic pathology of prostate cancer in whole mount slides incorporating individual gland classification. Computer Methods in Biomechanics and Biomedical Engineering: Imaging & Visualization.
  50. Rouchdy, Y., & Cohen, L.D. (2013). Geodesic voting for the automatic extraction of tree structures. methods and applications. Computer Vision and Image Understanding, 117(10), 1453–1467.CrossRefGoogle Scholar
  51. Sirinukunwattana, K., Raza, S.E.A., Tsang, Y.W., Snead, D.R., Cree, I.A., Rajpoot, N.M. (2016). Locality sensitive deep learning for detection and classification of nuclei in routine colon cancer histology images. IEEE Transactions on Medical Imaging, 35(5), 1196–1206.CrossRefGoogle Scholar
  52. Stein, T.D., Alvarez, V.E., McKee, A.C. (2014). Chronic traumatic encephalopathy: a spectrum of neuropathological changes following repetitive brain trauma in athletes and military personnel. Alzheimer’S Research & Therapy, 6(1), 4.CrossRefGoogle Scholar
  53. Steinwart, I., & Christmann, A. (2008). Support vector machines. Berlin: Springer Science & Business Media.Google Scholar
  54. Strekalovskiy, E., & Cremers, D. (2014). Real-time minimization of the piecewise smooth mumford-shah functional. In European conference on computer vision (pp. 127–141). Springer.Google Scholar
  55. Taylor, C., Bell, J., Breiding, M., Xu, L. (2017). Traumatic brain injury–related emergency department visits, hospitalizations, and deaths—United States, 2007 and 2013. MMWR Surveillance Summaries, 66(9), 1–16.CrossRefGoogle Scholar
  56. Teasdale, G., Maas, A., Lecky, F., Manley, G., Stocchetti, N., Murray, G. (2014). The glasgow coma scale at 40 years: standing the test of time. The Lancet Neurology, 13(8), 844–854.CrossRefGoogle Scholar
  57. The MathWorks. (2017a). Matlab: Deep learning. [Online; accessed 1 December 2017].
  58. The MathWorks. (2017b). Matlab: Regional maxima. [Online; accessed 1 December 2017].
  59. Vadakkan, T.J. (2009). Lacunarity of a binary image., [Online; accessed August 2018].
  60. Valous, N.A., Lahrmann, B., Zhou, W., Veltkamp, R., Grabe, N. (2013). Multistage histopathological image segmentation of iba1-stained murine microglias in a focal ischemia model: methodological workflow and expert validation. Journal of Neuroscience Methods, 213(2), 250–262.CrossRefGoogle Scholar
  61. Van Gool, L., Szekely, G., Ferrari, V. (2014). Computer Vision.Google Scholar
  62. Wu, T., Bae, M.H., Zhang, M., Pan, R., Badea, A. (2012). A prior feature svm-mrf based method for mouse brain segmentation. NeuroImage, 59(3), 2298–2306.CrossRefGoogle Scholar

Copyright information

© Springer Science+Business Media, LLC, part of Springer Nature 2018

Authors and Affiliations

  • Alexander D. Kyriazis
    • 1
  • Shahriar Noroozizadeh
    • 1
  • Amir Refaee
    • 1
  • Woongcheol Choi
    • 1
  • Lap-Tak Chu
    • 1
  • Asma Bashir
    • 2
  • Wai Hang Cheng
    • 2
  • Rachel Zhao
    • 2
  • Dhananjay R. Namjoshi
    • 2
  • Septimiu E. Salcudean
    • 3
  • Cheryl L. Wellington
    • 2
  • Guy Nir
    • 4
  1. 1.Engineering PhysicsUniversity of British ColumbiaVancouverCanada
  2. 2.Department of Pathology and Laboratory MedicineUniversity of British ColumbiaVancouverCanada
  3. 3.Department of Electrical and Computer EngineeringUniversity of British ColumbiaVancouverCanada
  4. 4.Department of Urologic SciencesUniversity of British ColumbiaVancouverCanada

Personalised recommendations