Defect detection method and related device
The coordinate conversion neural network model converts the first position coordinate of the defect on the wafer into the second position coordinate, which solves the problem that the defect cannot be quickly obtained relative to the bearing device coordinates in the prior art, and improves the efficiency and accuracy of defect processing.
Patent Information
- Application Number
- CN202311281629.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-28
- Publication Date
- 2025-04-04
- Estimated Expiration
- 2043-09-28
AI Technical Summary
The prior art cannot quickly obtain the position coordinates of defects on the wafer relative to the second reference coordinate system of the carrier device, resulting in inefficient defect processing.
By designing a coordinate conversion neural network model, the position coordinates of the defect relative to the first reference coordinate system are converted into position coordinates relative to the second reference coordinate system, and the second position coordinates of the defect are quickly obtained.
The convenience and efficiency of obtaining the second position coordinates of the defect relative to the bearing device are improved, and the speed and accuracy of defect processing are improved.
Smart Images

Figure CN119757348A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a defect detection method and related devices. Background Art
[0002] As a wafer defect detection device, the detection device can first detect the wafer surface, the computer can process the detected image and extract the defects, and then store the processed image data in the computer. The above process has been realized in the wafer detection instrument. In other words, the detection image of the wafer defect can be quickly displayed in the computer, and the distribution of defects on the wafer can be intuitively understood based on the detection image.
[0003] However, because the coordinates of each position on the wafer are generally composed of two coordinates, one is the coordinate of the target position on the wafer relative to the first reference coordinate system on the wafer, and the other is the coordinate of the wafer relative to the second reference coordinate system on the carrier (the carrier is generally used to carry wafers, such as a flat plate or panel, etc.), in order to process defects on the wafer, it is currently necessary to first obtain the position coordinates of the defects relative to the second reference coordinate system, and then process the defects on the wafer according to the position coordinates of the defects relative to the second reference coordinate system.
[0004] However, currently only the position coordinates of the defect relative to the first reference coordinate system are known, but the position coordinates of the defect relative to the second reference coordinate system cannot be obtained. Summary of the invention
[0005] An embodiment of the present invention provides a defect detection method and a related device for quickly acquiring a position coordinate of a defect relative to a second reference coordinate system based on a first position coordinate of the defect relative to a first reference coordinate system.
[0006] A first aspect of an embodiment of the present application provides a defect detection method, comprising:
[0007] Acquire first position coordinates of a defect in the inspection object relative to a first reference coordinate system, wherein the first reference coordinate system is set in the inspection object;
[0008] Inputting the first position coordinates of the defect into a coordinate conversion neural network model to obtain the second position coordinates of the defect relative to a second reference coordinate system output by the coordinate conversion neural network model, wherein the second reference coordinate system is set in a carrying device of the inspection object, and the coordinate conversion neural network model is used to realize the conversion from the first position coordinates to the second position coordinates;
[0009] The defect is detected according to the second position coordinates of the defect.
[0010] Preferably, the step of obtaining first position coordinates of a defect in the inspection object relative to a first reference coordinate system includes:
[0011] Acquire a plurality of first position coordinates of a plurality of defects in the inspection object respectively relative to the first reference coordinate system;
[0012] Inputting the first position coordinates of the defect into the coordinate transformation neural network model to obtain the second position coordinates of the defect relative to the second reference coordinate system output by the coordinate transformation neural network model, including:
[0013] The multiple first position coordinates of the multiple defects are respectively input into the coordinate transformation neural network model by using multi-threading to obtain the multiple second position coordinates of the multiple defects output by the coordinate transformation neural network model relative to the second reference coordinate system.
[0014] Preferably, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer;
[0015] The plurality of first position coordinates of the plurality of defects are respectively input into the coordinate transformation neural network model by using multithreading to obtain a plurality of second position coordinates of the plurality of defects output by the coordinate transformation neural network model relative to the second reference coordinate system, including:
[0016] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0017] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0018] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0019] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0020] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of second position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution model.
[0021] Preferably, before inputting the first position coordinates of the defect into the coordinate transformation neural network model, the method further comprises:
[0022] Acquire a training sample, wherein the training sample includes: a plurality of first position coordinates of a plurality of defects in a plurality of inspection objects respectively relative to the first reference coordinate system, and a plurality of second position coordinates of the plurality of defects respectively relative to the second reference coordinate system, wherein the first position coordinate of each defect corresponds to the second position coordinate one by one;
[0023] Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model;
[0024] Calculating the loss between the third position coordinates of the plurality of defects and the plurality of second position coordinates according to a preset loss function;
[0025] The coordinate transformation neural network model is trained using the loss and back propagation algorithm until the loss meets the target loss.
[0026] Preferably, before inputting the plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model, the method further comprises:
[0027] The training samples are subjected to data cleaning, wherein the data cleaning at least includes: at least one of deleting duplicate values, deleting outliers, and filling missing values.
[0028] Preferably, the using the loss and back propagation algorithm to train the coordinate transformation neural network model includes:
[0029] When the model parameters of the coordinate transformation neural network model are updated using the loss and back propagation algorithm, the learning rate of the parameter update is optimized using the Adamw optimizer.
[0030] Preferably, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer;
[0031] Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model, comprising:
[0032] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0033] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0034] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0035] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0036] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of third position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution module.
[0037] A second aspect of an embodiment of the present application provides a defect detection device, including:
[0038] an acquisition unit, configured to acquire first position coordinates of a defect in the inspection object relative to a first reference coordinate system, wherein the first reference coordinate system is set in the inspection object;
[0039] An input-output unit, used to input the first position coordinates of the defect into the coordinate transformation neural network model to obtain the second position coordinates of the defect relative to a second reference coordinate system output by the coordinate transformation neural network model, wherein the second reference coordinate system is set in a carrying device of the inspection object;
[0040] The detection unit is used to detect the defect according to the second position coordinates of the defect.
[0041] Preferably, the acquisition unit is specifically used for:
[0042] Acquire a plurality of first position coordinates of a plurality of defects in the inspection object respectively relative to the first reference coordinate system;
[0043] Preferably, the input-output unit is specifically used for:
[0044] The multiple first position coordinates of the multiple defects are respectively input into the coordinate transformation neural network model by using multi-threading to obtain the multiple second position coordinates of the multiple defects output by the coordinate transformation neural network model relative to the second reference coordinate system.
[0045] Preferably, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer;
[0046] Input and output unit, specifically used for:
[0047] The plurality of first position coordinates of the plurality of defects are respectively input into the coordinate transformation neural network model by using multithreading to obtain a plurality of second position coordinates of the plurality of defects output by the coordinate transformation neural network model relative to the second reference coordinate system, including:
[0048] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0049] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0050] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0051] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0052] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of second position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution model.
[0053] Preferably, the acquisition unit is further used for:
[0054] Acquire a training sample, wherein the training sample includes: a plurality of first position coordinates of a plurality of defects in a plurality of inspection objects respectively relative to the first reference coordinate system, and a plurality of second position coordinates of the plurality of defects respectively relative to the second reference coordinate system, wherein the first position coordinate of each defect corresponds to the second position coordinate one by one;
[0055] Input-output unit, also used for:
[0056] Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model;
[0057] The device also includes:
[0058] A calculation unit, configured to calculate the loss between the third position coordinates of the plurality of defects and the plurality of second position coordinates according to a preset loss function;
[0059] A training unit is used to train the coordinate transformation neural network model using the loss and a back propagation algorithm until the loss meets the target loss.
[0060] The device also includes:
[0061] A cleaning unit is used to perform data cleaning on the training samples, wherein the data cleaning at least includes: deleting at least one of duplicate values, deleting abnormal values and filling missing values.
[0062] The training unit is further used for:
[0063] When the model parameters of the coordinate transformation neural network model are updated using the loss and back propagation algorithm, the learning rate of the parameter update is optimized using the Adamw optimizer.
[0064] Preferably, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer;
[0065] Input and output unit, specifically used for:
[0066] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0067] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0068] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0069] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0070] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of third position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution module.
[0071] A third aspect of an embodiment of the present application provides a computer device, including a processor, which is used to implement the defect detection method provided in the first aspect of the embodiment of the present application when executing a computer program stored in a memory.
[0072] A fourth aspect of an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the computer program is used to implement the defect detection method provided in the first aspect of the embodiment of the present application.
[0073] It can be seen from the above technical solutions that the embodiments of the present invention have the following advantages:
[0074] In an embodiment of the present application, a first position coordinate of a defect in a detection object relative to a first reference coordinate system is obtained, wherein the first reference coordinate system is set in the detection object; the first position coordinate of the defect is input into a coordinate transformation neural network model to obtain a second position coordinate of the defect relative to a second reference coordinate system output by the coordinate transformation neural network model, wherein the second reference coordinate system is set in a supporting device of the detection object, and the coordinate transformation neural network model is used to realize the conversion from the first position coordinate to the second position coordinate; according to the second position coordinate of the defect, the defect is detected.
[0075] Because the embodiment of the present application can input the first position coordinates of the defect in the detection object into the coordinate transformation neural network model to obtain the second position coordinates output by the coordinate transformation neural network model, wherein the second position coordinates are set in the supporting device of the detection object, thereby improving the convenience of obtaining the second position coordinates of the defect. BRIEF DESCRIPTION OF THE DRAWINGS
[0076] Figure 1 A schematic diagram of an embodiment of a defect detection method in an embodiment of the present application;
[0077] Figure 2 This is another schematic diagram of an embodiment of the defect detection method in the embodiment of the present application;
[0078] Figure 3 for Figure 1 A refinement of step 102 in the embodiment;
[0079] Figure 4 This is a schematic diagram of the structure of the coordinate transformation neural network model in the embodiment of the present application;
[0080] Figure 5 This is a schematic diagram of an embodiment of the coordinate transformation neural network model training process in the embodiment of the present application;
[0081] Figure 6 for Figure 5A refinement of step 502 in the embodiment;
[0082] Figure 7 It is a schematic diagram of an embodiment of a defect detection device in an embodiment of the present application. DETAILED DESCRIPTION
[0083] The embodiment of the present invention provides a defect detection method and related device for quickly acquiring the position coordinates of a defect relative to a second reference coordinate system.
[0084] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0085] The terms "first", "second", "third", "fourth", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0086] For ease of understanding, the defect detection method in the embodiment of the present application is described below. Figure 1 , an embodiment of the defect detection method in the embodiment of the present application includes:
[0087] 101. Obtain first position coordinates of a defect in a detection object relative to a first reference coordinate system, wherein the first reference coordinate system is set in the detection object;
[0088] Specifically, the inspection objects in the embodiments of the present application include but are not limited to wafers, glass masks or screens, etc. Generally, in the embodiments of the present application, a first reference coordinate system will be set on the inspection object itself, wherein the first reference coordinate system can be based on the lower left corner of the inspection object as the coordinate origin, or the center of the inspection object as the coordinate origin, etc. There is no restriction on the origin position of the first reference coordinate system, as long as the positioning of defects in the inspection object can be achieved.
[0089] In the present application, two position coordinates are generally set for the wafer, and the target position on the other wafer is relative to the second position coordinate of the wafer carrier. In order to process the defects in the wafer, it is generally necessary to first obtain the second position coordinate of the defects in the wafer relative to the carrier.
[0090] 102. Input the first position coordinates of the defect into a coordinate transformation neural network model to obtain the second position coordinates of the defect relative to a second reference coordinate system output by the coordinate transformation neural network model, wherein the second reference coordinate system is arranged in a supporting device of the inspection object, and the coordinate transformation neural network model is used to realize the conversion from the first position coordinates to the second position coordinates.
[0091] After obtaining the first position coordinates of the defect in the wafer, the embodiment of the present application further inputs the first position coordinates of the defect into the coordinate transformation neural network model to obtain the second position coordinates of the defect relative to the second reference coordinate system output by the coordinate transformation neural network model, wherein the coordinate transformation neural network model is used to realize the coordinate transformation from the first position coordinate to the second position coordinate, and the second reference coordinate system is arranged in the carrying device of the detection object, and the carrying device of the detection object is used to carry the detection object, such as a flat plate or panel, and there is no specific restriction on the appearance of the carrying device of the detection object.
[0092] 103. Detect the defect according to the second position coordinates of the defect.
[0093] After obtaining the second position coordinates of the defect in the inspection object, the defect can be further inspected based on the second position coordinates of the defect.
[0094] In an embodiment of the present application, the first position coordinates of a defect in the inspection object are input into a coordinate transformation neural network model to obtain a second position coordinate output by the coordinate transformation neural network model, wherein the second position coordinate is set in a supporting device of the inspection object, thereby improving the convenience of obtaining the second position coordinate of the defect.
[0095] based on Figure 1 In the embodiment described above, when the first position coordinates of the defect are input into the coordinate conversion neural network model to obtain the corresponding second position coordinates of the defect, the prior art generally inputs the first position coordinates of a single defect and then obtains a single second position coordinate output by the coordinate conversion neural network model. In order to improve the convenience of obtaining the second position coordinates of multiple defects relative to the carrier device, the present application can execute the following embodiments, please refer to Figure 2 Another embodiment of the defect detection method in the embodiment of the present application includes:
[0096] 201. Obtain a plurality of first position coordinates of a plurality of defects in the inspection object relative to the first reference coordinate system respectively;
[0097] In order to obtain multiple second position coordinates of multiple defects relative to the second reference coordinate system, it is first necessary to obtain multiple first position coordinates of multiple defects in the inspection object relative to the first reference coordinate system, wherein the multiple first position coordinates here can be position coordinates stored in advance locally or in a third party, or can be first position coordinates obtained in real time from the inspection object. There is no specific restriction on the method of obtaining multiple first position coordinates of multiple defects.
[0098] 202. Input the multiple first position coordinates of the multiple defects into the coordinate transformation neural network model respectively by using multi-threading, so as to obtain the multiple second position coordinates of the multiple defects output by the coordinate transformation neural network model respectively relative to the second reference coordinate system.
[0099] Different from the method of obtaining the second position coordinates of defects one by one, the embodiment of the present application uses multi-threading to input multiple first position coordinates of multiple defects into the coordinate transformation neural network model, thereby obtaining multiple second position coordinates output by the coordinate transformation neural network model, thereby improving the convenience of obtaining the second position coordinates of multiple defects.
[0100] 203. Detect multiple defects according to the multiple second position coordinates of the multiple defects.
[0101] After obtaining the second position coordinates of multiple defects, the defects can be detected separately according to the second position coordinates of each defect.
[0102] In an embodiment of the present application, multi-threading is used to input multiple first position coordinates of multiple defects into a coordinate transformation neural network model, thereby obtaining multiple second position coordinates output by the coordinate transformation neural network model, thereby improving the convenience of obtaining the second position coordinates of multiple defects.
[0103] based on Figure 1 The coordinate transformation neural network model in the embodiment of the present application includes a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer. Figure 1 For a detailed description of step 102 in Figure 3 , Figure 3 The detailed steps of step 102 are as follows:
[0104] 301. Inputting a plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0105] For ease of understanding, Figure 4 A structural schematic diagram of the coordinate transformation neural network model in the present application is given, wherein the convolution module is used to extract the coordinate features of multiple first position coordinates. Therefore, the embodiment of the present application can input multiple first position coordinates of multiple defects into the convolution module to extract the coordinate features of multiple first position coordinates.
[0106] 302. Input the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0107] In order to avoid coordinate features that are too small being ignored during the model conversion process, this community implementation example adds a batch normalization layer to the coordinate conversion neural network model, where the batch normalization layer normalizes the output of each layer to ensure that the coordinate features of the first position coordinates can all be taken into account, where the normalization method is to subtract the average value of the output data of the previous layer from the output data of the previous layer and divide it by the standard deviation of the output data of the previous layer.
[0108] 303. Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0109] Some of the coordinate features of the normalized multiple first position coordinates are useless features, while some are features that need to be emphasized. If these useless features are added to the coordinate transformation neural network model, the computing power of the coordinate transformation neural network model will increase, thereby affecting the output efficiency of the coordinate transformation neural network model.
[0110] Therefore, the embodiment of the present application inputs the normalized coordinate features of the multiple first position coordinates into a long short-term memory network (LSTM) to ignore the first part of the features of the coordinate features of the multiple first position coordinates (such as useless features) and emphasize the second part of the features of the multiple first position coordinates (such as useful features), thereby improving the output efficiency of the coordinate transformation neural network model.
[0111] 304. Input the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the multiple first position coordinates;
[0112] Because each node of the fully connected layer is connected to all the nodes of the previous layer to integrate the features extracted previously, the embodiment of the present application can input the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the multiple first position coordinates.
[0113] 305. Input the coordinate features of the fitted multiple first position coordinates into the shape changing layer to obtain a preset number of second position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution model.
[0114] The coordinate transformation neural network model includes multiple different network layers, so the number of coordinate features of the multiple first position coordinates after fitting may not be equal to the number of the multiple first position coordinates input in advance. Therefore, in the embodiment of the present application, a shape changing layer is set after the long short-term memory network layer, and the coordinate features of the multiple first position coordinates after fitting are input into the shape changing layer to obtain a preset number of second position coordinates, wherein the preset number of second position coordinates is equal to the number of first position coordinates input into the convolution module.
[0115] The coordinate transformation neural network model in the embodiment of the present application includes a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a reshape layer, wherein the batch normalization layer can avoid ignoring smaller coordinate features in the coordinate features of the first position coordinates, and ensure that all coordinate features of the first position coordinates can be taken into account, thereby improving the accuracy of the second position coordinates output by the coordinate transformation neural network model.
[0116] Furthermore, the long short-term memory network in the embodiment of the present application can also ignore useless features in the coordinate features of the first position coordinates, and emphasize useful features in the coordinate features of the first position coordinates, thereby further improving the accuracy of the coordinate transformation neural network model outputting the second position coordinates.
[0117] Further, based on Figures 1 to 3 In the embodiment described above, before the first position coordinates of the defect are input into the coordinate transformation neural network model, the coordinate transformation neural network model needs to be trained. The following describes the training process of the coordinate transformation neural network model. Figure 5 , an embodiment of the training process of the coordinate transformation neural network model in the embodiment of the present application includes:
[0118] 501. Acquire a training sample, wherein the training sample includes: a plurality of first position coordinates of a plurality of defects in a plurality of inspection objects respectively relative to the first reference coordinate system, and a plurality of second position coordinates of the plurality of defects respectively relative to the second reference coordinate system, wherein the first position coordinate of each defect corresponds to the second position coordinate one by one;
[0119] It is easy to understand that before training the coordinate transformation neural network model, it is necessary to first obtain training samples, wherein the training samples include: multiple first position coordinates of multiple defects in multiple inspection objects relative to the first reference coordinate system, and multiple second position coordinates of multiple defects relative to the second reference coordinate system, wherein the first position coordinates and the second position coordinates of each defect correspond one to one, wherein the second position coordinate of each defect serves as a label of the first position coordinate for subsequent calculation of the loss.
[0120] In order to use the training samples to train the coordinate transformation neural network model, in actual situations, the training sample data may contain errors due to various accidents, such as omissions, unreasonable values or incorrect values. Therefore, before using the training samples to train the coordinate transformation neural network model, this application also needs to clean the data in the training samples to eliminate inaccurate, incomplete or irrelevant information.
[0121] Specifically, in deep learning, the purpose of data cleaning is to improve the quality of data, reduce the noise and bias of model training, and improve the performance and accuracy of the model. The data cleaning in this application at least includes: deleting at least one of duplicate values, deleting outliers, and filling missing values.
[0122] When filling missing values, the embodiment of the present application fills the missing values by interpolation, thereby improving the accuracy of the filled values.
[0123] 502. Input a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model;
[0124] After obtaining the first position coordinates and second position coordinates (as labels of the first position coordinates) of multiple defects, the first position coordinates of each defect are input into the coordinate transformation neural network model to obtain the corresponding third position coordinates output by the coordinate transformation neural network model.
[0125] As for the process of inputting the first position coordinates into the coordinate transformation neural network model to obtain the third position coordinates output by the coordinate transformation neural network model, it will be described in the following embodiments and will not be repeated here.
[0126] 503. Calculate the loss between the third position coordinates of the plurality of defects and the plurality of second position coordinates according to a preset loss function;
[0127] Furthermore, in the embodiment of the present application, the loss between the third position coordinates and the second position coordinates of each defect in the multiple defects is calculated according to a preset loss function, wherein the preset loss function includes: L1 loss function, L2 loss function and cross entropy loss function, etc., and no specific restrictions are made here.
[0128] 504. Train the coordinate transformation neural network model using the loss and back propagation algorithm until the loss meets the target loss.
[0129] After obtaining the loss between the second position coordinate and the third position coordinate of each defect, the coordinate transformation neural network model is further trained using the loss and the back propagation algorithm until the loss meets the target loss.
[0130] Furthermore, in the embodiments of the present application, when the model parameters of the coordinate transformation neural network model are updated using the loss and back-propagation algorithms, in order to ensure the speed of gradient convergence, the present application uses the Adamw optimizer to optimize the learning rate of parameter updates to ensure gradient convergence. The Adamw optimizer, as an optimization algorithm for adaptive learning rate, can automatically adjust the learning rates of different parameters to better adapt to changes in gradients of different parameters. The training speed is relatively faster, and it can also better handle sparse gradients. In addition, the Adamw optimizer performs L2 regularization on larger weight updates, which can further improve the training effect of the model.
[0131] The structure of the Adamw optimizer itself is consistent with that described in the prior art and will not be described in detail here.
[0132] based on Figure 5 The training process of the coordinate transformation neural network model, wherein the coordinate transformation neural network model includes a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer, step 502 is described in detail below, please refer to Figure 6 , Figure 6 The detailed steps of step 502 are as follows:
[0133] 601. Input a plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0134] 602. Input the coordinate features of the plurality of first position coordinates to the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0135] 603. Input the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0136] 604. Input the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the multiple first position coordinates;
[0137] 605. Input the fitted coordinate features of the plurality of first position coordinates into the shape changing layer to obtain a preset number of third position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution module.
[0138] It should be noted that the description of step 601 to step 605 is the same as Figure 3 The description in the embodiment is similar and will not be repeated here.
[0139] Because the coordinate transformation neural network model in the embodiment of the present application includes a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a reshape layer, and the batch normalization layer can avoid the smaller coordinate features in the coordinate features of the first position coordinates from being ignored, and ensure that all the coordinate features of the first position coordinates can be taken into account, thereby improving the accuracy of the second position coordinates output by the coordinate transformation neural network model.
[0140] Furthermore, the long short-term memory network in the embodiment of the present application can also ignore useless features in the coordinate features of the first position coordinates, and emphasize useful features in the coordinate features of the first position coordinates, thereby further improving the accuracy of the coordinate transformation neural network model outputting the second position coordinates.
[0141] The above describes the defect detection method in the implementation of the present application in detail. The following describes the defect detection device in the embodiment of the present application. Figure 7 , an embodiment of the defect detection device in the embodiment of the present application includes:
[0142] An acquisition unit 701 is used to acquire first position coordinates of a defect in a detection object relative to a first reference coordinate system, wherein the first reference coordinate system is set in the detection object;
[0143] An input-output unit 702 is used to input the first position coordinates of the defect into the coordinate transformation neural network model to obtain the second position coordinates of the defect relative to a second reference coordinate system output by the coordinate transformation neural network model, wherein the second reference coordinate system is set in a carrying device of the inspection object;
[0144] The detection unit 703 is used to detect the defect according to the second position coordinates of the defect.
[0145] Preferably, the acquisition unit 701 is specifically used for:
[0146] Acquire a plurality of first position coordinates of a plurality of defects in the inspection object respectively relative to the first reference coordinate system;
[0147] Preferably, the input-output unit 702 is specifically used for:
[0148] The multiple first position coordinates of the multiple defects are respectively input into the coordinate transformation neural network model by using multi-threading to obtain the multiple second position coordinates of the multiple defects output by the coordinate transformation neural network model relative to the second reference coordinate system.
[0149] Preferably, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer;
[0150] The input and output unit 702 is specifically used for:
[0151] The plurality of first position coordinates of the plurality of defects are respectively input into the coordinate transformation neural network model by using multithreading to obtain a plurality of second position coordinates of the plurality of defects output by the coordinate transformation neural network model relative to the second reference coordinate system, including:
[0152] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0153] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0154] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0155] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0156] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of second position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution model.
[0157] Preferably, the acquisition unit 701 is further used for:
[0158] Acquire a training sample, wherein the training sample includes: a plurality of first position coordinates of a plurality of defects in a plurality of inspection objects respectively relative to the first reference coordinate system, and a plurality of second position coordinates of the plurality of defects respectively relative to the second reference coordinate system, wherein the first position coordinate of each defect corresponds to the second position coordinate one by one;
[0159] The input-output unit 702 is further used for:
[0160] Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model;
[0161] The device also includes:
[0162] A calculation unit 704, configured to calculate the loss between the third position coordinates of the plurality of defects and the plurality of second position coordinates according to a preset loss function;
[0163] The training unit 705 is used to train the coordinate transformation neural network model using the loss and the back propagation algorithm until the loss meets the target loss.
[0164] The device also includes:
[0165] The cleaning unit 706 is used to perform data cleaning on the training samples, wherein the data cleaning at least includes: deleting at least one of duplicate values, deleting abnormal values, and filling missing values.
[0166] The training unit 705 is further used for:
[0167] When the model parameters of the coordinate transformation neural network model are updated using the loss and back propagation algorithm, the learning rate of the parameter update is optimized using the Adamw optimizer.
[0168] Preferably, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer;
[0169] The input and output unit 702 is specifically used for:
[0170] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0171] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0172] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0173] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0174] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of third position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution module.
[0175] It should be noted that the functions of the above units are Figures 1 to 6 The description in the embodiment is similar and will not be repeated here.
[0176] In an embodiment of the present application, the first position coordinates of the defect in the inspection object are input into the coordinate transformation neural network model through the input-output unit 702 to obtain the second position coordinates output by the coordinate transformation neural network model, wherein the second position coordinates are set in the supporting device of the inspection object, thereby improving the convenience of obtaining the second position coordinates of the defect.
[0177] The defect detection device in the embodiment of the present invention is described above from the perspective of modular functional entities. The computer device in the embodiment of the present invention is described below from the perspective of hardware processing:
[0178] The computer device is used to implement the functions of the defect detection device. In an embodiment of the present invention, an embodiment of the computer device includes:
[0179] Processor and memory;
[0180] The memory is used to store a computer program, and when the processor is used to execute the computer program stored in the memory, the following steps can be implemented:
[0181] Acquire first position coordinates of a defect in the inspection object relative to a first reference coordinate system, wherein the first reference coordinate system is set in the inspection object;
[0182] Inputting the first position coordinates of the defect into a coordinate conversion neural network model to obtain the second position coordinates of the defect relative to a second reference coordinate system output by the coordinate conversion neural network model, wherein the second reference coordinate system is set in a carrying device of the inspection object, and the coordinate conversion neural network model is used to realize the conversion from the first position coordinates to the second position coordinates;
[0183] The defect is detected according to the second position coordinates of the defect.
[0184] In some embodiments of the present invention, the processor may also be used to implement the following steps:
[0185] Acquire a plurality of first position coordinates of a plurality of defects in the inspection object respectively relative to the first reference coordinate system;
[0186] Inputting the first position coordinates of the defect into the coordinate transformation neural network model to obtain the second position coordinates of the defect relative to the second reference coordinate system output by the coordinate transformation neural network model, including:
[0187] The multiple first position coordinates of the multiple defects are respectively input into the coordinate transformation neural network model by using multi-threading to obtain the multiple second position coordinates of the multiple defects output by the coordinate transformation neural network model relative to the second reference coordinate system.
[0188] In some embodiments of the present invention, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer; the processor can also be used to implement the following steps:
[0189] The plurality of first position coordinates of the plurality of defects are respectively input into the coordinate transformation neural network model by using multithreading to obtain a plurality of second position coordinates of the plurality of defects output by the coordinate transformation neural network model relative to the second reference coordinate system, including:
[0190] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0191] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0192] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0193] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0194] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of second position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution model.
[0195] In some embodiments of the present invention, before inputting the first position coordinates of the defect into the coordinate transformation neural network model, the processor may also be used to implement the following steps:
[0196] Acquire a training sample, wherein the training sample includes: a plurality of first position coordinates of a plurality of defects in a plurality of inspection objects respectively relative to the first reference coordinate system, and a plurality of second position coordinates of the plurality of defects respectively relative to the second reference coordinate system, wherein the first position coordinate of each defect corresponds to the second position coordinate one by one;
[0197] Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model;
[0198] Calculating the loss between the third position coordinates of the plurality of defects and the plurality of second position coordinates according to a preset loss function;
[0199] The coordinate transformation neural network model is trained using the loss and back propagation algorithm until the loss meets the target loss.
[0200] In some embodiments of the present invention, before inputting the plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model, the processor may also be used to implement the following steps:
[0201] The training samples are subjected to data cleaning, wherein the data cleaning at least includes: at least one of deleting duplicate values, deleting outliers, and filling missing values.
[0202] In some embodiments of the present invention, the processor may also be used to implement the following steps:
[0203] When the model parameters of the coordinate transformation neural network model are updated using the loss and back propagation algorithm, the learning rate of the parameter update is optimized using the Adamw optimizer.
[0204] In some embodiments of the present invention, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer, and the processor can also be used to implement the following steps:
[0205] Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model, comprising:
[0206] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0207] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0208] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0209] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0210] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of third position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution module.
[0211] It can be understood that when the processor in the computer device described above executes the computer program, it can also implement the functions of the various units in the corresponding device embodiments described above, which will not be repeated here. Exemplarily, the computer program can be divided into one or more modules / units, and the one or more modules / units are stored in the memory and executed by the processor to complete the present invention. The one or more modules / units can be a series of computer program instruction segments that can perform specific functions, and the instruction segments are used to describe the execution process of the computer program in the defect detection device. For example, the computer program can be divided into the various units in the above-mentioned defect detection device, and each unit can implement the specific functions described in the above-mentioned corresponding defect detection device.
[0212] The computer device may be a computing device such as a desktop computer, a notebook, a PDA, and a cloud server. The computer device may include, but is not limited to, a processor and a memory. Those skilled in the art will appreciate that a processor and a memory are merely examples of computer devices and do not constitute a limitation of the computer device. The computer device may include more or fewer components, or a combination of certain components, or different components. For example, the computer device may also include input and output devices, network access devices, buses, and the like.
[0213] The processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. The processor is the control center of the computer device, and various interfaces and lines are used to connect various parts of the entire computer device.
[0214] The memory can be used to store the computer program and / or module, and the processor realizes various functions of the computer device by running or executing the computer program and / or module stored in the memory, and calling the data stored in the memory. The memory can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, at least one application required for a function, etc.; the data storage area can store data created according to the use of the terminal, etc. In addition, the memory can include a high-speed random access memory, and can also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (SecureDigital, SD) card, a flash card (Flash Card), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0215] The present invention also provides a computer-readable storage medium, which is used to implement the functions of the defect detection device, and stores a computer program thereon. When the computer program is executed by a processor, the processor can be used to perform the following steps:
[0216] Acquire first position coordinates of a defect in the inspection object relative to a first reference coordinate system, wherein the first reference coordinate system is set in the inspection object;
[0217] Inputting the first position coordinates of the defect into a coordinate conversion neural network model to obtain the second position coordinates of the defect relative to a second reference coordinate system output by the coordinate conversion neural network model, wherein the second reference coordinate system is set in a carrying device of the inspection object, and the coordinate conversion neural network model is used to realize the conversion from the first position coordinates to the second position coordinates;
[0218] The defect is detected according to the second position coordinates of the defect.
[0219] In some embodiments of the present invention, when the computer program is executed by a processor, the processor may also be used to implement the following steps:
[0220] Acquire a plurality of first position coordinates of a plurality of defects in the inspection object respectively relative to the first reference coordinate system;
[0221] Inputting the first position coordinates of the defect into the coordinate transformation neural network model to obtain the second position coordinates of the defect relative to the second reference coordinate system output by the coordinate transformation neural network model, including:
[0222] The multiple first position coordinates of the multiple defects are respectively input into the coordinate transformation neural network model by using multi-threading to obtain the multiple second position coordinates of the multiple defects output by the coordinate transformation neural network model relative to the second reference coordinate system.
[0223] In some embodiments of the present invention, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer; when the computer program is executed by the processor, the processor can also be used to implement the following steps:
[0224] The plurality of first position coordinates of the plurality of defects are respectively input into the coordinate transformation neural network model by using multithreading to obtain a plurality of second position coordinates of the plurality of defects output by the coordinate transformation neural network model relative to the second reference coordinate system, including:
[0225] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0226] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0227] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0228] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0229] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of second position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution model.
[0230] In some embodiments of the present invention, before the first position coordinates of the defect are input into the coordinate transformation neural network model, when the computer program is executed by the processor, the processor may also be used to implement the following steps:
[0231] Acquire a training sample, wherein the training sample includes: a plurality of first position coordinates of a plurality of defects in a plurality of inspection objects respectively relative to the first reference coordinate system, and a plurality of second position coordinates of the plurality of defects respectively relative to the second reference coordinate system, wherein the first position coordinate of each defect corresponds to the second position coordinate one by one;
[0232] Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model;
[0233] Calculating the loss between the third position coordinates of the plurality of defects and the plurality of second position coordinates according to a preset loss function;
[0234] The coordinate transformation neural network model is trained using the loss and back propagation algorithm until the loss meets the target loss.
[0235] In some embodiments of the present invention, before inputting the plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model, when the computer program is executed by the processor, the processor may also be used to implement the following steps:
[0236] The training samples are subjected to data cleaning, wherein the data cleaning at least includes: at least one of deleting duplicate values, deleting outliers, and filling missing values.
[0237] In some embodiments of the present invention, when the computer program is executed by a processor, the processor may also be used to implement the following steps:
[0238] When the model parameters of the coordinate transformation neural network model are updated using the loss and back propagation algorithm, the learning rate of the parameter update is optimized using the Adamw optimizer.
[0239] In some embodiments of the present invention, the coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer. When the computer program is executed by the processor, the processor can also be used to implement the following steps:
[0240] Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model, comprising:
[0241] Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates;
[0242] Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates;
[0243] Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer;
[0244] Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates;
[0245] The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of third position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution module.
[0246] It is understandable that if the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a corresponding computer-readable storage medium. Based on such an understanding, the present invention implements all or part of the processes in the above-mentioned corresponding embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium. It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable media do not include electric carrier signals and telecommunication signals.
[0247] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0248] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0249] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0250] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0251] As described above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A defect detection method, characterized in that: include: Acquire first position coordinates of a defect in the inspection object relative to a first reference coordinate system, wherein the first reference coordinate system is set in the inspection object; Inputting the first position coordinates of the defect into a coordinate conversion neural network model to obtain the second position coordinates of the defect relative to a second reference coordinate system output by the coordinate conversion neural network model, wherein the second reference coordinate system is set in a carrying device of the inspection object, and the coordinate conversion neural network model is used to realize the conversion from the first position coordinates to the second position coordinates; The defect is detected according to the second position coordinates of the defect.
2. The method according to claim 1, characterized in that The step of obtaining first position coordinates of a defect in the inspection object relative to a first reference coordinate system includes: Acquire a plurality of first position coordinates of a plurality of defects in the inspection object respectively relative to the first reference coordinate system; Inputting the first position coordinates of the defect into the coordinate transformation neural network model to obtain the second position coordinates of the defect relative to the second reference coordinate system output by the coordinate transformation neural network model, including: The multiple first position coordinates of the multiple defects are respectively input into the coordinate transformation neural network model by using multi-threading to obtain the multiple second position coordinates of the multiple defects output by the coordinate transformation neural network model relative to the second reference coordinate system.
3. The method according to claim 2, characterized in that The coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer; The plurality of first position coordinates of the plurality of defects are respectively input into the coordinate transformation neural network model by using multithreading to obtain a plurality of second position coordinates of the plurality of defects output by the coordinate transformation neural network model relative to the second reference coordinate system, including: Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates; Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates; Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer; Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates; The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of second position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution model.
4. The method according to claim 1, characterized in that: Before inputting the first position coordinates of the defect into the coordinate transformation neural network model, the method further includes: Acquire a training sample, wherein the training sample includes: a plurality of first position coordinates of a plurality of defects in a plurality of inspection objects respectively relative to the first reference coordinate system, and a plurality of second position coordinates of the plurality of defects respectively relative to the second reference coordinate system, wherein the first position coordinate of each defect corresponds to the second position coordinate one by one; Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model; Calculating the loss between the third position coordinates of the plurality of defects and the plurality of second position coordinates according to a preset loss function; The coordinate transformation neural network model is trained using the loss and back propagation algorithm until the loss meets the target loss.
5. The method according to claim 4, characterized in that Before inputting the plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model, the method further comprises: The training samples are subjected to data cleaning, wherein the data cleaning at least includes: at least one of deleting duplicate values, deleting outliers, and filling missing values.
6. The method according to claim 4, characterized in that The method of training the coordinate transformation neural network model by using the loss and back propagation algorithm includes: When the model parameters of the coordinate transformation neural network model are updated using the loss and back propagation algorithm, the learning rate of the parameter update is optimized using the Adamw optimizer.
7. The method according to claim 4, characterized in that The coordinate transformation neural network model includes: a convolution module, a batch normalization layer, a long short-term memory network layer, a fully connected layer and a shape change layer; Inputting a plurality of first position coordinates of the plurality of defects into the coordinate transformation neural network model to obtain a plurality of corresponding third position coordinates output by the coordinate transformation neural network model, comprising: Inputting the plurality of first position coordinates of the plurality of defects into the convolution module to extract coordinate features of the plurality of first position coordinates; Inputting the coordinate features of the plurality of first position coordinates into the batch normalization layer to normalize the coordinate features of the plurality of first position coordinates; Inputting the normalized coordinate features of the plurality of first position coordinates into the long short-term memory network to ignore the first part of the features of the coordinate features of the plurality of first position coordinates and emphasize the second part of the features of the coordinate features of the plurality of first position coordinates, thereby obtaining the output of the long short-term memory network layer; Inputting the output of the long short-term memory network layer to the fully connected layer to fit the coordinate features of the plurality of first position coordinates; The coordinate features of the fitted multiple first position coordinates are input into the shape changing layer to obtain a preset number of third position coordinates, wherein the preset number is equal to the number of first position coordinates input into the convolution module.
8. A defect detection device, characterized in that: include: An acquisition unit, used for acquiring first position coordinates of a defect in the inspection object relative to a first reference coordinate system, wherein the first reference coordinate system is set in the inspection object; An input-output unit is used to input the first position coordinates of the defect into a coordinate transformation neural network model to obtain the second position coordinates of the defect relative to a second reference coordinate system output by the coordinate transformation neural network model, wherein the second reference coordinate system is arranged in a supporting device of the detection object.
9. A computer device comprising a processor, characterized in that: When the processor executes the computer program stored in the memory, the processor is used to implement the defect detection method according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, it is used to implement the defect detection method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Construction method of deep learning model and nonlinear coordinate conversion method
CN114387240A
Defect detection method and device, electronic equipment and storage medium
CN115187537A
Pole reversal defect detection method and detection device based on feature point matching algorithm
CN115713639A
Vehicle defect positioning system, method and device and storage medium
CN116148259A
Defect observation device
US20200335300A1