A VCSEL epitaxial wafer defect detection method based on image processing

By using an image processing-based method, the background threshold is calculated using grayscale peak value and disorder weight, and the defect probability is calculated by combining the roundness factor and grayscale dominance factor. This solves the problem of misjudgment in VCSEL epitaxial wafer detection and achieves high-precision defect detection.

CN121120638BActive Publication Date: 2026-02-03WAFERCHINA CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511656905.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-11-13
Publication Date
2026-02-03
Estimated Expiration
2045-11-13

AI Technical Summary

Technical Problem

In the existing technology, the detection of pitting on VCSEL epitaxial wafers relies on manual visual inspection, which is highly subjective and easily leads to misjudging substrate scratches as pitting, resulting in a high rate of missed detection and false detection.

Method used

An image processing-based approach is adopted, which divides the image into sub-blocks, calculates the gray-level peak and disorder weight to obtain the background gray-level threshold, filters target pixels, calculates the defect probability using the roundness factor and gray-level dominance factor, and combines the parameters of the pitted reflection area and the shadow area to quantify the defect area ratio for detection.

Benefits of technology

It improves detection accuracy, reduces false positive and false negative rates, meets the consistency requirements of mass production testing of VCSEL epitaxial wafers, and reduces false positives or false negatives caused by inaccurate background thresholds.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121120638B_ABST
    Figure CN121120638B_ABST
Patent Text Reader

Abstract

The present application belongs to the technical field of image detection, and particularly relates to a VCSEL epitaxial wafer defect detection method based on image processing, which comprises the following steps: firstly, pre-processing the collected image; then, determining the background gray threshold by calculating the gray peak value and confusion weight of the image sub-block, and identifying the target pixel point based on the background gray threshold to calculate the first defect probability representing the pitting reflection area; then, determining the pitting reflection area by clustering, and demarcating the candidate shadow area according to the position and size characteristics of the pitting reflection area to calculate the second defect probability representing the pitting shadow area; finally, combining the area characteristics of the pitting reflection area and the pitting shadow area to output the final defect detection result. Through multi-dimensional feature extraction and probability calculation, the present application can accurately identify the real pitting defects and exclude the interference, effectively reduce the missed detection and misjudgment rate, and improve the detection accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image detection technology, and in particular to a method for detecting defects in VCSEL epitaxial wafers based on image processing. Background Technology

[0002] Vertical-cavity surface-emitting lasers (VCSELs) are core devices in the optoelectronic field, boasting advantages such as low threshold current and high modulation rate, and are widely used in data communication, automotive radar, and other applications. The performance of a VCSEL is determined by the quality of its epitaxial wafer, which is a superlattice structure thin film built layer by layer on a specific compound semiconductor substrate using molecular beam epitaxy (MBE) and metal-organic chemical vapor deposition (MOCVD) techniques. When residual impurities in the reaction chamber cause localized growth anomalies, or when substrate polishing is insufficient, pitting defects can occur. These defects not only disrupt the lattice integrity of the epitaxial layer but also create leakage channels during device fabrication, leading to a decrease in the electro-optical conversion efficiency of the VCSEL and, in severe cases, direct device failure.

[0003] From a physical structure perspective, the pitting on a VCSEL epitaxial wafer is essentially a locally raised three-dimensional structure. The thickness of the epitaxial layer in the raised portion differs from that of the surrounding normal area, resulting in a significantly higher reflectivity of the raised portion to the detection light source, forming a pitting reflection area. At the same time, the raised structure can block the light source, creating a light-deficient area on the other side under a uniform light source illumination direction, i.e., a pitting shadow area. The pitting shadow area and the pitting reflection area are two coexisting characteristics of pitting defects, but neither is a true pit. The former only manifests as grayscale abnormalities, without a raised structure, and does not affect the electrical properties of the device; the latter is only localized reflection and has no blocking effect.

[0004] Traditional VCSEL epitaxial wafer pit detection relies on manual visual inspection, which is not only highly subjective but also prone to misjudging substrate scratches as pits, resulting in a high rate of missed detections and false detections. Summary of the Invention

[0005] To address the existing technical problems of high subjectivity and the tendency to misjudge substrate scratches as pitting, leading to high rates of missed and false detections, this invention provides a VCSEL epitaxial wafer defect detection method based on image processing.

