CN113822868A - Defect detection method, device, equipment and medium for light-emitting diode bracket - Google Patents

Defect detection method, device, equipment and medium for light-emitting diode bracket Download PDF

Info

Publication number
CN113822868A
CN113822868A CN202111129347.2A CN202111129347A CN113822868A CN 113822868 A CN113822868 A CN 113822868A CN 202111129347 A CN202111129347 A CN 202111129347A CN 113822868 A CN113822868 A CN 113822868A
Authority
CN
China
Prior art keywords
image
detected
area
defect
defect detection
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.)
Withdrawn
Application number
CN202111129347.2A
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 Sensetime Technology Co Ltd
Original Assignee
Shenzhen Sensetime 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 Sensetime Technology Co Ltd filed Critical Shenzhen Sensetime Technology Co Ltd
Priority to CN202111129347.2A priority Critical patent/CN113822868A/en
Publication of CN113822868A publication Critical patent/CN113822868A/en
Withdrawn legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0004Industrial image inspection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/20Image enhancement or restoration using local operators
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/70Denoising; Smoothing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/11Region-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20016Hierarchical, coarse-to-fine, multiscale or multiresolution image processing; Pyramid transform
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20024Filtering details
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20084Artificial neural networks [ANN]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30108Industrial image inspection

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • General Engineering & Computer Science (AREA)
  • Evolutionary Computation (AREA)
  • Computing Systems (AREA)
  • Biomedical Technology (AREA)
  • General Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • Biophysics (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Molecular Biology (AREA)
  • Health & Medical Sciences (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Evolutionary Biology (AREA)
  • Quality & Reliability (AREA)
  • Image Analysis (AREA)

Abstract

The disclosure relates to a method, an apparatus, a device and a medium for detecting defects of a light emitting diode bracket. The method comprises the following steps: acquiring an image to be detected of the light-emitting diode bracket; determining a key area in the image to be detected; determining a potential defect area in the image to be detected based on the key area; and carrying out defect detection on the potential defect area to obtain a defect detection result of the image to be detected.

Description

Defect detection method, device, equipment and medium for light-emitting diode bracket
Technical Field
The present disclosure relates to the field of image processing technologies, and in particular, to a method and an apparatus for detecting defects of a light emitting diode support, an electronic device, and a storage medium.
Background
The intelligent industrial quality inspection is an important problem in the field of computer vision and industrial quality inspection and an important development direction of industrial 4.0 technical strategy. The intelligent industrial quality inspection in the semiconductor industry is one of the important subjects of the intelligent industrial quality inspection.
Light Emitting Diode (LED) holders are typically molded from high precision silver plated copper sheets and high reflectivity EMC (Epoxy Molding Compound). If the appearance of the light-emitting diode bracket has defects, problems in the aspects of die bonding, wire bonding and the like of the light-emitting diode chip easily occur in the follow-up process. Therefore, the method has great significance for detecting the defects of the LED bracket.
Disclosure of Invention
The present disclosure provides a defect detection technical scheme for a light emitting diode bracket.
According to an aspect of the present disclosure, there is provided a method for detecting defects of a light emitting diode bracket, including:
acquiring an image to be detected of the light-emitting diode bracket;
determining a key area in the image to be detected;
determining a potential defect area in the image to be detected based on the key area;
and carrying out defect detection on the potential defect area to obtain a defect detection result of the image to be detected.
The method comprises the steps of obtaining an image to be detected of the light emitting diode support, determining a key area in the image to be detected, determining a potential defect area in the image to be detected based on the key area, and carrying out defect detection on the potential defect area to obtain a defect detection result of the image to be detected, so that the appearance defect of the light emitting diode support can be accurately detected.
In a possible implementation manner, after the acquiring an image to be detected of the led bracket and before the defect detecting the potential defect area, the method further includes:
and carrying out potential defect area detection on the image to be detected by adopting a pre-trained first neural network, and determining a potential defect area in the image to be detected.
In the implementation mode, the first neural network is adopted to detect the potential defect area of the image to be detected, so that the detection of the shallow scratch on the surface of the light-emitting diode support and the defect of the area outside the key area are facilitated, the potential defect area can be subjected to supplementary detection on the basis of obtaining the potential defect area based on the key area, and more potential defect areas are obtained. The defect detection result of the image to be detected is obtained by combining the potential defect area obtained by the first neural network detection and the potential defect area obtained by the key area analysis, so that the accuracy of the detection result of the appearance defect of the light-emitting diode bracket is improved.
In a possible implementation manner, the determining a critical area in the image to be detected includes:
acquiring a mask image corresponding to the light-emitting diode bracket;
and determining a key area in the image to be detected based on the mask image.
In the implementation mode, the key area in the image to be detected is determined by acquiring the mask image corresponding to the light emitting diode support and based on the mask image, so that the key area in the image to be detected can be determined quickly and accurately.
In a possible implementation manner, the determining, based on the mask image, a critical area in the image to be detected includes:
denoising the image to be detected to obtain a denoised image to be detected;
and matching the noise-reduced image to be detected with the mask image to obtain a key area in the image to be detected.
The potential defect area in the image to be detected is determined based on the key area determined by the implementation mode, and the accuracy of the determined potential defect area can be improved.
In a possible implementation manner, the performing noise reduction processing on the image to be detected to obtain a noise-reduced image to be detected includes:
and carrying out bilateral filtering processing and Gaussian filtering processing on the image to be detected to obtain the image to be detected after noise reduction.
In the implementation mode, the image to be detected is subjected to bilateral filtering processing and Gaussian filtering processing, so that the imaging noise and the interference of complex fine textures in the image to be detected can be removed.
In a possible implementation manner, the determining, based on the key region, a potential defect region in the image to be detected includes:
carrying out binarization on the key area to obtain a binarized image corresponding to the key area;
smoothing the binary image to obtain a smooth image corresponding to the key area;
determining connected regions in the smoothed image;
and determining a potential defect area in the image to be detected according to the connected area.
In the implementation mode, the key area is binarized to obtain a binarized image corresponding to the key area, the binarized image is smoothed to obtain a smoothed image corresponding to the key area, the connected area in the smoothed image is determined, and the potential defect area in the image to be detected is determined according to the connected area, so that the accuracy of determining the potential defect area in the image to be detected based on the key area can be improved.
In a possible implementation manner, the smoothing processing on the binarized image to obtain a smoothed image corresponding to the key region includes:
and smoothing the binary image by adopting a diamond filter to obtain a smooth image corresponding to the key area.
In the implementation mode, the filtering of the binary image is performed by adopting the diamond filter, so that the reduction of the burrs of the edges in the binary image is facilitated.
In a possible implementation manner, the determining, according to the connected region, a potential defect region in the image to be detected includes:
and in response to the fact that the size of any one connected region is larger than or equal to a first preset size, determining the connected region as a potential defect region in the image to be detected.
The realization mode screens the communicated regions according to the sizes, thereby being beneficial to reducing the influence of noise in the image to be detected on defect detection, and further improving the accuracy of determining the potential defect regions in the image to be detected based on the key regions.
In a possible implementation manner, the performing, by using a pre-trained first neural network, potential defect region detection on the image to be detected, and determining a potential defect region in the image to be detected includes:
enhancing the contrast of the image to be detected to obtain an image to be detected with enhanced contrast;
and detecting the defect area of the image to be detected with the enhanced contrast by adopting a pre-trained first neural network, and determining the potential defect area in the image to be detected.
The realization mode can increase the gray scale difference of the pixels of the image to be detected by enhancing the contrast of the image to be detected, thereby being beneficial to the first neural network to capture the defect characteristics in the image to be detected.
In a possible implementation manner, before the detecting the potential defect region of the image to be detected by using the pre-trained first neural network, the method further includes:
and training the first neural network by adopting a first training image set, wherein the training images in the first training image set comprise the labeling data of the defect area.
In this implementation, the first neural network is trained by employing a first set of training images with labeling data for the defect region, thereby enabling the first neural network to learn the ability to detect potential defect regions in the images.
In a possible implementation manner, the performing defect detection on the potential defect area to obtain a defect detection result of the image to be detected includes:
determining a union region of all the potential defect regions in the case that the number of the potential defect regions is more than two;
and carrying out defect detection on the union region to obtain a defect detection result of the image to be detected.
In this implementation manner, when the number of the potential defect areas is two or more, the union area of all the potential defect areas is determined, and the union area is subjected to defect detection to obtain the defect detection result of the image to be detected, so that the defect detection can be performed based on a more accurate area, and repeated detection of the same area can be reduced, thereby improving the accuracy and efficiency of the defect detection of the image to be detected
In a possible implementation manner, the performing defect detection on the union set region to obtain a defect detection result of the image to be detected includes:
under the condition that the size of the union set area is larger than a second preset size, cutting and/or size conversion are carried out on the union set area to obtain at least one image block;
and carrying out defect detection on the at least one image block to obtain a defect detection result of the image to be detected.
In this implementation manner, when the size of the union set region is larger than a second preset size, the union set region is cut and/or subjected to size conversion to obtain at least one image block, and the at least one image block is subjected to defect detection to obtain a defect detection result of the image to be detected, thereby facilitating improvement of accuracy of defect detection.
In a possible implementation manner, the performing defect detection on the at least one image block to obtain a defect detection result of the image to be detected includes:
performing defect detection on the at least one image block through a second neural network to obtain a defect detection result of the at least one image block;
and determining the defect detection result of the image to be detected according to the defect detection result of the at least one image block.
In the implementation mode, the defect detection is performed on the at least one image block through the second neural network to obtain the defect detection result of the at least one image block, and the defect detection result of the image to be detected is determined according to the defect detection result of the at least one image block, so that the speed and the accuracy of defect detection on the image to be detected can be improved.
According to an aspect of the present disclosure, there is provided a defect detecting apparatus of a light emitting diode support, including:
the acquisition module is used for acquiring an image to be detected of the light-emitting diode bracket;
the first determining module is used for determining a key area in the image to be detected;
the second determining module is used for determining a potential defect area in the image to be detected based on the key area;
and the defect detection module is used for carrying out defect detection on the potential defect area to obtain a defect detection result of the image to be detected.
In one possible implementation, the apparatus further includes:
and the third determining module is used for detecting the potential defect area of the image to be detected by adopting a pre-trained first neural network and determining the potential defect area in the image to be detected.
In one possible implementation manner, the first determining module is configured to:
acquiring a mask image corresponding to the light-emitting diode bracket;
and determining a key area in the image to be detected based on the mask image.
In one possible implementation manner, the first determining module is configured to:
denoising the image to be detected to obtain a denoised image to be detected;
and matching the noise-reduced image to be detected with the mask image to obtain a key area in the image to be detected.
In one possible implementation manner, the first determining module is configured to:
and carrying out bilateral filtering processing and Gaussian filtering processing on the image to be detected to obtain the image to be detected after noise reduction.
In one possible implementation manner, the second determining module is configured to:
carrying out binarization on the key area to obtain a binarized image corresponding to the key area;
smoothing the binary image to obtain a smooth image corresponding to the key area;
determining connected regions in the smoothed image;
and determining a potential defect area in the image to be detected according to the connected area.
In one possible implementation manner, the second determining module is configured to:
and smoothing the binary image by adopting a diamond filter to obtain a smooth image corresponding to the key area.
In a possible implementation manner, the second determining module is used for
And in response to the fact that the size of any one connected region is larger than or equal to a first preset size, determining the connected region as a potential defect region in the image to be detected.
In one possible implementation manner, the third determining module is configured to:
enhancing the contrast of the image to be detected to obtain an image to be detected with enhanced contrast;
and detecting the defect area of the image to be detected with the enhanced contrast by adopting a pre-trained first neural network, and determining the potential defect area in the image to be detected.
In one possible implementation, the apparatus further includes:
and the training module is used for training the first neural network by adopting a first training image set, wherein the training images in the first training image set comprise the labeling data of the defect area.
In one possible implementation, the defect detection module is configured to:
determining a union region of all the potential defect regions in the case that the number of the potential defect regions is more than two;
and carrying out defect detection on the union region to obtain a defect detection result of the image to be detected.
In one possible implementation, the defect detection module is configured to:
under the condition that the size of the union set area is larger than a second preset size, cutting and/or size conversion are carried out on the union set area to obtain at least one image block;
and carrying out defect detection on the at least one image block to obtain a defect detection result of the image to be detected.
In one possible implementation, the defect detection module is configured to:
performing defect detection on the at least one image block through a second neural network to obtain a defect detection result of the at least one image block;
and determining the defect detection result of the image to be detected according to the defect detection result of the at least one image block.
According to an aspect of the present disclosure, there is provided an electronic device including: one or more processors; a memory for storing executable instructions; wherein the one or more processors are configured to invoke the memory-stored executable instructions to perform the above-described method.
According to an aspect of the present disclosure, there is provided a computer readable storage medium having stored thereon computer program instructions which, when executed by a processor, implement the above-described method.
In the embodiment of the disclosure, a key area in an image to be detected is determined by obtaining the image to be detected of the light emitting diode support, a potential defect area in the image to be detected is determined based on the key area, and defect detection is performed on the potential defect area to obtain a defect detection result of the image to be detected, so that the appearance defect of the light emitting diode support can be accurately detected.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Other features and aspects of the present disclosure will become apparent from the following detailed description of exemplary embodiments, which proceeds with reference to the accompanying drawings.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the disclosure.
Fig. 1 shows a flowchart of a method for detecting defects of a light emitting diode bracket provided by an embodiment of the present disclosure.
Fig. 2 is a schematic diagram illustrating a mask image in a defect detection method for a light emitting diode bracket according to an embodiment of the present disclosure.
Fig. 3 is a schematic view illustrating an application scenario of the method for detecting defects of an led mount according to an embodiment of the present disclosure.
Fig. 4 shows another schematic diagram of an application scenario of the method for detecting defects of an led mount according to an embodiment of the present disclosure.
Fig. 5 shows a block diagram of a defect detection apparatus of a light emitting diode bracket provided by an embodiment of the present disclosure.
Fig. 6 illustrates a block diagram of an electronic device 800 provided by an embodiment of the disclosure.
Fig. 7 shows a block diagram of an electronic device 1900 provided by an embodiment of the disclosure.
Detailed Description
Various exemplary embodiments, features and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. In the drawings, like reference numbers can indicate functionally identical or similar elements. While the various aspects of the embodiments are presented in drawings, the drawings are not necessarily drawn to scale unless specifically indicated.
The word "exemplary" is used exclusively herein to mean "serving as an example, embodiment, or illustration. Any embodiment described herein as "exemplary" is not necessarily to be construed as preferred or advantageous over other embodiments.
The term "and/or" herein is merely an association describing an associated object, meaning that three relationships may exist, e.g., a and/or B, may mean: a exists alone, A and B exist simultaneously, and B exists alone. In addition, the term "at least one" herein means any one of a plurality or any combination of at least two of a plurality, for example, including at least one of A, B, C, and may mean including any one or more elements selected from the group consisting of A, B and C.
Furthermore, in the following detailed description, numerous specific details are set forth in order to provide a better understanding of the present disclosure. It will be understood by those skilled in the art that the present disclosure may be practiced without some of these specific details. In some instances, methods, means, elements and circuits that are well known to those skilled in the art have not been described in detail so as not to obscure the present disclosure.
The LED support is a bottom base of the LED lamp bead before packaging. For example, the light emitting diode bead can be fixed on the basis of the light emitting diode bracket, the positive and negative electrodes are welded, and then the light emitting diode bead is packaged and formed by packaging glue at one time.
In the related art, the following two methods are mainly adopted to judge whether the support of the light emitting diode has defects:
the first method is to visually inspect the led holder manually through a microscope. The method has low efficiency, and the accuracy of defect detection is difficult to guarantee.
The second method is to perform defect detection on the led support by using a conventional AOI (Automated Optical Inspection) device. Specifically, the AOI device scans the led mount to be detected to obtain an image of the led mount to be detected, and compares the image of the led mount to be detected with a defect sample image in a pre-constructed database to determine whether the led mount to be detected has a defect similar to the defect sample image in the database. Since the shapes of the defects of the led support are various and the material of the led support has high reflectivity, it is difficult to construct a complete database for defect matching, resulting in an undesirable effect of the method. That is, if there is no defect sample image containing a specific defect in the pre-constructed database, the specific defect cannot be detected by the AOI defect detection method.
The embodiment of the disclosure provides a defect detection method and device for a light emitting diode support, electronic equipment and a storage medium. Compared with a manual visual detection method in the related art, the defect detection scheme of the light emitting diode bracket provided by the embodiment of the disclosure has the advantages of higher reliability, more stable defect detection result, capability of reducing manual intervention and higher precision. Compared with the AOI defect detection method in the related art, the defect detection scheme of the light-emitting diode bracket provided by the embodiment of the disclosure has higher precision, can reduce the difficulty of constructing a sample image set, and can effectively detect a new defect form.
The following describes a method for detecting defects of a led mount according to an embodiment of the present disclosure in detail with reference to the accompanying drawings.
Fig. 1 shows a flowchart of a method for detecting defects of a light emitting diode bracket provided by an embodiment of the present disclosure. In a possible implementation manner, the method for detecting the defect of the led bracket may be performed by a terminal device or a server or other processing devices. The terminal device may be a User Equipment (UE), a mobile device, a User terminal, a cellular phone, a cordless phone, a Personal Digital Assistant (PDA), a handheld device, a computing device, a vehicle-mounted device, or a wearable device. In some possible implementations, the method for detecting the defect of the led bracket may be implemented by a processor calling a computer readable instruction stored in a memory. As shown in fig. 1, the method for detecting defects of led brackets includes steps S11 to S14.
In step S11, an image to be detected of the led mount is acquired.
In step S12, a key region in the image to be detected is determined.
In step S13, based on the key area, a potential defect area in the image to be detected is determined.
In step S14, defect detection is performed on the potential defect area to obtain a defect detection result of the to-be-detected image.
The led bracket may be a bracket of a direct-insertion led, a bracket of a piranha led, a bracket of a patch led, or a bracket of a high-power led, and is not limited herein.
In the embodiment of the present disclosure, the image to be detected may represent an image of the led mount to be detected. The image to be detected may be obtained by photographing the led support. For any light emitting diode bracket, image acquisition can be carried out from at least one angle to obtain at least one image to be detected of the light emitting diode. For example, the front and the back of the led mount may be photographed to obtain a front image and a back image of the led mount, and the front image and the back image of the led mount may be used as the images to be detected, respectively.
In the embodiments of the present disclosure, the critical area may represent an area that is critical to the product quality of the led support. For example, if defects occur in critical areas of the led mount, the led mount is likely to be scrapped.
In a possible implementation manner, the determining a critical area in the image to be detected includes: acquiring a mask image corresponding to the light-emitting diode bracket; and determining a key area in the image to be detected based on the mask image. In this implementation manner, the mask image corresponding to the led holder may represent a mask image of a model to which the led holder belongs. In this implementation, different mask images may be pre-designed for different models of led mounts. The mask image of any model of the LED support can comprise a mask area and a non-mask area, wherein the mask area is used for indicating the position information of the key area in the model of the LED support. Fig. 2 is a schematic diagram illustrating a mask image in a defect detection method for a light emitting diode bracket according to an embodiment of the present disclosure. In fig. 2, the white region is a masked region, and the black region is a non-masked region. In the left image of fig. 2, the mask region in the mask image includes a portion of the circular region inside the led support except for the support bridge; in the right drawing of fig. 2, the mask region in the mask image includes the main body region of the outer frame of the led holder. In the implementation mode, the key area in the image to be detected is determined by acquiring the mask image corresponding to the light emitting diode support and based on the mask image, so that the key area in the image to be detected can be determined quickly and accurately.
As an example of this implementation, the determining a critical area in the image to be detected based on the mask image includes: denoising the image to be detected to obtain a denoised image to be detected; and matching the noise-reduced image to be detected with the mask image to obtain a key area in the image to be detected. In this example, the noise-reduced image to be detected may be aligned with the mask image, and then an image area belonging to the mask area in the noise-reduced image to be detected may be extracted as a key area. The potential defect area in the image to be detected is determined based on the key area determined by the example, and the accuracy of the determined potential defect area can be improved.
In one example, the denoising processing on the image to be detected to obtain a denoised image to be detected includes: and carrying out bilateral filtering processing and Gaussian filtering processing on the image to be detected to obtain the image to be detected after noise reduction. For example, bilateral filtering processing and gaussian filtering processing may be sequentially performed on the image to be detected, so as to obtain the noise-reduced image to be detected. For another example, the image to be detected may be subjected to gaussian filtering processing and bilateral filtering processing in sequence to obtain the noise-reduced image to be detected. The filter parameters of bilateral filtering and gaussian filtering, such as the shape and size of the filter kernel, can be adjusted according to the appearance of the light emitting diode support, shooting noise and the like. In the above example, the image noise and the interference of the complex fine texture in the image to be detected can be removed by performing bilateral filtering processing and gaussian filtering processing on the image to be detected.
Of course, in other examples, the noise reduction processing may be performed on the image to be detected by using other noise reduction methods, which is not limited herein.
As another example of this implementation, the determining a critical area in the image to be detected based on the mask image includes: and matching the image to be detected with the mask image to obtain a key area in the image to be detected. In this example, the image to be detected may be aligned with the mask image, and then the image area belonging to the mask area in the aligned image to be detected may be extracted as the key area. In this example, before the image to be detected and the mask image are subjected to the matching processing, the image to be detected may not need to be subjected to the noise reduction processing.
In another possible implementation manner, the determining a critical area in the image to be detected includes: and detecting the key area of the image to be detected through a pre-trained third neural network to obtain the key area in the image to be detected. In this implementation, different third neural networks may be trained for different models of the led mount, respectively. For any model of LED support, a second training image set with labeled data of position information of key areas can be adopted to train a third neural network in advance.
In the disclosed embodiment, the potential defect area may represent an area where the possibility of the existence of a defect is high. The Region of potential defect may also be referred to as a Region of Interest (ROI).
In a possible implementation manner, the determining, based on the key region, a potential defect region in the image to be detected includes: carrying out binarization on the key area to obtain a binarized image corresponding to the key area; smoothing the binary image to obtain a smooth image corresponding to the key area; determining connected regions in the smoothed image; and determining a potential defect area in the image to be detected according to the connected area.
In this implementation, the key region is binarized, which may be to set the pixel values of the pixels in the key region to 0 and 255. For example, the pixel value of the pixel in the key region having the pixel value greater than or equal to the first preset threshold may be set to 255, and the pixel value of the pixel having the pixel value less than the first preset threshold may be set to 0. For example, the first preset threshold may be 128. Of course, a person skilled in the art can flexibly set the first preset threshold according to an actual application scenario (for example, the illumination intensity of a shooting scenario, the material of the led bracket, and the like), and is not limited herein.
Because the defects of the light emitting diode support are mainly scratches, and the light reflecting area of the scratches on the metal surface has a larger gray value, in the implementation mode, if the key area is binarized into 0 and 255, the connected area of the pixels with the median value of 255 in the smooth image can be determined, and then the potential defect area in the image to be detected is determined according to the connected area of the pixels with the median value of 255 in the smooth image.
In the implementation mode, the key area is binarized to obtain a binarized image corresponding to the key area, the binarized image is smoothed to obtain a smoothed image corresponding to the key area, the connected area in the smoothed image is determined, and the potential defect area in the image to be detected is determined according to the connected area, so that the accuracy of determining the potential defect area in the image to be detected based on the key area can be improved.
As an example of this implementation, the smoothing processing on the binarized image to obtain a smoothed image corresponding to the key region includes: and smoothing the binary image by adopting a diamond filter to obtain a smooth image corresponding to the key area. For example, the binarized image may be smoothed using a 4 × 4 diamond filter. Of course, a person skilled in the art may adjust the size of the diamond filter according to an empirical value of the size of the detected defect region of the model to which the led bracket belongs, which is not limited herein. In this example, filtering the binarized image with a diamond filter helps to reduce the edge glitch in the binarized image.
As another example of this implementation, the smoothing processing on the binarized image to obtain a smoothed image corresponding to the key region includes: and sequentially carrying out slight corrosion and slight expansion on the binary image to obtain a smooth image corresponding to the key area.
As another example of this implementation, the smoothing processing on the binarized image to obtain a smoothed image corresponding to the key region includes: and sequentially carrying out severe corrosion and severe expansion on the binary image to obtain a smooth image corresponding to the key area.
As another example of this implementation, the smoothing processing on the binarized image to obtain a smoothed image corresponding to the key region includes: and sequentially carrying out slight corrosion, severe expansion, severe corrosion and slight expansion on the binary image to obtain a smooth image corresponding to the key area.
As an example of this implementation, the determining, according to the connected region, a potential defect region in the image to be detected includes: and in response to the fact that the size of any one connected region is larger than or equal to a first preset size, determining the connected region as a potential defect region in the image to be detected. In this example, if the size of any connected region is greater than or equal to a first preset size, the connected region may be determined as a potential defect region in the image to be detected; if the duration of any connected region is less than the first preset size, the connected region may not be determined as a potential defect region in the image to be detected. For example, the first preset size may be 50 pixels. The example screens the connected regions according to the sizes, thereby being beneficial to reducing the influence of noise in the image to be detected on defect detection, and further improving the accuracy of determining the potential defect regions in the image to be detected based on the key regions.
In another possible implementation manner, the determining, based on the key region, a potential defect region in the image to be detected includes: smoothing the key area to obtain a smooth image corresponding to the key area; carrying out binarization on the smooth image to obtain a binarized image corresponding to the key area; determining a connected region in the binary image; and determining a potential defect area in the image to be detected according to the connected area. In this implementation, the key region may be smoothed first, and then the smoothed image may be binarized.
In another possible implementation manner, the determining, based on the key region, a potential defect region in the image to be detected includes: carrying out binarization on the key area to obtain a binarized image corresponding to the key area; determining a connected region in the binary image; and determining a potential defect area in the image to be detected according to the connected area. In this implementation, the smoothing process may not be performed.
In a possible implementation manner, after the acquiring an image to be detected of the led bracket and before the defect detecting the potential defect area, the method further includes: and carrying out potential defect area detection on the image to be detected by adopting a pre-trained first neural network, and determining a potential defect area in the image to be detected.
In this implementation, the first Neural network may be a Deep learning based Neural network, i.e., the first Neural network may be a Deep Neural Network (DNN). For example, the first neural network may adopt a fast-RCNN framework, use the ResNet-50 as a backbone network, and combine with FPN (Feature Pyramid Networks) to perform the detection of the potential defect region.
In the implementation mode, the first neural network is adopted to detect the potential defect area of the image to be detected, so that the detection of the shallow scratch on the surface of the light-emitting diode support and the defect of the area outside the key area are facilitated, the potential defect area can be subjected to supplementary detection on the basis of obtaining the potential defect area based on the key area, and more potential defect areas are obtained. The defect detection result of the image to be detected is obtained by combining the potential defect area obtained by the first neural network detection and the potential defect area obtained by the key area analysis, so that the accuracy of the detection result of the appearance defect of the light-emitting diode bracket is improved.
As an example of this implementation, the performing, by using a pre-trained first neural network, a potential defect region detection on the image to be detected to determine a potential defect region in the image to be detected includes: enhancing the contrast of the image to be detected to obtain an image to be detected with enhanced contrast; and detecting the defect area of the image to be detected with the enhanced contrast by adopting a pre-trained first neural network, and determining the potential defect area in the image to be detected. In this example, linear transformation, piecewise linear transformation, nonlinear transformation, etc. may be employed to enhance the contrast of the image to be detected. For example, the gray scale value range of the image to be detected is [30,230], and the gray scale value of the image to be detected can be mapped to the interval [0,255] to enhance the contrast of the image to be detected. By enhancing the contrast of the image to be detected, the gray level difference of pixels of the image to be detected can be increased, so that the first neural network is facilitated to capture the defect characteristics in the image to be detected.
Of course, in another example, the defect area detection may also be performed on the image to be detected directly through the first neural network without enhancing the contrast of the image to be detected, so as to determine the potential defect area in the image to be detected.
As an example of this implementation, before the performing, by using the pre-trained first neural network, the detection of the potential defect region on the image to be detected, the method further includes: and training the first neural network by adopting a first training image set, wherein the training images in the first training image set comprise the labeling data of the defect area. The label data of the defective area may indicate label data of position information of the defective area. For example, the label data of the defective area may be represented by position information of a rectangular frame. Of course, the defect area may have other shapes, and is not limited herein. In this example, the first neural network is trained by employing a first set of training images with labeling data for the defect regions, thereby enabling the first neural network to learn the ability to detect potential defect regions in the images. Wherein the training images in the first set of training images may be the same or different from the training images in the second set of training images above.
In the related art, an AOI defect detection method needs to construct a large and complete defect sample image database, and if a defect sample image containing a certain specific defect does not exist in the pre-constructed database, the specific defect cannot be detected by using the AOI defect detection method. In the above example, the first neural network is made to learn the ability to detect potential defect regions in which various defects (including new-morphology defects) in the image by constructing a first training image set with labeling data of the defect regions and training the first neural network using the first training image set. Therefore, compared with the AOI defect detection method in the related art, the above example can reduce the difficulty of constructing the sample image set, and can effectively detect a new defect form, thereby improving the precision of defect detection on the led mount.
In a possible implementation manner, the defect detection result of the image to be detected may include whether the image to be detected has a defect. For example, the defect detection result of the image to be detected may be that the image to be detected has no defect, or the defect detection result of the image to be detected may be that the image to be detected has a defect. In one example, if the image to be detected has no defects, the light emitting diode bracket corresponding to the image to be detected can be determined as a qualified product; if the image to be detected has defects, the light-emitting diode bracket corresponding to the image to be detected can be determined as an unqualified product.
In another possible implementation manner, the defect detection result of the image to be detected may include a defect category to which the image to be detected belongs. For example, the defect classes may include a first class, a second class, and a third class. If the image to be detected belongs to the first class, the defect of the first class of the light emitting diode support corresponding to the image to be detected can be represented; if the image to be detected belongs to the second category, the second type of defects of the light emitting diode support corresponding to the image to be detected can be represented; if the image to be detected belongs to the third category, the defect of the light-emitting diode support corresponding to the image to be detected does not exist. Of course, the number of defect categories may be more or less, and is not limited herein.
In a possible implementation manner, in the case that the image to be detected has a defect, the defect detection result of the image to be detected may further include position information of a defect area in the image to be detected. Of course, in another possible implementation manner, the defect detection result of the image to be detected may not include the position information of the defect area in the image to be detected.
In a possible implementation manner, the performing defect detection on the potential defect area to obtain a defect detection result of the image to be detected includes: determining a union region of all the potential defect regions in the case that the number of the potential defect regions is more than two; and carrying out defect detection on the union region to obtain a defect detection result of the image to be detected. In this implementation manner, when the number of the potential defect areas is more than two, a union area of all the potential defect areas is determined, and the union area is subjected to defect detection to obtain a defect detection result of the image to be detected, so that the defect detection can be performed based on a more accurate area, repeated detection of the same area can be reduced, and the accuracy and efficiency of the defect detection of the image to be detected can be improved.
As an example of this implementation manner, the performing defect detection on the union set region to obtain a defect detection result of the to-be-detected image includes: under the condition that the size of the union set area is larger than a second preset size, cutting and/or size conversion are carried out on the union set area to obtain at least one image block; and carrying out defect detection on the at least one image block to obtain a defect detection result of the image to be detected. In this example, in a case that the size of the union region is larger than a second preset size, the union region may be cropped and/or size-transformed so that the size of the obtained image block is smaller than or equal to the second preset size, for example, the sizes of the image blocks obtained by cropping and/or size-transformation may be both equal to the second preset size, for example, the second preset size is n × n. In one example, the union region may be cropped to an n × n image block, and the final region less than n × n size may be enlarged to an n × n size. In this example, when the size of the union set region is larger than a second preset size, the union set region is cut and/or subjected to size conversion to obtain at least one image block, and the at least one image block is subjected to defect detection to obtain a defect detection result of the image to be detected, thereby being beneficial to improving the accuracy of defect detection.
In an example, the performing defect detection on the at least one image block to obtain a defect detection result of the image to be detected includes: performing defect detection on the at least one image block through a second neural network to obtain a defect detection result of the at least one image block; and determining the defect detection result of the image to be detected according to the defect detection result of the at least one image block. Wherein the second neural network may be a deep learning based neural network, i.e. the second neural network may be a deep neural network. For example, a second neural network may employ ResNet-18. Wherein, the second neural network can be trained in advance in a supervised learning mode. In the above example, the defect detection result of the image to be detected may be determined to be defective in response to the defect detection result of any image block of the at least one image block being defective; and determining that the defect detection result of the image to be detected is defect-free in response to that the defect detection result of each image block in the at least one image block is defect-free. Or, determining that the defect detection result of the image to be detected is defective in response to that the number of image blocks with defects in the defect detection result is greater than or equal to a second preset threshold value in the at least one image block; and determining that the defect detection result of the image to be detected is defect-free in response to that the number of the image blocks with defects in the defect detection result is smaller than a second preset threshold value in the at least one image block. In the above example, the defect detection is performed on the at least one image block through the second neural network to obtain the defect detection result of the at least one image block, and the defect detection result of the image to be detected is determined according to the defect detection result of the at least one image block, so that the speed and the accuracy of defect detection on the image to be detected can be improved.
In one example, prior to the defect detection of the at least one image block by the second neural network, the method further comprises: and training the second neural network by adopting a third training image set, wherein the training images in the third training image set contain the labeling data of the defect detection result. For example, the labeling data of the defect detection result may be the presence or absence of a defect. Wherein the training images in the third training image set may be the same as or different from the training images in the first and second training image sets.
In the related art, an AOI defect detection method needs to construct a large and complete defect sample image database, and if a defect sample image containing a certain specific defect does not exist in the pre-constructed database, the specific defect cannot be detected by using the AOI defect detection method. In the above example, the second neural network can learn the ability to detect various defects (including new-morphology defects) in the image by constructing a third training image set with labeled data of the defect detection result and training the first neural network using the third training image set. Therefore, compared with the AOI defect detection method in the related art, the above example can reduce the difficulty of constructing the sample image set, and can effectively detect a new defect form, thereby improving the precision of defect detection on the led mount.
In another possible implementation manner, the performing defect detection on the potential defect area to obtain a defect detection result of the image to be detected includes: and under the condition that the number of the potential defect areas is more than two, respectively carrying out defect detection on each potential defect area in the more than two potential defect areas to obtain a defect detection result of the image to be detected. For example, the defect detection result of the image to be detected can be determined to be defective in response to the defect detection result of any potential defect area being defective; and determining that the defect detection result of the image to be detected is defect-free in response to that the defect detection result of each potential defect area is defect-free.
The defect detection method of the light-emitting diode support provided by the embodiment of the disclosure can be applied to the technical fields of computer vision, image processing, semiconductor industrial quality inspection, semiconductor defect detection, intelligent industrial quality inspection and the like, can automatically detect the appearance defects of the light-emitting diode support, reduces manual intervention, and improves the production efficiency and the product quality control.
The following describes a method for detecting defects of a led mount according to an embodiment of the present disclosure with a specific application scenario. Fig. 3 is a schematic view illustrating an application scenario of the method for detecting defects of an led mount according to an embodiment of the present disclosure. Fig. 4 shows another schematic diagram of an application scenario of the method for detecting defects of an led mount according to an embodiment of the present disclosure. In the application scene, an image to be detected of the light emitting diode support and a mask image corresponding to the light emitting diode support can be obtained firstly.
Bilateral filtering processing and Gaussian filtering processing can be carried out on the image to be detected, and the image to be detected after noise reduction is obtained. The image to be detected after noise reduction can be aligned with the mask image, and then the image area belonging to the mask area in the image to be detected after noise reduction after alignment is extracted as a key area. The pixel values of the pixels of the key area may be binarized into 0 and 255, so as to obtain a binarized image corresponding to the key area. The binarized image may be smoothed by using a 4 × 4 diamond filter to obtain a smoothed image corresponding to the key region. Connected regions in the smoothed image may be determined and the connected regions may be determined as potential defect regions in the image to be detected in response to a size of any connected region being greater than or equal to 50 pixels.
The contrast of the image to be detected can be enhanced to obtain an image to be detected with enhanced contrast, the image to be detected with enhanced contrast can be subjected to defect area detection by adopting a pre-trained first neural network, and a potential defect area in the image to be detected is determined.
In the case where the number of potential defect regions is two or more, a union region of all the potential defect regions may be determined. And under the condition that the size of the union set area is larger than a second preset size, performing clipping and/or size transformation on the union set area to obtain at least one image block. The defect detection of the at least one image block can be performed through a second neural network to obtain the defect detection result of the at least one image block, and the defect detection result of the image to be detected can be determined according to the defect detection result of the at least one image block.
It is understood that the above-mentioned method embodiments of the present disclosure can be combined with each other to form a combined embodiment without departing from the logic of the principle, which is limited by the space, and the detailed description of the present disclosure is omitted. Those skilled in the art will appreciate that in the above methods of the specific embodiments, the specific order of execution of the steps should be determined by their function and possibly their inherent logic.
In addition, the present disclosure also provides a defect detection apparatus for a light emitting diode bracket, an electronic device, a computer readable storage medium, and a program, which can be used to implement any one of the defect detection methods for a light emitting diode bracket provided by the present disclosure, and corresponding technical solutions and technical effects can be referred to in corresponding descriptions of the method sections and are not described again.
Fig. 5 shows a block diagram of a defect detection apparatus of a light emitting diode bracket provided by an embodiment of the present disclosure. As shown in fig. 5, the defect detecting apparatus of the led mount includes:
the acquiring module 51 is used for acquiring an image to be detected of the light emitting diode bracket;
a first determining module 52, configured to determine a key region in the image to be detected;
a second determining module 53, configured to determine a potential defect area in the image to be detected based on the key area;
and the defect detection module 54 is configured to perform defect detection on the potential defect area to obtain a defect detection result of the image to be detected.
In one possible implementation, the apparatus further includes:
and the third determining module is used for detecting the potential defect area of the image to be detected by adopting a pre-trained first neural network and determining the potential defect area in the image to be detected.
In one possible implementation, the first determining module 52 is configured to:
acquiring a mask image corresponding to the light-emitting diode bracket;
and determining a key area in the image to be detected based on the mask image.
In one possible implementation, the first determining module 52 is configured to:
denoising the image to be detected to obtain a denoised image to be detected;
and matching the noise-reduced image to be detected with the mask image to obtain a key area in the image to be detected.
In one possible implementation, the first determining module 52 is configured to:
and carrying out bilateral filtering processing and Gaussian filtering processing on the image to be detected to obtain the image to be detected after noise reduction.
In a possible implementation manner, the second determining module 53 is configured to:
carrying out binarization on the key area to obtain a binarized image corresponding to the key area;
smoothing the binary image to obtain a smooth image corresponding to the key area;
determining connected regions in the smoothed image;
and determining a potential defect area in the image to be detected according to the connected area.
In a possible implementation manner, the second determining module 53 is configured to:
and smoothing the binary image by adopting a diamond filter to obtain a smooth image corresponding to the key area.
In a possible implementation manner, the second determining module 53 is configured to
And in response to the fact that the size of any one connected region is larger than or equal to a first preset size, determining the connected region as a potential defect region in the image to be detected.
In one possible implementation manner, the third determining module is configured to:
enhancing the contrast of the image to be detected to obtain an image to be detected with enhanced contrast;
and detecting the defect area of the image to be detected with the enhanced contrast by adopting a pre-trained first neural network, and determining the potential defect area in the image to be detected.
In one possible implementation, the apparatus further includes:
and the training module is used for training the first neural network by adopting a first training image set, wherein the training images in the first training image set comprise the labeling data of the defect area.
In one possible implementation, the defect detection module 54 is configured to:
determining a union region of all the potential defect regions in the case that the number of the potential defect regions is more than two;
and carrying out defect detection on the union region to obtain a defect detection result of the image to be detected.
In one possible implementation, the defect detection module 54 is configured to:
under the condition that the size of the union set area is larger than a second preset size, cutting and/or size conversion are carried out on the union set area to obtain at least one image block;
and carrying out defect detection on the at least one image block to obtain a defect detection result of the image to be detected.
In one possible implementation, the defect detection module 54 is configured to:
performing defect detection on the at least one image block through a second neural network to obtain a defect detection result of the at least one image block;
and determining the defect detection result of the image to be detected according to the defect detection result of the at least one image block.
According to the method and the device for detecting the defects of the LED support, the key area in the image to be detected is determined by obtaining the image to be detected of the LED support, the potential defect area in the image to be detected is determined based on the key area, the potential defect area is detected, the defect detection result of the image to be detected is obtained, and therefore the appearance defects of the LED support can be accurately detected. Compared with a manual visual detection method in the related art, the defect detection scheme of the light emitting diode bracket provided by the embodiment of the disclosure has the advantages of higher reliability, more stable defect detection result, capability of reducing manual intervention and higher precision. Compared with the AOI defect detection method in the related art, the defect detection scheme of the light-emitting diode bracket provided by the embodiment of the disclosure has higher precision, can reduce the difficulty of constructing a sample image set, and can effectively detect a new defect form.
In some embodiments, functions or modules included in the apparatus provided in the embodiments of the present disclosure may be used to execute the method described in the above method embodiments, and specific implementations and technical effects thereof may refer to the description of the above method embodiments, which are not described herein again for brevity.
Embodiments of the present disclosure also provide a computer-readable storage medium having stored thereon computer program instructions, which when executed by a processor, implement the above-described method. The computer-readable storage medium may be a non-volatile computer-readable storage medium, or may be a volatile computer-readable storage medium.
Embodiments of the present disclosure also provide a computer program, which includes computer readable code, and when the computer readable code runs in an electronic device, a processor in the electronic device executes the above method.
The disclosed embodiments also provide a computer program product comprising computer readable code or a non-volatile computer readable storage medium carrying computer readable code, which when run in an electronic device, a processor in the electronic device performs the above method.
An embodiment of the present disclosure further provides an electronic device, including: one or more processors; a memory for storing executable instructions; wherein the one or more processors are configured to invoke the memory-stored executable instructions to perform the above-described method.
The electronic device may be provided as a terminal, server, or other form of device.
Fig. 6 illustrates a block diagram of an electronic device 800 provided by an embodiment of the disclosure. For example, the electronic device 800 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, or the like terminal.
Referring to fig. 6, electronic device 800 may include one or more of the following components: processing component 802, memory 804, power component 806, multimedia component 808, audio component 810, input/output (I/O) interface 812, sensor component 814, and communication component 816.
The processing component 802 generally controls overall operation of the electronic device 800, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing components 802 may include one or more processors 820 to execute instructions to perform all or a portion of the steps of the methods described above. Further, the processing component 802 can include one or more modules that facilitate interaction between the processing component 802 and other components. For example, the processing component 802 can include a multimedia module to facilitate interaction between the multimedia component 808 and the processing component 802.
The memory 804 is configured to store various types of data to support operations at the electronic device 800. Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 804 may be implemented by any type or combination of volatile or non-volatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
The power supply component 806 provides power to the various components of the electronic device 800. The power components 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the electronic device 800.
The multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and a user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front facing camera and/or a rear facing camera. The front camera and/or the rear camera may receive external multimedia data when the electronic device 800 is in an operation mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 810 is configured to output and/or input audio signals. For example, the audio component 810 includes a Microphone (MIC) configured to receive external audio signals when the electronic device 800 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may further be stored in the memory 804 or transmitted via the communication component 816. In some embodiments, audio component 810 also includes a speaker for outputting audio signals.
The I/O interface 812 provides an interface between the processing component 802 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor assembly 814 includes one or more sensors for providing various aspects of state assessment for the electronic device 800. For example, the sensor assembly 814 may detect an open/closed state of the electronic device 800, the relative positioning of components, such as a display and keypad of the electronic device 800, the sensor assembly 814 may also detect a change in the position of the electronic device 800 or a component of the electronic device 800, the presence or absence of user contact with the electronic device 800, orientation or acceleration/deceleration of the electronic device 800, and a change in the temperature of the electronic device 800. Sensor assembly 814 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 814 may also include a light sensor, such as a Complementary Metal Oxide Semiconductor (CMOS) or Charge Coupled Device (CCD) image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices. The electronic device 800 may access a wireless network based on a communication standard, such as a wireless network (Wi-Fi), a second generation mobile communication technology (2G), a third generation mobile communication technology (3G), a fourth generation mobile communication technology (4G)/long term evolution of universal mobile communication technology (LTE), a fifth generation mobile communication technology (5G), or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the electronic device 800 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic components for performing the above-described methods.
In an exemplary embodiment, a non-transitory computer-readable storage medium, such as the memory 804, is also provided that includes computer program instructions executable by the processor 820 of the electronic device 800 to perform the above-described methods.
Fig. 7 shows a block diagram of an electronic device 1900 provided by an embodiment of the disclosure. For example, the electronic device 1900 may be provided as a server. Referring to fig. 7, electronic device 1900 includes a processing component 1922 further including one or more processors and memory resources, represented by memory 1932, for storing instructions, e.g., applications, executable by processing component 1922. The application programs stored in memory 1932 may include one or more modules that each correspond to a set of instructions. Further, the processing component 1922 is configured to execute instructions to perform the above-described method.
The electronic device 1900 may also include a power component 1926 configured to perform power management of the electronic device 1900, a wired or wireless network interface 1950 configured to connect the electronic device 1900 to a network, and an input/output (I/O) interface 1958. The electronic device 1900 may operate based on an operating system, such as the Microsoft Server operating system (Windows Server), stored in the memory 1932TM) Apple Inc. of the present application based on the graphic user interface operating System (Mac OS X)TM) Multi-user, multi-process computer operating system (Unix)TM) Free and open native code Unix-like operating System (Linux)TM) Open native code Unix-like operating System (FreeBSD)TM) Or the like.
In an exemplary embodiment, a non-transitory computer readable storage medium, such as the memory 1932, is also provided that includes computer program instructions executable by the processing component 1922 of the electronic device 1900 to perform the above-described methods.
The present disclosure may be systems, methods, and/or computer program products. The computer program product may include a computer-readable storage medium having computer-readable program instructions embodied thereon for causing a processor to implement various aspects of the present disclosure.
The computer readable storage medium may be a tangible device that can hold and store the instructions for use by the instruction execution device. The computer readable storage medium may be, for example, but not limited to, an electronic memory device, a magnetic memory device, an optical memory device, an electromagnetic memory device, a semiconductor memory device, or any suitable combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium would include the following: 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), a Static Random Access Memory (SRAM), a portable compact disc read-only memory (CD-ROM), a Digital Versatile Disc (DVD), a memory stick, a floppy disk, a mechanical coding device, such as punch cards or in-groove projection structures having instructions stored thereon, and any suitable combination of the foregoing. Computer-readable storage media as used herein is not to be construed as transitory signals per se, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through a waveguide or other transmission medium (e.g., optical pulses through a fiber optic cable), or electrical signals transmitted through electrical wires.
The computer-readable program instructions described herein may be downloaded from a computer-readable storage medium to a respective computing/processing device, or to an external computer or external storage device via a network, such as the internet, a local area network, a wide area network, and/or a wireless network. The network may include copper transmission cables, fiber optic transmission, wireless transmission, routers, firewalls, switches, gateway computers and/or edge servers. The network adapter card or network interface in each computing/processing device receives computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in a computer-readable storage medium in the respective computing/processing device.
The computer program instructions for carrying out operations of the present disclosure may be assembler instructions, Instruction Set Architecture (ISA) instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source or object code written in any combination of one or more programming languages, including an object oriented programming language such as Smalltalk, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The computer-readable program instructions may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider). In some embodiments, the electronic circuitry that can execute the computer-readable program instructions implements aspects of the present disclosure by utilizing the state information of the computer-readable program instructions to personalize the electronic circuitry, such as a programmable logic circuit, a Field Programmable Gate Array (FPGA), or a Programmable Logic Array (PLA).
Various aspects of the present disclosure are described herein with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the disclosure. It will be understood that each block of the flowchart illustrations and/or block diagrams, and combinations of blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer-readable program instructions.
These computer-readable program instructions may be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions/acts specified in the flowchart and/or block diagram block or blocks. These computer-readable program instructions may also be stored in a computer-readable storage medium that can direct a computer, programmable data processing apparatus, and/or other devices to function in a particular manner, such that the computer-readable medium storing the instructions comprises an article of manufacture including instructions which implement the function/act specified in the flowchart and/or block diagram block or blocks.
The computer readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other devices to cause a series of operational steps to be performed on the computer, other programmable apparatus or other devices to produce a computer implemented process such that the instructions which execute on the computer, other programmable apparatus or other devices implement the functions/acts specified in the flowchart and/or block diagram block or blocks.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of instructions, which comprises one or more executable instructions for implementing the specified logical function(s). In some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The computer program product may be embodied in hardware, software or a combination thereof. In an alternative embodiment, the computer program product is embodied in a computer storage medium, and in another alternative embodiment, the computer program product is embodied in a Software product, such as a Software Development Kit (SDK), or the like.
Having described embodiments of the present disclosure, the foregoing description is intended to be exemplary, not exhaustive, and not limited to the disclosed embodiments. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The terminology used herein is chosen in order to best explain the principles of the embodiments, the practical application, or improvements made to the technology in the marketplace, or to enable others of ordinary skill in the art to understand the embodiments disclosed herein.

