journal article·2026-06-12Open access

A Python-based algorithm for automated grain size analysis in ZnO-based varistor ceramics

Zuzanna Cieślikowska, Leszek S Litzbarski

Materials Research Express· Volume 13· Issue 11

Abstract

Abstract Standard methods for grain size determination in microstructures, including those defined in ASTM E112, are largely manual and operator-dependent. In this study, commonly used edge detection and segmentation algorithms, such as the Canny detector and the watershed method, were evaluated with respect to automated grain analysis. Based on this assessment, a Python-based algorithm was developed to enable fully automated detection of grain boundaries in confocal microscopy images of ZnO-based varistor ceramics. The proposed workflow combines image preprocessing and marker-controlled watershed segmentation with automated area-based measurements of labeled grains. Each grain was treated as an individual object, its area was measured in pixels and converted to physical units, and the grain size was expressed as the equivalent circular diameter. The algorithm demonstrates reliable performance, accurately detecting intergranular boundaries and computing grain size in microstructures with variable contrast and artifacts. Owing to its modular design, the method can be readily extended for additional applications. The algorithm is freely available for academic and non-commercial use, and users are requested to cite this work when applying the method or code.
Source: crossref · Quality: baseline

Research context

OpenAlex topics: Machine Learning in Materials Science · Electron and X-Ray Spectroscopy Techniques · Surface Roughness and Optical Measurements

SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.

Affiliations

Gdańsk University of Technology

References (26)

Show source-provided references
1. Influence of grain size on distribution of temperature and thermal stress in ZnO varistor ceramics10.1360/02ye9040 ↗
2. E.-96 ASTM and others · 2004
3. Grain size measurements using circular or rectangular test grids10.3139/147.110208 ↗
4. Lineal intercept technique for measuring grain size in two-phase polycrystalline ceramics10.1111/j.1151-2916.1972.tb11224.x ↗
5. Grain size measurement methods: a review and comparison10.1017/S1431927613010799 ↗
6. Comparative study among Sobel, Prewitt and Canny edge detection operators used in image processing
7. A review of watershed implementations for segmentation of volumetric images10.3390/jimaging8050127 ↗
8. An overview of watershed algorithm implementations in open source libraries10.3390/jimaging4100123 ↗
9. Estimation of average grain size from microstructure image using a convolutional neural network10.3390/ma15196954 ↗
10. Application of deep learning workflow for autonomous grain size analysis10.3390/molecules27154826 ↗
11. Synthesis and characterization of ZnO based varistor ceramics: effect of sintering temperatures10.1108/MI-01-2022-0005 ↗
12. Mielcarek · 2002 · 212 · 1
13. Microstructural engineering of ZnO-based varistor ceramics10.1007/s10853-011-5937-2 ↗
14. Jinliang · 201910.1002/9783527684038 ↗
15. Microstructural and compositional aspects of ZnO-based varistor ceramics prepared by direct mixing of the constituent phases and high-energy milling10.1016/j.ceramint.2007.04.003 ↗
16. Grain-size measurements in metals, and importance of such information10.1039/tf9171200040 ↗
17. Effect of sintering temperature on zinc oxide varistor ceramics10.1088/1757-899X/440/1/012037 ↗
18. Influence of sintering temperature on electrical properties of ZnO varistors10.1063/1.355233 ↗
19. Breakdown phenomenon of ZnO varistors caused by non-uniform distribution of internal pores10.1016/j.jeurceramsoc.2019.06.043 ↗
20. Quality assessment of low voltage surge arresters10.1109/ACCESS.2022.3226401 ↗
21. Morphological, structural and physical characterization of commercially available low voltage ZnO-based varistors10.1038/s41598-026-36941-0 ↗
22. A comprehensive study on the quality of commercially available medium voltage surge arresters10.1109/ACCESS.2026.3678375 ↗
23. Segmentation of experimental datasets via convolutional neural networks trained on phase field simulations10.1016/j.actamat.2021.116990 ↗
24. A novel training methodology for phase segmentation of steel microstructures using a deep learning algorithm10.1016/j.mtla.2023.101803 ↗
25. A novel approach to analyze the microstructure of porous ceramics by image processing technique10.1088/1402-4896/ae1364 ↗
26. Microstructure Grain Analysis