[0006] This invention provides a VCSEL epitaxial wafer defect detection method based on image processing, comprising: dividing the image to be detected into several sub-blocks, constructing a gray-level histogram for each sub-block and obtaining the gray-level peak value of each sub-block; obtaining a background gray-level threshold based on the gray-level peak value of each sub-block and a disorder weight characterizing the degree of disorder in the gray-level distribution of pixels within each sub-block; selecting target pixels based on the deviation between the gray-level value of each pixel and the background gray-level threshold; obtaining a first defect probability that the target pixel belongs to a pitted reflection area based on the roundness factor of the target pixel and a gray-level dominance factor characterizing the degree to which its gray-level value exceeds the background; and selecting suspected pitted reflection areas based on the first defect probability. For the target pixels in the dot reflection region, cluster the target pixels in the suspected dot reflection region to obtain multiple dot reflection regions. Based on the center coordinates and equivalent diameter of each dot reflection region, obtain its candidate shadow region. Based on the angle, gray value, and distance of each pixel in the candidate shadow region from the center of the dot reflection region, obtain the second defect probability that the candidate shadow region belongs to the dot shadow region. Based on the second defect probability, determine the dot shadow region corresponding to the dot reflection region. Based on the ratio of the sum of the areas of the dot reflection region and the dot shadow region to the area of ​​the image to be detected, obtain the defect detection result of the VCSEL epitaxial wafer in the image to be detected.

[0007] This invention accurately determines the background grayscale threshold by using sub-block grayscale peak values ​​and disorder weights, combines a two-factor calculation to screen suspected pitting reflection areas, then uses the pitting reflection area parameters to delineate candidate shadow areas and calculates a second defect probability using multiple features, effectively distinguishing between real pitting and interference, and finally quantifies the results by area ratio, thereby improving detection accuracy, reducing false negative and false negative rates, and meeting the consistency requirements of mass production testing of VCSEL epitaxial wafers.

[0008] Preferably, obtaining the background grayscale threshold based on the grayscale peak value of each sub-block and the disorder weight representing the degree of disorder in the pixel grayscale distribution within each sub-block includes: In the formula, It is the background grayscale threshold; It is the first Disordered weights of individual sub-blocks; It is the first The gray-level peak value of the gray-level histogram of each sub-block; It is the index of the sub-block; It represents the total number of sub-blocks.

[0009] This method achieves accurate dynamic calculation of the background grayscale threshold by weighting and summing the grayscale peak value of the grayscale histogram of each sub-block with a disorder weight that characterizes the degree of disorder in the pixel grayscale distribution within the sub-block. On the one hand, the grayscale peak value directly reflects the most common grayscale level within the corresponding sub-block, providing a basis for background grayscale determination based on the actual pixel distribution. On the other hand, the disorder weight can assign higher weights to sub-blocks with more stable grayscale distributions that better represent the real background, and reduce the weights of sub-blocks with noise or local anomalies that may interfere with background determination, effectively filtering out interference information. This avoids the influence of grayscale feature deviations of a single sub-block on the threshold and can adapt to image scenes with large differences in grayscale distribution in different regions. The resulting background grayscale threshold is more in line with the real background of the image, laying a reliable foundation for the accurate identification of defects such as pitted shadow areas and reducing false detections or missed detections caused by inaccurate background thresholds.

[0010] Preferably, the step of selecting target pixels based on the deviation between the grayscale value of each pixel and the background grayscale threshold includes: The background grayscale threshold is used to obtain the standard deviation of the grayscale peak values ​​of all sub-blocks, denoted as . When pixel grayscale value satisfy: When that happens, the pixel is taken as the first... If a pixel within a sub-block belongs to the background area, then that pixel is considered the first pixel. The target pixels within each sub-block.

[0011] Preferably, the method for obtaining the circularity factor of the target pixel includes: In the formula, It is the first Target pixels within each sub-block Circularity factor; It is the first Target pixels within each sub-block of Within the neighborhood Gradient direction of each surrounding pixel; It is the first The ideal circular tangent direction corresponding to each surrounding pixel. arrive There are eight fixed directions: 0°, 45°, 90°, 135°, 180°, 225°, 270°, and 315°. It is the directional tolerance parameter.

[0012] This method, on the one hand, through... The gradient directions of the eight surrounding pixels within the neighborhood comprehensively capture the local structural information around the target pixel, avoiding the one-sidedness of features from a single direction. Furthermore, by calculating the difference with eight fixed ideal circular tangent directions and using an exponential function to weight the directional fit, the approximation of the target pixel's surrounding shape and its proximity to the ideal circle is intuitively reflected, achieving continuous quantification of circularity. Simultaneously, the directional tolerance parameter can be flexibly adjusted to accommodate different image noise levels and defect morphology features, while taking the average of the eight directions further smooths out local noise interference, making the circularity factor more stable and reliable. This calculation logic effectively distinguishes circular defects, such as pits, from non-circular interference areas, providing key feature support for the accurate identification of subsequent defect types and improving the specificity and accuracy of VCSEL epitaxial wafer defect detection.

