Circuit board fault identification method and related equipment

Through image processing and feature extraction technology, the component types and locations in the circuit board are automatically identified, which solves the problem of inefficient circuit board failure detection and achieves efficient and accurate fault identification.

CN113536868BActive Publication Date: 2025-07-18FOXCONN PRECISION ELECTRONICS TAIYUAN CO LTD +1
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202010324236.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-04-22
Publication Date
2025-07-18
Estimated Expiration
2040-04-22

AI Technical Summary

Technical Problem

In the prior art, circuit board fault detection is inefficient and prone to missed or missed detection, making it difficult to achieve efficient and accurate fault identification.

Method used

By acquiring the circuit board images, image annotation and component identification, component feature vectors are extracted, and aggregation channel feature method and classifier are used to determine whether the circuit board has a fault and output fault information.

Benefits of technology

Improves the efficiency and accuracy of circuit board fault identification, and can quickly and accurately identify faulty components in the circuit board.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113536868B_ABST
    Figure CN113536868B_ABST
Patent Text Reader

Abstract

The present invention provides a circuit board fault identification method, apparatus, electronic device, and storage medium. The circuit board fault identification method includes: obtaining a circuit board image to be measured of a circuit board to be measured, where the circuit board to be measured includes a plurality of components to be measured; performing image annotation on the plurality of components to be measured in the circuit board image to be measured to obtain candidate images of each component to be measured; obtaining position information of each component to be measured according to the candidate images of each component to be measured; extracting component features of each candidate image based on an aggregated channel features method to obtain a first feature vector of each candidate image; identifying the component type of each component to be measured according to the first feature vector of each candidate image; judging whether the circuit board to be measured has a fault according to the component type and position information of each component to be measured, and outputting fault information when the circuit board to be measured has a fault. Using the present invention can improve the fault identification efficiency of the circuit board.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer vision technology, and in particular, to a method, device, electronic device, and storage medium for identifying circuit board faults. Background Art

[0002] Electronic product manufacturers usually need to perform fault detection on the produced circuit boards. For example, it is necessary to detect whether the positions of the electronic components in the circuit board are normal and whether the appearances of each electronic component are normal.

[0003] Currently, manual sampling inspection is used to detect faults in the electronic components in the circuit board. In this way, not only is the efficiency low, but also missed inspections or misinspections are likely to occur.

[0004] How to improve the detection efficiency and accuracy is a problem to be solved. Summary of the Invention

[0005] In view of the above, it is necessary to provide a method, device, electronic device, and storage medium for identifying circuit board faults, which can not only improve the efficiency of identifying circuit board faults, but also improve the accuracy of identifying circuit board faults.

[0006] A method for identifying circuit board faults, which is applied to an electronic device. The method for identifying circuit board faults includes:

[0007] Obtain a test circuit board image of the circuit board to be tested, where the circuit board to be tested includes a plurality of test components;

[0008] Perform image annotation on the plurality of test components in the test circuit board image to obtain candidate images of each test component;

[0009] Obtain the position information of each test component according to the candidate images of each test component;

[0010] Extract the component features of each candidate image based on the aggregated channel features method to obtain the first feature vector of each candidate image;

[0011] Identify the component type of each test component according to the first feature vector of each candidate image;

[0012] Judge whether the circuit board to be tested has a fault according to the component type and position information of each test component, and output fault information when the circuit board to be tested has a fault.

[0013] A device for identifying circuit board faults, which runs on an electronic device. The device for identifying circuit board faults includes:

[0014] A first acquisition module, configured to acquire a test circuit board image of the circuit board to be tested, where the circuit board to be tested includes a plurality of test components;

[0015] A labeling module, configured to perform image labeling on the plurality of components to be measured in the image of the circuit board to be measured, so as to obtain candidate images of the respective components to be measured;

[0016] A second obtaining module, configured to obtain the position information of the respective components to be measured according to the candidate images of the respective components to be measured;

[0017] An extraction module, configured to extract component features of the respective candidate images based on an aggregated channel features method, so as to obtain first feature vectors of the respective candidate images;

[0018] A first recognition module, configured to recognize the component types of the respective components to be measured according to the first feature vectors of the respective candidate images;

[0019] A judgment module, configured to judge whether the circuit board to be measured has a fault according to the component types and position information of the respective components to be measured, and output fault information when the circuit board to be measured has a fault.

[0020] An electronic device, the electronic device includes:

[0021] A memory, storing at least one instruction; and

[0022] A processor, configured to obtain the instruction stored in the memory to implement the circuit board fault recognition method.

