CN115984197A - Defect detection method based on standard PCB image and related device - Google Patents

Defect detection method based on standard PCB image and related device Download PDF

Info

Publication number
CN115984197A
CN115984197A CN202211625724.6A CN202211625724A CN115984197A CN 115984197 A CN115984197 A CN 115984197A CN 202211625724 A CN202211625724 A CN 202211625724A CN 115984197 A CN115984197 A CN 115984197A
Authority
CN
China
Prior art keywords
image
pcb
detected
standard
pcb image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211625724.6A
Other languages
Chinese (zh)
Inventor
蔡淳昊
易振彧
罗羊
潘阳山
王卓琛
刘枢
吕江波
沈小勇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Smartmore Technology Co Ltd
Original Assignee
Shenzhen Smartmore Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Smartmore Technology Co Ltd filed Critical Shenzhen Smartmore Technology Co Ltd
Priority to CN202211625724.6A priority Critical patent/CN115984197A/en
Publication of CN115984197A publication Critical patent/CN115984197A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/30Computing systems specially adapted for manufacturing

Abstract

The application discloses a defect detection method based on a standard PCB image and a related device, wherein the method comprises the following steps: acquiring a PCB image to be detected; determining a standard PCB image with the same size as the PCB design drawing; the size of the standard PCB image is larger than that of the PCB image to be detected, and the PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected; and carrying out image interception processing on the standard PCB image to obtain a target standard PCB image. The design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected; and comparing the PCB image to be detected with the target standard PCB image, and determining the position of the defect in the PCB image to be detected. According to the defect detection method based on the standard PCB image, the to-be-detected PCB image is compared with the target standard PCB image, so that defect identification is carried out on the to-be-detected PCB image. Therefore, defects can be effectively identified without learning, and the accuracy of PCB defect detection is improved.

Description