[0013] Preferably, obtaining the first defect probability that the target pixel belongs to the pitted reflection region based on the circularity factor of the target pixel and the grayscale dominance factor characterizing the degree to which its grayscale value exceeds the background significance includes: In the formula, It is the first Target pixels within each sub-block The probability of the first defect belonging to the speckled reflection region in the image to be detected; Target pixel grayscale value The magnitude exceeding the upper limit of the grayscale value of the background pixels; It is the standard deviation of the grayscale peak values ​​of all sub-blocks; It is the first Target pixels within each sub-block Circularity factor; It is the first Disordered weights of individual sub-blocks; It is the first Target pixels within each sub-block The gray-scale advantage factor.

[0014] This method achieves precise selection of pixels in the speckled reflective region through the organic fusion of multi-dimensional features: on the one hand, it adopts a piecewise function design, directly adjusting the probability when the gray value of the target pixel exceeds the upper limit of the background. Setting it to 0 excludes non-defective pixels without grayscale advantage from the source, reducing invalid calculations and misjudgments; on the other hand, when At the same time, the significance of pixel grayscale is quantified by the grayscale advantage factor, and the one-sidedness of a single grayscale value is avoided by combining the overall grayscale fluctuation. Multiplying by the roundness factor introduces morphological features to ensure that the target conforms to the circular shape of the pit. Then, the feature credibility of the stable grayscale distribution area is enhanced by combining the disorder weight. A joint judgment with multiple constraints is formed, which not only ensures the high probability of identifying the real pit reflection area, but also effectively suppresses the interference pixels that only meet a single feature. This significantly improves the discrimination and reliability of the first defect probability, and provides an accurate quantitative basis for the subsequent threshold-based pit reflection area judgment, reducing the risk of missed detection and false detection.

[0015] Preferably, the method for obtaining each pockmarked reflective area includes: setting a pockmarked reflective threshold. It needs to meet the following requirements. When the probability of the first defect belonging to the pitted reflection region in the image to be detected is greater than or equal to the pitted reflection threshold, When the target pixel belongs to the speckled reflection area in the image to be detected, it does not belong to the image otherwise.

[0016] Preferably, the method for obtaining the center coordinates and equivalent diameter of each pitted reflection region includes: taking the average coordinates of all target pixels in each pitted reflection region as the center coordinates of each pitted reflection region; and taking the pitted reflection region as the center coordinates of each target pixel. The total number of target pixels is used as the pockmarked reflection area. area Then the pockmarked reflective area equivalent diameter .

[0017] Preferably, obtaining the candidate shadow region based on the center coordinates and equivalent diameter of each speckled reflection region includes: using the speckled reflection region center coordinates The horizontal direction to the right is 0°, and the angle increases sequentially in a clockwise direction; the angle range of the sector is... The angle between the positive axis and the sector boundary ray, with the angle between 30° and 60°, is used to set the radius range. .

[0018] Preferably, the method for obtaining the second defect probability that a pixel within a candidate shadow region belongs to a pitted shadow region includes: ;in, It is a candidate shaded area pixels within The probability of the second defect belonging to the pockmarked shadow area; It is a pixel. Relative to the pitted reflective area center coordinates Direction angle; It is a pixel. Relative to the pitted reflective area center coordinates The Euclidean distance; It is the standard deviation of the grayscale peak values ​​of all sub-blocks; It is the background grayscale threshold; It is a pixel. grayscale value; It is the equivalent diameter; It is a preset micro value; It is a cosine function; Based on the natural constant An exponential function with base 1; It is the absolute value symbol.

[0019] This method achieves accurate identification of pixels in the pitted shadow region through the collaborative quantization of multi-dimensional features: on the one hand, the cosine function term Effectively measures pixels Direction angle The degree of agreement with the typical direction of the speckled shadow ensures that only pixels whose directional features conform to the shadow distribution pattern are considered; on the other hand, the exponential function term via Euclidean distance With equivalent diameter The difference calculation constrains the spatial distance between the pixel and the center of the pockmarked reflection area, ensuring that it focuses on pixels that conform to the shadow space distribution range; simultaneously, grayscale correlation terms... By combining background grayscale threshold, pixel grayscale value, and overall grayscale fluctuation, the shadow grayscale features of pixels are quantified, and preset small values ​​avoid calculation anomalies. This organic fusion of multi-dimensional features not only ensures the accurate capture of the core features of pitted shadows, but also filters out non-shadow interference pixels through reasonable constraints of various parameters, significantly improving the distinguishing ability and reliability of the second defect probability. It provides a scientific quantitative basis for the accurate determination of pitted shadow areas and effectively reduces the risk of missed detection and false detection in the detection process.

[0020] Preferably, determining the pitted shadow region corresponding to the pitted reflection region based on the second defect probability includes: setting a pitted shadow threshold. It needs to meet the following requirements. When the candidate shadow region of the pockmarked reflection area belongs to the second defect probability of the pockmarked shadow region in the image to be detected is greater than or equal to the pockmarked shadow threshold. When the candidate shadow region of the pockmarked reflection area is considered to belong to the pockmarked shadow region in the image to be detected, the other way around is not considered to belong to it.

