Detection Method and Detection System

Image compression and gradient analysis improve the precision of critical dimension measurement in semiconductor detection by enhancing the signal-to-noise ratio and achieving sub-pixel accuracy.

CN114612372BActive Publication Date: 2025-07-15SKYVERSE TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202011425019.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-12-08
Publication Date
2025-07-15
Estimated Expiration
2040-12-08

AI Technical Summary

Technical Problem

Traditional semiconductor detection methods are difficult to meet the high accuracy requirements for critical size measurements, especially when critical sizes of semiconductor devices are reduced.

Method used

By compressing the image, the image of interest is acquired and compressed in the first direction, the grayscale values of the multiple pixels are compressed into one compressed grayscale, and the edge point position information of the target image is obtained using the compressed grayscale curve.

Benefits of technology

Improve detection accuracy, realize subpixel accuracy of edge point position acquisition, reduce interference from background data, and enhance signal-to-noise ratio and contrast.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114612372B_ABST
    Figure CN114612372B_ABST
Patent Text Reader

Abstract

The present invention provides a detection method and a detection system. Among them, the method includes: acquiring an image of a test object to obtain a to-be-processed image, where the surface of the test object has a test target, and the to-be-processed image includes a target image of the test target; performing a partitioning process on the to-be-processed image to obtain at least one region of interest image, the region of interest image includes a target image of at least a part of the edge of the test target, and the region of interest image includes a plurality of pixels in a first direction; performing a compression process on the region of interest image along the first direction, so that the gray values of the plurality of pixels of the region of interest image in the first direction are compressed into a compressed gray value, and obtaining the compressed gray values of the pixels of the region of interest image in a second direction to obtain a compressed gray value curve. By performing a compression process on the region of interest image, the signal-to-noise ratio of the obtained compressed gray value curve can be increased, thereby improving the detection accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a detection method and a detection system, in particular to a method and a system for detecting a target to be detected through image processing. Background Art

[0002] In semiconductor detection, it is usually necessary to detect the critical dimensions of a target to be detected. Imaging the target to be detected and obtaining the critical dimensions of the target to be detected from the image of the target to be detected are common technical means in the detection field.

[0003] The method used to measure critical dimensions in traditional technologies is as follows: First, use template matching, etc. to find the approximate region of interest of the dimension to be measured, then use an edge extraction algorithm (such as canny, etc.) to calculate the position of the edge within the region of interest, and then use an algorithm such as least squares to fit to obtain the critical dimension information.

[0004] However, with the reduction of the critical dimensions of semiconductor devices, the accuracy requirements for critical dimension measurement are continuously increasing, and traditional measurement methods are difficult to meet the requirements of semiconductor detection. The technical solution of the present invention provides a detection method that can improve the detection accuracy. Summary of the Invention

[0005] To solve the above problems, the present invention proposes a detection method that can improve the signal-to-noise ratio of the compressed grayscale image by performing compression processing on the image, thereby improving the detection accuracy.

[0006] The technical solution of the present invention provides a detection method, which is characterized in that it includes: obtaining an image of the object to be detected to obtain an image to be processed, the surface of the object to be detected has a target to be detected, and the image to be processed includes a target image of the target to be detected; performing a partitioning process on the image to be processed to obtain at least one image of interest, the image of interest includes a target image of at least part of the edge of the target to be detected, and the image of interest includes a plurality of pixels in a first direction; performing compression processing on the image of interest along the first direction, so that the grayscale values of the plurality of pixels of the image of interest in the first direction are compressed into a compressed grayscale, obtaining a compressed grayscale curve of each pixel of the image of interest in a second direction, the second direction is different from the first direction; according to the compressed grayscale curve, obtaining the position information of the edge points of the target image.

[0007] Optionally, the step of compressing the image of interest in the first direction includes: selecting any pixel in the second direction of the image of interest to obtain a reference point; performing a linear combination on all pixels of the image of interest in the first direction passing through the reference point to obtain the compressed gray level of the reference point; repeating the steps of obtaining the reference point and the compressed gray level to obtain the compressed gray levels of multiple pixels in the second direction of the image of interest, thereby obtaining the compressed gray level curve.

[0008] Optionally, the linear combination includes: summing, averaging, or weighting the gray levels of all pixels in the first direction passing through the reference point; the first direction is a straight line, and the second direction is perpendicular to the first direction.

[0009] Optionally, the step of obtaining the position information of the edge points of the target image according to the compressed gray level curve includes: partitioning the image of interest to obtain the edge region of the target image; performing an edge point obtaining operation on one or more edge region images of interest respectively to obtain the position information of the edge points of the target image in the edge region.

[0010] Optionally, the image of interest includes: a first number of separate edge points located in the second direction, where the first number is multiple; the partitioning step includes: obtaining the initial position information of the edge points of the target image according to the compressed gray level curve; obtaining the edge region of the target image in the image of interest according to the initial position information of the edge points.

[0011] Optionally, the image of interest includes the first number of separate edge points of the target image located in the second direction respectively; the step of obtaining the edge region of the target image in the image of interest according to the initial position information of the edge points includes: obtaining the initial center of the target image according to the initial position information of the edge points; obtaining the edge region of the target image in the image of interest according to the preset size of the target image and the initial center point.

[0012] Optionally, the step of obtaining the initial position information of the edge points of the target image according to the compressed gray level curve includes: obtaining the gradient of each point of the compressed gray level curve; obtaining a gradient curve according to the correspondence between the gradient of each pixel of the compressed gray level curve and the position of each pixel; obtaining the initial position information according to the gradient curve.

[0013] Optionally, the step of obtaining the initial position information according to the gradient curve includes: obtaining the pixel positions corresponding to the gradients of the top second number among the gradients of each pixel to obtain the initial position information of the second number of edge points; or, performing function fitting on the gradient curve to obtain a first fitting function; obtaining the extreme points of the first fitting function; obtaining the positions corresponding to the gradients of the extreme points of the top second number of gradient values to obtain the initial position information of the edge points, where the first number is less than or equal to the second number.

