A method and device for metallographic microscopic image analysis excluding interference of precipitates

By pre-setting grain boundary and precipitate segmentation models, misdivided grains in metallographic micrographs are screened and corrected, solving the problem of precipitate boundaries being misidentified as grain boundaries and improving the accuracy and efficiency of grain boundary segmentation.

CN116630248BActive Publication Date: 2026-03-20UNIV OF SCI & TECH BEIJING
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-05-08
Publication Date
2026-03-20

AI Technical Summary

Technical Problem

Existing grain boundary segmentation methods are prone to misidentifying precipitated phase boundaries as grain boundaries, which affects the grain boundary reconstruction effect.

Method used

A pre-defined grain boundary and precipitate segmentation model was used to obtain preliminary segmentation results of metallographic material microscopic images. By screening and correcting missegmented grains, a redistribution strategy was used to correct the problem of misidentifying precipitate boundaries as grain boundaries.

Benefits of technology

It improves the accuracy of grain boundary segmentation, achieves efficient and precise grain boundary and precipitate segmentation, and corrects the grain boundary missegmentation problem caused by precipitate shading.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116630248B_ABST
    Figure CN116630248B_ABST
Patent Text Reader

Abstract

The application discloses a metallographic microscopic image analysis method and device for excluding interference of precipitated phases, and the method comprises the following steps: obtaining a grain boundary segmentation result of a metallographic material microscopic image based on a preset grain boundary segmentation model; obtaining a precipitated phase segmentation result of the metallographic material microscopic image based on a preset precipitated phase segmentation model; screening out misclassified grains that misidentify precipitated phases as grains based on the grain boundary segmentation result and the precipitated phase segmentation result; correcting the misclassified grains to synthesize a correct segmentation result. The metallographic microscopic image analysis scheme of the application can specifically correct the problem of misjudgment of grain boundary caused by the shielding of grain boundary by precipitated phases in the metallographic image analysis task, further improves the accuracy of subsequent material microstructure characterization, can be widely applied to image analysis, material evaluation and other aspects in the field of metal materials, and has a wide application prospect.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of metallographic image analysis, and in particular to a metallographic microscopic image analysis method and device for excluding interference of precipitated phases. BACKGROUND

[0002] In the research field of material science, the microstructure of materials plays an irreplaceable role in the research of processing technology, organization development, physical and mechanical properties, etc. of materials. Scientific and quantitative characterization of material microstructure is a core problem in the field of material science.

[0003] In recent years, the interdisciplinary research of material science and artificial intelligence has been highly valued by countries around the world. Because the analysis and information extraction depending on artificial experience can lead to the omission of important information of material microstructure, and the microstructure of materials is usually presented in the form of unstructured image data, therefore, accurately and intelligently extracting microstructure information in material microstructure images through image segmentation methods in the field of computer vision has become a hot direction of interdisciplinary research between computer science and material science. And using image segmentation methods based on deep learning, on the basis of low-dimensional features learned by traditional methods, further learning the topological structure of material microstructure images can more accurately and efficiently extract key information in material images, which is a popular trend of current research.

[0004] However, for metallographic image analysis tasks, precipitated phases will be generated at the grain boundaries during the grain growth process, which can easily lead to the error of the metallographic segmentation model based on deep learning to consider the precipitated phase boundary as the grain boundary, affecting the subsequent grain boundary reconstruction effect. Therefore, there is an urgent need for a correction method to exclude the interference of precipitated phases and obtain correct segmentation results. SUMMARY

[0005] The present application provides a metallographic microscopic image analysis method and device for excluding the interference of precipitated phases, to solve the technical problem of misidentifying precipitated phase boundaries as grain boundaries by existing grain boundary segmentation methods.

[0006] To solve the above technical problems, the present application provides the following technical solutions:

[0007] On the one hand, the present application provides a metallographic microscopic image analysis method for excluding the interference of precipitated phases, which comprises:

[0008] obtaining a grain boundary segmentation result of the metallographic material microscopic image based on a preset grain boundary segmentation model;

[0009] obtaining a precipitated phase segmentation result of the metallographic material microscopic image based on a preset precipitated phase segmentation model;

[0010] screening out misclassified grains based on the grain boundary segmentation result and the precipitated phase segmentation result; wherein the misclassified grain refers to a case that the precipitated phase is misidentified as a grain in the grain boundary segmentation result;

[0011] correcting the misclassified grains to synthesize a correct segmentation result.

[0012] Further, the grain boundary segmentation result of the metallographic material microscopic image is obtained based on a preset grain boundary segmentation model, comprising:

[0013] a grain boundary pre-segmentation result of the metallographic material microscopic image is obtained by using a preset grain boundary segmentation model;