[0023] A computer-readable storage medium, in which at least one instruction is stored, and the at least one instruction is obtained by a processor in an electronic device to implement the circuit board fault recognition method.

[0024] It can be seen from the above technical solutions that the present invention judges whether the circuit board to be measured has a fault according to the component types of the respective components to be measured and the position information of the respective components to be measured, and can improve the fault recognition efficiency of the circuit board to be measured. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] Figure 1 is a flowchart of a preferred embodiment of the circuit board fault recognition method of the present invention.

[0026] Figure 2 is a functional module diagram of a preferred embodiment of the circuit board fault recognition device of the present invention.

[0027] Figure 3 is a schematic structural diagram of an electronic device of a preferred embodiment for implementing the circuit board fault recognition method of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0028] In order to make the objectives, technical solutions and advantages of the present invention clearer, the present invention will be described in detail below with reference to the accompanying drawings and specific embodiments.

[0029] As shown Figure 1 in the figure, it is a flowchart of a preferred embodiment of the circuit board fault identification method of the present invention. According to different requirements, the order of steps in this flowchart can be changed, and some steps can be omitted.

[0030] The circuit board fault identification method is applied to an electronic device, which is a device capable of automatically performing numerical calculations and / or information processing according to pre-set or stored instructions. Its hardware includes but is not limited to a microprocessor, an application specific integrated circuit (ASIC), a field-programmable gate array (FPGA), a digital signal processor (DSP), an embedded device, etc.

[0031] The electronic device can be any electronic product that can perform human-computer interaction with users. For example, a personal computer, a tablet computer, a smart phone, a personal digital assistant (PDA), etc.

[0032] The electronic device may also include a network device and / or a user device. Among them, the network device includes but is not limited to a single network server, a server group composed of multiple network servers, or a cloud composed of a large number of hosts or network servers based on cloud computing (CloudComputing).

[0033] The network where the electronic device is located includes but is not limited to the Internet, a wide area network, a metropolitan area network, a local area network, a virtual private network (VPN), etc.

[0034] S10. Obtain an image of the circuit board to be tested, where the circuit board to be tested includes multiple components to be tested.

[0035] In at least one embodiment of the present invention, the image of the circuit board to be tested includes an image of the entire circuit board to be tested of the electronic device or an image of a part of the circuit board to be tested of the electronic device.

[0036] In at least one embodiment of the present invention, the image of the circuit board to be tested is obtained by an industrial camera.

[0037] For example, an image of the entire circuit board to be tested can be taken by an industrial camera to obtain the image of the circuit board to be tested.

[0038] In at least one embodiment of the present invention, an industrial camera can be controlled by a motion control system to take segmented pictures of the overall circuit board to be tested of an electronic device, so as to obtain images of partial circuit boards to be tested of the electronic device.

[0039] In at least one embodiment of the present invention, the front and back of the overall circuit board to be tested of the electronic device are taken in segments by the industrial camera, so as to obtain images of partial circuit boards to be tested of the electronic device.

[0040] S11, perform image annotation on the multiple components to be tested in the image of the circuit board to be tested, so as to obtain candidate images of each component to be tested.

[0041] In at least one embodiment of the present invention, the performing image annotation on the multiple components to be tested in the image of the circuit board to be tested includes:

[0042] Slide a sliding window of different sizes on the image of the circuit board to be tested to intercept multiple sliding images;

[0043] Use the trained component recognition model to recognize each component to be tested from the multiple sliding images;

[0044] Perform annotation on each recognized component to be tested in the image of the circuit board to be tested to obtain candidate images of each component to be tested. The component recognition model is a binary classification neural network.

[0045] In at least one embodiment of the present invention, before using the trained component recognition model to recognize each component to be tested from the multiple sliding images, the circuit board fault recognition method further includes: training the component recognition model.

[0046] The training of the component recognition model includes:

[0047] Obtain component image samples, and there are corresponding component image labels for the component image samples;

[0048] Use the component image samples as inputs, and calculate the recognition results of the component image samples through the component recognition model;

[0049] Optimize the component recognition model based on the recognition results and the component image labels according to the backpropagation algorithm to obtain the trained component recognition model.

[0050] When the component image sample is a complete component, the component image label corresponding to the component image sample is 1 (indicating that the component image sample is an image of a complete component); when the component image sample is not a complete component, the component image label corresponding to the component image sample is 0 (indicating that the component image sample is not an image of a complete component, or the component image sample is not an image of a component).

