Method for detecting sealing defects of a device cover using x-rays
By dividing X-ray images into regions and employing digital image processing technology, the stability and cost issues of detecting sealing defects in device caps have been resolved, achieving efficient and accurate automated detection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- THE 13TH RES INST OF CHINA ELECTRONICS TECH GRP CORP
- Filing Date
- 2022-06-06
- Publication Date
- 2026-06-12
AI Technical Summary
Existing technologies suffer from poor detection stability, high subjectivity, and high cost when detecting sealing defects in device caps. In particular, the criteria for judging corner areas are too strict, leading to waste.
The X-ray Y-axis view is divided into edge area and corner area. Different defect calculation formulas are used, and digital image processing technology is used to obtain the inner and outer boundaries and defect contours of the sealing area. The calculation is then automated through digital image processing technology.
It improves the stability and accuracy of detection, reduces the false judgment rate, reduces material waste, reduces manual labor intensity, and improves detection efficiency.
Smart Images

Figure CN115170474B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of device capping defect detection technology, specifically relating to a method for inspecting device capping sealing defects using X-rays. Background Technology
[0002] Currently, X-ray inspection is the optimal method for screening and eliminating packaged devices with sealing defects. This method is based on the fundamental principle that X-rays attenuate to varying degrees when penetrating the tested material. Areas with high density and great thickness absorb more X-rays, while areas with low density and little thickness absorb less X-rays. This method can detect sealing defects in the cap without damaging the sample.
[0003] After obtaining the X-ray image of the device, it is necessary to calculate the sealing defects of the cap. The current relevant inspection standard is GJB 548B-2005 "Test Methods and Procedures for Microelectronic Devices," which references the US military standard Mil-Std-883 "Test Method Standard Microcircuits." Figure 4 Taking a circular defect as an example, the specific calculation method is as follows: For the edge area, according to the formula... or The calculation results are used as the judgment criteria. For corner areas, the following is adopted: and The smaller value is the criterion.
[0004] In actual testing, after obtaining X-ray images, the sealing dimensions and defect dimensions of the caps are usually manually marked and then calculated. This process is subjective, time-consuming, labor-intensive, and cannot guarantee the stability of the test results. Furthermore, in the process of developing this invention, it was found that for corner areas, due to the presence of sealing areas on both sides of the cap, the probability of leakage is significantly lower than that of sealing areas along the edge of the cap. Therefore, using the currently implemented inspection standards may lead to stricter judgment criteria, which will increase the cost of the components to some extent, especially for high-grade and expensive components, resulting in significant waste. Summary of the Invention
[0005] This invention provides a method for inspecting device cap sealing defects using X-rays, aiming to improve the stability and rationality of current device cap sealing defect detection, reduce costs, and minimize waste.
[0006] To achieve the above objectives, the technical solution adopted by the present invention is: to provide a method for inspecting sealing defects of device caps using X-rays, comprising:
[0007] Obtain an X-ray Y-axis view of the device cover, and divide the sealed area of the cover in the X-ray Y-axis view into multiple edge area and multiple corner area. The inner and outer boundaries of the edge area are straight lines, and the inner and outer boundaries of the corner area are curves.
[0008] Determine the defect calculation formulas for the edge area and the corner area respectively;
[0009] The inner boundary contour, outer boundary contour, and defect contour of the sealing area are obtained based on digital image processing technology.
[0010] The parameters of the defect calculation formula are obtained based on the inner boundary profile, outer boundary profile, and defect profile, and the sealing defect ratio of the cap is calculated.
[0011] In one possible implementation, the formula for calculating defects in the edge region is: ,
[0012] The formula for calculating defects in corner areas is: ,
[0013] Among them, L A This is the shortest path distance between the defect profile and the outer boundary profile.
[0014] L B This is the shortest path distance between the defect profile and the inner boundary profile.
[0015] L is the distance between the inner and outer boundaries of the edge region corresponding to the location of the defect;
[0016] L1 is the minimum distance from the intersection point of the shortest straight path between the defect profile and the outer and inner boundaries of the corner area to the outer boundary profile.
[0017] L2 is the minimum distance from the intersection point of the shortest straight path between the defect profile and the inner and outer boundaries of the corner area to the inner boundary profile.
[0018] In some embodiments, obtaining the inner boundary contour, outer boundary contour, and defect contour of the sealing area based on digital image processing technology includes:
[0019] Image grayscale conversion: The X-ray Y-axis view is dimensionality reduced to transform it from a three-channel RGB color image into a single-channel grayscale image;
[0020] Histogram equalization: By changing the pixel value distribution of a single-channel grayscale image, the dynamic range of the image is compressed and the contrast of the image is enhanced.
[0021] Image noise reduction: Bilateral filtering is used to remove noise generated during the generation and transmission of the X-ray Y-axis view, as well as noise generated during image grayscale conversion and histogram equalization.
[0022] Image enhancement: Enhance image contrast and highlight target areas through gamma transformation;
[0023] Image thresholding segmentation: The inner and outer boundary contours of the sealed area of the cap, as well as the defect contour, are segmented on the entire sealed area of the cap to obtain the inner boundary contour, outer boundary contour, and defect contour.
[0024] For example, image grayscale conversion includes: converting image data from a three-dimensional matrix to a two-dimensional matrix from an X-ray Y-axis view using a weighted averaging algorithm to obtain a single-channel grayscale image.
[0025] For example, histogram equalization includes:
[0026] Determine the gray level probability density function of a single-channel grayscale image;
[0027] The cumulative probability distribution function of gray levels in a single-channel grayscale image is determined based on the gray level probability density function.
[0028] A single-channel grayscale image is transformed by mapping it to the entire grayscale range using a transformation function.
[0029] Specifically, the gray-level probability density function is: The cumulative probability distribution function for gray levels is: The conversion function is: The grayscale range is ;
[0030] in,
[0031] It is grayscale;
[0032] grayscale Number of times it appears;
[0033] n is the total number of pixel levels in the input image.
[0034] In one possible implementation, image thresholding segmentation includes:
[0035] All defect contours within the sealed area of the cap are obtained through threshold segmentation;
[0036] Extract all defect contours and store them in the Vector area;
[0037] The inner and outer boundary contours are obtained by threshold segmentation, and then extracted and rotated to the horizontal plane of the image.
[0038] For example, for defect calculation in the edge region, the intersection of the edge region and the vector region is taken to obtain the edge region set. Based on the edge region set, the shortest path distance L is calculated by sequentially selecting each defect contour. A Shortest path distance L B , Spacing L between inner and outer boundaries.
[0039] For example, in calculating defects in corner regions, the intersection of the corner region and the Vector region is taken to obtain a set of corner regions. Based on the set of corner regions, the shortest path distance L is calculated by sequentially selecting each defect contour. A Shortest path distance L B Calculate the shortest straight-line distances from the intersection of the extensions of the two shortest paths to the outer and inner boundary contours, respectively, and obtain the minimum values L1 and L2.
[0040] In some embodiments, the sealing area of the cap is a rectangular ring with rounded inner and outer corners. The area enclosed by the intersection of the extended straight edge of the inner boundary contour and the outer boundary contour is the corner area, so that the sealing area of the cap includes four edge areas, four corner areas, and other areas other than the four edge areas and corner areas; wherein, the defects in other areas are calculated using the defect calculation formulas for both edge areas and corner areas.
[0041] The beneficial effects of the method for inspecting sealing defects of devices using X-rays provided by this invention are as follows: Compared with the prior art, the method of this invention divides the X-ray Y-axis view into edge region and corner region, and formulates different calculation rules for the boundary structure of the two regions. This reduces the possibility of overly strict defect judgment criteria for corner regions, reduces misjudgment and waste, and saves costs. At the same time, the use of digital image processing technology can quickly obtain the various parameters required for the calculation process without manual measurement and calculation. This not only avoids the influence of subjective human factors on the stability of detection, but also reduces the intensity of manual labor, improves detection efficiency, and achieves cost reduction and efficiency improvement. Attached Figure Description
[0042] Figure 1 A process flowchart of a method for inspecting sealing defects of a device cap using X-rays, provided in an embodiment of the present invention;
[0043] Figure 2 This is a flowchart illustrating the process of obtaining the target contour of the sealing area based on digital image processing technology in an embodiment of the present invention.
[0044] Figure 3 This is a schematic diagram of the structure of the device package in the X-ray Y direction view in an embodiment of the present invention;
[0045] Figure 4This is a schematic diagram illustrating the calculation method for sealing defects of caps in existing technologies;
[0046] Figure 5 This is a schematic diagram illustrating the calculation method for sealing defects of the cap in an embodiment of the present invention;
[0047] Figure 6 This is a simulation diagram of the X-ray Y-axis view of the device package in an embodiment of the present invention;
[0048] Figure 7 To be Figure 6 The simulation image of the X-ray Y-axis view after grayscale processing;
[0049] Figure 8 This is a simulation image of the grayscale distribution before histogram equalization.
[0050] Figure 9 This is a simulation image of the grayscale distribution after histogram equalization.
[0051] Figure 10 for Figure 7 The image shown is a simulation image obtained after histogram equalization.
[0052] Figure 11 To Figure 10 The image shown is a simulation image obtained after bilateral filtering and noise reduction processing.
[0053] Figure 12 To Figure 11 The image shown is a simulation of the enhanced image obtained after gamma transformation.
[0054] Figure 13 To Figure 12 The image shown is a simulation image obtained after thresholding.
[0055] In the diagram: 10. Sealing area; 11. Edge area; 12. Corner area; 13. Other areas; 20. Defect. Detailed Implementation
[0056] To make the technical problems to be solved, the technical solutions, and the beneficial effects of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present invention and are not intended to limit the present invention.
[0057] It should be noted that the X-ray Y-axis view of the device cover can be understood as a top view of the device cover; here, Y-axis view is a technical term.
[0058] Please refer to the following: Figures 1 to 5The present invention will now describe a method for inspecting sealing defects of a device using X-rays. The method for inspecting sealing defects of a device using X-rays includes:
[0059] Obtain an X-ray Y-axis view of the device cover, and divide the cover sealing area 10 in the X-ray Y-axis view into multiple edge area 11 and multiple corner area 12, wherein the inner and outer boundaries of the edge area 11 are straight lines, and the inner and outer boundaries of the corner area 12 are curves.
[0060] Determine the calculation formulas for defects 20 in the edge area and the corner area respectively;
[0061] The inner boundary contour, outer boundary contour, and defect contour of the sealing area are obtained based on digital image processing technology.
[0062] The parameters of the defect calculation formula are obtained based on the inner boundary profile, outer boundary profile, and defect profile, and the sealing defect ratio of the cap is calculated.
[0063] It should be noted that for defect calculation in the edge area, the existing standard can be used in this embodiment. For defect calculation in the corner area, the specific structure of the corner area needs to be considered. Specifically, the inner and outer boundaries of the corner area are curves (the inner boundary is a pure arc, and the outer boundary is a combination of arcs and straight lines). Therefore, the inner boundary of the corner area extends radially to the outer boundary. This makes the shortest path between the defect and the inner and outer boundaries not the same as the horizontal or vertical path in the edge area. Therefore, to reduce the possibility of overly strict criteria, a different calculation formula is chosen here than that for the edge area.
[0064] The method for inspecting sealing defects of device caps using X-rays provided in this embodiment, compared with the prior art, divides the X-ray Y-axis view into edge region and corner region, and formulates different calculation rules for the boundary structure of the two regions. This reduces the possibility of overly strict defect judgment criteria for corner region, reduces misjudgment and waste, and saves costs. At the same time, the use of digital image processing technology can quickly obtain the various parameters required for the calculation process without manual measurement and calculation. This not only avoids the impact of human subjective factors on the stability of detection, but also reduces the intensity of manual labor, improves detection efficiency, and achieves cost reduction and efficiency improvement.
[0065] In some embodiments, see Figure 5 The formula for calculating defects in the edge area is: The formula for calculating defects in the corner area is: , where L A L represents the shortest path distance between the defect profile and the outer boundary profile. BL is the shortest path distance between the defect profile and the inner boundary profile; L is the distance between the inner and outer boundaries of the edge region corresponding to the location of the defect; L1 is the minimum distance from the intersection of the shortest straight path between the defect profile and the inner and outer boundaries of the corner region to the outer boundary profile; L2 is the minimum distance from the intersection of the shortest straight path between the defect profile and the inner and outer boundaries of the corner region to the inner boundary profile.
[0066] It should be understood that sealing defects affect product reliability because they can cause air leakage in hermetic devices to some extent. For the edge area, since its inner and outer boundaries are parallel straight lines, its sealing width (distance between inner and outer boundaries) is a fixed value. The effective sealing dimension excluding the defective area can be understood as the distance between the inner and outer boundaries minus the maximum value of the defective area in the sealing width direction. For corner areas, the shortest path distance L is obtained by drawing a straight line connecting the center point of the outer boundary contour and the center point of the inner boundary contour within the area. A This can be viewed as the distance the outer boundary contour moves along the straight line towards the inner boundary contour until it contacts the target defect contour. Similarly, the shortest path distance L B This can be viewed as the distance the inner boundary contour moves along the straight line in the opposite direction towards the outer boundary contour until it contacts the target defect contour. Then, based on the shortest path distance L... A and the shortest path distance L B The two shortest paths can be extended to intersect. The complete sealing path is the sum of the shortest distances (L1 and L2) between the intersection point and the inner and outer boundary contours, respectively. It can be understood that the sum of the shortest path distances is the effective sealing distance when defects occur. Using the ratio of the shortest path to the complete sealing path as a criterion is more lenient and accurate than conventional criteria, while meeting the airtightness requirements. This can avoid misjudgment and material waste, and help reduce costs.
[0067] It should be noted that, due to various reasons, the resolution of X-ray Y-axis views of device covers is usually poor. It is necessary to highlight the outer and inner boundary contours of the cover seal, as well as the defect contours within the seal area. Only after obtaining these boundaries can the coordinates of the contour pixels be accurately obtained. Then, calculations are performed according to the established formulas. For details, please refer to [link to relevant documentation]. Figures 6 to 13 In this embodiment, obtaining the inner boundary contour, outer boundary contour, and defect contour of the sealing area based on digital image processing technology includes:
[0068] Step S100, Image grayscale conversion: The X-ray Y-axis view is dimensionality reduced to transform it from a three-channel RGB color image into a single-channel grayscale image;
[0069] Step S200, Histogram equalization: By changing the pixel value distribution of a single-channel grayscale image, the dynamic range of the image is compressed and the contrast of the image is enhanced.
[0070] Step S300, Image noise removal: The bilateral filtering method is used to remove the noise generated during the generation and transmission of the X-ray Y-axis view, as well as the noise generated during the image grayscale conversion and histogram equalization process;
[0071] Step S400, Image Enhancement: Enhance image contrast through gamma transformation to highlight the target area;
[0072] Step S500, Image threshold segmentation: The inner boundary contour and outer boundary contour of the sealing area of the cap, as well as the defect contour, are segmented on the entire sealing area of the cap to obtain the inner boundary contour, outer boundary contour, and defect contour.
[0073] As a specific implementation of the above-mentioned image grayscale conversion, image grayscale conversion includes: converting the image data of the X-ray Y-axis view from a three-dimensional matrix to a two-dimensional matrix through a weighted averaging algorithm, thereby obtaining a single-channel grayscale image.
[0074] Since the directly obtained X-ray Y-axis view is an RGB color image with a three-channel color space, its image feature information is extremely rich. Directly processing and analyzing the color image would be complex and time-consuming. To simplify the algorithm and improve efficiency, the color image needs to be converted to grayscale. This process reduces the image data from a three-dimensional matrix to a two-dimensional matrix, thus obtaining a single-channel grayscale image. Specifically, a weighted average algorithm can be used to obtain the grayscale image. The formula for the weighted average algorithm is as follows: ,in, These are the pixel coordinates of the template center.
[0075] As a specific implementation of the above-mentioned histogram equalization, histogram equalization includes: determining the gray level probability density function of a single-channel grayscale image; determining the cumulative gray level probability distribution function of the single-channel grayscale image based on the gray level probability density function; and transforming the single-channel grayscale image to the entire gray level range using a transformation function.
[0076] Specifically, the gray-level probability density function is: The cumulative probability distribution function for gray levels is: The conversion function is: The grayscale range is ;
[0077] in,
[0078] It is grayscale;
[0079] grayscale Number of times it appears;
[0080] n is the total number of pixel levels in the input image.
[0081] It should be understood that the distribution of the histogram reflects the brightness of the image in the X-ray Y-axis view. If the image is dark, the histogram pixels are mainly concentrated in the smaller value range. When the image is bright overall, the histogram pixel distribution shifts to the larger value range. In addition, the distribution of the histogram also reflects the contrast of the image. Low-contrast images have small pixel value changes and the histogram pixel grayscale level distribution is concentrated. High-contrast images have significant pixel value changes, corresponding to a wider histogram pixel distribution range. The grayscale values of the X-ray Y-axis view after grayscale conversion are generally between 50 and 120, with a small dynamic range. The image is generally dark, and the outline of the sealing defect is not clearly distinguishable from the background. In view of this situation, the histogram equalization algorithm is used to enhance the image based on the characteristics of the image pixel distribution, thereby achieving the effect of compressing the dynamic range of the image, improving the image contrast, and making the sealing defect of the product more obvious.
[0082] Combination Figures 7 to 10 As can be seen, the image obtained through histogram equalization shows a clear difference between the before and after. The brightness of the sealing defect is greatly improved, and it can be well distinguished from other areas. The defect turns into an almost white color, making it more conspicuous, and the visual effect is further enhanced.
[0083] It should be noted that in this embodiment, for step S300, due to the influence of sensors, imaging components and transmission channels during the generation and transmission of image information, a certain amount of noise will inevitably be generated. In addition, noise will also be generated during the conversion and processing of images. Theoretically speaking, noise is an unpredictable random error. However, the presence of noise will reduce the image quality to a certain extent and affect subsequent processing and feature extraction. Therefore, in order to better perform processing and analysis, it is very necessary to reduce or eliminate various noises and interferences in the image.
[0084] This paper adopts a nonlinear bilateral filtering method, which can take into account not only spatial proximity but also pixel value similarity. The filter kernel function of the bilateral filtering method consists of a Gaussian function in the spatial domain and a Gaussian kernel function in the gray-level distance domain.
[0085] The filter kernel function is: ;
[0086] The Gaussian function in the spatial domain is: ;
[0087] The Gaussian kernel function for the grayscale distance range is given by the following formula: ;
[0088] In the formula, The center pixel coordinates of the template Create a table for the neighboring pixels of the template. is the standard deviation of the Gaussian function.
[0089] For step S400, when the image cannot clearly distinguish the target region (inner boundary contour, outer boundary contour, defect contour), the contrast can be enhanced to highlight the target region and improve its recognition and clarity. Here, gamma transform, also known as exponential transform, is used. It is a typical nonlinear transform, and its formula is: Where a is the original image. The minimum value of the medium gray level, c is the original image. The reciprocal of the maximum gray level, b is the maximum gray level value of the transformed image (usually 256). It can be seen that exponential transformation can achieve a large stretching of the high gray level area of the image.
[0090] Among some possible implementations, image thresholding segmentation includes: obtaining all defect contours within the sealed area of the cap through thresholding segmentation; uniformly extracting and storing each defect contour in a Vector region; obtaining the inner boundary contour and outer boundary contour through thresholding segmentation, extracting the inner boundary contour and outer boundary contour, and rotating them to the horizontal plane of the image.
[0091] In this embodiment, the calculation formula for the threshold segmentation method is as follows: .
[0092] For example, for defect calculation in the edge region, the intersection of the edge region and the vector region is taken to obtain the edge region set. Based on the edge region set, the shortest path distance L is calculated by sequentially selecting each defect contour. A Shortest path distance L B , Spacing L between inner and outer boundaries.
[0093] For example, in calculating defects in corner regions, the intersection of the corner region and the Vector region is taken to obtain a set of corner regions. Based on the set of corner regions, the shortest path distance L is calculated by sequentially selecting each defect contour. A Shortest path distance L B Calculate the shortest straight-line distances from the intersection of the extensions of the two shortest paths to the outer and inner boundary contours, respectively, and obtain the minimum values L1 and L2.
[0094] In some embodiments, see Figure 5The sealing area 10 is a rectangular ring with rounded inner and outer corners. The area enclosed by the intersection of the extended straight edge of the inner boundary contour and the outer boundary contour is the corner area 12. Thus, the sealing area includes four edge areas 11, four corner areas 12, and other areas 13 other than the four edge areas and corner areas. The defects in other areas are calculated using the same defect calculation formulas for edge areas and corner areas.
[0095] Since other areas intersect with both the edge area and the corner area, defects in these areas can be calculated using both the edge area defect calculation formula and the corner area defect calculation formula. Both calculation results are provided for users to choose the appropriate result based on their needs.
[0096] 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, and improvements made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for inspecting sealing defects in device caps using X-rays, characterized in that, include: Obtain an X-ray Y-axis view of the device cover, and divide the sealing area of the cover in the X-ray Y-axis view into multiple edge area and multiple corner area, wherein the inner and outer boundaries of the edge area are straight lines, and the inner and outer boundaries of the corner area are curves; Determine the defect calculation formulas for the edge region and the corner region respectively; The inner boundary contour, outer boundary contour, and defect contour of the sealing area of the cap are obtained based on digital image processing technology. The parameters of the defect calculation formula are obtained based on the inner boundary profile, the outer boundary profile, and the defect profile, and the sealing defect ratio of the cap is calculated. The formula for calculating defects in the edge region is as follows: , The formula for calculating defects in the corner area is: , Among them, L A This is the shortest path distance between the defect profile and the outer boundary profile. L B This is the shortest path distance between the defect profile and the inner boundary profile. L is the distance between the inner and outer boundaries of the edge region corresponding to the location of the defect; L1 is the minimum distance from the intersection point of the shortest straight path between the defect profile and the outer and inner boundaries of the corner area to the outer boundary profile. L2 is the minimum distance from the intersection point of the shortest straight path between the defect profile and the inner and outer boundaries of the corner area to the inner boundary profile.
2. The method for inspecting sealing defects of a device cap using X-rays as described in claim 1, characterized in that, The process of obtaining the inner boundary contour, outer boundary contour, and defect contour of the sealing area based on digital image processing technology includes: Image grayscale conversion: The X-ray Y-axis view is subjected to dimensionality reduction processing to transform it from a three-channel RGB color image into a single-channel grayscale image; Histogram equalization: By changing the pixel value distribution of the single-channel grayscale image, the dynamic range of the image is compressed and the contrast of the image is enhanced; Image noise reduction processing: Bilateral filtering is used to remove noise generated during the generation and transmission of the X-ray Y-axis view, as well as noise generated during the image grayscale conversion and histogram equalization processes; Image enhancement: Enhance image contrast and highlight target areas through gamma transformation; Image thresholding: The inner boundary contour, outer boundary contour, and defect contour of the sealing area of the cap are segmented on the entire sealing area to obtain the inner boundary contour, the outer boundary contour, and the defect contour.
3. The method for inspecting sealing defects of a device cap using X-rays as described in claim 2, characterized in that, The image grayscale conversion includes: The image data of the X-ray Y-axis view is converted from a three-dimensional matrix to a two-dimensional matrix using a weighted average algorithm, thereby obtaining the single-channel grayscale image.
4. The method for inspecting sealing defects of a device cap using X-rays as described in claim 2, characterized in that, The histogram equalization includes: Determine the gray level probability density function of the single-channel grayscale image; The cumulative probability distribution function of the gray levels of the single-channel grayscale image is determined based on the gray level probability density function. The single-channel grayscale image is transformed by mapping it to the entire grayscale range using a transformation function.
5. The method for inspecting sealing defects of a device cap using X-rays as described in claim 4, characterized in that, The gray level probability density function is: The cumulative probability distribution function of the gray level is: The conversion function is: The grayscale range is ; in, It is grayscale; grayscale Number of times it appears; n is the total number of pixel levels in the input image.
6. The method for inspecting sealing defects of a device cap using X-rays as described in claim 2, characterized in that, The image thresholding segmentation includes: All defect contours within the sealing area of the cap are obtained by threshold segmentation; Extract all the aforementioned defect contours and store them in the Vector area; The inner boundary contour and the outer boundary contour are obtained by threshold segmentation, and the inner boundary contour and the outer boundary contour are extracted and rotated to the horizontal plane of the image.
7. The method for inspecting device cap sealing defects using X-rays as described in claim 6, characterized in that, For the defect calculation of the edge region, the intersection of the edge region and the Vector region is taken to obtain the edge region set. Based on the edge region set, the shortest path distance L is calculated for each defect contour in turn. A Shortest path distance L B , Spacing L between inner and outer boundaries.
8. The method for inspecting sealing defects of a device cap using X-rays as described in claim 6, characterized in that, For the defect calculation in the corner region, the intersection of the corner region and the Vector region is taken to obtain a corner region set. Based on the corner region set, the shortest path distance L is calculated for each defect contour in turn. A Shortest path distance L B Calculate the shortest straight-line distances from the intersection of the extensions of the two shortest paths to the outer boundary contour and the inner boundary contour, respectively, to obtain the minimum values L1 and L2.
9. The method for inspecting sealing defects of a device cap using X-rays as described in any one of claims 1-8, characterized in that, The sealing area of the cap is a rectangular ring with rounded inner and outer corners. The area enclosed by the intersection of the extended straight edge of the inner boundary contour and the outer boundary contour is the corner area. Thus, the sealing area of the cap includes four edge areas, four corner areas, and other areas other than the four edge areas and the corner areas. The defects in the other regions are calculated using the same defect calculation formulas for the edge region and the corner region.