Defect detection method based on standard PCB image and related device
Technical Field
The application relates to the technical field of image processing, in particular to a defect detection method based on a standard PCB image and a related device.
Background
The printed circuit board PCB is manufactured by electronic printing, is an important electronic component, is a support for electronic components, and is a carrier for electrical interconnection of electronic components.
In the production and manufacturing process of the PCB, some appearance defects may be generated on the PCB due to the conditions of wrong manufacturing procedure, manual collision, or foreign matter pollution. The appearance defects on the PCB may further affect the functions of the electronic product using the PCB.
PCB defect detection is an important link of PCB detection. The PCB defect detection can be realized manually, but the efficiency and the accuracy of the manual detection of the PCB defects are low. In the PCB defect automatic detection method, the existing defect samples can be utilized to carry out model learning so as to identify the defects in the PCB image to be detected based on the model. However, the accuracy of this automatic detection method is low for rare or unknown types of defects.
Disclosure of Invention
In view of this, the present application provides a defect detection method and apparatus based on a standard PCB image, an electronic device, and a computer-readable storage medium, which can improve the accuracy of PCB defect detection.
In order to solve the above problems, the technical solution provided by the present application is as follows:
in a first aspect, the present application provides a defect detection method based on a standard PCB image, including:
acquiring a PCB image to be detected;
determining a standard PCB image with the same size as the PCB design drawing; the size of the standard PCB image is larger than that of the PCB image to be detected, and the PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected;
performing image interception processing on the standard PCB image to obtain a target standard PCB image; the design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected;
and comparing the PCB image to be detected with the target standard PCB image, and determining the position of the defect in the PCB image to be detected.
In a second aspect, the present application provides a defect detection apparatus based on a standard PCB image, comprising:
the acquisition unit is used for acquiring a PCB image to be detected;
the determining unit is used for determining a standard PCB image with the same size as the design drawing of the PCB; the size of the standard PCB image is larger than that of the PCB image to be detected, and the PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected;
the intercepting unit is used for carrying out image intercepting processing on the standard PCB image to obtain a target standard PCB image; the design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected;
and the comparison unit is used for comparing the PCB image to be detected with the target standard PCB image and determining the position of the defect in the PCB image to be detected.
In a third aspect, the present application provides an electronic device, which includes a memory and a processor, where the memory stores a computer program, and the processor implements the defect detection method based on the standard PCB image when executing the computer program.
In a fourth aspect, the present application provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the standard PCB image based defect detection method as described above.
Therefore, the application has the following beneficial effects:
firstly, acquiring a PCB image to be detected. Further, a standard PCB image having the same size as the PCB board design drawing is determined. And performing image interception processing on the standard PCB image to obtain a target standard PCB image because the size of the standard PCB image is larger than that of the PCB image to be detected. The design drawing area corresponding to the obtained target standard PCB design image is the same as the design drawing area corresponding to the PCB image to be detected, and the target standard PCB design image can be used as a non-defective reference image of the PCB image to be detected. Therefore, the position of the defect in the PCB image to be detected can be determined by comparing the PCB image to be detected with the target standard PCB design image. Therefore, by adopting the embodiment of the application, defects of all types can be effectively identified without learning the defects, and the accuracy of PCB defect detection is improved.
Drawings
Fig. 1a is a schematic view of a scratch defect provided in an embodiment of the present application;
FIG. 1b is a schematic view of a crack defect provided in an embodiment of the present application;
FIG. 1c is a schematic diagram of a copper leakage defect according to an embodiment of the present application;
FIG. 1d is a schematic view of a smudge defect provided by an embodiment of the present application;
fig. 2 is a flowchart of a defect detection method based on a standard PCB image according to an embodiment of the present disclosure;
fig. 3a is a schematic diagram of a PCB image to be detected according to an embodiment of the present application;
fig. 3b is a schematic diagram of a design drawing area corresponding to a target standard PCB image according to an embodiment of the present disclosure;
FIG. 3c is a schematic diagram of a target standard PCB image according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of a defect detection apparatus based on a standard PCB image according to an embodiment of the present disclosure;
fig. 5 is a schematic diagram of an electronic device according to an embodiment of the present application;
fig. 6 is a schematic diagram of a computer-readable storage medium according to an embodiment of the present application.
Detailed Description
In order to make the aforementioned objects, features and advantages of the present application more comprehensible, embodiments accompanying figures and detailed description thereof are described in further detail below.
To facilitate understanding and explanation of the technical solutions provided in the embodiments of the present application, the following description will first provide a background art of the present application.
Printed Circuit Boards (PCBs) are important electronic components, support members for electronic components, and carriers for electrical interconnection of electronic components, which are manufactured by electronic printing. In the production and manufacturing process of the PCB, some appearance defects may be generated on the PCB due to the conditions of wrong manufacturing procedure, manual collision, or foreign matter pollution.
The types of PCB defects mainly include two major types, linear type defects and bulk type defects. The linear type defects at least include scratch defects and crack defects, and the bulk type defects at least include ink type defects and copper leakage type defects. Referring to fig. 1a, fig. 1a is a schematic diagram illustrating a scratch defect according to an embodiment of the present application, where the scratch defect is a scratch occurring on a PCB. Referring to fig. 1b, fig. 1b is a schematic diagram of a crack defect provided in an embodiment of the present application, where the crack defect is a crack occurring on a PCB, such as a crack in ink covering the PCB.
Referring to fig. 1c, fig. 1c is a schematic diagram of a copper leakage defect provided in an embodiment of the present application, in which the copper leakage defect is a portion where copper is exposed due to ink falling from a circuit or a copper surface of a PCB caused by an external factor, and is referred to as copper leakage. The ink-type defects are generally heterochromatic parts appearing around the bonding pad and are generally light black. The different color part is caused by that the ink in the pad area is not removed completely. The welding pad is a connecting medium used for welding electronic elements on the PCB and is used for combining the electronic elements and the circuit according to the design requirement, so that the circuit function is realized. The pads may be in the form of different sizes and shapes as desired, such as circular, square, octagonal, teardrop, and the like. In addition, offset printing may occur on a character frame on the PCB, the offset printing contacts with the pad, or the character frame is printed on the pad, or the character is unclear, falls off, and the like, and the character defects can be understood as ink defects. Referring to fig. 1d, fig. 1d is a schematic view of a smudge defect provided by an embodiment of the present application, where the type defect further includes a smudge defect, and the smudge defect is a smudge occurring on the PCB.
It is known that the appearance defects on the PCB may further affect the functions of the electronic product using the PCB. Therefore, PCB defect detection is an important link of PCB detection. The PCB defect detection can be realized manually, but the efficiency and the accuracy of the manual detection of the PCB defects are low. In addition, the PCB defect detection can be carried out by utilizing a PCB defect automatic detection method. In the PCB defect automatic detection method, model learning and training can be carried out by utilizing the existing defect samples, so that the trained model is utilized to identify the defects in the PCB image to be detected. However, for rare or unknown types of defects, the model cannot be identified. This makes the automatic detection method less accurate.
Based on this, the embodiment of the application provides a defect detection method and device based on a standard PCB image, an electronic device and a computer readable storage medium, and a PCB image to be detected is obtained first. Further, a standard PCB image having the same size as the PCB board design drawing is determined. And performing image interception processing on the standard PCB image to obtain a target standard PCB image because the size of the standard PCB image is larger than that of the PCB image to be detected. The design drawing area corresponding to the obtained target standard PCB design image is the same as the design drawing area corresponding to the PCB image to be detected, and the target standard PCB design image can be used as a non-defective reference image of the PCB image to be detected. Therefore, the position of the defect in the PCB image to be detected can be determined by comparing the PCB image to be detected with the target standard PCB design image. Therefore, by adopting the method and the device, all types of defects can be effectively identified without learning the defects, and the accuracy of PCB defect detection is improved.
In order to facilitate understanding of the present application, a defect detection method based on a standard PCB image provided in an embodiment of the present application is described below with reference to the accompanying drawings.
Referring to fig. 2, the figure is a flowchart of a defect detection method based on a standard PCB image according to an embodiment of the present application. The method can be applied to Automatic Optical Inspection (AOI) equipment, and the AOI equipment is equipment for detecting defects encountered in welding production based on Optical principles. As shown in fig. 2, the method may include S201-S204:
s201: and acquiring the PCB image to be detected.
Before the PCB is fabricated by the electronic printing method, the whole PCB design is acquired. The PCB design drawing is a design drawing which takes a circuit schematic drawing as a basis and realizes a specific function on the PCB. And etching the PCB circuit board on the basis of the PCB design drawing to obtain the etched PCB.
The PCB image to be detected in the step is obtained by scanning the etched PCB. As an optional example, the AOI device may implement functions of scanning the PCB, acquiring a PCB image to be detected, processing the image of the PCB image to be detected, and detecting defects in the PCB image to be detected. Based on this, the hardware system of the AOI device may include a work platform, an image acquisition system, an image processing system, and the like. The PCB can be automatically scanned by a camera in the image acquisition system so as to acquire the PCB image to be detected.
Referring to fig. 3a, fig. 3a is a schematic diagram of a PCB image to be detected according to an embodiment of the present application. The etched PCB board may have some defects, and based on the defect detection method based on the standard PCB image provided by the embodiment of the application, the defect position can be automatically detected on the basis of the PCB image to be detected. As shown in fig. 3a, the type of the defect in the PCB image to be detected is a copper leakage defect, and refer to fig. 1c. The embodiment of the application can detect the defect position in fig. 3a in an automatic detection mode.
It should be noted that, when scanning the etched PCB, only a local PCB may be scanned, and the obtained to-be-detected PCB image is a local image of the entire etched PCB. The PCB image to be detected shown in fig. 3a is a partial image.
S202: determining a standard PCB image with the same size as the PCB design drawing; the size of the standard PCB image is larger than that of the PCB image to be detected; the PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected.
The PCB design in this step is the entire PCB design or a portion of the entire PCB design upon which the PCB is etched in S201. In addition, if the PCB image to be detected is a local image, the design drawing area corresponding to the PCB image to be detected is also a part of the whole PCB design drawing.
Based on the PCB design drawing, a standard PCB image with the same size as the PCB design drawing is determined. The standard PCB image corresponds to the PCB design drawing, and no PCB defect exists in the standard PCB image. For example, the PCB design drawing size (or resolution) is 600 × 600, the standard PCB image size (or resolution) is also 600 × 600, and the PCB image to be detected size (or resolution) is 30 × 30.
It will be appreciated that standard PCB images are not obtained by scanning an already etched PCB. The standard PCB image has no PCB defect, and the corresponding PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected.
Based on this, in some possible implementations, the embodiments of the present application provide two specific implementations of determining a standard PCB image with the same size as the PCB board design drawing, specifically please refer to A1-A3 and B1 below.
S203: performing image interception processing on the standard PCB image to obtain a target standard PCB image; and the design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected.
Because the size of the standard PCB image is larger than that of the PCB image to be detected, in order to more conveniently identify the defects in the PCB image to be detected, image capture processing needs to be performed on the standard PCB image to obtain a target standard PCB image. And the size of the target standard PCB image intercepted from the standard PCB image is the same as that of the PCB image to be detected. The design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected, no PCB defect exists in the target standard PCB image, and the target standard PCB image can be exemplarily understood as a reference image of the PCB image to be detected.
Referring to fig. 3b, fig. 3b is a schematic diagram of a design drawing area corresponding to a target standard PCB image according to an embodiment of the present disclosure. Referring to fig. 3c, fig. 3c is a schematic diagram of a target standard PCB image according to an embodiment of the present application. As shown in fig. 3a and 3c, the size of the target standard PCB image is the same as the size of the PCB image to be detected, and the target standard PCB image in fig. 3c is a reference image of the PCB image to be detected in fig. 3 a. The target standard PCB image in fig. 3c is free of the leaky copper-like defects in fig. 3 a.
It will be appreciated that the target standard PCB image obtained is surface complete and defect free and should be the same or similar in overall style and detail to the real PCB image. Such a target standard PCB image can be regarded as an image captured when no defect occurs in the PCB board region photographed by the PCB image to be detected.
In some possible implementation manners, the embodiment of the present application provides three specific implementation manners for performing image capturing processing on a standard PCB image to obtain a target standard PCB image, which are specifically referred to as C1-C3, D1-D4, and E1-E8 below.
S204: and comparing the PCB image to be detected with the target standard PCB image, and determining the position of the defect in the PCB image to be detected.
Because the target standard PCB image is a reference image of the PCB image to be detected and no PCB defect exists in the target standard PCB image, after the target standard PCB image is obtained, the PCB image to be detected can be compared with the target standard PCB image so as to determine the position of the defect in the PCB image to be detected.
It should be noted that the steps S201 to S204 executed to detect the defects in the PCB image to be detected are all automatically implemented, that is, the defects in the PCB image to be detected can be automatically detected.
As an alternative example, after determining the location of the defect in the image of the PCB to be inspected, the defect may be marked by an automatic mark, such as a circle. Furthermore, the to-be-detected PCB image marked with the defect position can be displayed through a display in the AOI equipment so as to be repaired by a maintenance worker.
In some possible implementation manners, embodiments of the present application provide a specific implementation manner for comparing a to-be-detected PCB image with a target standard PCB image and determining a defect position in the to-be-detected PCB image, which is specifically referred to as F1 to F4 below.
Based on the related contents of the above S201-S204, the application provides a defect detection method based on a standard PCB image. Firstly, acquiring a PCB image to be detected. And determining a standard PCB image with the same size as the PCB design drawing. The size of the standard PCB image is larger than that of the PCB image to be detected, and the PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected. And then, carrying out image interception processing on the standard PCB image to obtain a target standard PCB image. The design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected. Therefore, the PCB image to be detected is compared with the target standard PCB image, and the position of the defect in the PCB image to be detected is determined. Therefore, the defect detection method based on the standard PCB image provided by the embodiment of the application carries out defect identification on the PCB image to be detected by comparing the PCB image to be detected with the target standard PCB image. Therefore, all types of defects can be effectively identified without learning the defects, and the accuracy of PCB defect detection is improved.
In some possible implementations, the embodiment of the present application provides a specific implementation manner of determining the standard PCB image with the same size as the PCB board design drawing in S202, including:
a1: and acquiring a reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing.
The reference PCB design is any one of the PCB design except the PCB design involved in S201-S204. And acquiring a reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing. And the standard reference PCB image corresponding to the reference PCB design drawing is a PCB image without defects.
For example, the reference PCB may be etched according to the reference PCB design drawing, and the etched reference PCB may be scanned to obtain a standard reference PCB image corresponding to the reference PCB design drawing. And the reference standard PCB image corresponding to the reference PCB design drawing is manually detected and determined to have no defects.
A2: and determining a nonlinear transformation relation between the reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing.
And determining a non-linear transformation relation between the reference PCB design drawing and the standard reference PCB image corresponding to the reference PCB design drawing, namely determining the correlation between the reference PCB design drawing and the standard reference PCB image corresponding to the reference PCB design drawing.
As an alternative example, the non-linear transformation relationship between the reference PCB board design drawing and the standard reference PCB image corresponding to the reference PCB board design drawing may be determined through an image analogy algorithm. The image analogy algorithm is an algorithm for learning the mapping relation between the source image and the target image. Namely, the mapping relationship between the reference PCB design drawing and the standard reference PCB image corresponding to the reference PCB design drawing, i.e. the above-mentioned nonlinear transformation relationship, is learned through the image analogy algorithm.
The reference PCB design drawing is a source image, and the standard reference PCB image corresponding to the reference PCB design drawing is a target image.
A3: and determining a standard PCB image with the same size as the PCB design drawing according to the PCB design drawing and the nonlinear transformation relation.
After the nonlinear transformation relationship is obtained, the nonlinear transformation relationship may be represented by a function y = f (x), and the function f (x) is a nonlinear function. Wherein x is the pixel value of the pixel point in the source image, and y is the pixel value of the pixel point in the target image.
Thus, the PCB layout can also be used as a source image. Then according to the PCB design drawing and the determined nonlinear transformation relation, a standard PCB image with the same size as the PCB design drawing can be further determined, and the image is also a target image.
Based on the contents of A1-A3, it can be known that a standard PCB image having the same size as the PCB design drawing can be determined by learning a nonlinear transformation relationship between the reference PCB design drawing and the standard reference PCB image corresponding to the reference PCB design drawing.
In another possible implementation manner, the embodiment of the present application provides another specific implementation manner of determining a standard PCB image with the same size as the PCB design drawing in S202, including:
b1: and inputting the PCB design drawing into the trained generation countermeasure network for processing, and outputting a standard PCB image with the same size as the PCB design drawing. The generation of the countermeasure network is obtained by training based on the reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing.
The generation of the countermeasure network is a deep learning network and mainly comprises a generator and a discriminator. In specific implementation, the training generated confrontation network is a training generator and a discriminator. And inputting the standard reference PCB image corresponding to the reference PCB design drawing into the discriminator, marking the standard reference PCB image corresponding to the reference PCB design drawing as true, and training the discriminator. The generator generates a false standard PCB image corresponding to the reference PCB design drawing, inputs the false standard PCB image into the discriminator, marks the false standard PCB image as false, and trains the discriminator. In addition, the generator generates a false standard PCB image corresponding to the reference PCB design drawing, inputs the false standard PCB image into the discriminator, and trains the generator according to a judgment result output by the discriminator. At this time, the parameters of the discriminator are not updated. Repeating the training process until the generator and the arbiter reach Nash equilibrium, and obtaining the trained generation confrontation network.
After the trained generative countermeasure network is obtained, the PCB design drawing is input into the trained generative countermeasure network, and a standard PCB image with the same size as the PCB design drawing is output. It will be appreciated that a standard PCB image of the same size as the PCB board layout is the output that generates the countermeasure network.
As an alternative example, the generation countermeasure network may be trained by replacing it with another convolutional neural network, which is not described in detail here.
Based on the content of B1, a standard PCB image which generates the output of the countermeasure network and has the same size as the PCB design drawing can be obtained through the trained deep learning network. It is understood that the generation of the countermeasure network is a deep learning network, and the method belongs to a deep learning method.
It can be understood that A1-A3 and B1 are specific embodiments for determining a standard PCB image with the same size as the PCB board design drawing, and the two ways are in an or relationship, i.e. A1-A3 or B1 can be used for implementation.
In some possible implementation manners, an embodiment of the present application provides a specific implementation manner of performing image clipping processing on a standard PCB image in S203 to obtain a target standard PCB image, including:
c1: and moving the pixel points of the PCB image to be detected one by one on the standard PCB image.
After the standard PCB image is acquired, image capture processing needs to be performed on the standard PCB image to obtain a captured target standard PCB image.
As an alternative example, a sliding window template matching method can be adopted to perform image interception processing on a standard PCB image. In specific implementation, because the size of the standard PCB image is larger than that of the PCB image to be detected and the standard PCB image are both rectangular, the pixel points of the PCB image to be detected are moved on the standard PCB image one by one.
It will be appreciated that there is only translation in the horizontal and up-down directions when moving, and there is no rotation or zoom change. In specific implementation, the to-be-detected PCB image can be placed on the standard PCB image, one corner of the to-be-detected PCB image is aligned with one corner of the standard PCB image at the same position (for example, the upper left corners of the two images are aligned), and then the pixel points horizontally move one by one, and after the movement in the same horizontal direction is finished, one pixel point horizontally moves in the up-and-down direction, and then the pixel points horizontally move one by one.
C2: and after each movement, determining a first area image overlapped with the PCB image to be detected in the standard PCB image, and calculating the pixel mean square error of the first area image and the PCB image to be detected.
After each movement of the PCB image to be detected, the standard PCB image may have an area overlapping with the PCB image to be detected. As an alternative example, after each movement, a first area image of the standard PCB image that overlaps the PCB image to be detected is determined. The first region image is an image of the overlap region.
And further, calculating the pixel mean square error of the first area image and the PCB image to be detected.
Wherein, the mean square error of the pixel is S =1/n [ (x 1-y 1) ^2+ (x 2-y 2) ^2+ … … + (xn-yn) ^2]. And S is the mean square error of the pixel, x1 is the pixel value of a first pixel point in the first area image, and y1 is the pixel value of a pixel point in the PCB image to be detected, wherein the pixel point is at the same position as the pixel point of the first pixel point. And x2 is the pixel value of a second pixel point in the first area image, and y2 is the pixel value of a pixel point with the same pixel position as the second pixel point in the PCB image to be detected. xn is the pixel value of the nth pixel point in the first area image, and yn is the pixel value of the pixel point with the same pixel position as the nth pixel point in the PCB image to be detected. And n is the total number of pixel points in the first area image or the PCB image to be detected.
It will be appreciated that the C2 step is also performed when the PCB image to be detected is first placed on the standard PCB image.
C3: and when the pixel mean square error meets a first error preset range, intercepting a current first area image overlapped with the PCB image to be detected in the standard PCB image, and determining the current first area image as a target standard PCB image.
And when the pixel mean square error meets a first error preset range, determining that the standard PCB image and the PCB image to be detected are aligned, wherein the current first area image in the standard PCB image is the target standard PCB image. It can also be understood that the design drawing region corresponding to the current first region image is the same as the design drawing region corresponding to the PCB image to be detected. At the moment, a current first area image overlapped with the PCB image to be detected in the standard PCB image is intercepted, and the current first area image is determined as a target standard PCB image.
It is understood that the first error preset range is a smaller range close to 0, and the specific numerical value of the first error preset range is not limited herein.
Based on C1-C3, the slidable window template matching method realizes the alignment operation of the PCB image to be detected and the standard PCB image so as to obtain the target standard PCB image, and the obtained target standard PCB image is more accurate.
In another possible implementation manner, an embodiment of the present application provides another specific implementation manner for performing image capture processing on a standard PCB image in S203 to obtain a target standard PCB image, including:
d1: and performing edge extraction processing on the PCB image to be detected to obtain a first image edge characteristic in the PCB image to be detected.
The image edge is the position where the image gray-scale change rate is the largest. The edge extraction processing is extraction processing of image edge features in an image. As an alternative example, canny operator, sobel operator, and the like can be used to implement the edge extraction process. It is understood that the first image edge feature can be represented by a feature image, and an edge line composed of image edge contour points is displayed in the feature image.
D2: and projecting the PCB image to be detected on the standard PCB image, and moving the PCB image to be detected one by one according to pixel points.
And if the size of the standard PCB image is larger than that of the PCB image to be detected, projecting the PCB image to be detected on the standard PCB image, and moving the PCB image to be detected one by pixel points. The process of moving the pixels one by one can refer to C1, and is not described herein again.
D3: after each movement, determining a second area image which is overlapped with the projection of the PCB image to be detected in the standard PCB image, carrying out edge extraction processing on the second area image to obtain second image edge features in the second area image, and calculating a first feature distance between the first image edge features and the second image edge features.
After the PCB image to be detected is moved each time, a second area image which is overlapped with the projection of the PCB image to be detected exists in the standard PCB image. At this time, the edge extraction processing is performed on the second area image, so that the second image edge feature in the second area image is obtained. The method and process of the second image edge feature may refer to the first image edge feature, which is not described herein again. It is understood that the edge feature of the second image can also be represented by a feature image, and an edge line formed by the edge contour points of the image is displayed in the feature image.
After the first image edge feature and the second image edge feature after each movement are obtained, a first feature distance between the first image edge feature and the second image edge feature is calculated. As an alternative example, a first image edge feature may be represented by a first vector and a second image edge feature by a second vector. Thus, the first characteristic distance is the distance between the first vector and the second vector. At this time, the distance between the first vector and the second vector may be calculated by a cosine distance formula.
D4: and when the first characteristic distance meets a first distance preset range, intercepting a current second area image which is overlapped with the projection of the PCB to be detected in the standard PCB image, and determining the current second area image as a target standard PCB image.
After the first characteristic distance is calculated each time, whether the first characteristic distance meets a first distance preset range or not is judged, if yes, the standard PCB image is determined to be aligned with the PCB image to be detected, and the current second area image in the standard PCB image at the moment is the target standard PCB image. It can also be understood that the design drawing region corresponding to the current second region image is the same as the design drawing region corresponding to the PCB image to be detected. At the moment, a current second area image overlapped with the PCB image to be detected in the standard PCB image is intercepted, and the current second area image is determined as a target standard PCB image.
It is understood that the first predetermined range of distances is a smaller range close to 0, and the specific values of the first predetermined range of distances are not limited herein.
Based on D1-D4, the target standard PCB image in the standard PCB image can be intercepted through the edge features of the PCB image to be detected and the edge features of the middle area of the standard PCB image. Because the calculation amount for extracting the edge features is less, the efficiency for obtaining the target standard PCB image can be accelerated.
In another possible implementation manner, an embodiment of the present application provides another specific implementation manner for performing image capture processing on a standard PCB image in S203 to obtain a target standard PCB image, including:
e1: intercepting at least one region-of-interest image in the standard PCB image; the area of the interested area image is larger than that of the PCB image to be detected.
In order to improve the acquisition efficiency of the target standard PCB image, the standard PCB image can be intercepted firstly, and at least one interested area image in the standard PCB image is intercepted. For example, the standard PCB image is divided into a left part and a right part, and the left part and the right part are divided into two parts, and the two intercepted area images are two interested area images in the standard PCB image. In general, the region of interest may be a rectangular region.
It can be understood that the area of the image of the region of interest needs to be larger than the area of the image of the PCB to be detected.
Based on the method, each region-of-interest image is sequentially aligned with the PCB image to be detected. Therefore, if the target standard PCB image is in the first interested area image, the rest interested area images do not need to be aligned with the PCB image to be detected. Therefore, the acquisition efficiency of the target standard PCB image can be improved.
E2: carrying out pixel point-by-pixel point movement on the PCB image to be detected on the target interesting region image; the target region-of-interest image is each of the at least one region-of-interest images.
E3: and after each movement, determining a third area image overlapped with the PCB image to be detected in the target interesting area image, and calculating the pixel mean square error of the third area image and the PCB image to be detected.
E4: and when the pixel mean square error meets a second error preset range, intercepting a current third area image which is overlapped with the PCB image to be detected in the target interesting area image, and determining the current third area image as a target standard PCB image.
The second error preset range may be the same as or different from the first error preset range.
It can be understood that the technical implementation details of E2-E4 can refer to C1-C3, and only the standard PCB image needs to be replaced with the target region-of-interest image, which is not described herein again.
It can also be understood that, if the current image of the region of interest cannot make the obtained mean square error of the pixel meet the second preset error range, the next image of the region of interest is replaced for judgment. If the intercepted interested area images can not enable the pixel mean square error to meet the second error preset range, at least one interested area image in the standard PCB image can be intercepted again. It will be appreciated that the manner of interception at each time is different.
In addition, target standard PCB images can also be acquired based on E5-E8. It can be understood that E2-E4 and E5-E8 are both specific embodiments for obtaining a target standard PCB image on the basis of at least one region-of-interest image and a PCB image to be detected, and E2-E4 and E5-E8 are in an implementation relationship of "or".
E5: and performing edge extraction processing on the PCB image to be detected to obtain a third image edge characteristic in the PCB image to be detected.
E6: and projecting the PCB image to be detected on the target interesting region image, and moving the PCB image to be detected one by one according to pixel points.
E7: after each movement, determining a fourth area image which is projected and overlapped with the PCB image to be detected in the target interesting area image, carrying out edge extraction processing on the fourth area image to obtain a fourth image edge feature in the fourth area image, and calculating a second feature distance between the third image edge feature and the fourth image edge feature.
E8: and when the second characteristic distance meets a second distance preset range, intercepting a current fourth area image which is projected and overlapped with the PCB image to be detected in the target interesting area image, and determining the current fourth area image as a target standard PCB image.
The second preset range of distance may be the same as or different from the first preset range of distance.
It can be understood that D1-D4 can be referred to for the technical implementation details of E5-E8, and only the standard PCB image needs to be replaced by the target region-of-interest image, which is not described herein again.
Based on E1-E8, an interested area image can be intercepted from a standard PCB image, and then a target standard PCB image is obtained based on the interested area image and the PCB image to be detected. Therefore, the acquisition efficiency of the target standard PCB image can be improved.
It can also be understood that C1-C3, D1-D4, and E1-E8 are specific embodiments for performing image capture processing on a standard PCB image to obtain a target standard PCB image, and the two modes are in an or relationship, that is, can be implemented by A1-A3 or B1.
In some possible implementation manners, an embodiment of the present application provides a specific implementation manner of comparing the to-be-detected PCB image with the target standard PCB image in S204 to determine a defect position in the to-be-detected PCB image, including:
f1: and extracting the pixel characteristic data of each pixel point in the PCB image to be detected.
As an optional example, the pixel feature data of each pixel point in the PCB image to be detected may be extracted through a pre-trained feature extractor.
F2: and extracting the pixel characteristic data of each pixel point in the target standard PCB image.
As an alternative example, the pixel feature data of each pixel point in the target standard PCB image may be extracted by a pre-trained feature extractor.
In some embodiments, the feature extractors in F1-F2 may be implemented by deep neural networks.
F3: calculating the similarity between the pixel characteristic data of the target pixel point in the PCB image to be detected and the pixel characteristic data of the corresponding pixel point of the target pixel point in the target standard PCB image; the target pixel point is each pixel point in the PCB image to be detected.
For convenience of understanding and description, each pixel point in the PCB image to be detected is described by a target pixel point. And calculating the similarity between the pixel characteristic data of the target pixel point in the PCB image to be detected and the pixel characteristic data of the corresponding pixel point of the target pixel point in the target standard PCB image. And the corresponding pixel points in the target standard PCB image are pixel points at the same positions as the target pixel points in the target standard PCB image.
As an alternative example, the similarity is expressed by a distance. For example, the distance may be a mahalanobis distance, an euclidean distance, a manhattan distance, a hamming distance, and the like. The mahalanobis distance can be regarded as a correction of the euclidean distance.
F4: and determining the position of the target pixel point with the similarity larger than a preset threshold value as the defect position in the PCB image to be detected.
And presetting a preset threshold, and when the similarity is greater than the preset threshold, detecting that the target pixel point in the PCB image to be detected has a defect. And determining the position of the target pixel point in the PCB image to be detected as the defect position in the PCB image to be detected.
It is to be understood that the preset threshold is a preset distance threshold when the similarity is expressed in mahalanobis distance.
Based on the contents of F1-F4, a specific implementation mode for determining the defect position in the PCB image to be detected based on the feature similarity is provided. Because the defect position is accurate to the pixel point, the accuracy of the obtained defect position is high.
It will be understood by those of skill in the art that in the above method of the present embodiment, the order of writing the steps does not imply a strict order of execution and does not impose any limitations on the implementation, as the order of execution of the steps should be determined by their function and possibly inherent logic.
The present application can further combine to provide more implementations on the basis of the implementations provided by the above aspects.
Based on the defect detection method based on the standard PCB image provided by the embodiment of the method, the embodiment of the application also provides a defect detection device based on the standard PCB image, and the defect detection device based on the standard PCB image will be described with reference to the accompanying drawings. Because the principle of the device in the embodiment of the present disclosure for solving the problem is similar to the defect detection method based on the standard PCB image in the embodiment of the present disclosure, the implementation of the device may refer to the implementation of the method, and repeated details are not repeated.
Referring to fig. 4, the figure is a schematic structural diagram of a defect detection apparatus based on a standard PCB image according to an embodiment of the present disclosure. As shown in fig. 4, the defect detecting apparatus based on the standard PCB image includes:
an obtaining unit 401, configured to obtain a PCB image to be detected;
a determining unit 402, configured to determine a standard PCB image with the same size as the PCB board design drawing; the size of the standard PCB image is larger than that of the PCB image to be detected, and the PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected;
an intercepting unit 403, configured to perform image intercepting processing on the standard PCB image to obtain a target standard PCB image; the design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected;
and the comparison unit 404 is configured to compare the to-be-detected PCB image with the target standard PCB image, and determine a defect position in the to-be-detected PCB image.
In some possible implementations, in determining the standard PCB image with the same size as the PCB board layout, the determining unit 402 is specifically configured to:
acquiring a reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing;
determining a nonlinear transformation relation between the reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing;
and determining a standard PCB image with the same size as the PCB design drawing according to the PCB design drawing and the nonlinear transformation relation.
In some possible implementations, in determining the standard PCB image with the same size as the PCB board design drawing, the determining unit 402 is specifically configured to:
inputting the PCB design drawing into the trained generation countermeasure network for processing, and outputting a standard PCB image with the same size as the PCB design drawing;
the generation of the countermeasure network is obtained by training based on the reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing.
In some possible implementation manners, in terms of performing image clipping processing on the standard PCB image to obtain the target standard PCB image, the clipping unit 403 is specifically configured to:
moving the pixel points of the PCB image to be detected on the standard PCB image one by one;
after each movement, determining a first area image overlapped with the PCB image to be detected in the standard PCB image, and calculating the pixel mean square error of the first area image and the PCB image to be detected;
and when the pixel mean square error meets a first error preset range, intercepting a current first area image overlapped with the PCB image to be detected in the standard PCB image, and determining the current first area image as a target standard PCB image.
In some possible implementation manners, in terms of performing image clipping processing on the standard PCB image to obtain the target standard PCB image, the clipping unit 403 is specifically configured to:
performing edge extraction processing on a PCB image to be detected to obtain a first image edge characteristic in the PCB image to be detected;
projecting the PCB image to be detected on the standard PCB image, and moving the PCB image to be detected one by one according to pixel points;
after each movement, determining a second area image which is overlapped with the projection of the PCB image to be detected in the standard PCB image, carrying out edge extraction processing on the second area image to obtain a second image edge feature in the second area image, and calculating a first feature distance between the first image edge feature and the second image edge feature;
and when the first characteristic distance meets a first distance preset range, intercepting a current second area image which is overlapped with the projection of the PCB to be detected in the standard PCB image, and determining the current second area image as a target standard PCB image.
In some possible implementation manners, in terms of performing image capture processing on the standard PCB image to obtain the target standard PCB image, the capture unit 403 is specifically configured to:
intercepting at least one region-of-interest image in the standard PCB image; the area of the interested area image is larger than that of the PCB image to be detected;
carrying out pixel point-by-pixel point movement on the PCB image to be detected on the target interesting region image; the target region-of-interest image is each of the at least one region-of-interest image;
after each movement, determining a third area image overlapped with the PCB image to be detected in the target interesting area image, and calculating the pixel mean square error of the third area image and the PCB image to be detected;
when the pixel mean square error meets a second error preset range, intercepting a current third area image overlapped with the PCB image to be detected in the target interesting area image, and determining the current third area image as a target standard PCB image;
alternatively, the first and second electrodes may be,
performing edge extraction processing on the PCB image to be detected to obtain a third image edge feature in the PCB image to be detected;
projecting the PCB image to be detected on the target interesting region image, and moving the PCB image to be detected one by one according to pixel points;
after each movement, determining a fourth area image which is overlapped with the projection of the PCB image to be detected in the target interesting area image, carrying out edge extraction processing on the fourth area image to obtain a fourth image edge feature in the fourth area image, and calculating a second feature distance between the third image edge feature and the fourth image edge feature;
and when the second characteristic distance meets a second distance preset range, intercepting a current fourth area image which is overlapped with the projection of the PCB image to be detected in the target interesting area image, and determining the current fourth area image as a target standard PCB image.
In some possible implementation manners, in terms of comparing the to-be-detected PCB image with the target standard PCB image and determining the defect position in the to-be-detected PCB image, the comparing unit 404 is specifically configured to:
extracting pixel characteristic data of each pixel point in a PCB image to be detected;
extracting pixel characteristic data of each pixel point in the target standard PCB image;
calculating the similarity between the pixel characteristic data of the target pixel point in the PCB image to be detected and the pixel characteristic data of the corresponding pixel point of the target pixel point in the target standard PCB image; the target pixel point is each pixel point in the PCB image to be detected;
and determining the position of the target pixel point with the similarity larger than a preset threshold value as the defect position in the PCB image to be detected.
Referring to fig. 5, fig. 5 is a schematic view of an electronic device according to an embodiment of the present disclosure, the electronic device includes a memory 501 and a processor 502, the memory 501 stores a computer program, and the processor 502 executes the computer program to implement any one of the above defect detection methods based on a standard PCB image.
In exemplary embodiments disclosed herein, the following steps may be implemented when the computer program is executed by the processor 502:
acquiring a PCB image to be detected;
determining a standard PCB image with the same size as the PCB design drawing; the size of the standard PCB image is larger than that of the PCB image to be detected, and the PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected;
performing image interception processing on the standard PCB image to obtain a target standard PCB image; the design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected;
and comparing the PCB image to be detected with the target standard PCB image, and determining the position of the defect in the PCB image to be detected.
Those skilled in the art will appreciate that the configuration shown in fig. 5 is a block diagram of only a portion of the configuration associated with embodiments of the present application and does not constitute a limitation on the computing device to which embodiments of the present application may be applied, and that a particular computing device may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
Referring to fig. 6, fig. 6 is a schematic diagram of a computer-readable storage medium according to an embodiment of the present application, the computer-readable storage medium has a computer program 601 stored thereon, and when executed by a processor, the computer program 601 implements any one of the above-mentioned defect detection methods based on standard PCB images.
It should be noted that the computer-readable storage medium provided in the embodiments of the present application may also be a computer-readable signal medium or a computer-readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In embodiments of the present application, a computer readable storage medium may be any tangible medium that can contain, or store a computer program for use by or in connection with a processor, instruction execution system, apparatus, or device.
As can be seen from the above description of the embodiments, those skilled in the art can clearly understand that all or part of the steps in the above embodiment methods can be implemented by software plus a necessary general hardware platform. Based on such understanding, the technical solutions of the present application or portions contributing to the prior art may be embodied in the form of a software product, which may be stored in a storage medium, such as a ROM/RAM, a magnetic disk, an optical disk, etc., and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network communication device such as a media gateway, etc.) to execute the method of the embodiments or some portions of the embodiments of the present application.
It should be noted that, in the present specification, the embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments may be referred to each other. The method disclosed by the embodiment corresponds to the system disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the system part for description.
It should also be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising a … …" does not exclude the presence of another identical element in a process, method, article, or apparatus that comprises the element.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the application. Thus, the present application is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. A defect detection method based on standard PCB images is characterized by comprising the following steps:
acquiring a PCB image to be detected;
determining a standard PCB image with the same size as the PCB design drawing; the size of the standard PCB image is larger than that of the PCB image to be detected, and the PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected;
performing image interception processing on the standard PCB image to obtain a target standard PCB image; the design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected;
and comparing the PCB image to be detected with the target standard PCB image, and determining the position of the defect in the PCB image to be detected.
2. The method of claim 1, wherein determining a standard PCB image having the same dimensions as the PCB panel layout comprises:
acquiring a reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing;
determining a nonlinear transformation relation between the reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing;
and determining a standard PCB image with the same size as the PCB design drawing according to the PCB design drawing and the nonlinear transformation relation.
3. The method of claim 1, wherein determining a standard PCB image having the same dimensions as the PCB panel layout comprises:
inputting the PCB design drawing into a trained generation countermeasure network for processing, and outputting a standard PCB image with the same size as the PCB design drawing;
the generation countermeasure network is obtained by training based on a reference PCB design drawing and a standard reference PCB image corresponding to the reference PCB design drawing.
4. The method according to any one of claims 1 to 3, wherein the image-capturing the standard PCB image to obtain a target standard PCB image comprises:
performing pixel point-by-pixel point movement on the PCB image to be detected on the standard PCB image;
after each movement, determining a first area image overlapped with the PCB image to be detected in the standard PCB image, and calculating the pixel mean square error of the first area image and the PCB image to be detected;
and when the pixel mean square error meets a first error preset range, intercepting a current first area image which is overlapped with the PCB image to be detected in the standard PCB image, and determining the current first area image as a target standard PCB image.
5. The method according to any one of claims 1 to 3, wherein the image capturing process is performed on the standard PCB image to obtain a target standard PCB image, and comprises:
performing edge extraction processing on the PCB image to be detected to obtain a first image edge characteristic in the PCB image to be detected;
projecting the PCB image to be detected on the standard PCB image, and moving the PCB image to be detected one by one according to pixel points;
after each movement, determining a second area image which is in the standard PCB image and is overlapped with the projection of the PCB image to be detected, carrying out edge extraction processing on the second area image to obtain second image edge features in the second area image, and calculating a first feature distance between the first image edge features and the second image edge features;
and when the first characteristic distance meets a first distance preset range, intercepting a current second area image which is overlapped with the projection of the PCB image to be detected in the standard PCB image, and determining the current second area image as a target standard PCB image.
6. The method according to any one of claims 1 to 3, wherein the image capturing process is performed on the standard PCB image to obtain a target standard PCB image, and comprises:
intercepting at least one region-of-interest image in the standard PCB image; the area of the interested area image is larger than that of the PCB image to be detected;
carrying out pixel point-by-pixel point movement on the PCB image to be detected on the target interesting region image; the target region-of-interest image is each of the at least one region-of-interest image;
after each movement, determining a third area image overlapped with the PCB image to be detected in the target interesting area image, and calculating a pixel mean square error of the third area image and the PCB image to be detected;
when the pixel mean square error meets a second error preset range, intercepting a current third area image which is overlapped with the PCB image to be detected in the target interesting area image, and determining the current third area image as a target standard PCB image;
alternatively, the first and second electrodes may be,
performing edge extraction processing on the PCB image to be detected to obtain a third image edge characteristic in the PCB image to be detected;
projecting the PCB image to be detected on the target interesting region image, and moving the PCB image to be detected one by one according to pixel points;
after each movement, determining a fourth area image which is projected and overlapped with the PCB image to be detected in the target interesting area image, carrying out edge extraction processing on the fourth area image to obtain a fourth image edge feature in the fourth area image, and calculating a second feature distance between the third image edge feature and the fourth image edge feature;
and when the second characteristic distance meets a second distance preset range, intercepting a current fourth area image which is overlapped with the projection of the PCB image to be detected in the target interesting area image, and determining the current fourth area image as a target standard PCB image.
7. The method according to any one of claims 1 to 3, wherein the comparing the PCB image to be detected with the target standard PCB image to determine the position of the defect in the PCB image to be detected comprises:
extracting pixel characteristic data of each pixel point in the PCB image to be detected;
extracting pixel characteristic data of each pixel point in the target standard PCB image;
calculating the similarity between the pixel characteristic data of a target pixel point in the PCB image to be detected and the pixel characteristic data of a corresponding pixel point of the target pixel point in the target standard PCB image; the target pixel point is each pixel point in the PCB image to be detected;
and determining the position of the target pixel point with the similarity larger than a preset threshold value as the defect position in the PCB image to be detected.
8. A defect detection device based on standard PCB image is characterized by comprising:
the acquisition unit is used for acquiring a PCB image to be detected;
the determining unit is used for determining a standard PCB image with the same size as the design drawing of the PCB; the size of the standard PCB image is larger than that of the PCB image to be detected, and the PCB design drawing comprises a design drawing area corresponding to the PCB image to be detected;
the intercepting unit is used for carrying out image intercepting processing on the standard PCB image to obtain a target standard PCB image; the design drawing area corresponding to the target standard PCB image is the same as the design drawing area corresponding to the PCB image to be detected;
and the comparison unit is used for comparing the PCB image to be detected with the target standard PCB image and determining the position of the defect in the PCB image to be detected.
9. An electronic device, characterized in that the electronic device comprises a memory and a processor, the memory stores a computer program, and the processor when executing the computer program realizes the defect detection method based on standard PCB image as claimed in any one of claims 1-7.
10. A computer-readable storage medium, having stored thereon a computer program which, when being executed by a processor, carries out a method for defect detection based on standard PCB images as claimed in any one of claims 1 to 7.
CN202211625724.6A 2022-12-16 2022-12-16 Defect detection method based on standard PCB image and related device Pending CN115984197A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211625724.6A CN115984197A (en) 2022-12-16 2022-12-16 Defect detection method based on standard PCB image and related device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211625724.6A CN115984197A (en) 2022-12-16 2022-12-16 Defect detection method based on standard PCB image and related device

