A vision-based fully automatic LCD detection method, device and equipment

By automatically calibrating and adjusting LCD images, determining the grayscale value range, and establishing a detection template, the problem of artificially setting detection templates in the prior art is solved, and a fully automatic LCD detection process is realized.

CN119006462BActive Publication Date: 2025-02-18SHENZHEN FOCUSVISION PHOTOELECTRIC TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202411482774.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-23
Publication Date
2025-02-18
Estimated Expiration
2044-10-23

AI Technical Summary

Technical Problem

The existing LCD detection methods require manual settings of detection templates and need to be set in advance for each different LCD model, resulting in the detection process not being automated.

Method used

By acquiring the indenter image and product image, determining the search area and pixel size, calibrating the product image, adjusting the image to determine the feature area, obtaining the grayscale value range of the detection area, establishing an automatic detection template, and performing fully automatic detection.

Benefits of technology

It realizes detection templates without artificially setting different models of LCDs. It can automatically generate detection templates based on the preset number of product images on the assembly line, realizing a fully automatic LCD detection process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119006462B_ABST
    Figure CN119006462B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of visual inspection technology, and in particular to a vision-based fully automatic LCD inspection method, device and equipment. The method comprises: acquiring a pressure head image and a first preset number of product images; determining a search area and a pixel size; for each product image, calibrating the product image according to the pixel size, and determining a feature area within the search area; adjusting the remaining calibrated product images based on the feature area of ​​the first calibrated product image; for each adjusted product image, determining a detection area, and acquiring the gray value of each pixel in the detection area; determining the gray value range of each pixel in the detection area; establishing a product detection template based on the feature area and the gray value range of each pixel in the detection area; and inspecting the product according to the detection template. The present invention solves the problem of manually setting a detection template in advance for each different LCD.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of visual inspection technology, and in particular to a vision-based full-automatic LCD inspection method, device and equipment. Background Art

[0002] Liquid crystal display, also known as LCD (Liquid Crystal Display), not only has many advantages such as high resolution, high brightness and no geometric deformation, but also has the characteristics of small size, light weight and low power consumption. Therefore, LCD is widely used in display fields such as digital cameras, digital video cameras, car displays, desktop displays, laptops and LCD TVs.

[0003] LCDs may have defects during the production process due to raw materials and technical reasons in the production process, such as foreign matter and surface scratches on the optical films. These defects will have a serious impact on the performance of the LCD. Therefore, it is necessary to detect defects in LCDs during the production process.

[0004] The current detection method is generally to perform detection through LCD visual inspection equipment. Before detection, it is still necessary to manually set the detection template. If the LCD model changes, the detection template needs to be manually set again. There is a problem that the detection template needs to be manually set in advance for each different LCD. Summary of the invention

[0005] Based on this, it is necessary to provide a vision-based fully automatic LCD detection method, device and equipment to address the above problems.

[0006] The embodiment of the present invention is implemented as follows: a vision-based fully automatic LCD detection method, the vision-based fully automatic LCD detection method comprising:

[0007] S101, acquiring an image of a pressing head and a first preset number of product images;

[0008] S102, determining a search area and a pixel size according to the indenter image;

[0009] S103, for each product image, calibrate the product image according to the pixel size, and determine the characteristic area of ​​the calibrated product image in the search area according to the pixel mutation of the calibrated product image;

[0010] S104, adjusting the remaining calibrated product images based on the feature area of ​​the first calibrated product image;

[0011] S105, for each adjusted product image, determining a detection area of ​​the adjusted product image, and obtaining a grayscale value of each pixel in the detection area;

[0012] S106, determining a grayscale value range of each pixel in the detection area according to all adjusted product images;

[0013] S107, establishing a product detection template according to the gray value range of each pixel in the feature area and the detection area;

[0014] S108, testing the product according to the testing template.

[0015] In one embodiment, the present invention provides a vision-based fully automatic LCD detection device, the vision-based fully automatic LCD detection device comprising:

[0016] An image acquisition module, used for acquiring an image of the pressing head and a first preset number of product images;

[0017] A size determination module, for determining a search area and a pixel size based on the indenter image;

[0018] A feature region determination module is used to calibrate each product image according to the pixel size, and determine the feature region of the calibrated product image according to the pixel mutation of the calibrated product image in the search area;

[0019] An image adjustment module, used to adjust the remaining calibrated product images based on the feature area of ​​the first calibrated product image;

[0020] A detection area determination module, used to determine the detection area of ​​each adjusted product image and obtain the gray value of each pixel in the detection area.

[0021] A grayscale value determination module, used to determine the grayscale value range of each pixel in the detection area according to all adjusted product images;

[0022] A template module is established to establish a product detection template according to the gray value range of each pixel in the feature area and the detection area;

[0023] The product detection module is used to detect products according to the detection template.

[0024] In one embodiment, the present invention provides a vision-based fully automatic LCD detection system, the vision-based fully automatic LCD detection system comprising: a power supply device, a feeding and transmission device, a pressing device, an image acquisition device, and a computer device;

[0025] The power supply device is used to provide power to the feeding and transmission device, the pressing device, the image acquisition device, the computer device and the product;

[0026] The feeding transmission device is in communication connection with the computer device and is used for transporting products;

[0027] The pressing device is in communication connection with the computer device, and is used to press the product after the product reaches the detection area so that the product and the power supply device are in full contact;

[0028] The image acquisition device is connected to the computer device and is used to acquire the image of the pressing head of the pressing device and the image of the product after the product reaches the inspection area;