[0051] In at least one embodiment of the present invention, before image annotation of the multiple components to be tested in the circuit board image to be tested, the circuit board fault recognition method further includes:

[0052] Preprocessing and calibrating the circuit board image to be tested.

[0053] S12. Obtain the position information of each component to be tested according to the candidate images of each component to be tested.

[0054] In at least one embodiment of the present invention, the obtaining the position information of each component to be tested according to the candidate images of each component to be tested includes:

[0055] Obtain the first pixel point at the upper left corner of each candidate image;

[0056] Determine the first coordinate of the first pixel point in the circuit board image to be tested;

[0057] Determine the first coordinate as the position information of the component to be tested corresponding to the candidate image.

[0058] In at least one embodiment of the present invention, the obtaining the position information of each component to be tested according to the candidate images of each component to be tested includes:

[0059] Obtain the second pixel point at the center of each candidate image;

[0060] Determine the second coordinate of the second pixel point in the circuit board image to be tested;

[0061] Determine the second coordinate as the position information of the component to be tested corresponding to the candidate image.

[0062] S13. Extract the component features of each candidate image based on the aggregated channel features method to obtain the first feature vector of each candidate image.

[0063] In at least one embodiment of the present invention, the aggregated channel features method can superimpose various different features (such as color features, gradient features, and edge features) of each candidate image to form a unified feature.

[0064] In at least one embodiment of the present invention, the extracting the component features of each candidate image based on the aggregated channel features method includes:

[0065] Transform the candidate image into the YUV color space;

[0066] Determine the Y-channel feature of the candidate image as the first-channel feature;

[0067] Reduce the feature maps of the Y, U, and V channels of the candidate image by half respectively, and use them as the upper left corner, upper right corner, and lower left corner of the second-channel feature. Fill the lower right corner of the second-channel feature with 0;

[0068] After transforming the feature maps of the Y, U, and V channels of the candidate image through the Sobel operator and performing size scaling, obtain three edge maps, which are used as the upper left corner, upper right corner, and lower left corner of the second-channel feature. Take the pixel value with the largest amplitude at each position in the three edge maps as the lower right corner.

[0069] The component features of each candidate image can efficiently describe the component features corresponding to the candidate image.

[0070] S14. Identify the component types of each component to be measured according to the first feature vectors of the respective candidate images.

[0071] In at least one embodiment of the present invention, an AdaBoost classifier can be trained, and the AdaBoost classifier is used to identify the component types of each component to be measured according to the first feature vectors of the respective candidate images.

[0072] The first candidate image sample and the first label of the first candidate image sample can be obtained;

[0073] Extract the component features of the first candidate image sample based on the aggregated channel feature method to obtain the first feature vector sample of the first candidate image sample;

[0074] Use a decision tree as a weak classifier, take the first feature vector sample of the first candidate image sample as the input, and perform combined training on multiple weak classifiers according to the first label;

[0075] Perform weighted combination on the multiple weak classifiers to obtain a strong classifier applied to component type classification;

[0076] Identify the component types of each component to be measured according to the first feature vectors of the respective candidate images through the strong classifier.

[0077] In at least one embodiment of the present invention, the component types include: chip components, resistor components, capacitor components, etc.

[0078] S15. Judge whether the circuit board to be measured has a fault according to the component type and position information of each component to be measured, and output fault information when the circuit board to be measured has a fault.

[0079] In at least one embodiment of the present invention, determining whether there is a fault in the circuit board to be tested according to the component type and position information of each component to be tested includes:

[0080] Determining the number of components of each component type on the circuit board to be tested according to the component type of each component to be tested;

[0081] Obtaining the number of components of each component type on the standard circuit board and the standard positions of each component to be tested;

[0082] Judging whether the number of components of each given component type on the circuit board to be tested is less than the number of components of the given component type on the standard circuit board;

[0083] If the number of components of the given component type on the circuit board to be tested is less than the number of components of the given component type on the standard circuit board, determining that there is a component missing fault on the circuit board to be tested;

[0084] Judging whether the position information of each given component to be tested on the circuit board to be tested is consistent with the standard position of the given component to be tested on the standard circuit board;

[0085] If the position information of the given component to be tested on the circuit board to be tested is inconsistent with the standard position of the given component to be tested on the standard circuit board, there is a component collision fault on the circuit board to be tested.

[0086] In at least one embodiment of the present invention, if the number of components of the given component type on the circuit board to be tested is equal to the number of components of the given component type on the standard circuit board, and the position information of the given component to be tested on the circuit board to be tested is consistent with the standard position of the given component to be tested on the standard circuit board, it is determined that there is no fault on the circuit board to be tested.

