Advanced computer vision algorithm for extraction of microstructural features from BSE images of powder metallurgical microstructures - Harikrishna, Katika; Sen, Binayak; Nithin, Abeyram; Davidson, Maharajan Joseph; Bhowmik, Abhijit (International journal of advanced manufacturing technology, 2025)
Manual methods for measuring grain size are often time-consuming and labor-intensive, as grain size analysis is essential for understanding material properties. This research introduces an innovative method leveraging Python libraries such as OpenCV, SciPy, and NumPy to automate the segmentation and extract microstructural features such as grain, grain boundary, edge grains and pores in backscattered electron (BSE) images. The analysis of BSE images presents several challenges, including noise, inconsistent contrast, improper thresholding, merged grains, edge grain exclusion, and accurate grain boundary identification. To overcome these obstacles, advanced image processing strategies were employed. Gaussian filtering with mean of (9,9) and σ = 1 optimized to minimize noise, and Contrast Limited Adaptive Histogram Equalization (CLAHE) with a tile grid size of (8,8) and clip limit of L c = 4.0 improved local contrast, enhancing the visibility of grain boundaries. Otsu's method for automated thresholding enabled effective differentiation between grains and their boundaries, while morphological techniques (erosion and dilation) with kernel size of 2 and two iterations further separated merged grains. Edge grains were removed using the cv2.floodFill() function, and the distance transform function precisely defined the grains and boundaries. Connected components analysis was applied to label distinct regions, helping determine the grain count. The proposed algorithm was evaluated on various BSE images to assess its robustness, with results compared against manual grain size measurements based on ASTM standards. Pearson correlation analysis confirmed that the error remained within acceptable limits, and the correlation coefficient of 0.98 highlighted the algorithm's high accuracy in predicting grain sizes with consistent precision.