[0021] The beneficial effects of this invention are as follows: By combining the grayscale peak value of sub-blocks with chaotic weights to calculate the background grayscale threshold, the estimation bias of the defect cluster area by the traditional global threshold is avoided, laying an accurate foundation for subsequent detection; the circularity factor is used to distinguish the circular edge of the pit reflection area from substrate scratches, and the grayscale dominance factor is used to enhance the grayscale recognition of the pit. The first defect probability is calculated by combining the circularity factor and the grayscale dominance factor, which can significantly reduce the misjudgment of substrate scratches and reduce the false detection rate; and relying on the characteristics of real pits having reflective and shadow areas, the candidate shadow area is delineated along a fixed direction according to the parameters of the reflective area, which not only narrows the detection range and reduces invalid calculations to improve efficiency, but also calculates the second defect probability through three features: angle, distance, and grayscale, effectively eliminating interference such as substrate dark spots and dust reflection, ensuring that only the "reflective area + shadow area" unit is judged as a real pit, further reducing the false detection rate; finally, the result is quantified by the ratio of the sum of the two areas to the image area, avoiding the subjectivity of manual visual inspection, providing a standardized judgment basis, and adapting to the consistency and efficiency requirements of VCSEL epitaxial wafer mass production inspection. Attached Figure Description

[0022] Figure 1 This is a flowchart illustrating a VCSEL epitaxial wafer defect detection method based on image processing according to the present invention.

[0023] Figure 2 This schematically illustrates the angular range of the fan-shaped candidate shadow area. Detailed Implementation

[0024] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0025] The specific embodiments of the present invention will now be described in detail with reference to the accompanying drawings.

[0026] This invention discloses a method for detecting defects in VCSEL epitaxial wafers based on image processing, referring to... Figure 1 This includes steps S1 to S4:

[0027] S1. Acquire the surface image of the VCSEL epitaxial wafer and perform preprocessing to obtain the image to be detected.

[0028] It should be noted that this step aims to address the issues of high noise levels, weak defect features, and low data validity in surface images. On one hand, high-precision image acquisition hardware and calibration operations ensure that micron-level pits on the VCSEL epitaxial wafer surface can be clearly imaged, avoiding subsequent missed detections due to imaging distortion. On the other hand, preprocessing eliminates interference from uneven illumination, substrate reflection, electronic noise, and other factors, transforming the original image into an image to be inspected. This provides high-quality data input for subsequent steps, reducing the false judgment rate and computational load of the detection algorithm from the source, and ensuring that the accuracy and efficiency of the entire inspection process are suitable for mass production scenarios.

[0029] Specifically, the VCSEL epitaxial wafer is fixed on a movable platform, and an industrial camera is used to acquire surface images of the VCSEL epitaxial wafer through a 200-micron lens. Preprocessing is then performed, including: converting the surface image to grayscale to obtain a grayscale image, and then... The grayscale image is processed by Gaussian filtering with a large-size filter kernel to eliminate camera electronic noise and light source particle noise; then a histogram equalization algorithm is used to optimize local contrast to improve the grayscale difference between the speckles and the background, while avoiding excessive amplification of noise.

[0030] After the above processing, the image to be detected is obtained and used as the input for subsequent steps; grayscale processing, Gaussian filtering, and histogram equalization are all existing technologies and will not be described in detail here.

[0031] S2. Obtain the background grayscale threshold based on the grayscale peak value and disorder weight of the sub-blocks of the image to be detected; obtain the target pixel based on the deviation between the grayscale of the pixel and the background threshold; obtain the first defect probability based on the circularity factor and grayscale advantage of the target pixel.

[0032] It should be noted that in the grayscale image of the VCSEL epitaxial film, there are two regions: the speckled reflection region, which has a larger grayscale value and an approximately circular edge; the speckled shadow region, which has a smaller grayscale value and an approximately elliptical edge; and the background region, which has a grayscale value between the two and is relatively uniform. The speckled shadow region is always located approximately southeast of the center of the speckled reflection region.

[0033] Specifically, the image to be detected is divided into uniformly sized... A sub-block, for example, Draw a grayscale histogram for each sub-block, where the horizontal axis of the grayscale histogram represents the grayscale value, and the vertical axis represents the number of pixels corresponding to the grayscale value; and extract the grayscale peak value from the grayscale histogram of each sub-block. For example, the peak value of the grayscale histogram of the first sub-block is... The grayscale peak value of each sub-block is denoted as Further, obtain the normalized entropy value of the grayscale values ​​of all pixels in each sub-block, as the disorder weight of each sub-block. For example, the first... The disorder weight of each sub-block is denoted as This ensures that sub-blocks with more chaotic grayscale values ​​of pixels receive a greater chaos weight, and normalizes each chaos weight by dividing the chaos weight of each sub-block by the sum of all chaos weights.

[0034] It should be noted that since the speckled reflective area has high grayscale characteristics and the speckled shadow area has low grayscale characteristics, the coexistence of the two with the background area with medium grayscale characteristics will lead to a more chaotic distribution of the grayscale values ​​of the pixels in the sub-block. Therefore, the sub-block with more speckles has a high entropy value, and conversely, the sub-block with fewer speckles or no speckles has a low entropy value.

[0035] Furthermore, based on the grayscale peak value of each sub-block and the corresponding disorder weight of each sub-block, the background grayscale threshold is obtained, with the following relationship:

[0036] ;

[0037] In the formula, It is the background grayscale threshold; It is the first The disorder weight of each sub-block reflects the degree of disorder in the gray-scale distribution within the sub-block; the more speckles a sub-block contains, the greater its disorder weight. It is the first The gray value peak of the gray value histogram of each sub-block, that is, the gray value that appears most frequently in the sub-block, reflects the main gray value characteristics of the background area. It is the index of the sub-block; It is the total number of sub-blocks; It is the sum of the products of the disorder weights of all sub-blocks and the grayscale peak values.

[0038] It should be noted that although sub-blocks with more chaotic gray values ​​receive a greater weight for chaos, the gray value peaks of the gray value histogram of the sub-block are still mainly background pixels because the number of speckles is relatively small. Therefore, the background gray value threshold essentially reflects the gray value most likely to belong to the background and is more sensitive to the background features of areas with dense defects, thus solving the estimation bias of traditional global thresholds for defect clusters.

[0039] Specifically, first, obtain the gray value with the highest frequency in the gray-level histogram of each sub-block, define it as the gray-level peak value of the sub-block, and then obtain the standard deviation of the gray-level peak values ​​of all sub-blocks, denoted as . ; with the first Pixels within each sub-block Taking the example of analysis, let's look at the pixels. The grayscale value is denoted as , It is the background grayscale threshold, when the pixel... grayscale value satisfy: When that happens, the pixel is taken as the first... If a pixel within a sub-block belongs to the background area, then that pixel is considered the first pixel. For the target pixels within each sub-block, repeat the above operation to obtain the first... Furthermore, all target pixels within each sub-block are obtained; where... It is the standard deviation of the grayscale peak values ​​of all sub-blocks, and 1.5 is a multiple of this standard deviation. The physical meaning is that it allows the background gray level to fluctuate within 1.5 standard deviations.

[0040] Furthermore, when pixels It is the first When a target pixel is located within a sub-block, it is recorded as the target pixel. And further analysis: with target pixels Centered on, take The gradient directions of the eight surrounding pixels in the neighborhood are calculated using the Sobel operator. Target pixels within each sub-block The relationship for the circularity factor is as follows:

[0041] ;

[0042] In the formula, It is the first Target pixels within each sub-block The circularity factor reflects the target pixel. A quantitative indicator of the similarity between the edge of the object and the edge of an ideal circle; It is the first Target pixels within each sub-block of Within the neighborhood The gradient direction of each surrounding pixel, with a value ranging from 0 to 2π; It is the first Target pixels within each sub-block of Within the neighborhood The ideal circular tangent direction corresponding to each surrounding pixel. arrive There are eight fixed directions: 0°, 45°, 90°, 135°, 180°, 225°, 270°, and 315°. It is a direction tolerance parameter that allows for discrepancies between the actual gradient direction and the theoretical direction. The deviation is adjusted to accommodate the edge blurring characteristics of real images, for example, When the exponent term The closer to 1, the greater the deviation; the closer to 0, the closer to the edge is to a circle, and the higher the direction matching degree of the detection logic.

[0043] Specifically, based on the target pixel Circularity factor and target pixel grayscale value Obtain the target pixel. The probability of a first defect belonging to the speckled reflection region in the image to be detected is given by the following formula:

[0044] ;

[0045] ;

[0046] In the formula, It is the first Target pixels within each sub-block The probability of the first defect belonging to the speckled reflection region in the image to be detected; Target pixel grayscale value The magnitude exceeding the upper limit of the grayscale value of the background pixels; It is the standard deviation of the grayscale peak values ​​of all sub-blocks; It is the first Target pixels within each sub-block Circularity factor; It is the first The disorder weight of each sub-block reflects the degree of disorder in the grayscale distribution within the sub-block; the more speckles a sub-block contains, the greater its disorder weight.