[0087] In at least one embodiment of the present invention, the circuit board fault identification method further includes:

[0088] Identifying faulty components in each component to be tested according to each candidate image by using a support vector machine.

[0089] In at least one embodiment of the present invention, identifying faulty components in each component to be tested according to each candidate image by using a support vector machine includes:

[0090] Obtaining a plurality of second candidate image samples and second labels of each second candidate image sample;

[0091] Extracting second feature vectors of each second candidate image by using a local binary pattern algorithm;

[0092] Train a support vector machine classifier based on the second feature vectors of each second candidate image and the second labels of each second candidate image sample to obtain a trained support vector machine classifier;

[0093] Identify faulty components in each component to be tested through the trained support vector machine classifier.

[0094] Before identifying faulty components in each component to be tested through the trained support vector machine classifier, the circuit board fault identification method further includes:

[0095] Generate type vectors for each second candidate image sample according to the component types of each second candidate image sample;

[0096] Connect the second feature vectors and type vectors of each second candidate image sample to obtain the third feature vector of each second candidate image;

[0097] Train a support vector machine classifier based on the third feature vectors of each second candidate image and the second labels of each second candidate image sample to obtain a trained support vector machine classifier.

[0098] The support vector machine classifier can be trained with small samples, solving the problem of difficult sample collection, having good robustness, and high accuracy.

[0099] In at least one embodiment of the present invention, the classification types of the trained support vector machine classifier may include: normal components, damaged components, open solder components, residual glue components, etc.

[0100] In at least one embodiment of the present invention, the classification types of the trained support vector machine classifier may include: normal components, faulty components.

[0101] The average fault identification time of this method for a circuit board image with a resolution of 2448*2048 is 2.51 seconds, improving the efficiency of fault identification.

[0102] It can be seen from the above technical solutions that this method determines whether the circuit board to be tested has a fault according to the component types of each component to be tested and the position information of each component to be tested, which can improve the fault identification efficiency of the circuit board to be tested. In addition, this method can identify faulty components in each component to be tested through a support vector machine according to each candidate image, and can accurately identify the faulty components in the circuit board to be tested, improving the accuracy of identifying the faults of the circuit board to be tested.

[0103] Such as Figure 2As shown in the figure, it is a functional module diagram of a preferred embodiment of the circuit board fault identification device of the present invention. The circuit board fault identification device operates on an electronic device. The circuit board fault identification device 11 includes a first acquisition module 110, a marking module 111, a second acquisition module 112, an extraction module 113, an identification module 114, and a judgment module 115. The module referred to in the present invention means a series of computer program segments that can be acquired by a processor and can complete fixed functions, and are stored in a memory. In this embodiment, the functions of each module will be described in detail in subsequent embodiments.

[0104] The first acquisition module 110 is used to acquire an image of the circuit board to be tested, and the circuit board to be tested includes a plurality of components to be tested.

[0105] In at least one embodiment of the present invention, the image of the circuit board to be tested includes an image of the entire circuit board to be tested of the electronic device or an image of a partial circuit board to be tested of the electronic device.

[0106] In at least one embodiment of the present invention, the image of the circuit board to be tested is acquired by an industrial camera.

[0107] For example, an image of the entire circuit board to be tested can be taken by an industrial camera to obtain the image of the circuit board to be tested.

[0108] In at least one embodiment of the present invention, the motion control system can be used to control the industrial camera to take segmented pictures of the entire circuit board to be tested of the electronic device to obtain an image of a partial circuit board to be tested of the electronic device.

[0109] In at least one embodiment of the present invention, the industrial camera takes segmented pictures of the front and back of the entire circuit board to be tested of the electronic device to obtain an image of a partial circuit board to be tested of the electronic device.

[0110] The marking module 111 is used to perform image marking on the plurality of components to be tested in the image of the circuit board to be tested to obtain candidate images of each component to be tested.

[0111] In at least one embodiment of the present invention, the performing image marking on the plurality of components to be tested in the image of the circuit board to be tested includes:

[0112] Sliding a sliding window of different sizes on the image of the circuit board to be tested to intercept a plurality of sliding images;

[0113] Identifying each component to be tested from the plurality of sliding images by using a trained component identification model;

[0114] Label each identified component to be measured in the image of the circuit board to be measured, and obtain candidate images of each component to be measured. The component recognition model is a binary neural network.