[0014] Optionally, the edge point obtaining operation includes: obtaining the gradient of the compressed grayscale curve of the image of interest in the edge region to obtain an edge gradient; obtaining the relationship curve between the edge gradient of each pixel in the edge region and the position of the corresponding pixel to obtain an edge gradient curve; obtaining the position information of edge points in the edge region according to the edge gradient curve.

[0015] Optionally, the step of obtaining the position information of edge points in the edge region according to the edge gradient curve includes: obtaining the pixel position corresponding to the maximum edge gradient in each edge region to obtain the position information of the edge points; or,

[0016] obtaining the pixel positions corresponding to the edge gradients of the top third number of gradient values in the edge region to obtain candidate edge points; using a fitting function to fit the gradients of the candidate edge points to obtain a fitting curve; obtaining the position corresponding to the maximum gradient value on the fitting curve to obtain the position information of the edge points; the third number is multiple.

[0017] Optionally, the fitting function includes: Gaussian, quadratic curve or cosine function.

[0018] Optionally, the number of candidate edge points in each edge region is greater than or equal to 3.

[0019] Optionally, the target image is circular, and the preset size is the preset diameter or preset radius of the target image;

[0020] Optionally, the step of obtaining the edge region of the target image in the image of interest includes: obtaining the region with a predetermined width where the circle with the initial center as the center and the preset radius as the radius is located to obtain the edge region.

[0021] Optionally, before obtaining the initial position information according to the gradient curve, the step of obtaining the initial position information of at least two separated edge points in the second direction of the target image according to the compressed grayscale curve further includes: performing optimization processing on the gradient curve to increase the signal-to-noise ratio of the gradient curve.

[0022] Optionally, the steps of the optimization process include: obtaining a reference curve, where the reference curve represents the gradient curve of the object to be measured; performing a multiplication process on the reference curve and the gradient curve to obtain an optimized gradient curve; the multiplication process includes dot product or convolution, and the reference curve includes: the gradient curve of a reference object or the mirror curve of the gradient curve of the reference object, where the reference object is the designed gradient curve of the object to be measured or a standard object to be measured.

[0023] Optionally, the target image is a polygon; the first direction is parallel to one side of the target image.

[0024] Optionally, the number of the images of interest is multiple, and there is a preset included angle between the second directions of the multiple images of interest;

[0025] The method further includes: repeating the step of performing the compression process on the multiple images of interest until the position information of the edge points of the target image is obtained according to the gray curve, to obtain the position information of multiple edge points of the target image; obtaining the edge contour of the target image according to the position information of the multiple edge points.

[0026] Optionally, before obtaining the edge contour of the target image according to the position information of the multiple edge points, the method further includes: performing a denoising process on the multiple edge points; the method of the denoising process includes: a random sampling algorithm.

[0027] Optionally, the method further includes: obtaining the target size of the target image according to the edge contour; obtaining the size to be measured of the object to be measured according to the target size and the magnification ratio between the target image and the object to be measured; and / or, the method further includes: obtaining the target center of the target image according to the edge contour.

[0028] Optionally, there are multiple objects to be measured on the surface of the object to be measured, and the multiple objects to be measured include a first object to be measured and a second object to be measured;

[0029] The image to be processed includes multiple target images, and the multiple target images include: a first target image of the first object to be measured and a second target image of the first object to be measured;

[0030] The method further includes: obtaining the target center of the target image according to the edge contour; repeating the step of dividing the image to be processed until the target center is obtained, until the first target center of the first target image and the second target center of the second target image are obtained; obtaining the offset between the first object to be measured and the second object to be measured according to the first target center and the second target center.

[0031] Optionally, the image of interest includes two separate edge points of the target image located in the second direction respectively; obtaining the position information of the edge points of the target image according to the compressed grayscale curve includes: obtaining the edge points located at both ends in the second direction according to the compressed grayscale curve to obtain a first edge point and a second edge point;

[0032] The method further includes: obtaining the width of the target image along the second direction according to the position information of the first edge point and the second edge point.

[0033] Optionally, the steps of the partitioning process include: providing a template image, where the template image is a standard image of the target to be measured; using the template image to match the image to be processed to obtain a matching region; segmenting the matching region to obtain the image of interest; the image of interest further includes the center of the matching region.

[0034] Optionally, the positions of the points on the edges of the target image in the image of interest are smooth curves or straight lines.

[0035] A detection system includes a processing system for the above detection method.

[0036] In the detection method provided by the technical solution of the present invention, by performing a partitioning process on the image to be processed to obtain an image of interest, and by performing a compression process on the image of interest, the grayscale values of multiple pixels in the first direction of the image of interest are compressed into one compressed grayscale, which can equalize the target edge data and the background data, so that the target edge data stands out from the background data, increasing the signal-to-noise ratio of the obtained compressed grayscale curve, thereby increasing the accuracy of the position information of the obtained edge points, and further improving the detection accuracy.

[0037] Furthermore, obtaining the compressed grayscale of the reference point according to the linear combination grayscale of all pixels in the first direction passing through the reference point can improve the contrast of the compressed grayscale image.

[0038] Furthermore, performing a partitioning process on the image of interest to obtain an edge region of the target image, and obtaining the position information of the edge points of the target image according to the image of interest in the edge region can reduce the interference of the non-edge region image on obtaining the position information of the edge points, thereby improving the detection accuracy.

[0039] Furthermore, performing a function fitting on the compressed grayscale curve or the gradient curve can obtain the compressed grayscale or gradient at any point, thereby accurately obtaining the position of the point corresponding to the maximum gradient, and further realizing sub-pixel accuracy and improving the accuracy of the obtained initial position information.

