Additive manufacturing part defect identification method and system based on image analysis

By performing grayscale histogram analysis and correction on images acquired at different temperatures during additive manufacturing, the problems of image noise and distortion caused by temperature changes are solved, the accuracy of defect identification is improved, and the quality and performance of parts are ensured.

CN121707976APending Publication Date: 2026-03-20NORTHWESTERN POLYTECHNICAL UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-17
Publication Date
2026-03-20

AI Technical Summary

Technical Problem

In the additive manufacturing process, images of metal parts acquired using laser ultrasonic technology are subject to noise and distortion due to temperature changes, resulting in significant defects that can lead to errors in defect identification and affect the mechanical properties and service performance of the parts.

Method used

By performing grayscale histogram analysis on images acquired at different temperatures, enhancement coefficients and enhancement errors are obtained. The images are then corrected to reduce interference from temperature changes. Finally, the images are enhanced using the enhancement coefficients and enhancement errors to obtain accurate contours of defects.

Benefits of technology

It reduces image noise and distortion caused by temperature changes, improves the accuracy of defect identification, and ensures the quality and performance of parts.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121707976A_ABST
    Figure CN121707976A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of image processing, in particular to an additive manufacturing part defect identification method and system based on image analysis, and the method comprises the steps: obtaining error regions in images T1 and T2 collected at the same layer at any two temperatures; performing histogram specification on the error region in the T1 based on a gray histogram S2 in the error region in the T2 to obtain a gray histogram S1, and obtaining enhancement coefficients and enhancement errors of the S1 and the S2; the enhancement coefficient and the enhancement error are obtained again after S2 is corrected through the enhancement error, so that the difference of the enhancement coefficients of all the layers of images at any two temperatures is minimum, and enhancement and defect recognition are conducted on the collected images through the enhancement coefficient a and the enhancement error b when the difference is minimum. According to the invention, the identified defects are more reliable, and the problem that parts with complex structures interfere with laser ultrasonic detection under the action of high temperature is avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image processing technology, and specifically to a method and system for identifying defects in additive manufacturing parts based on image analysis. Background Technology

[0002] Traditional manufacturing often involves removing excess material from a block of material through cutting and grinding to obtain metal parts. Additive manufacturing, on the other hand, is based on digital models and uses laser printing to create three-dimensional solids by accumulating materials (such as metal powder) layer by layer. It is a bottom-up manufacturing method. During the printing process, metal parts may have defects such as porosity, incomplete fusion, and cracks. The root cause of these defects lies in unsuitable process parameters such as laser power and scanning speed during laser printing. This directly manifests as unstable molten pools (such as spatter), improper energy input (too high energy results in keyholes, too low energy results in incomplete fusion), or excessive temperature gradients. These defects directly lead to porosity, incomplete fusion, spheroidization, and huge residual stress, ultimately severely affecting the mechanical properties and service performance of the parts.

[0003] A common practice is to use laser ultrasonic technology to identify various defects in real time during the printing process, and then adjust the printing process accordingly based on the identification results, thereby reducing the presence of defects or avoiding waste of printing material due to defective parts. However, the printed metal material has a high temperature, and when using laser ultrasonic technology to acquire images, the propagation characteristics of ultrasonic waves in the material (such as wave speed and attenuation) are closely related to temperature. This results in non-negligible noise or distortion in the acquired images, leading to errors in the identified defects. Summary of the Invention

[0004] To address the aforementioned problems, this invention provides a method and system for defect identification of additive manufacturing parts based on image analysis.

[0005] The present invention provides a method and system for defect identification of additively manufactured parts based on image analysis, which adopts the following technical solution: One embodiment of the present invention provides a method for defect identification of additively manufactured parts based on image analysis, the method comprising the following steps: During the printing of metal parts, laser ultrasonic technology is used to acquire images of each layer and detect the contours of all defects in the images. Images acquired at the same layer at different times are at different temperatures. Images acquired at the same layer at any two temperatures are denoted as T1 and T2, where the temperature corresponding to T1 is greater than the temperature corresponding to T2. The area between the contours of the same defect in T1 and T2 is denoted as the error area. The gray-level histogram in the error area of ​​T2 is denoted as S2. Based on S2, the enhancement coefficient and enhancement error of images acquired at the same layer under any two temperatures are obtained, including: based on S2, the gray values ​​in the error region of T1 are histogramized to obtain gray histogram S1; the parameters of the gray histogram formed by the gray values ​​in the error region of T1 are transformed into S1 as the enhancement coefficient; the difference between S1 and S2 is recorded as the enhancement error. Subtracting a certain amount of enhancement error from S2 yields a corrected S2. Based on the corrected S2, the enhancement coefficient and enhancement error of images acquired at the same layer under any two temperatures are obtained again, so that the difference in enhancement coefficients of images acquired at all layers under any two temperatures is minimized. The enhancement coefficient and enhancement error with the smallest difference are denoted as a and b. The acquired image is enhanced using the enhancement coefficient a and enhancement error b to obtain the contour of the defects in the enhanced image.

[0006] Preferably, the region between the contours of the same defect in T1 and T2 is denoted as the error region, and the specific steps include the following: For two contours L1 and L2 in T1 and T2 respectively, for any pixel in L1, the nearest pixel in L2 is obtained and they form a pixel pair; for all pixel pairs in L1 and L2, and for a line segment with any pixel as its endpoint, all pixels on the line segment are denoted as the target pixel between the pixel pairs, and the area formed by the target pixels between all pixel pairs in L1 and L2 is denoted as the error region.

[0007] Preferably, the step of histogram specification of the gray values ​​in the error region of T1 based on S2 to obtain gray-level histogram S1, and the parameters of transforming the gray-level histogram formed by the gray values ​​in the error region of T1 to S1 are denoted as enhancement coefficients, and the specific steps are as follows: In T1, the pixels within the error area of ​​all defects are recorded as the first pixel. Based on the grayscale histogram S2, the histogram of all first pixels is defined to obtain the enhanced first pixel. The grayscale histogram formed by the grayscale values ​​of the enhanced first pixel is recorded as S1. The grayscale histogram formed by the grayscale values ​​of all first pixels is denoted as S3. Gamma transformation is performed on S3, and the difference between the grayscale histogram after gamma transformation and S1 is obtained, which is denoted as the transformation difference. The gamma coefficient with the smallest transformation difference is obtained and used as the enhancement coefficient.

