Screen detection method and device, electronic equipment and computer program product
By acquiring images in both on-screen and off-screen states and using models to distinguish between screen defects and foreign objects, the high cost and low flexibility of screen detection are solved, achieving efficient and low-cost screen detection.
Patent Information
- Application Number
- CN202411037396.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-30
- Publication Date
- 2024-11-15
AI Technical Summary
Existing screen testing methods are costly and inflexible, especially when tested in cleanrooms, where they are affected by dust and dirt in the environment, resulting in low accuracy of test results.
By acquiring screen images under different lighting conditions, and using an external artificial light source to obtain first and second images in both on-screen and off-screen states, screen defects and foreign objects are detected respectively. A pre-trained model is used to distinguish between real defects and foreign objects, reducing environmental interference.
This enables efficient and low-cost screen inspection in open environments, reducing inspection costs and improving inspection flexibility and accuracy.
Smart Images

Figure CN118961750A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of screen detection technology, and more specifically, to a screen detection method, device, electronic equipment and computer program product. Background Art
[0002] With the development of electronic technology, various electronic devices have gradually integrated into people's daily lives, such as mobile phones, tablet computers, electronic watches, etc. For some electronic devices, the screen is an important component, so the quality of the screen affects the user experience of the electronic device. Therefore, whether in the production scene of electronic devices or in the recycling scene, it is necessary to test the screen of electronic devices.
[0003] In current screen inspection, in order to avoid interference of dust, dirt, etc. on the inspection, the inspection process needs to be completed in a dust-free workshop, but the cost of a dust-free workshop is high, and the inspection flexibility is low due to the fixed inspection area. Summary of the invention
[0004] Based on the above-mentioned defects and shortcomings of the prior art, the present application proposes a screen detection method, device, electronic device and computer program product, which can solve the problems of high cost and low flexibility of the existing screen detection method.
[0005] According to a first aspect of an embodiment of the present application, a screen detection method is provided, the method comprising:
[0006] Acquire a first image and a second image; wherein the first image is acquired by capturing the screen to be detected in a bright screen state without external artificial light source; and the second image is acquired by capturing the screen to be detected in a dark screen state with external artificial light source;
[0007] detecting suspected screen defects based on the first image, and detecting foreign matter on the screen surface based on the second image;
[0008] Based on the detected suspicious screen defects and foreign matter, the real defects of the screen to be detected are determined.
[0009] According to a second aspect of an embodiment of the present application, a screen detection device is provided, including:
[0010] An image acquisition module, used to acquire a first image and a second image; wherein the first image is acquired by capturing the screen to be detected in a bright screen state without external artificial light source illumination; and the second image is acquired by capturing the screen to be detected in a dark screen state with external artificial light source illumination;
[0011] a detection module, configured to detect suspected screen defects based on the first image, and to detect foreign matter on the screen surface based on the second image;
[0012] The screen defect determination module is used to determine the real defects of the screen to be detected based on the detected suspected screen defects and foreign objects.
[0013] According to a third aspect of an embodiment of the present application, there is provided an electronic device, including: a memory and a processor;
[0014] The memory is connected to the processor and is used to store programs;
[0015] The processor is used to implement the screen detection method as described in the first aspect by running the program in the memory.
[0016] According to a fourth aspect of an embodiment of the present application, a storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the screen detection method as described in the first aspect is implemented.
[0017] According to a fifth aspect of the embodiments of the present application, a computer program product or a computer program is provided, wherein the computer program product includes the computer program, and when the processor of a computer device executes the computer program, the steps in the screen detection method as described in the first aspect are implemented. Optionally, the computer program can be stored in a readable storage medium or a cloud of the computer device; the processor of the computer device reads the computer program from the readable storage medium or the cloud.
[0018] In the technical solution provided in the present application, a first image can be captured of the screen to be detected in a bright screen state without illumination by an external artificial light source, and a second image can be captured of the screen to be detected in an off screen state with illumination by an external artificial light source, and suspected screen defects can be detected based on the first image, and foreign objects on the screen surface can be detected based on the second image. Based on the foreign objects detected by the second image, foreign objects that are mistakenly judged as suspected screen defects can be excluded, thereby screening out real screen defects and reducing the impact of foreign objects such as dust and dirt in an open environment on screen detection. Therefore, the technical solution provided in the embodiment of the present application enables screen detection to be implemented in an ordinary open environment without the need for a dust-free workshop. Since there is no need to use a dust-free workshop, the cost of screen defect detection can be reduced, and since it is not restricted by the dust-free detection environment, the setting of the detection area is more flexible, which makes the detection more flexible. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.
[0020] Figure 1 A schematic diagram of a flow chart of a screen detection method provided in an embodiment of the present application;
[0021] Figure 2 A schematic diagram of a first image provided in an embodiment of the present application;
[0022] Figure 3 A partially enlarged schematic diagram of a first image provided in an embodiment of the present application;
[0023] Figure 4 A schematic diagram of a second image provided in an embodiment of the present application;
[0024] Figure 5 A partially enlarged schematic diagram of a second image provided in an embodiment of the present application;
[0025] Figure 6 A block diagram of a screen detection device provided in an embodiment of the present application;
[0026] Figure 7 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0027] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0028] Application Overview
[0029] In current industrial screen defect detection, images of the screen to be tested are generally collected in a dust-free workshop using image acquisition equipment, and then the screen is tested to see if it is qualified in conjunction with relevant algorithms. Using a dust-free workshop can reduce foreign matter such as dust and dirt that falls on the screen surface, so as to avoid excessive interference with screen defect detection. For new equipment, the impact of foreign matter in the environment can also be reduced based on the film-sticking and film-tearing detection method, that is, the screen is filmed before testing, and the film is removed during testing, thereby reducing foreign matter on the screen surface.
[0030] However, the construction cost of a dust-free workshop is high, and the detection flexibility is low due to the fixed detection area. The method of film application and film removal will also increase the detection cost. In addition, in the recycling industry (also known as the second-hand industry), the equipment quality inspection workshop does not have a standard dust-free workshop, so there will be a lot of dust, and many recycled old equipment (also known as second-hand equipment) will have a lot of dust and dirt. There are also a large number of devices without film, and it is difficult to reduce foreign matter on the screen surface by film removal. This causes the detection process to be greatly affected by environmental dust, and the accuracy of the test results is low.
[0031] In order to solve the aforementioned technical problems, the present application provides a screen detection technology, which can overcome the interference of foreign matter in the environment on screen defect detection by performing screen defect detection based on images collected under different conditions (such as lighting, screen status), and improve the accuracy of the detection results even without using a dust-free workshop. Moreover, since there is no need to use a dust-free workshop, it can also reduce the detection cost and improve the flexibility of detection. The screen detection technology is described in detail below.
[0032] Exemplary Methods
[0033] An embodiment of the present application provides a screen detection method, and the execution subject may be an electronic device with a screen detection function, such as a detection device such as a mobile phone, a tablet computer, etc. provided with a screen detection function.
[0034] The method is described in detail below through some embodiments. The following embodiments can be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments.
[0035] like Figure 1 As shown, the method may include steps 101 to 103, which are specifically described as follows:
[0036] Step 101: Acquire a first image and a second image.
[0037] The first image described here is obtained by capturing the screen to be detected in a bright screen state without external artificial light source. When capturing the first image, the screen to be detected can display a white or nearly white picture as a background, and can only display a white or nearly white background image, and can preferably be a white picture, which can help to better highlight the screen defects in the first image while reducing interference from other factors. Among them, in addition to screen defects, the first image can also reflect foreign matter on the surface of the screen to be detected.
[0038] The second image described here is obtained by capturing the screen to be detected in the off state with the help of an external artificial light source. In the off state, the screen does not emit light and is black in color, while the color of foreign matter is generally lighter than black. Therefore, there is a difference between the color of the screen and the color of the foreign matter. Therefore, the foreign matter on the surface of the screen to be detected can be better highlighted in the second image. Since the screen is not illuminated, some defects caused by internal reasons of the screen cannot be reflected in the image. For example, screen defects caused by the presence of pixel defects (also known as bad pixels) are difficult to reflect in the image.
[0039] The external artificial light source required for use in the embodiments of the present application can be selected according to actual needs. For example, a white light source can be selected as the external artificial light source to reduce color interference; a light source with better anti-aging properties can also be selected as the external artificial light source to avoid frequent replacement of the light source; a coaxial light source can also be selected as the external artificial light source to provide more uniform lighting and improve the accuracy and reproducibility of machine vision.
[0040] It should be noted that the first image and the second image can be collected in an open environment without the need to collect images in a dust-free workshop. In addition, before collecting the first image and the second image, the dust, dirt and other foreign objects on the surface of the screen to be detected can be cleaned to reduce the interference of foreign objects on the screen surface on the screen detection. It should also be noted that the order of collecting the first image and the second image is not limited, that is, the first image can be collected first and then the second image, or the second image can be collected first and then the first image.
[0041] Step 102: Detect suspected screen defects based on the first image, and detect foreign matter on the screen surface based on the second image.
[0042] As can be seen from the above content, the first image can well highlight the screen defects, but at the same time, the first image may also include foreign objects on the screen surface. Since foreign objects may also be misjudged as screen defects, suspicious screen defects can be detected based on the first image. The second image can well highlight foreign objects on the screen surface, and the second image cannot reflect screen defects. Therefore, foreign objects on the screen surface can be detected based on the second image.
[0043] Step 103: Determine the real defects of the screen to be inspected based on the detected suspected screen defects and foreign matter.
[0044] In the embodiment of the present application, foreign matter on the screen surface detected based on the second image can exclude foreign matter that is mistakenly judged as a suspected screen defect, thereby screening out real screen defects and reducing the interference of foreign matter such as dust and dirt in an open environment on screen detection. Therefore, the technical solution provided by the embodiment of the present application enables screen detection to be implemented in an ordinary open environment without the need for a dust-free workshop. Since there is no need to use a dust-free workshop, the cost of screen defect detection can be reduced. Since it is not limited by the dust-free detection environment, the setting of the detection area is more flexible, meeting the detection needs of screen defects in the recycling industry.
[0045] In some optional embodiments, step 102: detecting suspected screen defects based on the first image, and detecting foreign matter on the screen surface based on the second image, may include step A1 and step A2, as described below:
[0046] Step A1: Detecting suspicious screen defects based on the first image, and marking the detected suspicious screen defects in the first image.
[0047] Figure 2 is a schematic diagram of a first image, specifically illustrating a marked suspicious screen defect. Figure 3 for Figure 2 A schematic diagram of a partial enlargement of the first image is shown as follows: Figure 3 As shown, three dotted circle frames identify rectangular identification frames a1 to a3, and the image contents framed by the rectangular identification frames a1 to a3 include the marked suspicious screen defects.
[0048] In an embodiment of the present application, a suspected screen defect can be detected based on a pre-trained defect detection model. For example, a first image can be input into the defect detection model, and the defect detection model can identify a suspected screen defect in the first image, and the detected suspected screen defect can be marked in the first image.
[0049] Optionally, images with real screen defects marked can be used as positive samples, and images with foreign objects such as dust and dirt marked can be used as negative samples to train the defect detection model. The defect detection model can be a classifier model for distinguishing real screen defects from foreign objects on the screen surface, or for distinguishing real screen defects from non-real screen defects. The difference between the latter and the former is that only real screen defects need to be identified, and whether the screen surface includes foreign objects is not important.
[0050] Step A2: Based on the second image, detect whether there is a foreign object in the target area of the screen to be detected.
[0051] The target area described here is the area where the suspected screen defect is located in the screen to be detected. In the embodiment of the present application, the area where the suspected screen defect is located in the screen to be detected (i.e., the target area) can be determined based on the first image, and then in the second image, it can be determined whether there is a foreign object in the same screen area.
[0052] Optionally, in order to more easily determine the correspondence between the screen areas in the first image and the second image, when capturing the first image and the second image, it is preferred that the capturing position and capturing angle of the image capturing device remain unchanged and the placement position of the screen to be detected remains unchanged, so that the size and position of the screen to be detected in the first image and the second image are the same, so that the same screen area is the same image area.
[0053] Optionally, in order to ensure that the acquisition position and acquisition angle of the image acquisition device remain unchanged when acquiring the first image and the second image, and the placement position of the screen to be detected remains unchanged, the image acquisition device can be fixed by a bracket to ensure that the image acquisition position and acquisition angle remain unchanged, and at the same time, other fixing devices can be used to fix the placement position of the device with the screen to be detected. It is understandable that other methods can also be used to make the size and position of the screen to be detected the same in the first image and the second image.
[0054] In some embodiments, before step A2: detecting whether there is a foreign object in the target area of the screen to be detected based on the second image, the method may further include: detecting foreign objects on the screen to be detected based on the second image, and marking the detected foreign objects in the second image.
[0055] Step A2: Based on the second image, detecting whether there are foreign objects in the target area of the screen to be detected may include: determining the position of the target area in the second image; and based on the foreign objects marked in the second image, determining whether there are foreign objects in the target area of the screen to be detected in the second image.
[0056] In the embodiment of the present application, when judging whether there is a foreign object in the target area of the screen to be detected by the second image, all foreign objects on the screen to be detected can be detected by the second image first, and the detected foreign objects can be marked in the second image. Figure 4 As shown, the foreign body detection result in the second image is illustrated. Figure 5 for Figure 4 The second image is a partial enlarged schematic diagram, in which two circles mark two groups of foreign body marks, namely foreign body marks b1 and b2. The foreign body mark is composed of four white dots, and the image content in the rectangular area formed by the four white dots includes the marked foreign body (not shown in the figure).
[0057] Then, the position of the target area of the screen to be detected in the second image is determined, and based on the foreign matter marked in the second image, it is determined whether there is a foreign matter in the target area of the screen to be detected in the second image.
[0058] Assumptions Figure 3 and Figure 5 As shown in the figure, the target area of the screen to be detected in the first image includes the image areas marked by the rectangular identification frames a1, a2 and a3, and the same target areas in the second image are: the rectangular image area formed by the foreign body identification b1 (corresponding to the image area marked by the rectangular identification frame a1), the rectangular image area formed by the foreign body identification b2 (corresponding to the image area marked by the rectangular identification frame a2), and the image area marked by the rectangular identification frame b3 (corresponding to the image area marked by the rectangular identification frame a3). After determining the position correspondence between the image areas in the two frames of images, it is possible to continue to determine whether there is a foreign body in the target area of the screen to be detected in the second image. Figure 5 As shown, the target areas indicated by b1 and b2 include foreign matter, while the target area indicated by b3 does not include foreign matter.
[0059] It should be noted that the step of "detecting foreign objects on the screen to be detected based on the second image, and marking the detected foreign objects in the second image" can be performed simultaneously with step A1, after step A1, or before step A1.
[0060] In some embodiments, step A2: detecting whether there is a foreign object in the target area of the screen to be detected based on the second image may include:
[0061] The position of the target area in the second image is determined, and whether there is a foreign object in the target area of the screen to be inspected in the second image is detected.
[0062] In an embodiment of the present application, it is also possible to detect whether there is a foreign object in the target area based on the second image, that is, first determine the target area in the second image, and then detect whether there is a foreign object in the target area, which can reduce the detection of useless foreign objects.
[0063] In some optional embodiments, the suspected screen defects corresponding to the target area where foreign matter exists can be directly screened out, or the foreign matter in the area can be further compared and analyzed with the suspected screen defects, and a decision can be made based on the analysis results whether to screen out the suspected screen defects corresponding to the area, as described below.
[0064] In some embodiments, step 103: determining the real defects of the screen to be detected based on the detected suspected screen defects and foreign matter, may include:
[0065] The suspected screen defect corresponding to the target area of the screen to be inspected where no foreign matter exists is determined as the real defect of the screen to be inspected.
[0066] For a suspected screen defect determined based on the first image, if there is no foreign matter in the screen area where the suspected screen defect is located in the second image, it can be considered that the detection of the suspected screen defect is not affected by the foreign matter on the screen surface and is a real screen defect. Figure 5 As shown, for Figure 3 The rectangular identification box a3 in the figure corresponds to b3, and the target area indicated by it does not include foreign matter, so it can be considered that Figure 3 The suspected screen defect marked by the middle rectangular identification frame a3 is a real screen defect.
[0067] In an optional embodiment, for a suspected screen defect corresponding to a target area where a foreign object exists in the screen to be detected, the suspected screen defect may be considered to be a foreign object on the screen surface, not a real screen defect. Figure 5 As shown, for Figure 3 The rectangular identification boxes a1 and a2 correspond to b1 and b2 in the figure. Assuming that the target area shown in the figure includes foreign matter, it can be considered that Figure 3 The suspected screen defects marked by the middle rectangular identification frames a1 and a2 are foreign objects, not real screen defects. In this way, the interference of foreign objects such as dust and dirt on the screen surface on screen detection can be reduced, and the accuracy of screen defect detection can be improved.
[0068] In another optional embodiment, for a suspected screen defect corresponding to a target area where a foreign object exists in the screen to be detected, it is also possible to determine whether the suspected screen defect is a real defect based on the similarity between the foreign object feature and the suspected screen defect feature.
[0069] If there is foreign matter in the screen area where the suspected screen defect is located in the second image, it means that the detection of the suspected screen defect may be affected by the foreign matter on the screen surface. In this case, whether the suspected screen defect is a real defect can be determined based on the similarity between the foreign matter characteristics and the suspected screen defect characteristics.
[0070] If the similarity between the foreign matter feature and the suspected screen defect feature is high, it is considered that the suspected screen defect is actually a foreign matter on the screen surface; if the similarity between the foreign matter feature and the suspected screen defect feature is low, it is considered that the suspected screen defect is not a foreign matter on the screen surface, but the two are in the same screen area, so the suspected screen defect is a real screen defect. In this way, the real screen defects can be screened out more accurately, and the interference of foreign matter such as dust and dirt on the screen surface on screen detection can be further reduced.
[0071] Optionally, the foreign matter features and suspected screen defect features may include but are not limited to at least one of the following: the shape, area, color, overall comprehensive features of the foreign matter and suspected screen defect, etc. It is understandable that the more feature parameters there are, the more accurate the similarity comparison analysis result will be.
[0072] For example, when the feature is area, the area of the foreign matter and the area of the suspected screen defect can be calculated separately, and then the difference between the two areas can be calculated. If the difference between the areas is within the area threshold, the two are considered to have a high similarity; conversely, if the difference between the areas is not within the area threshold, the two are considered to have a low similarity. The area threshold described here can be an area range threshold, and the specific value can be set according to actual needs.
[0073] For example, when the feature is morphology, the similarity value between the foreign body morphology and the suspected screen defect morphology can be calculated separately. If the similarity value is greater than or equal to the similarity threshold, the two are considered to have a high similarity; conversely, if the similarity value is less than the similarity threshold, the two are considered to have a low similarity. The specific value of the similarity threshold described here can be set according to actual needs. Of course, the similarity value between the foreign body and the suspected screen defect can also be calculated based on the overall comprehensive features of the two.
[0074] It is understandable that the above two examples can also be combined to perform a similarity comparison analysis between foreign matter and suspected screen defects. For example, if the difference between the area of the foreign matter and the area of the suspected screen defect is within the area threshold, and the similarity value between the morphology of the foreign matter and the morphology of the suspected screen defect is greater than or equal to the similarity threshold, then the similarity between the two is considered to be high; if the difference between the area of the foreign matter and the area of the suspected screen defect is not within the area threshold, or the similarity value between the morphology of the foreign matter and the morphology of the suspected screen defect is less than the similarity threshold, then the similarity between the two is considered to be low. In this way, the accuracy of the similarity comparison analysis results can be improved.
[0075] In some optional embodiments, foreign objects on the surface of the screen to be detected can be detected by a pre-trained model, or by the brightness value of the second image, as described below.
[0076] In some embodiments, "detecting foreign objects on the surface of the screen to be detected based on the second image" in step 102 may include: inputting the second image into a pre-trained foreign object detection model, and detecting foreign objects on the surface of the screen to be detected through the foreign object detection model.
[0077] By reasonably training the foreign object detection model, the model's detection accuracy for foreign objects can be improved, thereby improving the accuracy of foreign object detection on the screen surface to be detected.
[0078] Optionally, images marked with foreign objects such as dust and dirt can be used as positive samples, and images marked with real screen defects can be used as negative samples to train the foreign object detection model. The foreign object detection model can be a classifier model for distinguishing foreign objects from non-foreign objects.
[0079] In some embodiments, "detecting foreign objects on the surface of the screen to be detected based on the second image" in step 102 may include: determining an image in the second image whose brightness value is greater than or equal to a brightness threshold as a foreign object.
[0080] The brightness threshold described here is set according to the brightness value of black.
[0081] When the screen is off, the screen to be detected is black, and the brightness value of black in the image is low, while the brightness values of foreign objects such as dust and dirt are higher than the brightness value of black. There is a brightness difference between the two. Therefore, foreign objects on the screen surface can be detected based on the image brightness value, and a brightness threshold can be set based on the brightness value of black, and the brightness threshold can be greater than the brightness value of black.
[0082] Specifically, a continuous pixel group whose brightness value is greater than or equal to a brightness threshold may be determined as a foreign object.
[0083] The above is a description of the screen detection method provided in the embodiment of the present application.
[0084] To sum up, the screen detection method provided in the embodiment of the present application only requires an external artificial light source and an image acquisition device, without the need for a dust-free workshop. Therefore, the cost of screen defect detection can be reduced. Moreover, since it is not restricted by the dust-free detection environment, the application of the detection method is more flexible.
[0085] Exemplary Devices
[0086] Correspondingly, an embodiment of the present application also provides a screen detection device, which is applied to an electronic device with a screen detection function, such as a mobile phone, a tablet computer, etc. provided with a screen detection function.
[0087] like Figure 6 As shown, the device may include:
[0088] The image acquisition module 601 is used to acquire a first image and a second image.
[0089] Among them, the first image is obtained by capturing the screen to be detected in a bright state without any external artificial light source; the second image is obtained by capturing the screen to be detected in an off state with external artificial light source lighting.
[0090] The detection module 602 is used to detect suspicious screen defects based on the first image, and to detect foreign objects on the screen surface based on the second image.
[0091] The screen defect determination module 603 is used to determine the real defects of the screen to be detected based on the detected suspected screen defects and foreign matter.
[0092] Optionally, the screen defect determination module 603 may be specifically configured to: determine a suspected screen defect corresponding to a target area of the screen to be detected where no foreign matter exists as a real defect of the screen to be detected, wherein the target area is an area of the screen to be detected where the suspected screen defect is located.
[0093] Optionally, the screen defect determination module 603 may also be specifically used to: for a suspected screen defect corresponding to a target area where a foreign object exists in the screen to be detected, determine whether the suspected screen defect is a real defect according to the similarity between the foreign object feature and the suspected screen defect feature.
[0094] Optionally, the detection module 602 may include:
[0095] a screen defect detection unit, configured to detect suspicious screen defects based on the first image, and mark the detected suspicious screen defects in the first image;
[0096] A screen foreign matter detection unit is used to detect whether there is a foreign matter in a target area of the screen to be detected based on the second image.
[0097] Optionally, the screen foreign matter detection unit may be specifically configured to: determine a position of the target area in the second image; and detect whether there is a foreign matter in the target area of the screen to be detected in the second image.
[0098] Optionally, the device may further include: a foreign matter detection module, configured to detect foreign matter on the screen to be detected based on the second image, and mark the detected foreign matter in the second image.
[0099] The screen foreign matter detection unit can be specifically used to: determine the position of the target area in the second image; and determine whether there is a foreign matter in the target area of the screen to be detected in the second image based on the foreign matter marked in the second image.
[0100] Optionally, the detection module can be specifically used to: input the second image into a pre-trained foreign object detection model, and detect foreign objects on the screen to be detected through the foreign object detection model; or, determine an image in the second image whose brightness value is greater than or equal to a brightness threshold as a foreign object; the brightness threshold is set according to the brightness value of black.
[0101] The screen detection device provided in the embodiment of the present application belongs to the same application concept as the screen detection method provided in the above embodiment of the present application, and can execute the screen detection method provided in any of the above embodiments of the present application, and has the corresponding functional modules and beneficial effects of the execution method. For the technical details not fully described in this embodiment, please refer to the specific processing content of the screen detection method provided in the above embodiment of the present application, and will not be repeated here.
[0102] Exemplary Electronic Devices
[0103] The present application also provides an electronic device, such as Figure 7 As shown, the electronic device includes: a memory 700 and a processor 710 .
[0104] The memory 700 is connected to the processor 710 and is used to store programs.
[0105] The processor 710 is used to implement the screen detection method in the above embodiment by running the program stored in the memory 700 .
[0106] Specifically, the electronic device may further include: a communication interface 720 , an input device 730 , an output device 740 and a bus 750 .
[0107] The processor 710, the memory 700, the communication interface 720, the input device 730 and the output device 740 are connected to each other via a bus.
[0108] Bus 750 may include a pathway for transferring information between the various components of the computer system.
[0109] Processor 710 may be a general-purpose processor, such as a general-purpose central processing unit (CPU), a microprocessor, etc., or an application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling the execution of the program of the scheme of the present invention. It may also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0110] The processor 710 may include a main processor, and may also include a baseband chip, a modem, and the like.
[0111] The memory 700 stores a program for executing the technical solution of the present invention, and may also store an operating system and other key services. Specifically, the program may include a program code, and the program code includes a computer operation instruction. More specifically, the memory 700 may include a read-only memory (ROM), other types of static storage devices that can store static information and instructions, a random access memory (RAM), other types of dynamic storage devices that can store information and instructions, a disk storage, a flash, and the like.
[0112] The input device 730 may include a device for receiving data and information input by a user, such as a keyboard, a mouse, a camera, a scanner, a light pen, a voice input device, a touch screen, a pedometer, or a gravity sensor.
[0113] Output device 740 may include devices that allow information to be output to a user, such as a display screen, printer, speaker, etc.
[0114] The communication interface 720 may include any transceiver or the like to communicate with other devices or communication networks, such as Ethernet, Radio Access Network (RAN), Wireless Local Area Network (WLAN), etc.
[0115] The processor 710 executes the program stored in the memory 700 and calls other devices, which can be used to implement the various steps of the screen detection method provided in the above embodiments of the present application.
[0116] Exemplary computer program products and storage media
[0117] In addition to the above-mentioned method and device, the embodiment of the present application may also be a computer program product, which includes computer program instructions, which, when executed by a processor, enable the processor to execute the steps in the screen detection method described in the embodiment of the present application.
[0118] The computer program product may be implemented in hardware, software or a combination thereof. In one optional embodiment, the computer program product is implemented as a computer storage medium. In another optional embodiment, the computer program product is implemented as a software product, such as a software development kit (SDK).
[0119] The computer program product may be written in any combination of one or more programming languages to write program codes for performing the operations of the embodiments of the present application, including object-oriented programming languages, such as Java, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as an independent software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server.
[0120] In addition, the embodiment of the present application may also be a storage medium on which a computer program is stored, and the computer program is executed by a processor to execute the steps of the screen detection method described in the embodiment of the present application.
[0121] For the aforementioned method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations (i.e., step combinations), but those skilled in the art should be aware that the present application is not limited by the described action sequence, because according to the present application, some steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present application.
[0122] It should be noted that each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments, and the same or similar parts between the embodiments can be referred to each other. For the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0123] The steps in the methods of each embodiment of the present application can be adjusted in order, combined and deleted according to actual needs, and the technical features recorded in each embodiment can be replaced or combined.
[0124] The modules and sub-modules in the devices and terminals in the various embodiments of the present application can be combined, divided and deleted according to actual needs.
[0125] In the several embodiments provided in the present application, it should be understood that the disclosed terminals, devices and methods can be implemented in other ways. For example, the terminal embodiments described above are only schematic, for example, the division of modules or submodules is only a logical function division, and there may be other division methods in actual implementation, for example, multiple submodules or modules can be combined or integrated into another module, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or modules, which can be electrical, mechanical or other forms.
[0126] The modules or submodules described as separate components may or may not be physically separated, and the components of the modules or submodules may or may not be physical modules or submodules, that is, they may be located in one place, or they may be distributed on multiple network modules or submodules. Some or all of the modules or submodules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0127] In addition, each functional module or submodule in each embodiment of the present application may be integrated into one processing module, or each module or submodule may exist physically separately, or two or more modules or submodules may be integrated into one module. The above-mentioned integrated modules or submodules may be implemented in the form of hardware or in the form of software functional modules or submodules.
[0128] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0129] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly by hardware, software units executed by a processor, or a combination of the two. The software units may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
[0130] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
Claims
1. A screen detection method, characterized in that: The method comprises: Acquire a first image and a second image; wherein the first image is acquired by capturing the screen to be detected in a bright screen state without external artificial light source; and the second image is acquired by capturing the screen to be detected in a dark screen state with external artificial light source; detecting suspected screen defects based on the first image, and detecting foreign matter on the screen surface based on the second image; Based on the detected suspicious screen defects and foreign matter, the real defects of the screen to be detected are determined.
2. The screen detection method according to claim 1, characterized in that: The determining of the real defects of the screen to be detected according to the detected suspected screen defects and foreign objects includes: The suspected screen defect corresponding to the target area in the screen to be detected where no foreign matter exists is determined as the real defect of the screen to be detected; wherein the target area is the area of the suspected screen defect in the screen to be detected.
3. The screen detection method according to claim 2, characterized in that: The determining of the real defects of the screen to be detected based on the detected suspected screen defects and foreign matter also includes: For a suspected screen defect corresponding to a target area where a foreign object exists in the screen to be inspected, it is determined whether the suspected screen defect is a real defect according to the similarity between the foreign object feature and the suspected screen defect feature.
4. The screen detection method according to claim 2 or 3, characterized in that: The detecting of suspected screen defects based on the first image, and detecting foreign matter on the screen to be detected based on the second image, comprises: detecting a suspected screen defect based on the first image, and marking the detected suspected screen defect in the first image; Based on the second image, it is detected whether there is a foreign object in the target area of the screen to be detected.
5. The screen detection method according to claim 4, characterized in that: The detecting whether there is a foreign object in the target area of the screen to be detected based on the second image includes: determining a position of the target area in the second image; Detect whether there is a foreign object in the target area of the screen to be detected in the second image.
6. The screen detection method according to claim 4, characterized in that: Before detecting whether there is a foreign object in the target area of the screen to be detected based on the second image, the method further includes: Detecting foreign matter on the screen to be detected based on the second image, and marking the detected foreign matter in the second image; The detecting whether there is a foreign object in the target area of the screen to be detected based on the second image includes: determining a position of the target area in the second image; Based on the foreign matter marked in the second image, it is determined whether there is a foreign matter in the target area of the screen to be detected in the second image.
7. The screen detection method according to claim 2 or 3, characterized in that: The detecting the foreign matter on the surface of the screen to be detected based on the second image includes: Inputting the second image into a pre-trained foreign object detection model, and detecting foreign objects on the screen to be detected by the foreign object detection model; Or, an image in the second image whose brightness value is greater than or equal to a brightness threshold is determined as a foreign object; the brightness threshold is set according to the brightness value of black.
8. A screen detection device, characterized in that: The device comprises: An image acquisition module, used to acquire a first image and a second image; wherein the first image is acquired by capturing the screen to be detected in a bright screen state without external artificial light source illumination; and the second image is acquired by capturing the screen to be detected in a dark screen state with external artificial light source illumination; a detection module, configured to detect suspected screen defects based on the first image, and to detect foreign matter on the screen surface based on the second image; The screen defect determination module is used to determine the real defects of the screen to be detected based on the detected suspected screen defects and foreign objects.
9. An electronic device, characterized in that: include: Memory and processor; The memory is connected to the processor and is used to store programs; The processor is used to implement the screen detection method according to any one of claims 1 to 7 by running the program in the memory.
10. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed by a processor, the screen detection method according to any one of claims 1 to 7 is implemented.
Citation Information
Cited By
Mobile phone screen backlight foreign matter defect diagnosis method and system
CN120525829A
A mobile phone screen backlight foreign matter defect diagnosis method and system
CN120525829B