[0040] Further, pixels corresponding to the edge gradients with the top third largest gradient values in each edge region are obtained to get candidate edge points, and a fitting curve is obtained by fitting the gradients of the candidate edge points using a fitting function; the fitting curve represents the gradient at any point, so that the position of the point corresponding to the maximum gradient can be obtained, and sub-pixel accuracy can be achieved. At the same time, by obtaining pixels corresponding to edge gradients with the top several largest gradient values to get candidate edge points, interference from non-edge points can be reduced, the fitting difficulty can be lowered, and the complexity of the algorithm can be decreased.

[0041] Further, the denoising process can eliminate outliers among the edge points, thereby improving the detection accuracy.

[0042] Further, the optimization process can perform a multiplication process on the mirror curve and the gradient curve, which can increase the gradient values of the edge points in the gradient curve, thereby increasing the signal-to-noise ratio of the gradient curve, and further increasing the accuracy of the obtained edge region.

[0043] Further, through the partitioning process, the image of interest includes the center of the matching region, which can reduce the deviation between the center point and the center of the target image, thereby increasing the detection accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] The present invention will be specifically described below with reference to the drawings and in combination with embodiments. The advantages and implementation manners of the present invention will become more obvious. Among them, the content shown in the drawings is only used to explain the present invention and does not constitute any limitation to the present invention in any sense. The drawings are only schematic and are not drawn strictly to scale. In the drawings:

[0045] Figure 1 A flowchart showing the steps of an embodiment of the detection method provided by the technical solution of the present invention is shown;

[0046] Figures 2 to 3 A schematic structural diagram showing the steps of the compression process and the partitioning process in an embodiment of the detection method provided by the technical solution of the present invention is shown.

[0047] Figure 4 A flowchart showing the steps of obtaining the position information of the edge points of the target image according to the compressed gray curve in an embodiment of the detection method provided by the technical solution of the present invention is shown;

[0048] Figure 5 A flowchart showing the steps of the zoning process and the edge point acquisition operation in an embodiment of the detection method of the present invention;

[0049] Figures 6 to 7 A schematic diagram showing the steps shown in an embodiment of the detection method provided by the technical solution of the present invention Figure 4 is shown. Specific embodiments

[0050] During the detection process, the key dimensions of the object to be measured are often obtained by extracting the edges of the target image. A commonly used method for extracting the edges of the target image includes: first, finding the two-dimensional region of interest of the dimension to be measured by using template matching, etc.; within the two-dimensional region of interest, calculating the position of the edge by using an edge extraction algorithm (for example, canny, etc.); then, obtaining the key dimension information by fitting the extracted edge with a function. However, when the background gray level is uneven or the gray level of the background is close to the gray level value of the target image edge, it is very difficult to extract the edge data by using the edge extraction algorithm.

[0051] The technical solution of the present invention provides a detection method, including: performing compression processing on the image of interest along a first direction, compressing the gray levels of multiple pixels of the image of interest in the first direction into a compressed gray level, and obtaining a compressed gray level curve of each pixel of the image of interest in a second direction; according to the compressed gray level curve, obtaining the position information of the edge points of the target image. By performing compression processing on the image of interest, the signal-to-noise ratio of the compressed gray level curve can be improved, thereby improving the detection accuracy.

[0052] Figure 1 It is a flowchart of each step of an embodiment of the detection method provided by the technical solution of the present invention.

[0053] Refer to Figure 1 , the technical solution of the present invention provides a detection method, including the following steps:

[0054] Step S1, obtaining an image of the object to be measured to obtain an image to be processed, where the surface of the object to be measured has a target to be measured, and the image to be processed includes a target image of the target to be measured;

[0055] Step S2, performing partitioning processing on the image to be processed to obtain at least one image of interest, where the image of interest includes a target image of at least part of the edge of the target to be measured, and the image of interest includes multiple pixels in a first direction;

[0056] Step S3, performing compression processing on the image of interest along the first direction, compressing the gray levels of multiple pixels of the image of interest in the first direction into a compressed gray level, and obtaining a compressed gray level curve of each pixel of the image of interest in a second direction, where the second direction is different from the first direction;

[0057] Step S4, obtaining the position information of the edge points of the target image according to the compressed gray level curve.

[0058] The technical solution of the present invention performs a partitioning process on the image to be processed to obtain an image of interest. By performing a compression process on the image of interest, the gray values of multiple pixels in the first direction of the image of interest are compressed into a compressed gray value, which can equalize the target edge data and the background data, thereby highlighting the target edge data from the background data, increasing the signal-to-noise ratio of the obtained compressed gray curve, and further increasing the position information of the obtained edge points, thereby improving the detection accuracy.

[0059] Figures 2 to 3 Fig. shows a schematic structural diagram of each step of the compression process and the partitioning process in an embodiment of the detection method provided according to the technical solution of the present invention.

[0060] The image in this embodiment includes: the position information and gray value of each pixel, the position information and the gray value correspond one by one, and the position information of each pixel on the image corresponds one by one to the position of the surface points of the object to be measured.

[0061] The following Figure 2 in combination with the drawings will elaborate on the technical solution of the present invention in detail.

[0062] Referring to Figure 2 , perform step S1 to obtain an image of the object to be measured, and obtain the image to be processed 10. The surface of the object to be measured has a target to be measured, and the image to be processed 10 includes the target image 12 of the target to be measured.

[0063] In this embodiment, the object to be measured is a patterned wafer or chip. In other embodiments, the object to be measured may be an OLED panel or a mobile phone screen.

[0064] In this embodiment, the surface to be measured of the target to be measured is circular, and correspondingly, the target image 12 is circular. Specifically, the target to be measured is a pad. In other embodiments, the surface to be measured of the target to be measured is polygonal, such as rectangular.