[0008] Preferably, the specific steps for recording the difference between S1 and S2 as the enhancement error are as follows: S1 and S2 are fitted into Gaussian mixture models G1 and G2, respectively, and each of the Gaussian mixture models G1 and G2 contains a sub-Gaussian model. Calculate the distribution difference between each sub-Gaussian model in Gaussian mixture model G2 and Gaussian mixture model G1, and obtain several sub-Gaussian models in Gaussian mixture model G2 that have the largest distribution difference with Gaussian mixture model G1, denoted as the enhancement error distribution; The difference between each enhancement error distribution and the Gaussian mixture model G1 is denoted as the error amount of each enhancement error distribution, and the sum of the error amounts of all enhancement error distributions is denoted as the enhancement error.

[0009] Preferably, the specific steps for subtracting a certain amount of enhancement error from S2 to obtain the corrected S2 are as follows: Randomly initialize a subtraction coefficient w, and let the subtraction magnitude P = w × M, where M represents the enhanced error; The error amounts of all the enhancement error distributions are normalized, and the normalized error amount of each enhancement error distribution is multiplied by the subtraction magnitude to obtain the error subtraction amount of each enhancement error distribution. The gray-level histogram S2 is corrected using the error subtraction amount of each enhancement error distribution to obtain the corrected S2.

[0010] Preferably, the enhancement coefficient and enhancement error of the images acquired at the same layer under any two temperatures are obtained again based on the corrected S2, so that the difference in enhancement coefficients of all layers acquired under any two temperatures is minimized. The enhancement coefficient and enhancement error with the minimum difference are denoted as a and b. The specific steps include the following: Based on the corrected S2, the enhancement coefficient A(w) and enhancement error B(w) of the images acquired at the same layer under any two temperatures are obtained again. A(w) and B(w) represent the enhancement coefficient and enhancement error related to the subtraction coefficient w. The difference between the enhancement coefficients A(w) of all layers acquired at any two temperatures is denoted as the first difference. The genetic algorithm is used to obtain the value of w when the first difference is minimized. The mean value of the enhancement coefficients A(w) and the mean value of the enhancement error B(w) of all layers acquired at any two temperatures under this value of w are denoted as the enhancement coefficient a and enhancement error b obtained at any two temperatures, respectively.

[0011] Preferably, the specific steps of enhancing the acquired image using enhancement coefficient a and enhancement error b to obtain the contour of the defect in the enhanced image are as follows: The image acquired on the most recently printed layer is denoted as T0. For the enhancement error b and enhancement coefficient a corresponding to the temperature at which T0 was acquired and the room temperature, a gamma transform is performed on T0 using the enhancement coefficient a. The contours of all defects in T0 after the gamma transform are denoted as E1 and E2. The contours E1 and E2 are fused using the enhancement error b to obtain the contours of the defects in the enhanced image. During the fusion, the weight of contour E1 is negatively correlated with b.

[0012] Preferably, the specific steps for calculating the distribution difference between each sub-Gaussian model in the Gaussian mixture model G2 and the Gaussian mixture model G1 are as follows: For each sub-Gaussian model in the Gaussian mixture model G2 or G1, the mean and variance of each sub-Gaussian model are used as the distribution features of each sub-Gaussian model; the KM algorithm is used to match all sub-Gaussian models in G2 with all sub-Gaussian models in G1, so that the distribution features of the matched sub-Gaussian models have the minimum Euclidean distance. The absolute value of the difference between the maximum values ​​of any two sub-Gaussian models is denoted as the magnitude difference between the two sub-Gaussian models. For any sub-Gaussian model in the Gaussian mixture model G2, the magnitude difference between this sub-Gaussian model and the matched sub-Gaussian models in G1 is denoted as the distribution difference between any sub-Gaussian model in the Gaussian mixture model G2 and the Gaussian mixture model G1.

[0013] Preferably, the grayscale histogram S2 is corrected using the error subtraction amount of each enhancement error distribution to obtain the corrected S2. The specific steps include the following: For each enhancement error distribution, obtain all gray values ​​belonging to each enhancement error distribution in S2; The frequencies corresponding to all gray values ​​belonging to each enhancement error distribution are updated in S2 to obtain the corrected S2; where the updated frequency is equal to the frequency before the update multiplied by the error reduction amount of each enhancement error distribution.

[0014] Another embodiment of the present invention provides an image analysis-based additive manufacturing component defect identification system. The system includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor runs the computer program, it performs all the steps of the image analysis-based additive manufacturing component defect identification method described above.

[0015] The beneficial effects of the technical solution of the present invention are: In this invention, the grayscale values ​​within the error region of T1 are histogramized based on S2 to obtain a grayscale histogram S1. The parameters of the grayscale histogram formed by the grayscale values ​​within the error region of T1 when transformed to S1 are denoted as the enhancement coefficient. This enhancement coefficient indicates that after enhancing the high-temperature image T1 with significant laser-ultrasonic interference, it can be restored or reconstructed into an image that is the same as or similar to the low-temperature image T2 with less laser-ultrasonic interference; this helps to reduce defect identification errors.

[0016] Furthermore, this invention denotes the difference between S1 and S2 as the enhancement error; by subtracting a certain magnitude of the enhancement error from S2, a corrected S2 is obtained. Based on the corrected S2, the enhancement coefficient and enhancement error of images acquired at the same layer under any two temperatures are re-obtained, minimizing the difference in enhancement coefficients among all layers under any two temperatures. The enhancement coefficient and enhancement error at the minimum difference are denoted as a and b. In this process, by removing the aforementioned error during restoration or reconstruction, the enhancement coefficient is optimized and updated (i.e., enhancement coefficient a is obtained), and the error b when using enhancement coefficient a for enhancement reconstruction is evaluated. This process avoids the problem that temperature changes cause relatively complex interference with laser ultrasound, limiting the enhancement coefficient's ability to perform enhancement reconstruction. It also avoids the problem that, under complex interference conditions in laser ultrasound, the grayscale distribution within the error region of images acquired on different layers (i.e., different component structures) has significant randomness or uncertainty, leading to insufficient enhancement reconstruction capability of the enhancement coefficient.

[0017] Finally, this invention uses enhancement coefficient a and enhancement error b to enhance the acquired image, obtaining the outline of the defect in the enhanced image. At the same time, it takes into account the ability of enhancement coefficient a to restore or recover the image as well as the error of such restoration or recovery, making the identified defects more reliable and avoiding the problem of interference of complex structural components with laser ultrasonic detection under high temperature as much as possible. Attached Figure Description