[0029] The computer device is used to execute the steps of the above-mentioned vision-based fully automatic LCD detection method.

[0030] The embodiment of the present invention provides a vision-based fully automatic LCD detection method, which obtains a pressure head image and a first preset number of product images; determines a search area and a pixel size according to the pressure head image; calibrates the product image according to the pixel size for each product image, and determines the characteristic area of ​​the calibrated product image in the search area according to the pixel mutation of the calibrated product image; adjusts the remaining calibrated product images based on the characteristic area of ​​the first calibrated product image; determines the detection area of ​​the adjusted product image for each adjusted product image, and obtains the gray value of each pixel in the detection area; determines the gray value range of each pixel in the detection area according to all adjusted product images; establishes a product detection template according to the characteristic area and the gray value range of each pixel in the detection area; and detects the product according to the detection template. In this way, there is no need to manually set detection templates for different models of LCDs in advance, and the detection template of the product is automatically generated according to the product images of the preset number of products on the production line, and then the detection template of the corresponding product is determined by the characteristic area of ​​the product image, and finally the product is detected by the detection template, so as to achieve the purpose of fully automatic detection, and solve the problem of manually setting the detection template in advance for each different LCD. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] Figure 1 is a flow chart of a vision-based fully automatic LCD detection method in one embodiment;

[0032] Figure 2 This is the effect diagram of the indenter image;

[0033] Figure 3 An effect diagram showing the contents of the product image display area;

[0034] Figure 4Effect for product images Figure 1 ;

[0035] Figure 5 Effect for product images Figure 2 ;

[0036] Figure 6 The rendering is a rendering of the characteristic region of the calibrated product image determined within the search region;

[0037] Figure 7 is a structural block diagram of a vision-based fully automatic LCD detection device in one embodiment;

[0038] Figure 8 is a structural block diagram of a vision-based fully automatic LCD inspection system in one embodiment;

[0039] Fig. 9 FIG. 4 is a block diagram of the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0040] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.

[0041] It is understood that the terms "first", "second", etc. used in the present invention may be used herein to describe various elements, but unless otherwise specified, these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, a first xx script may be referred to as a second xx script, and similarly, a second xx script may be referred to as a first xx script without departing from the scope of the present invention.

[0042] like Figure 1 As shown, in one embodiment, a vision-based fully automatic LCD detection method is proposed, which may specifically include the following steps:

[0043] S101, acquiring an image of a pressing head and a first preset number of product images;

[0044] S102, determining a search area and a pixel size according to the indenter image;

[0045] S103, for each product image, calibrate the product image according to the pixel size, and determine the characteristic area of ​​the calibrated product image in the search area according to the pixel mutation of the calibrated product image;

[0046] S104, adjusting the remaining calibrated product images based on the feature area of ​​the first calibrated product image;

[0047] S105, for each adjusted product image, determining a detection area of ​​the adjusted product image, and obtaining a grayscale value of each pixel in the detection area;

[0048] S106, determining a grayscale value range of each pixel in the detection area according to all adjusted product images;

[0049] S107, establishing a product detection template according to the gray value range of each pixel in the feature area and the detection area;

[0050] S108, testing the product according to the testing template.

[0051] In this embodiment, both the image of the indenter and the image of the product are obtained through an image acquisition device. The image acquisition device is fixed at a certain position, for example, the image acquisition device is fixed on the product, and the product is photographed downward to obtain the product image. In the absence of the product, the indenter is pressed down to the working position, and the image obtained is the indenter image, such as Figure 2 As shown. If the product model has not changed, the indenter image does not need to be changed. The indenter image is mainly used to determine the search area and pixel size. The feature area of ​​the product image can only be found in the search area. The product refers to the LCD that needs to be tested. After the rated voltage of the product is input into the signal input area of ​​the product, the display area of ​​the product will display the relevant content. The content displayed in the display area of ​​the product is all the content that the product can display, such as Figure 3 As shown, Figure 3 and Figure 2 There is no necessary connection, but Figure 3 The content that a product can display. Figure 3 The text can be in black with white background or in white with black text.

[0052] In this embodiment, the pressure head image needs to be reacquired only when the pressure head changes. The pressure head will be replaced only when the signal input areas of different products are of different sizes. The pressure head image is acquired in advance, that is, the pressure head image is acquired before the product reaches the detection area.

[0053] In this embodiment, the first preset number of product images is used to establish modeling data for the product inspection template. In principle, the more the better, but if there are too many, it is difficult to ensure that all product images are good products, so the number needs to be controlled. Generally, the first preset number can be set to 5-10. It should be noted that the image acquisition device corresponding to the pressure head image and the image acquisition device of the product image are not necessarily the same. For example, the image acquisition device of the pressure head image shoots downward, while the image acquisition device of the product image shoots upward. It is just that the image acquisition devices are relative. Alternatively, the image acquisition device is the same, but the pressure head is transparent. When shooting the pressure head image, there is no backlight, so the outline of the pressure head can be captured. When shooting the product image, there is backlight, and the image of the signal input area of ​​the product appears, but the outline of the pressure head is not obvious. The product image of the product includes the image of the content displayed on the product display and the image of the signal input area of ​​the product. The image of the content displayed on the product display is as shown in the figure. Figure 4 As shown, the signal input area of ​​the product is as follows Figure 5 shown. Figure 5 Only the signal input area of ​​the product is displayed. Figure 6 Schematic diagram of the comparison between the image of the indenter and the image of the signal input area of ​​the product. It can be seen from the figure that the search area of ​​the indenter image is the signal input area of ​​the product. Figure 4 Only the images of the product's display are shown. Figure 5 Only the signal input area of ​​the product is displayed in the image, and the complete product image is Figure 4 and Figure 5 For the convenience of viewing, two pictures are identified here. Figure 4 and Figure 5 In an image, there is a clear distinction between the upper and lower parts. Generally, the upper part of the image is Figure 5 , the lower part is Figure 4 .