[0115] In at least one embodiment of the present invention, the circuit board fault recognition device 11 further includes a training module 116, which is used to train the component recognition model before identifying each component to be measured from the multiple sliding images using the trained component recognition model.

[0116] The training of the component recognition model includes:

[0117] Obtain a component image sample, and there is a corresponding component image label for the component image sample;

[0118] Use the component image sample as an input, and calculate the recognition result of the component image sample through the component recognition model;

[0119] Based on the backpropagation algorithm, optimize the component recognition model according to the recognition result and the component image label to obtain a trained component recognition model.

[0120] When the component image sample is a complete component, the component image label corresponding to the component image sample is 1 (indicating that the component image sample is an image of a complete component); when the component image sample is not a complete component, the component image label corresponding to the component image sample is 0 (indicating that the component image sample is not an image of a complete component, or the component image sample is not an image of a component).

[0121] In at least one embodiment of the present invention, the circuit board fault recognition device 11 further includes a preprocessing module 117, which is used to preprocess and calibrate the image of the circuit board to be measured before performing image annotation on the multiple components to be measured in the image of the circuit board to be measured.

[0122] The second acquisition module 112 is used to obtain the position information of each component to be measured according to the candidate images of each component to be measured.

[0123] In at least one embodiment of the present invention, the obtaining the position information of each component to be measured according to the candidate images of each component to be measured includes:

[0124] Obtain the first pixel point at the upper left corner of each candidate image;

[0125] Determine the first coordinate of the first pixel point in the image of the circuit board to be measured;

[0126] Determine the first coordinate as the position information of the component to be measured corresponding to the candidate image.

[0127] In at least one embodiment of the present invention, obtaining the position information of each component to be measured according to the candidate images of each component to be measured includes:

[0128] Obtain the second pixel point at the center of each candidate image;

[0129] Determine the second coordinate of the second pixel point in the image of the circuit board to be measured;

[0130] Determine the second coordinate as the position information of the component to be measured corresponding to the candidate image.

[0131] The extraction module 113 is configured to extract the component features of each candidate image based on the aggregated channel feature method to obtain the first feature vector of each candidate image.

[0132] In at least one embodiment of the present invention, the aggregated channel feature method can superimpose various different features (such as color features, gradient features, and edge features) of each candidate image to form a unified feature.

[0133] In at least one embodiment of the present invention, extracting the component features of each candidate image based on the aggregated channel feature method includes:

[0134] Transform the candidate image into the YUV color space;

[0135] Determine the Y-channel feature of the candidate image as the first channel feature;

[0136] Reduce the feature maps of the Y, U, and V channels of the candidate image by half respectively, and use them as the upper left corner, upper right corner, and lower left corner of the second channel feature. Fill the lower right corner of the second channel feature with 0;

[0137] After the feature maps of the Y, U, and V channels of the candidate image are transformed by the Sobel operator and scaled in size, three edge maps are obtained and used as the upper left corner, upper right corner, and lower left corner of the second channel feature. Take the pixel value with the largest amplitude at each position in the three edge maps as the lower right corner.

[0138] The component features of each candidate image can efficiently describe the component features corresponding to the candidate image.

[0139] The recognition module 114 is configured to recognize the component types of each component to be measured according to the first feature vectors of each candidate image.

[0140] In at least one embodiment of the present invention, an AdaBoost classifier can be trained, and the AdaBoost classifier is used to recognize the component types of each component to be measured according to the first feature vectors of each candidate image.

[0141] The first candidate image sample and the first label of the first candidate image sample can be obtained;

[0142] Based on the aggregated channel features method, the component features of the first candidate image sample are extracted to obtain the first feature vector sample of the first candidate image sample;

[0143] Using a decision tree as a weak classifier, with the first feature vector sample of the first candidate image sample as the input, multiple weak classifiers are combined and trained according to the first label;

[0144] The multiple weak classifiers are weighted and combined to obtain a strong classifier for component type classification;

[0145] The component types of each component to be tested are identified by the strong classifier according to the first feature vector of each candidate image.

[0146] In at least one embodiment of the present invention, the component types include: chip components, resistor components, capacitor components, etc.

[0147] The judgment module 115 is configured to judge whether the circuit board to be tested has a fault according to the component type and position information of each component to be tested, and output fault information when the circuit board to be tested has a fault.

[0148] In at least one embodiment of the present invention, judging whether the circuit board to be tested has a fault according to the component type and position information of each component to be tested includes:

[0149] Determining the number of components of each component type on the circuit board to be tested according to the component type of each component to be tested;

[0150] Obtaining the number of components of each component type on the standard circuit board and the standard positions of each component to be tested;