[0018] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0019] Figure 1 This is a flowchart illustrating the steps of an image analysis-based additive manufacturing component defect identification method according to an embodiment of the present invention. Detailed Implementation

[0020] To further illustrate the technical means and effects adopted by the present invention to achieve its intended purpose, the following, in conjunction with the accompanying drawings and preferred embodiments, details the specific implementation, structure, features, and effects of an image analysis-based additive manufacturing component defect identification method and system proposed according to the present invention. In the following description, different "one embodiment" or "another embodiment" do not necessarily refer to the same embodiment. Furthermore, specific features, structures, or characteristics in one or more embodiments can be combined in any suitable form.

[0021] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains.

[0022] The following description, in conjunction with the accompanying drawings, details the specific scheme of the image analysis-based additive manufacturing component defect identification method and system provided by the present invention.

[0023] Example 1: Please see Figure 1 The diagram illustrates a flowchart of a method for identifying defects in additive manufacturing parts based on image analysis, according to an embodiment of the present invention. The method includes the following steps: Step S101: During the printing process of metal parts, laser ultrasonic technology is used to acquire images of each layer and detect the contours of all defects in the images.

[0024] In one comparative embodiment, during the printing of metal parts, after each layer is printed (i.e., after each layer of material is accumulated), a laser ultrasonic probe is used to scan the metal material of that layer to obtain a planar scan image; then image processing technology is used to identify the contours of all defects in the image.

[0025] However, the problem with this comparative example is that after each layer is printed, the metal material of that layer has a high temperature. When using laser ultrasonic technology to acquire images, the propagation characteristics of ultrasonic waves in the material (such as wave speed and attenuation) are closely related to temperature. This results in non-negligible noise or distortion in the acquired images, thus the defects identified in the comparative example have a large error.

[0026] In this embodiment, after each layer is printed, the laser ultrasonic probe scans all layers sequentially from top to bottom, acquiring one image for each layer. Then, image processing technology is used to identify the contours of all defects in each image.

[0027] It should be noted that as the printing process progresses, the same layer is repeatedly scanned by the laser ultrasonic probe, resulting in multiple images being captured for each layer. Furthermore, in this embodiment, for any given layer, the metal material continuously cools as the printing process continues. Therefore, after each layer is printed, multiple images are captured for the same layer, and these images, captured at different times, are at different temperatures. It should also be noted that in this embodiment, the printer lifts 50 micrometers at a time during laser printing, meaning that each layer on the component is 20 micrometers from bottom to top. Additionally, each image captured in this embodiment is a grayscale image, containing the internal details and textures of the component within each layer. Each image in this embodiment is 2048×2048 pixels in size.

[0028] In some embodiments, the printer can be raised multiple times (e.g., 20 times) as a single layer, that is, every 1000 micrometers on the component from bottom to top is considered a layer, in order to reduce the amount of computation required when implementing this embodiment.

[0029] As an example, image processing techniques are used to identify the contours of all defects in each image, including the following methods: Canny edge detection technology is used to extract all edges in an image, obtaining edges that can serve as the contours of each connected region. These edges are the contours of defects such as pores, unfused voids, and cracks.

[0030] As another example, image processing techniques are used to identify the contours of all defects in each image, including the following methods: The image is input into a semantic segmentation network (such as the DeepLabV3 network) to obtain semantic regions of defects such as pores, unfused pores, and cracks. The edge contour of each semantic region is used as the contour of each defect.

[0031] Since there are various existing technologies for identifying the contours of defects such as pores, voids, and cracks, this embodiment will not elaborate on them or specify them in detail.

[0032] Step S102: Images acquired at the same layer under any two temperatures are denoted as T1 and T2. The region between the contours of the same defect in T1 and T2 is denoted as the error region.

[0033] In this embodiment, in addition to using laser ultrasound technology to acquire images of each layer, four infrared cameras are installed around the component to collect the surface temperature of the component in real time.

[0034] Specifically, each infrared camera faces the side of the component. The height of each row of pixels is pre-marked in the infrared image captured by the camera. This allows the camera to obtain the pixel area where each layer of the component is located in the infrared image. The average temperature within this pixel area is taken as the average temperature captured by each infrared camera for each layer. The average of all the average temperatures captured by the infrared cameras for each layer is recorded as the temperature of that layer. As the printing process progresses, the temperature of the same layer will continuously cool to room temperature; or, in other words, each layer will have a different temperature at different times before cooling to room temperature.

[0035] Two arbitrary images, T1 and T2, are acquired from the same layer. The temperatures of the layer at the time of acquisition are also determined. This embodiment uses the example where the temperature corresponding to image T1 is greater than the temperature corresponding to T2. In other words, T1 and T2 are images acquired from the same layer at two different temperatures. The different temperatures at which these two images were acquired have different effects on the propagation characteristics of ultrasound in the material. Therefore, the identification results (i.e., the contours of the defects) for the same defect in these two images may differ.

[0036] Specifically, the area enclosed by each contour in T1 and T2 is called a defect area. For any defect area in T2, if the defect area in T2 has the largest intersection-union ratio with a defect area in T1, it means that the contours corresponding to these two defect areas describe the same defect in two different images (i.e., T1 and T2), and these two contours may be different.

[0037] The region between the contours of the same defect in T1 and T2 is denoted as the error region of the same defect.

[0038] As an example, the specific process for obtaining the error region includes: For two contours L1 and L2 in T1 and T2 respectively, for any pixel in L1, the nearest pixel in L2 is obtained. These two pixels form a pixel pair. All pixel pairs in L1 and L2 are obtained by traversing all pixels in L1. For a line segment with any pixel as its endpoint, all pixels on the line segment are recorded as the target pixels between pixel pairs. The area formed by the target pixels between all pixel pairs in L1 and L2 is recorded as the error region.

[0039] The error region refers to the area where the defect region changes due to temperature variations. Specifically, since higher temperatures significantly interfere with the ultrasonic waves in laser ultrasonic technology, the defect region detected in temperature T1 (when the temperature is higher) is offset (or an error occurs) compared to the defect region detected in temperature T2 (when the temperature is lower). The error region represents the pixel area where the offset has occurred.

