Algorithms and methods for comparing microstructures of materials based on their images Valeriia Hritskova1, Oleh Semenenko1, Mariia Shapovalova1 and Oleksii Vodka1 1 National Technical University Β«Kharkiv Polytechnic InstituteΒ», 2, Kyrpychova str., Kharkiv, 61002, Ukraine Abstract The study aims to develop robust image processing algorithms capable of automatically identifying and characterizing individual grains within material microstructures. These algorithms extract essential grain properties, including area, shape factor, and orientation angle. Additionally, the study explores which grain characteristics are most effective for microstructure comparison. The proposed algorithm segments microstructure images to isolate individual grains. Grain properties (e.g., area, perimeter, circularity) areare quantified. The distributions of grain characteristics are analyzed using violin plots. Both visual comparisons and statistical measures (mean, variance, skewness) informs microstructure similarity. Proposed algorithms have been tested on validation images and errors have been estimated. Understanding microstructure properties is crucial for material design, quality control, and performance optimization. The proposed algorithms contribute to automated microstructure analysis, benefiting fields such as materials science, engineering, and manufacturing. Keywords Image Processing Algorithm, Feature Extraction, Grain Characteristics, Violin Plots, Statistical Comparison 1 1. Introduction Algorithms and methods for comparing the microstructures of materials based on their images have become the object of considerable attention in modern research. The significance of this area lies in the possibility of obtaining information about the properties of materials that affect their functionality and application. The development of algorithms for comparing microstructures has become an important task in the context of finding optimal solutions in materials science. The initiation of this process involved establishing a complex for generating microstructures; however, a challenge emerged concerning the comparison between these generated structures and real ones. In light of this, the solution to this problem involved the development of image processing methods for comparing the generated microstructures with experimental data. The microstructures of materials play a fundamental role in their properties and functionality, determining their mechanical, thermal, and electrical characteristics. The contribution of microstructures to the development of science and technology cannot be overstated, as their understanding and optimization have a significant impact on the design and production of materials. Research emphasizes not only the significant role of the microstructure itself but also its components. Particular attention is given to the process of microstructure formation - crystal growth. Since physical experiments are difficult to study the characteristics of microstructure evolution during grain growth, computer modeling is used as an effective alternative. Using the cellular automata method, various models have been considered so far: 2D modeling of microstructures [4], [5], 3D modeling of microstructures [6]-[8], [19], [20] modeling using probabilities [9], [10], modeling of crystal growth by recrystallization [11]-[12]. The study of these models has allowed us to analyze various aspects of the processes of microstructure formation, their evolution, and their influence on the properties of materials. The use of different CMIS-2024: Seventh International Workshop on Computer Modeling and Intelligent Systems, May 3, 2024, Zaporizhzhia, Ukraine valeriia.hriskova@infiz.khpi.edu.ua (V. Hritskova); oleh.semenenko@infiz.khpi.edu.ua (O. Semenenko); mariia.shapovalova@khpi.edu.ua (M. Shapovalova); oleksii.vodka@khpi.edu.ua (O. Vodka) 0009-0002-6825-726X (V. Hritskova); 0009-0003-7275-2412 (O. Semenenko); 0000-0002-4771-7485 (M. Shapovalova); 0000-0002-4462-9869 (O. Vodka) Β© 2024 Copyright for this paper by its authors. Use permitted under Creative Commons License Attribution 4.0 International (CC BY 4.0). CEUR ceur-ws.org Workshop ISSN 1613-0073 Proceedings modeling approaches allows for obtaining a more complete understanding of the physical and chemical processes that occur during crystal growth and microstructure formation. A special application MatViz3D (https://github.com/MME-NTU-KhPI/MatViz3D) has been developed for computer modelling of the crystallization process and generation of microstructures. The main advantages of the application are the three-dimensional generation of microstructures, which allows to obtain detailed and realistic images of the material structure, the selection of cell neighborhoods for the diversity of generation, and the ability to follow the step-by-step crystallization process. Overall, MatViz3D is a powerful tool for modeling, analyzing, and visualizing material microstructures using a variety of approaches and techniques. Once the microstructure is generated, it is necessary to conduct research and identify the characteristics inherent in the model. The identification of model characteristics is carried out through data processing and systematization. Among the tools that can be used for this purpose, a special place is occupied by processing data in the form of images. Using techniques such as image analysis and image processing, it is possible to identify the main features of microstructures, such as grain size, shape, and distribution of grains in space. For example, the use of segmentation algorithms can automatically identify individual grains in microstructure images, which simplifies further analysis. In addition, the use of image processing techniques to determine various characteristics, such as grain size, shape, and texture, provides quantitative data that can be used for further analysis and comparison with experimental data or other models. This approach to image processing is becoming increasingly common in the study of material microstructures and plays an important role in the development of the fields of materials science and mechanics [14]-[18]. Having processed the image and obtained the grain properties of the microstructures, it becomes necessary to develop an algorithm for their comparison. In this context, a special emphasis is placed on comparing the distributions and statistical characteristics of each of the grain properties. This approach will allow for a deeper analysis and comparison of material microstructures, contributing to the further development of the fields of materials science and mechanics. Although there are already software tools, such as CLEMEX [21] and Fiji [22], designed to process images and detect regions on them, this study developed a system for comparing grain characteristics that goes beyond the capabilities of these programs. The developed system allows for automated comparison of the distribution of microstructure characteristics and determines statistical parameters that are not available in existing software. This expands the analytical capabilities and provides a deeper understanding of the microstructures of materials. 2. Problem statement The objective of this study is to develop image processing algorithms for automatically identifying regions in an image that correspond to individual grains in the microstructure of a material. The resulting algorithms should also provide the calculation of the characteristics of each grain, such as area, shape factor, orientation angle, etc. Further, the developed algorithms will be tested on test images of microstructures, after which the results will be presented. Based on the analysis of these results, recommendations should be made as to which grain characteristics can be used for more effective comparison of microstructures and which may have limited variability and therefore be less important for comparison. In addition, the study will develop an algorithm for comparing microstructures by analyzing the distributions of grain characteristics. For this purpose, violin plots will be used to visualize the distributions of grain size and other characteristics. In addition to comparing the visual characteristics, the statistical properties of the distributions will be analyzed, which will provide additional data on the similarity or difference of microstructures in different cases. 3. Methodology The study and reproduction of microstructures plays a key role in the development of new materials with unique properties that will find applications in a wide range of industries, including electronics, aviation, medicine, and energy. Microstructures are defined as the organization and arrangement of materials at the microscopic level, and they have a significant impact on the properties and behavior of materials. It is important to note that the formation of microstructures is a complex and multifactorial problem, which is influenced by a variety of factors, including chemical composition, temperature, pressure, cooling rate, and others. Furthermore, microstructures can exhibit extreme diversity depending on the type of material, the number of impurities, the manufacturing process, and the conditions. The key stage is the formation of the internal structure of the material, as it allows analyzing the interaction between its elements, such as location, quantity, and nature. This helps to determine the optimal conditions for achieving the desired material parameters (e.g. strength, wear resistance, thermal conductivity, etc.). The detailed analysis and presentation of such material information can enable modeling and simulation with an accurate description of specific microstructural features. It also opens up the possibility of performing highly accurate engineering calculations using well-known methods, such as the finite element method. The ability to characterize microstructural features using statistical methods is a significant advance in materials science. This helps to increase the accuracy of material property predictions. Conventional techniques and methodologies employed for the quantitative analysis of three- dimensional structures using data derived from two-dimensional images or their cross-sections enable the prediction and determination of three-dimensional structural attributes. These encompass parameters such as volume, surface area, boundary length, and other descriptors derived from the analysis of images acquired from various orientations or viewpoints. Such approaches facilitate the evaluation of geometric and morphological characteristics of structures and materials. However, there are microstructural parameters that cannot be determined from a single two- dimensional section, such as the connectivity of features, the true shape of inclusions, and the number of inclusions per unit volume. The need for a more complete characterization of microstructures has led to the development of techniques that allow for the direct acquisition of three-dimensional microstructural data of grain structures, such as serial sectioning, intergranular corrosion, and various X-ray tomography-based techniques. This includes references [2] and [3], where the authors quantify a set of microstructural parameters and their relationships to determine morphological characteristics using the serial sectioning technique to collect 3D crystallographic data. Many of the parameters have been quantified in two- dimensional space, while only a few have been determined in three-dimensional space, but the study of the relationships between these parameters has remained limited [1]. Thus, despite the significant progress in microstructure generation and the development of related applications, this topic requires further research and development. There is potential for improving generation algorithms, expanding the functionality of applications, and improving the accuracy of microstructure visualization. This study aims to analyze and compare the structures obtained experimentally with similar structures generated by artificial methods in an analytical context. The paper uses a set of metrics to compare such structures. Features such as sample and inclusion areas, their perimeters, and the ratio of these parameters are analyzed. The concept of area equivalence is introduced, and equivalent radii are found. Based on these indicators, the results are visualized using histograms and Kernel Density Estimation (KDE). By performing a statistical analysis of the results, using mathematical expectation and variance of values, a comparison is made, and a conclusion is drawn about the adequacy of the use of computer modeling of microstructure and artificial sample generation in comparison with experimental data. 3.1. Metrics for comparing experimental and generated structures Several parameters are employed to ascertain the characteristics of grains, facilitating the evaluation of their shape and size. β€’ The normalized grain area is determined by the ratio of the grain area to the total image area using the formula (1): π΄π‘”π‘Ÿ 𝐴𝑛 = , (1) 𝐴 where, π΄π‘”π‘Ÿ - is the grain area, and 𝐴 - is the total area of the image. β€’ The grain shape coefficient is calculated as the ratio of the grain area to the square of its perimeter according to (2): π΄π‘”π‘Ÿ 𝐢𝑠 = 4πœ‹ 2 , (2) π‘ƒπ‘”π‘Ÿ where π‘ƒπ‘”π‘Ÿ - is the perimeter of the grain. β€’ The equivalent circle radius of the grain, as the value of the radius of a circle having the same area as the area of the grain projection onto the plane, is calculated by (3): 𝐴𝑛 π‘’Ρπ‘Ÿ = √ , (3) πœ‹ β€’ In addition, the orientation angle πœ“ which is reflected in the deviation of the major axis of the grain 𝑆π‘₯ from the horizontal axis. β€’ The scale factor of the grain is defined as the ratio of the large to the small grain axes according to (4): 𝑆π‘₯ 𝑆𝑐 = , (4) 𝑆𝑦 where 𝑆π‘₯ - is the major axis, and 𝑆𝑦 - is the minor axis of the grain. An example of the appearance of an arbitrary grain with the designation of the minor and major axes and the orientation angle is shown in Figure 1. β€’ The grain inertia tensor is represented as (5): 𝐼π‘₯π‘₯ 𝐼π‘₯𝑦 𝐼=( ), (5) 𝐼𝑦π‘₯ 𝐼𝑦𝑦 where 𝐼π‘₯π‘₯ and 𝐼𝑦𝑦 - are the principal moments of inertia, and 𝐼π‘₯𝑦 (or 𝐼𝑦π‘₯ since the inertia tensor is symmetric) - is the element representing the moment of inertia between the x and y axes. β€’ The grain aspect ratio, which indicates how closely a shape coincides with the rectangle described around it, is calculated using the formula (6): 𝐴𝑏 𝐴𝑅 = , (6) π΄π‘”π‘Ÿ where 𝐴𝑏 - is the area of the described grain rectangle. The closer the value of the coefficient is to 1 means the more rectangular the shape. In the ideal case, when the shape is a pure rectangle, this coefficient will be equal to 1. β€’ The grain compactness ratio is calculated using formula (7): 𝐴𝑐 Π‘π‘˜ = , (7) π΄π‘”π‘Ÿ where 𝐴𝑐 - is the area of the convex polygon that is described around the grain. This coefficient provides information on how close the grain is to a round or uniform shape: the larger the coefficient, the more compact the grain shape. β€’ The ratio of the area to the grain axes, which indicates how elliptical or circular the grain shape is, is calculated using formula (8): π΄π‘”π‘Ÿ 𝐸= . (8) 𝑆π‘₯ βˆ™ 𝑆𝑦 β€’ The ratio of the inertia tensor to the grain area, which indicates the mass distribution relative to the geometric properties of the grain, is calculated using formula (9): 𝐼 πΌπ‘Žπ‘Ÿπ‘’π‘Ž = . (9) π΄π‘”π‘Ÿ During the research, an issue arose concerning the compatibility of existing image processing algorithms, which were primarily tailored for analyzing two-dimensional images, with the three- dimensional microstructures generated. To address this challenge, the approach involved partitioning the three-dimensional microstructure into layers, each of a single voxel thickness, as a preliminary step before the analysis of grain properties. This partitioning effectively transforms the problem into a series of two-dimensional image sets, facilitating subsequent processing procedures. Figure 1: Arbitrary grain with labels for minor and major axes and orientation angle The generated microstructure is depicted in Figure 2, while the experimental microstructure is shown in Figure 3. These images will be utilized in the study for characterization and comparison purposes. Figure 2: Generated microstructure Figure 3: Experimental microstructure 3.2. Calculating and visualizing statistical characteristics As part of the study, statistical characteristics were calculated for the results of the grain characteristics analysis. For each of the characteristics obtained by software, the mean (10), standard deviation (11), median (12), mode, range (13), and interquartile range (14) were calculated. β€’ The average value is calculated as the arithmetic mean of the characteristic values for each grain using the formula (10): βˆ‘π‘›π‘–=1 π‘₯𝑖 πœ‡= , (10) 𝑛 where π‘₯𝑖 - is the value of the characteristic for each grain, 𝑛 - is the number of grains, and 𝑖 - belongs to the set of integers. β€’ The standard deviation is defined as the square root of the variance using formula (11): βˆ‘π‘› (π‘₯𝑖 βˆ’ πœ‡)2 𝜎 = √ 𝑖=1 , (11) 𝑛 where π‘₯𝑖 - is the value of the characteristic for each grain, 𝑖 - belongs to the set of integers, πœ‡ - is the average value, and 𝑛 - is the number of grains. β€’ The median for a data set of the form (π‘₯1, π‘₯2, . . . , π‘₯₁) is defined as (12): π‘₯𝑖+1 , 𝑖𝑓 𝑖 𝑖𝑠 π‘œπ‘‘π‘‘ 2 𝑀 = {π‘₯ 𝑖 + π‘₯ 𝑖 , (12) 2 2+1 , 𝑖𝑓 𝑖 𝑖𝑠 𝑒𝑣𝑒𝑛 2 where π‘₯𝑖 - are the values of the characteristic for each grain, ordered in ascending order, and 𝑖 - belongs to the set of integers. β€’ The mode (π‘€π‘œ) is the most frequent value in the data set. β€’ The range is the difference between the maximum and minimum values in the data set, determined by formula (13): π‘…π‘Žπ‘›π‘”π‘’ = π‘₯π‘šπ‘Žπ‘₯ βˆ’ π‘₯π‘šπ‘–π‘› , (13) where π‘₯π‘šπ‘Žπ‘₯ - is the maximum value in the dataset, and π‘₯π‘šπ‘–π‘› - is the minimum value. β€’ The interquartile range is the difference between the third (75%) and first (25%) quartiles in the dataset, determined by the formula (14): 𝐼𝑄𝑅 = 𝑄3 βˆ’ 𝑄1 , (14) where 𝑄3 - is the third quartile, and 𝑄1 - is the first. After these statistics were calculated, the data were visualized using violin plots. This method made it possible to compare the distribution of grain property values in the generated and real microstructures, providing an opportunity to conclude the interaction and characteristics of the grains. To build a violin chart, the data is first processed, including filtering by the selected characteristic. Then, the data is prepared for display, namely, it is combined into one DataFrame, where the category (generated or real grains), the name of the property, and its value are indicated. The next step is to build the graph itself using the Matplotlib and Seaborn libraries. In a scatterplot, each grain property has its distribution of values for the generated and real grains. Adding statistical information such as the mean, standard deviation, and median helps to better understand the distribution of the data. 4. Testing 4.1. Testing image processing methods One of the objectives of the study is to test the methods of processing images obtained from the experiment and generated artificially. The testing process involves the experimental application of various in-age processing and analysis algorithms to accurately determine the characteristics of the microstructural elements of a material. It is primarily used to study the properties of material grains. The test results indicate the effectiveness of the chosen approach and the possibility of its application in further research in this area. To achieve these goals, four images of different sizes were generated (Fig. 2-5), containing the same grain. Each image includes one grain, which is the same for all images. The first two samples consist of square grains of 50β¨―50 pixels each, with sample sizes of 200β¨―200 and 250β¨―250 pixels, respectively (Fig. 2 and Fig. 3). The third and fourth samples contain round grains with a radius of 50 pixels each. The overall dimensions of the studied images are 200β¨―200 (Fig. 4) and 300β¨―300 pixels (Fig. 5). For each image, the grain characteristics such as area, normalized area, shape factor, equivalent circle radius, orientation angle, scale factor, and inertia tensor were calculated according to (1)-(9). The calculated values of the characteristics were compared with the analytically calculated values to verify the correctness of the image processing. The results of the calculated characteristics are shown in Table 1. Analyzing the results, it can be seen that the values of the characteristics do not depend on the size of the age, so they can be compared for further study and matching the generated structures to the experimental ones. Additionally, the calculation of the relative error for the diverse grain characteristics acquired from the analysis is presented in Table 1. The relative error is determined through the comparison between the software-calculated value of the characteristic and the analytically measured value. Elevated relative error values signify substantial deviations between measurements, whereas lower values suggest relatively precise measurements. In general, the analysis results show very good agreement between the values obtained analytically and by software for most grain characteristics. Figure 4: A 200β¨―200 pixel sample with Figure 6: A 200β¨―200 pixel sample with 50β¨―50 pixel square grains round grains of 50 pixels radius Figure 5: A 250β¨―250 pixel sample with Figure 7: A 300β¨―300 pixel sample with 50β¨―50 pixel square grains round grains of 50 pixels radius For example, for the characteristics π΄π‘”π‘Ÿ and 𝐴𝑛 the discrepancy between analytical and artificial values does not exceed 1%, which indicates the high accuracy of the analysis methods. However, for the characteristics 𝐢𝑠 , and π‘’π‘π‘Ÿ which reflect the shape and size of the grain, the discrepancies between analytical and software values are much larger, reaching almost 15% for 𝐢𝑠 and 3.7% for π‘’π‘π‘Ÿ in some cases. These deviations, especially in the case of 𝐢𝑠 characteristic, may be the result of inaccurate calculation of the grain perimeter. This indicates the need to improve image processing methods, in particular, to adapt algorithms to the peculiarities of grain shape and size. Further research is aimed at improving the methods for calculating these characteristics to provide more accurate results. 4.2 Analysis of the statistical characteristics of the distribution of grain properties One of the key tasks in materials science is to analyze the microstructures of materials to study their mechanical properties and behavior. To do this, it is important to identify the relationship between the characteristics of microstructure grains and material properties. A large number of methods are used in modern science to analyze microstructures, among which one of the most powerful tools is violin plots. Violin plots are an effective tool for comparing the distribution of grain characteristics between generated and experimental microstructures. In each scatter plot, the distribution of grain characteristics for the generated microstructures is shown on the left and for the experimental microstructures on the right. In addition, the graph also provides statistical information such as the mean, standard deviation, and median, according to (10)-(12), which provides additional context for comparing the distributions. In this paper, violin plots are used to compare the distribution of normalized grain area (Fig. 6), grain scale factor (Fig. 7), grain shape factor (Fig. 8), equivalent grain circle radius (Fig. 9), grain orientation angle (Fig. 10) and other characteristics (Fig.11-19). This allows researchers to gain a deeper understanding of the microstructure of the material and its impact on material properties. Thus, the use of violin plots to compare the distribution of grain characteristics in generated and experimental microstructures is a powerful tool in materials science and mechanics research. Table 1 Comparison of characteristics Figure 2 Figure 3 Figure 4 Figure 5 Error Error Error Error Analyti Prog Analyti Progr Analyti Progr Analytic Progr cal ram cal am cal am al am Size, 200 Γ— 200 250 Γ— 250 200 Γ— 200 300 Γ— 300 px Agr 0.4% 0.4% 0% 0% , 2500 2500 2500 2500 7854 7825 7854 7825 px 0.3% 0.2% 0% 0% An 0.06 0.06 0.04 0.04 0.2 0.196 0.09 0.087 Pgr 0.5% 0.5% 8.2% 8.2% , 200 199 200 199 314.2 340 314.2 340 px 0.79 1.1% 1.1% 15% 15% Cs 0.785 0.785 0.793 1 0.851 1 0.851 3 0.14 0.2% 3.7% 0% 0% ecr 0.141 0.113 0.113 0.25 0.249 0.16 0.166 1 πœ“, 0% 0% 0% 0% ra Β±0.79 -0.79 Β±0.79 -0.79 Β±0.79 -0.79 Β±0.79 -0.79 d 0% 0.02% 0% 0.02% 0% 0% Sc 1 1 1 1 1 1 1 1 208. 3.7% 3.7% 𝐼π‘₯π‘₯ 208.3 208.3 208.2 625 622.7 625 622.7 2 1.5% 0.9% 1.5% 0.9% 0% 0% AR 1 1 1 1 1.27 1.25 1.27 1.25 0% 0% πΆπ‘˜ 1 1 1 1 1.001 1.011 1.001 1.011 50% 50% 0% 0% 𝐸 0.5 0.75 0.5 0.75 0.79 0.785 0.79 0.785 𝐼π‘₯π‘₯ 0.08 1.3% 1.3% 0% 0% 0.083 0.083 0.083 0.079 0.08 0.079 0.08 π΄π‘”π‘Ÿ 3 After constructing the violin plots, a comparative analysis of the statistical characteristics of the distribution of grain properties in real and generated microstructures has been carried out. The analysis conducted facilitated the identification of similarities and differences between both types of microstructures, enabling an assessment of the compliance of the generated microstructures with real conditions. The data obtained will be used to further improve the image processing algorithms and virtual reconstruction of grain microstructures. Information on the analysis of statistical characteristics is presented in Table 2. Conclusions Throughout this study, the objectives have been attained, yielding significant results conducive to the advancement of image processing methodologies and the analysis of material microstructures. Figure 8: Comparison of normalized grain Figure 9: Comparison of grain-scale factor area distributions distributions Figure 10: Comparison of grain shape factor Figure 11: Comparison of the distributions of distributions the grain equivalent circle radius Figure 12: Comparison of grain orientation Figure 13: Comparison of grain moment of angle distributions inertia distributions Figure 14: Comparison of grain moment of Figure 15: Comparison of grain aspect ratio inertia distributions between grain axes distributions Figure 16: Comparison of grain compactness Figure 17: Comparison of the distribution of ratio distributions the ratio of the area to the grain axes Figure 18: Comparison of distributions of the Figure 19: Comparison of distributions of the ratio of the main moment of inertia to the ratio of the moment of inertia between the grain area axes to the grain area corresponding to individual grains in the material microstructure. The successful testing of these First, image processing algorithms were developed to automatically detect regions algorithms on test images enabled the accurate determination of various characteristics of each Generated 0.005 0.179 0.018 0.766 0.38 3.705 1.864 0.276 0.114 0.061 0.025 0.036 IQR Real 0.004 0.091 0.022 1.855 0.744 90.32 42.49 0.23 0.091 0.051 0.028 0.047 Generated 0.011 0.981 0.048 2.047 1.556 10.47 5.869 1.116 0.386 0.236 0.123 0.113 Range Real 0.008 0.384 0.045 3.135 2.168 184 207.9 0.755 0.243 0.113 0.063 0.103 grain, including area, shape factor, orientation angle, and so forth. Generated 0.005 0.785 0.04 0 2.45 0.188 0 1.5 1.25 0.817 0.047 0 Mode Real 0 0.354 0.007 -1.566 1.133 3.151 -156.4 1.331 1.084 0.652 0.031 -0.069 Generated 0.006 0.574 0.044 -0.114 1.425 4.584 0.194 1.597 1.185 0.72 0.075 0.005 Median Real 0.004 0.617 0.034 -1.199 1.788 87.17 -15.45 1.699 1.155 0.719 0.056 -0.02 Generated 0.003 0.151 0.012 0.533 0.307 2.454 1.339 0.206 0.08 0.044 0.019 0.024 deviation Standard Real 0.002 0.102 0.013 1.138 0.52 50.94 47.31 0.187 0.064 0.032 0.019 0.028 Statistical summary table Generated 0.006 0.561 0.042 -0.109 1.488 4.537 0.229 1.614 1.195 0.713 0.076 0.004 Mean Real 0.003 0.579 0.030 -0.574 1.95 82.61 -26.06 1.708 1.165 0.718 0.061 -0.022 Table 2 π΄π‘”π‘Ÿ π΄π‘”π‘Ÿ 𝐼π‘₯𝑦 𝐼π‘₯π‘₯ ecr 𝐼π‘₯𝑦 𝐼π‘₯π‘₯ AR πΆπ‘˜ An Cs Sc πœ“ 𝐸 The resulting grain characteristics were further analyzed and it has been found that dimensionless characteristics, such as normalized area, equivalent to the radius of a grain circle, which is determined based on the normalized area, are most suitable for more efficient comparison of microstructures. The study also showed that other dimensionless quantities, such as the ratio of the inertia tensor to the grain area, the grain wrapping ratio, the ratio of the area to the principal grain axes, and the grain scale factor, are very useful for comparing microstructures, as they will not depend on the size of the image itself. Also, when comparing the characteristics calculated analytically and software, it has been found that grain properties calculated using the perimeter have a larger error, so it is recommended to avoid characteristics such as the grain shape coefficient and use characteristics defined as a ratio to the area, such as the ratio of the inertia tensor to the grain area. Our study also included the development of an algorithm for comparing grain characteristic distributions based on the analysis of violin plots and the comparison of statistical properties of the distributions. This algorithm will be used to further tune the generation of microstructures using the MatViz3D software package. The results obtained are an important step towards the further development of image processing methods and virtual reconstruction of grain microstructures. They can be used in further research in the field of materials science and mechanics to gain new knowledge and develop new materials with improved properties. Acknowledgments This work has been supported by the Ministry of Education and Science of Ukraine in the framework of the realization of the research project β€œAlgorithms, models, and tools of artificial intelligence for two-level modeling of complex materials behavior for dual-use technologies” (State Reg. Num. 0124U000450). References [1] X. Zeng, Ch. Liu, Ch. Zhao, J. Dong, F. Roters, D. Guan Three-dimensional study of grain scale tensile twinning activity in magnesium: A combination of microstructure characterization and mechanical modeling. Acta Materialia, 2023, 255, 119043. https://doi.org/10.1016/j.actamat.2023.119043 [2] М. Sitko, M. Mojzeszko, L. Rychlowski, G. Cios, P. Bala, K. Muszka, L. Madej Numerical procedure of three-dimensional reconstruction of ferrite-pearlite microstructure data from SEM/EBSD serial sectioning. Procedia Manufacturing, 2020, 47, pp. 1217-1222. https://doi.org/10.1016/j.promfg.2020.04.183 [3] P. Seibert, A. Raßloff, K. A. Kalina, J. Gussone, K. Bugelnig, M. Diehl, M. KΓ€stner Two-stage 2D- to-3D reconstruction of realistic microstructures: Implementation and numerical validation by effective properties. Computer Methods in Applied Mechanics and Engineering, 2023, 412, 116098. https://doi.org/10.1016/j.cma.2023.116098 [4] GarcΓ­a-GarcΓ­a, V., MejΓ­a, I. and Reyes-CalderΓ³n, F. Two-dimensional Monte Carlo–Voronoi simulation of grain growth and nucleation in the heat affected zone of TWIP-Ti welds. Materialia, 2019 5, 100223. doi: 10.1016/j.mtla.2019.100223 [5] Z. Li, J. Wang, H. Huang, Grain boundary curvature based 2D cellular automata simulation of grain coarsening. Journal of Alloys and Compounds, 2019, 791, pp. 411–422. doi: 10.1016/j.jallcom.2019.03.195 [6] H. L. Ding, Y. Z. He, L.F. Liu, W. J. Ding, Cellular automata simulation of grain growth in three dimensions based on the lowest-energy principle. Journal of Crystal Growth, 2006, 293(2), pp. 489–497. doi: 10.1016/j.jcrysgro.2006.05.060 [7] M. Sitko, Q. Chao, J. Wang, K. Perzynski, K. Muszka, L. Madej, A parallel version of the cellular automata static recrystallization model dedicated for high performance computing platforms – Development and verification. Computational Materials Science, 2020, 172, 109283. doi: 10.1016/j.commatsci.2019.109283 [8] O. Vodka, Computer modeling of microstructures with probabilistic cellular automata method using different nucleation rate functions, CMIS, 2020, pp. 450-461 doi: 10.32782/cmis/2608-34 [9] A. N Hytowitz, Review of using the Dyop optotype for acuity and refractions per the article. Journal of Optometry, 2023, 16(4), pp. 317-318. doi: 10.1016/j.optom.2022.12.002 [10] M. Bakhtiari, M. S. Salehi, Reconstruction of deformed microstructure using cellular automata method. Computational Materials Science, 2018, 149, pp. 1–13. doi: 10.1016/j.commatsci.2018.02.053 [11] Y. C. Lin, Y.-X. Liu, M.-S. Chen, M.-H. Huang, X. Ma, Z.-L. Long, Study of static recrystallization behavior in hot deformed Ni-based superalloy using cellular automaton model. Materials & Design, 2016, 99, pp. 107–114. doi: 10.1016/j.matdes.2016.03.050 [12] N. Maazi, R. Boulechfar, A modified grain growth Monte Carlo algorithm for increased calculation speed in the presence of Zener drag effect. Materials Science and Engineering: B, 2019, 242, pp. 52–62. doi: 10.1016/j.mseb.2019.03.003 [13] J. Melville, V. Yadav, L. Yang, A. R. Krause, M. R. Tonks, J. B. Harley, A new efficient grain growth model using a random gaussian-sampled mode filter. Materials & Design, 2023, 112604. doi: 10.1016/j.matdes.2023.112604 [14] J. Pu, N. S. Gezer, S. Ren, A. O. Alpaydin, E. R. Avci, M. Risbano, B. Rivera-Lebron, S. Y.-W. Chan, J. K. Leader, Automated detection and segmentation of pulmonary embolisms on computed tomography pulmonary angiography (CTPA) using deep learning but without manual outlining. Medical Image Analysis, 2023, 102882. doi: 10.1016/j.media.2023.102882 [15] X. Xu, Z. Yu, W.-Y. Chen, A. Chen, A. Motta, X. Wang, Automated analysis of grain morphology in TEM images using convolutional neural network with CHAC algorithm. Journal of Nuclear Materials, 2024, 588, 154813. doi: 10.1016/j.jnucmat.2023.154813 [16] Ma, Q. and Wang, Z. Characterizing heterogenous microstructures of fiber-reinforced composite materials using an advanced image processing-based approach through optical microscopic images. Manufacturing Letters, 2023, 35, 1163–1172. doi: 10.1016/j.mfglet.2023.08.123 [17] Sawai, K., Chen, T.-T., Sun, F., Ogawa, T. and Adachi, Y. Image regression analysis for linking the microstructure and property of steel. Results in Materials, 2024, 21, 100526. doi: 10.1016/j.rinma.2023.100526 [18] Gao, P., Lv, Z., Song, Y., Song, M. and Qian, P. Evolution of morphology and microstructure of coarsened nanoporous gold studied by automatic thresholding and image recognition algorithms. Scripta Materialia, 2023, 226, 115256. doi: 10.1016/j.scriptamat.2022.115256 [19] Ding, Y., Camanho, P. P. and Silva, A. Comparison of three algorithms generating virtual microstructures in terms of the degree of randomness. Composites Part A: Applied Science and Manufacturing, 2023, 107959. doi: 10.1016/j.compositesa.2023.107959 [20] Cai, C., Zhang, T., Wang, X., Yin, W., Xu, Z., Wang, R. and He, X. A versatile and highly efficient algorithm to generate representative microstructures for heterogeneous materials. Composites Science and Technology, 2023, 110138. doi: 10.1016/j.compscitech.2023.110138 [21] CLEMEX VISION, P. E. Clemex intelligent microscopy, Quebec, Canada. [22] Schindelin, J., Arganda-Carreras, I., Frise, E., Kaynig, V., Longair, M., Pietzsch, T., … Cardona, A. (2012). Fiji: an open-source platform for biological-image analysis. Nature Methods, 9(7), 676–682. doi:10.1038/nmeth.2019