Automobile lamp surface detection method and system

By calculating the similarity of pixel points of the car lamp images under different light sources, identifying and marking damaged areas, the problem of light intensity changes in the prior art affecting detection accuracy, and achieving more accurate detection robustness of damaged areas.

CN118644480BActive Publication Date: 2024-11-08WUHAN AURATECH AUTOMOBILE TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411109910.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-14
Publication Date
2024-11-08
Estimated Expiration
2044-08-14

AI Technical Summary

Technical Problem

Existing automotive lamp detection methods are difficult to accurately identify the texture information of the lamp surface under different light intensity conditions, resulting in inaccurate detection results and lack of good adaptability to ambient light changes.

Method used

By acquiring the lamp image and standard image under light sources of different intensities, the similarity between pixel points is calculated, the point with a similarity greater than the preset threshold is the initial damage point, the initial damage area is constructed, and the optimal analysis is determined through damage evaluation Area, the area with the largest final marking area is the damaged area, and the pixel point ratio is calculated as quality evaluation and the detection result is judged.

Benefits of technology

It improves the identification accuracy and detection efficiency of damaged areas on the surface of the lamp, enhances the adaptability to ambient light changes, and improves the robustness of detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118644480B_ABST
    Figure CN118644480B_ABST
Patent Text Reader

Abstract

The present application relates to the field of lamp detection, and in particular to a method and system for detecting the surface of automobile lamps. The method comprises the following steps: obtaining lamp images and standard images under light sources of different intensities, calculating the similarity between the pixels of the lamp images and the pixels of the standard images, and obtaining a similarity feature map according to the similarity; marking the points in the similarity feature map whose similarity is greater than a preset threshold as initial damaged points, and obtaining an initial damaged area according to the initial damaged points; calculating the damage evaluation, and taking the initial damaged area with the smallest damage evaluation in each lamp image as the optimal analysis area; for any two lamp images under light sources of different intensities, marking the optimal analysis area with the largest area among the optimal analysis areas with overlapping positions as the final damaged area; and taking the ratio of the number of pixels in the final damaged area to the number of non-zero pixels as the quality evaluation. The present application has the effect of improving the accuracy of the detection results.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of lamp detection, and in particular to a method and system for detecting the surface of an automobile lamp. Background Art

[0002] Ambient lighting refers to lighting equipment installed inside a car to enhance the atmosphere and aesthetics of the interior environment. These lamps are usually not intended to provide primary lighting or driving safety signals, but to enhance the comfort and visual experience inside the car. Ambient lighting may be installed in locations such as the door, roof, dashboard, footwell or center console.

[0003] The automotive ambient light system usually includes LED light strips or lamp beads, and decorative covers or shells. The decorative covers or shells cover the LED light strips or lamp beads as a protective layer for the ambient light and also serve as a decoration. The surface quality of the ambient light is directly related to the consumer's experience, and surface defects may still affect its luminous effect, so it is necessary to conduct quality inspections.

[0004] The existing technology can detect the quality of lampshades through image processing and recognition. For example, the lampshade quality detection method, device, electronic device and storage medium disclosed in the Chinese patent with patent announcement number CN114004776A include obtaining the image to be detected of the lampshade; performing corner point detection on the image to be detected to determine the number of corner points in the image to be detected; judging whether the number of corner points is equal to the preset number, if not, the lampshade quality is unqualified.

[0005] The lampshade is usually made of transparent or translucent plastic material. Under conditions of different light intensities, too high light intensity will cause the pixel value of the image to be detected to be too high, and too low light intensity will cause the pixel value of the image to be detected to be too low. Both situations may cover up or change the texture information on the surface of the lampshade, resulting in unclear texture and affecting the accuracy of the detection results. Summary of the invention

[0006] In order to improve the accuracy of the detection results, the present application provides a method and system for detecting the surface of an automobile lamp.

[0007] In a first aspect, the present application provides a method for detecting the surface of an automobile lamp, which adopts the following technical solution:

[0008] A method for detecting the surface of automobile lamps comprises the following steps: obtaining lamp images and standard images under light sources of different intensities, calculating the degree of similarity between the pixels of the lamp images and the pixels of the standard images, and obtaining a similarity feature map according to the degree of similarity; marking the points in the similarity feature map with a degree of similarity greater than a preset threshold as initial damage points, and obtaining an initial damage area according to the initial damage points; calculating a damage evaluation, and taking the initial damage area with the smallest damage evaluation in each lamp image as an optimal analysis area; for any two lamp images under light sources of different intensities, marking the optimal analysis area with the largest area among the optimal analysis areas with overlapping positions as a final damage area; taking the ratio of the number of pixels in the final damage area to the number of non-zero pixels as a quality evaluation, and in response to the quality evaluation being greater than a preset evaluation threshold, the detection result is unqualified.

