Vehicle camera fault positioning method and system, storage medium and equipment
By combining hardware line detection and video image quality evaluation in the vehicle camera failure positioning, the problem of large data volume and artificial identification difficulties in existing technologies, achieved rapid and accurate fault positioning, and improved monitoring effects and user security.
Patent Information
- Application Number
- CN202411286851.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-13
- Publication Date
- 2025-01-24
AI Technical Summary
The prior art has problems such as large amount of data, difficulty in manual identification, and time-consuming in the process of fault location of vehicle cameras, which affects monitoring effect and user safety.
By combining hardware line detection and video image quality assessment, the auxiliary image abnormal detection is performed for fault positioning. Specific steps include real -time monitoring of the operating status of the camera, judging the hardware failure, and determining the cause of the fault through the image quality assessment.
The efficient detection of camera images has been achieved, the cost of manpower is reduced, the fault position is quickly and accurately located, and the safety of vehicles and users is improved.
Smart Images

Figure CN119363965A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of vehicle-mounted equipment fault location, and in particular relates to a vehicle camera fault location method, system, storage medium and equipment. Background Art
[0002] With the rapid development of smart car technology, the demand for cameras in car applications has gradually increased. This also places higher requirements on the stability of the camera system. Failure of any node in the link will cause abnormalities such as black images and distorted screens on the back-end display, and even bring safety risks to vehicles and users.
[0003] At present, when a car camera fails during the development phase, users are required to capture log data and transfer it to R&D for analysis, which takes a long time. However, a large number of cameras generate a large number of data images. In order to analyze the data quality in the images, managers need to identify and screen the video image content. If there is a problem with the video image quality before processing the video image, it will affect subsequent operations. When there is a quality problem with the video image, accurate video image information cannot be obtained, which affects the subsequent analysis and processing of the image by managers and greatly affects the monitoring effect. In addition, relying solely on current manual recognition to obtain specific fault information in the image is not only a heavy burden for the staff, but also difficult to accurately obtain effective information in the image. Summary of the invention
[0004] Based on this, it is necessary to provide a vehicle camera fault location method, system, storage medium and device to address the above technical problems, combine hardware circuit detection and video image quality evaluation and adjustment, and assist in fault location problems in image anomaly detection.
[0005] In order to achieve the above-mentioned object of the invention, the present invention adopts the following technical scheme:
[0006] In a first aspect, the present invention provides a method for locating a fault of a vehicle camera, comprising:
[0007] Respond to the camera driver command to start the camera in the link;
[0008] Monitor the operating status of the camera in real time. When it is detected that the camera cannot output images, determine the hardware failure of the camera based on the collected information related to the camera hardware, and insert a fault information mark describing the cause of the hardware failure into the external input simulation image and display it on the screen;
[0009] Perform fault repair based on the fault information displayed on the screen until the camera function returns to normal;
[0010] When a fault occurs and causes the image collected by the camera to display abnormally, the image quality abnormality is evaluated based on the image quality related information of the camera;
[0011] Combined with the evaluation results of the camera's hardware failure and image quality abnormality, key information during the camera's operation is determined; after the camera fails, the fault is located based on the key information.
[0012] Optionally, the camera hardware related information includes: camera power control status, camera deserializer status, camera serializer status, and platform driver operation status.
[0013] Optionally, obtaining the abnormal display of an image collected by a camera due to the occurrence of the fault includes:
[0014] According to the pre-selected automated test items, perform automated tests on image quality, and automatically report the test results obtained by the automated tests; wherein the automated test items include a black image anomaly detection function;
[0015] The black image anomaly detection function is used to identify the black image phenomenon in the image, and store the black image anomaly image frames with the black image phenomenon in the disk.
[0016] Optionally, the identifying a black image phenomenon in an image includes:
[0017] Calculate all pixels of the displayed image and obtain any pixel in the displayed image as a pixel to be tested;
[0018] Calculate the grayscale value of the pixel to be tested. Based on the judgment principle that the higher the black pixel rate of the grayscale value, the darker the image, define the pixel whose grayscale value is less than the first preset threshold as a black pixel, and judge whether there is a black screen phenomenon according to the black pixel rate of the image.
[0019] Optionally, defining pixels whose grayscale values are less than a first preset threshold as black pixels, and judging whether a black screen phenomenon exists according to a black pixel rate of the image includes:
[0020] Determine the size between the grayscale value of the pixel and a first preset threshold; if the grayscale value of the pixel is less than the first preset threshold, count it as a black pixel; otherwise, obtain the next pixel in the displayed image as the pixel to be tested, calculate the grayscale value of the pixel to be tested, determine the size between the grayscale value of the pixel and the preset threshold, and accumulate the number of black pixels according to the determination result;
[0021] Determine the black pixel rate according to the proportion of the accumulated number of black pixels in all pixels;
[0022] Comparing the black pixel ratio with a preset black pixel determination threshold, and if the black pixel ratio exceeds the preset black pixel determination threshold, determining that the currently displayed image is an abnormal image;
[0023] The number of times that the black pixel rate in the abnormal image is greater than the black image judgment threshold is defined as the number of black images; when the number of black images exceeds the second preset threshold, the image has a black image phenomenon.
[0024] Optionally, the evaluating of image quality abnormality based on the image quality related information of the camera includes:
[0025] Collecting information related to the image quality of the camera; wherein the information related to the image quality of the camera includes: brightness, clarity, noise and distortion parameters of the image frame;
[0026] Read the black image abnormality frame from the disk, use any one of the brightness, clarity, noise and distortion parameters as an evaluation parameter for analyzing the image quality abnormality, and further analyze the cause of the abnormality;
[0027] Read the black image abnormality frames in the disk and calculate the evaluation parameters of each image frame;
[0028] When an abnormal jump in the evaluation parameter value of an image frame is identified, an influence range of the abnormal image frame where the evaluation parameter value jump occurs is defined, adjacent normal image frames are cached within the defined influence range of the abnormal image frame, and an abnormal flag associated with the evaluation parameter is added to the abnormal image frame where the evaluation parameter value jump occurs, to obtain an image frame carrying the abnormal flag;
[0029] Trigger the image transfer and storage process, and store the image frame carrying the abnormal identification and the adjacent image frames of the abnormal image frame as image display abnormality information to the disk;
[0030] The image display abnormality information in the disk is added to the image as a watermark, and the image with the watermark is uploaded to the application through a link for display.
[0031] Optionally, the determining key information during the operation of the camera, and locating the fault based on the key information when the camera fails, includes:
[0032] The hardware failure of the camera and the abnormal evaluation results of the image quality are defined as the key information in the operation process of the camera;
[0033] Combined with key information during camera operation, determine the camera fault location and its impact range, including the cause of the fault, the fault point, and the affected area associated with the fault point.
[0034] In a second aspect, the present invention provides a vehicle camera fault location system, the system is arranged in a vehicle host, connected to at least one camera and a display screen, and includes:
[0035] A response module, used to respond to a camera driver instruction to start the camera in the link;
[0036] The hardware fault detection module monitors the operating status of the camera in real time. When it is detected that the camera cannot output images, the hardware fault of the camera is determined based on the collected information related to the camera hardware, and a fault information mark describing the cause of the hardware fault is inserted into the external input simulation image and displayed on the screen;
[0037] A repair module is used to repair the fault based on the fault information displayed on the screen until the camera function returns to normal;
[0038] An image quality assessment module, used to assess the image quality abnormality based on the image quality related information of the camera when a fault occurs and causes the image collected by the camera to display abnormally;
[0039] The abnormal data analysis module is used to determine the key information during the operation of the camera by combining the evaluation results of the camera's hardware failure and image quality abnormality; after the camera fails, the fault is located based on the key information.
[0040] In a third aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method steps described in any one of the first aspects.
[0041] In a fourth aspect, the present invention provides an electronic device, comprising a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor executes the method steps described in any one of the first aspects.
[0042] Compared with the closest prior art, the present invention has the following beneficial effects:
[0043] Through the vehicle camera fault location method, system, storage medium and device proposed in the present invention, based on image processing technology, an objective and efficient detection algorithm for camera images is established, which can identify display anomalies caused by possible hardware line failures in the camera, and assist in locating image quality problems through image quality evaluation; automatic detection of image quality is realized to reduce labor costs.
[0044] The vehicle camera fault location method, system, storage medium and device proposed in the present invention obtain key information during the camera operation process by integrating the collected camera-related hardware faults and image quality anomalies; when the camera fails, the vehicle camera fault can be directly located with the help of the above information. Among them, by combining the above two categories to obtain hardware status and image quality information, it can be known whether the fault occurs in hardware or software, and a comprehensive analysis can be performed based on the above problems.
[0045] In addition, the cause of the camera failure obtained by the vehicle camera fault location method, system, storage medium and device proposed in the present invention is directly displayed on the screen, helping the user to quickly determine the cause of the problem and improve the user interaction experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] The accompanying drawings are only used to illustrate specific embodiments and are not considered to limit the present invention. In the entire drawings, the same reference symbols represent the same components. Obviously, the drawings described below are only some embodiments described in the embodiments of the present invention. For those skilled in the art, other drawings can also be obtained based on these drawings;
[0047] Figure 1 A diagram of a fault location network for a vehicle camera according to an embodiment of the present invention;
[0048] Figure 2 A flow chart of a method for locating a fault of a vehicle camera according to an embodiment of the present invention;
[0049] Figure 3 A black screen phenomenon test flow chart provided in an embodiment of the present application;
[0050] Figure 4 A schematic diagram of the structure of a fault location system for a vehicle camera according to an embodiment of the present invention;
[0051] Figure 5 The figure is a schematic diagram of the structure of an electronic device in an embodiment of the present invention. DETAILED DESCRIPTION
[0052] The following embodiments of the technical solution of the present invention are described in detail in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present invention, and are therefore only used as examples, and cannot be used to limit the protection scope of the present invention.
[0053] See also Figure 1 , Figure 1This is a network architecture diagram of a vehicle camera fault location provided by one or more embodiments of the present application. In one or more embodiments, this embodiment can be implemented by the operating system of the client and the vehicle. The operating system can exchange data with the client; the client is the device where the user who can use the application services provided by the operating system is located. Figure 1 As shown, the operating system 101 can interact with clients (such as client 102a, client 102b, and client 102c, etc.) for data, and the client can preload the fault location information of the vehicle camera from the computer device. Specifically, taking client 102a as an example, client 102a can obtain a call for the camera, and based on the operation, predict the behavior operation that may be triggered by the user associated with client 102a, that is, the user behavior intention of the user can be predicted. Client 102a can determine the camera corresponding to the user operation based on the behavior operation that may be triggered by the user, and preload the fault location information of multiple cameras based on fault location. Similarly, other user terminals (such as client 102b or client 102c, etc.) can also preload the image fault location information of the vehicle camera based on the above process.
[0054] Through this process, the user terminal can predict in advance the operation that the user may trigger next time, so as to preload the predicted fault location information, etc., so that when the user terminal triggers the predicted fault location information, it can directly obtain the display from the preloaded fault location information, so that the client only needs to spend less time when switching the displayed fault location information, thereby improving the efficiency of data loading.
[0055] in, Figure 1 The client in the example is only a part of the client, and the client in this application is not limited to this Figure 1 The client exemplified in .
[0056] In one embodiment, the present invention provides an embodiment of the present invention, and the following is a description of the embodiment of the present invention in conjunction with the accompanying drawings. Figure 2 The present invention provides a method for locating a fault of a vehicle camera, and the specific steps include:
[0057] S101 responds to the camera driving instruction to turn on the camera in the link;
[0058] S102 monitors the operating status of the camera in real time. When it is detected that the camera cannot output an image, the hardware failure of the camera is determined based on the collected information related to the camera hardware, and a fault information mark for describing the cause of the hardware failure is inserted into the external input simulation image and displayed on the screen;
[0059] S103 performs fault repair based on the fault information indicator displayed on the screen until the camera function returns to normal;
[0060] S104: when a fault occurs and causes an image collected by the camera to be displayed abnormally, evaluating the image quality abnormality based on the image quality related information of the camera;
[0061] S105 determines key information during the operation of the camera based on the evaluation results of the camera's hardware failure and image quality abnormality; after the camera fails, the fault is located based on the key information.
[0062] In the above embodiment, in step S101, before responding to the camera driving instruction, it also includes: by reporting the timestamp of each node in the link, the delay of each stage is counted to achieve the performance test of the link; when the performance test result meets the actual working condition requirements, a camera driving instruction to start the camera is sent; after receiving the camera driving instruction, the camera driving instruction is responded to; and the camera hardware related information is collected.
[0063] In the above embodiment, when it is monitored that the camera cannot output an image, the reasons include: the user opens a regular camera application on the Android side, and the screen can display the camera image normally, but due to a harness failure between the serializer and the deserializer, the camera device cannot output an image.
[0064] For the above faults, the following process is followed: poll the deserialization register to determine the link up status; when the link is up, trigger the hardware information collection. When the camera is detected to be unable to output images, the camera hardware fault is determined based on the collected camera hardware related information, and a fault information identifier describing the cause of the hardware fault is inserted into the external input analog image and displayed on the screen.
[0065] In the above embodiment, the camera hardware related information includes: camera power control status, camera deserializer status, camera serializer status, platform driver operation status. Summarize the power supply chip (voltage, current) status, camera deserializer status (lock, video link, err status, etc.), camera serializer status (chip Id, etc.).
[0066] In this embodiment, the key information of the camera operation process is obtained by integrating the collected camera-related hardware failures and image quality anomalies; when the camera fails, the above information can be used to directly locate the fault of the vehicle camera. Among them, by combining the above two categories to obtain hardware status and image quality information, it can be known whether the failure occurs in hardware or software problems, and a comprehensive analysis can be performed based on the above problems. Since there are many reasons for camera failure, the causes of the failure are usually divided into two categories: hardware failure and software failure according to the camera failure phenomenon.
[0067] (1) Hardware failure. If the calibration software reports that the sensor is not connected, continue to check the wiring harness for physical damage and circuit breakage. After eliminating the wiring harness failure, continue to check whether the camera component is faulty. If so, replace the camera.
[0068] (2) Software failure. Software failure usually occurs when the image quality is low: if the image is blurry, check and adjust the camera resolution parameters; if the image angle is tilted upward or downward, change the camera pitch angle parameters; check whether the image angle is tilted to the left or right, if so, change the camera heading angle parameters.
[0069] In addition, the camera needs to be cleaned during daily use to prevent stains on the image displayed by the camera, which will affect fault judgment.
[0070] In one embodiment, when monitoring hardware failures, the step of determining the fault location in the link based on the link length, reflection coefficient and analysis results includes: determining the short circuit location or the open circuit location in the link based on the link length, reflection coefficient and analysis results, and using the short circuit location or the open circuit location as the fault location.
[0071] Optionally, when detecting camera failure, use Ctrl+Alt+t to open the computer command window of the autonomous driving processor, and determine whether the camera network is abnormal by checking whether the camera IP address has normal data output. Enter the command ping192.168.1.xx and observe whether there is continuous data output. If not, continue to check whether the camera software has a fault.
[0072] After the software fault is eliminated, you can open the dream view human-computer interaction interface, open the camera in the module controller interface, and then open the camera sensor to observe the camera information normally. At this time, the fault troubleshooting is complete and the camera can work normally.
[0073] By simulating specific application scenarios in the above embodiments, the specific embodiments can be further described:
[0074] In the above embodiment, the image quality evaluation in step S104 can assist in locating the image quality problem; specifically, the processing flow of using the auxiliary positioning image quality problem is as follows:
[0075] When users use the Camera stress testing software for testing, some frames of image data appear black, and the cause of the fault needs to be confirmed.
[0076] In view of the above fault, the following process is performed in this embodiment:
[0077] 1. The user turns on the black image anomaly detection function.
[0078] 2. The image quality statistics module calculates the brightness information of each frame, passes the result to the abnormal data analysis module, and prints the relevant logo.
[0079] 3. Display the brightness information in the image through a watermark, and transmit the modified image to the app through the Camera link for display.
[0080] 4. Cache the latest 8 frames of image data. When an abnormal change in brightness data is detected, such as a frame with normal brightness, the Image Dump process is triggered to store the abnormal image, the normal images of the previous and next frames, and the fault logo to the disk.
[0081] 5. The user can observe the image brightness in real time during the test. At the same time, after the test, the black image abnormal data frame can be obtained from the disk to further analyze the cause of the fault.
[0082] In the above embodiment, obtaining the abnormal display of the image collected by the camera due to the fault in step S104 includes:
[0083] According to the pre-selected automated test items, perform automated tests on image quality, and automatically report the test results obtained by the automated tests; wherein the automated test items include a black image anomaly detection function;
[0084] The black image anomaly detection function is used to identify the black image phenomenon in the image, and store the black image anomaly image frames with the black image phenomenon in the disk.
[0085] In the above embodiment, Figure 3 As shown, the black image phenomenon in the recognition image includes:
[0086] Calculate all pixels of the displayed image and obtain any pixel in the displayed image as a pixel to be tested;
[0087] Calculate the gray value of the pixel to be tested, and based on the judgment principle that the higher the black pixel rate of the gray value, the darker the image, define the pixel with a gray value less than the first preset threshold as a black pixel, and judge whether there is a black screen phenomenon according to the black pixel rate of the image. If the black image detection function is turned on, if a black image is detected, it will automatically report the abnormality and record the current status, such as capturing images, capturing key LOGs, and key information.
[0088] In the above embodiment, the pixel points whose grayscale values are less than the first preset threshold are defined as black pixels, and judging whether there is a black screen phenomenon according to the black pixel rate of the image includes:
[0089] Determine the size between the grayscale value of the pixel and a first preset threshold; if the grayscale value of the pixel is less than the first preset threshold, count it as a black pixel; otherwise, obtain the next pixel in the displayed image as the pixel to be tested, calculate the grayscale value of the pixel to be tested, determine the size between the grayscale value of the pixel and the preset threshold, and accumulate the number of black pixels according to the determination result;
[0090] Determine the black pixel rate according to the proportion of the accumulated number of black pixels in all pixels;
[0091] Comparing the black pixel ratio with a preset black pixel determination threshold, and if the black pixel ratio exceeds the preset black pixel determination threshold, determining that the currently displayed image is an abnormal image;
[0092] The number of times that the black pixel rate in the abnormal image is greater than the black image judgment threshold is defined as the number of black images; when the number of black images exceeds the second preset threshold, the image has a black image phenomenon.
[0093] In the above embodiment, the step S104 of evaluating the image quality abnormality based on the image quality related information of the camera includes:
[0094] Collecting information related to the image quality of the camera; wherein the information related to the image quality of the camera includes: brightness, clarity, noise and distortion parameters of the image frame;
[0095] Read the black image abnormality frame from the disk, use any one of the brightness, clarity, noise and distortion parameters as an evaluation parameter for analyzing the image quality abnormality, and further analyze the cause of the abnormality;
[0096] Read the black image abnormality frames in the disk and calculate the evaluation parameters of each image frame;
[0097] When an abnormal jump in the evaluation parameter value of an image frame is identified, an influence range of the abnormal image frame where the evaluation parameter value jump occurs is defined, adjacent normal image frames are cached within the defined influence range of the abnormal image frame, and an abnormal flag associated with the evaluation parameter is added to the abnormal image frame where the evaluation parameter value jump occurs, to obtain an image frame carrying the abnormal flag;
[0098] Trigger the image transfer and storage process, and store the image frame carrying the abnormal identification and the adjacent image frames of the abnormal image frame as image display abnormality information to the disk;
[0099] The image display abnormality information in the disk is added to the image as a watermark, and the image with the watermark is uploaded to the application through a link for display.
[0100] In this embodiment, under normal circumstances, the reasons for abnormal image quality can be divided into two categories: internal factors and external factors. Among them, internal factors refer to the quality problems of the imaging element or display device itself and the quality problems of the transmission line; external factors refer to electromagnetic interference; if there is relatively strong electromagnetic interference near the imaging element, near the display screen, or around the transmission line, then the final displayed image will have noise, abnormal brightness, etc. Common quality abnormalities include: color deviation, abnormal brightness, jitter, signal loss, stripe interference, noise, occlusion, etc.
[0101] In this embodiment, assuming that all accidents can be perceived by the camera, the main problem to be solved is the black image, abnormal brightness, and abnormal blur caused by external factors.
[0102] When a black image occurs, the screen color is single, based on which the black image can be detected from the image pixel distribution characteristics.
[0103] A grayscale image is just a single-channel image, where each pixel value represents the grayscale level at the corresponding position. Therefore, converting a color image to a grayscale image requires converting each color pixel. The grayscale value of each pixel in the above image can be calculated.
[0104] In the above embodiment, the calculation of the brightness information of the image requires converting the image from the RGB color space to the HSV color space, where H represents the image color channel, S represents the saturation of the image color, and V represents the brightness of the image. The conversion steps are as follows:
[0105] (1) Normalize the R, G, and B channels of the image respectively;
[0106] (2) Find the maximum and minimum values in the three channels of R, G, and B and calculate their difference; based on the difference between the maximum and minimum values of different color channels, obtain the channel conversion of image color, saturation, and brightness.
[0107] In the above embodiment, step S105 determines key information during the operation of the camera. When the camera fails, locating the fault based on the key information includes:
[0108] The hardware failure of the camera and the abnormal evaluation results of the image quality are defined as the key information in the operation process of the camera;
[0109] Combined with key information during camera operation, determine the camera fault location and its impact range, including the cause of the fault, the fault point, and the affected area associated with the fault point.
[0110] In one embodiment, after the step of locating the link fault according to the key information, the step further includes:
[0111] After analyzing the fault type and fault location of the fault in the link, the fault location and the fault status corresponding to the fault type are uploaded to the link database of the cloud server through the SOC to update the link database.
[0112] Based on the same inventive concept, the embodiment of the present application also provides a vehicle camera fault location method and a vehicle camera fault location system. The implementation scheme for solving the problem provided by the system is similar to the implementation scheme recorded in the above method, so the specific limitations in the embodiments of one or more vehicle camera fault location systems provided below can refer to the limitations of the vehicle camera fault location method above, and will not be repeated here.
[0113] In one embodiment, Figure 4 As shown, a vehicle camera fault location system is provided, which is arranged in a host of a vehicle machine end, connected to at least one camera and a display screen for collecting images, and includes:
[0114] A response module 210, configured to respond to a camera driving instruction to start a camera in the link;
[0115] The hardware fault detection module 220 monitors the operating status of the camera in real time. When it is detected that the camera cannot output an image, the hardware fault of the camera is determined based on the collected information related to the camera hardware, and a fault information mark for describing the cause of the hardware fault is inserted into the external input simulation image and displayed on the screen;
[0116] The repair module 230 is used to perform fault repair based on the fault information identification displayed on the screen until the camera function returns to normal;
[0117] An image quality assessment module 240 is used to assess the image quality abnormality based on the image quality related information of the camera when a fault occurs and causes the image collected by the camera to display abnormally;
[0118] The abnormal data analysis module 250 is used to determine key information during the operation of the camera based on the evaluation results of the camera's hardware failure and image quality abnormality; after the camera fails, the fault is located based on the key information.
[0119] In addition, optionally, the host further includes: an MCU, used to power the camera;
[0120] AIS architecture provides the client with an API interface for operating the camera, calling ais_service; ais_service runs as a daemon process in the NATIVE layer. The service uses the encapsulated platform-related libraries, and finally uses IOCTL and kernelnative to interact, uses the terminal to generate time, and is driven by the V4L2 video framework. At the same time, ais_service interacts with ais_client through socket, and the encapsulated socket implements sending instructions to the other end and retrieving the data returned by the other end, which actually implements IPC. ais_service is Qualcomm's Camera HAL implementation for vehicle-mounted systems, running as a background service program in the native layer; ais_service is the core of the Camera HAL layer.
[0121] In the above embodiment, the API interface transparently transmits the image data of the camera to the QNX upper layer through the AIS architecture;
[0122] The application layer interacts with the underlying layer through the AIS function interface and the Android Carmera2 interface; rewrites the logic of the upper and lower layers, and handles exceptions when calling the interface return value.
[0123] At the same time, the present application also proposes a computer-readable storage medium and an electronic device. In one embodiment, the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of any one of the methods in step S101 to step S105 are implemented.
[0124] In one embodiment, an electronic device is provided. The electronic device may be a terminal, and its internal structure diagram may be as follows: Figure 5As shown. The electronic device includes a processor, a memory, a communication interface, a display screen and an input device connected via a system bus. Among them, the processor of the electronic device is used to provide computing and control capabilities. The memory of the electronic device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the electronic device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be implemented through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, the method described in any one of S101 to S105 is implemented. The display screen of the electronic device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the electronic device can be a touch layer covered on the display screen, or a button, a trackball or a touch pad set on the housing of the electronic device, or an external keyboard, touch pad or mouse, etc.
[0125] Those skilled in the art will understand that Figure 5 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0126] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties.
[0127] A person of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory may include read-only memory ROM, magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive memory ReRAM, magnetic memory MRAM, ferroelectric memory FRAM, phase change memory PCM, graphene memory, etc. Volatile memory may include random access memory RAM or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory SRAM or dynamic random access memory DRAM, etc. The database involved in the embodiments provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited thereto. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic unit, a data processing logic unit based on quantum computing, etc., but is not limited thereto.
[0128] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0129] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A method for locating a vehicle camera fault, characterized in that: The method comprises: Respond to the camera driver command to start the camera in the link; Monitor the operating status of the camera in real time. When it is detected that the camera cannot output images, determine the hardware failure of the camera based on the collected information related to the camera hardware, and insert a fault information mark describing the cause of the hardware failure into the external input simulation image and display it on the screen; Perform fault repair based on the fault information displayed on the screen until the camera function returns to normal; When a fault occurs and causes the image collected by the camera to display abnormally, the image quality abnormality is evaluated based on the image quality related information of the camera; Combined with the evaluation results of the camera's hardware failure and image quality abnormality, key information during the camera's operation is determined; after the camera fails, the fault is located based on the key information.
2. The method according to claim 1, characterized in that The camera hardware related information includes: camera power control status, camera deserializer status, camera serializer status, and platform driver operation status.
3. The method according to claim 1, characterized in that Obtaining the abnormal display of the image collected by the camera due to the fault includes: According to the pre-selected automated test items, perform automated tests on image quality, and automatically report the test results obtained by the automated tests; wherein the automated test items include a black image anomaly detection function; The black image anomaly detection function is used to identify the black image phenomenon in the image, and store the black image anomaly image frames with the black image phenomenon in the disk.
4. The method according to claim 3, characterized in that: The black image phenomenon in the recognition image includes: Calculate all pixels of the displayed image and obtain any pixel in the displayed image as a pixel to be tested; Calculate the grayscale value of the pixel to be tested. Based on the judgment principle that the higher the black pixel rate of the grayscale value, the darker the image, define the pixel whose grayscale value is less than the first preset threshold as a black pixel, and judge whether there is a black screen phenomenon according to the black pixel rate of the image.
5. The method according to claim 4, characterized in that The step of defining a pixel point whose grayscale value is less than a first preset threshold as a black pixel point, and judging whether there is a black screen phenomenon according to the black pixel rate of the image includes: Determine the size between the grayscale value of the pixel and a first preset threshold; if the grayscale value of the pixel is less than the first preset threshold, count it as a black pixel; otherwise, obtain the next pixel in the displayed image as the pixel to be tested, calculate the grayscale value of the pixel to be tested, determine the size between the grayscale value of the pixel and the preset threshold, and accumulate the number of black pixels according to the determination result; Determine the black pixel rate according to the proportion of the accumulated number of black pixels in all pixels; Comparing the black pixel ratio with a preset black pixel determination threshold, and if the black pixel ratio exceeds the preset black pixel determination threshold, determining that the currently displayed image is an abnormal image; The number of times that the black pixel rate in the abnormal image is greater than the black image judgment threshold is defined as the number of black images; when the number of black images exceeds the second preset threshold, the image has a black image phenomenon.
6. The method according to claim 1, characterized in that The image quality abnormality assessment based on the image quality related information of the camera includes: Collecting information related to the image quality of the camera; wherein the information related to the image quality of the camera includes: brightness, clarity, noise and distortion parameters of the image frame; Read the black image abnormality frame from the disk, use any one of the brightness, clarity, noise and distortion parameters as an evaluation parameter for analyzing the image quality abnormality, and further analyze the cause of the abnormality; Read the black image abnormality image frames in the disk and calculate the evaluation parameters of each image frame; When an abnormal jump in the evaluation parameter value of an image frame is identified, an influence range of the abnormal image frame where the evaluation parameter value jump occurs is defined, adjacent normal image frames are cached within the defined influence range of the abnormal image frame, and an abnormal flag associated with the evaluation parameter is added to the abnormal image frame where the evaluation parameter value jump occurs, to obtain an image frame carrying the abnormal flag; Trigger the image transfer and storage process, and store the image frame carrying the abnormal identification and the adjacent image frames of the abnormal image frame as image display abnormality information to the disk; The image display abnormality information in the disk is added to the image as a watermark, and the image with the watermark is uploaded to the application through a link for display.
7. The method according to claim 1, characterized in that Determining key information during camera operation and locating the fault based on the key information when the camera fails includes: The hardware failure of the camera and the abnormal evaluation results of the image quality are defined as the key information in the operation process of the camera; Combined with key information during camera operation, determine the camera fault location and its impact range, including the cause of the fault, the fault point, and the affected area associated with the fault point.
8. A vehicle camera fault location system, characterized in that: The system is arranged in a vehicle host, connected to at least one camera and a display screen, and includes: A response module, used to respond to a camera driver instruction to start the camera in the link; The hardware fault detection module monitors the operating status of the camera in real time. When it is detected that the camera cannot output images, the hardware fault of the camera is determined based on the collected information related to the camera hardware, and a fault information mark describing the cause of the hardware fault is inserted into the external input simulation image and displayed on the screen; A repair module is used to repair the fault based on the fault information displayed on the screen until the camera function returns to normal; An image quality assessment module, used to assess the image quality abnormality based on the image quality related information of the camera when a fault occurs and causes the image collected by the camera to display abnormally; The abnormal data analysis module is used to determine the key information during the operation of the camera by combining the evaluation results of the camera's hardware failure and image quality abnormality; after the camera fails, the fault is located based on the key information.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
10. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and when the computer program is executed by the processor, the processor executes the steps of the method according to any one of claims 1 to 7.