[0040] Specifically, for images acquired at any layer under any two temperatures (i.e., T1 and T2), if the area of ​​the error region obtained by the above method is less than the preset area, it indicates that the defect region in T1 and T2 has not shifted, and the interference of the change between any two temperatures on the ultrasound in the laser ultrasound technology can be ignored. At this time, the images acquired at this layer under these two temperatures are not considered, that is, the images acquired at this layer under these two temperatures do not participate in the implementation of subsequent steps. In this embodiment, the preset area is 50 pixels.

[0041] In step S103, the gray-level histogram within the error region of T2 is denoted as S2; based on S2, the enhancement coefficient and enhancement error of the images acquired at the same layer under any two temperatures are obtained, including: based on S2, the gray-level values ​​within the error region of T1 are histogramized to obtain gray-level histogram S1, and the parameters of the gray-level histogram formed by the gray-level values ​​within the error region of T1 are denoted as enhancement coefficients when transforming it to S1.

[0042] (1) In the above process, the error regions of the same defect in T2 and T1 were obtained. For the error regions of all defects in T2, the gray values ​​of all pixels in the error regions of all defects in T2 are obtained. The gray histogram formed by the gray values ​​of these pixels is denoted as S2, which describes the gray distribution of pixels in the offset region at a lower temperature when the defect region is offset.

[0043] In T1, the pixels within the error area of ​​all defects are recorded as the first pixel. Based on the grayscale histogram S2, the histogram of all first pixels is defined (i.e., histogram matching) to obtain the enhanced first pixel. The grayscale histogram formed by the grayscale values ​​of the enhanced first pixel is recorded as S1.

[0044] Histogram specification is a well-known technique used to adjust the histogram of pixels in an image (i.e., the first pixel in this embodiment) into a specific shape or distribution (i.e., the shape or distribution of the grayscale histogram S2). The specific principle will not be described in detail in this embodiment.

[0045] The grayscale histogram S1 represents the following: after restoring or correcting the grayscale values ​​of the high-temperature image T1 with significant laser-ultrasound interference, the restored or corrected grayscale distribution is the same as or similar to the grayscale distribution of the low-temperature image T2 with less laser-ultrasound interference. This ensures that the restored and corrected grayscale distribution can avoid or reduce the defect identification error caused by the interference of high temperature on laser-ultrasound.

[0046] (2) For all pixels in the error region of all defects in T1 (i.e., all first pixels), the gray-level histogram formed by the gray values ​​of all first pixels is transformed into S1. The parameter during the transformation is denoted as the enhancement coefficient. This enhancement coefficient means that after enhancing the high-temperature image T1 with large laser-ultrasonic interference using this enhancement coefficient, it can be restored or reconstructed into an image that is the same as or similar to the low-temperature image T2 with less laser-ultrasonic interference; this helps to reduce defect identification errors.

[0047] As an example, the gray-level histogram formed by the gray values ​​of all first pixels is transformed into S1, and the parameters during the transformation are denoted as enhancement coefficients. The methods include: The grayscale histogram formed by the grayscale values ​​of all first pixels is denoted as S3. A gamma transform is performed on S3, with the gamma coefficients randomly initialized. The difference between the grayscale histogram after the gamma transform and S1 is obtained and denoted as the transform difference. This transform difference is considered a function related to the gamma coefficients. The particle swarm optimization algorithm is used to obtain the gamma coefficients that minimize the transform difference and these coefficients are used as enhancement coefficients.

[0048] As another example, the gray-level histogram formed by the gray values ​​of all the first pixels is transformed into S1. The parameters during the transformation are denoted as enhancement coefficients, and the methods include: The grayscale histogram formed by the grayscale values ​​of all first pixels is denoted as S3. A linear transformation is performed on S3. The linear transformation refers to linear mapping of S3 using a linear function, which is a well-known technique. In this embodiment, the linear function is a continuous piecewise linear function, which is a continuous function composed of linear functions in multiple intervals. As an example, the grayscale interval [0, 255] is divided into 5 equal intervals, each interval containing a linear function. The linear functions in all intervals are concatenated to form a continuous piecewise linear function. The vector formed by the slopes of the linear functions in all intervals is used as the transformation parameter of the linear transformation. This transformation parameter is also randomly initialized. The difference between the grayscale histogram after the linear transformation and S1 is obtained and denoted as the transformation difference. This transformation difference is considered as a function related to the transformation parameter. The transformation parameter with the smallest transformation difference is obtained using the particle swarm optimization algorithm and used as the enhancement coefficient.

[0049] As an example, methods for obtaining transformation differences include: For the grayscale histogram after gamma transformation or linear transformation, the histogram is regarded as a curve (the horizontal axis is the grayscale value, and the vertical axis is the frequency of the grayscale value). The DTW distance between the curve corresponding to this histogram and the curve corresponding to histogram S1 is used as the transformation difference. The DTW distance is obtained by the DTW algorithm, which is a well-known technology and will not be described in detail in this embodiment.

[0050] Step S104: Record the difference between S1 and S2 as the enhancement error.

[0051] In summary, the above obtained the error region, which represents the area where the defect region detected in the high-temperature image T1 shifts compared to the defect region detected in the low-temperature image T2 when the detected defect region is different due to temperature changes; and further obtained the enhancement coefficient, which represents the enhancement coefficient that restores or recovers the grayscale of the error region in the high-temperature image T1 to the low-temperature image T2 as much as possible through image enhancement.

[0052] In this embodiment, it is further considered that the interference of temperature changes (e.g., the temperature corresponding to T1 relative to the temperature corresponding to T2) on laser ultrasound is complex. The above-mentioned enhancement coefficient can only restore or recover to a certain extent, and cannot further restore or recover the error area in the high temperature image T1.

[0053] Based on this, in this embodiment, the difference between S1 and S2 is denoted as the enhancement error, which represents the error that exists when only the enhancement coefficient is used for restoration or recovery. The larger the enhancement error, the less accurately the gray distribution of the error area in the high temperature image T1 can be restored or recovered to the gray distribution of the error area in the low temperature image T2 when only the enhancement coefficient is used for restoration or recovery.