[0054] In this embodiment, the search area is essentially the area occupied by the pressure head when the pressure head is pressed down to the working position. The pixel size is the physical size of each pixel on the image, which is used to describe the resolution of the image.

[0055] In this embodiment, the product image is calibrated according to the pixel size in order to ensure that the resolution of the product image is always consistent with the resolution of the indenter image.

[0056] In this embodiment, the search area on the indenter image is the area occupied by the indenter when the indenter is pressed down to the working position, and on the calibrated product image it corresponds to the area of ​​the product's signal input area. There are pins and first pin identification points in the product's signal input area, and the feature area is determined between them.

[0057] In this embodiment, the characteristic area of ​​the calibrated product image is used as the positioning area, and all the calibrated product images are adjusted according to the positioning area so that each pixel of the calibrated product image is aligned.

[0058] In this embodiment, the detection area is essentially the display area of ​​the product at the location of the product image.

[0059] In this embodiment, after each pixel of the adjusted product image is aligned, the grayscale value of each pixel in the detection area is obtained, thereby determining the grayscale value range of each pixel in the detection area. Generally speaking, the grayscale values ​​of the same pixel in different product images are slightly different.

[0060] In this embodiment, each product corresponds to a detection template, and the identification of the product is based on the feature area. For the product corresponding to the product image used to establish the detection template, it can be determined whether the product is qualified when the detection template is established, or vice versa after the detection template is detected.

[0061] The embodiment of the present invention provides a vision-based fully automatic LCD detection method, which obtains a pressure head image and a first preset number of product images; determines a search area and a pixel size according to the pressure head image; calibrates the product image according to the pixel size for each product image, and determines the characteristic area of ​​the calibrated product image in the search area according to the pixel mutation of the calibrated product image; adjusts the remaining calibrated product images based on the characteristic area of ​​the first calibrated product image; determines the detection area of ​​the adjusted product image for each adjusted product image, and obtains the gray value of each pixel in the detection area; determines the gray value range of each pixel in the detection area according to all adjusted product images; establishes a product detection template according to the characteristic area and the gray value range of each pixel in the detection area; and detects the product according to the detection template. In this way, there is no need to manually set detection templates for different models of LCDs in advance, and the detection template of the product is automatically generated according to the product images of the preset number of products on the production line, and then the detection template of the corresponding product is determined by the characteristic area of ​​the product image, and finally the product is detected by the detection template, so as to achieve the purpose of fully automatic detection, and solve the problem of manually setting the detection template in advance for each different LCD.

[0062] In one embodiment, determining the search area and pixel size according to the indenter image includes:

[0063] S201, taking the direction from the midpoint pixels of the four sides of the indenter image to the center of the indenter image as the advancing direction, successively determining whether the difference in the grayscale value between two adjacent pixels in the advancing direction is less than a first preset value, and if so, recording the pixel relatively close to the center of the indenter image as the first pixel, and recording the first pixel as the first edge pixel;

[0064] S202, after determining the first first edge pixel, taking two perpendicular directions of the moving direction of the first edge pixel as second directions, determining whether there is a first pixel among a second preset number of adjacent pixels of the first edge pixel in the second direction, and if so, recording the first pixel as the first edge pixel;

[0065] S203, for a first edge pixel after the first first edge pixel, determine whether there is a first pixel among a second preset number of adjacent pixels of the first edge pixel in the second direction along the second direction in which the first edge pixel is determined, and if so, record the first pixel as the first edge pixel;

[0066] S204, repeating S203 until there is no first pixel among a second preset number of adjacent pixels of the first edge pixel in the second direction;

[0067] S205, determining a search area as an area surrounded by all first edge pixels;

[0068] S206, determining the pixel size according to the search area and the data of the indenter.

[0069] In this embodiment, the difference in grayscale values ​​between two adjacent pixels in the forward direction is obtained by subtracting the grayscale value of the pixel relatively far from the center of the indenter image from the grayscale value of the pixel relatively close to the center of the indenter image.

[0070] In this embodiment, if Figure 2 As shown in the figure, the indenter is a silver indenter, which appears white in the image. The image around the indenter appears black, and there is a sudden change in the pixels at the indenter. Therefore, the edge pixels can be judged by the difference in the grayscale values ​​of the pixels. The grayscale value of black pixels is 0, and the grayscale value of white pixels is 255. According to the advancing direction, the sudden change of edge pixels is from black to white, so the first preset value should be a negative number, which can be set to a value between -200 and -150.

[0071] In this embodiment, for any side of the indenter image, after the first first edge pixel is determined in S201, S201 is no longer performed, but S202 is performed. Except for the pixels on the edge of the indenter image, the other pixels along the forward direction have an adjacent pixel before and after, so except for the pixels on the edge of the indenter image, the other pixels along the forward direction may participate in two calculations, the first time as the minuend and the second time as the subtrahend.

[0072] In this embodiment, for example, for the top of the indenter image, the forward direction is downward, and the two second directions are left and right.

