A method and system for automatic testing of set-top box front end integrating artificial intelligence
By integrating artificial intelligence and automated testing technology, using deep learning models and protocol control devices, the problems of low efficiency and poor accuracy of traditional set-top box testing are solved, and efficient and accurate image quality evaluation is achieved.
Patent Information
- Application Number
- CN202210642258.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-08
- Publication Date
- 2024-11-01
- Estimated Expiration
- 2042-06-08
AI Technical Summary
Traditional set-top box front-end testing methods are inefficient and prone to misjudgment. Manually judging image quality depends on experience, resulting in low and inaccurate testing.
Using the automatic front-end test method of set-top box integrated with artificial intelligence, the deep learning model is used to classify and determine image quality, combined with the code stream signal generator, video collector and network relay, the test process is realized through automated test scripts and protocol control, and Baidu Cloud is used AI's EasyDL customized image recognition model performs image quality evaluation.
It improves the efficiency and accuracy of discriminating the output image quality of set-top box, reduces manual intervention, reduces test time, and improves the automation and consistency of the test system.
Smart Images

Figure CN115037924B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a set-top box front-end automatic testing method, and in particular to a set-top box front-end automatic testing method and system integrating artificial intelligence. Background Art
[0002] Traditional set-top box front-end testing uses manual testing methods to manually judge the quality of the set-top box output image. The specific testing steps are as follows:
[0003] 1. Manually set the code stream signal generator to generate code stream;
[0004] 2. The set-top box parses the code stream and outputs the image;
[0005] 3. Image quality is judged by human eyes;
[0006] Among them, manually setting the parameters of the code stream signal generating instrument is relatively cumbersome, time-consuming and inefficient.
[0007] In addition, it is boring for testers to stare at the TV for a long time, which can easily cause visual fatigue. Manual judgment of image quality relies entirely on experience, and the naked eye judgment standards of different testers may vary, which may lead to misjudgment.
[0008] Therefore, how to provide a testing system to improve the efficiency of determining the quality of the image output by the set-top box is a technical problem that needs to be solved urgently by those skilled in the art. Summary of the invention
[0009] In order to solve the problems in the prior art, the present invention provides a set-top box front-end automatic testing method and system integrating artificial intelligence.
[0010] The present invention provides a method for automatically testing a set-top box front end integrating artificial intelligence, comprising the following steps:
[0011] S1. Determine whether the test data exists. If so, proceed to the next step. If not, generate test JSON data.
[0012] S2. Read the test JSON data and convert it into dictionary data that can be directly used by the Python program;
[0013] S3, initialize the code stream signal generator and set the fixed parameters required for the test items;
[0014] S4, determine whether the test result is empty, if not, skip the current test point, that is, continue the test at the breakpoint, check the next test point, if yes, test the current test point;
[0015] S5. Set fixed parameters of the code stream signal generator according to the test points;
[0016] S6, the computer controls the video capture instrument to lock the set-top box and returns whether the locking is successful. If it fails, skip the current test point and check the next test point. If it succeeds, go to the next step;
[0017] S7, setting variable parameters related to the code stream signal generator and the lock station according to the test points;
[0018] S8, determining whether the video currently played by the set-top box is normal or has mosaics;
[0019] S9. Write the test results into JSON files and CSV files;
[0020] S10, loop through the test steps S4-S9 to complete the testing of all test points.
[0021] As a further improvement of the present invention, in step S6, the computer terminal calls the video capture device screenshot interface to implement video frame extraction and controls it to transmit infrared signals to set the set-top box to lock the station.
[0022] As a further improvement of the present invention, the computer terminal controls the code stream signal generator based on the VISA protocol to set instrument parameters.
[0023] As a further improvement of the present invention, the computer side sets a network relay through the TCP protocol, thereby controlling the on and off of the set-top box power supply to achieve self-recovery of the set-top box restart under abnormal circumstances.
[0024] As a further improvement of the present invention, in step S8, deep learning modeling is used to classify and judge the image quality.
[0025] As a further improvement of the present invention, the deep learning modeling includes: using Baidu Cloud AI to provide EasyDL customized image recognition model, collecting pictures with low image quality and high image quality in the code stream in the early stage, and forming a data set through manual labeling. The training of the model relies on the EasyDL platform. After platform training, the image classification model is obtained and its effect is verified, the quality of the data set is continuously adjusted, the model training algorithm is optimized, and the optimal model is obtained.
[0026] The present invention also provides an artificial intelligence-integrated set-top box front-end automatic testing system, comprising a readable storage medium, wherein the readable storage medium stores execution instructions, and the execution instructions are used to implement the described method when executed by a processor.
[0027] The present invention also provides an artificial intelligence-integrated set-top box front-end automatic testing system, comprising a computer terminal, a code stream signal generator, a video acquisition instrument and a network relay. The computer terminal, the code stream signal generator, the video acquisition instrument and the network relay communicate based on the TCP or HTTP protocol to form a communication system. The set-top box, as a tested object, does not directly enter the communication system, but uses a video acquisition instrument to obtain the set-top box video in real time to access the system, thereby evaluating the playback quality and performing the test. The system is used to implement the method described.
[0028] As a further improvement of the present invention, the computer end is used to run an automated test script; the computer end is used to set SFU / SFE parameters for a bit stream signal generator, and the bit stream signal generator is used to play bit streams to a set-top box; the computer end is used to control the switch of a network relay, and the network relay is used to control the power on and off of the set-top box; the bit stream signal generator is used to obtain real-time video of the set-top box, and to set parameters of the set-top box through infrared, and to determine whether the set-top box is playing a program and feed it back to the computer end, and the computer end is used to trigger video frame extraction of the bit stream signal generator.
[0029] As a further improvement of the present invention, the computer terminal includes a test data reading module, an instrument control module, a sensitivity threshold finding module and a test report exporting module; wherein,
[0030] The function of the test data reading module is to read the generated JSON data file into the program memory for use when setting parameters of the bit stream signal generator and the set-top box;
[0031] The instrument control module is used to set the parameters of the code stream signal generator. Through the VISA protocol, the functions and parameters of the code stream signal generator are set, which completely simulates the setting process of a person.
[0032] The function of the sensitivity threshold finding module is to find the limit value of a variable parameter under the condition of certain fixed parameters when the set-top box can play the video normally, and its input is the variable parameter starting value, and its output is the variable parameter threshold value;
[0033] The test report export module is used to convert the test data into a table format and add row and column labels to facilitate the reading of the test results.
[0034] The beneficial effect of the present invention is that: through the above scheme, the efficiency of judging the quality of the image output by the set-top box is improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other solutions can be obtained based on these drawings without paying creative work.
[0036] Figure 1 The invention discloses a principle block diagram of an automatic test system for a set-top box front end integrating artificial intelligence.
[0037] Figure 2 The present invention discloses a network connection diagram of a set-top box front-end automatic test system integrating artificial intelligence.
[0038] Figure 3 The present invention is a flow chart of an automatic test method for a set-top box front end integrating artificial intelligence.
[0039] Figure 4 The present invention is a module decomposition diagram of a set-top box front-end automatic testing system integrating artificial intelligence. DETAILED DESCRIPTION
[0040] It should be noted that, in the absence of conflict, the embodiments of the present invention and the features in the embodiments may be combined with each other.
[0041] In the description of the present invention, it should be understood that the terms "center", "longitudinal", "lateral", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside" and the like indicate positions or positional relationships based on the positions or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as limiting the scope of protection of the present invention. In addition, the terms "first", "second", etc. are only used for descriptive purposes, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, features defined as "first", "second", etc. may explicitly or implicitly include one or more of the features. In the description of the present invention, unless otherwise specified, "multiple" means two or more.
[0042] In the description of the present invention, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" 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 direct connection, or an indirect connection through an intermediate medium, or it can be the internal communication of two components. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood by specific circumstances.
[0043] The present invention will be further described below in conjunction with the accompanying drawings and specific implementation methods.
[0044] like Figures 1 to 4 As shown, an automatic test system for the front end of a set-top box integrating artificial intelligence includes a computer (PC) 101, a bit stream signal generator 102, a video acquisition instrument 103 and a network relay 104.
[0045] like Figure 1 As shown, the computer terminal 101 runs the automated test script, controls the bit stream signal generator 102 based on the VISA protocol to set the instrument parameters, the set-top box 105 searches for the bit stream to play the video, the computer terminal 101 calls the screenshot interface of the video acquisition instrument 103 to realize video frame extraction and controls its infrared emission to set the set-top box 105 to lock the station, and the computer terminal 101 sets the network relay 104 through the TCP protocol, and then controls the on and off of the power supply of the set-top box 105 to realize the restart and self-recovery of the set-top box 105 under abnormal conditions.
[0046] like Figure 2 As shown, the system integrates hardware such as a code stream signal generator 102, a video capturer 103, a network relay 104, a computer terminal 101, and a set-top box 105 to be tested. The code stream signal generator 102, the video capturer 103, the network relay 104, the computer terminal 101 and other internal devices communicate based on the TCP or HTTP protocol. The set-top box 105, as the object to be tested, does not directly enter the communication system, but uses the video capturer 103 to obtain the video of the set-top box 105 in real time to access the system, thereby evaluating the playback quality and conducting the test.
[0047] An automatic test method for set-top box front end integrating artificial intelligence, such as Figure 3 As shown, the process is as follows:
[0048] 1. When the automatic test starts, determine whether the test data exists. If the test data already exists, proceed to the next step. If not, generate new test JSON data.
[0049] 2. Read the test JSON data and convert it into dictionary data that can be directly used by the Python program.
[0050] 3. Initialize the bit stream signal generator and set the fixed parameters required for the test items.
[0051] 4. Determine whether the test result is empty. If not, skip this test point (breakpoint continuation test) and check the next test point. If yes, test this test point.
[0052] 5. Set the fixed parameters of the code stream signal generator according to the test points.
[0053] 6. The computer controls the video capture instrument to use infrared to lock the set-top box and returns whether the locking is successful.
[0054] 7. Set the variable parameters related to the code stream signal generator and the lock station according to the test points.
[0055] 8. Determine whether the video currently played by the set-top box is normal or has mosaics.
[0056] 9. Write the test results to JSON and CSV files.
[0057] 10. Repeat test steps 4-9 to complete the testing of all test points.
[0058] The present invention provides a solution that relies on AI to perform image quality judgment model to replace manual work, and uses deep learning technology to classify and judge image quality, specifically including:
[0059] Deep learning modeling uses the EasyDL customized image recognition model provided by Baidu Cloud AI. In the early stage, we collect low-quality and high-quality images in the code stream and form a data set through manual annotation. The model training relies on the EasyDL platform. After platform training, we obtain the image classification model and verify its effect, continuously adjust the data set quality, optimize the model training algorithm, and obtain the optimal model.
[0060] The specific implementation steps are as follows:
[0061] 1. Adjust the code stream generator to generate code streams with different parameters for the set-top box to play;
[0062] 2. Extract the real-time video of the set-top box as an image, manually annotate the image quality and form a data set;
[0063] 3. Upload the dataset to Baidu Cloud EasyDL platform and adjust the model parameters for training;
[0064] 4. Use the test set data that was not used in the training to verify the model effect;
[0065] 5. Continue to adjust steps 1-4, use different annotated images and model parameters, and train the optimal model
[0066] After continuous optimization, the model's accuracy in judging the image quality of a single image is 96%. In actual applications, multiple images within a period of time are extracted and thresholds are set for judgment. The overall accuracy is 99.89%, which meets the usage requirements. The method of using AI models to judge the quality of the video currently played by the set-top box replaces manual judgment and improves the efficiency and accuracy of the test system.
[0067] In the front-end automated testing system, the design and implementation of modules are adopted, among which each module is as follows Figure 4 As shown, it includes four modules: test data reading module, instrument control module, sensitivity threshold finding module, and test report export module.
[0068] The function of the test data reading module is to read the generated JSON data file into the program memory for use when setting parameters of the instrument and set-top box.
[0069] The function of the instrument control module is to set the parameters of the code stream signal generator. The functions and parameters of the instrument are set through the VISA protocol, completely simulating the human setting process.
[0070] The function of the sensitivity threshold module is to find the limit value of a variable parameter under certain fixed parameters when the set-top box can play the video normally. Its input is the variable parameter starting value, and its output is the variable parameter threshold. Specifically, it collects the video stream played by the set-top box for frame extraction analysis, determines whether the bitstream playback is normal, and continuously loops a certain parameter to find the threshold value for normal bitstream playback, thereby reflecting the playback performance of the set-top box under different signal strengths and other conditions.
[0071] Image classification is a relatively important part. Traditional image classification algorithms extract the characteristics of the image itself and establish feature engineering for classification. However, in complex environments (different degrees of mosaic quality, changing image content, etc.), the performance is not very ideal. Finally, the AI deep learning method is used to establish a set-top box mosaic classification model. The AI model is trained with the help of Baidu EasyDL development platform. Various mild, moderate, severe, and non-mosaic images are collected and added to the neural network for training, and the parameters are continuously tuned to obtain a high-precision model.
[0072] The set-top box video frame extraction uses a video capture device, calls its screenshot interface, captures multiple pictures at one time, and cooperates with the AI mosaic classification model to determine whether mosaics appear in the video within a period of time, and then evaluates the performance of the set-top box under the current parameter mode.
[0073] The set-top box video frame extraction uses a video capture device, calls its screenshot interface, captures multiple pictures at one time, and cooperates with the AI mosaic classification model to determine whether mosaics appear in the video within a period of time, and then evaluates the performance of the set-top box under the current parameter mode.
[0074] The above contents are further detailed descriptions of the present invention in combination with specific preferred embodiments, and it cannot be determined that the specific implementation of the present invention is limited to these descriptions. For ordinary technicians in the technical field to which the present invention belongs, several simple deductions or substitutions can be made without departing from the concept of the present invention, which should be regarded as falling within the protection scope of the present invention.
Claims
1. A set-top box front-end automatic testing method integrating artificial intelligence, characterized in that: The following steps are involved: S1. Determine whether the test data exists. If so, proceed to the next step. If not, generate test JSON data. S2. Read the test JSON data and convert it into dictionary data that can be directly used by the Python program; S3, initialize the code stream signal generator and set the fixed parameters required for the test items; S4, determine whether the test result is empty, if not, skip the current test point, that is, continue the test at the breakpoint, check the next test point, if yes, test the current test point; S5. Set fixed parameters of the code stream signal generator according to the test points; S6, the computer controls the video capture instrument to lock the set-top box and returns whether the locking is successful. If it fails, skip the current test point and check the next test point. If it succeeds, go to the next step; S7, setting variable parameters related to the code stream signal generator and the lock station according to the test points; S8, determining whether the video currently played by the set-top box is normal or has mosaics; S9. Write the test results into JSON files and CSV files; S10, loop through the test steps S4-S9 to complete the test work of all test points; In step S8, the image quality is classified and judged using deep learning modeling; The deep learning modeling includes: using the EasyDL customized image recognition model provided by Baidu Cloud AI, collecting pictures with low image quality and high image quality in the code stream in the early stage, forming a data set through manual labeling, and the training of the model relies on the EasyDL platform. After platform training, the image classification model is obtained and its effect is verified, the quality of the data set is continuously adjusted, the model training algorithm is optimized, and the optimal model is obtained.
2. The method for automatically testing a set-top box front end integrating artificial intelligence according to claim 1 is characterized in that: In step S6, the computer terminal calls the video capture device screenshot interface to extract video frames and controls it to transmit infrared signals to set the set-top box to lock the station.
3. The method for automatically testing a set-top box front end integrating artificial intelligence according to claim 1 is characterized in that: The computer controls the code stream signal generator based on the VISA protocol to set the instrument parameters.
4. The method for automatically testing a set-top box front end integrating artificial intelligence according to claim 1 is characterized in that: The computer sets a network relay through the TCP protocol, and then controls the on and off of the set-top box power supply to achieve self-recovery of the set-top box under abnormal conditions.
5. An automatic test system for set-top box front end integrating artificial intelligence, characterized in that: The method comprises a readable storage medium in which execution instructions are stored. When the execution instructions are executed by a processor, the execution instructions are used to implement the method according to any one of claims 1 to 4.
6. An automatic test system for set-top box front end integrating artificial intelligence, characterized in that: The method comprises a computer terminal, a bit stream signal generator, a video acquisition instrument and a network relay. The computer terminal, the bit stream signal generator, the video acquisition instrument and the network relay communicate based on the TCP or HTTP protocol to form a communication system. The set-top box as the object under test does not directly enter the communication system, but uses the video acquisition instrument to obtain the set-top box video in real time to access the communication system, thereby evaluating the playback quality and conducting the test. The system is used to implement the method as described in any one of claims 1 to 4.
7. The set-top box front-end automatic test system integrating artificial intelligence according to claim 6 is characterized in that: The computer terminal is used to run the automated test script; the computer terminal is used to set SFU / SFE parameters for the bit stream signal generator, and the bit stream signal generator is used to play the bit stream to the set-top box; The computer end is used to control the switch of the network relay, and the network relay is used to control the power on and off of the set-top box; the code stream signal generator is used to obtain real-time video of the set-top box, and to set the parameters of the set-top box through infrared, and to determine whether the set-top box is playing a program and feed it back to the computer end, and the computer end is used to trigger the video frame extraction of the code stream signal generator.
8. The set-top box front-end automatic test system integrating artificial intelligence according to claim 6 is characterized in that: The computer terminal includes a test data reading module, an instrument control module, a sensitivity threshold finding module and a test report exporting module; wherein, The function of the test data reading module is to read the generated JSON data file into the program memory for use when setting parameters of the bit stream signal generator and the set-top box; The instrument control module is used to set the parameters of the code stream signal generator. Through the VISA protocol, the functions and parameters of the code stream signal generator are set, which completely simulates the setting process of a person. The function of the sensitivity threshold finding module is to find the limit value of a variable parameter under the condition of certain fixed parameters when the set-top box can play the video normally, and its input is the variable parameter starting value, and its output is the variable parameter threshold value; The test report export module is used to convert the test data into a table format and add row and column labels to facilitate the reading of the test results.