[0014] the grain boundary pre-segmentation result is post-processed to process the grain boundary to be complete, closed and consistent in boundary width, to obtain the grain boundary segmentation result; wherein the post-processing includes dilation, erosion and skeletonization operations.

[0015] Further, the precipitated phase segmentation result of the metallographic material microscopic image is obtained based on a preset precipitated phase segmentation model, comprising:

[0016] a precipitated phase pre-segmentation result of the metallographic material microscopic image is obtained by using a preset precipitated phase segmentation model;

[0017] the precipitated phase pre-segmentation result is post-processed to filter out small target noise in the precipitated phase pre-segmentation result and remove small gaps appearing inside the precipitated phase pre-segmentation result; wherein the post-processing includes noise filtering, dilation and erosion operations.

[0018] Further, misclassified grains are screened out based on the grain boundary segmentation result and the precipitated phase segmentation result, comprising:

[0019] the grain boundary segmentation result is analyzed by using a connected region division method to obtain a grain subset;

[0020] the precipitated phase segmentation result is analyzed by using a connected region division method to obtain a precipitated phase subset;

[0021] the grains in the grain subset are matched with the precipitated phases in the precipitated phase subset one by one, and if the area coincidence degree of a grain and a precipitated phase is higher than a preset threshold, it is considered that the matching of the two is successful;

[0022] all the matched grains are marked as misclassified grains.

[0023] Further, the misclassified grains are corrected to synthesize a correct segmentation result, comprising:

[0024] for each misclassified grain, all non-misclassified grains adjacent thereto are found based on the relationship between the current misclassified grain and the surrounding grains;

[0025] distributing pixels of the misclassified grains to the non-misclassified grains by using a preset redistribution strategy; wherein the preset redistribution strategy is a combination of any one or more of a watershed and graph cut.

[0026] In another aspect, the present application also provides a metallographic micrograph analysis device for excluding interference of precipitates, comprising:

[0027] a grain boundary extraction module, configured to obtain a grain boundary segmentation result of a metallographic material micrograph based on a preset grain boundary segmentation model;

[0028] a precipitate phase extraction module, configured to obtain a precipitate phase segmentation result of the metallographic material micrograph based on a preset precipitate phase segmentation model;

[0029] a misclassified grain screening module, configured to screen out misclassified grains based on the grain boundary segmentation result output by the grain boundary extraction module and the precipitate phase segmentation result output by the precipitate phase extraction module; wherein the misclassified grains refer to cases where the precipitate phase is misidentified as a grain in the grain boundary segmentation result;

[0030] a misclassified grain redistribution module, configured to correct the misclassified grains and synthesize a correct segmentation result.

[0031] Further, the grain boundary extraction module is specifically configured to:

[0032] obtain a grain boundary pre-segmentation result of the metallographic material micrograph by using a preset grain boundary segmentation model;

[0033] post-process the grain boundary pre-segmentation result to process the grain boundary to be complete, closed and consistent in boundary width, to obtain the grain boundary segmentation result; wherein the post-processing includes dilation, erosion and skeletonization operations.

[0034] Further, the precipitate phase extraction module is specifically configured to:

[0035] obtain a precipitate phase pre-segmentation result of the metallographic material micrograph by using a preset precipitate phase segmentation model;

[0036] post-process the precipitate phase pre-segmentation result to filter out small target noise in the precipitate phase pre-segmentation result and remove small gaps appearing inside the precipitate phase pre-segmentation result; wherein the post-processing includes noise filtering, dilation and erosion operations.

[0037] Further, the misclassified grain screening module is specifically configured to:

[0038] analyze the grain boundary segmentation result by using a connected region division method to obtain a grain subset;

[0039] The precipitation phase subset is obtained by using a connected region division method to analyze the precipitation phase segmentation result.

[0040] The grains in the grain subset are matched with the precipitation phases in the precipitation phase subset one by one, and if the area coincidence degree of a grain and a precipitation phase is higher than a preset threshold, it is considered that the grain and the precipitation phase are matched successfully.

[0041] All the matched grains are marked as misclassified grains.

[0042] Further, the misclassified grain reassignment module is specifically used for:

[0043] Based on the relationship between the current misclassified grain and the surrounding grains, for each misclassified grain, all non-misclassified grains adjacent thereto are found.

[0044] The pixels occupied by the misclassified grain are distributed to the non-misclassified grains by using a preset reassignment strategy; wherein the preset reassignment strategy is a combination of any one or more of watershed and graph cut.

[0045] In another aspect, the present application also provides an electronic device comprising a processor and a memory; wherein the memory stores at least one instruction, which is loaded and executed by the processor to implement the above method.