[0073] In this embodiment, the second preset number can be set to 3. For example, for the upper edge of the indenter image, the advancing direction is downward. After obtaining a first edge pixel, a 3*3 pixel frame is established with the first edge pixel as the center, and the three pixels on both sides of the pixel frame are judged respectively. If there is a first pixel, the first pixel is the first edge pixel. Therefore, it can be understood that S202-S204 can determine an edge of the search area.

[0074] In this embodiment, after obtaining four edges, an area surrounded by the four edges can be obtained and recorded as the search area, that is, the area surrounded by all the first edge pixels is determined as the search area.

[0075] In this embodiment, the data of the pressure head includes the length distance and the width distance of the pressure head.

[0076] In one embodiment, determining the pixel size according to the search area and the data of the indenter includes:

[0077] Determine the horizontal and vertical distances of the search area;

[0078] Determine the length and width of the pressure head according to the pressure head data;

[0079] Depend on Get the calibration value in the horizontal direction;

[0080] Depend on Get the calibration value in the vertical direction;

[0081] The average value of the calibration value in the horizontal direction and the calibration value in the vertical direction is determined as the pixel size;

[0082] Among them, a is the length distance of the indenter, X is the horizontal distance of the indenter image, x is the horizontal distance of the search area, p1 is the resolution of the image acquisition device in the horizontal distance, b is the width distance of the indenter, Y is the vertical distance of the indenter image, y is the vertical distance of the search area, and p2 is the resolution of the image acquisition device in the vertical distance.

[0083] In this embodiment, the horizontal distance and the vertical distance of the search area are the horizontal distance and the vertical distance of the indenter on the indenter image.

[0084] In this embodiment, the length distance and the width distance of the pressure head are distances obtained by actual measurement.

[0085] In this embodiment, is the horizontal resolution of the indenter image. Resolution refers to the total number of pixels in the horizontal and vertical directions of the image, usually expressed as Indicates. The calibration value is the length of each pixel. Theoretically, the calibration value in the horizontal direction is the same as the calibration value in the vertical direction, so the average of the calibration value in the horizontal direction and the calibration value in the vertical direction can also be directly set as the calibration value in the horizontal direction or the calibration value in the vertical direction. Therefore, the pixel size is also the length of each pixel.

[0086] In one embodiment, determining the characteristic region of the calibrated product image according to the pixel mutation of the calibrated product image in the search region includes:

[0087] Get the pixel interval corresponding to the search area;

[0088] Determine a corresponding pixel interval in the calibrated product image according to the pixel interval corresponding to the search area;

[0089] Obtaining the grayscale value of each pixel in the corresponding pixel interval in the calibrated product image;

[0090] For each pixel, determine whether the grayscale value of the pixel is greater than a second preset value, if so, record the pixel as a second pixel, if not, determine whether the grayscale value of the pixel is less than a third preset value;

[0091] If the grayscale value of the pixel is less than a third preset value, the pixel is recorded as a third pixel;

[0092] Recording a region composed of adjacent second pixels as a first region;

[0093] Recording the area formed by the adjacent third pixels as the second area;

[0094] A first region including a second region is determined, and a region consisting of the first region including the second region and the second region included therein is determined as a characteristic region of the calibrated product image.

[0095] In this embodiment, the pixel interval is used to determine the interval of the signal input area of ​​the product in the calibrated product image.

[0096] In this embodiment, if Figure 5As shown, the pixels of the signal input area in the calibrated product image are either black or white, so it is only necessary to distinguish these two types of pixels. The circled area in the figure is the second area included in the first area. The second preset value can be set to any integer value between 150 and 200. The third preset value can be set to any integer value between 100 and 150, and the third preset value can also be set to the same value as the second preset value.

[0097] In this embodiment, two pixels can be regarded as adjacent pixels if their vertices or edges touch each other. The region formed by the adjacent second pixels is recorded as the first region, and there are multiple first regions. Similarly, there are also multiple second regions.

[0098] In this embodiment, there are pins and first pin identification points in the signal input area of ​​the product, the pins are identified as the first area, and the first pin identification points are identified as the second area. Figure 5 As shown by the black dots in the circled area, only the first pin contains the first pin identification point, so the characteristic area is the area composed of the first pin and the first pin identification point in the signal input area of ​​the product. The first pin refers to the pin ranked 1. For different models of LCDs, the pin distribution in the signal input area of ​​the product is different, and the characteristic area is also different. Therefore, the model of the LCD is identified based on the characteristic area.

[0099] In one embodiment, adjusting the remaining calibrated product images based on the feature area of ​​the first calibrated product image includes:

[0100] For other calibrated product images except the first calibrated product image, determining a geometric change relationship between a feature region of the first calibrated product image and feature regions of the other calibrated product images;

[0101] The other calibrated product images are adjusted according to the geometric change relationship so that the other calibrated product images are registered with the first calibrated product image.

[0102] In this embodiment, the geometric change relationship includes rotation, scaling, translation, perspective transformation, affine transformation, projection transformation, three-dimensional space transformation, non-rigid transformation, etc. Determining the geometric change relationship between the feature area of ​​the first calibrated product image and the feature areas of the other calibrated product images is equal to determining how many degrees, how many times it is scaled, how much it is translated, etc., the feature area of ​​the first calibrated product image is rotated relative to the feature areas of the other calibrated product images.