[0054] As an example, the difference between S1 and S2 is denoted as the enhancement error, and the methods include: Using the EM algorithm, S1 and S2 are fitted into Gaussian mixture models, denoted as G1 and G2 respectively. A Gaussian mixture model is the sum of multiple sub-Gaussian models, and its specific formula is well known and will not be described in detail in this embodiment. The number of sub-Gaussian models contained in the Gaussian mixture models G1 and G2 is set to n1 respectively. In this embodiment, n1=10 is used as an example. The preferred value range is [5, 20]. Each sub-Gaussian model represents a gray-level distribution feature in S1 or S2.

[0055] Calculate the distribution difference between each sub-Gaussian model in Gaussian mixture model G2 and Gaussian mixture model G1. Obtain the n2 sub-Gaussian models in Gaussian mixture model G2 that have the largest distribution difference with Gaussian mixture model G1, and denote them as the enhancement error distribution. This embodiment uses n2=5 as an example for description.

[0056] Any grayscale error distribution describes the following: Since there are some grayscale values ​​in the error region of the low-temperature image T2, the distribution of these grayscale values ​​exhibits the characteristics of this enhancement error distribution. These grayscale values ​​exhibiting the characteristics of this enhancement error distribution cannot be restored or recovered by the above enhancement coefficients, which leads to the existence of errors when restoring or recovering using only the enhancement coefficients.

[0057] Calculate the distribution difference between the sub-Gaussian model and the Gaussian mixture model G1 corresponding to each enhancement error distribution, and denote it as the error amount of each enhancement error distribution. The sum of the error amounts of all enhancement error distributions is denoted as the enhancement error.

[0058] As an example, calculating the distributional differences between each sub-Gaussian model in the Gaussian mixture model G2 and the Gaussian mixture model G1 involves the following steps: For each sub-Gaussian model in a Gaussian mixture model G2 or G1, the mean and variance of each sub-Gaussian model, as well as the mean and variance of all models in G2 and G1, are linearly normalized. This normalization removes the dimensions and orders of magnitude of all means and variances in G2 and G1. The vector formed by the normalized mean and variance of each sub-Gaussian model is then used as the distribution feature of that model. The KM matching algorithm is then used to match all sub-Gaussian models in G2 with all sub-Gaussian models in G1, ensuring that the distribution features of the matched sub-Gaussian models have the minimum Euclidean distance.

[0059] The absolute value of the difference between the maximum values ​​of any two sub-Gaussian models is denoted as the magnitude difference between the two sub-Gaussian models.

[0060] For each sub-Gaussian model in the Gaussian mixture model G2, for each sub-Gaussian model that is matched with a pair of sub-Gaussian models in G1; In one example, the product of the Euclidean distance between the distribution characteristics of the two sub-Gaussian models and the magnitude difference between the two sub-Gaussian models is calculated. This product is used to describe the distribution difference between the two sub-Gaussian models and is denoted as the distribution difference between each sub-Gaussian model in the Gaussian mixture model G2 and the Gaussian mixture model G1.

[0061] In another example, the magnitude difference between the two sub-Gaussian models is used to describe the distribution difference between the two sub-Gaussian models, which is denoted as the distribution difference between each sub-Gaussian model in the Gaussian mixture model G2 and the Gaussian mixture model G1.

[0062] Step S105: Subtract a certain amount of enhancement error from S2 to obtain the corrected S2. Based on the corrected S2, obtain the enhancement coefficient and enhancement error of the images acquired at the same layer at any two temperatures, so that the difference in enhancement coefficients of all layers acquired at any two temperatures is minimized. The enhancement coefficient and enhancement error with the smallest difference are denoted as a and b.

[0063] The above process yielded the enhancement coefficient and enhancement error for images T1 and T2 acquired at the same layer at any two temperatures. During the metal parts printing process, after each layer is printed, a laser ultrasonic probe scans all layers sequentially from top to bottom. Each layer is imaged multiple times (each layer has a different temperature during each image capture). This results in multiple layers containing both temperatures mentioned above during the multiple image captures (layers that do not contain either of the two temperatures are not considered). For multiple layers containing either of the two temperatures, the enhancement coefficient and enhancement error can be obtained for each layer in the same way.

[0064] In this embodiment, on the one hand, as described in step S104 above, the interference of temperature change on laser ultrasound is complex, and the above enhancement coefficient can only restore or recover to a certain extent, and cannot further restore or recover the error area in the high temperature image T1.

[0065] On the other hand, this embodiment further considers that the components have different structures in different layers (the propagation of ultrasonic waves in laser ultrasound technology is different under different structures). When there is interference in laser ultrasound, the gray-scale distribution in the error area obtained by the images acquired on different layers (i.e., different component structures) has a large degree of randomness or uncertainty. The enhancement coefficient obtained above is only applicable to or only used to describe the process of image restoration or recovery when there is interference in laser ultrasound under a specific component structure. It cannot further restore or recover the image in scenarios where the component structure is complex and there is interference in laser ultrasound.

[0066] This embodiment solves the two problems mentioned above with the enhancement coefficient through the following process: subtracting a certain amount of enhancement error from S2 to obtain a corrected S2; and obtaining the enhancement error and enhancement coefficient of the same layer image at any two temperatures based on the corrected S2, so that the difference in enhancement coefficient of all layers of images at any two temperatures is minimized.

[0067] The process takes into account the two problems with the enhancement coefficients mentioned above, which can be summarized as follows: the enhancement coefficients obtained above have errors, which prevent accurate restoration or recovery of images for all layers. The enhancement errors obtained for different layers at any two temperatures include these errors. Therefore, this embodiment updates the enhancement coefficients by removing enhancement errors of a suitable magnitude, minimizing the difference in enhancement coefficients for all layers at any two temperatures. The enhancement coefficient with the smallest difference can remove interference (caused by temperature changes during laser ultrasonic testing of components with various structural characteristics), thus enabling the most accurate restoration or recovery of the image. The restoration or recovery refers to restoring or recovering an image with high temperature interference to an image with low temperature interference (e.g., restoring or recovering a high-temperature image T1 with significant laser ultrasonic interference to a low-temperature image T2 with less laser ultrasonic interference).

[0068] As an example, subtracting a certain amount of amplitude enhancement error from S2 to obtain the corrected S2 involves the following methods: Randomly initialize a parameter w, denoted as the subtraction coefficient, whose value range is [0, 1]; Let the reduction magnitude P = w × M, where M represents the enhancement error obtained by the same layer at any two temperatures; For all enhancement error distributions obtained at the same layer under any two temperatures (obtained in step S104), the error amounts of all enhancement error distributions (obtained in step S104) are normalized using the softmax formula. The normalized error amount of each enhancement error distribution is multiplied by the subtraction magnitude to obtain the error subtraction amount of each enhancement error distribution.