[0046] In another aspect, the present application also provides a computer readable storage medium, which stores at least one instruction, which is loaded and executed by the processor to implement the above method.

[0047] The technical solution provided by the present application has at least the following beneficial effects:

[0048] The present application preliminarily segments the metallographic material microscopic image to obtain the grain boundary and precipitation phase pre-segmentation result; then according to the grain boundary pre-segmentation result and the precipitation phase pre-segmentation result, the misclassified grains that need to be corrected are screened out based on the overlap degree of the precipitation phase and the grain, and finally based on the relationship between the current misclassified grain and the surrounding grains, the pixels occupied by the misclassified grain are distributed to the non-misclassified grains by using a reassignment strategy to correct the problem of misidentifying the precipitation phase boundary as the grain boundary. Thus, the grain boundary segmentation accuracy is improved. The present application realizes efficient extraction of the grain boundary and precipitation phase segmentation result in the metallographic material microscopic image, further corrects the misclassified grain boundary segmentation problem caused by the precipitation phase shielding, effectively improves the segmentation result, and realizes efficient and high-precision segmentation effect. BRIEF DESCRIPTION OF DRAWINGS

[0049] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the embodiments description. Obviously, the drawings in the following description only some embodiments of the present application, and for those skilled in the art, other drawings can also be obtained without creative labor based on these drawings.

[0050] Figure 1 is the execution flow diagram of the metallographic microscopic image analysis method for excluding precipitate phase interference provided by the embodiments of the present application;

[0051] Figure 2 is the nickel-based superalloy microscopic image original drawing-grain boundary-precipitate phase diagram; wherein, (a) is the nickel-based superalloy microscopic image original drawing diagram; (b) is the nickel-based superalloy microscopic image grain boundary annotation diagram; (c) is the nickel-based superalloy microscopic image precipitate phase annotation diagram;

[0052] Figure 3 is the structure diagram of the grain boundary / precipitate phase segmentation network provided by the embodiments of the present application;

[0053] Figure 4 is the effect diagram before and after the precipitate phase misclassification boundary correction effect;

[0054] Figure 5 is the metallographic microscopic image analysis device block diagram for excluding precipitate phase interference provided by the embodiments of the present application. DETAILED DESCRIPTION

[0055] In order to make the purpose, technical solutions and advantages of the present application more clear, the following will further describe the embodiments of the present application in combination with the drawings.

[0056] First embodiment

[0057] In order to solve the problem that the existing grain boundary segmentation method misrecognizes the precipitate phase boundary as the grain boundary, the present embodiment provides a metallographic microscopic image analysis method for excluding precipitate phase interference, which realizes the grain boundary and precipitate phase segmentation and the post-processing of misclassified grain correction for the metallographic microscopic image with precipitate phase shielding problem. The method can be realized by an electronic device. The execution flow of the method is as shown in Figure 1 The method comprises the following steps:

[0058] S1, obtaining the grain boundary segmentation result of the metallographic material microscopic image based on a preset grain boundary segmentation model;

[0059] Specifically, in the present embodiment, the implementation process of S1 is as follows:

[0060] S11, obtaining the grain boundary pre-segmentation result of the metallographic material microscopic image by using a preset grain boundary segmentation model;

[0061] It should be noted that the grain boundary segmentation model is used to extract the grain boundary portion in microscopic images of metallographic materials. It can employ any of the following models: edge detection model, threshold segmentation model, or deep learning model.

[0062] In this embodiment, since medical images and material images are characterized by simple semantics, simple structure, and small datasets, the classic image segmentation network U-Net is used for image segmentation. The design of U-shaped network and feature map stitching can make full use of the semantic information in the small dataset, thereby accurately determining the grain boundary part in the image. Of course, it should be understood that this is only a preferred design for this embodiment, and this embodiment does not limit the specific type of grain boundary segmentation model.

[0063] S12, Post-process the grain boundary pre-segmentation result to make the grain boundaries complete, closed and with consistent boundary width, to obtain the grain boundary segmentation result; wherein, the post-processing includes expansion, etching and framework operations;

[0064] It should be noted that the conventional post-processing method for grain boundaries involves the following steps: The pre-segmentation results output by the grain boundary segmentation model are expanded to connect incompletely segmented grain boundaries. Then, erosion and framework operations are performed to process the grain boundaries until the boundary widths are consistent. Finally, the grain boundaries are expanded uniformly to facilitate visual inspection and correction, and subsequent grain reconstruction. Furthermore, to address the branching problem caused by incomplete grain boundary prediction, a pruning method using single-grain expansion is employed to remove the branched portions of the grain boundaries, resulting in complete and closed grain boundaries.