Claims (16)

1. A defect detection method of a light-emitting diode bracket is characterized by comprising the following steps:
acquiring an image to be detected of the light-emitting diode bracket;
determining a key area in the image to be detected;
determining a potential defect area in the image to be detected based on the key area;
and carrying out defect detection on the potential defect area to obtain a defect detection result of the image to be detected.
2. The method of claim 1, wherein after the obtaining of the image to be detected of the led support and before the defect detecting of the potential defect area, the method further comprises:
and carrying out potential defect area detection on the image to be detected by adopting a pre-trained first neural network, and determining a potential defect area in the image to be detected.
3. The method according to claim 1 or 2, wherein the determining the critical area in the image to be detected comprises:
acquiring a mask image corresponding to the light-emitting diode bracket;
and determining a key area in the image to be detected based on the mask image.
4. The method according to claim 3, wherein the determining a critical area in the image to be detected based on the mask image comprises:
denoising the image to be detected to obtain a denoised image to be detected;
and matching the noise-reduced image to be detected with the mask image to obtain a key area in the image to be detected.
5. The method according to claim 4, wherein the denoising the image to be detected to obtain a denoised image to be detected comprises:
and carrying out bilateral filtering processing and Gaussian filtering processing on the image to be detected to obtain the image to be detected after noise reduction.
6. The method according to any one of claims 1 to 5, wherein the determining potential defect areas in the image to be detected based on the key areas comprises:
carrying out binarization on the key area to obtain a binarized image corresponding to the key area;
smoothing the binary image to obtain a smooth image corresponding to the key area;
determining connected regions in the smoothed image;
and determining a potential defect area in the image to be detected according to the connected area.
7. The method according to claim 6, wherein the smoothing of the binarized image to obtain a smoothed image corresponding to the key region comprises:
and smoothing the binary image by adopting a diamond filter to obtain a smooth image corresponding to the key area.
8. The method according to claim 6 or 7, wherein the determining the potential defect area in the image to be detected according to the connected area comprises:
and in response to the fact that the size of any one connected region is larger than or equal to a first preset size, determining the connected region as a potential defect region in the image to be detected.
9. The method of claim 2, wherein the step of performing latent defect area detection on the image to be detected by using a pre-trained first neural network to determine a latent defect area in the image to be detected comprises:
enhancing the contrast of the image to be detected to obtain an image to be detected with enhanced contrast;
and detecting the defect area of the image to be detected with the enhanced contrast by adopting a pre-trained first neural network, and determining the potential defect area in the image to be detected.
10. The method according to claim 2 or 9, wherein before the detecting the potential defect region of the image to be detected by using the pre-trained first neural network, the method further comprises:
and training the first neural network by adopting a first training image set, wherein the training images in the first training image set comprise the labeling data of the defect area.
11. The method according to any one of claims 1 to 10, wherein the performing defect detection on the potential defect area to obtain a defect detection result of the image to be detected comprises:
determining a union region of all the potential defect regions in the case that the number of the potential defect regions is more than two;
and carrying out defect detection on the union region to obtain a defect detection result of the image to be detected.
12. The method according to claim 11, wherein the performing defect detection on the union region to obtain a defect detection result of the image to be detected comprises:
under the condition that the size of the union set area is larger than a second preset size, cutting and/or size conversion are carried out on the union set area to obtain at least one image block;
and carrying out defect detection on the at least one image block to obtain a defect detection result of the image to be detected.
13. The method according to claim 12, wherein the performing defect detection on the at least one image block to obtain a defect detection result of the image to be detected comprises:
performing defect detection on the at least one image block through a second neural network to obtain a defect detection result of the at least one image block;
and determining the defect detection result of the image to be detected according to the defect detection result of the at least one image block.
14. A defect detection device of a light-emitting diode bracket is characterized by comprising:
the acquisition module is used for acquiring an image to be detected of the light-emitting diode bracket;
the first determining module is used for determining a key area in the image to be detected;
the second determining module is used for determining a potential defect area in the image to be detected based on the key area;
and the defect detection module is used for carrying out defect detection on the potential defect area to obtain a defect detection result of the image to be detected.
15. An electronic device, comprising:
one or more processors;
a memory for storing executable instructions;
wherein the one or more processors are configured to invoke the memory-stored executable instructions to perform the method of any one of claims 1 to 13.
16. A computer readable storage medium having computer program instructions stored thereon, which when executed by a processor implement the method of any one of claims 1 to 13.
CN202111129347.2A 2021-09-26 2021-09-26 Defect detection method, device, equipment and medium for light-emitting diode bracket Withdrawn CN113822868A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111129347.2A CN113822868A (en) 2021-09-26 2021-09-26 Defect detection method, device, equipment and medium for light-emitting diode bracket

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111129347.2A CN113822868A (en) 2021-09-26 2021-09-26 Defect detection method, device, equipment and medium for light-emitting diode bracket