[0103] In this embodiment, the purpose is to align the product images to avoid slight rotation or other geometric changes in the images. If the product has no defects, the grayscale value of each pixel in the display area of ​​the aligned product image will be within a range. If the grayscale value of a pixel is greatly different, then the pixel is a defect. Figure 6 The defect recognition is performed using the image, and the defect recognition is only performed within the detection area obtained in S105.

[0104] In one embodiment, determining the detection area of ​​the adjusted product image includes:

[0105] Determine the horizontal distance x of the search area and the length distance a of the pressure head;

[0106] Determine the vectors from the center point of the signal input area to the four vertices of the display area respectively according to the model information of the product corresponding to the product image;

[0107] Depend on Get the distance d from the center point of the search area to the four vertices of the detection area in the adjusted product image respectively i ;

[0108] According to d i The directions of the vectors of the four vertices determine the four vertices of the detection area in the adjusted product image;

[0109] Determine a rectangular area surrounded by four vertices as a detection area of ​​the adjusted product image;

[0110] Among them, D i is the size of the vector of the i-th vertex, and i is the sequence number of the vertex.

[0111] In this embodiment, equal , so the distances from the center point of the search area in the adjusted product image to the four vertices of the detection area can be determined.

[0112] In this embodiment, the model information of the product corresponding to the product image includes distance information of the signal input area, distance information of the display area, an angle from the top of the display area to the bottom of the signal input area, and the like.

[0113] In this embodiment, the magnitude of the vector is the distance from the center of the signal input area to the vertex of the display area. The direction of the vector is the angle between the center of the signal input area and the vertex of the display area, that is, the angle between the vertex of the display area and the bottom of the signal input area.

[0114] In this embodiment, after determining the model of the product, the model information of the product can be obtained by calculating the length and distance of the product. For the detection area (display area) of the LCD in the image, it is necessary to determine the specific position of the detection area (display area) of the LCD in the image, and the relative distance between this specific position and the signal input area and the relative distance between the two areas of the product should be proportional. This ratio is Since the display area is a rectangular area, the display area can be obtained by determining the four vertices of the rectangular area. The distance between each vertex and the midpoint of the signal input area can be obtained from the four vertices and the midpoint of the signal input area in the above figure, and the angle can be obtained by the tan formula.

[0115] In one embodiment, determining the grayscale value range of each pixel in the detection area according to all adjusted product images includes:

[0116] For each pixel in the detection area, obtaining the grayscale value of the pixel in all adjusted product images;

[0117] Determine whether there is an outlier in the grayscale value obtained by the pixel, and if so, discard all image data of the adjusted product image corresponding to the outlier;

[0118] The value obtained by subtracting the fourth preset value from the minimum value of the remaining grayscale values ​​is determined as the minimum value of the grayscale value range of the pixel, and the value obtained by adding the fourth preset value to the maximum value of the remaining grayscale values ​​is determined as the maximum value of the grayscale value range of the pixel.

[0119] In this embodiment, if the product image is not adjusted, a slight shift may occur, and the correspondence of such pixels may change, thereby causing an error in the process of determining the gray value range of the pixels.

[0120] In this embodiment, the position of each pixel is consistent in each adjusted product image, which can be specifically represented by rows and columns, such as the pixel in the first row and the first column. Normally, when there is no damage on the product surface, the grayscale value of each pixel in all adjusted product images is within the grayscale value range corresponding to the pixel.

[0121] In this embodiment, an outlier, also called an escape value, refers to a data point in a data set that has one or more values ​​that are significantly different from other values. After power is turned on, the product image will show all the display content, and the pixels of the display content are black, and the pixels of the background are white or a single gray color, so the grayscale value is very different. When the position corresponding to the pixel of the display content is damaged, the color of the pixel will become the same color as the background. Therefore, when an outlier appears in the grayscale value obtained by the pixel, it means that the adjusted product image corresponding to the pixel is a defective product. Defective products cannot be used as data for establishing a detection template and need to be excluded. Defective products that appear in the establishment of a detection template can be determined as unqualified for detection.

[0122] In one embodiment, the testing of the product according to the test template includes:

[0123] Determine characteristic regions of a product image of a product;

[0124] Identify the corresponding detection template according to the feature area of ​​the product image;

[0125] Determine a detection area of ​​a product image of a product;

[0126] It is determined whether each pixel in the detection area of ​​the product image of the product is within the grayscale value range of the corresponding pixel in the detection area of ​​the detection template. If so, the detection is qualified, otherwise, the detection is unqualified.

[0127] In this embodiment, after obtaining the detection template of the product, matching can be performed directly through the feature area of ​​the product image, so as to obtain the pixel gray value range of the detection area in the detection template of the product corresponding to the product image.

[0128] In this embodiment, a product that passes the test is a good product, and a product that fails the test is a defective product.

[0129] In this embodiment, if a product is replaced and the corresponding detection template is not identified, then the product is a new product and the step of establishing a detection template for the product will be performed first.

[0130] like Figure 7 As shown, in one embodiment, a vision-based fully automatic LCD detection device is provided, which may specifically include:

[0131] An image acquisition module, used for acquiring an image of the pressing head and a first preset number of product images;

[0132] A size determination module, for determining a search area and a pixel size based on the indenter image;

[0133] A feature region determination module is used to calibrate each product image according to the pixel size, and determine the feature region of the calibrated product image according to the pixel mutation of the calibrated product image in the search area;

[0134] An image adjustment module, used to adjust the remaining calibrated product images based on the feature area of ​​the first calibrated product image;

[0135] A detection area determination module, used to determine the detection area of ​​each adjusted product image and obtain the gray value of each pixel in the detection area.