[0065] Specifically, in this embodiment, the input image of the grain boundary segmentation network is a microscopic image of a nickel-based superalloy material, and the labeled image is a grain boundary label. For example... Figure 2 As shown, Figure 2 Image (a) in the image is the original microscopic image of a nickel-based superalloy material. Figure 2 (b) in the image corresponds to the grain boundary portion annotated by experts. Figure 2 In the image, (c) represents the corresponding extracted phase portion annotated by experts. For example... Figure 2 As shown in (a) of the figure, there is a relatively obvious phenomenon of precipitates obscuring the grain boundaries, and there is also a problem of high similarity between the precipitate boundaries and the grain boundaries. In this embodiment, the dataset used includes a total of 20 original datasets with a pixel value of 2048*2048, which are divided into training set:validation set:test set = 7:1:2.

[0066] In the network training process, first, data preprocessing operation is performed. The input gray material microscopic image is preprocessed, including cropping, scaling and normalization, etc. to facilitate the subsequent network training and optimization. Then the image segmentation network is constructed. In this embodiment, U-Net network architecture is adopted, which includes encoder and decoder, as shown in Figure 3 The encoder is composed of multiple convolutional layers and pooling layers, which is used to extract image features. The decoder is composed of multiple up-sampling layers and convolutional layers, which is used to map the feature map back to the original image for segmentation. In the U-Net network, the encoder can gradually reduce the size of the feature map to extract deep-level feature information of the image. The decoder gradually recovers the size of the feature map through up-sampling and feature map splicing, and performs image segmentation. In the network training process, the U-Net network is supervised learning using the labeled segmentation label data. The balanced cross-entropy loss function is used to calculate the error between the network prediction value and the true label. The learning rate is set to 0.0001. The Adam optimizer is used for parameter optimization. The maximum epoch is set to 100. The loss function uses Balanced Cross-Entropy (BCE) Loss. The formula of BCE Loss function is as follows:

[0067]

[0068]

[0069] wherein, is the segmentation prediction map output by the network, is the true value image. is the factor used to balance the positive and negative samples, The formula of is as follows:

[0070]

[0071] Finally, the segmentation prediction is performed. When a new gray material microscopic image is segmented and predicted, the image is input into the trained U-Net network, and the network will output the segmentation result. Then through the binarization processing, the output image is divided into background and foreground two parts, so as to realize the accurate segmentation of the target region.

[0072] In the grain boundary segmentation result post-processing part, the embodiment first performs an expansion processing operation. The image directly output by the grain boundary segmentation network is subjected to expansion processing to connect the grain boundaries that are not completely segmented. Expansion is a morphological operation commonly used in image processing, which can expand the foreground objects in a binary image to connect adjacent grain boundaries. Through expansion processing, the broken parts of the grain boundaries can be connected to ensure the integrity of the grain boundaries. Then the expanded grain boundaries are subjected to skeletonization processing. Skeletonization is a morphological operation commonly used in image processing, which can change the foreground objects in a binary image into their skeletons to obtain specific boundary shapes, thereby facilitating subsequent processing. In the embodiment, through skeletonization processing, the grain boundaries can be processed to have consistent boundary widths, facilitating the reconstruction of the grains afterwards. In addition, the embodiment also adopts a pruning method of expanding and then eroding a single grain to remove the branches caused by incomplete grain boundary prediction, to obtain complete and closed grain boundaries. This method can ensure the accuracy and continuity of the grain boundaries and improve the precision and reliability of the grain reconstruction. Finally, the grain boundaries are subjected to moderate expansion to facilitate visual screening and correction.

[0073] S2, obtaining a precipitation phase segmentation result of the metallographic material microscopic image based on a preset precipitation phase segmentation model;

[0074] Specifically, in the embodiment, the implementation process of S2 is as follows:

[0075] S21, obtaining a precipitation phase pre-segmentation result of the metallographic material microscopic image by using a preset precipitation phase segmentation model;

[0076] It should be noted that the precipitation phase segmentation model is used to extract the precipitation phase part in the metallographic material microscopic image. It can be any one of an edge detection model, a threshold segmentation model or a deep learning model. In the embodiment, the precipitation phase segmentation model used is the same as the grain boundary segmentation model, both of which are U-Net networks. In addition, due to the characteristics of the close distribution of the precipitation phase and the easy adhesion of the segmentation result, in the specific training process, the loss function proposed in the U-Net network is adopted, the boundary is weighted according to the distance, the place close to the boundary is disposed with a higher weight, and a more accurate single precipitation phase segmentation result is obtained.

[0077] S22, performing post-processing on the precipitation phase pre-segmentation result to filter out small target noise in the precipitation phase pre-segmentation result and remove small gaps appearing in the precipitation phase pre-segmentation result; wherein the post-processing includes noise filtering, expansion and erosion operations;