Publications (1)

Publication Number Publication Date
CN113822868A true CN113822868A (en) 2021-12-21

Family

ID=78921217

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111129347.2A Withdrawn CN113822868A (en) 2021-09-26 2021-09-26 Defect detection method, device, equipment and medium for light-emitting diode bracket

Country Status (1)

Country Link
CN (1) CN113822868A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117252876A (en) * 2023-11-17 2023-12-19 江西斯迈得半导体有限公司 LED support defect detection method and system

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117252876A (en) * 2023-11-17 2023-12-19 江西斯迈得半导体有限公司 LED support defect detection method and system
CN117252876B (en) * 2023-11-17 2024-02-09 江西斯迈得半导体有限公司 LED support defect detection method and system

Similar Documents

Publication Publication Date Title
CN112419328B (en) Image processing method and device, electronic equipment and storage medium
CN111553864B (en) Image restoration method and device, electronic equipment and storage medium
CN110889469B (en) Image processing method and device, electronic equipment and storage medium
KR102463101B1 (en) Image processing method and apparatus, electronic device and storage medium
CN109344832B (en) Image processing method and device, electronic equipment and storage medium
WO2023087741A1 (en) Defect detection method and apparatus, and electronic device, storage medium and computer program product
CN113344901B (en) Glue spreading defect detection method and device, storage medium and electronic equipment
EP3200125A1 (en) Fingerprint template input method and device
CN106127751B (en) Image detection method, device and system
CN112465843A (en) Image segmentation method and device, electronic equipment and storage medium
US20210326649A1 (en) Configuration method and apparatus for detector, storage medium
CN108009563B (en) Image processing method and device and terminal
CN111104920A (en) Video processing method and device, electronic equipment and storage medium
CN111126108A (en) Training method and device of image detection model and image detection method and device
CN114066858A (en) Model training method and device, electronic equipment and storage medium
WO2023050690A1 (en) Image processing method and apparatus, electronic device, storage medium, and program
CN113689361B (en) Image processing method and device, electronic equipment and storage medium
CN113313115B (en) License plate attribute identification method and device, electronic equipment and storage medium
CN113052874B (en) Target tracking method and device, electronic equipment and storage medium
CN113822868A (en) Defect detection method, device, equipment and medium for light-emitting diode bracket
CN114066856A (en) Model training method and device, electronic equipment and storage medium
CN113660531A (en) Video processing method and device, electronic equipment and storage medium
CN111582381A (en) Method and device for determining performance parameters, electronic equipment and storage medium
CN115082413A (en) Defect detection method and device, electronic equipment and storage medium
CN113781429A (en) Defect classification method and device for liquid crystal panel, electronic equipment and storage medium

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
WW01 Invention patent application withdrawn after publication

Application publication date: 20211221

WW01 Invention patent application withdrawn after publication