[0136] A grayscale value determination module, used to determine the grayscale value range of each pixel in the detection area according to all adjusted product images;

[0137] A template module is established to establish a product detection template according to the gray value range of each pixel in the feature area and the detection area;

[0138] The product detection module is used to detect products according to the detection template.

[0139] In this embodiment, the various modules of the vision-based fully automatic LCD detection device are modularized in the method part of the present invention. For the specific explanation of each module, please refer to the corresponding content of the method part of the present invention, and the embodiment of the present invention will not be repeated here.

[0140] like Figure 8 As shown, in one embodiment, a vision-based fully automatic LCD inspection system is provided, which may specifically include: a power supply device, a feeding and transmission device, a pressing device, an image acquisition device, and a computer device;

[0141] The power supply device is used to provide power to the feeding and transmission device, the pressing device, the image acquisition device, the computer device and the product;

[0142] The feeding transmission device is in communication connection with the computer device and is used for transporting products;

[0143] The pressing device is in communication connection with the computer device, and is used to press the product after the product reaches the detection area so that the product and the power supply device are in full contact;

[0144] The image acquisition device is connected to the computer device and is used to acquire the image of the pressing head of the pressing device and the image of the product after the product reaches the inspection area;

[0145] The computer device is used to execute the steps of the above-mentioned vision-based fully automatic LCD detection method.

[0146] In this embodiment, the pressing device includes a pressing head and a pressing head control module. The pressing head is used to press the product after the product reaches the detection area so that the product and the power supply device are in full contact. The pressing head control module is connected to the computer device for communication and fixedly connected to the pressing head, and is used to control the action of the pressing head according to the instructions of the computer device.

[0147] In this embodiment, there may be several image acquisition devices. Generally speaking, one image acquisition device is fixed when acquiring images.

[0148] The embodiment of the present invention provides a vision-based fully automatic LCD detection method, which obtains a pressure head image and a first preset number of product images; determines a search area and a pixel size according to the pressure head image; calibrates the product image according to the pixel size for each product image, and determines the characteristic area of ​​the calibrated product image in the search area according to the pixel mutation of the calibrated product image; adjusts the remaining calibrated product images based on the characteristic area of ​​the first calibrated product image; determines the detection area of ​​the adjusted product image for each adjusted product image, and obtains the gray value of each pixel in the detection area; determines the gray value range of each pixel in the detection area according to all adjusted product images; establishes a product detection template according to the characteristic area and the gray value range of each pixel in the detection area; and detects the product according to the detection template. In this way, there is no need to manually set detection templates for different models of LCDs in advance, and the detection template of the product is automatically generated according to the product images of the preset number of products on the production line, and then the detection template of the corresponding product is determined by the characteristic area of ​​the product image, and finally the product is detected by the detection template, so as to achieve the purpose of fully automatic detection, and solve the problem of manually setting the detection template in advance for each different LCD.

[0149] Fig. 9 FIG. 2 shows an internal structure diagram of a computer device in one embodiment. Fig. 9As shown, the computer device includes a processor, a memory, a network interface, an input device and a display screen connected through a system bus. Among them, the memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium of the computer device stores an operating system and may also store a computer program. When the computer program is executed by the processor, the processor can implement a vision-based fully automatic LCD detection method provided by an embodiment of the present invention. The internal memory may also store a computer program. When the computer program is executed by the processor, the processor can execute a vision-based fully automatic LCD detection method provided by an embodiment of the present invention. The display screen of the computer device may be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device may be a touch layer covered on the display screen, or a button, trackball or touchpad provided on the computer device housing, or an external keyboard, touchpad or mouse, etc.

[0150] Those skilled in the art will understand that Fig. 9 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present invention, and does not constitute a limitation on the computer device to which the solution of the present invention is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0151] In one embodiment, a vision-based fully automatic LCD detection device provided by the embodiment of the present invention can be implemented in the form of a computer program. The computer program can be used in Fig. 9 The computer device shown in the figure is run on the computer device. The memory of the computer device can store various program modules constituting the vision-based fully automatic LCD detection device, such as, Figure 7 The computer program composed of the image acquisition module, size determination module, feature area determination module, image adjustment module, detection area determination module, gray value determination module, template establishment module and product detection module shown in the figure enables the processor to execute the steps of a vision-based fully automatic LCD detection method of each embodiment of the present invention described in this specification.

[0152] For example, Fig. 9 The computer device shown can be Figure 7In the vision-based fully automatic LCD detection device shown, the image acquisition module executes step S101; the computer device can execute step S102 through the size determination module; the computer device can execute step S103 through the feature area determination module; the computer device can execute step S104 through the image adjustment module; the computer device can execute step S105 through the detection area determination module; the computer device can execute step S106 through the gray value determination module; the computer device can execute step S107 through the template establishment module; the computer device can execute step S108 through the product detection module.

[0153] In one embodiment, a computer device is provided, the computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the following steps are implemented:

[0154] S101, acquiring an image of a pressing head and a first preset number of product images;

[0155] S102, determining a search area and a pixel size according to the indenter image;

[0156] S103, for each product image, calibrate the product image according to the pixel size, and determine the characteristic area of ​​the calibrated product image in the search area according to the pixel mutation of the calibrated product image;

[0157] S104, adjusting the remaining calibrated product images based on the feature area of ​​the first calibrated product image;

[0158] S105, for each adjusted product image, determining a detection area of ​​the adjusted product image, and obtaining a grayscale value of each pixel in the detection area;