[0151] Judging whether the number of components of each given component type on the circuit board to be tested is less than the number of components of the given component type on the standard circuit board;

[0152] If the number of components of the given component type on the circuit board to be tested is less than the number of components of the given component type on the standard circuit board, it is determined that the circuit board to be tested has a component missing fault;

[0153] Judging whether the position information of each given component to be tested on the circuit board to be tested is consistent with the standard position of the given component to be tested on the standard circuit board;

[0154] If the position information of the given component to be tested on the circuit board to be tested is inconsistent with the standard position of the given component to be tested on the standard circuit board, the circuit board to be tested has a component collision fault.

[0155] In at least one embodiment of the present invention, if the number of components of the given component type on the circuit board to be tested is equal to the number of components of the given component type on the standard circuit board, and the position information of the given component to be tested on the circuit board to be tested is consistent with the standard position of the given component to be tested on the standard circuit board, it is determined that there is no fault in the circuit board to be tested.

[0156] In at least one embodiment of the present invention, the recognition module 114 is further configured to identify faulty components in each component to be tested through a support vector machine according to each candidate image.

[0157] In at least one embodiment of the present invention, the step of identifying faulty components in each component to be tested through a support vector machine according to each candidate image includes:

[0158] Obtain a plurality of second candidate image samples and second labels of each second candidate image sample;

[0159] Extract second feature vectors of each second candidate image by using the local binary pattern algorithm;

[0160] Train a support vector machine classifier according to the second feature vectors of each second candidate image and the second labels of each second candidate image sample to obtain a trained support vector machine classifier;

[0161] Identify faulty components in each component to be tested through the trained support vector machine classifier.

[0162] The training module is further configured to generate type vectors of each second candidate image sample according to the component type of each second candidate image sample before identifying faulty components in each component to be tested through the trained support vector machine classifier;

[0163] Connect the second feature vectors and type vectors of each second candidate image sample to obtain third feature vectors of each second candidate image;

[0164] Train a support vector machine classifier according to the third feature vectors of each second candidate image and the second labels of each second candidate image sample to obtain a trained support vector machine classifier.

[0165] The support vector machine classifier can be trained with small samples, solves the problem of difficult sample collection, has good robustness, and high accuracy.

[0166] In at least one embodiment of the present invention, the classification types of the trained support vector machine classifier may include: normal components, damaged components, non-welded components, residual glue components, etc.

[0167] In at least one embodiment of the present invention, the classification types of the trained support vector machine classifier may include: normal components and faulty components.

[0168] The average fault recognition time of this device for a circuit board image with a resolution of 2448*2048 is 2.51 seconds, which improves the efficiency of fault recognition.

[0169] It can be seen from the above technical solutions that this device determines whether there is a fault in the circuit board according to the component types of each component to be tested and the position information of each component to be tested, which can improve the fault recognition efficiency of the circuit board. In addition, this device can identify the faulty components in each component to be tested according to each candidate image through a support vector machine, and can accurately identify the faulty components in the circuit board, improving the accuracy of identifying circuit board faults.

[0170] Such as Figure 3 shown, is a schematic structural diagram of an electronic device according to a preferred embodiment of the method for realizing circuit board fault recognition of the present invention.

[0171] In one embodiment of the present invention, the electronic device 1 includes, but is not limited to, a memory 12, a processor 13, and a computer program stored in the memory 12 and executable on the processor 13, such as a circuit board fault recognition program.

[0172] Those skilled in the art can understand that the schematic diagram is only an example of the electronic device 1, and does not constitute a limitation on the electronic device 1. It may include more or fewer components than shown, or combine some components, or different components. For example, the electronic device 1 may also include input / output devices, network access devices, buses, etc.

[0173] The processor 13 may be a central processing module (Central Processing Unit, CPU), or may also be other general-purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), field programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The processor 13 is the operation core and control center of the electronic device 1, connecting various parts of the entire electronic device 1 through various interfaces and lines, and obtaining the operating system of the electronic device 1 and various installed application programs, program codes, etc.

[0174] The processor 13 obtains the operating system of the electronic device 1 and various installed application programs. The processor 13 obtains the application programs to implement the steps in the embodiments of the above various circuit board fault identification methods, such as Figure 1 the steps shown.