Publications (1)

Publication Number Publication Date
CN115984197A true CN115984197A (en) 2023-04-18

Family

ID=85969294

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211625724.6A Pending CN115984197A (en) 2022-12-16 2022-12-16 Defect detection method based on standard PCB image and related device

Country Status (1)

Country Link
CN (1) CN115984197A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117437636A (en) * 2023-12-21 2024-01-23 成都数联云算科技有限公司 Method and system for improving defect labeling effect based on image comparison

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117437636A (en) * 2023-12-21 2024-01-23 成都数联云算科技有限公司 Method and system for improving defect labeling effect based on image comparison
CN117437636B (en) * 2023-12-21 2024-02-23 成都数联云算科技有限公司 Method and system for improving defect labeling effect based on image comparison

Similar Documents

Publication Publication Date Title
JP5699788B2 (en) Screen area detection method and system
CN108562250B (en) Keyboard keycap flatness rapid measurement method and device based on structured light imaging
US20130070095A1 (en) Fast obstacle detection
CN114266773B (en) Display panel defect positioning method, device, equipment and storage medium
CN104331695B (en) A kind of circle marker symbol shape quality detection method of robust
CN111025701B (en) Curved surface liquid crystal screen detection method
CN109752392B (en) PCB defect type detection system and method
CN112419298B (en) Bolt node plate rust detection method, device, equipment and storage medium
CN115205223B (en) Visual inspection method and device for transparent object, computer equipment and medium
CN111223078B (en) Method for determining flaw level and storage medium
CN113888756A (en) Method for determining effective area parameters, image acquisition method and test system
CN115908420A (en) Method, device and equipment for detecting defects of printed circuit board and storage medium
CN115984197A (en) Defect detection method based on standard PCB image and related device
CN110288040B (en) Image similarity judging method and device based on topology verification
CN113705564B (en) Pointer type instrument identification reading method
US9946918B2 (en) Symbol detection for desired image reconstruction
CN115375608A (en) Detection method and device, detection equipment and storage medium
JP2005345290A (en) Streak-like flaw detecting method and streak-like flaw detector
CN110658215B (en) PCB automatic splicing detection method and device based on machine vision
CN116091503B (en) Method, device, equipment and medium for discriminating panel foreign matter defects
CN111563869B (en) Stain test method for quality inspection of camera module
CN111932517A (en) Contour mapping method and device for excess material plate, electronic equipment and storage medium
CN116402771A (en) Defect detection method and device and model training method and device
CN116993654A (en) Camera module defect detection method, device, equipment, storage medium and product
CN115479891A (en) Automatic detection system and method for circuit board mounted components based on image recognition

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination