A method for detecting obstruction of an electronic exterior mirror of a vehicle
By employing image processing and texture feature analysis methods, the issues of accuracy and hardware cost in electronic rearview mirror occlusion detection have been resolved, enabling real-time occlusion recognition and a low false alarm rate in complex environments.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- FORYOU GENERAL ELECTRONICS
- Filing Date
- 2025-05-23
- Publication Date
- 2026-07-21
AI Technical Summary
In the existing technology, the electronic exterior rearview mirror occlusion detection method has problems such as low recognition accuracy, high hardware cost, high computational complexity and poor adaptability. In particular, the false alarm rate is high in complex lighting and dynamic occlusion scenarios, making it difficult to meet the real-time processing requirements.
Image processing techniques are used to simplify the captured image into a single-channel target image, perform image compression and interference frame filtering, extract texture features and perform texture restoration, combine frame difference calculation method and local density analysis to determine the occlusion area, and use pixel value summation and LOF value to help determine whether there is abnormal occlusion.
It improves the accuracy and adaptability of occlusion detection, reduces hardware resource requirements, reduces false alarm rate, and enables real-time occlusion recognition in complex environments.
Smart Images

Figure CN120912877B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent assisted driving technology, and in particular to a method for detecting obstruction of vehicle electronic exterior rearview mirrors. Background Technology
[0002] With the development of intelligent connected vehicle technology, electronic exterior rearview mirrors are gradually replacing traditional physical rearview mirrors, becoming an industry trend. Electronic exterior rearview mirrors typically use cameras to capture images and display them on a screen. However, in practical applications, the cameras of electronic exterior rearview mirrors are easily obstructed or blocked by stubs, resulting in poor image display and a reduced driver experience.
[0003] In existing technologies, lens occlusion is mainly identified in two ways:
[0004] (1) Deep learning algorithms are used. Although they have high recognition accuracy, they also have high requirements for hardware resources and require a large number of pre-labeled samples, which is costly. They also have poor adaptability and insufficient generalization ability for scenarios that have not been collected.
[0005] Specifically, deep learning algorithms require a large amount of labeled data to train models, but real-world road scenarios involve diverse occlusion types (such as rain, insect carcasses, and dust). Labeling is costly and incomplete, leading to a sharp drop in model recognition accuracy for unfamiliar occlusion types. Furthermore, deep learning methods typically have high computational complexity, while in-vehicle edge devices have limited computing power, making it difficult to meet real-time processing requirements. This results in delays in occlusion recognition, impacting driving safety.
[0006] (2) Image recognition algorithms are used to detect occluded areas. Image recognition algorithms rely on manually designed features, and the recognition effect is relatively consistent for various scenarios. They have low requirements for hardware resources, but the overall recognition accuracy is lower than that of deep learning methods that have been optimized for specific scenarios.
[0007] Specifically, image processing algorithms rely on specific scene assumptions and are poorly adaptable to scenarios with complex lighting and dynamic occlusion. For example, in backlit or low-contrast environments, algorithms are prone to misidentifying normal images as occlusions. Summary of the Invention
[0008] This invention provides a method for detecting occlusion in vehicle-mounted electronic rearview mirrors, which solves the problems of existing occlusion detection and recognition schemes based on traditional image algorithms and convolutional neural networks. The former has lower accuracy than the latter and requires a large amount of template matching and rule matching for post-processing; the latter has higher accuracy in specific scenarios, but is limited by the large number of parameters and computational load of convolutional neural networks, resulting in high hardware costs for implementation, high costs for data collection and annotation, and weak robustness and high false alarm rate of lens occlusion recognition, leading to low recognition accuracy and poor sensitivity.
[0009] To solve the above technical problems, the present invention provides a method for detecting obstruction of vehicle electronic exterior rearview mirrors, comprising the following steps:
[0010] The image captured by the vehicle's electronic rearview mirror is processed to obtain a single-channel target image.
[0011] The target image is processed by image compression based on image pixels and interference frame filtering to obtain the image to be detected;
[0012] The filtered image to be detected is obtained, and texture feature extraction is performed to obtain a texture image. Texture restoration is then performed in conjunction with texture augmentation.
[0013] The proportion of occlusion area is calculated based on the repaired texture image, and then the presence of abnormal occlusion is determined based on the frame difference statistical algorithm.
[0014] This basic solution is based on the requirements of vehicle-mounted electronic rearview mirror occlusion detection. On the one hand, it simplifies the acquired image into a single-channel target image through image processing, and performs image compression and interference frame filtering. This significantly reduces the data volume while preserving image features (the main structure and edge information of the image are still preserved), thereby improving detection and recognition efficiency and reducing costs. On the other hand, it performs texture feature extraction to obtain texture images, retains key texture patterns, and filters irrelevant details to improve the efficiency of subsequent processing. It also combines texture augmentation processing to perform texture repair. By analyzing surrounding texture features, it naturally augments missing parts to enhance the robustness of the model, thereby reducing false alarms and false negatives of abnormal occlusion. By optimizing image processing technology, it reduces the dependence on hardware resources and the cost investment.
[0015] In a further implementation, the proportion of occlusion area is calculated based on the repaired texture image, and then an abnormal occlusion is determined based on a frame difference statistical algorithm, including:
[0016] A1. Obtain the repaired texture image and divide it into several grid regions;
[0017] A2. Based on the summation and filtering of pixel values, identify whether each of the grid regions is occluded, and calculate the area ratio of the occluded grid regions relative to the texture image.
[0018] Based on the area ratio, determine whether there is occlusion in the current frame. If so, perform frame difference statistics based on the image position of the occluded area to determine whether there is abnormal occlusion and output the first conclusion.
[0019] A3. Calculate the LOF value of each grid region to help determine whether it is occluded, and count the area ratio of the occluded grid region relative to the texture image.
[0020] Based on the area ratio, determine whether there is occlusion in the current frame. If so, perform frame difference statistics based on the image position of the occluded area to determine whether there is abnormal occlusion and output a second conclusion.
[0021] A4. If the first conclusion and the second conclusion are consistent, then it is determined that there is abnormal occlusion.
[0022] In this solution, when detecting abnormal occlusion, "pixel value summation and filtering recognition" is used as a lightweight detection method. It compares the statistical differences in pixels between the normal state and the occluded state (e.g., occlusion may cause overall darkening or color abrupt changes), sets a threshold to confirm the occluded area, and has low computational load and strong real-time performance. At the same time, "LOF value assisted judgment" is used to identify occlusion by analyzing the density deviation of local areas of the image. It automatically adapts to the data distribution, can detect unknown occlusion types, and can adapt to harsh scenes such as rain, fog, backlight, and cold regions. Finally, pixel value summation and filtering recognition and LOF value assisted judgment are introduced to perform frame difference statistics and comparative verification to avoid interference from shooting anomalies, thereby improving computational efficiency while maintaining detection accuracy.
[0023] In a further implementation, the method identifies whether each grid region is occluded based on the summation of pixel values and calculates the area ratio of the occluded grid region relative to the texture image. Specifically, the method calculates the sum of pixel values for each grid region, determines whether the sum of pixel values is greater than a preset summation threshold, and marks the corresponding grid region as 1 to indicate that it is occluded if it is, otherwise it is marked as 0. The method calculates the total number of occluded grid regions and combines it with the total number of regions in the texture image to calculate the area ratio.
[0024] This solution quickly filters suspicious areas by summing pixels, offering high real-time performance and low cost.
[0025] In a further implementation, the LOF value of each grid region is calculated to help determine whether it is occluded, and the area ratio of the occluded grid region relative to the texture image is counted. Specifically, the LOF value of each grid region is calculated, and the density of the corresponding grid region is determined according to the LOF value. If the density is inconsistent with the surrounding grid regions, the corresponding grid region is marked as 1, indicating that it is occluded; otherwise, it is marked as 0. The total number of occluded marked grid regions is counted, and the area ratio is calculated in combination with the total number of regions of the texture image.
[0026] This solution uses the LOF value to determine whether the density of the corresponding grid area is inconsistent with that of the surrounding grid areas, and to determine whether it is occluded. It can adapt to complex occlusion situations and has good robustness.
[0027] In a further implementation, the current frame is judged to have occlusion based on the area ratio. If so, frame difference statistics are performed based on the image position of the occluded area to determine whether there is abnormal occlusion. Specifically:
[0028] Based on the area ratio and the preset occlusion threshold, it is determined whether the current frame has an occlusion situation. When it is determined that the first conclusion / second conclusion indicates that there is abnormal occlusion, it is further determined whether the texture images of multiple consecutive frames have an occlusion situation. If so, the image position of the occluded area on the texture image of each frame is obtained, and the frame difference is statistically analyzed on the image position. If the positions are consistent, it is determined that there is abnormal occlusion.
[0029] This scheme uses multi-feature input, including pixel value summation filtering and LOF value-assisted judgment, to further calculate the area ratio of the occluded region to the total area of the rearview mirror through grid segmentation. If the area ratio exceeds a preset occlusion threshold, an occlusion is determined. By reducing data dimensionality, the scheme achieves high computational efficiency. Based on the persistence of actual occlusion, it judges whether occlusion occurs in multiple consecutive frames of the texture image and whether the image position of the occluded region on the texture image is consistent, thus avoiding false alarms and improving the anti-interference capability and reliability of occlusion detection.
[0030] In a further implementation, the repaired texture image is obtained and then divided into several grid regions. Specifically, the repaired texture image is obtained, the texture image is normalized, and the texture image is divided into several grid regions according to a preset division ratio.
[0031] This scheme eliminates the influence of uneven lighting on texture features by normalizing the texture image and reduces environmental interference; while dividing the texture image into grid regions and performing local focusing significantly improves the accuracy and adaptability of occlusion detection, especially suitable for partially occluded scenes in complex environments, thereby improving the adaptability of occlusion detection to different environments.
[0032] In a further implementation scheme, the image captured by the vehicle's electronic rearview mirror is obtained, and image processing is performed to obtain a single-channel target image, including:
[0033] Acquire images from the vehicle's left / right electronic exterior rearview mirrors;
[0034] Perform decoding to deserialize the captured image into an image layer in YUV420 data format;
[0035] The image layer is converted to pixel size format, and the single-channel image of the Y component of the image is obtained and stored as the target image in the image queue.
[0036] This solution employs two steps of pixel compression: image layer deserialization into YUV420 data format and pixel size format conversion. This significantly reduces the amount of data while preserving image features, thereby lowering hardware costs and improving computational efficiency.
[0037] In a further embodiment, the target image undergoes image processing, including image compression based on image pixels and interference frame filtering, to obtain the image to be detected, including:
[0038] The target image is obtained from the image queue, and the image pixel values of the target image are right-shifted by 4 bits to achieve image compression;
[0039] Traverse each pixel in the compressed target image, count the image pixel values, and determine the pixel value with the largest total number of pixels as a reference value.
[0040] Determine whether the reference value is greater than the pixel filtering threshold. If it is, output the compressed target image as the image to be detected; otherwise, filter the target image.
[0041] This solution uses a 4-bit right shift operation on the image pixel values to achieve image compression, directly reducing storage space by 50%, with good real-time performance and extremely low resource consumption.
[0042] In a further implementation, texture feature extraction is performed to obtain a texture image, including:
[0043] The image to be detected is subjected to horizontal integration to extract texture features and obtain horizontal gradient components, thereby obtaining a horizontal feature image.
[0044] The image to be detected is subjected to vertical integration to extract texture features and obtain vertical gradient components, thereby obtaining a vertical feature image.
[0045] The intensity of the edge texture is calculated based on the horizontal feature image and the vertical feature image to obtain the texture image.
[0046] This scheme performs horizontal and vertical integration operations simultaneously on the image to be detected to extract texture features. The intensity of edge texture is calculated based on the horizontal and vertical feature images to obtain a texture image. By combining directional analysis and statistical features, the computational efficiency is high. While ensuring speed, it can effectively capture the structured information of the texture (through texture extraction, the integral curve of the occluded area of the rearview mirror is significantly different from that of the clean mirror surface, which helps in the subsequent abnormal occlusion identification).
[0047] In a further implementation, texture restoration is performed in conjunction with texture augmentation processing, including:
[0048] The texture image is subjected to threshold binarization to obtain a grayscale image;
[0049] An opening operation is performed on the grayscale image. First, the image is eroded to remove noise points in the grayscale image. Then, dilation is performed to enlarge the binarized texture to achieve texture restoration.
[0050] This scheme first performs threshold binarization to reduce computational complexity and facilitate subsequent analysis. Then, it performs an opening operation on the grayscale image, first eroding the image to remove noise points in the grayscale image, and then performs dilation to amplify the binarized texture to achieve texture restoration. By analyzing the surrounding texture, the texture of the occluded part is naturally generated to fill the missing area and maintain the general outline of the target. Attached Figure Description
[0051] Figure 1 This is a flowchart illustrating the process of a vehicle-mounted electronic exterior rearview mirror occlusion detection method provided in an embodiment of the present invention.
[0052] Figure 2 These are comparison images of different scenes provided in the embodiments of the present invention. Detailed Implementation
[0053] The embodiments of the present invention are described in detail below with reference to the accompanying drawings. The embodiments are given for illustrative purposes only and should not be construed as limiting the present invention. The accompanying drawings are for reference and illustration only and do not constitute a limitation on the scope of patent protection of the present invention, because many changes can be made to the present invention without departing from the spirit and scope of the present invention.
[0054] This invention provides a method for detecting obstruction of a vehicle's electronic exterior rearview mirror, such as... Figure 1 , Figure 2 As shown, in this embodiment, steps S1 to S5 are included:
[0055] S1. Acquire the image captured by the vehicle's electronic exterior rearview mirror, perform image processing to obtain a single-channel target image, including:
[0056] S11. Acquire the images captured by the vehicle's left / right electronic exterior rearview mirrors;
[0057] S12. Perform decoding to deserialize the captured image into an image layer in YUV420 data format;
[0058] Specifically, the images captured by the electronic rearview mirror are deserialized into an image layer in YUV420 data format by the data stream transmission module of the RTOS system.
[0059] S13. Perform pixel size format conversion on the image layer, and store the single-channel image of the Y component of the image as the target image in the image queue.
[0060] For example, the YUV420 image layer is transmitted to the LINUX system via IPC and CAN. The application layer only obtains the 680x360 image buffer for format conversion to obtain a single-channel image of the Y component.
[0061] This embodiment achieves pixel compression through two steps: image layer deserialization into YUV420 data format and pixel size format conversion. This significantly reduces the amount of data while preserving image features, thereby reducing hardware costs and improving computational efficiency.
[0062] S2. Perform image processing on the target image, including image compression based on image pixels and interference frame filtering, to obtain the image to be detected, including:
[0063] The target image is obtained from the image queue, and the image pixel values of the target image are right-shifted by 4 bits to achieve image compression, compressing the image pixel values to between 0 and 16.
[0064] Traverse each pixel in the compressed target image, count the image pixel values, and determine the pixel value with the largest total number of pixels as a reference value.
[0065] Determine whether the reference value is greater than the pixel filtering threshold. If it is, output the compressed target image as the image to be detected; otherwise, filter the target image.
[0066] In this embodiment, the calculation formula for image compression is as follows:
[0067]
[0068] In the formula, Y represents the original pixel value of the Y component image obtained from the data queue, and its value range is 0≤Y≤255; n represents the number of bits to shift to the right, and here n=4, the purpose of which is to compress the pixel value to the range of 0 to 16; shifting to the right by n bits is equivalent to dividing the original pixel value by 2. n And round down; the f(x) operation represents the number of times the compressed pixel value appears in the image.
[0069] The pixel filtering threshold can be selected based on the number of bits shifted to the right, and in this embodiment, it is preferably 3.
[0070] This embodiment uses a 4-bit right shift operation on the image pixel values to achieve image compression, directly reducing storage space by 50%, with good real-time performance and extremely low resource consumption.
[0071] S3. Obtain the filtered image to be detected, perform texture feature extraction processing to obtain a texture image, and combine texture augmentation processing to perform texture restoration;
[0072] In this embodiment, texture feature extraction is performed to obtain a texture image, including:
[0073] S3a. Perform a horizontal integration operation on the image to be detected to extract texture features and obtain the horizontal gradient component, resulting in a horizontal feature image. The calculation formula is as follows:
[0074]
[0075] The horizontal core is:
[0076]
[0077] S3b. Perform vertical integration on the image to be detected to extract texture features and obtain the vertical gradient component, resulting in a vertical feature image. The calculation formula is as follows:
[0078]
[0079] The vertical core is:
[0080]
[0081] S3c. Calculate the intensity of the edge texture based on the horizontal feature image and the vertical feature image to obtain the texture image. The calculation formula is as follows:
[0082]
[0083] In the formula, I(x,y) represents the Y component value of the image at coordinates (x,y), and K x K y These represent the Sobel convolution kernels in the horizontal and vertical directions, respectively. The index offsets of kernels i and j (relative to the center pixel, with values ranging from -1, 0, 1) and G... x (x,y) represents the horizontal gradient component at the image location, G y (x,y) represents the vertical gradient component at the image, and G(x,y) represents the intensity of the edge texture.
[0084] In this embodiment, horizontal and vertical integration operations are performed simultaneously on the image to be detected to extract texture features. The intensity of edge texture is calculated based on the horizontal and vertical feature images to obtain a texture image. By combining directional analysis and statistical features, the computational efficiency is high. While ensuring speed, the structured information of the texture can be effectively captured (through texture extraction, the integral curve of the occluded area of the rearview mirror is significantly different from that of the clean mirror surface, which helps in the subsequent abnormal occlusion identification).
[0085] In this embodiment, texture restoration is performed in conjunction with texture augmentation processing, including:
[0086] S3A. Threshold binarization is performed on the texture image to obtain a grayscale image;
[0087] For example, iterate through the pixel value of each pixel in the texture image, and if the pixel value is >50, set it to 255; otherwise, set it to 0.
[0088] S3B. Perform an opening operation on the grayscale image. First, erode the image to remove noise points from the grayscale image. Then, perform dilation to enlarge the binarized texture to achieve texture restoration. The calculation formula is as follows:
[0089] O=((I≥50)*S)⊕S
[0090] In the formula, I represents the original grayscale image as input, with pixel values ranging from [0, 255]. *S refers to the texture structure operation, which in the above formula represents erosion. ⊕S refers to the texture structure operation, which in the above formula represents dilation.
[0091] This embodiment first performs threshold binarization to reduce computational complexity and facilitate subsequent analysis; then it performs an opening operation on the grayscale image, first eroding the image to remove noise points in the grayscale image, and then performs dilation to amplify the binarized texture to achieve texture restoration; by analyzing the surrounding texture, the texture of the occluded part is naturally generated to fill the missing area and maintain the general outline of the target.
[0092] S4. Calculate the occlusion area ratio based on the repaired texture image, and then determine whether there is abnormal occlusion based on the frame difference statistics algorithm, including A1 to A4:
[0093] A1. Obtain the repaired texture image and perform gridding to obtain several grid regions. Specifically, obtain the repaired texture image, normalize the texture image, and perform gridding to obtain several grid regions according to a preset division ratio.
[0094] For example: normalize the image to change the value of the binarized image from [0,255] to [0,1]; divide the normalized image into grid blocks with a ratio of 4x3, and statistically divide it into 12 square regions as grid regions.
[0095] This embodiment eliminates the influence of uneven lighting on texture features by normalizing the texture image, thereby reducing environmental interference. Furthermore, dividing the texture image into grid regions and performing local focusing significantly improves the accuracy and adaptability of occlusion detection, making it particularly suitable for partially occluded scenes in complex environments, thus enhancing the adaptability of occlusion detection to different environments.
[0096] A2. Based on the summation and filtering of pixel values, identify whether each of the grid regions is occluded, and calculate the area ratio of the occluded grid region relative to the texture image; determine whether the current frame has an occlusion situation based on the area ratio; if so, perform frame difference statistics based on the image position of the occluded region to determine whether there is abnormal occlusion, and output the first conclusion, specifically as follows:
[0097] A21. Calculate the total pixel value of each grid region, and determine whether the total pixel value is greater than the preset total threshold sumArea (e.g., sumArea>30). If so, mark the corresponding grid region as 1, indicating that it is occluded; otherwise, mark it as 0. Calculate the total number of occlusions of the marked grid regions, and calculate the area ratio in combination with the total number of regions of the texture image.
[0098] A22. Based on the area ratio and the preset occlusion threshold, determine whether the current frame has an occlusion situation. When it is determined that the first conclusion indicates that there is abnormal occlusion, further determine whether the texture images of multiple consecutive frames have an occlusion situation. If so, obtain the image position of the occluded area on the texture image of each frame, and perform frame difference statistics on the image position. If the positions are consistent, then it is determined that there is abnormal occlusion.
[0099] In this embodiment, the preset occlusion threshold can be set according to actual needs, for example, 50%.
[0100] This embodiment quickly filters suspicious areas by summing pixels, offering high real-time performance and low cost.
[0101] A3. Calculate the LOF value of each grid region to help determine whether it is occluded, and count the area ratio of the occluded grid region relative to the texture image; determine whether occlusion occurs in the current frame based on the area ratio; if so, perform frame difference statistics based on the image position of the occluded region to determine whether there is abnormal occlusion, and output a second conclusion, specifically:
[0102] A31. Calculate the LOF value of each grid region. Based on the LOF value, determine whether the density of the corresponding grid region is inconsistent with that of the surrounding grid regions. If so, mark the corresponding grid region as 1, indicating that it is occluded; otherwise, mark it as 0. Count the total number of occlusions of the marked grid regions and calculate the area ratio in combination with the total number of regions of the texture image.
[0103] LOF stands for Local Outlier Factor, which calculates the local density deviation of a given data point relative to its neighbors. It considers samples with significantly lower density than their neighbors as outliers. The formula for the LOF value is as follows:
[0104]
[0105] In the formula:
[0106] p represents the grid block whose LOF value needs to be calculated;
[0107] q and r represent other grid blocks related to p, which are used to traverse the neighborhood and calculate parameters such as distance and density during the calculation process;
[0108] k is a pre-defined integer used to determine the neighborhood range; in this method, the value is 7.
[0109] d(p,q) represents the Euclidean distance between p and q;
[0110] d(q,r) represents the Euclidean distance between q and r;
[0111] k_disance(r) indicates that there exists a distance d such that grid block r has at least k neighbors (including r itself) whose distance from r is not greater than d, and at most k-1 neighbors whose distance from r is less than d. It determines the range of the k-neighborhood of r. k_disance(q) is similar.
[0112] Nk(p) refers to the set of all grid blocks whose distance from p is less than or equal to k_distance(p), i.e., the k-neighborhood of p;
[0113] |Nk(p)| represents the number of grid blocks in the set, i.e. the size of the neighborhood, and is used for density calculation and weight assignment;
[0114] Nk(q) is a k-neighborhood defined with a neighboring grid block q of grid block p as its core, used to calculate the local reachability density of q;
[0115] |Nk(q)| represents the number of grid blocks in the set, i.e., the size of the neighborhood.
[0116] This embodiment uses the LOF value to determine whether the density of the corresponding grid area is inconsistent with that of the surrounding grid areas, and to determine whether it is occluded. It can adapt to complex occlusion situations and has good robustness.
[0117] A32. Based on the area ratio and the preset occlusion threshold, determine whether the current frame has an occlusion situation. When it is determined that the second conclusion indicates that there is abnormal occlusion, further determine whether the texture images of multiple consecutive frames have an occlusion situation. If so, obtain the image position of the occluded area on the texture image of each frame, and perform frame difference statistics on the image position. If the positions are consistent, then it is determined that there is abnormal occlusion.
[0118] This embodiment uses multi-feature input, including pixel value summation filtering and LOF value-assisted judgment, to further calculate the area ratio of the occluded region to the total area of the rearview mirror through grid segmentation. If the area ratio exceeds a preset occlusion threshold, an occlusion is determined to have occurred. By reducing data dimensionality, the calculation efficiency is high. Based on the persistence of actual occlusion, the system judges whether occlusion occurs in multiple consecutive frames of the texture image and whether the image positions of the occluded areas on the texture image are consistent, thus avoiding false alarms and improving the anti-interference capability and reliability of occlusion detection.
[0119] A4. If the first conclusion and the second conclusion are consistent, then it is determined that there is abnormal occlusion.
[0120] In this embodiment, steps A2 and A3 are only for explanation and do not restrict the order of the steps.
[0121] In this embodiment, when performing abnormal occlusion detection, "pixel value summation filtering and recognition" is used as a lightweight detection method. It compares the statistical differences in pixels between the normal state and the occluded state (e.g., occlusion may cause overall darkening or color abrupt changes), sets a threshold to confirm the occluded area, and has low computational load and strong real-time performance. At the same time, "LOF value assisted judgment" is used to identify occlusion by analyzing the density deviation of local areas of the image. It automatically adapts to the data distribution, can detect unknown occlusion types, and can adapt to harsh scenes such as rain, fog, backlight, and cold regions. Finally, pixel value summation filtering and recognition and LOF value assisted judgment are introduced to perform frame difference statistics and comparative verification to avoid interference such as shooting anomalies, thereby improving computational efficiency while maintaining detection accuracy.
[0122] S5. Provide alarm prompts based on abnormal obstruction, including but not limited to voice reminders, central control screen reminders, and sound and light alarms.
[0123] All experiments used scene detection rate and scene false detection rate as evaluation indicators. The tests included scenarios such as cold regions, rainy days, smog, parking lots, normal roads, and low light. Among them, there were 50 normal scenarios and 50 artificially created occlusion scenarios, for a total of 100 test scenarios.
[0124] The test results are as follows:
[0125] Method Detected cases Error detection example Detection rate Error detection rate CoverDet 44 7 88% 14% Ours 43 4 86% 8%
[0126] In the table above, the detection examples are 50 instances that were correctly detected in human-occluded scenes, and the detection rate is the percentage of instances that were correctly detected in human-occluded scenes. The error detection examples are 50 instances that were detected incorrectly in normal scenes, and the error detection rate is the percentage of instances that were detected incorrectly in normal scenes. For mass production, the lower the error detection rate, the better, and it has a higher priority than the detection rate.
[0127] CoverDet is a detection method based on deep learning. As shown in the table above, the detection rate of the deep learning method is higher than that of the method proposed in this embodiment, but the two are close. In terms of error detection rate, the deep learning method is limited by the prior knowledge of data training and has a high false detection rate in untrained scenarios, while the method proposed in this embodiment has a much lower false detection rate than the deep learning method and has higher robustness.
[0128] Using this solution to conduct random scenario tests yields the following results: Figure 2 The images, from left to right, show a cold region scene, a parking lot scene, a parking lot scene, and a scene with artificial obstruction. From top to bottom, they show the captured image, a grayscale image, and a grid area marker map.
[0129] The area of the cold region scene accounts for 5 / 12, which is less than 50%, so it is judged as unobstructed, and the detection and recognition are the same as the actual scene.
[0130] The parking lot scene occupies 4 / 12 of the area, which is less than 50%, so it is judged to be unobstructed, and the detection and recognition are the same as in the actual scene.
[0131] The area of the scene artificially occluded accounts for 8 / 12, which is greater than 50%, so it is judged as abnormal occlusion, and the detection and recognition are the same as the actual scene.
[0132] Based on the experimental conclusions of the above three scenarios, the occlusion detection in this embodiment has high robustness, good adaptability, and high detection accuracy.
[0133] This invention, based on the requirement of vehicle-mounted electronic rearview mirror occlusion detection, simplifies the acquired image into a single-channel target image through image processing, performs image compression and interference frame filtering, thereby significantly reducing the data volume while preserving image features (the main structure and edge information of the image are still retained), thus improving detection and recognition efficiency and reducing costs. On the other hand, texture feature extraction is performed to obtain a texture image, preserving key texture patterns and filtering irrelevant details to improve subsequent processing efficiency. Texture restoration is combined with texture augmentation processing, which naturally augments missing parts by analyzing surrounding texture features to enhance model robustness, thereby reducing false alarms and false negatives of abnormal occlusion. By optimizing image processing technology, the dependence on hardware resources and cost investment are reduced.
[0134] The above embodiments are preferred embodiments of the present invention, but the embodiments of the present invention are not limited to the above embodiments. Any changes, modifications, substitutions, combinations, or simplifications made without departing from the spirit and principle of the present invention shall be considered equivalent substitutions and shall be included within the protection scope of the present invention.
Claims
1. A method for detecting obstruction of a vehicle-mounted electronic exterior rearview mirror, characterized in that, Including the following steps: The image captured by the vehicle's electronic rearview mirror is processed to obtain a single-channel target image. The target image is processed by image compression based on image pixels and interference frame filtering to obtain the image to be detected; The filtered image to be detected is obtained, and texture feature extraction is performed to obtain a texture image. Texture restoration is then performed in conjunction with texture augmentation. The occlusion area ratio is calculated based on the repaired texture image, and then an abnormal occlusion is determined using a frame difference statistical algorithm, including: A1. Obtain the repaired texture image and divide it into several grid regions; A2. Based on the summation and filtering of pixel values, identify whether each of the grid regions is occluded, and calculate the area ratio of the occluded grid regions relative to the texture image. Based on the area ratio, determine whether there is occlusion in the current frame. If so, perform frame difference statistics based on the image position of the occluded area to determine whether there is abnormal occlusion and output the first conclusion. A3. Calculate the LOF value of each grid region to help determine whether it is occluded, and count the area ratio of the occluded grid region relative to the texture image. Based on the area ratio, determine whether there is occlusion in the current frame. If so, perform frame difference statistics based on the image position of the occluded area to determine whether there is abnormal occlusion and output a second conclusion. A4. If the first conclusion and the second conclusion are consistent, then it is determined that there is abnormal occlusion.
2. The method for detecting obstruction of a vehicle-mounted electronic rearview mirror as described in claim 1, characterized in that, The identification of whether each grid region is occluded is based on the summation of pixel values, and the area ratio of the occluded grid region relative to the texture image is calculated. Specifically, the sum of pixel values of each grid region is calculated, and it is determined whether the sum of pixel values is greater than a preset sum threshold. If it is, the corresponding grid region is marked as 1, indicating that it is occluded; otherwise, it is marked as 0. The total number of occluded grid regions is counted, and the area ratio is calculated in combination with the total number of regions of the texture image.
3. The method for detecting obstruction of a vehicle-mounted electronic rearview mirror as described in claim 1, characterized in that, The LOF value of each grid region is calculated to help determine whether it is occluded, and the area ratio of the occluded grid region relative to the texture image is counted. Specifically, the LOF value of each grid region is calculated, and the corresponding grid region is determined to have a density inconsistent with the surrounding grid regions based on the LOF value. If so, the corresponding grid region is marked as 1, indicating that it is occluded; otherwise, it is marked as 0. The total number of occluded grid regions is counted, and the area ratio is calculated in combination with the total number of regions in the texture image.
4. The method for detecting obstruction of a vehicle-mounted electronic rearview mirror as described in claim 1, characterized in that, Based on the area ratio, it is determined whether the current frame has occlusion. If so, frame difference statistics are performed based on the image position of the occluded area to determine whether there is abnormal occlusion. Specifically: Based on the area ratio and the preset occlusion threshold, it is determined whether the current frame has an occlusion situation. When it is determined that the first conclusion / second conclusion indicates that there is abnormal occlusion, it is further determined whether the texture images of multiple consecutive frames have an occlusion situation. If so, the image position of the occluded area on the texture image of each frame is obtained, and the frame difference is statistically analyzed on the image position. If the positions are consistent, it is determined that there is abnormal occlusion.
5. The method for detecting obstruction of a vehicle-mounted electronic rearview mirror as described in claim 1, characterized in that, The repaired texture image is obtained and then divided into several grid regions. Specifically, the repaired texture image is obtained, the texture image is normalized, and the texture image is divided into several grid regions according to a preset division ratio.
6. The method for detecting obstruction of a vehicle-mounted electronic rearview mirror as described in claim 1, characterized in that, The image captured by the vehicle's electronic rearview mirror is processed to obtain a single-channel target image, including: Acquire images from the vehicle's left / right electronic exterior rearview mirrors; Perform decoding to deserialize the captured image into an image layer in YUV420 data format; The image layer is converted to pixel size format, and the single-channel image of the Y component of the image is obtained and stored as the target image in the image queue.
7. The method for detecting obstruction of a vehicle-mounted electronic rearview mirror as described in claim 1, characterized in that, The target image is processed by performing image compression based on image pixels and filtering out interference frames to obtain the image to be detected, including: The target image is obtained from the image queue, and the image pixel values of the target image are right-shifted by 4 bits to achieve image compression; Traverse each pixel in the compressed target image, count the image pixel values, and determine the pixel value with the largest total number of pixels as a reference value. Determine whether the reference value is greater than the pixel filtering threshold. If it is, output the compressed target image as the image to be detected; otherwise, filter the target image.
8. The method for detecting obstruction of a vehicle-mounted electronic exterior rearview mirror as described in claim 7, characterized in that, Texture feature extraction is performed to obtain a texture image, including: The image to be detected is subjected to horizontal integration to extract texture features and obtain horizontal gradient components, thereby obtaining a horizontal feature image. The image to be detected is subjected to vertical integration to extract texture features and obtain vertical gradient components, thereby obtaining a vertical feature image. The intensity of the edge texture is calculated based on the horizontal feature image and the vertical feature image to obtain the texture image.
9. The method for detecting obstruction of a vehicle-mounted electronic rearview mirror as described in claim 1, characterized in that, Texture restoration is performed in conjunction with texture augmentation, including: The texture image is subjected to threshold binarization to obtain a grayscale image; An opening operation is performed on the grayscale image. First, the image is eroded to remove noise points in the grayscale image. Then, dilation is performed to enlarge the binarized texture to achieve texture restoration.