Automatic testing method for page image difference recognition of vehicle-mounted information entertainment system
By adopting automated testing methods in the vehicle information entertainment system, using the SSIM value to determine the start and end of the image frame, the traditional manual testing is consuming and easy to miss the error, and an efficient and accurate interface test is achieved.
Patent Information
- Application Number
- CN202411445478.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-16
- Publication Date
- 2025-01-28
AI Technical Summary
The traditional manual testing method is difficult to meet the needs of efficient and comprehensive inspection of in-vehicle infotainment systems, and there are problems such as long test time and easy to miss and errors.
Adopt an automated test method for identification of image difference recognition of the car information entertainment system. By extract the image frame in the video by frame, calculate the SSIM value between the two adjacent image frames, and set the SSIM changes to the SSIM according to the application scenario to determine the judgment The beginning and end of the image frame to achieve automated testing.
The automatic monitoring and testing of the UI interface of the vehicle machine is achieved, ensuring the accuracy of page switching logic, reducing artificial intervention, increasing test speed and coverage, and reducing labor costs.
Smart Images

Figure CN119377110A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of image recognition of an in-vehicle infotainment system, and in particular to an automated testing method for identifying page image differences of an in-vehicle infotainment system. Background Art
[0002] With the development of automobile intelligence, the complexity of the car system is increasing, especially the interaction and switching logic between pages has become more diverse. The traditional manual testing method is difficult to meet the needs of efficient and comprehensive testing, and there are problems such as long testing time and easy to miss errors. Therefore, it is particularly important to develop a system that can automatically identify changes in the car interface, simulate user operations, and verify the correctness of page switching. Summary of the invention
[0003] The purpose of the present invention is to provide an automated testing method for identifying differences in page images of an in-vehicle infotainment system, so as to solve the problems raised in the above-mentioned background technology.
[0004] To achieve the above object, the present invention provides the following technical solution: an automated testing method for identifying differences in page images of an in-vehicle infotainment system, comprising:
[0005] Extract image frames from the video frame by frame;
[0006] Calculate the SSIM value between two adjacent image frames;
[0007] Set the SSIM change threshold according to the application scenario;
[0008] Determine whether the SSIM value change between two adjacent image frames is less than a change threshold;
[0009] If the SSIM value change is less than the change threshold, it is determined that the latter image frame of two adjacent image frames is the end frame, and the former image frame is the start frame.
[0010] Furthermore, extracting image frames in the video frame by frame also includes:
[0011] Use the video processing library to load the video file.
[0012] Further, an image of an ideal display effect expected by the system is obtained as a reference image;
[0013] Capture images of what is actually displayed on the in-vehicle infotainment system screen via an automated script.
[0014] Furthermore, all images are made to have the same size through image preprocessing;
[0015] Convert the images to the same color space;
[0016] Remove noise from images.
[0017] Furthermore, calculating the SSIM value between two adjacent image frames also includes:
[0018] Define a list or array to store the SSIM values of two adjacent image frames;
[0019] Calculate the SSIM value between two adjacent image frames;
[0020] Store the obtained SSIM values in a list or array.
[0021] Furthermore, the similarity between two image frames is measured by calculating the brightness, contrast and structural similarity between image blocks, and the weights of brightness, contrast and structure are set according to the corresponding application scenarios to calculate the SSIM value.
[0022] Further, if the SSIM value change is less than the change threshold, it is determined that the latter image frame of two adjacent image frames is the end frame, and the previous image frame is the start frame, and further includes:
[0023] Traverse the SSIM value list and find SSIM values that are less than the change threshold. The image frames corresponding to these positions are the end frames, and the image frame before the end frame is the corresponding start frame.
[0024] Furthermore, by using color coding or highlighting the difference area between the start frame and the end frame, quick positioning is facilitated.
[0025] Further, each test result is recorded, wherein the test result includes a score and a difference graph of the SSIM value;
[0026] Track the score changes of the SSIM value to monitor the stability of the system.
[0027] Furthermore, image difference recognition testing is integrated into the software development process so that testing can be automatically performed after each code change;
[0028] Set up scheduled tasks and execute automated tests regularly to monitor the consistency of the interface.
[0029] Compared with the prior art, the beneficial effects of the present invention are: the present invention realizes automatic monitoring and testing of the vehicle UI interface to ensure the accuracy of the page switching logic; automated testing reduces manual intervention and improves test speed and coverage; image recognition technology ensures that each page switch can be accurately identified to reduce misjudgment; in the long run, automated testing can ensure quality and significantly reduce labor costs; the system design is flexible and easy to adapt to different vehicle systems, supporting the testing needs of future new functions. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] Figure 1 The present invention is a flowchart of an automated testing method for identifying page image differences in an in-vehicle infotainment system according to an embodiment of the present invention. DETAILED DESCRIPTION
[0031] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0032] In the description of the present invention, unless otherwise specified, "plurality" means two or more than two; the orientations or positional relationships indicated by the terms "upper", "lower", "left", "right", "inner", "outer", "front end", "rear end", "head", "tail", etc. are based on the orientations or positional relationships shown in the drawings, and are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operate in a specific orientation, and therefore cannot be understood as limiting the present invention. In addition, the terms "first", "second", "third", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance.
[0033] In the description of the present invention, it should be noted that, unless otherwise clearly specified and limited, the terms "connected" and "connection" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0034] Please refer to the attached drawings of the specification. The present invention provides a technical solution: an automated testing method for identifying page image differences in an in-vehicle infotainment system, comprising the following steps:
[0035] S102, extracting image frames in the video frame by frame;
[0036] Specifically, extracting image frames in the video frame by frame also includes:
[0037] Use the video processing library to load the video file.
[0038] Among them, the preferred automated testing framework uses tools such as Selenium to implement the writing and execution of test cases. The automated test first uses a video processing library (such as OpenCV or Pillow) to load the video file, and then extracts image frames in the video frame by frame.
[0039] Specifically, an image of an ideal display effect expected by the system is obtained as a reference image;
[0040] Capture images of what is actually displayed on the in-vehicle infotainment system screen via an automated script.
[0041] Among them, this embodiment is image acquisition, which obtains a baseline image of the ideal display effect expected by the system as a reference, and captures the image actually displayed on the vehicle screen through an automated script for testing.
[0042] Specifically, all images are made to have the same size through image preprocessing;
[0043] Convert the images to the same color space;
[0044] Remove noise from images.
[0045] Among them, the images are resized to ensure that all images are of the same size for comparison, the images are converted to the same color space, such as from RGB to YCbCr; and noise filtering is performed to remove noise from the images to improve the accuracy of the comparison.
[0046] S104, calculating the SSIM value between two adjacent image frames;
[0047] Specifically, a list or array is defined to store the SSIM values of two adjacent image frames;
[0048] Calculate the SSIM value between two adjacent image frames;
[0049] Store the obtained SSIM values in a list or array.
[0050] First, the initialization variables are defined, a list or array is defined to store the SSIM values of each pair of adjacent frames, and then the image frames are looped through. For each frame, the SSIM value between it and the next frame is calculated, and finally the obtained SSIM value is stored in the list or array.
[0051] Specifically, the similarity between two image frames is measured by calculating the brightness, contrast and structural similarity between image blocks, and the weights of brightness, contrast and structure are set according to the corresponding application scenarios to calculate the SSIM value.
[0052] Among them, this embodiment includes two aspects: local structural similarity calculation and parameter adjustment; local structural similarity calculation: the SSIM algorithm measures the similarity between two images by calculating the brightness, contrast and structural similarity between image blocks; parameter adjustment: adjust the weight parameters in the SSIM algorithm (such as brightness, contrast and structure weights) according to the specific application scenario to optimize the results.
[0053] S106, setting a change threshold of SSIM according to an application scenario;
[0054] Among them, a suitable SSIM threshold is selected according to the application scenario, and the threshold is used to determine whether a significant change occurs between two frames; a threshold is defined to determine when the difference between two images is considered acceptable.
[0055] S108, determining whether a change in the SSIM value between two adjacent image frames is less than a change threshold;
[0056] S110 , if the SSIM value change is less than the change threshold, it is determined that the latter image frame of two adjacent image frames is the end frame, and the former image frame is the start frame.
[0057] Among them, the SSIM value list is traversed to find SSIM values below the set threshold. The frames corresponding to these positions can be considered as potential "end frames" to determine the frame pairs. Once the end frame is found, the previous frame is the corresponding "start frame".
[0058] Specifically, if the SSIM value change is less than the change threshold, it is determined that the latter image frame of two adjacent image frames is the end frame, and the previous image frame is the start frame, and further includes:
[0059] Traverse the SSIM value list and find SSIM values that are less than the change threshold. The image frames corresponding to these positions are the end frames, and the image frame before the end frame is the corresponding start frame.
[0060] Specifically, by using color coding or highlighting the difference area between the start frame and the end frame, quick positioning is facilitated.
[0061] Among them, this step is to visualize the differences, using color coding or highlighting the difference areas to facilitate quick location of problems.
[0062] Specifically, each test result is recorded, wherein the test result includes a score and a difference map of the SSIM value;
[0063] Track the score changes of the SSIM value to monitor the stability of the system.
[0064] Among them, the results are recorded, the results of each test are recorded, including SSIM scores, difference graphs, etc., and an automated report is generated to track changes in SSIM scores over time to monitor the stability of the system for trend analysis.
[0065] Specifically, image difference recognition testing is integrated into the software development process so that testing can be automatically performed after each code change;
[0066] Set up scheduled tasks and execute automated tests regularly to monitor the consistency of the interface.
[0067] Among them, this step is integration and scheduling;
[0068] Continuous Integration / Continuous Deployment (CI / CD) Process: Integrate image difference recognition testing into the software development process to ensure that testing is automatically executed after each code change.
[0069] Regular execution: Set up scheduled tasks and regularly execute automated tests to monitor the consistency of the interface.
[0070] The automated test method for identifying differences in page images of an in-vehicle infotainment system based on the structural similarity index (SSIM) algorithm of the present invention mainly focuses on how to automatically detect and evaluate the visual differences between two images. This method is particularly suitable for interface testing of in-vehicle infotainment systems because it can help ensure that new versions of software updates or modifications will not have a negative impact on the user interface. The SSIM algorithm not only considers the brightness and contrast of the image, but also the structural information, which is lacking in many other image quality assessment methods; the algorithm has become an important tool for image similarity assessment due to its accuracy, robustness, efficiency and comprehensiveness. Using this algorithm in combination to test the differences in page images of in-vehicle infotainment systems will greatly reduce labor costs and improve accuracy.
[0071] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.
Claims
1. An automated testing method for identifying differences in page images of an in-vehicle infotainment system, characterized in that: include: Extract image frames from the video frame by frame; Calculate the SSIM value between two adjacent image frames; Set the SSIM change threshold according to the application scenario; Determine whether the SSIM value change between two adjacent image frames is less than a change threshold; If the SSIM value change is less than the change threshold, it is determined that the latter image frame of two adjacent image frames is the end frame, and the former image frame is the start frame.
2. The automated testing method for identifying differences in page images of an in-vehicle infotainment system according to claim 1, characterized in that: Extract image frames from the video frame by frame, also includes: Use the video processing library to load the video file.
3. The automated testing method for identifying differences in page images of an in-vehicle infotainment system according to claim 2, characterized in that: include: Acquire an image of the ideal display effect expected by the system as a reference image; Capture images of what is actually displayed on the in-vehicle infotainment system screen via an automated script.
4. The automated testing method for identifying differences in page images of an in-vehicle infotainment system according to claim 1, characterized in that: include: Make all images of the same size through image preprocessing; Convert the images to the same color space; Remove noise from images.
5. The automated testing method for identifying differences in page images of an in-vehicle infotainment system according to claim 1, characterized in that: Calculating the SSIM value between two adjacent image frames also includes: Define a list or array to store the SSIM values of two adjacent image frames; Calculate the SSIM value between two adjacent image frames; Store the obtained SSIM values in a list or array.
6. The automated testing method for identifying differences in page images of an in-vehicle infotainment system according to claim 5, characterized in that: include: The similarity between two image frames is measured by calculating the brightness, contrast and structural similarity between image blocks, and the weights of brightness, contrast and structure are set according to the corresponding application scenarios to calculate the SSIM value.
7. The automated testing method for identifying differences in page images of an in-vehicle infotainment system according to claim 1, characterized in that: If the SSIM value change is less than the change threshold, then the latter image frame of two adjacent image frames is determined to be the end frame, and the previous image frame is the start frame, and further comprising: Traverse the SSIM value list and find SSIM values that are less than the change threshold. The image frames corresponding to these positions are the end frames, and the image frame before the end frame is the corresponding start frame.
8. The automated testing method for identifying differences in page images of an in-vehicle infotainment system according to claim 7, characterized in that: include: Color-coding or highlighting of the difference between the start and end frames facilitates quick location.
9. The automated testing method for identifying differences in page images of an in-vehicle infotainment system according to claim 1, characterized in that: include: Record each test result, where the test result includes the SSIM value score and difference map; Track the score changes of the SSIM value to monitor the stability of the system.
10. The automated testing method for identifying differences in page images of an in-vehicle infotainment system according to claim 9, characterized in that: include: Integrate image difference recognition testing into the software development process so that testing can be automatically performed after each code change; Set up scheduled tasks and execute automated tests regularly to monitor the consistency of the interface.
Citation Information
Cited By
Coastal wetland carbon reserve dynamic monitoring method based on time sequence remote sensing
CN121708542A