[0159] S106, determining a grayscale value range of each pixel in the detection area according to all adjusted product images;

[0160] S107, establishing a product detection template according to the gray value range of each pixel in the feature area and the detection area;

[0161] S108, testing the product according to the testing template.

[0162] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the processor performs the following steps:

[0163] S101, acquiring an image of a pressing head and a first preset number of product images;

[0164] S102, determining a search area and a pixel size according to the indenter image;

[0165] S103, for each product image, calibrate the product image according to the pixel size, and determine the characteristic area of ​​the calibrated product image in the search area according to the pixel mutation of the calibrated product image;

[0166] S104, adjusting the remaining calibrated product images based on the feature area of ​​the first calibrated product image;

[0167] S105, for each adjusted product image, determining a detection area of ​​the adjusted product image, and obtaining a grayscale value of each pixel in the detection area;

[0168] S106, determining a grayscale value range of each pixel in the detection area according to all adjusted product images;

[0169] S107, establishing a product detection template according to the gray value range of each pixel in the feature area and the detection area;

[0170] S108, testing the product according to the testing template.

[0171] It should be understood that, although each step in the flow chart of each embodiment of the present invention is shown in sequence according to the indication of the arrow, these steps are not necessarily performed in sequence according to the order indicated by the arrow. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be performed in other orders. Moreover, at least a portion of the steps in each embodiment may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these sub-steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of other steps or sub-steps or stages of other steps.

[0172] A person of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a computer program, and the program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided by the present invention can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

[0173] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0174] The above-mentioned embodiments only express several implementation methods of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the present invention. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention.

Claims

1. A vision-based fully automatic LCD detection method, characterized in that: The vision-based fully automatic LCD detection method includes: S101, acquiring an image of a pressing head and a first preset number of product images; S102, determining a search area and a pixel size according to the indenter image; S103, for each product image, calibrate the product image according to the pixel size, and determine the characteristic area of ​​the calibrated product image in the search area according to the pixel mutation of the calibrated product image; S104, adjusting the remaining calibrated product images based on the feature area of ​​the first calibrated product image; S105, for each adjusted product image, determining a detection area of ​​the adjusted product image, and obtaining a grayscale value of each pixel in the detection area; S106, determining a grayscale value range of each pixel in the detection area according to all adjusted product images; S107, establishing a product detection template according to the gray value range of each pixel in the feature area and the detection area; S108, testing the product according to the testing template; Determining the search area and pixel size according to the indenter image includes: S201, taking the direction from the midpoint pixels of the four sides of the indenter image to the center of the indenter image as the advancing direction, successively determining whether the difference in the grayscale value between two adjacent pixels in the advancing direction is less than a first preset value, and if so, recording the pixel relatively close to the center of the indenter image as the first pixel, and recording the first pixel as the first edge pixel; S202, after determining the first first edge pixel, taking two perpendicular directions of the moving direction of the first edge pixel as second directions, determining whether there is a first pixel among a second preset number of adjacent pixels of the first edge pixel in the second direction, and if so, recording the first pixel as the first edge pixel; S203, for a first edge pixel after the first first edge pixel, determine whether there is a first pixel among a second preset number of adjacent pixels of the first edge pixel in the second direction along the second direction in which the first edge pixel is determined, and if so, record the first pixel as the first edge pixel; S204, repeating S203 until there is no first pixel among a second preset number of adjacent pixels of the first edge pixel in the second direction; S205, determining a search area as an area surrounded by all first edge pixels; S206, determining the pixel size according to the search area and the data of the indenter; The step of determining the pixel size according to the search area and the data of the indenter includes: Determine the horizontal and vertical distances of the search area; Determine the length and width of the pressure head according to the pressure head data; Depend on Get the calibration value in the horizontal direction; Depend on Get the calibration value in the vertical direction; The average value of the calibration value in the horizontal direction and the calibration value in the vertical direction is determined as the pixel size; Among them, a is the length distance of the indenter, X is the horizontal distance of the indenter image, x is the horizontal distance of the search area, p1 is the resolution of the image acquisition device in the horizontal distance, b is the width distance of the indenter, Y is the vertical distance of the indenter image, y is the vertical distance of the search area, and p2 is the resolution of the image acquisition device in the vertical distance.

2. The vision-based fully automatic LCD detection method according to claim 1, characterized in that: The step of determining the characteristic region of the calibrated product image according to the pixel mutation of the calibrated product image in the search region includes: Get the pixel interval corresponding to the search area; Determine a corresponding pixel interval in the calibrated product image according to the pixel interval corresponding to the search area; Obtaining the grayscale value of each pixel in the corresponding pixel interval in the calibrated product image; For each pixel, determine whether the grayscale value of the pixel is greater than a second preset value, if so, record the pixel as a second pixel, if not, determine whether the grayscale value of the pixel is less than a third preset value; If the grayscale value of the pixel is less than a third preset value, the pixel is recorded as a third pixel; Recording a region composed of adjacent second pixels as a first region; Recording the area formed by the adjacent third pixels as the second area; A first region including a second region is determined, and a region consisting of the first region including the second region and the second region included therein is determined as a characteristic region of the calibrated product image.

3. The vision-based fully automatic LCD detection method according to claim 1, characterized in that: The adjusting the remaining calibrated product images based on the feature area of ​​the first calibrated product image includes: For other calibrated product images except the first calibrated product image, determining a geometric change relationship between a feature region of the first calibrated product image and feature regions of the other calibrated product images; The other calibrated product images are adjusted according to the geometric change relationship so that the other calibrated product images are registered with the first calibrated product image.