[0078] It should be noted that the effect of the conventional post-processing method of the precipitated phase is to filter out small target noise in the result image directly output by the precipitated phase segmentation model, and to remove small gaps in the precipitated phase by erosion and expansion, so as to improve the segmentation accuracy of the precipitated phase.

[0079] Specifically, in the present embodiment, the input image of the precipitated phase segmentation network is a micrograph of a nickel-based superalloy material, and the labeled image is a precipitated phase label, as shown in Figure 2 The image processing method used is the same as the grain boundary segmentation process, as shown in Figure 3 .

[0080] In the training process, the learning rate is set to 0.0001, the Adam optimizer is used for parameter optimization, and the maximum epoch is set to 100. Due to the characteristics of the precipitated phase, such as mutual adhesion and easy adhesion, the U-Net Loss is used in the loss function selection of the training process to achieve the training effect of separating different precipitated phases. The U-Net Loss function formula is as follows:

[0081]

[0082] wherein, is the true label of each pixel, is a weight map that gives some pixels a more important position in training.

[0083]

[0084] wherein, is a weight map that balances class frequencies, represents the distance to the nearest precipitated phase boundary, represents the distance to the second nearest cell boundary.

[0085] In the present example, it is set that pixels, pixels.

[0086] In the precipitated phase segmentation result post-processing part, since the size of the precipitated phase is relatively uniform and there is no problem of too small precipitated phase, the present embodiment first uses the connected domain filtering method to filter out small connected domain regions in the precipitated phase pre-segmentation result as error segmentation noise; then, for the problem of incomplete segmentation in each precipitated phase, each precipitated phase individual is marked, and the operation of first expansion and then erosion is performed on each precipitated phase individual to eliminate the internal incomplete segmentation region; finally, the operation of first erosion and then small amplitude expansion is used to further separate the precipitated phases that may be adhered.

[0087] S3, screening out misclassified grains based on the grain boundary segmentation result and the precipitate segmentation result; wherein the misclassified grain refers to a case that a precipitate is misidentified as a grain in the grain boundary segmentation result;

[0088] Specifically, in the present embodiment, the implementation process of S3 is as follows:

[0089] S31, analyzing the grain boundary segmentation result by using a connected region division method to obtain a grain subset;

[0090] S32, analyzing the precipitate segmentation result by using a connected region division method to obtain a precipitate subset;

[0091] S33, matching the grains in the grain subset with the precipitates in the precipitate subset one by one, and if the area coincidence degree of a grain and a precipitate is higher than a preset threshold, it is considered that the matching is successful;

[0092] S34, identifying all the matched grains as misclassified grains;

[0093] It should be noted that S3 is to judge the grain area covered by each precipitate according to the precipitate segmentation result. If the overlap degree of the current precipitate and the grain exceeds the set threshold T, it means that the precipitate has caused interference to the grain boundary identification. At this time, the corresponding grain is determined as a misclassified grain that misidentifies the precipitate as a grain. For this, the next step of re-segmentation needs to be performed on this grain.

[0094] Based on the above, in the present embodiment, the specific processing process of S3 is as follows:

[0095] First, the grain boundary prediction result is reversed to obtain a grain effect image, and then each grain is marked with a serial number to obtain a grain set . The predicted precipitate image is also marked with a serial number to obtain a precipitate subset . For the marked precipitate image and grain image, all precipitates are traversed, and for a precipitate , the grains in all area overlapping regions on the grain segmentation image are counted to obtain a corresponding grain subset . Then all the area overlapping regions with the precipitate are traversed to determine whether the current grain is a misclassified result of the precipitate. For each overlapping grain , the index of the grain and the precipitate is calculated. In the present embodiment, is defined as follows:

[0096]

[0097] If the current grain is considered as normal segmentation, the judgment of the next overlapping grain is continued; otherwise, the current grain is considered as misidentified precipitate phase, and then it is re-allocated. In this embodiment, through multiple experimental effect determination, the threshold T is set to 0.9. for normal segmentation, the judgment of the next overlapping grain is continued; otherwise, the current grain is considered as misidentified precipitate phase, and then it is re-allocated. In this embodiment, through multiple experimental effect determination, the threshold T is set to 0.9. for normal segmentation, the judgment of the next overlapping grain is continued; otherwise, the current grain is considered as misidentified precipitate phase, and then it is re-allocated. In this embodiment, through multiple experimental effect determination, the threshold T is set to 0.9.

[0098] S4, correcting the misclassified grain to synthesize the correct segmentation result;

[0099] In this embodiment, the implementation process of S4 is as follows:

[0100] For the misclassified grain obtained by S3, the grain information around the misclassified grain is extracted, and based on the relationship between the current misclassified grain and the surrounding grains, the re-allocation strategy is used to allocate the pixels occupied by the misclassified grain to the non-misclassified grains, so as to correct the problem of misidentifying the precipitate phase boundary as the grain boundary and improve the accuracy of the grain boundary segmentation. The re-allocation strategy can include one or more of the methods such as watershed, graph cut, etc.

[0101] Specifically, in this embodiment, the grain that needs to be re-segmented obtained by S3 is re-allocated in the region. The process of re-allocation is as follows: first, the region of the grain to be segmented and the overlapping precipitate phase are determined. Then, the expansion region calculation is performed on the coverage regions of the precipitate phase and the grain , and then the original grain segmentation result is rectangularly cropped according to the expansion region position to determine the related non-misclassified grains and the operation region after re-allocation processing. When the target region is cropped, the cropping position (in this example, the recorded value is the upper left corner coordinates x and y of the rectangle) and the cropping size (in this embodiment, the recorded value is the width w and the height h of the rectangle) are recorded in order to splice the processing result back to the original segmentation result in the later stage. It should be noted that in this embodiment, the expansion region is realized by expanding 10 pixels up, down, left and right on the bounding_box region of the coverage region of the precipitate phase and the grain . The expansion region selection standard is to include the grain to be segmented and its adjacent grain set, and the specific method of selecting the expansion region is not limited in this embodiment.

[0102] Then, the grain is removed from the cropped target region, that is, the region of the grain is marked as background (label=0). Then, the original grain The region adopts a redistribution strategy to allocate the pixels occupied by the misclassified grains to the non-misclassified grains. The redistribution strategy can include one or more of watershed, graph cut, etc.

[0103] In this embodiment, the redistribution operation is implemented by a watershed operation. The watershed algorithm process is as follows:

[0104] First, all pixels in the gradient image are classified according to the gray value, and a geodesic distance threshold is set. Then, find the pixel point with the smallest gray value (default marked as the lowest gray value point), and let the threshold start growing from the minimum value. These points are the starting points. Then, during the growing process of the horizontal plane, it will encounter the surrounding neighborhood pixels, and measure the geodesic distance of these pixels to the starting point (the lowest gray value point). If it is less than the set threshold, these pixels will be flooded, otherwise a dam will be set on these pixels. In this way, the neighborhood pixels are classified. Finally, as the horizontal plane becomes higher and higher, more and higher dams will be set until the maximum value of the gray value, and all regions meet on the watershed line. These dams divide the entire image pixels.

[0105] The image after redistribution has realized the misclassified grains The region is redistributed to the related non-misclassified grains. Finally, for the re-segmented local image, according to the x, y coordinate values stored during the previous cropping, as well as the local width w and height h, the processed image is spliced back into the original image.

[0106] By repeatedly executing S3-S4, all precipitated phases and their overlapping grains are traversed, filtered, re-segmented and spliced, and the complete processing process of the method is completed. The final correction effect is as Figure 4 shown.

[0107] In summary, the embodiment provides a metallographic micrograph analysis method for excluding precipitated phase interference. The method performs preliminary segmentation on a metallographic material micrograph to obtain a grain boundary and precipitated phase preliminary segmentation result. Then, according to the grain boundary preliminary segmentation result and the precipitated phase preliminary segmentation result, based on the overlapping degree of the precipitated phase and the grain, misclassified grains that need to be corrected are selected. Finally, based on the relationship between the current misclassified grain and the surrounding grains, a redistribution strategy is used to allocate the pixels occupied by the misclassified grains to the non-misclassified grains, to correct the problem of misidentifying the precipitated phase boundary as a grain boundary. Thus, the grain boundary segmentation accuracy is improved. The method realizes efficient extraction of the grain boundary and precipitated phase segmentation result in the metallographic material micrograph, further corrects the misclassified grain boundary segmentation problem caused by the precipitated phase shielding, effectively improves the segmentation result, and realizes efficient and high-precision segmentation effect.

[0108] Second embodiment

[0109] The embodiment provides a metallographic microscopic image analysis device for excluding interference of precipitated phases, a system structure of the metallographic microscopic image analysis device for excluding interference of precipitated phases is as shown in the figure, and the metallographic microscopic image analysis device for excluding interference of precipitated phases comprises the following modules. Figure 5

[0110] A crystal boundary extraction module is configured to acquire a crystal boundary segmentation result of the metallographic material microscopic image based on a preset crystal boundary segmentation model.

[0111] A precipitated phase extraction module is configured to acquire a precipitated phase segmentation result of the metallographic material microscopic image based on a preset precipitated phase segmentation model.