[0069] The subtraction magnitude represents the amount of enhancement error that needs to be removed from S2.

[0070] The calculation of the error reduction amount for each enhancement error distribution takes into account that, for different layers at any two temperatures, the enhancement error may manifest in different grayscale distribution characteristics (i.e., different layers obtain different enhancement error distributions). In this embodiment, when removing a certain amplitude of enhancement error from S2, the certain amplitude of enhancement error is distributed to all enhancement error distributions according to a proportion (i.e., according to the normalized error amount), and then the error is removed from all enhancement error distributions at the same time, avoiding the problem of unreasonable removal of some layers when removing the error from a single enhancement error distribution.

[0071] Thus, for images acquired from the same layer at any two temperatures, this embodiment first obtains all enhancement error distributions in the grayscale histogram S2 of the low-temperature image T2 (see step S104 for details). This histogram describes the distribution characteristics of grayscale values ​​in T2 that cannot be restored or recovered using the enhancement coefficient. Then, the error reduction amount for each enhancement error distribution is obtained. Further, this embodiment uses the error reduction amount for each enhancement error distribution to correct the grayscale histogram S2, obtaining the corrected S2.

[0072] Based on the corrected S2, the enhancement coefficient and enhancement error of the same layer image at any two temperatures are obtained again, denoted as A(w) and B(w). This process is the same as steps S103 and S104, and will not be described in detail in this embodiment.

[0073] Thus, this embodiment obtains the enhancement coefficient A(w) and enhancement error B(w) related to w, obtains the difference between the enhancement coefficient A(w) of all layer images at any two temperatures, and denots it as the first difference. The first difference is regarded as a function related to w. The genetic algorithm is used to obtain the value of w when the first difference is minimized. The mean value of the enhancement coefficient A(w) and the mean value of the enhancement error B(w) of all layer images at any two temperatures under this value of w are denoted as the enhancement coefficient a and enhancement error b obtained at any two temperatures, respectively.

[0074] The enhancement coefficient 'a' and enhancement error 'b' represent the enhancement coefficient and the error during the restoration or recovery of the image, respectively, which are used to remove interference caused by any two temperature changes during laser ultrasonic testing of components with various structural features.

[0075] As an example, methods for obtaining the first difference include: For any two temperatures, the enhancement coefficients A(w) of all layer images are evaluated by taking the absolute value of the differences between each pair of enhancement coefficients A(w) (in some embodiments, the Euclidean distance between A(w) can also be taken), and the mean of the absolute values ​​(or Euclidean distances) of all differences is taken as the first difference.

[0076] As an example, the gray-level histogram S2 is corrected by subtracting the error from each enhancement error distribution to obtain the corrected S2. The steps include: It should be noted that the Gaussian mixture model G2 is obtained by fitting the histogram S2 in the image T2. Since the horizontal axis of the histogram S2 is the gray value and the vertical axis is the frequency of the gray value, the horizontal axis of the Gaussian mixture model G2 and the sub-Gaussian models in G2 are also gray values, and the vertical axis is also the frequency of the gray value.

[0077] For any gray value in S2, obtain the corresponding ordinate of the gray value on all sub-Gaussian models in G2, and obtain the sub-Gaussian model with the largest ordinate. The gray value belongs to that sub-Gaussian model.

[0078] The above process is used to determine the sub-Gaussian model to which each gray value belongs. In essence, it is a conventional method of classification based on Gaussian mixture model. This embodiment will not describe it in more detail.

[0079] For each enhancement error distribution (which is essentially a sub-Gaussian model in G2), obtain all gray values ​​belonging to each enhancement error distribution, and update the frequencies corresponding to these gray values ​​on the histogram S2 to obtain the corrected S2; where the updated frequency is equal to the frequency before the update multiplied by the error reduction amount of each enhancement error distribution.

[0080] Step S106: Enhance the acquired image using enhancement coefficient a and enhancement error b to obtain the contour of the defect in the enhanced image.

[0081] The above process describes the enhancement error b and enhancement coefficient a obtained for images of all layers acquired at any two temperatures after each layer is printed.

[0082] For the image acquired on the most recently printed layer, denoted as T0, obtain the enhancement error b and enhancement coefficient a corresponding to the two temperatures: the temperature at which T0 was acquired and the room temperature (25 degrees Celsius as an example). Record the enhancement error b and enhancement coefficient a obtained based on these two temperatures for defect identification.

[0083] The purpose of considering room temperature is to minimize the interference of room temperature with laser ultrasound technology. By taking into account the temperature at acquisition T0 and the corresponding enhancement error b and enhancement coefficient a at room temperature, it can be ensured that when the image T0 is restored or recovered using the enhancement error b and enhancement coefficient a, it can be restored to the state with minimal interference from laser ultrasound technology.

[0084] Specifically: Image enhancement of T0 is performed using an enhancement coefficient 'a', where the image enhancement is a gamma transform, and the enhancement coefficient 'a' serves as a gamma transform coefficient. In other embodiments, the image enhancement is a linear transform, where the enhancement coefficient 'a' serves as a transform coefficient for the linear transform.

[0085] Image processing techniques are used to identify the contours of all defects in the enhanced T0 (see step S101 for details), denoted as contour E1. Image processing techniques are also used to identify the contours of all defects in T0, denoted as contour E2. Contour E1 and contour E2 are fused using the enhancement error b, where the weight of contour E1 is negatively correlated with b during fusion.

[0086] The weight of contour E1 is negatively correlated with b, indicating that when the enhancement error b is large, the image restoration and reconstruction method obtained in the current printing process cannot accurately restore the image. This is because, on the one hand, the number of printed layers is small, and there are not enough image samples to extract the accurate enhancement coefficient a; on the other hand, due to the complex structure of the parts being printed, the influence of temperature interference on the image is unpredictable or highly uncertain. In this case, contour E1 is not considered during fusion; instead, E2 is considered to avoid the problem of severe distortion after image enhancement using enhancement coefficient a, leading to a large deviation in defect identification results. When the enhancement error b is small, it means that image enhancement using enhancement coefficient a can reliably remove the interference caused by temperature. In this case, contour E1 is given more attention to ensure the accuracy of defect identification results.