[0175] Exemplarily, the computer program may be divided into one or more modules, and the one or more modules are stored in the memory 12 and obtained by the processor 13 to complete the present invention. The one or more modules may be a series of computer program instruction segments capable of performing specific functions, and the instruction segments are used to describe the obtaining process of the computer program in the electronic device 1. For example, the computer program may be divided into a first obtaining module 110, a marking module 111, a second obtaining module 112, an extracting module 113, an identifying module 114, and a judging module 115.

[0176] The memory 12 may be used to store the computer program and / or modules. The processor 13 realizes various functions of the electronic device 1 by running or obtaining the computer program and / or modules stored in the memory 12 and calling the data stored in the memory 12. The memory 12 may mainly include a program storage area and a data storage area. Among them, the program storage area may store an operating system, application programs required for at least one function (such as a sound playing function, an image playing function, etc.); the data storage area may store data created according to the use of the electronic device. In addition, the memory 12 may include non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a SmartMedia Card (SMC), a Secure Digital (SD) card, a Flash Card, at least one magnetic disk storage device, a flash memory device, or other non-volatile solid state storage devices.

[0177] The memory 12 may be an external memory and / or an internal memory of the electronic device 1. Further, the memory 12 may be a memory in a physical form, such as a memory stick, a TF card (Trans-flash Card), etc.

[0178] If the modules integrated in the electronic device 1 are implemented in the form of software functional modules and sold or used as independent products, they may be stored in a computer-readable storage medium. Based on such an understanding, to implement all or part of the processes in the above embodiments of the method of the present invention, it may also be completed by a computer program instructing relevant hardware. The computer program may be stored in a computer-readable storage medium, and when the computer program is obtained by the processor, the steps of the above various method embodiments may be implemented.

[0179] Among them, the computer program includes computer program code, which may be in the form of source code, object code, an obtainable file, or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a mobile hard disk, a magnetic disk, an optical disc, a computer memory, a read-only memory (ROM, Read-Only Memory).

[0180] Combined with Figure 1 , the memory 12 in the electronic device 1 stores multiple instructions to implement a circuit board fault identification method, and the processor 13 can obtain the multiple instructions to implement: obtaining the MAC values of multiple machine nodes; allocating ID addresses to the multiple machine nodes according to the MAC values of the multiple machine nodes; generating a machine node status table according to the MAC values of the multiple machine nodes and the ID addresses; sending heartbeat instructions to the multiple machine nodes according to the machine node status table; receiving heartbeat data packets returned by the multiple machine nodes in response to the heartbeat instructions; and determining the status of the multiple machine nodes according to the heartbeat data packets and the machine node status table.

[0181] Specifically, for the specific implementation method of the above instructions by the processor 13, reference may be made to Figure 1 the description of the relevant steps in the corresponding embodiment, which will not be elaborated here.

[0182] In several embodiments provided by the present invention, it should be understood that the disclosed system, device, and method can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the modules is only a logical function division, and there may be other division methods in actual implementation.

[0183] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical modules, that is, they may be located in one place, or may be distributed on multiple network modules. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0184] In addition, in each embodiment of the present invention, the functional modules can be integrated in a processing module, or each module can exist physically alone, or two or more modules can be integrated in one module. The above integrated modules can be implemented in the form of hardware, or in the form of a combination of hardware and software functional modules.

[0185] Therefore, in any regard, the embodiments should be regarded as exemplary and non-limiting. The scope of the present invention is defined by the appended claims rather than the above description. Accordingly, all changes that fall within the meaning and scope of the equivalent elements of the claims are intended to be embraced by the present invention. Any reference signs in the claims should not be construed as limiting the claims concerned.

[0186] In addition, it is obvious that the word "comprising" does not exclude other modules or steps, and the singular does not exclude the plural. The multiple modules or devices recited in the system claims may also be implemented by one module or device through software or hardware. The terms such as "second" are used to denote names and do not denote any particular order.

[0187] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit them. Although the present invention has been described in detail with reference to the preferred embodiments, those of ordinary skill in the art should understand that the technical solutions of the present invention can be modified or equivalently replaced without departing from the spirit and scope of the technical solutions of the present invention.

Claims

