Wafer defect classification method, wafer defect classification device, wafer defect classification equipment and storage medium
By performing pixel difference processing and cluster analysis on wafer images, combining the SIFT algorithm to extract feature points and regional statistical features, and training machine learning models, the problem of reduced model accuracy caused by wafer atlas imaging is solved, and more efficient defect classification and identification is achieved.
Patent Information
- Application Number
- CN202511156436.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-18
- Publication Date
- 2025-10-17
AI Technical Summary
In the existing technology, wafer atlas imaging is based on secondary judgment imaging after optical scanning, which leads to reduced accuracy of model training samples and insufficient model classification accuracy and robustness.
By obtaining the grayscale image of the sample wafer and the reference grayscale image, pixel difference processing is performed to generate a difference image. Cluster analysis is used to screen out candidate defect areas. The SIFT algorithm is combined to extract feature points and regional statistical features to construct feature vectors. The machine learning algorithm is used to train the defect classification model.
The training efficiency and classification accuracy of the defect classification model are improved, the robustness and applicability of the model are enhanced, and different types of defects can be identified and classified more accurately.
Smart Images

Figure CN120808042A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of semiconductor technology, and in particular to a wafer defect classification method, device, equipment and storage medium. BACKGROUND
[0002] The processing technology in wafer manufacturing can cause defects on the wafer surface. Among the defect types of the wafer, mechanical scratches, crystal defects and wafer surface attachments are relatively common defects. Mechanical scratches are commonly found in scenarios where mechanical grinding and polishing are not in place; crystal defects are usually caused by processing parameters such as insufficient heat treatment time, uneven film deposition, and contaminated photomask; and surface attachments are commonly found when the excess photoresist liquid is not cleaned properly during the debonding process. As the core link of the semiconductor industry chain, wafer manufacturing directly affects the chip performance and yield rate, so after wafer processing is completed, the defects (such as mechanical scratches, crystal defects, wafer surface attachments, etc.) generated in the processing process need to be classified and detected to find the specific reasons for the defects and to improve the process accordingly.
[0003] The present application relates to the technical field of semiconductor technology, and in particular to a wafer defect classification method, device, equipment and storage medium. SUMMARY
[0004] The present application provides a wafer defect classification method, device, equipment and storage medium, which can improve the data quality and accuracy of the defect classification model training input, thereby improving the model training efficiency and the classification accuracy of the model, improving the robustness of the model, and having strong applicability.
[0005] In a first aspect, the application provides a wafer defect classification method, comprising: obtaining a sample wafer grayscale image, and performing pixel difference processing on pixel points of the sample wafer grayscale image and a reference grayscale image to generate a difference image corresponding to the sample wafer grayscale image, wherein the difference image includes a plurality of candidate defect regions; clustering the pixel points in the difference image, and obtaining a plurality of defect regions corresponding to the sample wafer grayscale image from the plurality of candidate defect regions according to the clustering results of the pixel points, wherein each defect region includes a group of feature points for wafer defect classification, and each group of feature points includes a plurality of feature points; constructing a plurality of groups of feature vectors corresponding to the plurality of defect regions based on the group of feature points included in each defect region and the regional statistical characteristics of each defect region, wherein each group of feature vectors includes a plurality of feature vectors, and the plurality of feature vectors correspond one-to-one to the plurality of feature points in the group of feature points included in the defect region; training a defect classification model according to the plurality of groups of feature vectors corresponding to each defect region and the defect category labels corresponding to the defect regions; when a wafer image of a wafer to be detected is obtained, obtaining a target feature vector group corresponding to the wafer image and inputting the target feature vector group into the defect classification model, and outputting the defect category of the wafer to be detected through the defect classification model. In the application, the pixel difference processing and clustering analysis of the sample wafer grayscale image and the reference image can effectively screen out defect regions, and the feature vectors are constructed based on the feature points and the regional statistical characteristics, and then the defect classification model is trained, which optimizes the processing of sample data, can quickly remove the interference of non-defect regions, can improve the sample data quality, and then improves the training efficiency and classification accuracy of the defect classification model, the model has strong robustness and strong applicability.
[0006] In a possible implementation of the first aspect, the plurality of defect regions corresponding to the sample wafer grayscale image are obtained from the plurality of candidate defect regions according to the clustering results of the pixel points, comprising: sorting the plurality of candidate defect regions according to the area from large to small according to the clustering results of the pixel points, and determining a plurality of defect regions with a large area from the plurality of candidate defect regions based on the sorting results of the area. In the application, the candidate defect regions are sorted according to the clustering results of the pixel points according to the area from large to small, and the regions with a large area are selected as the defect regions, which can focus on more significant defects, thereby improving the pertinence and effectiveness of detection, can reduce the error caused by small area noise or pseudo-defects, and at the same time improve the detection efficiency, ensure that limited detection resources are preferentially allocated to more prominent defects, and further improve the accuracy and reliability of the overall detection.
[0007] In a possible implementation of the first aspect, the constructing a plurality of groups of feature vectors corresponding to the plurality of defect regions based on the group of feature points included in each of the defect regions and the region statistical features of each of the defect regions comprises: extracting the group of feature points included in each of the defect regions based on a scale-invariant feature transform (SIFT) algorithm; calculating the region statistical features of each of the defect regions, wherein the region statistical features comprise one or more of an aspect ratio and an average gray value; and constructing the plurality of groups of feature vectors corresponding to the plurality of defect regions based on the group of feature points included in each of the defect regions and the region statistical features of each of the defect regions. In this application, the SIFT algorithm can extract stable and significant feature points in different scale spaces. These feature points have strong invariance to rotation, scale, brightness change, and noise. The feature points are combined with the region statistical features to construct feature vectors. One feature point constructs one feature vector, one defect region corresponds to one group of feature vectors, which further enriches the information of the feature vectors, enables the feature vectors to more comprehensively describe the characteristics of the defect regions, improves the robustness and accuracy of feature extraction, can enhance the recognition ability of the defect classification model for different types of defects, and thus improves the performance of the overall defect classification of the model, and has strong applicability.
[0008] In a possible implementation of the first aspect, the training the defect classification model according to the plurality of groups of feature vectors corresponding to each of the defect regions and the defect class labels corresponding to the defect regions comprises: obtaining a defect classification label corresponding to each of the defect regions, wherein the defect classification label is used to mark the defect class corresponding to each of the defect regions; taking the plurality of groups of feature vectors corresponding to each of the defect regions and the defect classification label as inputs of the defect classification model, and training the defect classification model by using a machine learning algorithm; and wherein the machine learning algorithm comprises one of a logistic regression algorithm, a support vector machine (SVM) algorithm, a K-nearest neighbor algorithm, and a decision tree algorithm. In this application, by selecting a diversified machine learning algorithm, the most suitable model training method can be selected according to the characteristics and complexity of the sample data to improve the flexibility and adaptability of model training, enhance the generalization ability of the model, enable the defect classification model to more accurately identify and classify different types of defects, improve the accuracy and reliability of classification, and have strong applicability.
[0009] In a possible implementation of the first aspect, the obtaining of the target feature vector set corresponding to the wafer image comprises: performing grayscale processing on the wafer image to obtain a target wafer grayscale image corresponding to the wafer image; generating a target difference image corresponding to the target wafer grayscale image based on the target wafer grayscale image and the reference grayscale image, wherein the target difference image includes a plurality of candidate target defect regions; clustering pixel points in the target difference image, and obtaining a plurality of target defect regions corresponding to the target wafer grayscale image from the plurality of candidate target defect regions according to a clustering result of the pixel points, wherein each target defect region includes a group of feature points for wafer defect classification, and each group of feature points includes a plurality of feature points; and constructing a plurality of target feature vectors corresponding to the plurality of target defect regions based on the group of feature points included in each target defect region and the region statistical features of each defect region, wherein each target feature vector includes a plurality of feature vectors, and the plurality of feature vectors correspond to a plurality of feature points in the group of feature points included in the target defect region.
[0010] In a second aspect, the present application provides a wafer defect classification device, comprising:
[0011] an image processing module configured to obtain a sample wafer grayscale image, and perform pixel difference processing on pixel points of the sample wafer grayscale image and a reference grayscale image to generate a difference image corresponding to the sample wafer grayscale image, wherein the difference image includes a plurality of candidate defect regions;
[0012] a defect region obtaining module configured to cluster the pixel points in the difference image, and obtain a plurality of defect regions corresponding to the sample wafer grayscale image from the plurality of candidate defect regions according to a clustering result of the pixel points, wherein each defect region includes a group of feature points for wafer defect classification, and each group of feature points includes a plurality of feature points;
[0013] a feature vector obtaining module configured to construct a plurality of feature vectors corresponding to the plurality of defect regions based on the group of feature points included in each defect region and the region statistical features of each defect region, wherein each feature vector includes a plurality of feature vectors, and the plurality of feature vectors correspond to a plurality of feature points in the group of feature points included in the defect region;
[0014] a model training module configured to train a defect classification model according to the plurality of groups of feature vectors corresponding to the respective defect regions and the defect categories corresponding to the respective defect regions;
[0015] a defect classification module configured to, when a wafer image of a wafer to be detected is obtained, obtain a target group of feature vectors corresponding to the wafer image and input the target group of feature vectors into the defect classification model, and output a defect category of the wafer to be detected by the defect classification model.
[0016] In the present application, wafer defect classification can be achieved through the cooperation of the image processing module, the defect region acquisition module, the feature vector acquisition module, the model training module, and the defect classification module. The image processing module can quickly obtain a sample wafer grayscale image and generate a difference image to locate a candidate defect region. The defect region acquisition module can accurately filter defect regions by using cluster analysis to remove noise interference. The model training module can construct a feature vector based on feature points and regional statistical features to train a defect classification model, thereby improving the recognition ability and recognition accuracy of the model. The defect classification module can be used to input the feature vector of a wafer image to be detected into the model to quickly and accurately output a defect category. The modular design of the wafer defect classification device optimizes the defect classification process, improves the robustness and generalization ability of the model, improves the classification precision and accuracy of the model, and has high applicability.
[0017] In a possible implementation of the second aspect, the defect region acquisition module comprises:
[0018] a clustering submodule configured to cluster the pixel points in the difference image to obtain a clustering result of the pixel points;
[0019] a region determination submodule configured to sort the plurality of candidate defect regions according to the region areas from large to small based on the clustering result of the pixel points obtained by the clustering submodule, and determine a plurality of defect regions with region areas in the front from the plurality of candidate defect regions based on the sorting result of the region areas.
[0020] In a possible implementation of the second aspect, the feature vector acquisition module comprises:
[0021] a feature point extraction submodule configured to extract a group of feature points included in each of the defect regions from each of the defect regions based on a scale-invariant feature transform (SIFT) algorithm;
[0022] a statistical feature calculation submodule configured to calculate regional statistical features of each of the defect regions, wherein the regional statistical features comprise one or more of an aspect ratio and an average grayscale value;
[0023] The vector construction submodule is configured to construct a plurality of groups of feature vectors corresponding to the plurality of defect regions based on a group of feature points included in each of the defect regions and a region statistical feature of each of the defect regions.
[0024] In a possible implementation of the second aspect, the model training module includes:
[0025] The identification acquisition submodule is configured to acquire a defect classification identification corresponding to each of the defect regions, where the defect classification identification is used to mark a defect category corresponding to each of the defect regions.
[0026] The algorithm execution submodule is configured to use a machine learning algorithm to train the defect classification model by taking the plurality of groups of feature vectors corresponding to each of the defect regions and the defect classification identification as inputs of the defect classification model, where the machine learning algorithm includes one of a logistic regression algorithm, a support vector machine (SVM) algorithm, a K-nearest neighbor algorithm, and a decision tree algorithm.
[0027] In a possible implementation of the second aspect, the defect classification module includes:
[0028] The difference image acquisition submodule is configured to perform grayscale processing on a wafer image of a wafer to be detected to obtain a target wafer grayscale image corresponding to the wafer image when the wafer image is obtained, and generate a target difference image corresponding to the target wafer grayscale image based on the target wafer grayscale image and the reference grayscale image, where the target difference image includes a plurality of candidate target defect regions.
[0029] The region acquisition submodule is configured to cluster pixel points in the target difference image, and obtain a plurality of target defect regions corresponding to the target wafer grayscale image from the plurality of candidate target defect regions according to a clustering result of the pixel points, where each of the target defect regions includes a group of feature points used for wafer defect classification, and each group of feature points includes a plurality of feature points.
[0030] The feature vector generation submodule is configured to construct a plurality of groups of target feature vectors corresponding to the plurality of target defect regions based on a group of feature points included in each of the target defect regions and a region statistical feature of each of the defect regions, where each group of target feature vectors includes a plurality of feature vectors, and the plurality of feature vectors correspond to a plurality of feature points in a group of feature points included in a target defect region where the plurality of feature vectors are located.
[0031] The result generation submodule is configured to input the target feature vector groups into the defect classification model, and output a defect category of the wafer to be detected by the defect classification model.
[0032] In a third aspect, the present application provides an electronic device, comprising: a processor and a memory; the memory is configured to store program codes; the processor is configured to invoke the program codes stored in the memory and execute the wafer defect classification method provided in the first aspect and any possible implementation manner of the first aspect.
[0033] In a fourth aspect, the present application provides a computer storage medium, the storage medium stores at least one instruction, the at least one instruction is configured to be executed by a processor to implement the wafer defect classification method provided in the first aspect and any possible implementation manner of the first aspect.
[0034] In a fifth aspect, the present application provides a computer program product, when the computer program product is run on an electronic device, the electronic device is caused to execute the wafer defect classification method provided in the first aspect and any possible implementation manner of the first aspect. BRIEF DESCRIPTION OF DRAWINGS
[0035] Figure 1 FIG. 1 is a schematic diagram of a system architecture of the wafer defect classification method provided by the embodiments of the present application;
[0036] Figure 2 FIG. 2 is a schematic diagram of a flow of the wafer defect classification method provided by the embodiments of the present application;
[0037] Figure 3 FIG. 3 is a schematic diagram of a data flow of the defect classification model provided by the embodiments of the present application;
[0038] Figure 4 FIG. 4 is a schematic diagram of the structure of the wafer defect classification device provided by the embodiments of the present application;
[0039] Figure 5 FIG. 5 is a schematic diagram of the structure of the electronic device provided by the embodiments of the present application. DETAILED DESCRIPTION
[0040] The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the scope of protection of the present application.
[0041] Wafers are the fundamental material for semiconductor manufacturing. They are typically made from high-purity single-crystal silicon through a series of precision machining processes, resulting in a circular, thin sheet with common diameters of 200 mm and 300 mm. Wafers play a crucial role in the chip manufacturing process. First, through a series of complex micro-nanofabrication processes, including high-temperature diffusion, etching, thin film deposition, and ion implantation, tiny electronic components such as transistors, capacitors, and resistors, as well as complex circuit connection structures, are precisely constructed on the wafer surface. Subsequently, through the alternating deposition of multiple layers of metal wiring and insulating layers, a complete integrated circuit pattern is formed. Ultimately, the wafer can be cut into tiny chip units (dies), each with independent circuit functions that can be packaged and applied to various electronic devices. Therefore, the wafer is not only the physical carrier of the chip but also the key platform for realizing its functions. Its quality and the quality of its manufacturing process directly determine the performance and reliability of the chip.
[0042] In today's digital age, advanced technologies such as artificial intelligence, intelligent communications, and the Internet of Things are rapidly driving global technological change and progress. Demand for high-performance chips across various industries is also exploding. For example, the complex computing tasks of AI require powerful chip processing capabilities, the high-speed data transmission of intelligent communications relies on low-latency, high-bandwidth chips, and the massive connectivity of the Internet of Things places even higher demands on chips with low power consumption and high integration. These demands not only present unprecedented opportunities for the wafer manufacturing industry but also drive continuous breakthroughs and innovations in manufacturing processes. Wafer manufacturing companies face enormous market potential while also shouldering the responsibility of meeting the growing demand for high-performance chips. This undoubtedly opens up vast opportunities for the industry's development.
[0043] Wafer manufacturing, as the basis of chip production, is also a key link in the semiconductor industry. Its importance is self-evident. The level of wafer manufacturing technology directly determines the performance and quality of chips. However, in the wafer manufacturing process, complex processing techniques can cause a variety of defects on the wafer surface, which can seriously affect the performance and reliability of the chip. Common defect types include, but are not limited to, mechanical scratches, crystal defects, and surface attachments. Mechanical scratches usually occur during mechanical grinding or polishing processes. When process parameters are not properly controlled or equipment precision is insufficient, scratches can appear on the wafer surface, affecting the precision and quality of subsequent processes. Crystal defects are often caused by improper processing parameter settings, such as insufficient heat treatment time, uneven film deposition, or contaminated masks. These factors can cause defects in the crystal structure inside or on the wafer surface, affecting the electrical performance of the chip. The presence of surface attachments is relatively common, especially during the de-gluing process. If the excess photoresist liquid is not completely cleaned, residual attachments can interfere with subsequent etching or deposition processes, causing abnormal chip function. As a core link in the semiconductor industry chain, wafer manufacturing directly affects chip performance and yield. Therefore, after wafer processing is complete, defects such as mechanical scratches, crystal defects, and wafer surface attachments need to be classified and detected to find the specific causes of the defects and make process improvements and optimize equipment operation to reduce the occurrence of defects and ensure high-quality chip production.
[0044] The wafer defect classification method provided by the embodiments of the present application can be applied to quality detection scenarios of wafer production processes, wafer production equipment maintenance and fault diagnosis scenarios, wafer processing process optimization scenarios, and automatic detection and classification scenarios. It can be used to classify and detect defects in wafers and output defect classification results. The defect classification results include, but are not limited to, mechanical scratches, crystal defects, wafer surface attachments, film deposition defects, etching defects, doping defects, and heat treatment defects. The specific application scenarios can be determined, and are not limited here. It can be understood that the various defect categories in the above examples can exist alone in the same wafer, or multiple types of defects can exist in the same wafer. Defects can interact with each other, further exacerbating the negative impact on wafer performance and reliability. The specific application scenarios can be determined, and are not limited here.
[0045] The embodiments of the present application take the semiconductor wafer measurement scenario as an example for illustration. For ease of description, the system architecture of the wafer defect classification method provided by the embodiments of the present application is combined with the wafer defect classification method provided by the embodiments of the present application. Figure 1 The system architecture of the wafer defect classification method provided by the embodiments of the present application is described.
[0046] Referring to Figure 1 , Figure 1 is a system architecture diagram of the wafer defect classification method provided by the embodiments of the present application. AsFigure 1 As shown, the system architecture can include a server 110, a terminal device 120, an image acquisition device 130, and a motion stage 140. Here, the motion stage 140 can be used to carry a wafer 150 to drive the wafer to move to adjust the position of the wafer. The server 110 can be a stand-alone physical server, a server cluster composed of multiple physical servers, or a distributed system, and can also be a cloud server providing basic cloud computing services such as cloud database, cloud service, cloud computing, cloud function, cloud storage, network service, cloud communication, middleware service, domain name service, security service, content delivery network (CDN), and big data and artificial intelligence platform. The terminal device 120 can be a smart terminal such as a palm computer, a smart phone, a notebook computer, a desktop computer, a tablet computer, a mobile internet device (MID), a wearable device (such as a smart watch, a smart bracelet, etc.), and a smart computer, and the specific terminal device can be determined according to the actual application scenario, which is not limited here. The server 110 and the terminal device 120 can establish a communication connection, and the communication connection is not limited to the connection mode, which can be directly or indirectly connected through wired communication or directly or indirectly connected through wireless communication, and the specific connection mode can be determined according to the actual application scenario, which is not limited here.
[0047] It should be understood that the terminal device 120 can be used to interact with the image acquisition device 130 and the equipment in the semiconductor measurement machine (not shown in the figure) such as the motion stage 140. The semiconductor measurement machine can be a wafer scanning detection machine, a wafer review machine, and other common semiconductor measurement equipment. The semiconductor measurement machine can also include, but is not limited to, a light source system, a control system, a software system, a calibration system, and other components, and the specific components can be determined according to the actual application scenario, which is not limited here. The terminal device 120 can send a control instruction to the semiconductor measurement machine to control the equipment in the semiconductor measurement machine to work to obtain a wafer image. For example, the terminal device 120 can send a motion control instruction to the motion stage 140 to control the motion stage to move to drive the wafer to move to adjust the position of the wafer. The terminal device 120 can also send an image acquisition instruction to the image acquisition device 130 to control the image acquisition device 130 to perform alignment scanning and other shooting operations on the wafer to obtain a wafer image, and obtain the photographed wafer image from the image acquisition device 130. The specific operation can be determined according to the actual application scenario, which is not limited here.
[0048] It should be understood that the terminal device 120 as shown can interact with the equipment in the semiconductor measurement machine as described above. Figure 1 The terminal device 120 as shown can interact with the equipment in the semiconductor measurement machine as described above. Figure 1The servers 110 shown are in data interaction, so that the servers 110 can receive service data from the terminal device 120, and the service data can be wafer image original data or preprocessed wafer image data, etc., which can be shared with the servers 110.
[0049] In some possible implementations, the terminal device 120 can be an execution subject of the wafer defect classification method provided in the embodiments of the present application, that is, the terminal device 120 can perform training and application of the wafer defect classification model. For example, as shown in FIG. 1, the terminal device 120 can be a wafer inspection device, and the terminal device 120 can be connected to the server 110 through a network, and the terminal device 120 can receive the wafer defect classification model from the server 110, and the terminal device 120 can perform wafer defect classification by using the wafer defect classification model. Figure 1As shown, assuming that the wafer 150 carried on the motion platform 140 is a sample wafer, the terminal device 120 can control the motion of the motion platform 140 and control the image acquisition device 130 to scan the sample wafer to obtain multiple sample wafer images. Alternatively, the sample wafer image can also be historical wafer scanning data. The above historical wafer scanning data can be stored in the terminal device 120 and directly read by the terminal device 120. The above historical wafer scanning data can also be stored in the server 110, and the terminal device 120 can send a download request to the server 110 to obtain the above historical wafer scanning data. The specific application scenario can be determined, and this is not limited here. Alternatively, the sample wafer image can also be wafer image data classified and recognized by other means after the sample wafer defect category is classified. It can be understood that the wafer image data can at least include sample wafer image and corresponding sample wafer defect category identification, etc. The specific application scenario can be determined, and this is not limited here. The terminal device 120 can perform image processing work on the obtained sample wafer image, including but not limited to image enhancement, image correction, image difference processing, image feature vector construction, etc. to generate a data set for training, and then train the wafer defect classification model in the terminal device 120 based on the above data set. When the terminal device 120 obtains a wafer image of a wafer to be detected, it can perform image processing work on the wafer image of the wafer to be detected, including but not limited to image enhancement, image correction, image difference processing, image feature vector construction, etc. to obtain the feature vector corresponding to the defect area in the wafer image of the wafer to be detected, and input the feature vector into the trained wafer defect model to output the defect category of the wafer to be detected through the wafer defect model. Alternatively, the above data set, the training parameters of the wafer defect model, the training progress of the wafer defect model, the identification result of the defect category of the wafer, and other business data can be shared with the server 110, and other terminal devices or other servers connected to the server 110 can share data. In the embodiment of the present application, the training and application of the wafer defect detection model can be completely deployed on the terminal device side, which can reduce the operation and maintenance cost of the server side, can process local data in real time, reduce data delay, data does not need to be transmitted to the server, improve data security, at the same time, the terminal device can run independently, not dependent on the server, improve the robustness and reliability of the system.
[0050] Alternatively, in some feasible embodiments, the server 110 can also serve as the execution subject of the wafer defect classification method provided in the embodiments of the present application, that is, the server 110 can perform the training and application of the wafer defect classification model. For example, as shown in FIG. 1, the terminal device 120 can send the sample wafer image to the server 110, and the server 110 can perform the training and application of the wafer defect classification model based on the sample wafer image. Figure 1As shown, assuming that the wafer is located on the motion table 140, the server 110 can obtain the service data uploaded by the terminal device 120, where the service data can be a plurality of sample wafer images photographed by the image acquisition device 130, or can be a feature vector corresponding to a defect area in a wafer image of a wafer to be detected obtained through image processing such as image enhancement, image correction, image difference processing, and image feature vector construction, and the like. The specific determination can be made according to the actual application scenario, and is not limited herein. Assuming that the server 110 obtains the sample wafer image, the server 110 can obtain a training data set through image processing such as image enhancement, image correction, image difference processing, and image feature vector construction on the obtained sample wafer image. The specific determination can be made according to the actual application scenario and the type of service data, and is not limited herein. Further, the server 110 can train the wafer defect classification model based on the training set. When the server 110 obtains a wafer image of a wafer to be detected, the server 110 can perform image processing such as image enhancement, image correction, image difference processing, and image feature vector construction on the wafer image of the wafer to be detected to obtain a feature vector corresponding to a defect area in the wafer image of the wafer to be detected, and input the feature vector into the trained wafer defect classification model to output a defect category of the wafer to be detected through the wafer defect classification model. In the embodiment of the present application, the training and application of the wafer defect detection model can be completely deployed on the server side, the computing power and data management capability of the server can be utilized to improve the concentration of data management, the data of multiple terminals can be shared, and the continuous optimization and updating of the model can be facilitated.
[0051] Optionally, in some feasible embodiments, after the wafer defect classification model is trained, the server 110 can also deploy the wafer defect classification model to the terminal device 120, and subsequently perform defect recognition on the wafer to be detected by using the wafer defect classification model on the terminal device 120. In the embodiment of the present application, the wafer defect detection model training work can be deployed on the server, and the finally trained model can be deployed on the terminal device for application. This mode not only can improve the efficiency and accuracy of model training, but also can ensure the rapid response and efficient operation of the terminal device in actual production.
[0052] In summary, the method provided in the embodiment of the present application can be executed by the server 110 as shown in Figure 1 , can be executed by the terminal device 120 as shown in Figure 1 , and can also be executed by the terminal device and the server together. The specific determination can be made according to the actual application scenario, and is not limited herein.
[0053] The wafer defect classification method and the wafer defect classification device provided in the embodiment of the present application will be specifically described below. Figure 2 to Figure 5 The wafer defect classification method and the wafer defect classification device provided in the embodiment of the present application will be specifically described below.
[0054] Referring to Figure 2 , Figure 2 is a flowchart of a wafer defect classification method provided by an embodiment of the present application. For ease of understanding, the present embodiment takes a terminal device as the execution subject, i.e., takes the terminal device 120 in Figure 1 as an example for description. The present embodiment can be applied to various scenarios, including but not limited to cloud technology, artificial intelligence, etc. In the wafer defect classification method shown in Figure 2 , each step of wafer defect classification can be performed by the terminal device 120 in the above Figure 1 , as shown in Figure 2 , the method of wafer defect classification can at least include the following S201 to S205:
[0055] S201, obtaining a sample wafer grayscale image, and performing pixel difference processing on pixel points of the sample wafer grayscale image and a reference grayscale image to generate a difference image corresponding to the sample wafer grayscale image, wherein the difference image includes a plurality of candidate defect regions.
[0056] In some possible implementations, the sample wafer grayscale image can be stored in a list or a database or the like structure, and the terminal device can obtain a plurality of sample wafer grayscale images from the list or the database. Here, the list or the database can be located in the terminal device, and the terminal device directly reads the sample wafer grayscale image when needed. The list or the database can also be located on a server, and the terminal device can send a request to the server to trigger the server to return a plurality of sample wafer grayscale images. The specific application scenario can be determined, and no limitation is made herein.
[0057] In some possible implementation manners, the terminal device can be connected to the image acquisition device, and then the sample wafer is photographed in real time by the image acquisition device to obtain a sample wafer original image. It can be understood that, due to the influence of lens distortion such as radial distortion and tangential distortion, the wafer original image (including the sample wafer original image) obtained by scanning or photographing by the image acquisition device can be distorted, and the sample wafer original image needs to be processed to obtain a corrected sample wafer image. Here, the image processing can include but is not limited to image enhancement, morphological filtering, image correction, and the like, and the specific method can be determined according to the actual application scenario, which is not limited here. For example, image enhancement can enhance useful information in the original image by an algebraic or statistical method to improve the visual effect of the image; morphological filtering includes but is not limited to erosion and dilation, opening and closing operation, morphological gradient, top-hat and black-hat operation, and the like, to realize denoising and enhancement of useful information of the image; image correction is to correct the incorrect shape and perspective of the original image obtained by photographing or scanning by perspective transformation algorithm and linear interpolation technology. After obtaining the sample wafer image processed by the terminal device, the terminal device can further perform gray processing on the image to obtain a sample wafer gray image, and the specific gray processing method can be determined according to the actual application scenario, which is not limited here. In the embodiments of the present application, the sample wafer gray image can be obtained in different ways, which can be a sample wafer gray image obtained by real-time image acquisition of the sample wafer and gray processing of the sample wafer image, or historical data (including historical wafer gray images and defect categories) obtained by wafer defect identification of multiple wafers in wafer defect classification application. The sample wafer gray image can be obtained in different ways, so as to improve the data diversity of the sample wafer gray image, and provide rich data support for subsequent model training.
[0058] In some possible implementation manners, the terminal device performs pixel difference processing on the sample wafer grayscale image and the reference grayscale image, which can be performed by comparing pixel points at the same positions in the two images one by one, and then calculating the difference between the pixel points. It can be understood that the reference grayscale image can be a grayscale image without defects or defects within an acceptable range and can be ignored. The reference grayscale image can be understood as a standard grayscale image or an ideal grayscale image. Here, the sample wafer grayscale image and the reference grayscale image can be preprocessed, including but not limited to image registration, alignment, and the like, to ensure that they have the same size and format, and then the sample wafer grayscale image and the reference grayscale image are compared pixel by pixel to calculate the difference between each pixel point. For example, for each pair of corresponding pixel points, the difference between their grayscale values is calculated. If the grayscale values of the two pixel points are the same or similar, the difference is close to zero; if the grayscale values are quite different, the difference is also quite large. Further, the calculated difference can be used as a new pixel value to generate a difference image. In the difference image, the areas with large differences are displayed with obvious grayscale changes, and the areas without differences are close to the background color or zero value. It can be understood that, by performing pixel difference processing between the sample wafer grayscale image and the reference grayscale image, the normal wafer processing image that is not of interest can be cleaned up, and the image of the defect area can be retained and highlighted. That is, the difference image generated after the difference processing removes the normal processing area (i.e., the non-defect area) and retains multiple candidate defect areas (i.e., the defect area), so as to facilitate subsequent defect classification. In the embodiments of the present application, by performing pixel difference processing on the sample wafer grayscale image and the reference grayscale image, a difference image containing multiple candidate defect areas is generated, which can quickly locate the part of the sample wafer grayscale image that is inconsistent with the reference grayscale image, that is, the area with defects, and can provide candidate defect areas for subsequent analysis and processing, thereby improving the efficiency of subsequent analysis and processing. At the same time, by removing the non-defect area to eliminate the interference of the non-defect area on subsequent training, the accuracy of the sample data is improved, and the accuracy and accuracy of the model training are improved.
[0059] S202, clustering the pixel points in the difference image, and obtaining, from the multiple candidate defect areas, multiple defect areas corresponding to the sample wafer grayscale image according to the clustering results of the pixel points, wherein each of the defect areas includes a group of feature points for wafer defect classification, and each group of feature points includes multiple feature points.
[0060] In some possible implementation manners, the terminal device can perform clustering processing on the pixel points in the difference image obtained after the pixel difference processing is performed on the sample wafer grayscale image and the reference grayscale image. Here, the clustering processing can be K-Means algorithm clustering, can be clustering based on pixel values and coordinates, or can be other clustering methods based on pixel points. The specific clustering method can be determined according to an actual application scenario, and is not limited herein. For example, the K-Means clustering method based on pixel points is taken as an example for description. After the terminal device obtains the difference image, the terminal device can perform image preprocessing, such as filtering, denoising, or the like, on the difference image to improve the accuracy of clustering. The specific image preprocessing method can be determined according to an actual application scenario, and is not limited herein. Further, the gray value of a pixel can be taken as a feature, or the spatial position of the pixel, such as x and y coordinates, can be taken as a feature vector to implement feature extraction of the difference image. Further, the terminal device can determine the number N of clusters in the K-Means algorithm, that is, the number of expected defect regions. Here, the number N of clusters can be selected by using an elbow method or the like, or can be set according to historical clustering values or manually. The specific method for determining the number N of clusters can be determined according to an actual application scenario, and is not limited herein. Further, N pixel points are randomly initialized as initial cluster centers, and then clustering iteration is performed until the change of the cluster centers is less than a threshold or a preset iteration number is reached. The clustering process can be determined according to an actual application scenario, and is not described herein again. The terminal device can obtain N defect regions from the plurality of candidate defect regions of the difference image according to the clustering result. It can be understood that the number of defect regions is the number N of clusters.
[0061] In some possible implementation manners, before the terminal device performs clustering on the pixel points in the difference image, the terminal device can perform preprocessing on the difference image. Here, the preprocessing can include, but is not limited to, Gaussian filtering, smoothing processing, binarization processing, or the like. The difference image can be smoothed and the feature region is highlighted, that is, the defect region is highlighted. The specific preprocessing method can be determined according to an actual application scenario, and is not limited herein.
[0062] In some possible implementation manners, the terminal device can obtain the clustering result of the pixel points, can sort the multiple candidate defect regions according to the area of the multiple candidate defect regions from large to small according to the clustering result of the pixel points, and determine multiple defect regions with a large area from the multiple candidate defect regions based on the sorting result of the area. It can be understood that after the pixel points are clustered, a defect region with a larger area can generally correspond to a more significant or more serious defect, and a small area region can be caused by noise or a non-defect factor. By excluding these small area regions, the false positives caused by small area noise or pseudo defects can be reduced, the amount of data with interference can be reduced, the waste of resources on unimportant regions can be further reduced, the resources can be concentrated on more important defect regions for analysis, and thus the overall detection efficiency can be improved. In the embodiments of the present application, the candidate defect regions are sorted according to the area from large to small through the clustering result of the pixel points, and the N regions with a large area are selected as the defect regions, so that more significant defects can be focused on preferentially, and thus the detection pertinence and effectiveness can be improved, the errors caused by small area noise or pseudo defects can be reduced, the detection efficiency can be improved, the limited detection resources can be preferentially allocated to more prominent defects, and the overall detection accuracy and reliability can be further improved.
[0063] S203, based on a group of feature points included in each of the defect regions and the region statistical features of each of the defect regions, constructing multiple groups of feature vectors corresponding to the multiple defect regions one by one, wherein each group of the feature vectors includes multiple feature vectors, and the multiple feature vectors correspond to multiple feature points in a group of feature points included in the defect region one by one.
[0064] In some possible implementation manners, the terminal device can extract feature points from each defect region, where one defect region includes a group of feature points for wafer defect classification, and each group of feature points includes a plurality of feature points. Here, a feature point can be a point with unique properties in an image, and can be used to describe the local features of the image. That is, the feature points in each defect region can be used to describe the local features of each defect region. It can be understood that the feature points can be corner points, interest points, SIFT feature points, and the like extracted according to an algorithm, and the specific feature points can be determined according to an actual application scenario, which is not limited herein. The terminal device can construct a feature vector corresponding to each defect region based on the feature points included in each defect region and the region statistical features of each defect region. Here, the feature vector can be used to describe the comprehensive features of each defect region, and the feature vector can include, but is not limited to, feature point descriptors (such as SIFT descriptors), region statistical features (such as the aspect ratio, average gray value, area, and perimeter of the region, and the like), and texture features (such as texture features extracted by a gray level co-occurrence matrix), and the specific feature vector can be determined according to an actual application scenario, which is not limited herein. It can be understood that each feature point in one defect region can construct a feature vector in combination with the region statistical features of the defect region, and therefore, one defect region can construct a plurality of feature vectors, and the plurality of feature vectors corresponding to one defect region are in one-to-one correspondence with the plurality of feature points in the defect region. For example, it is assumed that the terminal device obtains three defect regions from a plurality of candidate defect regions according to the clustering result, for convenience of description, the three defect regions are referred to as defect region 1, defect region 2, and defect region 3, each defect region includes a group of feature points for wafer defect classification, and each group of feature points includes a plurality of feature points. For example, three feature points can be extracted from the defect region 1, four feature points can be extracted from the defect region 2, and five feature points can be extracted from the defect region 3, and the three feature points in the defect region 1 can construct three feature vectors in combination with the region statistical features of the region feature 1, and the four feature points in the defect region 2 can construct four feature vectors in combination with the region statistical features of the region feature 2, and the five feature points in the defect region 3 can construct five feature vectors in combination with the region statistical features of the region feature 2, and each feature vector in each region is in one-to-one correspondence with a feature point. It can be understood that each feature vector carries feature information of each defect region, and can be used for learning of a defect classification model.
[0065] In some possible implementation, the terminal device can extract feature points included in each of the above defect regions based on a scale-invariant feature transform (SIFT) algorithm. Here, the SIFT algorithm as a feature extraction algorithm can be used to detect feature points in an image, and the feature points extracted by the SIFT algorithm generally have scale invariance, rotation invariance, and robustness to light changes, and can stably identify key features under different conditions. Here, the feature points can generally include but are not limited to position information, scale information, direction information, and descriptors, which can be determined according to actual application scenarios and are not limited herein. Here, the position information of the feature points can indicate the position of the feature points in the defect region, the scale information can indicate the scale at which the feature points are detected, the direction information of the feature points can indicate the main direction of the feature points, and the descriptor of the feature points is generally a 128-dimensional vector, each dimension of which can represent the gradient direction information of the local region around the feature points. By extracting feature points and constructing feature vectors through the SIFT algorithm, the terminal device can efficiently extract features with robustness and distinguishability from the defect regions, and provide high-quality input data for the subsequent defect classification model. Further, the terminal device can calculate the region statistical features of each of the above defect regions, which can include but are not limited to one or more of statistical information such as aspect ratio, average gray value, area, and perimeter, and can be determined according to actual application scenarios and is not limited herein. The terminal device can construct a feature vector corresponding to each of the above defect regions based on the above feature points included in each of the above defect regions and the above region statistical features of each of the above defect regions. It can be understood that the feature points combined with the region statistical features of the defect regions can enrich the region feature information carried by the feature vectors, and provide high-quality input data for the subsequent defect classification model. Here, when the feature vectors are constructed based on the feature points and the region statistical features, the terminal device can directly add the dimensions of the feature points and the region statistical features. For example, if the feature points (such as SIFT descriptors) are 128-dimensional, and the region statistical features (such as color mean, standard deviation, etc.) are 10-dimensional, the feature vectors constructed based on the feature points and the region statistical features will be 138-dimensional. Optionally, since the numerical scales of different features can differ greatly (such as SIFT descriptors and color variance), the terminal device can normalize or standard deviation normalize the feature points and the region statistical features before constructing the feature vectors based on the feature points and the region statistical features, so as to avoid that some features dominate in subsequent calculations. The actual application scenarios can be determined and are not limited herein. Optionally, if the dimension of the feature vector is high, it can be necessary to use dimension reduction techniques or more complex fusion methods (such as multi-modal fusion based on neural networks) to improve the calculation efficiency and avoid overfitting. The actual application scenarios can be determined and are not limited herein.In the embodiments of the present application, the SIFT algorithm can extract stable and significant feature points on different scale spaces. These feature points have strong invariance to rotation, scale, brightness change and noise. The feature points combine with the regional statistical features to construct feature vectors. One feature point constructs one feature vector. One defect region corresponds to a group of feature vectors. The information of the feature vectors is further enriched, which can more comprehensively describe the characteristics of the defect region, improve the robustness and accuracy of feature extraction, enhance the recognition ability of the defect classification model to different types of defects, and further improve the overall defect classification performance of the model, and has strong applicability.
[0066] S204, training a defect classification model according to the plurality of groups of feature vectors corresponding to each of the defect regions and the defect category identifiers corresponding to the defect regions.
[0067] In some possible implementation manners, the terminal device can acquire a defect classification identifier corresponding to each of the above defect regions. Here, the defect classification identifier can be used to mark a defect category corresponding to each of the above defect regions. The defect category can include, but is not limited to, mechanical scratches, crystal defects, wafer surface attachments, and the like. The defect classification identifier can be a coded identifier, a numerical identifier, a character string identifier, a self-defined identifier, and the like. The specific implementation can be determined according to an actual application scenario, which is not limited herein. It can be understood that the defect classification identifier corresponding to each defect region of the above sample wafer is known, and can be acquired through local storage data, server data, user input data, an external storage device, and the like. The specific implementation can be determined according to an actual application scenario, which is not limited herein. Further, the terminal device can take the above feature vector corresponding to each of the above defect regions and the above defect classification identifier as an input of a defect classification model, and train the defect classification model by using a machine learning algorithm. The machine learning algorithm includes one of a logistic regression algorithm, a support vector machine (SVM) algorithm, a K-nearest neighbor algorithm, and a decision tree algorithm. For example, it is assumed that the defect categories include "mechanical scratches", "crystal defects", and "wafer surface attachments", and each defect region has a corresponding defect classification identifier. Here, "1" can be used as the defect classification identifier of "mechanical scratches", "2" can be used as the defect classification identifier of "crystal defects", and "3" can be used as the defect classification identifier of "wafer surface attachments". The terminal device can acquire the feature vector corresponding to each defect region and the defect classification identifier, construct a data set containing multiple defect regions, each sample includes a feature vector and a corresponding defect classification identifier, and take the data set as an input of a defect classification model. Further, the terminal device can select a machine learning algorithm to train the defect classification model. It is assumed that the terminal device selects the SVM algorithm, an SVM model can be initialized first, and a suitable kernel function (such as a linear kernel, a polynomial kernel, or a radial basis function kernel) is selected to process the relationship between the feature vectors. The terminal device inputs the feature vector and the corresponding defect classification identifier into the SVM model for training. The SVM finds an optimal hyperplane by optimizing an objective function, which can maximize the separation of data points of different categories. In the training process, the SVM adjusts the model parameters, such as a penalty parameter or a kernel function parameter, to achieve the best classification effect.
[0068] In some feasible implementations, the terminal device can evaluate the model performance after training the model to adjust the model parameters. A cross-validation method can be used to divide the training data set into multiple subsets, and one of the subsets is used as the validation set in turn, and the remaining subsets are used as the training set. In this way, the terminal device can train and verify the model multiple times to obtain a more reliable performance evaluation indicator, such as accuracy, recall rate and F1 score. Based on the above evaluation results, the parameters of the model can be optimized and adjusted, such as reducing the penalty parameter to reduce overfitting, etc. The specific method can be determined according to the actual application scenario and is not limited here. After model training and parameter optimization, the terminal device can save the trained defect classification model for subsequent use. Optionally, the terminal device can also save the trained defect classification model to a server or cloud, etc., to facilitate sharing the defect classification model with other devices. The specific method can be determined according to the actual application scenario and is not limited here. In the embodiments of the present application, through the selection of diversified machine learning algorithms, the most appropriate model training method can be selected for training according to the characteristics and complexity of the sample data, thereby improving the flexibility and adaptability of model training and enhancing the generalization ability of the model, so that the defect classification model can more accurately identify and classify different types of defects, improve the accuracy and reliability of classification, and has strong applicability.
[0069] For easier understanding, see Figure 3 , Figure 3 This is a data flow diagram of the defect classification model provided by the embodiment of the present application. Figure 3 As shown, the feature vectors and defect classification identifiers corresponding to the defect areas of the sample wafers can constitute training samples and be input into the defect classification model for model training. It can be understood that each training sample can be composed of a feature vector and a corresponding defect classification identifier. The feature vector can contain multiple feature points extracted from the defect area and regional statistical features corresponding to the defect area. The specific construction method of the feature vector can refer to the above embodiment and will not be elaborated here. The defect classification identifier can be in the form of an integer, a string, etc., which is used to represent the defect category of the defect area corresponding to the feature vector. The specific form can be determined according to the actual application scenario and is not limited here. The training samples can be stored in the form of data sets, files, lists, arrays, databases, etc., and input and used in the model training and model optimization links. The specific form can be determined according to the actual application scenario and is not limited here.
[0070] In the embodiments of the present application, by performing pixel difference processing and clustering analysis on the sample wafer gray-scale image and the reference image, the defect area can be effectively screened out, and the feature vector is constructed based on the feature points and the area statistical characteristics, and then the defect classification model is trained, which optimizes the processing of sample data, can quickly remove the interference of non-defect areas, can improve the sample data quality, and then improves the training efficiency and classification accuracy of the defect classification model, the model has strong robustness and strong applicability.
[0071] S205, when obtaining the wafer image of the wafer to be detected, obtaining the target feature vector group corresponding to the wafer image and inputting the target feature vector group into the defect classification model, and outputting the defect category of the wafer to be detected through the defect classification model.
[0072] In some feasible embodiments, the terminal device can obtain the wafer image of the wafer to be detected. Here, the terminal device can obtain the wafer image of the wafer to be detected by connecting to a real-time shooting device or a real-time scanning device, etc. The terminal device can also download the wafer image of the wafer to be detected from a server. It can be understood that the wafer image downloaded from the server can be a wafer image uploaded by other terminal devices or image acquisition devices connected to the server. The specific application scenario can be determined, which is not limited here. After obtaining the wafer image of the wafer to be detected, the terminal device can perform image gray processing, image enhancement, image correction, image difference processing, image feature vector construction and other image processing work on the wafer image of the wafer to be detected, to obtain the feature vector corresponding to the defect area in the obtained wafer image of the wafer to be detected. It can be understood that the feature vector corresponding to the defect area in the wafer image of the wafer to be detected carries the feature information of the defect area of the wafer to be detected. The terminal device can input the feature vector corresponding to the defect area in the wafer image of the wafer to be detected into the defect classification model, and then output the defect category of the wafer to be detected through the defect classification model. It can be understood that at this time, the feature vector corresponding to the defect area in the wafer image of the wafer to be detected will be input into the defect classification model, and the defect classification model will obtain the corresponding defect classification mark based on the input feature vector, and then obtain the defect category corresponding to the defect classification mark.
[0073] In some possible implementation manners, the target feature vector can be obtained in a manner similar to that of constructing the feature vector corresponding to each defective region in S201-S203. For example, the terminal device can perform grayscale processing on the obtained wafer image to obtain a target wafer grayscale image corresponding to the wafer image, and then perform pixel difference processing on the target wafer grayscale image and a reference grayscale image. The pixel difference between the same position pixels in the two images can be obtained by comparing the same position pixels in the two images one by one. It can be understood that the reference grayscale image can be a grayscale image without defects or with defects that can be ignored within an acceptable range, that is, the reference grayscale image can be understood as a standard grayscale image or an ideal grayscale image. Further, the terminal device can generate a target difference image based on the pixel difference processing result. It can be understood that the pixel difference processing between the target wafer grayscale image and the reference grayscale image can remove the normally processed regions (i.e., the non-defective regions) and retain the defective regions. Further, the terminal device can cluster the pixels in the target difference image to obtain a plurality of target defective regions corresponding to the target wafer grayscale image. Here, the number of clusters (i.e., the number of target defective regions) is related to the number of clusters according to the model training history and the number of defect classification identifiers in the model, and can be determined according to the actual application scenario, which is not limited herein. The terminal device can construct a feature vector based on the plurality of feature points for wafer defect classification included in each target defective region corresponding to the target wafer grayscale image and the region statistical features of each target defective region, to obtain a target feature vector corresponding to the wafer image. It can be understood that the target feature vector corresponding to each target defective region in the wafer image of the wafer to be detected carries the feature information of each target defective region in the wafer to be detected. The terminal device can input the target feature vector into the defect classification model to obtain the defect classification identifier corresponding to each target defective region, and then obtain the defect category corresponding to each target defective region. In the embodiments of the present application, the terminal device can perform image processing and feature extraction on the wafer image of the wafer to be detected to obtain the target feature vector of the wafer image, and can obtain more comprehensive feature information of the wafer to be detected to improve the accuracy and reliability of defect classification, and has strong applicability. For ease of understanding, please refer to Figure 3 As shown in Figure 3 , after obtaining the target feature vector corresponding to the wafer to be detected, the terminal device can input the target feature vector corresponding to the wafer to be detected into the defect classification model. It can be understood that the data format of the target feature vector corresponding to the wafer to be detected is consistent with that of the feature vector corresponding to the defective region of the sample wafer in the training sample. The defect classification model can output the target defect classification identifier based on the target feature vector, and then the defect category of the wafer to be detected can be obtained.
[0074] In general, the wafer defect classification method provided in the embodiments of the present application can obtain a sample wafer grayscale image, perform pixel difference processing on the sample wafer grayscale image and a reference grayscale image to generate a difference image corresponding to the sample wafer grayscale image, cluster the pixel points in the difference image, and obtain a plurality of defect regions corresponding to the sample wafer grayscale image from a plurality of candidate defect regions according to the clustering results of the pixel points. Then, a plurality of feature points for wafer defect classification can be obtained from each defect region, and a feature vector corresponding to each defect region can be constructed based on the feature points included in each defect region and the regional statistical features of each defect region. A defect classification model can be trained according to the feature vectors corresponding to each defect region and the defect category labels corresponding to the defect regions. When a wafer image of a wafer to be detected is obtained, a target feature vector corresponding to the wafer image can be obtained and input into the defect classification model, and the defect category of the wafer to be detected can be output by the defect classification model. The wafer defect classification method provided in the embodiments of the present application can effectively filter out defect regions through pixel difference processing and clustering analysis on the sample wafer grayscale image and the reference image, and construct a feature vector based on feature points and regional statistical features, and then train a defect classification model, thereby optimizing the processing of sample data, quickly removing the interference of non-defect regions, improving the sample data quality, and further improving the training efficiency and classification accuracy of the defect classification model. The model has strong robustness and strong applicability. Therefore, the wafer defect classification method provided in the embodiments of the present application can improve user experience and enhance the market competitiveness of products, and provides high-quality, large-scale and efficient data acquisition solutions for various enterprises.
[0075] Based on the description of the wafer defect classification method embodiments described above, the embodiments of the present application further disclose a wafer defect classification device. The wafer defect classification device can be applied to Figure 2 and Figure 3 The wafer defect classification method provided in the embodiments shown in the foregoing embodiments can be used to execute the steps in the wafer defect classification method. Here, the wafer defect classification device can be the service server or the terminal device in the embodiments shown in the foregoing Figure 2 and Figure 3 The wafer defect classification device can be the execution subject of the wafer defect classification method in the embodiments shown in the foregoing Figure 2 and Figure 3 . See Figure 4 , Figure 4 is a structural schematic diagram of the wafer defect classification device provided in the embodiments of the present application. In the embodiments of the present application, the device can run the following modules:
[0076] The image processing module 41 is configured to acquire a sample wafer grayscale image, and perform pixel difference processing on the sample wafer grayscale image and a reference grayscale image to generate a difference image corresponding to the sample wafer grayscale image, wherein the difference image includes a plurality of candidate defect regions.
[0077] The defect region acquisition module 42 is configured to cluster the pixels in the difference image, and obtain a plurality of defect regions corresponding to the sample wafer grayscale image from the plurality of candidate defect regions according to the clustering result of the pixels, wherein each defect region includes a group of feature points used for wafer defect classification, and each group of feature points includes a plurality of feature points.
[0078] The feature vector acquisition module 43 is configured to construct a plurality of groups of feature vectors corresponding to the plurality of defect regions based on the group of feature points included in each defect region and the region statistical features of each defect region, wherein each group of feature vectors includes a plurality of feature vectors, and the plurality of feature vectors correspond to the plurality of feature points in the group of feature points included in the defect region.
[0079] The model training module 44 is configured to train a defect classification model according to the plurality of groups of feature vectors corresponding to each defect region and the defect category labels corresponding to the defect regions.
[0080] The defect classification module 45 is configured to, when a wafer image of a wafer to be detected is obtained, acquire a target feature vector corresponding to the wafer image and input the target feature vector into the defect classification model, and output a defect category of the wafer to be detected by the defect classification model.
[0081] In some possible implementation manners, the defect region acquisition module 42 includes:
[0082] The clustering sub-module 421 is configured to cluster the pixels in the difference image to obtain the clustering result of the pixels.
[0083] The region determination sub-module 422 is configured to sort the plurality of candidate defect regions according to the region areas from large to small according to the clustering result of the pixels obtained by the clustering sub-module, and determine a plurality of defect regions with region areas in front of the sorting according to the sorting result of the region areas from the plurality of candidate defect regions.
[0084] In some possible implementation manners, the feature vector acquisition module 43 includes:
[0085] The feature point extraction sub-module 431 is configured to extract the group of feature points included in each defect region from each defect region based on a scale-invariant feature transform (SIFT) algorithm.
[0086] The statistical feature calculation submodule 432 is further configured to calculate a region statistical feature of each of the defect regions, where the region statistical feature includes one or more of an aspect ratio and an average gray value.
[0087] The vector construction submodule 433 is configured to construct a plurality of groups of feature vectors corresponding to the plurality of defect regions based on the group of feature points included in each of the defect regions and the region statistical feature of each of the defect regions.
[0088] In some possible implementation manners, the model training module 44 includes:
[0089] The identification acquisition submodule 441 is configured to acquire a defect classification identification corresponding to each of the defect regions, where the defect classification identification is used to mark a defect category corresponding to each of the defect regions.
[0090] The algorithm execution submodule 442 is configured to train a defect classification model by taking the plurality of groups of feature vectors corresponding to each of the defect regions and the defect classification identification as input of the defect classification model, and using a machine learning algorithm, where the machine learning algorithm includes one of a logistic regression algorithm, a support vector machine (SVM) algorithm, a K-nearest neighbor algorithm, and a decision tree algorithm.
[0091] In some possible implementation manners, the defect classification module 45 includes:
[0092] The difference image acquisition submodule 451 is configured to perform gray processing on a wafer image of a wafer to be detected to obtain a target wafer gray image corresponding to the wafer image when the wafer image is obtained, and generate a target difference image corresponding to the target wafer gray image based on the target wafer gray image and the reference gray image, where the target difference image includes a plurality of candidate target defect regions.
[0093] The region acquisition submodule 452 is configured to cluster pixel points in the target difference image, and obtain a plurality of target defect regions corresponding to the target wafer gray image from the plurality of candidate target defect regions according to a clustering result of the pixel points, where each of the target defect regions includes a group of feature points used for wafer defect classification, and each group of feature points includes a plurality of feature points.
[0094] The feature vector generation submodule 453 is configured to construct a plurality of groups of target feature vectors corresponding to the plurality of target defect regions based on a group of feature points included in each of the target defect regions and a region statistical feature of each of the defect regions, where each group of target feature vectors includes a plurality of feature vectors, and the plurality of feature vectors correspond to a plurality of feature points in the group of feature points included in the target defect region where the plurality of feature vectors are located, one by one.
[0095] The result generation submodule 454 is configured to input the target feature vector group into the defect classification model, and output a defect category of the wafer to be detected by the defect classification model.
[0096] In the embodiments of the present application, the above Figure 4 Each module in the device shown in the above
[0097] In some possible embodiments, the above Figure 2 and Figure 3 The implementation method provided by each step in the wafer defect classification method shown in the above Figure 4 The implementation method provided by each module in the device shown in the above Figure 2 The steps S201, S202, S203, S204 and S205 in the wafer defect classification method shown in the above Figure 4 The implementation method provided by each module in the device shown in the above
[0098] In general, the wafer defect classification device provided by the embodiments of the present application is composed of at least an image processing module, a defect region acquisition module, a feature vector acquisition module, a model training module, and a defect classification module, and can further include functional submodules such as a clustering submodule, a region determination submodule, a feature point extraction submodule, a feature point extraction submodule, a vector construction submodule, an identification acquisition submodule, an algorithm execution submodule, a difference image acquisition submodule, a region acquisition submodule, a feature vector generation submodule, and a result generation submodule. The image processing module can quickly acquire a sample wafer grayscale image and generate a difference image to locate a candidate defect region. The defect region acquisition module can accurately filter a defect region by using clustering analysis and remove noise interference. The model training module can construct a feature vector based on feature points and region statistical features to train a defect classification model, thereby improving the recognition ability and recognition accuracy of the model. The defect classification module can be used to input the feature vector of a wafer image to be detected into the model to quickly and accurately output a defect category. The wafer defect classification device provided by the embodiments of the present application optimizes the defect classification process through modular design, improves the robustness and generalization ability of the model, improves the classification precision and accuracy of the model, and has high applicability. It can be seen that the wafer defect classification device provided by the embodiments of the present application can improve the user experience and enhance the market competitiveness of the product, and provides high-precision and high-reliability wafer defect classification solutions for various enterprises.
[0099] Referring to Figure 5 , Figure 5 is a structural schematic diagram of an electronic device provided by the embodiments of the present application. As Figure 5 indicated, the electronic device can be a terminal device in the embodiments corresponding to the above Figure 1 to Figure 3 . The electronic device 50 can include a processor 501 and a memory 505, and in addition, the electronic device 50 can further include a user interface 503, a network interface 504, and at least one communication bus 502. The communication bus 502 is used to realize the connection and communication between the components. The user interface 503 can include a display, a keyboard, and optionally the user interface 503 can further include a standard wired interface and a wireless interface. The network interface 504 can optionally include a standard wired interface and a wireless interface (such as a WI-FI interface). The memory 505 can be a high-speed RAM memory or a non-volatile memory such as at least one disk memory. The memory 505 can optionally be at least one storage device located away from the aforementioned processor 501. As Figure 5 indicated, the memory 505 as a computer readable storage medium can include an operating system, a network communication module, a user interface module, and a device control application program.
[0100] The network interface 504 in the electronic device 50 can also be connected to the above Figure 1 The server in the corresponding embodiment is connected to the network, and the optional user interface 503 may also include a display screen and a keyboard. Figure 5 In the electronic device 50 shown, the network interface 504 can provide network communication functions; the user interface 503 is mainly used to provide an input interface for developers; and the processor 501 can be used to call the device control application stored in the memory 505 to implement the above Figure 2 The wafer defect classification method in the corresponding embodiment.
[0101] It should be understood that the electronic device 50 described in the embodiment of the present application can execute the above Figure 2 and Figure 3 The description of the wafer defect classification method in the corresponding embodiment will not be repeated here. In addition, the description of the beneficial effects of adopting the same method will not be repeated here either.
[0102] The present invention also provides a computer-readable storage medium that stores a computer program. The computer program includes program instructions that are executed by a processor to implement Figure 2 and Figure 3 The wafer defect classification methods provided in each step can be found in the above Figure 2 and Figure 3 The implementation methods provided by each step will not be repeated here.
[0103] The computer-readable storage medium may be the wafer defect classification device provided in any of the aforementioned embodiments or the internal storage unit of the computer device, such as the hard disk or memory of the computer device. The computer-readable storage medium may also be an external storage device of the computer device, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the computer device. Furthermore, the computer-readable storage medium may also include both the internal storage unit of the computer device and an external storage device. The computer-readable storage medium is used to store the computer program and other programs and data required by the computer device. The computer-readable storage medium may also be used to temporarily store data that has been output or is to be output.
[0104] The term "comprising" in the description, claims and drawings of the embodiments of the present application and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, device, product or equipment comprising a series of steps or units is not limited to the listed steps or modules, but optionally also includes steps or modules that are not listed, or optionally also includes other step units inherent to these processes, methods, devices, products or equipment. Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented with electronic hardware, computer software or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in terms of function in the above description. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0105] The methods and related devices provided by the embodiments of the present application are described with reference to the method flow charts and / or structural diagrams provided by the embodiments of the present application. Specifically, each process and / or block in the method flow charts and / or structural diagrams, as well as the combination of processes and / or blocks in the flow charts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the steps in the process. Figure 1 Schematic diagram of one or more processes and / or structures Figure 1 These computer program instructions can also be stored in a computer-readable memory that can guide a computer or other programmable data processing device to work in a specific way, so that the instructions stored in the computer-readable memory produce a product including the instruction device, which implements the function specified in the process. Figure 1 Schematic diagram of one or more processes and / or structures Figure 1 These computer program instructions can also be loaded onto a computer or other programmable data processing device, so that a series of operation steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process in the process. Figure 1 The flow or flows and / or structures illustrate the steps of the functions specified in one block or multiple blocks.
[0106] The above descriptions are only the preferred embodiment of the application, of course, cannot be used to limit the scope of the application, thus the equivalent variations made by the claims of the application, still belongs to the scope of the application covered.
Claims
1. A wafer defect classification method, characterized in that: include: Acquire a sample wafer grayscale image, and perform pixel difference processing on the sample wafer grayscale image and a reference grayscale image to generate a difference image corresponding to the sample wafer grayscale image, wherein the difference image includes a plurality of candidate defect areas; Clustering the pixels in the difference image, and obtaining a plurality of defect regions corresponding to the sample wafer grayscale image from the plurality of candidate defect regions based on the clustering results of the pixels, wherein each of the defect regions includes a group of feature points for wafer defect classification, and each group of feature points includes a plurality of feature points; constructing a plurality of groups of feature vectors corresponding one-to-one to the plurality of defect regions based on a set of feature points included in each of the defect regions and regional statistical features of each of the defect regions, wherein each group of feature vectors includes a plurality of feature vectors, and the plurality of feature vectors correspond one-to-one to a plurality of feature points in a set of feature points included in the defect region where the plurality of feature vectors are located; Training a defect classification model based on the multiple groups of feature vectors corresponding to the defect areas and the defect category identifiers corresponding to the defect areas; When a wafer image of a wafer to be inspected is obtained, a target feature vector group corresponding to the wafer image is obtained and the target feature vector group is input into the defect classification model, and the defect category of the wafer to be inspected is output through the defect classification model.
2. The method according to claim 1, characterized in that The obtaining, from the plurality of candidate defect regions according to the clustering result of the pixel points, a plurality of defect regions corresponding to the sample wafer grayscale image comprises: The plurality of candidate defect regions are sorted from largest to smallest in terms of area according to the clustering result of the pixel points, and a plurality of defect regions ranked first in terms of area are determined from the plurality of candidate defect regions based on the sorting result of the area.
3. The method according to claim 2, characterized in that The constructing a plurality of groups of feature vectors corresponding to the plurality of defect regions one-to-one based on a group of feature points included in each of the defect regions and the regional statistical features of each of the defect regions comprises: Extracting a set of feature points included in each defect area from each defect area based on a scale-invariant feature transform (SIFT) algorithm; Calculating regional statistical features of each of the defective regions, wherein the regional statistical features include one or more of aspect ratio and average grayscale value; Based on the set of feature points included in each of the defect regions and the regional statistical features of each of the defect regions, a plurality of sets of feature vectors corresponding one-to-one to the plurality of defect regions are constructed.
4. The method according to claim 3, characterized in that The training of the defect classification model according to the multiple groups of feature vectors corresponding to the defect areas and the defect category identifiers corresponding to the defect areas includes: Obtaining a defect classification identifier corresponding to each defect area, wherein the defect classification identifier is used to mark the defect category corresponding to each defect area; The multiple groups of feature vectors and the defect classification identifiers corresponding to the respective defect areas are used as inputs of a defect classification model, and the defect classification model is trained using a machine learning algorithm.
5. The method according to any one of claims 1 to 4, characterized in that The obtaining of a target feature vector group corresponding to the wafer image includes: performing grayscale processing on the wafer image to obtain a target wafer grayscale image corresponding to the wafer image, and generating a target difference image corresponding to the target wafer grayscale image based on the target wafer grayscale image and the reference grayscale image, wherein the target difference image includes a plurality of candidate target defect areas; Clustering the pixels in the target difference image, and obtaining a plurality of target defect regions corresponding to the target wafer grayscale image from the plurality of candidate target defect regions based on the clustering results of the pixels, wherein each target defect region includes a set of feature points for wafer defect classification, and each set of feature points includes a plurality of feature points; Based on a set of feature points included in each of the target defect areas and the regional statistical characteristics of each of the defect areas, multiple groups of target feature vectors corresponding one-to-one to the multiple target defect areas are constructed, wherein each group of target feature vectors includes multiple feature vectors, and the multiple feature vectors correspond one-to-one to multiple feature points in a set of feature points included in the target defect area where they are located.
6. A wafer defect classification device, characterized in that: include: An image processing module is used to obtain a sample wafer grayscale image and perform pixel difference processing on the sample wafer grayscale image and a reference grayscale image to generate a difference image corresponding to the sample wafer grayscale image, wherein the difference image includes a plurality of candidate defect areas; a defect region acquisition module, configured to cluster the pixels in the difference image and obtain, from the plurality of candidate defect regions, a plurality of defect regions corresponding to the sample wafer grayscale image based on the clustering results of the pixels, wherein each of the defect regions includes a set of feature points for wafer defect classification, and each set of feature points includes a plurality of feature points; a feature vector acquisition module, configured to construct a plurality of groups of feature vectors corresponding one-to-one to the plurality of defect regions based on a set of feature points included in each of the defect regions and regional statistical features of each of the defect regions, wherein each group of feature vectors includes a plurality of feature vectors, and the plurality of feature vectors correspond one-to-one to a plurality of feature points in a set of feature points included in the defect region where the plurality of feature vectors are located; A model training module, configured to train a defect classification model based on the multiple groups of feature vectors corresponding to the defect areas and the defect category identifiers corresponding to the defect areas; The defect classification module is used to obtain a target feature vector group corresponding to the wafer image when a wafer image of the wafer to be inspected is obtained and input the target feature vector group into the defect classification model, and output the defect category of the wafer to be inspected through the defect classification model.
7. The wafer defect classification device according to claim 6, wherein: The defect area acquisition module includes: A clustering submodule, configured to cluster the pixels in the difference image to obtain a clustering result of the pixels; The region determination submodule is used to sort the multiple candidate defect regions from large to small according to the clustering results of the pixel points obtained by the clustering submodule, and determine multiple defect regions with the highest area ranking from the multiple candidate defect regions based on the sorting results of the area.
8. The wafer defect classification device according to claim 7, wherein: The feature vector acquisition module includes: A feature point extraction submodule, configured to extract a set of feature points included in each defect area from each defect area based on a scale-invariant feature transform (SIFT) algorithm; The statistical feature calculation submodule is further configured to calculate regional statistical features of each defect region, wherein the regional statistical features include one or more of aspect ratio and average grayscale value; The vector construction submodule is further configured to construct a plurality of groups of feature vectors corresponding to the plurality of defect regions on a one-to-one basis based on the group of feature points included in each defect region and the regional statistical features of each defect region.
9. The wafer defect classification device according to claim 8, wherein: The model training module includes: an identification acquisition submodule, configured to acquire a defect classification identification corresponding to each of the defect areas, wherein the defect classification identification is used to mark the defect category corresponding to each of the defect areas; The algorithm execution submodule is used to use the multiple groups of feature vectors and the defect classification identifiers corresponding to each defect area as inputs of a defect classification model, and train the defect classification model using a machine learning algorithm.
10. The wafer defect classification device according to any one of claims 6 to 9, characterized in that: The defect classification module includes: a difference image acquisition submodule for, when obtaining a wafer image of a wafer to be inspected, performing grayscale processing on the wafer image to obtain a target wafer grayscale image corresponding to the wafer image, and generating a target difference image corresponding to the target wafer grayscale image based on the target wafer grayscale image and the reference grayscale image, wherein the target difference image includes a plurality of candidate target defect areas; a region acquisition submodule, configured to cluster the pixels in the target difference image, and obtain a plurality of target defect regions corresponding to the target wafer grayscale image from the plurality of candidate target defect regions based on the clustering results of the pixels, wherein each target defect region includes a set of feature points for wafer defect classification, and each set of feature points includes a plurality of feature points; a feature vector generation submodule, configured to construct, based on a set of feature points included in each of the target defect regions and regional statistical features of each of the defect regions, a plurality of groups of target feature vectors corresponding one-to-one to the plurality of target defect regions, wherein each group of target feature vectors includes a plurality of feature vectors, and the plurality of feature vectors correspond one-to-one to a plurality of feature points in a set of feature points included in the target defect region where the plurality of feature vectors are located; The result generation submodule is used to input the target feature vector group into the defect classification model, and output the defect category of the wafer to be inspected through the defect classification model.
11. An electronic device, characterized in that: The electronic device includes: a processor and a memory; The memory is used to store program codes, and the processor is used to call the program codes stored in the memory and execute the method according to any one of claims 1 to 5.
12. A computer storage medium, characterized in that The storage medium stores at least one instruction, and the at least one instruction is configured to be executed by a processor to implement the method according to any one of claims 1 to 5.
13. A computer program product, characterized in that When the computer program product is run on an electronic device, the electronic device is enabled to perform the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Integrated circuit defect image recognition and classification system based on fusion deep learning model
CN110766660A
Defect image labeling method and device, computer equipment and storage medium
CN117237280A