[0112] A misclassified grain screening module is configured to screen out misclassified grains based on the crystal boundary segmentation result output by the crystal boundary extraction module and the precipitated phase segmentation result output by the precipitated phase extraction module, wherein the misclassified grains refer to cases that the precipitated phases are misidentified as grains in the crystal boundary segmentation result.

[0113] A misclassified grain reassignment module is configured to correct the misclassified grains and synthesize a correct segmentation result.

[0114] The metallographic microscopic image analysis device for excluding interference of precipitated phases in the embodiment corresponds to the metallographic microscopic image analysis method for excluding interference of precipitated phases in the first embodiment, the functions of the functional modules in the metallographic microscopic image analysis device for excluding interference of precipitated phases in the embodiment correspond to the flow steps in the metallographic microscopic image analysis method for excluding interference of precipitated phases, and thus, the functions of the functional modules in the metallographic microscopic image analysis device for excluding interference of precipitated phases in the embodiment will not be described herein.

[0115] Third embodiment

[0116] The embodiment provides an electronic device, which comprises a processor and a memory; wherein the memory stores at least one instruction, the instruction is loaded and executed by the processor to implement the method in the first embodiment.

[0117] The electronic device can be different in configuration or performance, and can comprise one or more than one processor (central processing unit, CPU) and one or more than one memory, wherein the memory stores at least one instruction, the instruction is loaded and executed by the processor to implement the method.

[0118] Fourth embodiment

[0119] ​The embodiment provides a computer readable storage medium, and at least one instruction is stored in the computer readable storage medium, the instruction is loaded and executed by a processor to implement the method in the first embodiment. The computer readable storage medium can be a ROM, a random access memory, a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like. The instruction stored therein can be loaded and executed by the processor in the terminal to implement the method.

[0120] In addition, it should be noted that the present application can be provided as a method, an apparatus or a computer program product. Therefore, the embodiments of the present application can be in the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Moreover, the embodiments of the present application can be in the form of a computer program product implemented on one or more computer-usable storage media containing computer-usable program code.

[0121] The embodiments of the present application are described with reference to flowcharts and / or block diagrams of the method, the terminal device (system) and the computer program product according to the embodiments of the present application. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and the combination of the flows and / or blocks in the flowcharts and / or block diagrams can be implemented by computer program instructions. These computer program instructions can be provided to a general-purpose computer, an embedded processor or other programmable data processing terminal device to produce a machine, so that the instructions executed by the computer or other programmable data processing terminal device produce an article of manufacture, including a machine, that implements the flowcharts and / or block diagrams. Figure 1 one or more flows and / or blocks Figure 1 an apparatus that performs the functions specified in one or more blocks or flows.

[0122] These computer program instructions can also be stored in a computer readable memory that can direct the computer or other programmable data processing terminal device to work in a specific manner, so that the instructions stored in the computer readable memory produce a product including instruction apparatus, which implements the flowcharts and / or block diagrams. Figure 1 one or more flows and / or blocks Figure 1 an apparatus that performs the functions specified in one or more blocks or flows. These computer program instructions can also be loaded into a computer or other programmable data processing terminal device, so that a series of operation steps are performed on the computer or other programmable terminal device to produce a computer implemented process, so that the instructions executed on the computer or other programmable terminal device provide a process for implementing the flowcharts and / or block diagrams. Figure 1 one or more flows and / or blocks Figure 1 an apparatus that performs the functions specified in one or more blocks or flows. These computer program instructions can also be loaded into a computer or other programmable data processing terminal device, so that a series of operation steps are performed on the computer or other programmable terminal device to produce a computer implemented process, so that the instructions executed on the computer or other programmable terminal device provide a process for implementing the flowcharts and / or block diagrams.

[0123] It is also noted that, as used herein, the terms "first", "second", and the like, merely designate a relationship or order of importance and do not necessarily indicate any such actual relationship or order of importance. The terms "comprises", "comprising", or any other variation thereof are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but can include other elements not expressly listed or inherent to such process, method, article, or apparatus. An element proceeded by "comprises... a" does not, without more constraints, exclude the existence of additional identical elements in the process, method, article, or apparatus that comprises the element.

[0124] Finally, it is noted that the foregoing description is of a preferred embodiment of the application, and that numerous changes and modifications can be made thereto without departing from the spirit and scope of the application as set forth in the appended claims.

Claims