[0065] Continue to refer to Figure 2 , perform step S2 to perform a partitioning process on the image to be processed 10 to obtain at least one image of interest 11. The image of interest 11 includes at least part of the edge of the target image 12, and the image of interest 11 includes multiple pixels in the first direction.

[0066] The partitioning process can extract the image of interest 11, thereby reducing the interference of the non-image of interest 11.

[0067] The steps of the partitioning process include: providing a template image, which is a standard image of the target to be measured; using the template image to match the image to be processed 10 to obtain a matching area; and segmenting the matching area to obtain the image of interest 11.

[0068] In this embodiment, the region of interest image 11 further includes the center of the matching region. By performing the division process to make the region of interest image 11 include the center of the matching region, the deviation between the center point and the center of the target image can be reduced, thereby increasing the detection accuracy.

[0069] The template image is used to match the image to be processed 10, and the region of the image to be measured that meets the threshold conditions is obtained to get the matching region; the threshold conditions include: making the difference parameter between the gray levels of each pixel point in the matching region and the corresponding pixel gray levels of the template image less than a preset value, and the difference parameter is positively correlated with the gray level difference; the gray level difference is the sum of the absolute values of the differences between the gray levels of each pixel point in the matching region and the corresponding pixel gray levels of the template image; specifically, the difference parameter is the sum of the absolute values of the differences between the gray levels of each pixel point in the matching region and the corresponding pixel gray levels of the template image, or the difference parameter is the average value of the absolute values of the differences between the gray levels of each pixel point in the matching region and the corresponding pixel gray levels of the template image, or the difference parameter is the sum or average value of the squares of the differences between the gray levels of each pixel point in the matching region and the corresponding pixel gray levels of the template image.

[0070] In this embodiment, the positions of the points on the edge of the target image 12 in the region of interest image 11 are smooth curves or straight lines. If the positions of the points on the edge of the target image 12 are smooth curves or straight lines, then the edges of the target image 12 in the region of interest are all in the same first direction or near the same first direction. Furthermore, after compressing the region of interest image 11, the gray level difference between the edge of the target image 12 and the background can be increased, and thus the contrast of the compressed gray level image can be further increased.

[0071] If the number of pixels of the region of interest image 11 in the first direction is too small, it is not conducive to increasing the image contrast. If the number of pixels of the region of interest image 11 in the first direction is too large, the complexity of the compression process is likely to increase. Specifically, in this embodiment, the number of pixels of the region of interest image 11 in the first direction is 10 to 50.

[0072] In this embodiment, the first direction is a straight line, and the first direction is parallel to the row or column of the pixels of the image to be processed 10, which is conducive to simplifying the calculation. In other embodiments, the first direction is a curve. For example, when the target image 12 is circular, the first direction is a plurality of concentric arcs centered on the center of the target image 12.

[0073] The region of interest image further includes a second direction A. When the first direction is a straight line, the second direction A is perpendicular to the first direction.

[0074] When the first direction is a curve, the second direction A is perpendicular to the tangent of the first direction.

[0075] In another embodiment, the target image 12 is a polygon, and the first direction is parallel to the side of the target image 12. Specifically, the target image 12 is a rectangle, and the first direction and the second direction A are straight lines and are respectively parallel to two sides of the target image 12.

[0076] In this embodiment, the region of interest image 11 is elongated. In other embodiments, the region of interest image may be square or other shapes.

[0077] In this embodiment, the region of interest image 11 includes the center of the matching region. By the division process, making the region of interest image 11 include the center of the matching region can reduce the deviation between the center point and the center of the target image 12, thereby increasing the detection accuracy. In other embodiments, the region of interest image 11 may not include the center of the matching region.

[0078] In this embodiment, the region of interest image 11 includes at least two edge points at both ends of the second direction A on the edge of the target image 12. Specifically, the region of interest image 11 penetrates the target image 12 in the second direction A. In other embodiments, the region of interest image 11 may only include one edge point located in the second direction A.

[0079] In this embodiment, the number of the region of interest images 11 is multiple; there is a preset angle between the second directions A of the multiple region of interest images 11, and each region of interest image 11 includes the center of the matching region.

[0080] In this embodiment, the preset angles between different region of interest images are equal. In other embodiments, the preset angles between different region of interest images may not be the same.

[0081] Specifically, in this embodiment, the preset angle is 5° to 45°, such as 15° or 30°.

[0082] In other tests, the multiple region of interest images 11 are bar-shaped, and the extending direction of each region of interest image 11 is parallel to the second direction A, and there is a preset distance between the centers of adjacent region of interest images 11 in the first direction.

[0083] Combined with reference Figure 2 and Figure 3, perform step S3, compress the interested image 11 along the first direction, compress the gray values of multiple pixels of the interested image 11 in the first direction into a compressed gray value, and obtain the compressed gray values of each pixel of the interested image 11 in the second direction A to obtain a compressed gray curve a.

[0084] By performing a partitioning process on the image 10 to be processed, the interested image 11 is obtained. By performing a compression process on the interested image 11, the gray values of multiple pixels of the interested image 11 in the first direction are compressed into a compressed gray value, which can equalize the target edge data and the background data, so that the target edge data stands out from the background data, increase the signal-to-noise ratio of the obtained compressed gray curve a, thereby increasing the position information of the obtained edge points, and further improving the detection accuracy.

[0085] The steps of compressing the interested image 11 along the first direction include: selecting any pixel in the second direction A of the interested image 11 to obtain a reference point; performing a linear combination on all pixels of the interested image 11 in the first direction passing through the reference point to obtain the compressed gray value of the reference point; repeating the steps of obtaining the reference point and the compressed gray value to obtain the compressed gray values of multiple pixels in the second direction A of the interested image 11, and obtaining the compressed gray curve a.