[0087] As an example, the method of fusing contours E1 and E2 using the enhancement error b includes: For contours E2 and E1 corresponding to the same defect in T0 and the enhanced T0, for any pixel in E1, the pixel closest to that pixel in E2 is obtained, and these two pixels form a pixel pair. All pixel pairs in E1 and E2 are obtained; the pixels in any pixel pair located on E1 and E2 are denoted as e1 and e2 respectively, and the fusion position P is obtained, P=y×P(e2)+(1-y)×P(e1), where P(e2) represents the position of e2 and P(e1) represents the position of e1; y represents the fusion coefficient, in this embodiment y=b / N, N is a preset normalization coefficient, and in this embodiment N=n2=5 is used as an example for description.

[0088] The closed contour formed by connecting the fusion positions P of all pixel pairs in contour E2 and contour E1 is used as the contour of the defect identified in T0.

[0089] Specifically, the above process includes: for the two temperatures constituted by the temperature at acquisition T0 and the room temperature, obtaining the enhancement error b and enhancement coefficient a corresponding to these two temperatures. It should be noted that when there are no corresponding layers at these two temperatures, that is, for all printed layers, no image has been acquired at either of these two temperatures, the two temperatures with the smallest difference from these two temperatures are obtained, and the enhancement error b and enhancement coefficient a corresponding to the two temperatures with the smallest difference are used to implement the above step S106.

[0090] This concludes the example.

[0091] In this embodiment, after each layer is printed, images of all layers are sequentially acquired using laser ultrasonic technology. This allows for the acquisition of the enhancement error *b* and enhancement coefficient *a* at any two temperatures. These represent the enhancement coefficient, which removes interference and allows for the most accurate possible restoration or recovery of the image, as well as the error during restoration or recovery. The interference refers to the disturbance caused by any two temperature changes during laser ultrasonic testing of components with various structural characteristics. For the image T0 acquired from the most recently printed layer, T0 is restored or recovered using the corresponding temperature and the enhancement error *b* and enhancement coefficient *a* at room temperature. This avoids temperature interference with laser ultrasonic testing and ensures the accuracy of defect identification. Example

[0092] In the above embodiments, after each layer is printed, the outline of all defects in that layer (i.e., in the image T0 described in Embodiment 1) is obtained.

[0093] In one example, the defect regions enclosed by each contour are input into a classification network to classify all defects. This embodiment describes the classification of all defects into three categories: porosity, unfused pores, and cracks. The classification network used in this embodiment is the ResNet-18 network. The structure, principle, and training method of this network are existing technologies, and will not be described in detail in this embodiment.

[0094] After each layer is printed, the outlines of all types of defects are displayed on the screen. Staff members observe the screen to determine whether to stop or continue printing.

[0095] In another example, the sum of the areas of all defect regions of the same type of defect is recorded as the interference amount for each type of defect.

[0096] When the interference of each type of defect is greater than 10% of the total number of pixels in the image, the defect is determined to exist. When the interference of each type of defect is less than or equal to 10% of the total number of pixels in the image, the defect is determined to be negligible and is considered not to exist.

[0097] If any type of defect is detected, printing stops to avoid wasting printing material. If no defects are detected, printing continues to the next layer.

[0098] In some examples, the interference from all types of defects is input into a fully connected neural network, which outputs laser power and scanning speed. This laser power and scanning speed represent the laser power and scanning speed required for laser printing to reduce all defects. Once the laser power and scanning speed are obtained, they are used for printing the next layer.

[0099] In this embodiment, the fully connected neural network has 3 intermediate layers, with 3 neurons in each intermediate layer. The specific related technologies of the fully connected neural network are well known, and will not be described in detail in this embodiment.

[0100] The training method for this fully connected neural network is as follows: In an experimental environment, when laser printing each layer of the test component, different laser powers and scanning speeds are manually set. The interference amount of all types of defects in each layer, as well as the laser power and scanning speed used, are recorded. If a defect exists in the current layer but not in the next layer, the interference amount of all types of defects in the previous layer is used as a sample, and the laser power and scanning speed of the next layer are used as the sample label. All samples and labels obtained through a large number of tests in the experimental environment are used as a dataset. This dataset is used to train the fully connected neural network. The mean squared error loss function is used during training, and the parameter update method for the fully connected neural network is the stochastic gradient descent algorithm.

[0101] In this embodiment, when the number of printing layers is less than 5, the error is large when using Embodiment 1 for defect identification. In this case, the comparative embodiment in Embodiment 1 is directly used for defect identification to obtain the outline of the defect.

[0102] Example 3: This embodiment provides an image analysis-based additive manufacturing part defect identification system. The system includes a laser printer and a laser ultrasonic device. The probe of the laser ultrasonic device faces one side of the part being printed, and the laser ultrasonic device can move up and down under the drive of a motor, so that the laser ultrasonic device can scan all layers.

[0103] The system includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor runs the computer program, it performs all the steps of all the embodiments described above.

[0104] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for defect identification of additively manufactured parts based on image analysis, characterized in that, The method includes the following steps: During the printing of metal parts, laser ultrasonic technology is used to acquire images of each layer and detect the contours of all defects in the images. Images acquired at the same layer at different times are at different temperatures. Images acquired at the same layer at any two temperatures are denoted as T1 and T2, where the temperature corresponding to T1 is greater than the temperature corresponding to T2. The area between the contours of the same defect in T1 and T2 is denoted as the error area. The gray-level histogram in the error area of ​​T2 is denoted as S2. Based on S2, the enhancement coefficient and enhancement error of images acquired at the same layer under any two temperatures are obtained, including: based on S2, the gray values ​​in the error region of T1 are histogramized to obtain gray histogram S1; the parameters of the gray histogram formed by the gray values ​​in the error region of T1 are transformed into S1 as the enhancement coefficient; the difference between S1 and S2 is recorded as the enhancement error. Subtracting a certain amount of enhancement error from S2 yields a corrected S2. Based on the corrected S2, the enhancement coefficient and enhancement error of images acquired at the same layer under any two temperatures are obtained again, so that the difference in enhancement coefficients of images acquired at all layers under any two temperatures is minimized. The enhancement coefficient and enhancement error with the smallest difference are denoted as a and b. The acquired image is enhanced using the enhancement coefficient a and enhancement error b to obtain the contour of the defects in the enhanced image.