1. A circuit board fault identification method, which is applied to an electronic device, and is characterized in that The circuit board fault identification method includes: Obtain an image of the circuit board to be tested, where the circuit board to be tested includes multiple components to be tested; Perform image annotation on the multiple components to be tested in the image of the circuit board to be tested to obtain candidate images of each component to be tested; Obtain the position information of each component to be tested according to the candidate images of each component to be tested; Extract the component features of each candidate image based on the aggregated channel features method to obtain the first feature vector of each candidate image, including: superimposing the color feature, gradient feature, and edge feature of each candidate image through the aggregated channel features method; Identify the component type of each component to be tested according to the first feature vector of each candidate image; Judge whether the circuit board to be tested has a fault according to the component type and position information of each component to be tested, and output fault information when the circuit board to be tested has a fault; Identify the faulty components in each component to be tested through a support vector machine, including: obtaining multiple second candidate image samples and the second labels of each second candidate image sample; extracting the second feature vector of each second candidate image by using the local binary pattern algorithm; generating the type vector of each second candidate image sample according to the component type of each second candidate image sample; connecting the second feature vector and the type vector of each second candidate image sample to obtain the third feature vector of each second candidate image; training the support vector machine classifier according to the third feature vector of each second candidate image sample and the second labels of each second candidate image sample to obtain the trained support vector machine classifier; identifying the faulty components in each component to be tested through the trained support vector machine classifier.

2. The circuit board fault identification method according to claim 1, characterized in that The performing image annotation on the multiple components to be tested in the image of the circuit board to be tested includes: Slide a sliding window of different sizes on the image of the circuit board to be tested to intercept multiple sliding images; Identify each component to be tested from the multiple sliding images by using the trained component recognition model; Annotate each identified component to be tested in the image of the circuit board to be tested to obtain candidate images of each component to be tested.

3. The circuit board fault identification method according to claim 2, wherein, Further include training a component recognition model, where the training of the component recognition model includes: Obtain component image samples, where there are corresponding component image labels for the component image samples; Take the component image samples as input and calculate the recognition result of the component image samples through the component recognition model; Optimize the component recognition model based on the backpropagation algorithm according to the recognition result and the component image label to obtain the trained component recognition model.

4. The circuit board fault identification method according to claim 1, characterized in that The obtaining the position information of each component to be tested according to the candidate images of each component to be tested includes: Obtain the first pixel point at the upper left corner of each candidate image; Determine the first coordinate of the first pixel point in the image of the circuit board to be tested; Determine the first coordinate as the position information of the component to be tested corresponding to the candidate image.

5. The circuit board fault identification method according to claim 1, characterized in that, The judging whether the circuit board to be tested has a fault according to the component type and position information of each component to be tested includes: Determine the number of components of each component type on the circuit board under test according to the component type of each component under test; Obtain the number of components of each component type on the standard circuit board and the standard positions of each component under test; In response to the number of components of a component type on the circuit board under test being less than the number of components of the component type on the standard circuit board, determine that there is a component missing fault on the circuit board under test; and / or In response to the position information of the component under test on the circuit board under test being inconsistent with the standard position of the component under test on the standard circuit board, determine that there is a component collision fault on the circuit board under test.

6. A circuit board fault identification device, which runs on an electronic device, and the electronic device communicates with multiple machine nodes, characterized in that, The circuit board fault identification device includes: A first acquisition module, configured to acquire an image of the circuit board under test, where the circuit board under test includes a plurality of components under test; A labeling module, configured to perform image labeling on the plurality of components under test in the image of the circuit board under test to obtain candidate images of each component under test; A second acquisition module, configured to obtain the position information of each component under test according to the candidate images of each component under test; An extraction module, configured to extract component features of each candidate image based on the aggregated channel features method to obtain a first feature vector of each candidate image, including: superimposing the color feature, gradient feature, and edge feature of each candidate image through the aggregated channel features method; A first identification module, configured to identify the component type of each component under test according to the first feature vector of each candidate image; A judgment module, configured to judge whether there is a fault on the circuit board under test according to the component type and position information of each component under test, and output fault information when there is a fault on the circuit board under test; identify fault components in each component under test through a support vector machine, including: obtaining a plurality of second candidate image samples and second labels of each second candidate image sample; extracting second feature vectors of each second candidate image by using the local binary pattern algorithm; generating type vectors of each second candidate image sample according to the component type of each second candidate image sample; connecting the second feature vectors and type vectors of each second candidate image sample to obtain a third feature vector of each second candidate image; training a support vector machine classifier according to the third feature vector of each second candidate image sample and the second label of each second candidate image sample to obtain a trained support vector machine classifier; identifying fault components in each component under test through the trained support vector machine classifier.

7. An electronic device, characterized in that, The electronic device includes: A memory, storing at least one instruction; and A processor, obtaining the instruction stored in the memory to implement the circuit board fault identification method according to any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that: At least one instruction is stored in the computer-readable storage medium, and the at least one instruction is obtained by a processor in an electronic device to implement the circuit board fault identification method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • PCB component detection method based on deep learning

    CN110070536A