Methods for detecting and locating anchor frames and notch points in wafers

By using an improved YOLOv5-Seg model and adaptive data augmentation methods, combined with least squares fitting, the problem of insufficient positioning accuracy and robustness in wafer inspection is solved, achieving efficient and accurate wafer good inspection and notch positioning, which is suitable for embedded computing platforms.

CN120563620BActive Publication Date: 2026-04-03SICHUAN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-05-31
Publication Date
2026-04-03

AI Technical Summary

Technical Problem

Existing wafer defect detection and good product output technologies suffer from limited positioning accuracy and insufficient robustness. They are prone to misjudgment or missed detection, especially in complex environments, which affects the automation of wafer processing and handling.

Method used

An improved YOLOv5-Seg model is used for wafer image processing. Adaptive data augmentation and least squares fitting are combined to detect and locate the wafer good anchor frame and notch point. Feature extraction and mask segmentation are performed using EfficientVit-Backbone, Neck and Head structures, and the angle of the notch relative to the turntable is calculated.

Benefits of technology

It improves the accuracy and efficiency of wafer inspection, reduces the difficulty of network training, is suitable for deployment on embedded computing platforms, achieves high-precision notch positioning and angle determination, and supports automated handling and inspection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120563620B_ABST
    Figure CN120563620B_ABST
Patent Text Reader

Abstract

This invention discloses a method for detecting and locating anchor frames and notch points on wafers. The method includes cropping and normalizing an input wafer image dataset to obtain a preprocessed image; training an improved YOLOv5-Seg model using the preprocessed image, employing an adaptive data augmentation method designed in this invention to enhance the model's learning ability during training; the improved YOLOv5-Seg model comprises three parts: EfficientVit-Backbone, Neck, and Head; using the trained model to perform target detection and mask segmentation on the input wafer image, obtaining the detection box and mask segmentation result for each wafer; based on the mask segmentation result, using the least squares method to fit the center and radius of the fitted circle for each wafer, and locating the wafer notch based on the wafer contour pixel coordinates and their corresponding radius; transforming the wafer notch from the image coordinate system to the fitted circle coordinate system, and calculating the angle of the wafer notch relative to the turntable based on the transformed coordinates.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to wafer inspection technology, specifically to a method for detecting and locating wafer good quality anchor frames and notch points. Background Technology

[0002] With the continuous advancement of semiconductor manufacturing processes, wafers, as a core basic material, directly impact the yield and performance of downstream chips. In all stages of wafer manufacturing, packaging, and testing, defect detection, good product output, and notch positioning on the wafer surface are crucial steps for achieving efficient automated processing and quality control. Especially during wafer fabrication, dicing, and packaging processes, accurate positioning of the wafer notch is essential to ensure that robotic arms correctly align the wafer during handling and to prevent damage.

[0003] Currently, wafer defect detection and yield output technologies mostly employ machine vision methods, using algorithms such as image acquisition, image enhancement, feature extraction, and target recognition to identify and mark defects. However, due to the complex texture and severe reflection of wafer surfaces, as well as the small and irregular notch areas, traditional image processing methods have limited accuracy in notch localization and lack robustness. Furthermore, in yield determination, judgments are typically based solely on pixel grayscale or morphological features, which can easily lead to false positives or false negatives, affecting overall efficiency and accuracy.

[0004] Therefore, there is an urgent need for a wafer defect inspection and notch location method that combines robustness, accuracy, and real-time performance, capable of accurately extracting notch regions in complex contexts, and providing highly reliable basic data support for automated handling, inspection, and traceability systems. Summary of the Invention

[0005] In view of the above-mentioned steps in the prior art, the wafer good anchor frame and notch point detection and positioning method provided by the present invention solves the problem that the existing detection methods are prone to misjudgment or omission when detecting wafers.

[0006] To achieve the above-mentioned objectives, the technical solution adopted by this invention is as follows:

[0007] A method for detecting and locating anchor frames and notch points on wafers is provided, comprising the following steps:

[0008] S1. Cropping and normalizing the input wafer image dataset to obtain a preprocessed image;

[0009] S2. The improved YOLOv5-Seg model is trained using preprocessed images. Adaptive data augmentation is used during training to enhance the model's learning ability. The improved YOLOv5-Seg model consists of three parts: EfficientVit-Backbone, Neck, and Head.

[0010] S3. The trained model is used to perform target detection and mask segmentation on the input wafer image to obtain the detection box and mask segmentation result of each good wafer.

[0011] S4. Based on the mask segmentation results, the center and radius of the fitted circle for each good wafer are obtained by least squares fitting, and the wafer notch is located based on the wafer outline pixel coordinates and their corresponding radii.

[0012] S5. Transform the wafer notch from the image coordinate system to the fitted circle coordinate system, and calculate the angle of the wafer notch relative to the turntable based on the transformed coordinates.

[0013] Furthermore, adaptive data augmentation methods include:

[0014] S21. Perform data augmentation on the preprocessed image according to the augmentation strategy:

[0015] ,

[0016] in, For the j-th preprocessed image The enhanced image after applying the i-th enhancement strategy, For preprocessed images mean and standard deviation Adaptive parameters; This is a factor that controls the range of variation of the i-th enhancement strategy;

[0017] S22. Based on the model feedback during the training process of the improved YOLOv5-Seg model, calculate the weight parameters of each enhancement strategy:

[0018]

[0019] in, and These are the weight parameters corresponding to the i-th enhancement strategy during the (t+1)th and tth training iterations of the model, respectively; The learning rate; This represents the model feedback during the t-th training iteration.

[0020] S23. Based on the enhanced image and weight parameters corresponding to each enhancement strategy, calculate the final enhanced image for each preprocessed image:

[0021]

[0022] in, This is the final enhanced image of the j-th preprocessed image;

[0023] S24. Input the final enhanced images of all preprocessed images into the improved YOLOv5-Seg model for training, by adjusting the weight parameters. The objective function is minimized, and its expression is:

[0024]

[0025] in, The data distribution for all segmented images; The loss function; y represents the model's predicted output; y represents the true label. The objective function is... This is the regularization intensity coefficient;

[0026] S25. Determine whether the loss function of the improved YOLOv5-Seg model has converged to the optimal value or reached the set stopping condition. If yes, proceed to step S26; otherwise, return to step S22.

[0027] S26. Use all the final enhanced images corresponding to when the loss function converges to the optimal value or reaches the set stopping condition to train the improved YOLOv5-Seg model and obtain the trained model.

[0028] Furthermore, the EfficientVit network is used to extract features from the input image; the Neck part is used to perform multi-scale feature fusion on the feature map, and then it is fed into the detection head Proto for mask segmentation; the Head part is used for target detection, and the detection box and its mask segmentation result of the wafer good are obtained based on the mask segmentation.

[0029] The EfficientVit network performs feature extraction as follows:

[0030] The enhanced features are input into the EfficientVit network Stage1, downsampled by a factor of 4 through the MBConv layer, and the output size is extracted to be 128×160×160. In Stage 2, the output is downsampled by 4 times after passing through the MBConv layer, and the size is extracted to be 256×80×80. In Stage 3, after downsampling by 16 times through the MBConv layer and the EfficientViT-Module, an output of size 512×40×40 is obtained. In Stage 4, the output, after being downsampled by 32 times by the MBConv layer and the EfficientViT-Module, undergoes SPPF operation. The SPPF result is then augmented using the CBAM attention mechanism to extract an output of size 1024×20×20. .

[0031] Furthermore, methods for multi-scale feature fusion in the Neck portion include:

[0032] right Perform a convolution operation with a kernel size of 1×1 and 512 output channels, and process the resulting feature map. The feature map is obtained by performing an upsampling operation. ,right With feature map Perform a stitching operation to obtain an intermediate feature map. ;

[0033] right The C3 module operation is performed, and the result is then subjected to a convolution operation with a kernel size of 1×1 and an output channel count of 256 to obtain the feature map. Then, an upsampling operation is performed to obtain the feature map. ,right With feature map Perform a stitching operation to obtain an intermediate feature map. ;

[0034] right The C3 module operation is performed, and the result is then subjected to a convolution operation with a kernel size of 1×1 and 128 output channels to obtain the feature map. Then, an upsampling operation is performed to obtain the feature map. ,right With feature map Perform a stitching operation to obtain an intermediate feature map. ;

[0035] right Perform C3 module operations to obtain the output results of the first layer. Perform a convolution operation on it with a kernel size of 1×1 and an output channel number of 128 to obtain the feature map. Later and The feature map is obtained by performing a stitching operation. ;

[0036] right Perform operations on module C3 to obtain the output of the second layer. Perform a convolution operation on it with a kernel size of 1×1 and an output channel number of 256 to obtain the feature map. Later and The feature map is obtained by performing a stitching operation. ;

[0037] right Perform C3 module operations to obtain the output results of the third layer. Perform a convolution operation on it with a kernel size of 1×1 and an output channel number of 256, and then obtain the feature map and... The feature map is obtained by performing a stitching operation. ;

[0038] right Perform operations on module C3 to obtain the output of the fourth layer. ;Will , , and Each part is fed into a Proto detection head for mask segmentation.

[0039] Furthermore, the C3 module has a two-branch structure. One branch uses multiple Bottleneck stacks and three standard convolutional layers, while the other branch goes through a basic convolutional module. Finally, the two branches are concatenated to obtain the output result.

[0040] Furthermore, methods for obtaining the center and radius of the fitted circle for each wafer using the least squares method include:

[0041] S41. Calculate the mean value of all contour points of each good wafer in the mask segmentation result. :

[0042] ,

[0043] Where N is the total number of all contour points for each good wafer; and The coordinates of the k-th contour point;

[0044] S42. Based on the coordinates of all contour points and their average values ​​for each good wafer. Calculate intermediate variables , and :

[0045] , , ;

[0046] S43, Based on intermediate variables , and Calculate the center (a, b) of the fitted circle of the good wafer:

[0047] , ;

[0048] S44. Calculate the radius R of the fitted circle based on the center (a,b) of the fitted circle and the coordinates of all contour points of the good wafer:

[0049] .

[0050] Furthermore, methods for locating notches on a wafer include:

[0051] Calculate the distance from the pixel coordinates of the wafer profile to the center of the fitted circle. :

[0052]

[0053] Where k is the kth contour point, 1≤k≤N, and N is the total number of contour points for each good wafer.

[0054] Calculate distance The difference between the fitted circle radius and the actual radius is used. When the difference exceeds a preset threshold, it is marked as an outlier. All outliers of the same good wafer are used as wafer gaps.

[0055] Furthermore, step S5 further includes:

[0056] S51. Perform coordinate transformation on the contour points at the notch to obtain their coordinates in the local coordinate system with the center of the fitted circle as the origin:

[0057]

[0058] in, and Let be the coordinates of any contour point at the gap; and For the contour points ( , The transformed coordinates; (a, b) is the center of the fitted circle;

[0059] S52. Determine the distance from the center of the fitted circle to the contour point. , vectors And use the arctangent function to calculate the vector. Image coordinate system of wafer Angle between axes ;

[0060] S53. Calculate the notch angle relative to the turntable. :

[0061]

[0062] in, For the known fixed offset angles existing in the image coordinate system and the turntable coordinate system;

[0063] S54, Regarding the notch angle Adjustments were made to ensure it fell within the 0 to 360 degree range:

[0064] .

[0065] The beneficial effects of this invention are as follows:

[0066] (1) This scheme uses the improved YOLOv5-Seg model as the target detection and segmentation network, which can realize end-to-end good product detection and image segmentation of wafer images. The subsequent notch point localization is based on the identified wafer good product anchor frame, thereby reducing the difficulty of network training.

[0067] (2) This scheme uses EfficientVit combined with a small target detection layer (Neck part combined with multiple detection heads Proto) as the feature extraction network of the network. While ensuring accuracy, the detection time is shorter and the number of parameters is less, which makes it easier to integrate the algorithm into the embedded computing platform (Jetson nano).

[0068] (3) This solution can identify good wafers and generate mask segmentation results for them. The wafer can be represented in the form of edge contour. Based on this, the location information of the wafer notch can be accurately determined, and the angle of the wafer notch relative to the turntable can be determined.

[0069] (4) This solution combines deep learning algorithms, machine vision technology, etc. It only needs to collect wafer images after production to automatically complete wafer good product positioning, which greatly improves the efficiency and accuracy of wafer recognition and the degree of automation of related robots. It is conducive to the automation integration and promotion of the semiconductor industry in wafer production, processing and transportation. Attached Figure Description

[0070] Figure 1 A flowchart for the detection and positioning method of anchor frames and notch points for good wafers.

[0071] Figure 2 The network structure diagram of the improved YOLOv5-Seg model.

[0072] Figure 3 This is a network structure diagram of the EfficientVit network.

[0073] Figure 4 This is a schematic diagram of the Head section of the improved YOLOv5-Seg model. Detailed Implementation

[0074] The specific embodiments of the present invention are described below to enable those skilled in the art to understand the present invention. However, it should be understood that the present invention is not limited to the scope of the specific embodiments. For those skilled in the art, various changes are obvious as long as they are within the spirit and scope of the present invention as defined and determined by the appended claims. All inventions utilizing the concept of the present invention are protected.

[0075] refer to Figure 1 , Figure 1 A flowchart illustrating the detection and positioning method for wafer good anchor frames and notch points is shown; as follows: Figure 1 As shown, the method S includes steps S1 to S5.

[0076] In step S1, the input wafer image dataset is cropped and normalized to obtain a preprocessed image. The detailed implementation process of step S1 is as follows: First, the input wafer image dataset f is cropped to a uniform size of 640×640, and its RGB three-channel [0,255] pixel values ​​are normalized to [0,1], resulting in a size of N×3×640×640. , where N is the number of images input for one training iteration.

[0077] In step S2, the improved YOLOv5-Seg model is trained using preprocessed images. During the training process, an adaptive data augmentation method is used to enhance the model's learning ability. The improved YOLOv5-Seg model consists of three parts: EfficientVit-Backbone, Neck, and Head.

[0078] Adaptive data augmentation methods: At the start of training, adaptive data augmentation dynamically selects and adjusts augmentation strategies based on input data features and model feedback to improve the model's generalization ability and robustness. For different data features, the augmentation strategy can be adaptively adjusted. For example, in object detection tasks, if the model performs poorly in detecting objects at a specific angle, the system will increase the probability of corresponding rotation, scaling, or viewpoint changes; in low-contrast scenes, brightness and contrast adjustment strategies are enhanced to optimize the model's adaptability.

[0079] In one embodiment of the present invention, the adaptive data augmentation method includes the steps of:

[0080] S21. Perform data augmentation on the preprocessed image according to the augmentation strategy:

[0081] ,

[0082] in, For the j-th preprocessed image The enhanced image after applying the i-th enhancement strategy, For preprocessed images mean and standard deviation Adaptive parameters; This is a factor that controls the range of variation of the i-th enhancement strategy;

[0083] S22. Based on the model feedback during the training process of the improved YOLOv5-Seg model, calculate the weight parameters of each enhancement strategy:

[0084]

[0085] in, and These are the weight parameters corresponding to the i-th enhancement strategy during the (t+1)th and tth training iterations of the model, respectively; The learning rate; This represents the model feedback during the t-th training iteration.

[0086] S23. Based on the enhanced image and weight parameters corresponding to each enhancement strategy, calculate the final enhanced image for each preprocessed image:

[0087]

[0088] in, This is the final enhanced image of the j-th preprocessed image;

[0089] S24. Input the final enhanced images of all preprocessed images into the improved YOLOv5-Seg model for training, by adjusting the weight parameters. The objective function is minimized, and its expression is:

[0090]

[0091] in, The data distribution for all segmented images; The loss function; y represents the model's predicted output; y represents the true label. The objective function is... This is the regularization intensity coefficient;

[0092] S25. Determine whether the loss function of the improved YOLOv5-Seg model has converged to the optimal value or reached the set stopping condition. If yes, proceed to step S26; otherwise, return to step S22.

[0093] S26. Use the improved YOLOv5-Seg model to train all the final enhanced images corresponding to the loss function converging to the optimal value or reaching the set stopping condition, to obtain the trained model.

[0094] The EfficientVit network is used for feature extraction from the input image; the Neck part is used for multi-scale feature fusion of the feature map, and then the Neck part is fed into the Proto detection head for mask segmentation; the Head part is used for target detection, and the detection box and its mask segmentation result of the wafer good are obtained based on the mask segmentation.

[0095] like Figure 3 As shown, the EfficientVit network performs feature extraction as follows:

[0096] The enhanced features are input into the EfficientVit network Stage1, downsampled by a factor of 4 through the MBConv layer, and the output size is extracted to be 128×160×160. In Stage 2, the output is downsampled by 4 times after passing through the MBConv layer, and the size is extracted to be 256×80×80. In Stage 3, after downsampling by 16 times through the MBConv layer and the EfficientViT-Module, an output of size 512×40×40 is obtained. In Stage 4, the output, after being downsampled by 32 times by the MBConv layer and the EfficientViT-Module, undergoes SPPF operation. The SPPF result is then augmented using the CBAM attention mechanism to extract an output of size 1024×20×20. .

[0097] like Figure 2 As shown, the methods for multi-scale feature fusion in the Neck region include:

[0098] right Perform a convolution operation with a kernel size of 1×1 and 512 output channels, and process the resulting feature map. The feature map is obtained by performing an upsampling operation. ,right With feature map Perform a stitching operation to obtain an intermediate feature map. ;

[0099] right The C3 module operation is performed, and the result is then subjected to a convolution operation with a kernel size of 1×1 and an output channel count of 256 to obtain the feature map. Then, an upsampling operation is performed to obtain the feature map. ,right With feature map Perform a stitching operation to obtain an intermediate feature map. ;

[0100] right The C3 module operation is performed, and the result is then subjected to a convolution operation with a kernel size of 1×1 and 128 output channels to obtain the feature map. Then, an upsampling operation is performed to obtain the feature map. ,right With feature map Perform a stitching operation to obtain an intermediate feature map. ;

[0101] right Perform C3 module operations to obtain the output results of the first layer. Perform a convolution operation on it with a kernel size of 1×1 and an output channel number of 128 to obtain the feature map. Later and The feature map is obtained by performing a stitching operation. ;

[0102] right Perform operations on module C3 to obtain the output of the second layer. Perform a convolution operation on it with a kernel size of 1×1 and an output channel number of 256 to obtain the feature map. Later and The feature map is obtained by performing a stitching operation. ;

[0103] right Perform C3 module operations to obtain the output results of the third layer. Perform a convolution operation on it with a kernel size of 1×1 and an output channel number of 256, and then obtain the feature map and... The feature map is obtained by performing a stitching operation. ;

[0104] right Perform operations on module C3 to obtain the output of the fourth layer. ;Will , , and Each part is fed into a Proto detection head for mask segmentation.

[0105] The C3 module consists of two branches. One branch uses multiple Bottleneck stacks and three standard convolutional layers, while the other branch goes through a basic convolutional module. Finally, the two branches are concatenated to obtain the output result.

[0106] To improve feature extraction from wafers, this scheme concatenates a 4x downsampled feature map introduced in the P2 layer with a newly added upsampled large-scale feature map in the Neck structure, thereby outputting an additional small target detection head. It uses EfficientVit combined with the PANET feature pyramid network structure as the network's feature extraction network, reducing the number of network parameters while maintaining feature extraction performance, facilitating the deployment and integration of the algorithm onto embedded platforms.

[0107] EfficientViT is a lightweight feature extraction network that uses a lightweight ReLU global attention mechanism to replace the previously inefficient Softmax attention mechanism. This effectively reduces the computational complexity from quadratic to linear while maintaining the same feature extraction capability. Furthermore, EfficientViT combines the global receptive field with multi-scale learning, thereby providing broader contextual information and more scaled feature representations while maintaining lower computational cost.

[0108] In step S3, the trained model is used to perform target detection and mask segmentation on the input wafer image to obtain the detection box and mask segmentation result of each good wafer.

[0109] like Figure 4 As shown, the wafer image is obtained by processing the Backbone and Neck parts of the trained model. After performing a convolution operation with a kernel size of 1×1 and the number of output channels equal to the number of anchor boxes on the wafer, a sigmoid activation function is used in the output of class probability and target confidence to restrict the output values ​​to [0, 1]. Predefined large, medium, and small anchor boxes are then used to predict the bounding boxes of the target. The size of these anchor boxes is varied by performing K-means clustering on the target boxes in the training data to adapt to the bounding boxes of the real target. For each anchor box, the improved YOLOv5-Seg model predicts the center offset, width, and height of the bounding box, as well as the target confidence and class probability. The output is a confidence score indicating whether it is background, and a binary cross-entropy loss is calculated in conjunction with the annotations. Summarized according to a certain proportion:

[0110] ;

[0111] The target has suffered losses ( The bounding box loss is used to measure whether a grid cell contains a target, and uses binary cross-entropy loss to calculate the target confidence error; ) is used to measure the difference between the predicted bounding box and the ground truth bounding box; category classification loss ( This is used to measure the error between the predicted class probability and the true class label.

[0112] Specifically, the improved YOLOv5-Seg model outputs a confidence score. , The closer the value is to 1, the more likely the model believes the region contains a target. The closer to 0, the more likely the area is background. This is combined with real-world annotations. (When the target exists) =1, in background mode =0), the target has a loss. The expression is as follows:

[0113]

[0114] in, This is the number of anchor boxes involved in the calculation; It is the first The true category of each anchor box (1 represents the target, 0 represents the background); The model predicts the probability (confidence score) that the bounding box contains the target; finally, NMS filters out redundant bounding boxes. NMS retains the prediction with the highest confidence and suppresses low-confidence boxes with large overlap.

[0115] Refer again Figure 4 ,right Perform a 3×3 convolution followed by a Leaky ReLU non-linear activation function, with the number of channels equal to the output channels, to obtain intermediate feature maps. Since wafer image segmentation requires high-resolution masks, this model uses an upsampling layer to increase the spatial resolution of the feature map, doubling its size, and then connects it to a 3×3 convolution for feature fusion and refinement. The final image segmentation layer is typically a 1x1 convolutional layer used to transform the number of channels in the feature map to the required number of masks (i.e., an instance mask for each object). This layer outputs a mask coefficient matrix, which is multiplied by the input feature map to generate the final mask.

[0116] After the segmentation mask is generated, it is cropped to the specific target region based on the bounding box coordinates of the segmented wafer image. Each mask corresponds to a bounding box, ensuring that the mask only covers the detected target object. Non-maximum suppression (NMS) is then applied to filter out redundant overlapping boxes, retaining only the detection box with the highest confidence on the wafer and its corresponding mask segmentation result.

[0117] In step S4, based on the mask segmentation results, the center and radius of the fitted circle for each good wafer are obtained by least squares fitting, and the wafer notch is located based on the wafer outline pixel coordinates and their corresponding radii.

[0118] In implementation, this scheme preferably uses the least squares method to fit the center and radius of the fitted circle for each wafer, including:

[0119] S41. Calculate the mean value of all contour points of each good wafer in the mask segmentation result. :

[0120] ,

[0121] Where N is the total number of all contour points for each good wafer; and The coordinates of the k-th contour point;

[0122] S42. Based on the coordinates of all contour points and their average values ​​for each good wafer. Calculate intermediate variables , and :

[0123] , , ;

[0124] S43, Based on intermediate variables , and Calculate the center (a, b) of the fitted circle of the good wafer:

[0125] , ;

[0126] S44. Calculate the radius R of the fitted circle based on the center (a,b) of the fitted circle and the coordinates of all contour points of the good wafer:

[0127] .

[0128] The methods for locating the notch on the wafer include:

[0129] Calculate the distance from the pixel coordinates of the wafer profile to the center of the fitted circle. :

[0130]

[0131] Where k is the kth contour point, 1≤k≤N, and N is the total number of contour points for each good wafer.

[0132] Calculate distance The difference between the fitted circle radius and the actual radius is used. When the difference exceeds a preset threshold, it is marked as an outlier. All outliers of the same good wafer are used as wafer gaps.

[0133] In step S5, the wafer notch is transformed from the image coordinate system to the fitted circle coordinate system, and the angle of the wafer notch relative to the turntable is calculated based on the transformed coordinates; step S5 further includes:

[0134] S51. Perform coordinate transformation on the contour points at the notch to obtain their coordinates in the local coordinate system with the center of the fitted circle as the origin:

[0135]

[0136] in, and Let be the coordinates of any contour point at the gap; and For the contour points ( , The transformed coordinates; (a, b) is the center of the fitted circle;

[0137] S52. Determine the distance from the center of the fitted circle to the contour point. , vectors And use the arctangent function to calculate the vector. Image coordinate system of wafer Angle between axes ;

[0138] S53. Calculate the notch angle relative to the turntable. :

[0139]

[0140] in, For the known fixed offset angles existing in the image coordinate system and the turntable coordinate system;

[0141] S54, Regarding the notch angle Adjustments were made to ensure it was within the 0 to 360 degree range:

[0142] .

[0143] During training, the improved YOLOv5-Seg model in this scheme first needs to load the official pre-trained weights (the pre-trained weights are the convolutional kernel parameters of the trained deep learning detection and segmentation model; if not loaded, the initial weights are all 0), and then deploy the model to the CUDA platform to accelerate computation. The improved YOLOv5-Seg model calculates each loss through forward propagation and updates each parameter weight through backpropagation until the optimal deep learning detection and segmentation model weights are obtained.

[0144] Forward propagation calculates the loss of each parameter, i.e., the input image is processed by the convolution of each layer of the deep learning detection and segmentation model, and the output result is calculated. The loss (error) between the label and the output result is calculated. Backpropagation updates the weights of each parameter, i.e., the gradient (derivative) of the loss is used to calculate the gradient of each parameter in reverse order. The specific update method is stochastic gradient descent (SGD). The learning rate update strategy is as follows: the initial learning rate is 0.001, the initial learning rate is 0.000006, the deep learning detection and segmentation model is warmed up, and the learning rate is linearly increased to 0.001. Every 5 epochs of training, the learning rate is multiplied by 0.3.

[0145] To further validate the detection performance of the improved model, this approach compares the improved YOLOv5-Seg model with the YOLOv5s-Seg, YOLOv7s-Seg, and YOLOv8s-Seg instance segmentation models. These experiments were conducted on a dataset of 233 enhanced wafer images, with each model trained until convergence. Subsequently, the model was tested on a test set using weight files generated by different models, and the prediction rate, recall, mean precision, and parameter count obtained from the test set were compared to draw conclusions.

[0146] The model accuracy experiment results are shown in Table 1. By comparing the performance of different models in terms of prediction rate, recall rate, and mean precision, their performance differences in object detection and instance segmentation tasks can be evaluated. The model speed experiment results are shown in Table 2. By comparing the inference speed of different models, their response speed and efficiency in practical applications can be understood.

[0147] Table 1 Experimental results for different model accuracies

[0148]

[0149] Table 2. Experimental results of different models' velocities

[0150]

[0151] As shown in Table 2, the improved Yolov5s-Seg model exhibits a significant performance improvement compared to the existing Yolov5s-Seg, Yolov7s-Seg, and Yolov8s-Seg models. Specifically, the improved model... The scores improved by 2.7%, 2%, and 2.1% respectively, demonstrating the model's optimization in balancing precision and recall. Meanwhile, in The accuracy of the improved models was increased by 3.1%, 2.1%, and 2.3% respectively, indicating that the improved models have enhanced accuracy in localization and edge recognition.

[0152] Furthermore, the improved Yolov5s-Seg model demonstrates significant advantages in technical performance metrics. This not only makes the model more lightweight but also more computationally efficient, making it suitable for deployment in environments with limited computing resources, such as mobile devices and embedded systems. Since these devices typically have lower computing power and limited memory, a lightweight model is particularly important. The improved Yolov5s-Seg model significantly reduces the number of parameters, directly reducing storage requirements and memory footprint, enabling it to run on smaller devices.

[0153] Meanwhile, the reduction in floating-point operations significantly lowers the computational load of the model when performing inference tasks, improving processing speed, reducing energy consumption, and extending device battery life. The smaller model size also brings many benefits, especially in situations with poor network conditions or limited bandwidth, making it easier to transmit and update, reducing transmission and installation time. Furthermore, the model achieves faster inference speed and response time while maintaining accuracy and performance.

Claims

1. A method for detecting and locating anchor frames and notch points on wafers, characterized in that, Including the following steps: S1. Cropping and normalizing the input wafer image dataset to obtain a preprocessed image; S2. The improved YOLOv5-Seg model is trained using preprocessed images. Adaptive data augmentation is used during training to enhance the model's learning ability. The improved YOLOv5-Seg model consists of three parts: EfficientVit-Backbone, Neck, and Head. S3. The trained model is used to perform target detection and mask segmentation on the input wafer image to obtain the detection box and mask segmentation result of each good wafer. S4. Based on the mask segmentation results, the center and radius of the fitted circle for each good wafer are obtained by least squares fitting, and the wafer notch is located based on the wafer outline pixel coordinates and their corresponding radii. S5. Transform the wafer notch from the image coordinate system to the fitted circle coordinate system, and calculate the angle of the wafer notch relative to the turntable based on the transformed coordinates.

2. The method for detecting and locating wafer defect anchor frames and notch points according to claim 1, characterized in that, Adaptive data augmentation methods include the following steps: S21. Perform data augmentation on the preprocessed image according to the augmentation strategy: , in, For the j-th preprocessed image The enhanced image after applying the i-th enhancement strategy, For preprocessed images mean and standard deviation Adaptive parameters; This is a factor that controls the range of variation of the i-th enhancement strategy; S22. Based on the model feedback during the training process of the improved YOLOv5-Seg model, calculate the weight parameters of each enhancement strategy: in, and These are the weight parameters corresponding to the i-th enhancement strategy during the (t+1)th and tth training iterations of the model, respectively; The learning rate; This represents the model feedback during the t-th training iteration. S23. Based on the enhanced image and weight parameters corresponding to each enhancement strategy, calculate the final enhanced image for each preprocessed image: in, This is the final enhanced image of the j-th preprocessed image; S24. Input the final enhanced images of all preprocessed images into the improved YOLOv5-Seg model for training, by adjusting the weight parameters. The objective function is minimized, and its expression is: in, The data distribution for all segmented images; The loss function; y represents the model's predicted output; y represents the true label. The objective function is... This is the regularization intensity coefficient; S25. Determine whether the loss function of the improved YOLOv5-Seg model has converged to the optimal value or reached the set stopping condition. If yes, proceed to step S26; otherwise, return to step S22. S26. Use all the final enhanced images corresponding to when the loss function converges to the optimal value or reaches the set stopping condition to train the improved YOLOv5-Seg model and obtain the trained model.

3. The method for detecting and locating wafer defect anchor frames and notch points according to claim 1, characterized in that, The EfficientVit network is used for feature extraction from the input image; the Neck part is used for multi-scale feature fusion of the feature map, and then the Neck part is fed into the Proto detection head for mask segmentation; the Head part is used for target detection, and the detection box and its mask segmentation result of the wafer good are obtained based on the mask segmentation. The EfficientVit network performs feature extraction as follows: The enhanced features are input into the EfficientVit network Stage1, downsampled by a factor of 4 through the MBConv layer, and the output size is extracted to be 128×160×160. In Stage 2, the output is downsampled by 4 times after passing through the MBConv layer, and the size is extracted to be 256×80×80. In Stage 3, after downsampling by 16 times through the MBConv layer and the EfficientViT-Module, an output of size 512×40×40 is obtained. In Stage 4, the output, after being downsampled by 32 times by the MBConv layer and the EfficientViT-Module, undergoes SPPF operation. The SPPF result is then augmented using the CBAM attention mechanism to extract an output of size 1024×20×20. .

4. The method for detecting and locating wafer defect anchor frames and notch points according to claim 3, characterized in that, Methods for multi-scale feature fusion in the Neck region include: right Perform a convolution operation with a kernel size of 1×1 and 512 output channels, and process the resulting feature map. The feature map is obtained by performing an upsampling operation. ,right With feature map Perform a stitching operation to obtain an intermediate feature map. ; right The C3 module operation is performed, and the result is then subjected to a convolution operation with a kernel size of 1×1 and an output channel count of 256 to obtain the feature map. Then, an upsampling operation is performed to obtain the feature map. ,right With feature map Perform a stitching operation to obtain an intermediate feature map. ; right The C3 module operation is performed, and the result is then subjected to a convolution operation with a kernel size of 1×1 and 128 output channels to obtain the feature map. Then, an upsampling operation is performed to obtain the feature map. ,right With feature map Perform a stitching operation to obtain an intermediate feature map. ; right Perform C3 module operations to obtain the output results of the first layer. Perform a convolution operation on it with a kernel size of 1×1 and an output channel number of 128 to obtain the feature map. Later and The feature map is obtained by performing a stitching operation. ; right Perform operations on module C3 to obtain the output of the second layer. Perform a convolution operation on it with a kernel size of 1×1 and an output channel number of 256 to obtain the feature map. Later and The feature map is obtained by performing a stitching operation. ; right Perform C3 module operations to obtain the output results of the third layer. Perform a convolution operation on it with a kernel size of 1×1 and an output channel number of 256, and then obtain the feature map and... The feature map is obtained by performing a stitching operation. ; right Perform operations on module C3 to obtain the output of the fourth layer. ;Will , , and Each part is fed into a Proto detection head for mask segmentation.

5. The method for detecting and locating wafer defect anchor frames and notch points according to claim 4, characterized in that, The C3 module consists of two branches. One branch uses multiple Bottleneck stacks and three standard convolutional layers, while the other branch goes through a basic convolutional module. Finally, the two branches are concatenated to obtain the output result.

6. The method for detecting and locating wafer defect anchor frames and notch points according to claim 1, characterized in that, Methods for obtaining the center and radius of the fitted circle for each wafer using the least squares method include: S41. Calculate the mean value of all contour points of each good wafer in the mask segmentation result. : , Where N is the total number of all contour points for each good wafer; and The coordinates of the k-th contour point; S42. Based on the coordinates of all contour points and their average values ​​for each good wafer. Calculate intermediate variables , and : , , ; S43. Based on intermediate variables , and Calculate the center (a, b) of the fitted circle of the good wafer: , ; S44. Calculate the radius R of the fitted circle based on the center (a,b) of the fitted circle and the coordinates of all contour points of the good wafer: 。 7. The method for detecting and locating wafer defect anchor frames and notch points according to claim 1, characterized in that, Methods for locating wafer notches include: Calculate the distance from the pixel coordinates of the wafer profile to the center of the fitted circle. : Where k is the kth contour point, 1≤k≤N, and N is the total number of contour points for each good wafer. Calculate distance The difference between the fitted circle radius and the actual radius is used. When the difference exceeds a preset threshold, it is marked as an outlier. All outliers of the same good wafer are used as wafer gaps.

8. The method for detecting and locating wafer defect anchor frames and notch points according to any one of claims 1-7, characterized in that, Step S5 further includes: S51. Perform coordinate transformation on the contour points at the notch to obtain their coordinates in the local coordinate system with the center of the fitted circle as the origin: in, and Let be the coordinates of any contour point at the gap; and For the contour points ( , The transformed coordinates; (a, b) is the center of the fitted circle; S52. Determine the distance from the center of the fitted circle to the contour point. , vectors And use the arctangent function to calculate the vector. Image coordinate system of wafer Angle between axes ; S53. Calculate the notch angle relative to the turntable. : in, For the known fixed offset angles existing in the image coordinate system and the turntable coordinate system; S54, Regarding the notch angle Adjustments were made to ensure it was within the 0 to 360 degree range: 。

Citation Information

Patent Citations

  • Weak supervision fine-grained image recognition method based on visual self-attention mechanism

    CN111539469A

  • Wafer positioning and orienting method and wafer edge detection device thereof

    CN115995416A