4. The vision-based fully automatic LCD detection method according to claim 1, characterized in that: The determining the detection area of ​​the adjusted product image includes: Determine the horizontal distance x of the search area and the length distance a of the pressure head; Determine the vectors from the center point of the signal input area to the four vertices of the display area respectively according to the model information of the product corresponding to the product image; Depend on Get the distance d from the center point of the search area to the four vertices of the detection area in the adjusted product image respectively i ; According to d i The directions of the vectors of the four vertices determine the four vertices of the detection area in the adjusted product image; Determine a rectangular area surrounded by four vertices as a detection area of ​​the adjusted product image; Among them, D i is the size of the vector of the i-th vertex, and i is the sequence number of the vertex.

5. The vision-based fully automatic LCD detection method according to claim 1, characterized in that: Determining the grayscale value range of each pixel in the detection area according to all adjusted product images includes: For each pixel in the detection area, obtaining the grayscale value of the pixel in all adjusted product images; Determine whether there is an outlier in the grayscale value obtained by the pixel, and if so, discard all image data of the adjusted product image corresponding to the outlier; The value obtained by subtracting the fourth preset value from the minimum value of the remaining grayscale values ​​is determined as the minimum value of the grayscale value range of the pixel, and the value obtained by adding the fourth preset value to the maximum value of the remaining grayscale values ​​is determined as the maximum value of the grayscale value range of the pixel.

6. The vision-based fully automatic LCD detection method according to claim 1, characterized in that: The testing of the product according to the testing template includes: Determine characteristic areas of a product image of a product; Identify the corresponding detection template according to the feature area of ​​the product image; Determine a detection area of ​​a product image of a product; It is determined whether each pixel in the detection area of ​​the product image of the product is within the grayscale value range of the corresponding pixel in the detection area of ​​the detection template. If so, the detection is qualified, otherwise, the detection is unqualified.

7. A vision-based fully automatic LCD detection device, characterized in that: The vision-based fully automatic LCD detection device comprises: An image acquisition module, used for acquiring an image of the pressing head and a first preset number of product images; A size determination module, for determining a search area and a pixel size based on the indenter image; A feature region determination module is used to calibrate each product image according to the pixel size, and determine the feature region of the calibrated product image according to the pixel mutation of the calibrated product image in the search area; An image adjustment module, used to adjust the remaining calibrated product images based on the feature area of ​​the first calibrated product image; A detection area determination module, used to determine the detection area of ​​each adjusted product image and obtain the gray value of each pixel in the detection area. A grayscale value determination module, used to determine the grayscale value range of each pixel in the detection area according to all adjusted product images; A template module is established to establish a product detection template according to the gray value range of each pixel in the feature area and the detection area; A product testing module is used to test products according to a test template; Determining the search area and pixel size according to the indenter image includes: S201, taking the direction from the midpoint pixels of the four sides of the indenter image to the center of the indenter image as the advancing direction, successively determining whether the difference in the grayscale value between two adjacent pixels in the advancing direction is less than a first preset value, and if so, recording the pixel relatively close to the center of the indenter image as the first pixel, and recording the first pixel as the first edge pixel; S202, after determining the first first edge pixel, taking two perpendicular directions of the moving direction of the first edge pixel as second directions, determining whether there is a first pixel among a second preset number of adjacent pixels of the first edge pixel in the second direction, and if so, recording the first pixel as the first edge pixel; S203, for a first edge pixel after the first first edge pixel, determine whether there is a first pixel among a second preset number of adjacent pixels of the first edge pixel in the second direction along the second direction in which the first edge pixel is determined, and if so, record the first pixel as the first edge pixel; S204, repeating S203 until there is no first pixel among a second preset number of adjacent pixels of the first edge pixel in the second direction; S205, determining a search area as an area surrounded by all first edge pixels; S206, determining the pixel size according to the search area and the data of the indenter; The step of determining the pixel size according to the search area and the data of the indenter includes: Determine the horizontal and vertical distances of the search area; Determine the length and width of the pressure head according to the pressure head data; Depend on Get the calibration value in the horizontal direction; Depend on Get the calibration value in the vertical direction; The average value of the calibration value in the horizontal direction and the calibration value in the vertical direction is determined as the pixel size; Among them, a is the length distance of the indenter, X is the horizontal distance of the indenter image, x is the horizontal distance of the search area, p1 is the resolution of the image acquisition device in the horizontal distance, b is the width distance of the indenter, Y is the vertical distance of the indenter image, y is the vertical distance of the search area, and p2 is the resolution of the image acquisition device in the vertical distance.

8. A vision-based fully automatic LCD inspection system, characterized in that: The vision-based fully automatic LCD inspection system includes: power supply equipment, feeding and transmission equipment, pressing equipment, image acquisition equipment and computer equipment; The power supply device is used to provide power to the feeding and transmission device, the pressing device, the image acquisition device, the computer device and the product; The feeding transmission device is in communication connection with the computer device and is used for transporting products; The pressing device is in communication connection with the computer device, and is used to press the product after the product reaches the detection area so that the product and the power supply device are in full contact; The image acquisition device is connected to the computer device and is used to acquire the image of the pressing head of the pressing device and the image of the product after the product reaches the inspection area; The computer device is used to execute the steps of the vision-based fully automatic LCD inspection method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • TFT-LCD Mura defect machine vision detecting method based on B spline surface fitting

    CN103792699A