[0047] further, It is the first Target pixels within each sub-block The gray-scale advantage factor, when Much larger When the grayscale advantage of this factor is obvious, approaching 1, it better matches the situation where the grayscale of the speckled reflective area is significantly higher than that of the background; when near At this time, the grayscale advantage of this factor is relatively weak, approaching 0.5, which is more consistent with the characteristics of low-contrast speckles; when the target pixel point Circularity factor When it is approximately close to 1, it reflects the target pixel point The neighborhood gradient direction highly matches the circular tangent direction, indicating that the target pixel point It is highly likely to be the edge of the pitted reflective area, and conversely, it may be the edge of the non-pitted reflective area. It is a region-sensitive factor that gives target pixels in sub-blocks with higher disorder weights a greater weight, thus enhancing the algorithm's sensitivity to regions where blemishes are more concentrated.

[0048] Specifically, the first defect probability of each target pixel belonging to the speckled reflection region in the image to be detected is obtained. Based on the comparison result between the first defect probability of each target pixel belonging to the speckled reflection region in the image to be detected and the speckled reflection threshold, the target pixels belonging to the speckled reflection region are obtained. The specific method is as follows: Set the speckled reflection threshold. It can be set according to actual needs. Based on the range of the first defect probability, the range of the pitting reflection threshold is determined to be [0,1].

[0049] It should be noted that the purpose of the pitting reflection threshold is to serve as a critical value for determining the probability of the first defect. By setting a clear numerical standard, continuous probability values ​​are transformed into discrete classification results, thereby defining whether a pixel belongs to a pitting reflection area. If the pitting reflection threshold is set too high, pixels with a slightly lower probability of the first defect but actually belonging to weaker pitting reflection will be excluded, resulting in the inability to identify and adjust weaker pitting. If the threshold is set too low, the judgment standard will be too lenient, and pixels in non-pitting reflection areas with a low probability of the first defect will be incorrectly included, causing misidentification.

[0050] Furthermore, considering the need to balance detection sensitivity and accuracy, the range of values ​​for the pitting reflection threshold can be set to... This range effectively covers the pockmarked reflection characteristics in most scenarios, reducing missed detections and false detections. For example, When the probability of the first defect belonging to the pitted reflection region in the image to be detected is greater than or equal to the pitted reflection threshold. When a target pixel is considered to belong to the speckled reflection region in the image to be detected, it is considered not to belong to it.

[0051] S3. Cluster the target pixels belonging to the pitted reflection area using the K-means clustering algorithm to obtain the pitted reflection area and its core parameters; obtain candidate shadow areas based on the position and size of the reflection area; obtain the second defect probability based on the angle, distance and grayscale features of the pixels in the candidate shadow area.

[0052] Specifically, the K-means clustering algorithm is used to cluster target pixels belonging to the pockmarked reflection region in the selected image to be detected; the sum of squared errors under different numbers of clusters is calculated using the elbow method to determine the optimal number of clusters for clustering results. This approach avoids merging multiple speckled reflection areas due to insufficient cluster size, while also preventing redundant clustering due to excessive cluster size, ultimately yielding a total of [number missing] clusters in the image to be detected. Each individual pockmarked reflection region is defined, and the average coordinates of all target pixels within each pockmarked reflection region are used as the center coordinates of that region. For example, the pockmarked reflection regions... The center coordinates are ; reflective area of ​​the pockmarks The total number of target pixels is used as the pockmarked reflection area. area Further refine the reflective area of ​​the pockmarks. Approximately circular, obtain its equivalent diameter Among them, the elbow method is an existing technique and will not be elaborated on here.

[0053] Furthermore, for each pockmarked reflective area, a fan-shaped candidate shadow area is delineated within its specific angular range to represent the pockmarked reflective area. Candidate shadow areas Taking the candidate shaded area as an example for analysis The constraint condition is: with the pockmarked reflection area center coordinates Establish a Cartesian coordinate system with the origin as the coordinate system, and the coordinate system extending horizontally to the right as the coordinate system. The positive direction of the axis is vertically upward. Positive direction of the axis; The positive direction of the axis is 0°, and the angles increase sequentially in a clockwise direction; the angle range of the sector is... The angle between the positive axis and the sector boundary ray, ranging from 30° to 60°, corresponds to the fixed orientation of the shadow cast by the pitting defect under uniform light source illumination, obtaining... Figure 2 A schematic diagram showing the angular range of the fan-shaped candidate shaded area.

[0054] Since the distance between the pockmarked shadow area and the pockmarked reflection area is positively correlated with the size of the reflection area, to avoid interference areas that are too far or too close, the radius range is set to... Only in candidate shaded areas The pixels within the range are used in the subsequent calculation of the second defect probability.

[0055] Specifically, with candidate shadow areas pixels within Taking this as an example, we can obtain the pixel points. Relative to the pitted reflective area center coordinates The direction angle and Euclidean distance are denoted as follows: Further pixel The grayscale value is denoted as Then the candidate shadow region pixels within The probability of a second defect belonging to the pockmarked shadow region in the image to be detected is:

[0056] ;