1. A metallographic microscopic image analysis method that excludes interference from precipitates, characterized in that, include: Based on a pre-defined grain boundary segmentation model, the grain boundary segmentation results of the microscopic images of metallographic materials are obtained; Based on a preset precipitate segmentation model, the precipitate segmentation results of the microscopic images of metallographic materials are obtained; Based on the grain boundary segmentation results and the precipitate segmentation results, misidentified grains are screened out; wherein, misidentified grains refer to the cases in the grain boundary segmentation results where precipitates are mistakenly identified as grains; The misdivided grains are corrected to synthesize the correct segmentation result; The process of obtaining grain boundary segmentation results from metallographic material micrographs based on a preset grain boundary segmentation model includes: A pre-defined grain boundary segmentation model was used to obtain the grain boundary pre-segmentation results of the microscopic images of metallographic materials; The grain boundary pre-segmentation results are post-processed to make the grain boundaries complete, closed, and with consistent boundary widths, thus obtaining the grain boundary segmentation results; wherein, the post-processing of the grain boundary pre-segmentation results includes expansion, etching, and framework operations; The step of obtaining precipitate segmentation results from metallographic material micrographs based on a preset precipitate segmentation model includes: A pre-defined precipitate segmentation model was used to obtain the pre-segmentation results of precipitates in the microscopic images of metallographic materials; The pre-segmentation results of the precipitated phase are post-processed to filter out small target noise and remove small voids that appear inside the pre-segmentation results of the precipitated phase; wherein, the post-processing of the pre-segmentation results of the precipitated phase includes noise filtering, expansion and corrosion operations; Based on the grain boundary segmentation results and the precipitate segmentation results, erroneous grains are screened, including: The grain boundary segmentation results are analyzed using a connected region partitioning method to obtain the grain particle set; The precipitate segmentation results are analyzed using a connected region partitioning method to obtain a subset of precipitates; The grains in the grain particle set are matched one by one with the precipitates in the precipitate phase set. If the area overlap between the grains and the precipitates is higher than a preset threshold, the two are considered to be successfully matched. Mark all successfully matched grains as misaligned grains; Correcting the misdivided grains to synthesize a correct segmentation result includes: Based on the relationship between the current misaligned grain and its surrounding grains, for each misaligned grain, find all non-misaligned grains that are adjacent to it; A preset redistribution strategy is used to allocate the pixels occupied by the misaligned dies to the non-misaligned dies; wherein, the preset redistribution strategy is any one or more combinations of watershed and map cut.

2. A metallographic microscopic image analysis device for eliminating interference from precipitated phases, characterized in that, include: The grain boundary extraction module is used to obtain the grain boundary segmentation results of the microscopic images of metallographic materials based on a preset grain boundary segmentation model. The precipitate extraction module is used to obtain the precipitate segmentation results of the microscopic image of metallographic material based on the preset precipitate segmentation model. The misclassified grain screening module is used to screen out misclassified grains based on the grain boundary segmentation results output by the grain boundary extraction module and the precipitate segmentation results output by the precipitate extraction module; wherein, the misclassified grains refer to the cases in the grain boundary segmentation results where precipitates are mistakenly identified as grains; The misdivided grain redistribution module is used to correct the misdivided grains and synthesize the correct segmentation result; The grain boundary extraction module is specifically used for: A pre-defined grain boundary segmentation model was used to obtain the grain boundary pre-segmentation results of the microscopic images of metallographic materials; The grain boundary pre-segmentation results are post-processed to make the grain boundaries complete, closed, and with consistent boundary widths, thus obtaining the grain boundary segmentation results; wherein, the post-processing of the grain boundary pre-segmentation results includes expansion, etching, and framework operations; The precipitate extraction module is specifically used for: A pre-defined precipitate segmentation model was used to obtain the pre-segmentation results of precipitates in the microscopic images of metallographic materials; The pre-segmentation results of the precipitated phase are post-processed to filter out small target noise and remove small voids that appear inside the pre-segmentation results of the precipitated phase; wherein, the post-processing of the pre-segmentation results of the precipitated phase includes noise filtering, expansion and corrosion operations; The misaligned grain screening module is specifically used for: The grain boundary segmentation results are analyzed using a connected region partitioning method to obtain the grain particle set; The precipitate segmentation results are analyzed using a connected region partitioning method to obtain a subset of precipitates; The grains in the grain particle set are matched one by one with the precipitates in the precipitate phase set. If the area overlap between the grains and the precipitates is higher than a preset threshold, the two are considered to be successfully matched. Mark all successfully matched grains as misaligned grains; The misaligned grain redistribution module is specifically used for: Based on the relationship between the current misaligned grain and its surrounding grains, for each misaligned grain, find all non-misaligned grains that are adjacent to it; A preset redistribution strategy is used to allocate the pixels occupied by the misaligned dies to the non-misaligned dies; wherein, the preset redistribution strategy is any one or more combinations of watershed and map cut.