[0086] In this embodiment, the linear combination gray value includes: the sum, average value or weighted value of the gray values of all pixels in the first direction passing through the reference point.

[0087] When the linear combination gray value includes the weighted values of all pixel grays on a line segment passing through the reference point and parallel to the first direction, pixels with different positions in the first direction have different weights, and pixels with the same position in the first direction and different positions in the second direction A have the same weight. Specifically, the smaller the weight of the pixel in the interested image 11 that is farther from the second direction A passing through the center of the interested image 11; or, divide the interested area into multiple sub-regions along the first direction, pixels in different sub-regions have different weights, and pixels in the same sub-region have the same weight.

[0088] According to the linear combination gray value of all pixels in the first direction passing through the reference point, the compressed gray value of the reference point is obtained, which can improve the contrast of the obtained compressed gray image.

[0089] Figure 4 This is a flowchart of the steps for obtaining the position information of the edge points of the target image 12 according to the compressed gray curve a in an embodiment of the detection method of the present invention;

[0090] Reference Figure 4, in this embodiment, the steps of obtaining the position information of the edge points of the target image 12 according to the compressed gray curve a include:

[0091] Step S41, perform partitioning processing on the image of interest to obtain the edge region of the target image;

[0092] Step S42, perform edge point acquisition operations on one or more edge region images of interest respectively to obtain the position information of the edge points of the target image in the edge region.

[0093] Figure 5 It is a flowchart of each step in the partitioning processing and edge point acquisition operation in an embodiment of the detection method of the present invention.

[0094] The steps of the partitioning process include:

[0095] Step S411, obtain the initial position information of the edge points of the target image according to the compressed gray curve;

[0096] Step S412, obtain the edge region of the target image in the image of interest according to the initial position information of the edge points;

[0097] The steps of obtaining the edge region 13 of the target image 12 in the image of interest 11 include: obtaining the initial center of the target image 12 according to the initial position information of the edge points; obtaining the edge region 13 according to the initial center and the preset size of the target image 12.

[0098] The edge point acquisition operation includes:

[0099] Step S421, obtain the gradient of the compressed gray curve of the image of interest in the edge region to obtain the edge gradient;

[0100] Step S422, obtain the relationship curve between the edge gradient of each pixel in the edge region and the position of the corresponding pixel to obtain the edge gradient curve;

[0101] Step S423, obtain the position information of the edge points in the edge region according to the edge gradient curve.

[0102] Figures 6 to 7 It is a structural diagram of each step of obtaining the position information of the edge points of the target image 12 according to the compressed gray curve a in an embodiment of the technical solution of the present invention.

[0103] Execute step S41, perform partitioning processing on the image of interest to obtain the edge region of the target image.

[0104] Partition the image of interest to obtain the edge region of the target image. Based on the image of interest in the edge region, obtain the position information of the edge points of the target image, which can reduce the interference of the non-edge region image on obtaining the position information of the edge points, thereby improving the detection accuracy.

[0105] In this embodiment, the steps of partitioning the image of interest are as Figure 6 shown.

[0106] Refer to Figure 6 , execute step S411 to obtain the initial position information of the edge points of the target image 12 according to the compressed gray curve a;

[0107] In this embodiment, the steps of obtaining the initial position information of the edge points of the target image 12 according to the compressed gray curve a include: obtaining the gradient of each pixel of the compressed gray curve a; according to the correspondence between the gradient of each pixel of the compressed gray curve a and the position of each pixel, obtaining the gradient curve b; obtaining the initial position information according to the gradient curve b.

[0108] In this embodiment, before obtaining the initial position information according to the gradient curve b, the steps of obtaining the initial position information of the edge points of the target image 12 according to the compressed gray curve a further include: performing optimization processing on the gradient curve b to increase the signal-to-noise ratio of the gradient curve b. In this embodiment, according to the optimized gradient curve b, obtain the initial position information of the edge points of the target image 12.

[0109] Specifically, in this embodiment, the steps of the optimization processing include: obtaining a reference curve, where the reference curve represents the gradient curve b of the object to be measured; performing multiplication processing on the reference curve and the gradient curve b to obtain the optimized gradient curve b.

[0110] The multiplication processing includes dot multiplication or convolution. The reference curve includes: the gradient curve b of the reference object or the mirror curve of the gradient curve b of the reference object. The reference object is the designed gradient curve b of the object to be measured or the standard object to be measured.

[0111] The optimization processing can increase the gradient value of the edge points in the gradient curve b by multiplying the mirror curve and the gradient curve b, thereby increasing the signal-to-noise ratio of the gradient curve b, and further increasing the accuracy of the obtained edge region 13.

[0112] Specifically, in this embodiment, the optimization of the gradient curve b is achieved by convolving the gradient curve b with the mirror curve. In other embodiments, the optimization processing may not be performed.

[0113] The steps of obtaining the initial position information according to the gradient curve include: obtaining the pixel positions corresponding to the second largest number of gradients among the gradients of each point, to obtain the initial position information of the second largest number of edge points; the first number is less than or equal to the second number.

[0114] In this embodiment, specifically, the image of interest includes two edge points located at both ends of the second direction A of the target image.

[0115] The steps of obtaining the pixel positions corresponding to the second largest number of gradients among the gradients of each point, to obtain the initial position information of the second largest number of edge points include: obtaining the second largest number of gradients among the gradients of each point, to obtain the initial edge gradients; obtaining the pixel positions corresponding to each initial edge gradient, to obtain the initial position information of the second largest number of edge points.

[0116] In another embodiment, the steps of obtaining the initial position information according to the gradient curve include: performing function fitting on the gradient curve b to obtain a first fitting function; obtaining the extreme points of the first fitting function; obtaining the gradients of the extreme points with the second largest number of gradients in terms of gradient value, to obtain the initial edge gradients;. Performing function fitting on the gradient curve can obtain the gradient at any position on the gradient curve, so as to achieve sub-pixel accuracy.

[0117] In this embodiment, the first number is 2 and the second number is 2; in other embodiments, the first number and the second number can be greater than 2. For example, the target image is circular, the first number is 4, and the second number is 4.

[0118] In other embodiments, the steps of obtaining the initial position information according to the gradients of each point of the compressed grayscale curve a include: providing a template image, where the template image is a standard image of the target to be measured; obtaining a matching region by matching the image to be processed 10 with the template grayscale image; obtaining at least the initial edge region 13 of the target image 12 located at both ends of the second direction A according to the matching region; respectively obtaining the points corresponding to the maximum gradient value in the initial edge region 13, to obtain the initial position information.

[0119] Among them, the steps of obtaining the points corresponding to the maximum gradient value in the initial edge region 13 include: selecting the pixel corresponding to the maximum value among the gradient values of each pixel in the initial edge region 13, to obtain the initial position information; or, obtaining the corresponding relationship between the gradients and positions of the pixels with the first several largest gradients among each pixel in the initial edge region 13, to obtain a simulated gradient relationship, performing function fitting on the simulated gradient relationship, to obtain a second fitting function; obtaining the position corresponding to the maximum gradient of the second fitting function, to obtain the initial position information.

[0120] The pixels arranged in the top several quantities refer to the top several gradients when the gradients of each pixel in the initial edge region 13 are arranged from largest to smallest.

[0121] The step of obtaining the matching region and the step of obtaining the matching region in the division process can be the same step.

[0122] The above are the steps of obtaining the initial position information through the gradient curve b. In other embodiments, the steps of obtaining the initial position information of at least two separated edge points in the second direction A of the target image 12 according to the compressed grayscale curve a include: obtaining the initial position information of the edge points through an edge detection algorithm, such as the Canny algorithm.

[0123] Reference Figure 6 , execute step S412, and obtain the edge region of the target image in the region of interest image according to the initial position information of the edge points.

[0124] Specifically, in this embodiment, the region of interest image includes at least two separated edge points of the target image in the second direction A respectively.

[0125] The steps of obtaining the edge region 13 of the target image 12 in the region of interest image 11 include: obtaining the center point of the edge points according to the initial position information of the edge points; obtaining the edge region 13 of the target image 12 in the region of interest image 11 according to the preset size of the target image 12 and the center point.

[0126] Specifically, the steps of obtaining the edge region 13 of the target image 12 in the region of interest image 11 according to the preset size of the target image 12 and the center point include: obtaining the initial center of the target image 12 according to the center point; obtaining the edge region 13 according to the initial center and the preset size of the target image 12. In this embodiment, the center point is used as the initial center. In other embodiments, the initial center can be obtained according to the designed positional relationship between the center of the target image and the center point; the positional relationship between the initial center and the center point is the same as the designed positional relationship.

[0127] Specifically, in this embodiment, the target to be measured is circular, the target image 12 is circular, and the preset size is the preset diameter or preset radius of the target image 12.

[0128] The steps of obtaining the edge area 13 of the target image 12 in the region of interest image 11 according to the preset size of the target image 12 and the initial center include: obtaining a region with a predetermined width where a circle with the initial center as the center and a preset radius as the radius is located, to obtain the edge area 13. In other embodiments, the target to be measured is rectangular, and the preset size is the side length of the target image 12 along the second direction A. The steps of obtaining the edge area 13 of the target image 12 in the region of interest image 11 according to the preset size of the target image 12 and the initial center include: obtaining the endpoints of a line segment that is parallel to the second direction A and has a length equal to the preset size with the initial center as the center point; obtaining the region with a predetermined width where the endpoints are located, to obtain the edge area 13. In another embodiment, the region of interest image only includes one edge point in the second direction A; or, the region of interest image includes at least two separate edge points of the target image respectively located in the second direction A.

[0129] Continue to refer to Figure 6 , perform step S42, and perform edge point acquisition operations on the one or more edge areas 13 of the region of interest image 11 respectively, to obtain the position information of the edge points of the target image 12 in the edge area 13.

[0130] It should be noted that one or more edge areas 13 can be obtained according to the partition processing. Specifically, in this embodiment, the number of the edge areas 13 is multiple. The method includes: performing the edge point acquisition operation on each edge area 13 respectively, and obtaining the position information of one edge point in each edge area 13 respectively.

[0131] Performing the edge point acquisition operation on any one region of interest image 11 is as Figure 6 shown.

[0132] Please continue to refer to Figure 6 , perform 421, obtain the gradient of the compressed gray curve of the region of interest image of the edge area, to obtain the edge gradient; obtain the relationship curve between the edge gradient of each pixel in the edge area and the position of the corresponding pixel, to obtain the edge gradient curve; obtain the position information of the edge points in the edge area according to the edge gradient curve.

[0133] The steps of obtaining the position information of the edge points in the edge area according to the edge gradient curve include: obtaining the pixel position information corresponding to the maximum edge gradient in each edge area 13, to obtain the position information of the edge points.

[0134] Alternatively, the step of obtaining the position information of the edge points in the edge region 13 according to the edge gradient includes: obtaining the pixels corresponding to the edge gradients with the top third number of gradient values in each edge region 13 to obtain candidate edge points; fitting the gradients of the candidate edge points using a fitting function to obtain a fitting curve; obtaining the position information corresponding to the maximum gradient value on the fitting curve to obtain the position information of the edge points. The third number is greater than or equal to 3.

[0135] The edge gradients with the top third number of gradient values in the edge region 13 refer to the edge gradients with the top third number when the gradient values in the edge region 13 are arranged from large to small.

[0136] Obtaining the pixels corresponding to the edge gradients with the top third number of gradient values in each edge region 13 to obtain candidate edge points, and fitting the gradients of the candidate edge points using a fitting function to obtain a fitting curve; the fitting curve represents the gradient at any point, so that the position of the point corresponding to the maximum gradient can be obtained, and thus sub-pixel accuracy can be achieved. At the same time, by obtaining the pixels corresponding to the edge gradients with the top several gradient values to obtain candidate edge points, the interference of non-edge points can be reduced, the fitting difficulty can be reduced, and the complexity of the algorithm can be decreased.

[0137] In this embodiment, the fitting function includes: Gaussian, quadratic curve or cosine function.

[0138] In this embodiment, the number of candidate edge points in each edge region 13 is greater than or equal to 3.

[0139] Reference Figure 7 The detection method further includes: repeating the compression process to the step of obtaining the position information of the edge points of the target image 12 according to the gray curve for multiple interest images 11, and obtaining the position information of multiple edge points of the target image 12; obtaining the edge contour 31 of the target image 12 according to the position information of the multiple edge points.

[0140] In this embodiment, the step of obtaining the edge contour 31 of the target image 12 according to the position information of the multiple edge points includes: obtaining the edge contour 31 of the target image 12 by performing shape fitting on the position information of the multiple edge points. The shape fitting includes least squares fitting.

[0141] Before obtaining the edge contour 31 of the target image 12 according to the position information of the multiple edge points, the method further includes: denoising the multiple edge points.

[0142] The denoising process can eliminate the outliers among the edge points, thereby reducing and improving the detection accuracy.

[0143] In this embodiment, the denoising method includes: a random sampling algorithm.

[0144] In this embodiment, the method further includes: obtaining the target size of the target image 12 according to the edge contour 31; obtaining the size to be measured of the object to be measured according to the target size and the magnification ratio between the target image 12 and the object to be measured; and / or, the method further includes: obtaining the target center of the target image 12 according to the edge contour 31.

[0145] Obtaining the target size according to the edge contour 31 can increase the accuracy of the obtained target size. In other embodiments, obtaining the position information of the edge points of the target image 12 according to the compressed gray curve a includes: respectively obtaining the edge points located at both ends of the second direction A according to the compressed gray curve a to obtain a first edge point and a second edge point; the target size includes: the width along the second direction A; the detection method may not obtain the edge contour 31, and obtain the width of the target image 12 along the second direction A according to the position information of the first edge point and the second edge point.

[0146] Specifically, in this embodiment, the object to be measured is circular; the size to be measured includes the diameter or radius of the object to be measured in the image. In other embodiments, the object to be measured is a polygon, and the size to be measured includes the side length of the object to be measured.

[0147] In other embodiments, the surface of the object to be measured has multiple objects to be measured, and the multiple objects to be measured include a first object to be measured and a second object to be measured; specifically, the first object to be measured and the second object to be measured are respectively located on different film layers on the surface of the object to be measured.

[0148] The image to be processed 10 includes multiple target images 12, and the multiple target images 12 include: a first target image 12 of the first object to be measured and a second target image 12 of the first object to be measured;

[0149] The method further includes: obtaining the target center of the target image 12 according to the edge contour 31; repeating the step of dividing the image to be processed 10 until the target center is obtained until the first target center of the first target image 12 and the second target center of the second target image 12 are obtained; obtaining the offset of the first object to be measured and the second object to be measured according to the first target center and the second target center.

[0150] Although the present invention is disclosed as above, the present invention is not limited thereto. Any person skilled in the art can make various changes and modifications without departing from the spirit and scope of the present invention. Therefore, the protection scope of the present invention should be subject to the scope defined by the claims.

Claims

1. A detection method, characterized in that, Including: Obtain an image of the object to be measured to get a to-be-processed image. There is a target to be measured on the surface of the object to be measured, and the to-be-processed image includes a target image of the target to be measured; Perform a partitioning process on the to-be-processed image to obtain at least one image of interest. The image of interest includes a target image of at least part of the edge of the target to be measured, and the image of interest includes a plurality of pixels in a first direction; Perform a compression process on the image of interest along the first direction, so that the gray values of the plurality of pixels of the image of interest in the first direction are compressed into a compressed gray value. Obtain the compressed gray values of the pixels of the image of interest in a second direction to get a compressed gray curve. The second direction is different from the first direction, and the compressed gray value is used to extract the edge feature of the target image; According to the compressed gray curve, obtain the position information of the edge points of the target image; The step of performing a compression process on the image of interest along the first direction includes: select any pixel in the second direction of the image of interest to get a reference point; perform a linear combination on all the pixels of the image of interest in the first direction passing through the reference point to get the compressed gray value of the reference point; repeat the steps of obtaining the reference point and the compressed gray value to obtain the compressed gray values of a plurality of pixels in the second direction of the image of interest to get the compressed gray curve.

2. The detection method according to claim 1, characterized in that, The linear combination includes: summing, averaging or weighting the gray values of all the pixels in the first direction passing through the reference point; the first direction is a straight line, and the second direction is perpendicular to the first direction.

3. The detection method according to claim 1, characterized in that The step of obtaining the position information of the edge points of the target image according to the compressed gray curve includes: perform a partitioning process on the image of interest to obtain the edge area of the target image; perform an edge point obtaining operation on the image of interest in one or more edge areas respectively to obtain the position information of the edge points of the target image in the edge area.

4. The detection method according to claim 3, wherein The image of interest includes: a first number of separated edge points located in the second direction, and the first number is a plurality; the partitioning process step includes: obtain the initial position information of the edge points of the target image according to the compressed gray curve; according to the initial position information of the edge points, obtain the edge area of the target image in the image of interest.

5. The detection method according to claim 4, characterized in that, The image of interest includes the first number of separated edge points of the target image respectively located in the second direction; The step of obtaining the edge area of the target image in the image of interest according to the initial position information of the edge points includes: obtain the initial center of the target image according to the initial position information of the edge points; According to the preset size of the target image and the initial center point, obtain the edge area of the target image in the image of interest.

6. The detection method according to claim 4, wherein The step of obtaining the initial position information of the edge points of the target image according to the compressed gray curve includes: obtain the gradient of each point of the compressed gray curve; according to the corresponding relationship between the gradient of each pixel of the compressed gray curve and the position of each pixel, obtain a gradient curve; obtain the initial position information according to the gradient curve.

7. The detection method according to claim 6, wherein The steps of obtaining the initial position information according to the gradient curve include: obtaining the pixel positions corresponding to the second largest number of gradients among the gradients of each pixel to obtain the initial position information of the second largest number of edge points; or, performing function fitting on the gradient curve to obtain a first fitting function; obtaining the extreme points of the first fitting function; obtaining the positions corresponding to the gradients of the extreme points with the second largest number of gradient values to obtain the initial position information of the edge points, where the first number is less than or equal to the second number.

8. The detection method according to claim 3, characterized in that The edge point obtaining operation includes: obtaining the gradient of the compressed grayscale curve of the image of interest in the edge region to obtain an edge gradient; obtaining a relationship curve between the edge gradient of each pixel in the edge region and the position of the corresponding pixel to obtain an edge gradient curve; obtaining the position information of edge points in the edge region according to the edge gradient curve.

9. The detection method according to claim 8, wherein The steps of obtaining the position information of edge points in the edge region according to the edge gradient curve include: obtaining the pixel position corresponding to the largest edge gradient in each edge region to obtain the position information of the edge points; or, obtaining the pixel positions corresponding to the edge gradients with the third largest number of gradient values in the edge region to obtain candidate edge points; using a fitting function to fit the gradients of the candidate edge points to obtain a fitting curve; obtaining the position corresponding to the maximum gradient value on the fitting curve to obtain the position information of the edge points; the third number is multiple.

10. The detection method according to claim 9, characterized in that, The fitting function includes: Gaussian, quadratic curve or cosine function.

11. The detection method according to claim 9, characterized in that, The number of candidate edge points in each edge region is greater than or equal to 3.

12. The detection method according to claim 5, wherein The target image is circular, and the preset size is the preset diameter or preset radius of the target image; The steps of obtaining the edge region of the target image in the image of interest according to the preset size of the target image and the initial center include: obtaining a region with a predetermined width where a circle with the initial center as the center and the preset radius as the radius is located to obtain the edge region.

13. The detection method according to claim 6, wherein Before obtaining the initial position information according to the gradient curve, the steps of obtaining the initial position information of at least two separated edge points in the second direction of the target image according to the compressed grayscale curve further include: performing optimization processing on the gradient curve to increase the signal-to-noise ratio of the gradient curve.

14. The detection method according to claim 13, wherein The steps of the optimization processing include: obtaining a reference curve, where the reference curve represents the gradient curve of the object to be measured; performing multiplication processing on the reference curve and the gradient curve to obtain an optimized gradient curve; the multiplication processing includes dot multiplication or convolution, and the reference curve includes: the gradient curve of the reference object or the mirror curve of the gradient curve of the reference object, and the reference object is the designed gradient curve of the object to be measured or the standard object to be measured.

15. The detection method according to claim 1, characterized in that, The target image is polygonal; the first direction is parallel to one side of the target image.

16. The detection method according to claim 1, wherein The number of images of interest is multiple, and there is a preset angle between the second directions of the multiple images of interest; The method further includes: repeating the compression process for the multiple images of interest until the position information of the edge points of the target image is obtained according to the gray curve, to obtain the position information of multiple edge points of the target image; obtaining the edge contour of the target image according to the position information of the multiple edge points.

17. The detection method according to claim 16, wherein, Before obtaining the edge contour of the target image according to the position information of the multiple edge points, the method further includes: performing denoising processing on the multiple edge points; the method of the denoising processing includes: a random sampling algorithm.

18. The detection method according to claim 16, characterized in that, The method further includes: obtaining the target size of the target image according to the edge contour; obtaining the size to be measured of the object to be measured according to the target size and the magnification ratio between the target image and the object to be measured. And / or, the method further includes: obtaining the target center of the target image according to the edge contour.

19. The detection method according to claim 16, wherein The surface of the object to be measured has multiple objects to be measured, and the multiple objects to be measured include a first object to be measured and a second object to be measured. The image to be processed includes multiple target images, and the multiple target images include: a first target image of the first object to be measured and a second target image of the first object to be measured. The method further includes: obtaining the target center of the target image according to the edge contour; repeating the step of dividing the image to be processed until the target center is obtained, until the first target center of the first target image and the second target center of the second target image are obtained; obtaining the offset between the first object to be measured and the second object to be measured according to the first target center and the second target center.

20. The detection method according to claim 1, wherein, The image of interest includes two separate edge points of the target image respectively located in the second direction; obtaining the position information of the edge points of the target image according to the compressed gray curve includes: respectively obtaining the edge points located at both ends in the second direction according to the compressed gray curve, to obtain a first edge point and a second edge point. The method further includes: obtaining the width of the target image in the second direction according to the position information of the first edge point and the second edge point.

21. The detection method according to claim 1, wherein The step of the dividing process includes: providing a template image, where the template image is a standard image of the object to be measured; using the template image to perform matching on the image to be processed to obtain a matching region; segmenting the matching region to obtain the image of interest; the image of interest further includes the center of the matching region.

22. The detection method according to claim 1, wherein The positions of the edge points of the target image in the image of interest are smooth curves or straight lines.

23. A detection system, characterized in that, It includes a processing system for executing the detection method according to any one of claims 1 to 22.

Citation Information

Patent Citations

  • Image enhancement method and apparatus

    CN106780413A

  • Defect detection method and device

    CN111758024A