[0057] in, It is a candidate shaded area pixels within The probability of the second defect belonging to the pockmarked shadow area; It is a pixel. Relative to the pitted reflective area center coordinates The direction angle, ; It is a pixel. Relative to the pitted reflective area center coordinates Euclidean distance, ; It is the standard deviation of the grayscale peak values ​​of all sub-blocks; It is the background grayscale threshold; It is a pixel. grayscale value; It is the equivalent diameter; It is a preset microvalue used to prevent It can be set to 0, or 0.01, or as needed; It is a cosine function; Based on the natural constant An exponential function with base 1; It is the absolute value symbol.

[0058] It should be noted that, With the center of the fan-shaped area ranging from 45° to 60° To achieve the optimal direction, pixels smoothly decay to 0 towards both edges, allowing for slight directional deviations while strictly excluding pixels not in the southeast direction. With equivalent diameter To determine the optimal distance, a Gaussian function is used to quantify the distance deviation; the smaller the deviation, the closer the distance. hour, The closer to 1; the greater the deviation. hour, Rapidly attenuate to below 0.3 to eliminate interference from unreasonable distances; Only when A positive value is only contributed when the gray level is below the core gray range of the shadow, and the lower the gray level, the closer it is to the shadow feature. The closer the value is to 1, the less interference from irrelevant dark spots should be avoided; It is a very small positive number to prevent the denominator from being 0, for example .

[0059] Specifically, obtain candidate shadow regions The second defect probability of each pixel belonging to the pitted shadow region in the image to be detected is used as the average value of the pitted reflection region. Candidate shadow areas The second defect probability belonging to the pockmarked shadow region in the image to be detected is obtained, and then the second defect probability of the candidate shadow region of each pockmarked reflection region belonging to the pockmarked shadow region in the image to be detected is obtained.

[0060] Furthermore, based on the comparison between the second defect probability of each candidate shadow region belonging to the shadow region of the pitted reflection area in the image to be detected and the pitted shadow threshold, the pixels belonging to the shadow region of the pitted reflection area are obtained. The specific method is as follows: Set the pitted shadow threshold. It can be configured according to actual needs, and must meet certain requirements. Exemplary When the candidate shadow region of the pockmarked reflection area belongs to the second defect probability of the pockmarked shadow region in the image to be detected is greater than or equal to the pockmarked shadow threshold. When the candidate shadow region of the pockmarked reflection area is considered to belong to the pockmarked shadow region in the image to be detected, the other way around is not considered to belong to it.

[0061] S4. Based on the area characteristics of the pitted reflection area and the pitted shadow area, obtain the defect detection results of the VCSEL epitaxial wafer in the image to be detected.

[0062] It should be noted that a real pitting defect appears as an independent unit in an image, which is composed of a pitting reflection area and a pitting shadow area.

[0063] Specifically, based on each pitted reflection region and its paired pitted shadow region obtained in step S3, the combined area of ​​each pitted defect unit is calculated. This combined area is the sum of the area of ​​its reflection region and the area of ​​its shadow region: the total number of pixels in all pitted reflection regions is taken as the area of ​​the pitted reflection region; the total number of pixels in all pitted shadow regions is taken as the area of ​​the pitted shadow region. The ratio of the sum of the two areas to the area of ​​the image to be detected is taken as the defect detection result of the VCSEL epitaxial wafer in the image to be detected. The larger the ratio, the worse the surface quality of the epitaxial wafer, and vice versa.

Claims

1. A method for detecting defects in VCSEL epitaxial wafers based on image processing, characterized in that, include: The grayscale peak value of each sub-block is obtained based on the grayscale histogram of each sub-block; The background grayscale threshold is obtained based on the grayscale peak value of each sub-block and the disorder weight, which represents the degree of disorder in the grayscale distribution of pixels within each sub-block; the target pixels are selected based on the deviation between the grayscale value of each pixel and the background grayscale threshold; the first defect probability of the target pixel belonging to the pitted reflection area is obtained based on the roundness factor of the target pixel and the grayscale dominance factor, which represents the degree to which its grayscale value exceeds the background. Methods for obtaining the circularity factor of target pixels include: , It is the first Target pixels within each sub-block Circularity factor It is the first Target pixels within each sub-block of Within the neighborhood The gradient direction of each surrounding pixel It is the first The ideal circular tangent direction corresponding to each surrounding pixel. arrive There are eight fixed directions: 0°, 45°, 90°, 135°, 180°, 225°, 270°, and 315°. It is the orientation tolerance parameter; Based on the first defect probability, target pixels belonging to suspected pitted reflection regions are selected. These suspected pitted reflection regions are then clustered to obtain multiple pitted reflection regions. Candidate shadow regions are obtained based on the center coordinates and equivalent diameter of each pitted reflection region. A second defect probability is obtained based on the angle, grayscale value, and distance of each pixel within the candidate shadow region from the center of the pitted reflection region. This probability includes: , It is a candidate shaded area pixels within The probability of the second defect belonging to the pockmarked shadow area. It is a pixel. Relative to the pitted reflective area center coordinates The direction angle, It is a pixel. Relative to the pitted reflective area center coordinates Euclidean distance, It is the standard deviation of the grayscale peak values ​​of all sub-blocks. It is the background grayscale threshold. It is a pixel. grayscale value, It is the equivalent diameter. It is a preset micro value. It is a cosine function. Based on the natural constant An exponential function with base 1. It is an absolute value sign; the pitted shadow area corresponding to the pitted reflection area is determined according to the second defect probability; The defect detection result of the VCSEL epitaxial wafer in the image to be detected is obtained by the ratio of the sum of the areas of the pitted reflection area and the pitted shadow area to the area of ​​the image to be detected.