2. The method for defect identification of additive manufacturing parts based on image analysis according to claim 1, characterized in that, The region between the contours of the same defect in T1 and T2 is denoted as the error region, and the specific steps involved are as follows: For two contours L1 and L2 in T1 and T2 respectively, for any pixel in L1, the nearest pixel in L2 is obtained and they form a pixel pair; for all pixel pairs in L1 and L2, and for a line segment with any pixel as its endpoint, all pixels on the line segment are denoted as the target pixel between the pixel pairs, and the area formed by the target pixels between all pixel pairs in L1 and L2 is denoted as the error region.

3. The method for defect identification of additive manufacturing parts based on image analysis according to claim 1, characterized in that, The histogram specification of the gray values ​​in the error region of T1 based on S2 is obtained to obtain the gray-level histogram S1. The parameters of the gray-level histogram formed by the gray values ​​in the error region of T1 when transforming to S1 are denoted as the enhancement coefficients. The specific steps include the following: In T1, the pixels within the error area of ​​all defects are recorded as the first pixel. Based on the grayscale histogram S2, the histogram of all first pixels is defined to obtain the enhanced first pixel. The grayscale histogram formed by the grayscale values ​​of the enhanced first pixel is recorded as S1. The grayscale histogram formed by the grayscale values ​​of all first pixels is denoted as S3. Gamma transformation is performed on S3, and the difference between the grayscale histogram after gamma transformation and S1 is obtained, which is denoted as the transformation difference. Obtain the gamma coefficients that minimize the transformation difference and use them as enhancement coefficients.

4. The method for defect identification of additive manufacturing parts based on image analysis according to claim 1, characterized in that, The specific steps involved in recording the difference between S1 and S2 as the enhancement error are as follows: S1 and S2 are fitted into Gaussian mixture models G1 and G2, respectively, and each of the Gaussian mixture models G1 and G2 contains a sub-Gaussian model. Calculate the distribution difference between each sub-Gaussian model in Gaussian mixture model G2 and Gaussian mixture model G1, and obtain several sub-Gaussian models in Gaussian mixture model G2 that have the largest distribution difference with Gaussian mixture model G1, denoted as the enhancement error distribution; The difference between each enhancement error distribution and the Gaussian mixture model G1 is denoted as the error amount of each enhancement error distribution, and the sum of the error amounts of all enhancement error distributions is denoted as the enhancement error.

5. The method for defect identification of additive manufacturing parts based on image analysis according to claim 4, characterized in that, The specific steps involved in subtracting a certain amount of enhancement error from S2 to obtain the corrected S2 are as follows: Randomly initialize a subtraction coefficient w, and let the subtraction magnitude P = w × M, where M represents the enhanced error; The error amounts of all the enhancement error distributions are normalized, and the normalized error amount of each enhancement error distribution is multiplied by the subtraction magnitude to obtain the error subtraction amount of each enhancement error distribution. The gray-level histogram S2 is corrected using the error subtraction amount of each enhancement error distribution to obtain the corrected S2.

6. The method for defect identification of additive manufacturing parts based on image analysis according to claim 5, characterized in that, The enhancement coefficient and enhancement error of images acquired at the same layer under any two temperatures are obtained again based on the corrected S2, so that the difference in enhancement coefficients of images acquired at all layers under any two temperatures is minimized. The enhancement coefficient and enhancement error with the minimum difference are denoted as a and b. The specific steps include the following: Based on the corrected S2, the enhancement coefficient A(w) and enhancement error B(w) of the images acquired at the same layer under any two temperatures are obtained again. A(w) and B(w) represent the enhancement coefficient and enhancement error related to the subtraction coefficient w. The difference between the enhancement coefficients A(w) of all layers acquired at any two temperatures is denoted as the first difference. The genetic algorithm is used to obtain the value of w when the first difference is minimized. The mean value of the enhancement coefficients A(w) and the mean value of the enhancement error B(w) of all layers acquired at any two temperatures under this value of w are denoted as the enhancement coefficient a and enhancement error b obtained at any two temperatures, respectively.

7. The method for defect identification of additive manufacturing parts based on image analysis according to claim 6, characterized in that, The specific steps involved in enhancing the acquired image using an enhancement coefficient 'a' and an enhancement error 'b' to obtain the contours of defects in the enhanced image are as follows: The image acquired on the most recently printed layer is denoted as T0. For the enhancement error b and enhancement coefficient a corresponding to the temperature at which T0 was acquired and the room temperature, a gamma transform is performed on T0 using the enhancement coefficient a. The contours of all defects in T0 after the gamma transform are denoted as E1 and E2. The contours E1 and E2 are fused using the enhancement error b to obtain the contours of the defects in the enhanced image. During the fusion, the weight of contour E1 is negatively correlated with b.

8. The method for defect identification of additive manufacturing parts based on image analysis according to claim 4, characterized in that, The specific steps for calculating the distribution difference between each sub-Gaussian model in the Gaussian mixture model G2 and the Gaussian mixture model G1 are as follows: For each sub-Gaussian model in the Gaussian mixture model G2 or G1, the mean and variance of each sub-Gaussian model are used as the distribution features of each sub-Gaussian model; the KM algorithm is used to match all sub-Gaussian models in G2 with all sub-Gaussian models in G1, so that the distribution features of the matched sub-Gaussian models have the minimum Euclidean distance. The absolute value of the difference between the maximum values ​​of any two sub-Gaussian models is denoted as the magnitude difference between the two sub-Gaussian models. For any sub-Gaussian model in the Gaussian mixture model G2, the magnitude difference between this sub-Gaussian model and the matched sub-Gaussian models in G1 is denoted as the distribution difference between any sub-Gaussian model in the Gaussian mixture model G2 and the Gaussian mixture model G1.

9. The method for defect identification of additive manufacturing parts based on image analysis according to claim 5, characterized in that, The grayscale histogram S2 is corrected by subtracting the error from each enhancement error distribution to obtain the corrected S2. The specific steps are as follows: For each enhancement error distribution, obtain all gray values ​​belonging to each enhancement error distribution in S2; The frequencies corresponding to all gray values ​​belonging to each enhancement error distribution are updated in S2 to obtain the corrected S2; where the updated frequency is equal to the frequency before the update multiplied by the error reduction amount of each enhancement error distribution.

10. A defect identification system for additively manufactured parts based on image analysis, the system comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor runs the computer program, it executes all the steps of the image analysis-based additive manufacturing part defect identification method according to any one of claims 1 to 9.