[0009] The beneficial effect is that the optimal analysis area indicates that the damage points in the area are most consistent in similarity, which may be the most representative damage area, that is, the image that expresses the clearest damage area. The final damage area is determined according to the optimal analysis area. In this way, the damage area on the surface of the lamp can be more accurately identified, and the efficiency of identification is improved. At the same time, since light sources of different intensities are taken into account, the method has better adaptability to changes in ambient lighting and improves the robustness of detection.

[0010] Optionally, calculating the similarity between the pixels of the lamp image and the pixels of the standard image includes: taking any pixel in the lamp image as a target pixel, taking the pixel in the standard image at the same position as the target pixel as the standard pixel; calculating the similarity between the target pixel and the standard pixel, the expression is: ,in, Indicates the degree of similarity, The feature vector representing the target pixel, The feature vector representing the standard pixel.

[0011] The beneficial effect is that, according to the relationship between the feature vector of the target pixel point and the feature vector of the standard pixel point, the difference between the existing lamp surface and the standard lamp surface is found and the difference is quantified.

[0012] Optionally, the similarity between the pixels of the lamp image and the pixels of the standard image is calculated, including: taking any pixel in the lamp image as the target pixel, and taking the pixel in the standard image at the same position as the target pixel as the standard pixel; and taking the Euclidean distance between the target pixel and the standard pixel as the similarity.

[0013] The beneficial effect is: finding the image features of the target pixel points to find the difference between the surface of the existing lamp and the surface of the standard lamp, and quantifying the difference to facilitate subsequent analysis and calculation.

[0014] Optionally, the eigenvector is calculated as:

[0015] , , ,in, is the target pixel, for The pixel value of Represents any pixel other than the target pixel. express The pixel value of represents the maximum value function, Indicates the maximum pixel difference of the target pixel. express and The distance between The feature vector representing the target pixel.

[0016] Optionally, the eigenvector is calculated as:

[0017] , , ,in, is the target pixel, for The pixel value of Represents any pixel other than the target pixel. express The pixel value of represents the minimum function, Indicates the maximum pixel difference of the target pixel. express and The distance between The feature vector representing the target pixel.

[0018] Optionally, the damage evaluation is a standard deviation or variance of a set of similarities of initial damage points in the initial damage area.

[0019] The beneficial effects are: the standard deviation measures the degree of dispersion of similarity values, and the variance is the square of the standard deviation and can also reflect the fluctuation of the data.

[0020] Optionally, acquiring the lamp image includes: acquiring a color image of the lamp surface, performing grayscale processing on the color image to obtain a grayscale image, and performing threshold segmentation on the grayscale image to delete a background area to obtain the lamp image.

[0021] In a second aspect, the present application provides a system for detecting the surface of an automobile lamp, which adopts the following technical solution:

[0022] A system for detecting the surface of an automobile lamp comprises: a processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, the above-mentioned method for detecting the surface of an automobile lamp is implemented.

[0023] The beneficial effect is that the above-mentioned automobile lamp surface detection method is generated into a computer program and stored in a memory so as to be loaded and executed by a processor, thereby making a system based on the memory and the processor for easy use.

[0024] This application has the following technical effects:

[0025] 1. Accurately identify the damaged area on the surface of the lamp and improve the efficiency of recognition. At the same time, taking into account light sources of different intensities, this method has good adaptability to changes in ambient lighting and improves the robustness of detection.

[0026] 2. According to the relationship between the feature vector of the target pixel and the feature vector of the standard pixel, find the difference between the existing lamp surface and the standard lamp surface, and quantify the difference to facilitate subsequent analysis and calculation. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] By reading the detailed description below with reference to the accompanying drawings, the above and other purposes, features and advantages of the exemplary embodiments of the present application will become easily understood. In the accompanying drawings, several embodiments of the present application are shown in an exemplary and non-restrictive manner, and the same or corresponding numbers represent the same or corresponding parts.

[0028] Figure 1 This is a method flow chart of a method for detecting the surface of an automobile lamp according to an embodiment of the present application. DETAILED DESCRIPTION

[0029] 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 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 those skilled in the art without creative work are within the scope of protection of the present application.

[0030] It should be understood that when the terms "first", "second", etc. are used in the claims, specification and drawings of the present application, they are only used to distinguish different objects, rather than to describe a specific order. The terms "include" and "comprise" used in the specification and claims of the present application indicate the presence of the described features, wholes, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or their collections.

[0031] The present application embodiment discloses a method for detecting the surface of an automobile lamp. Figure 1 , including steps S1 to S5, which are specifically as follows:

[0032] S1: Obtain lamp images and standard images under light sources of different intensities, calculate the similarity between the pixels of the lamp images and the pixels of the standard images, and obtain a similarity feature map based on the similarity.

[0033] Specifically, under different light sources, a color image of the lamp surface is obtained, the color image is gray-processed to obtain a gray image, and the gray image is threshold segmented to delete the background area to obtain a lamp image. In one embodiment, the threshold segmentation can use a semantic segmentation model.

[0034] After obtaining the lamp image, any pixel in the lamp image is used as a target pixel, and a pixel in the standard image having the same position as the target pixel is used as a standard pixel, and the similarity between the target pixel and the standard pixel is calculated.

[0035] In one embodiment, the expression of similarity is: ,in, Indicates the degree of similarity, The feature vector representing the target pixel, The feature vector representing the standard pixel.

[0036] The calculation method of the feature vector of the target pixel is the same as that of the feature vector of the standard pixel. The feature vector of the target pixel is used as an example for explanation, and the calculation method of the feature vector of the standard pixel is not repeated.

[0037] Specifically, the calculation formula of the feature vector of the target pixel is:

[0038] , , ,in, is the target pixel, for The pixel value of Represents any pixel other than the target pixel. express The pixel value of Represents the maximum value function. Indicates the maximum pixel difference of the target pixel. express and The distance between The feature vector representing the target pixel.

[0039] In other embodiments, in the calculation formula of the feature vector of the target pixel, the expression of the maximum pixel difference of the target pixel may also be: ,in, Indicates the maximum pixel difference of the target pixel. is the target pixel, for The pixel value of Represents any pixel other than the target pixel. express The pixel value of Represents the minimum function.

[0040] In other embodiments, the similarity calculation method may also be: taking the Euclidean distance between the target pixel and the standard pixel as the similarity. The calculation of the Euclidean distance is a prior art and will not be described in detail here.

[0041] S2: Mark the points in the similarity feature map whose similarity is greater than a preset threshold as initial damage points, and obtain the initial damage area based on the initial damage points.

[0042] Specifically, in the similarity feature map, each point represents the similarity between the pixel point corresponding to the point and the standard pixel point. The preset threshold is set to 0.8 or 0.7. The preset threshold is used to distinguish between damaged points and non-damaged points. The value of the preset threshold can be adjusted according to the actual application scenario.

[0043] The points in the similarity feature graph whose similarity is greater than a preset threshold are marked as initial damaged points, and the other points are non-damaged points.

[0044] The method of obtaining the initial damage area according to the initial damage point is: constructing the initial damage area with any initial damage point as the center of the area, and the initial damage area contains a preset number of initial damage points adjacent to any initial damage point, the preset number can be 30, and the value of the preset number can be adjusted according to the actual application scenario. Among them, the initial damage area can be constructed by the connected domain analysis method.

[0045] S3: Calculate the damage evaluation and select the initial damaged area with the smallest damage evaluation in each lamp image as the optimal analysis area.

[0046] The damage evaluation is the standard deviation or variance of the similarity set of initial damage points in the initial damage area. The standard deviation measures the dispersion of the similarity values, while the variance is the square of the standard deviation, which can also reflect the fluctuation of the data.

[0047] The initial damaged area with the smallest damage evaluation is taken as the optimal analysis area. The optimal analysis area means that the damage points in the area are most consistent in similarity and may be the most representative damaged area, that is, the image that expresses the clearest image of the damaged area.

[0048] S4: For any two lamp images under light sources of different intensities, the optimal analysis region with the largest area among the optimal analysis regions with overlapping positions is marked as the final damaged region.

[0049] Acquire lamp images from two light sources of different intensities, perform damage analysis on each lamp image, identify the optimal analysis area in each lamp image, and determine whether the two optimal analysis areas overlap in position. If so, calculate the areas of the two optimal analysis areas, and take the optimal analysis area with the largest area as the final damaged area and mark it.

[0050] S5: The ratio of the number of pixels in the final damaged area to the number of non-zero pixels is used as a quality evaluation. In response to the quality evaluation being greater than a preset evaluation threshold, the detection result is unqualified.

[0051] The ratio of the number of damaged pixels in the final damaged area to the number of non-zero pixels in the entire area is calculated. This ratio reflects the severity of the damage. When the quality evaluation is greater than the preset evaluation threshold, the test result is judged as unqualified, otherwise, the test result is qualified.

[0052] The evaluation threshold is set to 0.001. The value of the evaluation threshold can be adjusted according to the actual application scenario.

[0053] The embodiment of the present application also discloses an automobile lamp surface detection system, including a processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, the automobile lamp surface detection method according to the present application is implemented.

[0054] The above system also includes other components well known to those skilled in the art, such as a communication bus and a communication interface, and their configuration and functions are known in the art, so they will not be described in detail here.

[0055] In the present application, the aforementioned memory may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, apparatus, or device. For example, a computer-readable storage medium may be any appropriate magnetic storage medium or magneto-optical storage medium, such as a resistive random access memory RRAM (Resistive Random Access Memory), a dynamic random access memory DRAM (Dynamic Random Access Memory), a static random access memory SRAM (Static Random Access Memory), an enhanced dynamic random access memory EDRAM (Enhanced Dynamic Random Access Memory), a high bandwidth memory HBM (High Bandwidth Memory), a hybrid memory cube HMC (Hybrid Memory Cube), etc., or any other medium that can be used to store the required information and can be accessed by an application, a module, or both. Any such computer storage medium may be part of a device or accessible or connectable to a device.

[0056] Although this specification has shown and described a plurality of embodiments of the present application, it is obvious to those skilled in the art that such embodiments are provided by way of example only. Those skilled in the art will think of many changes, modifications and alternatives without departing from the thought and spirit of the present application. It should be understood that in the process of practicing the present application, various alternatives to the embodiments of the present application described herein may be adopted.

[0057] The above are all preferred embodiments of the present application, and the protection scope of the present application is not limited thereto. Therefore, any equivalent changes made according to the structure, shape, and principle of the present application should be included in the protection scope of the present application.

Claims

1. A method for detecting the surface of an automobile lamp, characterized in that: Includes steps: Obtain lamp images and standard images under light sources of different intensities, calculate the similarity between the pixels of the lamp images and the pixels of the standard images, and obtain a similarity feature map based on the similarity; The points in the similarity feature graph whose similarity is greater than a preset threshold are marked as initial damage points, and the initial damage area is obtained according to the initial damage points; Calculate the damage evaluation, and take the initial damage area with the smallest damage evaluation in each lamp image as the optimal analysis area. The damage evaluation is the standard deviation or variance of the similarity set of initial damage points in the initial damage area; For any two lamp images under light sources of different intensities, the optimal analysis area with the largest area among the optimal analysis areas with overlapping positions is marked as the final damaged area; The ratio of the number of pixels in the final damaged area to the number of non-zero pixels in the entire area is used as a quality evaluation. In response to the quality evaluation being greater than a preset evaluation threshold, the detection result is unqualified.

2. The automobile lamp surface detection method according to claim 1, characterized in that: Calculate the similarity between the pixels of the lamp image and the pixels of the standard image, including: Any pixel point in the lamp image is taken as the target pixel point, and the pixel point in the standard image with the same position as the target pixel point is taken as the standard pixel point; Calculate the similarity between the target pixel and the standard pixel. The expression is: ,in, Indicates the degree of similarity, The feature vector representing the target pixel, The feature vector representing the standard pixel.

3. The automobile lamp surface detection method according to claim 2, characterized in that: Calculate the similarity between the pixels of the lamp image and the pixels of the standard image, including: Any pixel in the lamp image is taken as the target pixel, and the pixel in the standard image with the same position as the target pixel is taken as the standard pixel; the Euclidean distance between the target pixel and the standard pixel is taken as the similarity.

4. The automobile lamp surface detection method according to claim 2 or 3, characterized in that: The calculation formula of the target pixel feature vector is: , , ,in, is the target pixel, for The pixel value of Represents any pixel other than the target pixel. express The pixel value of represents the maximum value function, Indicates the maximum pixel difference of the target pixel. express and The distance between The feature vector representing the target pixel.

5. The automobile lamp surface detection method according to claim 2 or 3, characterized in that: The calculation formula of the target pixel feature vector is: , , ,in, is the target pixel, for The pixel value of Represents any pixel other than the target pixel. express The pixel value of represents the minimum function, Indicates the maximum pixel difference of the target pixel. express and The distance between The feature vector representing the target pixel.

6. The automobile lamp surface detection method according to claim 1, characterized in that: The acquisition of the lamp image includes: acquiring a color image of the lamp surface, gray-processing the color image to obtain a gray-scale image, and performing threshold segmentation on the gray-scale image to delete the background area to obtain the lamp image.

7. An automobile lamp surface detection system, characterized in that: include: A processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, the automobile lamp surface detection method according to any one of claims 1 to 6 is implemented.

Citation Information

Cited By

  • A method and system for intelligently identifying defects in automobile lamp housings

    CN120318238B