2. The method for detecting defects in VCSEL epitaxial wafers based on image processing according to claim 1, characterized in that, The step of obtaining the background grayscale threshold based on the grayscale peak value of each sub-block and the disorder weight representing the degree of disorder in the pixel grayscale distribution within each sub-block includes: ; In the formula, It is the background grayscale threshold; It is the first Disordered weights of individual sub-blocks; It is the first The gray-level peak value of the gray-level histogram of each sub-block; It is the index of the sub-block; It represents the total number of sub-blocks.

3. The method for detecting defects in VCSEL epitaxial wafers based on image processing according to claim 1, characterized in that, The step of selecting target pixels based on the deviation between the grayscale value of each pixel and the background grayscale threshold includes: The background grayscale threshold is used to obtain the standard deviation of the grayscale peak values ​​of all sub-blocks, denoted as . When pixel grayscale value satisfy: When that happens, the pixel is taken as the first... If a pixel within a sub-block belongs to the background area, then that pixel is considered the first pixel. The target pixels within each sub-block.

4. The VCSEL epitaxial wafer defect detection method based on image processing according to claim 1, characterized in that, The step of obtaining the first defect probability that the target pixel belongs to the pitted reflection region based on the circularity factor of the target pixel and the grayscale dominance factor that characterizes the degree to which its grayscale value exceeds the background significance includes: ; In the formula, It is the first Target pixels within each sub-block The probability of the first defect belonging to the speckled reflection region in the image to be detected; Target pixel grayscale value The magnitude exceeding the upper limit of the grayscale value of the background pixels; It is the standard deviation of the grayscale peak values ​​of all sub-blocks; It is the first Target pixels within each sub-block Circularity factor; It is the first Disordered weights of individual sub-blocks; It is the first Target pixels within each sub-block The gray-scale advantage factor.

5. The method for detecting defects in VCSEL epitaxial wafers based on image processing according to claim 1, characterized in that, The method for obtaining the reflective areas of each pockmark includes: Set the pitting reflection threshold It needs to meet the following requirements. When the probability of the first defect belonging to the pitted reflection region in the image to be detected is greater than or equal to the pitted reflection threshold, When the target pixel belongs to the speckled reflection area in the image to be detected, it does not belong to the image otherwise.

6. The method for detecting defects in VCSEL epitaxial wafers based on image processing according to claim 1, characterized in that, The methods for obtaining the center coordinates and equivalent diameter of each pitted reflection region include: The average coordinates of all target pixels in each pockmarked reflection region are used as the center coordinates of each pockmarked reflection region; the pockmarked reflection region The total number of target pixels is used as the pockmarked reflection area. area Then the pockmarked reflective area equivalent diameter .

7. The method for detecting defects in VCSEL epitaxial wafers based on image processing according to claim 1, characterized in that, The process of obtaining candidate shadow regions based on the center coordinates and equivalent diameter of each pockmarked reflection region includes: Reflective area with pockmarks center coordinates The horizontal direction to the right is 0°, and the angle increases sequentially in a clockwise direction; the angle range of the sector is... The angle between the positive axis and the sector boundary ray, with the angle between 30° and 60°, is used to set the radius range. .

8. The method for detecting defects in VCSEL epitaxial wafers based on image processing according to claim 1, characterized in that, The step of determining the pitted shadow region corresponding to the pitted reflection region based on the second defect probability includes: Set the dimple / shadow threshold It needs to meet the following requirements. When the candidate shadow region of the pockmarked reflection area belongs to the second defect probability of the pockmarked shadow region in the image to be detected is greater than or equal to the pockmarked shadow threshold. When the candidate shadow region of the pockmarked reflection area is considered to belong to the pockmarked shadow region in the image to be detected, the other way around is not considered to belong to it.

Citation Information

Patent Citations

  • Fuzzy clustering steel plate surface defect detection method based on pre classification

    CN104794491A

  • Metal mold quality detection method based on pocking mark defect

    CN115222735A