WO2024000387A1 - Ai model establishment evaluation system, video stream simulation module and method, and controller - Google Patents

Ai model establishment evaluation system, video stream simulation module and method, and controller Download PDF

Info

Publication number
WO2024000387A1
WO2024000387A1 PCT/CN2022/102783 CN2022102783W WO2024000387A1 WO 2024000387 A1 WO2024000387 A1 WO 2024000387A1 CN 2022102783 W CN2022102783 W CN 2022102783W WO 2024000387 A1 WO2024000387 A1 WO 2024000387A1
Authority
WO
WIPO (PCT)
Prior art keywords
model
video stream
video
controller
streaming media
Prior art date
Application number
PCT/CN2022/102783
Other languages
French (fr)
Chinese (zh)
Inventor
樊林
Original Assignee
京东方科技集团股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 京东方科技集团股份有限公司 filed Critical 京东方科技集团股份有限公司
Priority to CN202280002046.XA priority Critical patent/CN117642728A/en
Priority to PCT/CN2022/102783 priority patent/WO2024000387A1/en
Publication of WO2024000387A1 publication Critical patent/WO2024000387A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/10Requirements analysis; Specification techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/06Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling

Definitions

  • Embodiments of the present disclosure relate to, but are not limited to, the technical field of intelligent systems, and in particular, to an AI model construction and evaluation system, a video stream simulation module and method, and a controller.
  • Computer vision artificial intelligence Artificial Intelligence, AI
  • AI Computer vision artificial intelligence
  • GPU Graphics Processing Unit
  • Triton is an open source software released by NVIDIA
  • the AI model is dynamically arranged and processed as needed to achieve the purpose of saving physical resources.
  • each model update may involve changes in the accuracy of multiple AI functions.
  • DevOps Development & Operations, Integration of development and operation
  • the embodiment of the present disclosure provides an AI model construction and evaluation system, including: a controller and a simulation evaluation module, wherein:
  • the controller is configured to determine the grouping information of the AI model; according to the grouping order, perform the following operations for the AI model of each group: construct the AI model of the current group to the test environment, and send the first notification to the simulation evaluation module;
  • the simulation evaluation module is configured to receive a first notification from the controller and provide a video streaming service to the AI model.
  • the content of the video streaming service is a video stream of video files required to evaluate the AI model of the current group. Content; perform AI capability assessment on the currently grouped AI model; release the video stream after the capability assessment is completed.
  • the embodiment of the present disclosure also provides an AI model construction and evaluation method, including:
  • the controller determines model grouping information
  • the controller constructs the AI model of the current group to the test environment, and sends the first notification to the simulation evaluation module;
  • the simulation evaluation module receives the first notification from the controller and provides a video streaming service to the AI model.
  • the content of the video streaming service is the video streaming content of the video file required to evaluate the AI model of the current group; Perform an AI capability assessment on the currently grouped AI model; after the capability assessment is completed, release the video stream.
  • the embodiment of the present disclosure also provides an AI model construction and evaluation method, including:
  • the controller determines model grouping information
  • the controller performs the following operations on the AI model of each group in accordance with the grouping order: builds the AI model of the current group to the test environment, and notifies the video stream simulation module to push the video stream content of the video file required to evaluate the AI model of the current group.
  • To the streaming media platform notify the AI capability evaluation module to use the video stream of the streaming media platform to evaluate the AI capabilities of the current grouped AI model.
  • An embodiment of the present disclosure also provides a controller, including a memory; and a processor coupled to the memory, the processor being configured to execute any implementation of the present disclosure based on instructions stored in the memory.
  • a controller including a memory; and a processor coupled to the memory, the processor being configured to execute any implementation of the present disclosure based on instructions stored in the memory.
  • Embodiments of the present disclosure also provide a storage medium on which a computer program is stored.
  • the program is executed by a processor, the AI model construction and evaluation method described in any embodiment of the present disclosure is implemented.
  • Embodiments of the present disclosure also provide a video stream simulation method, including:
  • the video stream simulation module pulls the corresponding video file from the video file address list, pushes the video stream content of the video file to the streaming media platform, and notifies the controller that the streaming media environment is completed;
  • the video stream simulation module receives the release instruction of the controller and stops pushing the video stream content
  • the video stream simulation module sends a video stream release instruction to the streaming media platform.
  • Embodiments of the present disclosure also provide a video stream simulation module, including a memory; and a processor coupled to the memory, the processor being configured to execute any of the instructions of the present disclosure based on instructions stored in the memory.
  • the steps of the video stream simulation method according to an embodiment.
  • An embodiment of the present disclosure also provides a storage medium on which a computer program is stored.
  • the program is executed by a processor, the video stream simulation method as described in any embodiment of the present disclosure is implemented.
  • Figures 1A, 1B and 1C are schematic structural diagrams of three AI model construction and evaluation systems according to exemplary embodiments of the present disclosure
  • Figure 2A is a schematic structural diagram of another AI model construction and evaluation system according to an exemplary embodiment of the present disclosure
  • Figure 2B is a schematic diagram of a test case and required video stream of an AI model according to an exemplary embodiment of the present disclosure
  • Figures 2C and 2D are schematic diagrams of two exemplary methods for group testing the test cases shown in Figure 2B;
  • Figure 2E is a schematic diagram of a test case and required video stream of another AI model according to an exemplary embodiment of the present disclosure
  • Figure 2F is a schematic diagram of an exemplary method for group testing the test cases shown in Figure 2E;
  • Figure 3 is a schematic diagram of a method for grouping video streams required for simulation according to an exemplary embodiment of the present disclosure
  • Figure 4 is a schematic diagram of a DevOps task initiation process according to an exemplary embodiment of the present disclosure
  • Figure 5 is a schematic diagram of a video environment construction process according to an exemplary embodiment of the present disclosure
  • Figure 6 is a schematic flowchart of an AI model construction and evaluation method according to an exemplary embodiment of the present disclosure
  • Figure 7 is a schematic flowchart of another AI model construction and evaluation method according to an exemplary embodiment of the present disclosure.
  • Figure 8 is a schematic flowchart of a video stream simulation method according to an exemplary embodiment of the present disclosure.
  • the embodiment of the present disclosure provides an AI model construction and evaluation system, including: a controller 11 and a simulation evaluation module 12, wherein:
  • the controller 11 is configured to determine the grouping information of the AI model; according to the grouping order, perform the following operations for the AI model of each group: construct the AI model of the current group to the test environment, and send the first notification to the simulation evaluation module 12 ( The function of the first notification is to inform the simulation evaluation module 12 that the AI model of the current group has been built into the test environment);
  • the simulation evaluation module 12 is configured to receive the first notification from the controller 11 and provide a video streaming service to the AI model.
  • the content of the video streaming service is a video stream of video files required to evaluate the AI model of the current group. Content; perform AI capability assessment on the currently grouped AI model; release the video stream after the capability assessment is completed.
  • the AI model construction and evaluation system of the embodiment of the present disclosure groups the AI models, sequentially builds the AI models of each group to the test environment, and provides the streaming media services required for evaluation on demand for the currently grouped AI models. After the evaluation is completed Finally, the video stream is released, and there is no need to maintain the video stream of all AI models at all times. This not only solves the problem of wasting a lot of resources in the video streaming environment, but also greatly reduces the computing resources required in the DevOps environment of the AI model, and also makes the model evaluation process more feasible. Control, improve the efficiency of AI technology research and development, and reduce costs.
  • the AI model described in the embodiments of the present disclosure refers to a program that can perceive, reason, act and adapt, while the machine learning model generally refers to a program that can continuously improve performance as the amount of data increases.
  • the deep learning model is a machine A subset of learning models, deep learning models are programs that use multi-layer neural networks to learn from large amounts of data. Therefore, in terms of coverage, AI models are larger than machine learning models and are larger than deep learning models.
  • test case when evaluating the AI capabilities of an AI model, one test case or multiple test cases can be designed for one AI model.
  • a test case is to design a situation in which the AI model must be able to run normally and achieve the expected execution results of the model design.
  • the test cases designed for it can include the following three:
  • Test case 1 Notify the AI model to pull video stream 1 (video stream 1 does not contain VIP users), and detect the AI model output results;
  • Test case 2 Notify the AI model to pull video stream 2 (video stream 2 contains 1 VIP user), and detect the AI model output result;
  • Test case 3 Notifies the AI model to pull video stream 3 (video stream 3 contains 2 VIP users), and detects the AI model output result.
  • test Case When testing each test case, when the output result of the AI model matches the actual pulled video stream content, the test case passes; when the AI model output result does not match the actual pulled video stream content, the test Case failed.
  • the controller 11 pulls the model code of the AI model from the code warehouse, compiles the model code and deploys it to the test environment; when testing, the AI model pulls the streaming media platform or streaming media server The video stream is output accordingly according to the pulled video stream.
  • the simulation evaluation module detects the output result of the AI model, and determines whether the test case passes based on the output result of the AI model.
  • the simulation evaluation module 12 provides video streaming services to the AI model, which means that the simulation evaluation module provides one or more video stream control interfaces to the AI model (exemplarily, the video stream control interface can be a video stream address ), the AI model can pull a certain video stream by controlling different video stream control interfaces. After the capability evaluation is completed, the simulation evaluation module 12 releases the release stream through the release video stream control interface.
  • the test environment may include one or more physical machines, which may receive the AI model deployed by the controller 11 and run the AI model.
  • the controller 11 constructs the AI model of the current group to the test environment; when testing, the simulation evaluation module 12 provides video streaming services to the AI model, and evaluates the AI capabilities of the AI model of the current group; After the capability assessment is completed, release the video stream.
  • the simulation evaluation module 12 may be partially or entirely installed on the physical machine where the test environment is located, or may be installed on a physical machine outside the test environment. This is not limited in the embodiment of the present disclosure.
  • the simulation evaluation module 12 includes a video stream simulation server 120 and an AI capability evaluation module 121, where:
  • the video stream simulation server 120 is configured to receive the first notification from the controller 11 and provide a video stream service to the AI model.
  • the content of the video stream service is the video of the video file required to evaluate the AI model of the current group.
  • Stream content send a second notification to the controller 11, so that the controller 11 sends a third notification to the AI capability evaluation module 121; receive the fifth notification from the controller 11, release the video stream;
  • the AI capability evaluation module 121 is configured to receive the third notification from the controller 11 and perform an AI capability evaluation on the AI model of the current group; after the capability evaluation is completed, send the fourth notification to the controller 11 so that the controller 11 Send the fifth notification to the video stream simulation server 120;
  • the controller 11 is further configured to receive a second notification from the video stream simulation server 120 and send a third notification to the AI capability evaluation module 121; upon receiving a fourth notification from the AI capability evaluation module 121, send a fifth notification. Notification to video stream simulation server 120.
  • the video stream simulation server 120 when the video stream simulation server 120 is ready for the video stream service, it notifies the controller 11, and the controller 11 notifies the AI capability evaluation module 121 to start AI capability evaluation of the AI model of the current group.
  • the video stream simulation server 120 may also directly notify the AI capability evaluation module 121 to start performing AI capability evaluation on the AI model of the current group, and the embodiment of the present disclosure does not limit this.
  • the AI capability assessment module 121 completes the AI capability assessment, it notifies the controller 11, and the controller 11 notifies the video stream simulation server 120 to release the video stream.
  • the AI capability assessment module can also directly 121 notifies the video stream simulation server 120 to release the video stream, and the embodiment of the present disclosure does not limit this.
  • the controller 11 notifies the AI capability evaluation module 121 to start AI capability evaluation of the current grouped AI model and the controller 11 notifies the video stream simulation server 120 to release the video stream, which enables the controller 11 to accurately control each
  • the process of AI model evaluation makes the model evaluation process more controllable, improves the efficiency of AI technology research and development, and reduces costs.
  • the video stream simulation server 120 includes a video stream simulation module 1201 and a streaming media platform 1202, wherein:
  • the video stream simulation module 1201 is configured to receive the first notification from the controller 11, push the video stream content of the video file required to evaluate the AI model of the current group to the streaming media platform 1202, and send the second notification to the controller 11 ; Receive the fifth notification from the controller 11, stop pushing the video stream content, and send the sixth notification to the streaming media platform 1202;
  • the streaming media platform 1202 is configured to receive the video stream content pushed by the video stream simulation module 1201 and provide video streaming services to the AI model; upon receiving the sixth notification from the video stream simulation module 1201, release the video stream.
  • the controller 11 when building the test environment, the controller 11 builds the AI model of the current group into the test environment; when performing the test, the video stream simulation module 1201 adds the video of the video file required to evaluate the AI model of the current group.
  • the streaming content is pushed to the streaming media platform 1202, and the streaming media platform 1202 provides video streaming services to the AI model in the test environment.
  • the AI capability evaluation module 121 notifies the AI model to pull the video stream of the streaming media platform 1202, and evaluates the AI model's The output results are tested, and whether the test case passes is judged based on the output results of the AI model.
  • embodiments of the present disclosure provide an AI model construction evaluation system, including: a controller 11, a video stream simulation module 1201, a streaming media platform 1202, and an AI capability evaluation module 121 ,in:
  • the controller 11 is configured to determine the model grouping information; according to the grouping order, perform the following operations for the AI model of each group: build the AI model of the current group to the test environment, send the first notification to the video stream simulation module 1201; receive The second notification is sent to the video stream simulation module 1201, and the third notification is sent to the AI capability evaluation module 121; the fourth notification is received from the AI capability evaluation module 121, and the fifth notification is sent to the video stream simulation module 1201;
  • the video stream simulation module 1201 is configured to receive the first notification from the controller 11, push the video stream content of the video file required to evaluate the AI model of the current group to the streaming media platform 1202, and send the second notification to the controller 11 ; Receive the fifth notification from the controller 11, stop pushing the video stream content, and send the sixth notification to the streaming media platform 1202;
  • the AI capability assessment module 121 is configured to receive the third notification from the controller 11, use the video stream to perform an AI capability assessment on the AI model of the current group, and after the capability assessment is completed, send the fourth notification to the controller 11;
  • the streaming media platform 1202 is configured to receive the video stream content pushed by the video stream simulation module 1201 and provide video streaming services to the AI model; upon receiving the sixth notification from the video stream simulation module 1201, release the video stream.
  • the DevOps pipeline of AI models includes the following process: First, R&D personnel develop the code of the AI model ⁇ compile + deploy the AI model code to the test environment (this step is collectively referred to as the build process and can be realized through automation) ⁇ test + result analysis (This step is collectively called the evaluation process and can be realized through automation) ⁇ After repeated debugging and defect modification, after the test is OK, it will be launched on the production platform. Due to the debugging and defect modification of the AI model, it is necessary to cycle through the construction, evaluation and defect modification processes multiple times. Only after all defects have been cleared can the launch process be entered. The construction script of each AI model is usually completed by R&D personnel, the evaluation process is mainly led by testers, and the online process is mainly led by operation and maintenance personnel.
  • the actual physical locations of the video stream simulation module 1201 and the AI capability evaluation module 121 can be located at any location, as long as they are connected to the controller 11 and the streaming media platform 1202 through the network.
  • the video stream simulation module 1201 can be located on the physical machine where the controller 11 is located, or on the physical machine where the streaming media platform 1202 is located, or it can be located on a physical machine other than the controller 11 or the streaming media platform 1202 superior.
  • the AI capability assessment module 121 can be located on the physical machine where the test environment is located. When building the test environment, the code corresponding to the AI capability assessment module 121 and the model code corresponding to the AI model can be pulled from the code warehouse, and then compiled.
  • the code corresponding to the AI capability assessment module 121 may include script code required to run automated tests, and run preset test cases for different AI models to conduct specific capability assessments.
  • each test case can specify the pulled video stream address.
  • the AI capability evaluation module 121 notifies the AI model to pull the video stream of the specified video stream address, and the AI model will pull the video stream of the specified video stream address.
  • the AI capability evaluation module determines whether the output results of the AI model match the actual pulled video stream content, and determines whether each test case passes the test.
  • the AI capability evaluation module 121 and the AI model are deployed on the physical machine where the test environment is located, the physical resources required to build the entire AI model construction and evaluation system can be reduced, system resource utilization can be improved, system complexity can be reduced, and AI capabilities can be reduced Evaluate network communication data between module 121 and other modules.
  • the AI capability evaluation module 121 may also be located on a physical machine outside the test environment.
  • the streaming media platform 1202 can be a streaming media server.
  • the video stream simulation module 1201 can specify the push address corresponding to each video stream. After the video stream is released , the push address stops providing the corresponding video streaming service.
  • the AI model construction evaluation system also includes a code warehouse 105 , where the code warehouse 105 is configured to store the code information of the AI model, the grouping information of the model, and the construction script of the model. , the strategy code that organizes the operation of the AI model, etc.
  • the code repository 105 may be a GIT code repository.
  • GIT is an open source distributed version control system for agile and efficient handling of any project, small or large.
  • the code repository 105 can also be other types of code repositories, such as SVN (Subversion), etc., and the embodiment of the present disclosure does not limit this.
  • SVN Subversion
  • Each AI model can correspond to a project in the code warehouse.
  • the AI capability evaluation module is located on the physical machine where the test environment is located.
  • the physical machine where the test environment is located is deployed with an AI model.
  • the AI model needs to pull the video stream of the streaming media platform, which is equivalent to the physical machine where the AI capability assessment module is located.
  • the video stream of the streaming media platform needs to be pulled. Therefore, there is a connection relationship between the AI capability evaluation module in Figure 2A and the streaming media platform.
  • the AI capability evaluation module can also be located on a physical machine other than the physical machine where the test environment is located. In this case, between the AI capability evaluation module in Figure 1C and the streaming media platform There is no connection between them.
  • building the AI model of the current group to the test environment includes:
  • the code repository 105 can automatically trigger the controller 11 to perform a build evaluation process.
  • the controller 11 builds the AI model of the current group to the test environment
  • the controller 11 pulls the model code of the AI model of the current group (which can be pulled to the physical machine where the controller 11 is located).
  • the controller 11 in the controller 11 (on the physical machine where it is located) compiles the model code of the AI model of the current group, and finally the controller 11 deploys the AI model of the current group to the test environment.
  • the model code after compiling the AI model of the current group can be stored in the code warehouse.
  • building the AI model of the current group to the test environment includes: pulling The model code after compiling the AI model of the current group; deploy the AI model of the current group to the test environment.
  • the controller 11 starts a unified build evaluation process at regular intervals every day.
  • the controller 11 regularly starts the unified construction and evaluation process for dozens or even hundreds of models every day, so that The model evaluation process becomes more controllable, improving the efficiency of AI technology research and development.
  • the controller 11 is further configured to organize and merge the construction scripts of multiple AI models and then push them to the task queue.
  • the controller 11 needs to maintain a task queue, which can include: grouping information of the AI model and the deployment order of the AI model grouping, so that the following two dimensions of control can be achieved through the task queue: 1. How to Group AI models; 2. Deployment order after grouping (that is, which batch of AI models to deploy first, and which batch of AI models to deploy next).
  • the task queue also includes: sequential DevOps process for each AI model.
  • the sequential DevOps process of each AI model includes the process from compilation ⁇ deployment ⁇ testing ⁇ result analysis.
  • the build scripts pushed to the task queue can be grouped by specialized grouping personnel.
  • the grouping personnel can store the grouping code in the code warehouse 105, and the controller 11 pulls the grouping code and obtains the grouping. information.
  • build scripts pushed to the task queue may be grouped by controller 11 .
  • the controller 11 determines model grouping information, including:
  • the multiple AI models to be built are grouped according to the resources consumed by each AI model, and the resources consumed by each group of AI models are less than the resources of the test environment.
  • the AI model construction and evaluation system of the disclosed embodiment can run multiple AI models simultaneously on a single GPU to maximize utilization, and can be integrated with Kubernetes for orchestration, indicators and automation. Extension.
  • a single GPU can be a GPU on the physical machine where the test environment is located.
  • the multiple AI models to be built are grouped according to the resources consumed by each AI model.
  • the resources here can be hardware resources (such as inference card resource size, etc.) or software resources ( For example, number of threads, etc.).
  • the resource can be a hardware resource.
  • the multiple AI models to be built are grouped according to the hardware resources consumed by each AI model. Since the hardware resources are easier and more convenient to read, the feasibility of model grouping is enhanced. implement.
  • the inference card may be a graphics card, that is, the graphics card may be used for inference.
  • the inference card may be a non-graphics card, that is, the inference card may not have a display function.
  • the test environment needs to deploy 100 AI models at the same time.
  • the hardware resource requirements of the environment are relatively high; if the 100 AI models are divided into 10 groups, each group has 10 AI models, then the test environment only needs to deploy 10 AI models in each group at the same time, and deploy 10 groups in turn, which reduces the load of the test environment. Hardware resource requirements.
  • the controller 11 determines model grouping information, further including:
  • the multiple AI models to be built are grouped according to the relationship between different AI models, and the AI models with dependencies are grouped into one group.
  • each group of 10 AI models there may be business dependencies between some or all models, or there may be no business dependencies between all models, but there are business dependencies.
  • Sexual AI models should be grouped into one group.
  • the controller 11 determines dependencies between multiple AI models (ie, whether there are business dependencies) according to the policy code that organizes the operation of the AI models.
  • the business dependency described in the embodiments of this disclosure refers to the specific logical relationship between multiple different AI models set in a certain AI application or AI business in order to achieve a certain goal, for example: multiple The execution sequence of AI models, the output of AI model A as the input of AI model B, etc.
  • the controller 11 determines whether there are business dependencies between multiple AI models by organizing the strategy code for running the AI models.
  • the strategy code for organizing the running of the AI models is usually stored in a code warehouse.
  • the strategy code for organizing the operation of the AI model may be as follows: detect all women in the video stream through model 1, if not detected, return an empty result; use model 2 to detect women between 20 and 30 years old in the output of model 1 If the person between them is not detected, an empty result will be returned; if the person wearing red clothes among the 20- to 30-year-old women output by Model 2 is detected by Model 3, an empty result will be returned.
  • model 1, model 2 and model 3 have business dependencies and should be divided into one group (in addition to model 1, model 2 and model 3, this group of AI models can also Including other AI models, or not including other AI models, depending on the hardware resources of the test environment), that is, Model 1, Model 2 and Model 3 are constructed and evaluated together.
  • the controller 11 determines model grouping information, further including:
  • the multiple AI models to be constructed are grouped according to the video streams required for the AI capability assessment of the multiple AI models, and the AI models that require the same video stream for the AI capability assessment are grouped into one group.
  • each AI model can design only one test case, or multiple test cases can be designed.
  • the video streams required by the multiple test cases can be the same or different.
  • model 1, model 2, and model 3 only require video stream a when evaluating their capabilities. Then, model 1, model 2, and model 3 can be grouped into one group.
  • the capability assessment of Model 1 requires video streams a and b
  • the capability assessment of Model 2 requires video streams a and c
  • the capability assessment of Model 3 requires video streams a and d
  • the capability assessment of Model 4 requires video streams e and f.
  • model 1, model 2 and model 3 can still be grouped into one group.
  • the controller 11 is configured to:
  • test cases of each grouped AI model when evaluating the AI capabilities of each grouped AI model, can be grouped, and the test cases of each grouped AI model can be grouped to make the test Maximum efficiency and enables testability with limited resources.
  • the test cases of the currently grouped AI model are grouped according to the CPU resources consumed by the video streams required to run the test cases, and at the same time, the resources consumed by the video streams required to run each group of test cases are smaller than those of streaming media Platform 1202 resources. For example, the CPU resources consumed by the video streams required to run each set of test cases simultaneously are less than the CPU resources of the streaming media platform 1202 .
  • the test cases of the currently grouped AI model can also be grouped based on the fact that the GPU resources consumed by the video stream required to run each group of test cases simultaneously is less than the GPU resources of the streaming media platform 1202. This disclosure The embodiment does not limit this.
  • the controller 11 groups the test cases according to the resource size of the streaming media platform 1202 occupied by the video streams required to run the test case. Resource requirements for the streaming media platform 1202 can be reduced.
  • each AI model has 10 test cases (i.e., 10 AI capabilities to be tested)
  • resources of the streaming media platform 1202 exemplary , resource is CPU resource
  • each AI model tests 1 test case at a time
  • the system can test 10 test cases at the same time in one round (assuming that the video streams of these 10 test cases are different ), a total of 10 rounds of testing are required, that is, the test cases are divided into 10 groups.
  • the video streams required for each group of multiple test cases may be the same or may be different, and the embodiments of the present disclosure do not limit this.
  • the controller 11 notifies the video stream simulation module 1201 to prepare the video stream content of the video files required for the test case of the current group, and pushes the video stream content of these video files to the streaming media platform 1202 for video streaming through the video stream simulation module 1201 Provided, after the video stream required for the current grouped test case is ready on the streaming media platform 1202, the controller 11 notifies the AI capability evaluation module 121 to start testing (the AI capability evaluation module 121 notifies the AI model to pull the streaming media platform 1202 video stream, and detect the output results of the AI model.
  • the AI model pulls the video stream of the streaming media platform 1202 it can be processed frame by frame, or it can be processed in multiple frames. , the embodiment of the present disclosure does not limit this).
  • the AI capability evaluation module 121 notifies the controller 11 that the testing is completed.
  • the controller 11 notifies the video stream simulation module 1201 to stop pushing the video stream content, and the video stream simulation module 1201 notifies the streaming media platform 1202 to release the video stream.
  • the controller 11 notifies the video stream simulation module 1201 to prepare the video stream content of the video file required for the test case of the next group until the test case testing of all groups is completed. Then, re-construct the next batch of grouped AI models to the test environment, and test the test cases of the next batch of grouped AI models according to the above method.
  • the test time required for each test case may be the same or different. Therefore, the test cases of each group can be divided into multiple groups, and the test cases using the same video stream are divided into one group.
  • the AI capability evaluation module 121 can notify the controller 11 that the test case or the test case of this group is completed, and the controller 11 notifies the video stream simulation module 1201 to stop pushing the test case or the test case.
  • the video stream content corresponding to the group's test case the video stream simulation module 1201 notifies the streaming media platform 1202 to release the test case or the video stream corresponding to the group's test case, so that the resources of the streaming media platform 1202 can be released as early as possible and improve parallel efficiency. .
  • test cases of the currently grouped AI model include 20 test cases, and the 20 test cases require three video streams.
  • the 10 test cases A1 to A10 require video streams.
  • the five test cases B1 to B5 require video stream b
  • the five test cases C1 to C5 require video stream c.
  • the streaming media platform 1202 can provide video streams a and b at the same time or provide video streams a and c at the same time.
  • these 20 test cases can be divided into 10 groups.
  • the first group of test cases includes A1 and B1
  • the second group of test cases Including A2, B2,...
  • the fifth group of test cases includes A5, B5
  • the sixth group of test cases includes A6, C1
  • the seventh group of test cases includes A7, C2,...
  • the tenth group of test cases includes A10, C5, in
  • video stream b can be released and video stream c provided, and then the sixth set of test cases can be evaluated.
  • the 10 test cases from A1 to A10 can be divided into one group
  • the 5 test cases from B1 to B5 can be divided into one group
  • the 5 test cases from C1 to C5 can be divided into one group.
  • the streaming media platform 1202 releases the video stream corresponding to the group's test case, so that the resources of the streaming media platform 1202 can be released as early as possible and improve parallel efficiency.
  • the streaming media platform 1202 can provide video streams a, b, and c at the same time
  • these 20 test cases can be divided into 10 groups, where , the first group of test cases includes A1, B1, C1, the second group of test cases includes A2, B2, C2,..., the fifth group of test cases includes A5, B5, C5, and the sixth group of test cases includes A6 , the seventh group of test cases includes A7,..., and the tenth group of test cases includes A10.
  • each AI model only runs one test case at the same time. In actual use, each AI model can run multiple test cases at the same time.
  • the video streams corresponding to the multiple test cases can be the same or different.
  • the current batch of AI models includes 10 (that is, 10 AI capabilities to be tested), each AI model has 10 test cases, and the 100 test cases correspond to different video streams.
  • the CPU resource performance of the streaming media platform 1202 is very strong, and it can provide video streaming services corresponding to the 100 test cases at the same time, and the hardware resources of the test environment are very strong.
  • Each AI model can test 10 test cases at a time, and the system is in one round. You can test 100 test cases at the same time, that is, all test cases are divided into one group.
  • the controller 11 notifies the video stream simulation module 1201 to prepare the video stream content of the video files required for these 100 test cases, and pushes the video stream content of these video files to the streaming media platform 1202 through the video stream simulation module 1201 Provide video streams.
  • the controller 11 notifies the AI capability evaluation module 121 to start testing (the AI capability evaluation module 121 notifies the AI model to pull the streaming media The video stream of the platform 1202 and detect the output results of the AI model).
  • the AI capability evaluation module 121 notifies the controller 11 that the test is completed, the controller 11 notifies the video stream simulation module 1201 to stop pushing video stream content, and the video stream simulation module 1201 notifies the streaming media platform 1202 to release the video stream.
  • the controller 11 notifies the video stream simulation module 1201 to release the video file corresponding to the test case or the group's test case.
  • the video stream simulation module 1201 notifies the streaming media platform 1202 to release the video stream corresponding to the test case or the test case of the group).
  • the controller 11 reconstructs the next batch of grouped AI models to the test environment, and according to the above method, tests the test cases of the next batch of grouped AI models.
  • grouping the test cases of the currently grouped AI model further includes: grouping according to video streams required to run the test cases.
  • AI model 1 needs to detect human faces
  • AI model 2 needs to detect human heads
  • the five test cases from D1 to D5 of AI model 1 require video stream a
  • E1 to The five test cases of E5 require video stream b
  • the five test cases of AI model 2 from F1 to F5 require video stream a
  • the five test cases of G1 to G5 require video stream c.
  • the streaming media platform 1202 can provide two at the same time. Video streams cannot provide three video streams at the same time.
  • the first set of test cases can include D1, E1, and F1 (requiring video streams a and b)
  • the second set of test cases can include D2 and E2.
  • the fifth group of test cases can include D5, E5, F5 (requires video streams a, b), and the sixth group of test cases can include G1, G2 and G3 (requires video streams c), the seventh group of test cases can include G4 and G5 (requires video stream c).
  • the specific method of grouping test cases can be set as needed, and the embodiments of the present disclosure do not limit this.
  • a test case fails to pass the test, relevant developers can be reminded by sending corresponding alarm information, emails, etc., so that the developers can modify the model code as early as possible to improve research and development efficiency.
  • this embodiment of the present disclosure combines the video streaming environment requirements required for the AI capability goals targeted by DevOps, combined with the case requirements required for automated verification, uses video files to simulate video streaming technology, and converts the media in the media file library The file is simulated into a video stream, the construction process is completed, and then released, which solves the problem of excessive CPU and memory resource overhead caused by the huge video stream required by some methods to simultaneously carry out the DevOps construction process of multiple AI services.
  • the video stream simulation module 1201 pushes the video stream content required for the test case of the current group to the streaming media platform 1202 for cyclic provision.
  • the AI capability evaluation module 121 can determine whether the AI model can provide inference results within a relative playback duration, that is, for each test case Having a relative video start time reduces the difficulty of evaluation. For example, assume that the video stream playback duration of a certain test case is 15s. If the AI model gives the inference result within 15s, the inference is considered successful. Then, since the video stream content is pushed in a loop, if within 15s from a certain moment, If the AI model does not provide an inference result, the AI capability evaluation module 121 may determine that the inference fails.
  • the AI capability evaluation module 121 can accurately determine the start time of the AI model pulling the video stream and the inference time when obtaining the inference result through the timestamp of the video frame, thereby obtaining an accurate inference duration.
  • This method of obtaining accurate inference duration does not require looping the video stream, but the execution steps are relatively complex and the evaluation difficulty is relatively high.
  • the video stream simulation module 1201 pushes the video stream content required for the current grouped test case to the streaming media platform 1202 for cyclic provision, including any of the following two situations: 1) Video stream simulation module 1201 cyclically pushes the video stream content required for the test case of the current group to the streaming media platform 1202, so that the streaming media platform 1202 cyclically provides the video stream required for the test case of the current group; 2) the video stream simulation module 1201 will The video stream content required for the test case of the current group is pushed to the streaming media platform 1202 (pushed only once), but the streaming media platform 1202 provides the video stream required for the test case of the current group in a loop, that is, the streaming media platform 1202 has a loop mode, at this time, the video stream simulation module 1201 only needs to push the video stream content once, and the streaming media platform 1202 provides the video stream in a loop.
  • the AI model building evaluation system further includes a media file library 106 , wherein the media file library 106 is configured to store video files required for evaluating the AI model of each group. .
  • the video files corresponding to the test cases are stored in the media file library 106 .
  • the video stream simulation module 1201 plays the video file from the media file library 106, and then pushes the video stream content of the played video file to the streaming media platform 1202.
  • the video files in the embodiment of the present disclosure are videos that are pre-stored in the media file library 106 and are used to evaluate the function or performance of the AI model to achieve automated testing.
  • the streaming media platform 1202 can be more focused on implementing the push-pull streaming function.
  • the storage of video files required by the streaming media platform 1202 is completed by the media file library 106. , which can provide richer video file content, which can make the evaluation of the AI model more accurate.
  • the video stream simulation module 1201 when the format of the video file is a non-streaming media file format, notifies the streaming media platform 1202 to convert the format of the video file into a streaming media file format.
  • the format of the video file may be MPEG-1 or any other video file format
  • the streaming media platform 1202 may convert it into MPEG-4 or any other streaming media file format.
  • This embodiment of the present disclosure is suitable for This is not a limitation.
  • the AI model construction evaluation system simulates on demand the construction evaluation process of the video streaming environment required in the AI intelligent service DevOps process, including the following steps:
  • the DevOps controller organizes the build process, merges it and pushes it to the task queue
  • the DevOps controller obtains the build task, pulls the group code from the GIT code warehouse, obtains the model group information, then pulls the model code of the current batch group, compiles and deploys it to the test environment;
  • the DevOps controller reads the configuration involved in all AI capability catalogs (here, the AI capability catalog refers to the list of AI functions that need to be tested, that is, test cases) in the current batch group (this configuration includes the AI model and all Required video stream address list), sort out the video stream address list required for testing;
  • the DevOps controller sends the required video stream address list to the video stream simulation module for processing
  • the video stream simulation module obtains the video stream information in the case library (determines whether the video file format is a streaming media format, and if not, notifies the streaming media platform to convert the video file format to a streaming media file format), and pulls the corresponding video file;
  • the video stream simulation module pushes the video stream content of the video file to the streaming media platform for cyclic provision based on the one-to-one correspondence between the video file and the video stream address (the video stream simulation module cyclically pushes the video stream content of the video file to The streaming media platform, or the streaming media platform provides the video streaming content of the video files in a loop) and verifies them one by one;
  • the DevOps controller After receiving the signal that the video streaming environment construction is complete, the DevOps controller starts the AI capability evaluation module to evaluate the model. After the model evaluation is completed, it sends a release instruction to the video streaming simulation module;
  • the video stream simulation module stops pushing video stream content that is no longer in use based on the usage of the video stream, and sends a release instruction to the streaming media platform to complete the release of the video stream.
  • the AI model construction and evaluation system provided by the embodiments of the present disclosure temporarily builds the required video stream according to the needs of the evaluation object, and releases it immediately after completing the model evaluation, which greatly reduces the resources required in the DevOps environment and makes the model evaluation process more feasible. control; the model evaluation process has a video start time for the case, which reduces the difficulty of evaluation; the construction, evaluation, and online processes can be carried out in groups, which improves the efficiency of AI technology research and development and reduces costs.
  • embodiments of the present disclosure also provide an AI model construction and evaluation method, including:
  • Step 601 The controller determines the grouping information of the AI model
  • Step 602 According to the grouping order, perform the following operations on the AI models of each group:
  • the controller builds the AI model of the current group to the test environment and sends the first notification to the simulation evaluation module; the simulation evaluation module receives the first notification from the controller and provides video streaming services to the AI model.
  • the content of the video streaming service is to evaluate the current grouping.
  • the AI model construction and evaluation method of the embodiment of the present disclosure groups the AI models, sequentially constructs the AI models of each group to the test environment, and provides the streaming media services required for evaluation on demand for the currently grouped AI models.
  • the video stream is released, and there is no need to maintain the video stream of all AI models at all times. This not only solves the problem of wasting a lot of resources in the video streaming environment, but also greatly reduces the computing resources required in the DevOps environment of the AI model, and also makes the model evaluation process more efficient. Controllable, it improves the efficiency of AI technology research and development and reduces costs.
  • the controller determines grouping information of the AI model, including:
  • the controller obtains the construction scripts of multiple AI models to be built
  • the controller groups the multiple AI models to be built according to the resources consumed by each AI model.
  • the hardware resources consumed by each group of AI models are less than the hardware resources of the test environment.
  • the total inference card resource size occupied by these 10 AI models should be less than 16G.
  • the controller determines grouping information of the AI model, including:
  • the controller obtains the construction scripts of multiple AI models to be built
  • the controller groups the multiple AI models to be built according to the resources consumed by each AI model and the relationship between different AI models.
  • the hardware resources consumed by each group of AI models are less than the hardware of the test environment. Resources, AI models with dependencies are grouped into a group.
  • the controller determines dependencies between multiple AI models according to a policy code that organizes the operation of the AI models.
  • the AI model construction and evaluation method further includes:
  • the controller obtains the grouping information of the test cases of the currently grouped AI model
  • the AI capability evaluation of the currently grouped AI models includes: performing an AI capability evaluation on the test cases of each group according to the grouping order of the test cases.
  • the controller groups the test cases of the currently grouped AI model according to the resources consumed by the video stream required to simulate the test case, and at the same time, the resources consumed by the video stream required to simulate each group of test cases are less than the resource consumed by the video stream.
  • Media platform resources
  • the video stream simulation module pushes the video stream content of the video file required by the test case of the current group to the streaming media platform to cyclically provide the test case of the current group.
  • the video stream required for the test case (the video stream simulation module cyclically pushes the video stream content of the video file required to evaluate the current grouped AI model to the streaming media platform, or the streaming media platform cyclically provides the video stream content of the video file ).
  • the video stream simulation module after the test case of a certain test case or a test case of a certain group is tested, notifies the streaming media platform to release the video stream corresponding to the test case or the test case of the group so as to release it as soon as possible. Resources for streaming platforms.
  • the controller builds the current grouped AI model to the test environment, including:
  • the grouping information of the AI model, the code information of the AI model, the construction script of the AI model, and the policy code for organizing the operation of the AI model are all stored in the code warehouse.
  • the code repository can be a GIT code repository.
  • GIT is an open source distributed version control system for agile and efficient handling of any project, small or large. Whenever developers submit code to the GIT code repository, the GIT code repository can automatically trigger the DevOps build evaluation process.
  • the video files required to evaluate the AI model for each group are stored in a media file library.
  • the video stream simulation module when the format of the video file is a non-streaming media file format, notifies the streaming media platform to convert the format of the video file into a streaming media file format.
  • the embodiment of the present disclosure also provides an AI model construction and evaluation method, which is applied to the controller.
  • the AI model construction and evaluation method includes:
  • Step 701 Determine model grouping information
  • Step 702 Perform the following operations on the AI model of each group according to the grouping order: build the AI model of the current group to the test environment, and notify the video stream simulation module to evaluate the video stream content of the video file required by the AI model of the current group. Push it to the streaming media platform, and notify the AI capability evaluation module to use the video stream of the streaming media platform to evaluate the AI capability of the current grouped AI model. After the capability assessment is completed, notify the video stream simulation module and streaming media platform to release the video stream.
  • the AI model construction and evaluation method of the embodiment of the present disclosure groups the AI models, sequentially constructs the AI models of each group to the test environment, and provides the streaming media services required for evaluation on demand for the currently grouped AI models.
  • the video stream is released, and there is no need to maintain the video stream of all AI models at all times. This not only solves the problem of wasting a lot of resources in the video streaming environment, but also greatly reduces the computing resources required in the DevOps environment of the AI model, and also makes the model evaluation process more efficient. Controllable, it improves the efficiency of AI technology research and development and reduces costs.
  • determining model grouping information includes:
  • the multiple AI models to be built are grouped according to the resources consumed by each AI model, and the hardware resources consumed by each group of AI models are less than the hardware resources of the test environment.
  • determining model grouping information includes:
  • the multiple AI models to be built are grouped according to the resources consumed by each AI model and the relationship between different AI models.
  • the hardware resources consumed by each group of AI models are less than the hardware resources of the test environment, AI models with dependencies are grouped into a group.
  • dependencies between multiple AI models are determined according to a policy code that organizes the operation of the AI model.
  • the video stream simulation module in step 702 pushes the video stream content of the video file required to evaluate the AI model of the current group to the streaming media platform, and notifies the AI capability evaluation module to use the video of the streaming media platform.
  • the stream performs an AI capability assessment on the current grouped AI model. After the capability assessment is completed, it notifies the video stream simulation module and the streaming media platform to release the video stream, including:
  • each grouped test case performs the following operations for each grouped test case: notify the video stream simulation module to push the video stream content of the video file required for the current grouped test case to the streaming media platform, so that it can be displayed on the streaming media platform.
  • Form a video stream that can be pulled by the AI model notify the AI capability evaluation module to use the video stream of the streaming media platform to test the test cases of each group.
  • the video stream simulation module is notified to stop pushing the video stream content, and the video stream simulation module notifies the streaming media platform to release the video stream.
  • test cases of the currently grouped AI model are grouped according to the resources consumed by the video streams required to simulate the test cases, and at the same time, the resources consumed by the video streams required to simulate each group of test cases are smaller than those of the streaming media platform H.
  • building the AI model of the current group to the test environment includes:
  • notifying the video stream simulation module and the streaming media platform to release the video stream includes:
  • the video stream simulation module is notified to stop pushing the video stream content, and the video stream simulation module sends a video stream release instruction to the streaming media platform.
  • the video source is a video stream simulation module, which pushes streams to the streaming media platform; the AI model pulls streams from the streaming media platform, and the streaming media platform is in the middle, equivalent to a forwarding function, equivalent to AI
  • the model is connected to the video streaming simulation module through the streaming platform.
  • the video files required to evaluate the AI model for each group are stored in a media file library.
  • An embodiment of the present disclosure also provides a controller, including a memory; and a processor coupled to the memory, the processor being configured to execute any implementation of the present disclosure based on instructions stored in the memory.
  • a controller including a memory; and a processor coupled to the memory, the processor being configured to execute any implementation of the present disclosure based on instructions stored in the memory.
  • the controller may include: a first processor, a first memory and a first bus system, wherein the first processor and the first memory are connected through the first bus system, the first memory is used to store instructions, and the first bus system is used to store instructions.
  • a processor is used to execute instructions stored in the first memory.
  • the first processor determines the model grouping information; according to the grouping order, performs the following operations for the AI model of each group: builds the AI model of the current group to the test environment, and notifies the video stream simulation module to evaluate the AI model of the current group
  • the video stream content of the required video file is pushed to the streaming media platform, and the AI capability assessment module is notified to use the video stream of the streaming media platform to evaluate the AI capabilities of the current grouped AI model.
  • the video stream simulation module is notified and Streaming platforms unleash video streaming.
  • the first processor can be a central processing unit (Central Processing Unit, CPU), and the first processor can also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASICs), off-the-shelf programmable processors, etc. Gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • a general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc.
  • the first memory may include read-only memory and random access memory and provide instructions and data to the first processor.
  • a portion of the first memory may also include non-volatile random access memory.
  • the first memory may also store device type information.
  • the first bus system may also include a power bus, a control bus, a status signal bus, etc.
  • the processing performed by the processing device may be completed by instructions in the form of hardware integrated logic circuits or software in the first processor. That is to say, the method steps of the embodiments of the present disclosure may be implemented by a hardware processor, or may be executed by a combination of hardware and software modules in the processor.
  • Software modules can be located in random access memory, flash memory, read-only memory, programmable read-only memory or electrically erasable programmable memory, registers and other storage media.
  • the storage medium is located in the first memory, and the first processor reads the information in the first memory and completes the steps of the above method in combination with its hardware. To avoid repetition, it will not be described in detail here.
  • Embodiments of the present disclosure also provide a storage medium on which a computer program is stored.
  • the AI model construction and evaluation method described in any embodiment of the present disclosure is implemented.
  • This AI model construction and evaluation method can determine model grouping information; according to the grouping order, perform the following operations for the AI model of each group: build the AI model of the current group to the test environment, and notify the video stream simulation module to evaluate the AI model of the current group.
  • the video stream content of the required video file is pushed to the streaming media platform, and the AI capability assessment module is notified to use the video stream of the streaming media platform to evaluate the AI capabilities of the current grouped AI model.
  • the video stream simulation module is notified and The streaming media platform releases video streams.
  • the method of driving AI model construction and evaluation by executing executable instructions is basically the same as the AI model construction and evaluation method provided by the above embodiments of the present disclosure, and will not be described again here.
  • an embodiment of the present disclosure also provides a video stream simulation method, including:
  • Step 801 The video stream simulation module receives a list of video file addresses required to evaluate the AI model of the current group;
  • Step 802 The video stream simulation module pulls the corresponding video file from the video file address list, and pushes the video stream content of the video file to the streaming media platform, notifying the controller that the streaming media environment is completed;
  • Step 803 The video stream simulation module receives the release instruction from the controller and stops pushing the video stream content
  • Step 804 The video stream simulation module sends a video stream release instruction to the streaming media platform.
  • the video stream simulation method of the embodiment of the present disclosure provides streaming services required for evaluation on demand by grouping AI models. After the model evaluation is completed, the video stream is released, and there is no need to keep all AI models at all times.
  • the video stream of the model not only solves the problem of wasting a lot of resources in the video streaming environment, but also greatly reduces the computing resources required in the DevOps environment of the AI model. It also makes the model evaluation process more controllable, improves the efficiency of AI technology research and development, and reduces costs. .
  • the video source can be a camera, and the camera pushes the stream to the streaming media platform; the AI inference platform pulls the stream from the streaming media platform, and the streaming media platform is in the middle, equivalent to a forwarding function, which is equivalent to the AI inference platform passing the stream
  • the media platform establishes a connection with the camera.
  • the video source is the video stream simulation module, which pushes streams to the streaming media platform; the AI inference platform pulls streams from the streaming media platform, the streaming media platform is in the middle, and the AI inference platform passes the streaming media platform Establish a connection with the video streaming simulation module.
  • the video files required to evaluate the AI model of each group are stored in a media file library, and the video stream simulation module pulls the corresponding video files from the media file library.
  • the video stream simulation module pushes the video stream content of the video file to the streaming media platform for cyclic provision.
  • the video stream simulation module pushes the video stream content of the video file to the streaming media platform for cyclic provision, including any of the following two situations: 1) The video stream simulation module pushes the video stream content of the video file to Cyclically pushed to the streaming media platform, so that the streaming media platform cyclically provides the video stream of the video file; 2) The video stream simulation module pushes the video stream content of the video file to the streaming media platform (only pushed once), but the streaming media platform Provides a video stream of video files in a loop.
  • Embodiments of the present disclosure also provide a video stream simulation module, including a memory; and a processor coupled to the memory, the processor being configured to execute any of the instructions of the present disclosure based on instructions stored in the memory.
  • the steps of the video stream simulation method according to an embodiment.
  • the video stream simulation module may include: a second processor, a second memory, and a second bus system, wherein the second processor and the second memory are connected through the second bus system, and the second memory is used to store instructions.
  • the second processor is used to execute instructions stored in the second memory.
  • the second processor receives the video file address list required to evaluate the AI model of the current group, pulls the corresponding video file from the video file address list, and pushes the video stream content of the video file to the streaming media platform, notifying The construction of the controller streaming media environment is completed; it receives the release instruction of the controller, stops pushing the video stream content, and sends the video stream release instruction to the streaming media platform.
  • the second processor can be a central processing unit (Central Processing Unit, CPU).
  • the second processor can also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASICs), off-the-shelf programmable processors, etc.
  • DSP digital signal processor
  • ASICs application-specific integrated circuits
  • FPGA Gate array
  • a general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc.
  • the second memory may include read-only memory and random access memory and provide instructions and data to the second processor.
  • a portion of the second memory may also include non-volatile random access memory.
  • the second memory may also store device type information.
  • the second bus system may also include a power bus, a control bus, a status signal bus, etc.
  • the processing performed by the processing device may be completed by instructions in the form of hardware integrated logic circuits or software in the second processor. That is to say, the method steps of the embodiments of the present disclosure may be implemented by a hardware processor, or may be executed by a combination of hardware and software modules in the processor.
  • Software modules can be located in random access memory, flash memory, read-only memory, programmable read-only memory or electrically erasable programmable memory, registers and other storage media.
  • the storage medium is located in the second memory, and the second processor reads the information in the second memory and completes the steps of the above method in combination with its hardware. To avoid repetition, it will not be described in detail here.
  • An embodiment of the present disclosure also provides a storage medium on which a computer program is stored.
  • the video stream simulation method as described in any embodiment of the present disclosure is implemented.
  • the video stream simulation method can receive a video file address list required to evaluate the current grouped AI model, pull the corresponding video file from the video file address list, and push the video stream content of the video file to the streaming media platform, Notify the controller that the construction of the streaming media environment is completed; receive the release instruction from the controller, stop pushing the video stream content, and send the video stream release instruction to the streaming media platform. There is no need to maintain the video streams of all AI models at all times.
  • the method of driving video stream simulation by executing executable instructions is basically the same as the video stream simulation method provided by the above embodiments of the present disclosure, and will not be described again here.
  • computer storage media includes volatile and nonvolatile media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. removable, removable and non-removable media.
  • Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, Digital Versatile Disk (DVD) or other optical disk storage, magnetic cassettes, tapes, disk storage or other magnetic storage devices, or may Any other medium used to store the desired information and that can be accessed by a computer.
  • communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media .

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Business, Economics & Management (AREA)
  • Quality & Reliability (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Computer Hardware Design (AREA)
  • Strategic Management (AREA)
  • Economics (AREA)
  • Human Resources & Organizations (AREA)
  • Marketing (AREA)
  • Game Theory and Decision Science (AREA)
  • Educational Administration (AREA)
  • Development Economics (AREA)
  • Software Systems (AREA)
  • Operations Research (AREA)
  • Tourism & Hospitality (AREA)
  • General Business, Economics & Management (AREA)
  • Debugging And Monitoring (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Monitoring And Testing Of Transmission In General (AREA)

Abstract

An AI model establishment evaluation system, comprising: a controller (11) and a simulation evaluation module (12). The controller (11) is configured to determine grouping information of an AI model; executing the following operations on an AI model of each group according to the grouping sequence: establishing an AI model of a current group to a testing environment, and sending a first notification to the simulation evaluation module (12). The simulation evaluation module (12) is configured to receive the first notification from the controller (11) and provide a video stream service to the AI model, the content of the video stream service being video stream content of a video file required for evaluating the AI model of the current group; performing AI capability evaluation on the AI model of the current group; and releasing a video stream once capability evaluation is completed.

Description

AI模型构建评估系统、视频流模拟模块与方法、控制器AI model construction and evaluation system, video stream simulation module and method, controller 技术领域Technical field
本公开实施例涉及但不限于智能系统技术领域,尤其涉及一种AI模型构建评估系统、视频流模拟模块与方法、控制器。Embodiments of the present disclosure relate to, but are not limited to, the technical field of intelligent systems, and in particular, to an AI model construction and evaluation system, a video stream simulation module and method, and a controller.
背景技术Background technique
基于视频处理的计算机视觉人工智能(Artificial Intelligence,AI)技术,需要大量的图形处理器(Graphics Processing Unit,GPU)资源进行处理。基于Triton的动态模型调用框架(Triton是英伟达(NVIDIA)公司发布的一款开源软件),将AI模型根据需要动态的进行编排与处理,以达到节约物理资源的目的。但是,在开发过程中,每个模型的更新都可能涉及到多个AI功能的精度变化,为了更快捷且更低成本的解决此种AI模型之间的依赖关系,需要引入基于DevOps(Development&Operations,开发运维一体化)全套模型打包、部署、测试、上线的过程,对于变化的模型进行全方位的自动化的评估,从而确定每个模型的更新达到的效果是正面效果还是负面效果。Computer vision artificial intelligence (Artificial Intelligence, AI) technology based on video processing requires a large amount of graphics processor (Graphics Processing Unit, GPU) resources for processing. Based on the dynamic model calling framework of Triton (Triton is an open source software released by NVIDIA), the AI model is dynamically arranged and processed as needed to achieve the purpose of saving physical resources. However, during the development process, each model update may involve changes in the accuracy of multiple AI functions. In order to resolve the dependencies between such AI models more quickly and at a lower cost, it is necessary to introduce DevOps (Development & Operations, Integration of development and operation) The process of packaging, deploying, testing and launching a full set of models, and conducting a comprehensive and automated assessment of the changed models to determine whether the effect of each model update is positive or negative.
发明内容Contents of the invention
以下是对本文详细描述的主题的概述。本概述并非是为了限制权利要求的保护范围。The following is an overview of the topics described in detail in this article. This summary is not intended to limit the scope of the claims.
本公开实施例提供了一种AI模型构建评估系统,包括:控制器和模拟测评模块,其中:The embodiment of the present disclosure provides an AI model construction and evaluation system, including: a controller and a simulation evaluation module, wherein:
所述控制器,被配置为确定AI模型的分组信息;按照分组顺序,对每一分组的AI模型,执行如下操作:构建当前分组的AI模型至测试环境,发送第一通知至模拟测评模块;The controller is configured to determine the grouping information of the AI model; according to the grouping order, perform the following operations for the AI model of each group: construct the AI model of the current group to the test environment, and send the first notification to the simulation evaluation module;
所述模拟测评模块,被配置为接收到控制器的第一通知,向所述AI模型提供视频流服务,所述视频流服务的内容为评估当前分组的AI模型所需的视频文件的视频流内容;对当前分组的AI模型进行AI能力评估;待能力 评估完成后,释放所述视频流。The simulation evaluation module is configured to receive a first notification from the controller and provide a video streaming service to the AI model. The content of the video streaming service is a video stream of video files required to evaluate the AI model of the current group. Content; perform AI capability assessment on the currently grouped AI model; release the video stream after the capability assessment is completed.
本公开实施例还提供了一种AI模型构建评估方法,包括:The embodiment of the present disclosure also provides an AI model construction and evaluation method, including:
控制器确定模型分组信息;The controller determines model grouping information;
按照分组顺序,对每一分组的AI模型,执行如下操作:According to the grouping order, perform the following operations on the AI model of each group:
所述控制器构建当前分组的AI模型至测试环境,发送第一通知至模拟测评模块;The controller constructs the AI model of the current group to the test environment, and sends the first notification to the simulation evaluation module;
所述模拟测评模块接收到所述控制器的第一通知,向所述AI模型提供视频流服务,所述视频流服务的内容为评估当前分组的AI模型所需的视频文件的视频流内容;对当前分组的AI模型进行AI能力评估;待能力评估完成后,释放所述视频流。The simulation evaluation module receives the first notification from the controller and provides a video streaming service to the AI model. The content of the video streaming service is the video streaming content of the video file required to evaluate the AI model of the current group; Perform an AI capability assessment on the currently grouped AI model; after the capability assessment is completed, release the video stream.
本公开实施例还提供了一种AI模型构建评估方法,包括:The embodiment of the present disclosure also provides an AI model construction and evaluation method, including:
控制器确定模型分组信息;The controller determines model grouping information;
控制器按照分组顺序,对每一分组的AI模型,执行如下操作:构建当前分组的AI模型至测试环境,通知视频流模拟模块将评估当前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台,通知AI能力评估模块使用所述流媒体平台的视频流对当前分组的AI模型进行AI能力评估,待能力评估完成后,通知视频流模拟模块与流媒体平台释放所述视频流。The controller performs the following operations on the AI model of each group in accordance with the grouping order: builds the AI model of the current group to the test environment, and notifies the video stream simulation module to push the video stream content of the video file required to evaluate the AI model of the current group. To the streaming media platform, notify the AI capability evaluation module to use the video stream of the streaming media platform to evaluate the AI capabilities of the current grouped AI model. After the capability assessment is completed, notify the video stream simulation module and the streaming media platform to release the video stream. .
本公开实施例还提供了一种控制器,包括存储器;和耦接至所述存储器的处理器,所述处理器被配置为基于存储在所述存储器中的指令,执行如本公开任一实施例所述的AI模型构建评估方法的步骤。An embodiment of the present disclosure also provides a controller, including a memory; and a processor coupled to the memory, the processor being configured to execute any implementation of the present disclosure based on instructions stored in the memory. The steps of the AI model construction and evaluation method described in the example.
本公开实施例还提供了一种存储介质,其上存储有计算机程序,该程序被处理器执行时实现如本公开任一实施例所述的AI模型构建评估方法。Embodiments of the present disclosure also provide a storage medium on which a computer program is stored. When the program is executed by a processor, the AI model construction and evaluation method described in any embodiment of the present disclosure is implemented.
本公开实施例还提供了一种视频流模拟方法,包括:Embodiments of the present disclosure also provide a video stream simulation method, including:
视频流模拟模块从所述视频文件地址列表拉取相应的视频文件,并推送所述视频文件的视频流内容至流媒体平台,通知控制器流媒体环境构建完成;The video stream simulation module pulls the corresponding video file from the video file address list, pushes the video stream content of the video file to the streaming media platform, and notifies the controller that the streaming media environment is completed;
视频流模拟模块接收所述控制器的释放指令,停止推送所述视频流内容;The video stream simulation module receives the release instruction of the controller and stops pushing the video stream content;
视频流模拟模块向所述流媒体平台发送视频流释放指令。The video stream simulation module sends a video stream release instruction to the streaming media platform.
本公开实施例还提供了一种视频流模拟模块,包括存储器;和耦接至所述存储器的处理器,所述处理器被配置为基于存储在所述存储器中的指令,执行如本公开任一实施例所述的视频流模拟方法的步骤。Embodiments of the present disclosure also provide a video stream simulation module, including a memory; and a processor coupled to the memory, the processor being configured to execute any of the instructions of the present disclosure based on instructions stored in the memory. The steps of the video stream simulation method according to an embodiment.
本公开实施例还提供了一种存储介质,其上存储有计算机程序,该程序被处理器执行时实现如本公开任一实施例所述的视频流模拟方法。An embodiment of the present disclosure also provides a storage medium on which a computer program is stored. When the program is executed by a processor, the video stream simulation method as described in any embodiment of the present disclosure is implemented.
在阅读理解了附图和详细描述后,可以明白其他方面。After reading and understanding the drawings and detailed description, other aspects can be understood.
附图说明Description of drawings
附图用来提供对本公开技术方案的进一步理解,并且构成说明书的一部分,与本公开的实施例一起用于解释本公开的技术方案,并不构成对本公开的技术方案的限制。附图中各部件的形状和大小不反映真实比例,目的只是示意说明本公开内容。The drawings are used to provide a further understanding of the technical solution of the present disclosure, and constitute a part of the specification. They are used to explain the technical solution of the present disclosure together with the embodiments of the present disclosure, and do not constitute a limitation of the technical solution of the present disclosure. The shapes and sizes of components in the drawings do not reflect true proportions and are intended only to illustrate the present disclosure.
图1A、图1B和图1C为本公开示例性实施例三种AI模型构建评估系统的结构示意图;Figures 1A, 1B and 1C are schematic structural diagrams of three AI model construction and evaluation systems according to exemplary embodiments of the present disclosure;
图2A为本公开示例性实施例另一种AI模型构建评估系统的结构示意图;Figure 2A is a schematic structural diagram of another AI model construction and evaluation system according to an exemplary embodiment of the present disclosure;
图2B为本公开示例性实施例一种AI模型的测试案例与所需视频流示意图;Figure 2B is a schematic diagram of a test case and required video stream of an AI model according to an exemplary embodiment of the present disclosure;
图2C和图2D为示例性的对图2B所示的测试案例进行分组测试的两种方法示意图;Figures 2C and 2D are schematic diagrams of two exemplary methods for group testing the test cases shown in Figure 2B;
图2E为本公开示例性实施例另一种AI模型的测试案例与所需视频流示意图;Figure 2E is a schematic diagram of a test case and required video stream of another AI model according to an exemplary embodiment of the present disclosure;
图2F为示例性的对图2E所示的测试案例进行分组测试的方法示意图;Figure 2F is a schematic diagram of an exemplary method for group testing the test cases shown in Figure 2E;
图3为本公开示例性实施例一种分组模拟所需视频流的方法示意图;Figure 3 is a schematic diagram of a method for grouping video streams required for simulation according to an exemplary embodiment of the present disclosure;
图4为本公开示例性实施例一种DevOps任务发起过程示意图;Figure 4 is a schematic diagram of a DevOps task initiation process according to an exemplary embodiment of the present disclosure;
图5为本公开示例性实施例一种视频环境构建过程示意图;Figure 5 is a schematic diagram of a video environment construction process according to an exemplary embodiment of the present disclosure;
图6为本公开示例性实施例一种AI模型构建评估方法的流程示意图;Figure 6 is a schematic flowchart of an AI model construction and evaluation method according to an exemplary embodiment of the present disclosure;
图7为本公开示例性实施例另一种AI模型构建评估方法的流程示意图;Figure 7 is a schematic flowchart of another AI model construction and evaluation method according to an exemplary embodiment of the present disclosure;
图8为本公开示例性实施例一种视频流模拟方法的流程示意图。Figure 8 is a schematic flowchart of a video stream simulation method according to an exemplary embodiment of the present disclosure.
具体实施方式Detailed ways
为使本公开的目的、技术方案和优点更加清楚明白,下文中将结合附图对本公开的实施例进行详细说明。需要说明的是,在不冲突的情况下,本公开中的实施例及实施例中的特征可以相互任意组合。In order to make the purpose, technical solutions and advantages of the present disclosure more clear, the embodiments of the present disclosure will be described in detail below with reference to the accompanying drawings. It should be noted that, as long as there is no conflict, the embodiments and features in the embodiments can be arbitrarily combined with each other.
除非另外定义,本公开实施例公开使用的技术术语或者科学术语应当为本公开所属领域内具有一般技能的人士所理解的通常意义。本公开实施例中使用的“第一”、“第二”以及类似的词语并不表示任何顺序、数量或者重要性,而只是用来区分不同的组成部分。“包括”或者“包含”等类似的词语意指出该词前面的元件或物件涵盖出现在该词后面列举的元件或者物件及其等同,而不排除其他元件或者物件。Unless otherwise defined, the technical terms or scientific terms used in the disclosure of the embodiments of the present disclosure shall have the usual meanings understood by those with ordinary skill in the art to which the disclosure belongs. The "first", "second" and similar words used in the embodiments of the present disclosure do not indicate any order, quantity or importance, but are only used to distinguish different components. Words such as "include" or "include" mean that the elements or things preceding the word include the elements or things listed after the word and their equivalents, without excluding other elements or things.
如果可以加速代码变更、模型重构、模型评估和模型上线这个过程的循环频率,相当于加速了整个AI模型与策略的成熟过程,提升了研发效率。当同时维护的模型与AI策略达到数量比较大的情况下,整套AI模型与策略所依赖的视频流也就达到了几百个的规模,如果始终保持这么多视频流的环境存在,需要消耗大量的中央处理器(Central Processing Unit,CPU)资源,同时对于基于视频业务的AI能力评估也带来难度。If the cycle frequency of code changes, model reconstruction, model evaluation, and model launch can be accelerated, it will be equivalent to accelerating the maturity process of the entire AI model and strategy and improving research and development efficiency. When a large number of models and AI strategies are maintained at the same time, the number of video streams that the entire set of AI models and strategies rely on reaches a scale of several hundred. If an environment with so many video streams is always maintained, it will consume a lot of money. The central processing unit (Central Processing Unit, CPU) resources also bring difficulties to the evaluation of AI capabilities based on video services.
如图1A所示,本公开实施例提供了一种AI模型构建评估系统,包括:控制器11和模拟测评模块12,其中:As shown in Figure 1A, the embodiment of the present disclosure provides an AI model construction and evaluation system, including: a controller 11 and a simulation evaluation module 12, wherein:
控制器11,被配置为确定AI模型的分组信息;按照分组顺序,对每一分组的AI模型,执行如下操作:构建当前分组的AI模型至测试环境,发送第一通知至模拟测评模块12(第一通知的作用是告知模拟测评模块12当前分组的AI模型已构建至测试环境);The controller 11 is configured to determine the grouping information of the AI model; according to the grouping order, perform the following operations for the AI model of each group: construct the AI model of the current group to the test environment, and send the first notification to the simulation evaluation module 12 ( The function of the first notification is to inform the simulation evaluation module 12 that the AI model of the current group has been built into the test environment);
模拟测评模块12,被配置为接收到控制器11的第一通知,向所述AI模型提供视频流服务,所述视频流服务的内容为评估当前分组的AI模型所需的视频文件的视频流内容;对当前分组的AI模型进行AI能力评估;待能 力评估完成后,释放所述视频流。The simulation evaluation module 12 is configured to receive the first notification from the controller 11 and provide a video streaming service to the AI model. The content of the video streaming service is a video stream of video files required to evaluate the AI model of the current group. Content; perform AI capability assessment on the currently grouped AI model; release the video stream after the capability assessment is completed.
本公开实施例的AI模型构建评估系统,通过对AI模型进行分组,依次构建每组的AI模型至测试环境,并对当前分组的AI模型按需提供评估所需的流媒体服务,在评估完成后,释放视频流,不需要始终保持所有AI模型的视频流,不但解决了视频流环境大量资源浪费的问题,使得AI模型DevOps环境所需计算资源大幅降低,同时使得模型评估过程变得更加可控,提升了AI技术研发效率,降低了成本。The AI model construction and evaluation system of the embodiment of the present disclosure groups the AI models, sequentially builds the AI models of each group to the test environment, and provides the streaming media services required for evaluation on demand for the currently grouped AI models. After the evaluation is completed Finally, the video stream is released, and there is no need to maintain the video stream of all AI models at all times. This not only solves the problem of wasting a lot of resources in the video streaming environment, but also greatly reduces the computing resources required in the DevOps environment of the AI model, and also makes the model evaluation process more feasible. Control, improve the efficiency of AI technology research and development, and reduce costs.
本公开实施例所述的AI模型,指的是能够感知、推理、行动和适应的程序,而机器学习模型一般指的是能够随着数据量的增加不断改进性能的程序,深度学习模型是机器学习模型的一个子集,深度学习模型利用多层神经网络从大量数据中进行学习的程序。因此,从涵盖范围上来讲,AI模型大于机器学习模型大于深度学习模型。The AI model described in the embodiments of the present disclosure refers to a program that can perceive, reason, act and adapt, while the machine learning model generally refers to a program that can continuously improve performance as the amount of data increases. The deep learning model is a machine A subset of learning models, deep learning models are programs that use multi-layer neural networks to learn from large amounts of data. Therefore, in terms of coverage, AI models are larger than machine learning models and are larger than deep learning models.
本公开实施例中,在对AI模型进行AI能力评估时,针对一个AI模型可以设计一个测试案例,也可以设计多个测试案例。通常来说,一个测试案例就是设计一个情况,AI模型在这种情况下,必须能够正常的运行并且达到模型设计的预期执行结果。示例性的,假设针对一个用于VIP用户检测的AI模型,为其设计的测试案例可以包括以下3个:In this disclosed embodiment, when evaluating the AI capabilities of an AI model, one test case or multiple test cases can be designed for one AI model. Generally speaking, a test case is to design a situation in which the AI model must be able to run normally and achieve the expected execution results of the model design. For example, assuming that for an AI model used for VIP user detection, the test cases designed for it can include the following three:
测试案例1)通知AI模型拉取视频流1(视频流1不包含VIP用户),检测AI模型输出结果;Test case 1) Notify the AI model to pull video stream 1 (video stream 1 does not contain VIP users), and detect the AI model output results;
测试案例2)通知AI模型拉取视频流2(视频流2包含1个VIP用户),检测AI模型输出结果;Test case 2) Notify the AI model to pull video stream 2 (video stream 2 contains 1 VIP user), and detect the AI model output result;
测试案例3)通知AI模型拉取视频流3(视频流3包含2个VIP用户),检测AI模型输出结果。Test case 3) Notifies the AI model to pull video stream 3 (video stream 3 contains 2 VIP users), and detects the AI model output result.
在测试每个测试案例时,当AI模型的输出结果与实际拉取的视频流内容匹配时,该测试案例通过;当AI模型的输出结果与实际拉取的视频流内容不匹配时,该测试案例失败。When testing each test case, when the output result of the AI model matches the actual pulled video stream content, the test case passes; when the AI model output result does not match the actual pulled video stream content, the test Case failed.
在构建测试环境时,由控制器11从代码仓库拉取AI模型的模型代码,对模型代码进行编译之后将其部署至测试环境;在进行测试时,AI模型拉取 流媒体平台或流媒体服务器的视频流,根据拉取的视频流进行相应的输出,由模拟测评模块对AI模型的输出结果进行检测,根据AI模型的输出结果判断测试案例是否通过。When building a test environment, the controller 11 pulls the model code of the AI model from the code warehouse, compiles the model code and deploys it to the test environment; when testing, the AI model pulls the streaming media platform or streaming media server The video stream is output accordingly according to the pulled video stream. The simulation evaluation module detects the output result of the AI model, and determines whether the test case passes based on the output result of the AI model.
本公开实施例中,模拟测评模块12向AI模型提供视频流服务,指的是模拟测评模块向AI模型提供一个或多个视频流控制接口(示例性的,视频流控制接口可以为视频流地址),AI模型可以通过控制不同的视频流控制接口,拉取某一视频流。当能力评估完成后,模拟测评模块12通过释放视频流控制接口释放释放流。In the embodiment of the present disclosure, the simulation evaluation module 12 provides video streaming services to the AI model, which means that the simulation evaluation module provides one or more video stream control interfaces to the AI model (exemplarily, the video stream control interface can be a video stream address ), the AI model can pull a certain video stream by controlling different video stream control interfaces. After the capability evaluation is completed, the simulation evaluation module 12 releases the release stream through the release video stream control interface.
在一些示例性实施方式中,测试环境可以包括一台或多台物理机器,该物理机器可以接收控制器11部署的AI模型,并运行AI模型。在构建测试环境时,由控制器11构建当前分组的AI模型至测试环境;在进行测试时,由模拟测评模块12向AI模型提供视频流服务,对当前分组的AI模型进行AI能力评估;待能力评估完成后,释放视频流。模拟测评模块12可以部分或全部设置在测试环境所在的物理机器上,也可以设置在测试环境以外的物理机器上,本公开实施例对此不作限制。In some exemplary embodiments, the test environment may include one or more physical machines, which may receive the AI model deployed by the controller 11 and run the AI model. When building a test environment, the controller 11 constructs the AI model of the current group to the test environment; when testing, the simulation evaluation module 12 provides video streaming services to the AI model, and evaluates the AI capabilities of the AI model of the current group; After the capability assessment is completed, release the video stream. The simulation evaluation module 12 may be partially or entirely installed on the physical machine where the test environment is located, or may be installed on a physical machine outside the test environment. This is not limited in the embodiment of the present disclosure.
在一些示例性实施方式中,如图1B所示,模拟测评模块12包括视频流模拟服务器120和AI能力评估模块121,其中:In some exemplary embodiments, as shown in Figure 1B, the simulation evaluation module 12 includes a video stream simulation server 120 and an AI capability evaluation module 121, where:
视频流模拟服务器120,被配置为接收到控制器11的第一通知,向所述AI模型提供视频流服务,所述视频流服务的内容为评估当前分组的AI模型所需的视频文件的视频流内容,发送第二通知至控制器11,以使得控制器11发送第三通知至AI能力评估模块121;接收到控制器11的第五通知,释放所述视频流;The video stream simulation server 120 is configured to receive the first notification from the controller 11 and provide a video stream service to the AI model. The content of the video stream service is the video of the video file required to evaluate the AI model of the current group. Stream content, send a second notification to the controller 11, so that the controller 11 sends a third notification to the AI capability evaluation module 121; receive the fifth notification from the controller 11, release the video stream;
AI能力评估模块121,被配置为接收到控制器11的第三通知,对当前分组的AI模型进行AI能力评估;待能力评估完成后,发送第四通知至控制器11,以使得控制器11发送第五通知至视频流模拟服务器120;The AI capability evaluation module 121 is configured to receive the third notification from the controller 11 and perform an AI capability evaluation on the AI model of the current group; after the capability evaluation is completed, send the fourth notification to the controller 11 so that the controller 11 Send the fifth notification to the video stream simulation server 120;
控制器11,还被配置为接收到所述视频流模拟服务器120的第二通知,发送第三通知至AI能力评估模块121;接收到所述AI能力评估模块121的第四通知,发送第五通知至视频流模拟服务器120。The controller 11 is further configured to receive a second notification from the video stream simulation server 120 and send a third notification to the AI capability evaluation module 121; upon receiving a fourth notification from the AI capability evaluation module 121, send a fifth notification. Notification to video stream simulation server 120.
本公开实施例中,当视频流模拟服务器120准备好视频流服务后,通知控制器11,由控制器11通知AI能力评估模块121可以开始对当前分组的AI模型进行AI能力评估,在另一些示例性实施方式中,也可以直接由视频流模拟服务器120通知AI能力评估模块121开始对当前分组的AI模型进行AI能力评估,本公开实施例对此不作限制。当AI能力评估模块121完成AI能力评估后,通知控制器11,由控制器11通知视频流模拟服务器120释放所述视频流,在另一些示例性实施方式中,也可以直接由AI能力评估模块121通知视频流模拟服务器120释放所述视频流,本公开实施例对此也不作限制。通过控制器11通知AI能力评估模块121可以开始对当前分组的AI模型进行AI能力评估以及通过控制器11通知视频流模拟服务器120释放所述视频流,可以使得控制器11能够准确把控每个AI模型评估的过程,从而使得模型评估过程变得更加可控,提升了AI技术研发效率,降低了成本。In the embodiment of the present disclosure, when the video stream simulation server 120 is ready for the video stream service, it notifies the controller 11, and the controller 11 notifies the AI capability evaluation module 121 to start AI capability evaluation of the AI model of the current group. In an exemplary embodiment, the video stream simulation server 120 may also directly notify the AI capability evaluation module 121 to start performing AI capability evaluation on the AI model of the current group, and the embodiment of the present disclosure does not limit this. After the AI capability assessment module 121 completes the AI capability assessment, it notifies the controller 11, and the controller 11 notifies the video stream simulation server 120 to release the video stream. In other exemplary embodiments, the AI capability assessment module can also directly 121 notifies the video stream simulation server 120 to release the video stream, and the embodiment of the present disclosure does not limit this. The controller 11 notifies the AI capability evaluation module 121 to start AI capability evaluation of the current grouped AI model and the controller 11 notifies the video stream simulation server 120 to release the video stream, which enables the controller 11 to accurately control each The process of AI model evaluation makes the model evaluation process more controllable, improves the efficiency of AI technology research and development, and reduces costs.
在一些示例性实施方式中,如图1C所示,视频流模拟服务器120包括视频流模拟模块1201和流媒体平台1202,其中:In some exemplary implementations, as shown in Figure 1C, the video stream simulation server 120 includes a video stream simulation module 1201 and a streaming media platform 1202, wherein:
视频流模拟模块1201,被配置为接收到控制器11的第一通知,将评估当前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台1202,发送第二通知至控制器11;接收到控制器11的第五通知,停止推送视频流内容,并发送第六通知至流媒体平台1202;The video stream simulation module 1201 is configured to receive the first notification from the controller 11, push the video stream content of the video file required to evaluate the AI model of the current group to the streaming media platform 1202, and send the second notification to the controller 11 ; Receive the fifth notification from the controller 11, stop pushing the video stream content, and send the sixth notification to the streaming media platform 1202;
流媒体平台1202,被配置为接收视频流模拟模块1201推送的视频流内容,并向AI模型提供视频流服务;接收到视频流模拟模块1201的第六通知,释放视频流。The streaming media platform 1202 is configured to receive the video stream content pushed by the video stream simulation module 1201 and provide video streaming services to the AI model; upon receiving the sixth notification from the video stream simulation module 1201, release the video stream.
本实施例中,在构建测试环境时,由控制器11构建当前分组的AI模型至测试环境;在进行测试时,由视频流模拟模块1201将评估当前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台1202,由流媒体平台1202向测试环境中的AI模型提供视频流服务,由AI能力评估模块121通知AI模型拉取流媒体平台1202的视频流,并对AI模型的输出结果进行检测,根据AI模型的输出结果判断测试案例是否通过。In this embodiment, when building the test environment, the controller 11 builds the AI model of the current group into the test environment; when performing the test, the video stream simulation module 1201 adds the video of the video file required to evaluate the AI model of the current group. The streaming content is pushed to the streaming media platform 1202, and the streaming media platform 1202 provides video streaming services to the AI model in the test environment. The AI capability evaluation module 121 notifies the AI model to pull the video stream of the streaming media platform 1202, and evaluates the AI model's The output results are tested, and whether the test case passes is judged based on the output results of the AI model.
在一些示例性实施方式中,如图1C所示,本公开实施例提供了一种AI模型构建评估系统,包括:控制器11、视频流模拟模块1201、流媒体平台 1202和AI能力评估模块121,其中:In some exemplary implementations, as shown in Figure 1C, embodiments of the present disclosure provide an AI model construction evaluation system, including: a controller 11, a video stream simulation module 1201, a streaming media platform 1202, and an AI capability evaluation module 121 ,in:
控制器11,被配置为确定模型分组信息;按照分组顺序,对每一分组的AI模型,执行如下操作:构建当前分组的AI模型至测试环境,发送第一通知至视频流模拟模块1201;接收到视频流模拟模块1201的第二通知,发送第三通知至AI能力评估模块121;接收到AI能力评估模块121的第四通知,发送第五通知至视频流模拟模块1201;The controller 11 is configured to determine the model grouping information; according to the grouping order, perform the following operations for the AI model of each group: build the AI model of the current group to the test environment, send the first notification to the video stream simulation module 1201; receive The second notification is sent to the video stream simulation module 1201, and the third notification is sent to the AI capability evaluation module 121; the fourth notification is received from the AI capability evaluation module 121, and the fifth notification is sent to the video stream simulation module 1201;
视频流模拟模块1201,被配置为接收到控制器11的第一通知,将评估当前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台1202,发送第二通知至控制器11;接收到控制器11的第五通知,停止推送视频流内容,并发送第六通知至流媒体平台1202;The video stream simulation module 1201 is configured to receive the first notification from the controller 11, push the video stream content of the video file required to evaluate the AI model of the current group to the streaming media platform 1202, and send the second notification to the controller 11 ; Receive the fifth notification from the controller 11, stop pushing the video stream content, and send the sixth notification to the streaming media platform 1202;
AI能力评估模块121,被配置为接收到控制器11的第三通知,使用视频流对当前分组的AI模型进行AI能力评估,待能力评估完成后,发送第四通知至控制器11;The AI capability assessment module 121 is configured to receive the third notification from the controller 11, use the video stream to perform an AI capability assessment on the AI model of the current group, and after the capability assessment is completed, send the fourth notification to the controller 11;
流媒体平台1202,被配置为接收视频流模拟模块1201推送的视频流内容,并向AI模型提供视频流服务;接收到视频流模拟模块1201的第六通知,释放视频流。The streaming media platform 1202 is configured to receive the video stream content pushed by the video stream simulation module 1201 and provide video streaming services to the AI model; upon receiving the sixth notification from the video stream simulation module 1201, release the video stream.
通常,AI模型的DevOps流水线包括如下过程:首先,由研发人员进行AI模型的代码开发→编译+部署AI模型代码到测试环境(本步骤统称为构建过程,可通过自动化实现)→测试+结果分析(本步骤统称为评估过程,可通过自动化实现)→经过反复调试与缺陷修改,测试OK后,上线至生产平台。由于AI模型的调试与缺陷修改,需要将构建、评估与缺陷修改过程进行多次循环,清理完所有的缺陷后才可以进入上线流程。每个AI模型的构建脚本通常是由研发人员完成,评估过程主要是由测试人员来主导,上线过程主要由运维人员来主导。Usually, the DevOps pipeline of AI models includes the following process: First, R&D personnel develop the code of the AI model → compile + deploy the AI model code to the test environment (this step is collectively referred to as the build process and can be realized through automation) → test + result analysis (This step is collectively called the evaluation process and can be realized through automation) → After repeated debugging and defect modification, after the test is OK, it will be launched on the production platform. Due to the debugging and defect modification of the AI model, it is necessary to cycle through the construction, evaluation and defect modification processes multiple times. Only after all defects have been cleared can the launch process be entered. The construction script of each AI model is usually completed by R&D personnel, the evaluation process is mainly led by testers, and the online process is mainly led by operation and maintenance personnel.
本公开实施例中,视频流模拟模块1201和AI能力评估模块121实际的物理位置可以位于任意的位置,只要与控制器11、流媒体平台1202通过网络相连接即可。示例性的,视频流模拟模块1201可以位于控制器11所在的物理机器上,也可以位于流媒体平台1202所在的物理机器上,或者,也可以位于控制器11或流媒体平台1202以外的物理机器上。示例性的,AI能力评 估模块121可以位于测试环境所在的物理机器上,在构建测试环境时,可以从代码仓库拉取AI能力评估模块121对应的代码与AI模型对应的模型代码,然后编译后一起部署至测试环境,AI能力评估模块121对应的代码可以包括运行自动化测试所需的脚本代码,针对不同的AI模型运行预先设定的测试案例,以进行特定的能力评估。示例性的,各个测试案例可以指定拉取的视频流地址,运行各个测试案例时,AI能力评估模块121通知AI模型拉取指定视频流地址的视频流,AI模型将指定视频流地址的视频流作为输入并进行相应的输出,AI能力评估模块判断AI模型的输出结果与实际拉取的视频流内容是否匹配,进行判断各个测试案例是否测试通过。当AI能力评估模块121和AI模型均部署于测试环境所在的物理机器时,可以减少构建整个AI模型构建评估系统所需的物理资源,提高系统资源利用率,减小系统复杂度,减少AI能力评估模块121与其他模块之间的网络通信数据。在另外一些示例中,AI能力评估模块121也可以位于测试环境以外的物理机器上。In the embodiment of the present disclosure, the actual physical locations of the video stream simulation module 1201 and the AI capability evaluation module 121 can be located at any location, as long as they are connected to the controller 11 and the streaming media platform 1202 through the network. For example, the video stream simulation module 1201 can be located on the physical machine where the controller 11 is located, or on the physical machine where the streaming media platform 1202 is located, or it can be located on a physical machine other than the controller 11 or the streaming media platform 1202 superior. For example, the AI capability assessment module 121 can be located on the physical machine where the test environment is located. When building the test environment, the code corresponding to the AI capability assessment module 121 and the model code corresponding to the AI model can be pulled from the code warehouse, and then compiled. Deployed together to the test environment, the code corresponding to the AI capability assessment module 121 may include script code required to run automated tests, and run preset test cases for different AI models to conduct specific capability assessments. For example, each test case can specify the pulled video stream address. When running each test case, the AI capability evaluation module 121 notifies the AI model to pull the video stream of the specified video stream address, and the AI model will pull the video stream of the specified video stream address. As input and corresponding output, the AI capability evaluation module determines whether the output results of the AI model match the actual pulled video stream content, and determines whether each test case passes the test. When both the AI capability evaluation module 121 and the AI model are deployed on the physical machine where the test environment is located, the physical resources required to build the entire AI model construction and evaluation system can be reduced, system resource utilization can be improved, system complexity can be reduced, and AI capabilities can be reduced Evaluate network communication data between module 121 and other modules. In other examples, the AI capability evaluation module 121 may also be located on a physical machine outside the test environment.
本公开实施例中,流媒体平台1202可以为流媒体服务器,在流媒体平台1202提供视频流服务时,可以由视频流模拟模块1201指定每个视频流对应的推流地址,当释放视频流后,该推流地址停止提供对应的视频流服务。In this disclosed embodiment, the streaming media platform 1202 can be a streaming media server. When the streaming media platform 1202 provides video streaming services, the video stream simulation module 1201 can specify the push address corresponding to each video stream. After the video stream is released , the push address stops providing the corresponding video streaming service.
在一些示例性实施方式中,如图2A所示,该AI模型构建评估系统还包括代码仓库105,其中,代码仓库105被配置为存储AI模型的代码信息、模型的分组信息、模型的构建脚本、组织AI模型运行的策略代码等。In some exemplary embodiments, as shown in FIG. 2A , the AI model construction evaluation system also includes a code warehouse 105 , where the code warehouse 105 is configured to store the code information of the AI model, the grouping information of the model, and the construction script of the model. , the strategy code that organizes the operation of the AI model, etc.
示例性的,该代码仓库105可以为GIT代码仓库。GIT是一个开源的分布式版本控制系统,用于敏捷高效地处理任何或小或大的项目。代码仓库105也可以是其他类型的代码仓库,如SVN(Subversion)等,本公开实施例对此不作限制。每个AI模型在代码仓库可以对应一个工程。For example, the code repository 105 may be a GIT code repository. GIT is an open source distributed version control system for agile and efficient handling of any project, small or large. The code repository 105 can also be other types of code repositories, such as SVN (Subversion), etc., and the embodiment of the present disclosure does not limit this. Each AI model can correspond to a project in the code warehouse.
图2A中AI能力评估模块位于测试环境所在的物理机器上,测试环境所在的物理机器部署有AI模型,AI模型需要拉取流媒体平台的视频流,即相当于AI能力评估模块所在的物理机器需要拉取流媒体平台的视频流,因此,图2A中的AI能力评估模块和流媒体平台之间有连接关系。在其他一些示例性实施方式中,如图1C所示,AI能力评估模块也可以位于测试环境所在的物理机器以外的物理机器上,此时,图1C中的AI能力评估模块和流媒体平 台之间无连接关系。In Figure 2A, the AI capability evaluation module is located on the physical machine where the test environment is located. The physical machine where the test environment is located is deployed with an AI model. The AI model needs to pull the video stream of the streaming media platform, which is equivalent to the physical machine where the AI capability assessment module is located. The video stream of the streaming media platform needs to be pulled. Therefore, there is a connection relationship between the AI capability evaluation module in Figure 2A and the streaming media platform. In some other exemplary implementations, as shown in Figure 1C, the AI capability evaluation module can also be located on a physical machine other than the physical machine where the test environment is located. In this case, between the AI capability evaluation module in Figure 1C and the streaming media platform There is no connection between them.
在一些示例性实施方式中,构建当前分组的AI模型至测试环境,包括:In some exemplary implementations, building the AI model of the current group to the test environment includes:
拉取当前分组的AI模型的模型代码;Pull the model code of the currently grouped AI model;
编译当前分组的AI模型的模型代码;Compile the model code of the currently grouped AI model;
部署当前分组的AI模型至测试环境。Deploy the AI model of the current group to the test environment.
在一些示例性实施方式中,每当研发人员提交模型代码至代码仓库105时,代码仓库105可以自动触发控制器11进行构建评估过程。控制器11构建当前分组的AI模型至测试环境时,控制器11拉取当前分组的AI模型的模型代码(可以拉取至控制器11所在的物理机器上),控制器11(在控制器11所在的物理机器上)编译当前分组的AI模型的模型代码,最后控制器11部署当前分组的AI模型至测试环境。In some exemplary embodiments, whenever a developer submits model code to the code repository 105, the code repository 105 can automatically trigger the controller 11 to perform a build evaluation process. When the controller 11 builds the AI model of the current group to the test environment, the controller 11 pulls the model code of the AI model of the current group (which can be pulled to the physical machine where the controller 11 is located). The controller 11 (in the controller 11 (on the physical machine where it is located) compiles the model code of the AI model of the current group, and finally the controller 11 deploys the AI model of the current group to the test environment.
在另外一些示例性实施方式中,可以将当前分组的AI模型编译之后的模型代码存储至代码仓库,当当前分组的AI模型没有更新时,构建当前分组的AI模型至测试环境,包括:拉取当前分组的AI模型编译之后的模型代码;部署当前分组的AI模型至测试环境。In some other exemplary implementations, the model code after compiling the AI model of the current group can be stored in the code warehouse. When the AI model of the current group is not updated, building the AI model of the current group to the test environment includes: pulling The model code after compiling the AI model of the current group; deploy the AI model of the current group to the test environment.
在另一些示例性实施方式中,控制器11每日定时启动统一的构建评估过程。In other exemplary embodiments, the controller 11 starts a unified build evaluation process at regular intervals every day.
假设一个上百人研发团队,开发几十乃至上百个AI模型,每个模型对应一个开发组,那么,控制器11针对几十甚至上百个模型每日定时启动统一构建与评估过程,从而使得模型评估过程变得更加可控,提升了AI技术研发效率。Assume that a R&D team of hundreds of people develops dozens or even hundreds of AI models, and each model corresponds to a development group. Then, the controller 11 regularly starts the unified construction and evaluation process for dozens or even hundreds of models every day, so that The model evaluation process becomes more controllable, improving the efficiency of AI technology research and development.
在一些示例性实施方式中,控制器11还被配置为,将多个AI模型的构建脚本进行整理合并后推送至任务队列。In some exemplary embodiments, the controller 11 is further configured to organize and merge the construction scripts of multiple AI models and then push them to the task queue.
本实施例中,控制器11需要维护一个任务队列,该任务队列可以包括:AI模型的分组信息、AI模型分组的部署顺序,从而可以通过任务队列实现以下两种维度的控制:1、怎么对AI模型进行分组;2、分组之后的部署顺序(即先部署哪一批AI模型,再部署哪一批AI模型)。In this embodiment, the controller 11 needs to maintain a task queue, which can include: grouping information of the AI model and the deployment order of the AI model grouping, so that the following two dimensions of control can be achieved through the task queue: 1. How to Group AI models; 2. Deployment order after grouping (that is, which batch of AI models to deploy first, and which batch of AI models to deploy next).
在一些示例性中,任务队列还包括:每个AI模型的顺序DevOps过程。 每个AI模型的顺序DevOps过程包括从编译→部署→测试→结果分析的过程。In some examples, the task queue also includes: sequential DevOps process for each AI model. The sequential DevOps process of each AI model includes the process from compilation→deployment→testing→result analysis.
在一些示例性实施方式中,推送到任务队列的构建脚本可以由专门的分组人员进行分组,此时,分组人员可以将分组代码存储于代码仓库105中,控制器11拉取分组代码,取得分组信息。In some exemplary implementations, the build scripts pushed to the task queue can be grouped by specialized grouping personnel. At this time, the grouping personnel can store the grouping code in the code warehouse 105, and the controller 11 pulls the grouping code and obtains the grouping. information.
在另一些示例性实施方式中,推送到任务队列的构建脚本可以由控制器11进行分组。In other exemplary embodiments, build scripts pushed to the task queue may be grouped by controller 11 .
在一些示例性实施方式中,控制器11确定模型分组信息,包括:In some exemplary embodiments, the controller 11 determines model grouping information, including:
获取待构建的多个AI模型的构建脚本;Obtain the construction scripts of multiple AI models to be built;
根据每个AI模型所消耗的资源对所述待构建的多个AI模型进行分组,每组AI模型所消耗的资源小于测试环境所具备的资源。The multiple AI models to be built are grouped according to the resources consumed by each AI model, and the resources consumed by each group of AI models are less than the resources of the test environment.
本公开实施例的AI模型构建评估系统,借助Triton推理框架,可在单个GPU上同时运行多个AI模型,以更大限度地提高利用率,并可与Kubernetes集成以用于编排、指标和自动扩展。可选的,单个GPU可以是测试环境所在的物理机器上的GPU。The AI model construction and evaluation system of the disclosed embodiment, with the help of the Triton inference framework, can run multiple AI models simultaneously on a single GPU to maximize utilization, and can be integrated with Kubernetes for orchestration, indicators and automation. Extension. Optionally, a single GPU can be a GPU on the physical machine where the test environment is located.
本公开实施例中,根据每个AI模型所消耗的资源对所述待构建的多个AI模型进行分组,此处资源可以为硬件资源(如推理卡资源大小等),也可以为软件资源(例如,线程数等)。示例性的,该资源可以为硬件资源,根据每个AI模型所消耗的硬件资源对所述待构建的多个AI模型进行分组,由于硬件资源的读取较为容易方便,增强了模型分组的可执行。In the embodiment of the present disclosure, the multiple AI models to be built are grouped according to the resources consumed by each AI model. The resources here can be hardware resources (such as inference card resource size, etc.) or software resources ( For example, number of threads, etc.). For example, the resource can be a hardware resource. The multiple AI models to be built are grouped according to the hardware resources consumed by each AI model. Since the hardware resources are easier and more convenient to read, the feasibility of model grouping is enhanced. implement.
示例性的,假设在一个系统(可选的,该系统可以为测试环境)上部署了10个AI模型,该系统的推理卡资源大小为16G,那么,这10个AI模型总体占用的推理卡资源大小应该小于16G。在一些示例性实施例中,推理卡可以为显卡,即显卡可以用于推理。在另一些示例性实施例中,推理卡可以为非显卡,即推理卡也可以不具备显示功能。本公开实施例通过对AI模型进行分组,对测试环境的硬件资源的要求降低,假设有100个AI模型需要测试,如果不对AI模型进行分组,那么测试环境需要同时部署100个AI模型,对测试环境的硬件资源要求较高;如果将该100个AI模型分成10组,每组10个AI模型,那么测试环境只需要每组同时部署10个AI模型,轮流 部署10组,降低了测试环境的硬件资源要求。For example, assuming that 10 AI models are deployed on a system (optional, the system can be a test environment), and the inference card resource size of the system is 16G, then the total inference card occupied by these 10 AI models Resource size should be less than 16G. In some exemplary embodiments, the inference card may be a graphics card, that is, the graphics card may be used for inference. In other exemplary embodiments, the inference card may be a non-graphics card, that is, the inference card may not have a display function. By grouping AI models, the embodiments of this disclosure reduce the requirements on hardware resources of the test environment. Assume that there are 100 AI models that need to be tested. If the AI models are not grouped, then the test environment needs to deploy 100 AI models at the same time. The hardware resource requirements of the environment are relatively high; if the 100 AI models are divided into 10 groups, each group has 10 AI models, then the test environment only needs to deploy 10 AI models in each group at the same time, and deploy 10 groups in turn, which reduces the load of the test environment. Hardware resource requirements.
在一些示例性实施方式中,控制器11确定模型分组信息,还包括:In some exemplary embodiments, the controller 11 determines model grouping information, further including:
根据不同AI模型之间的关系对所述待构建的多个AI模型进行分组,有依赖关系的AI模型分为一组。The multiple AI models to be built are grouped according to the relationship between different AI models, and the AI models with dependencies are grouped into one group.
仍以每组10个AI模型为例,这10个AI模型中,可能有部分模型之间或全部模型之间存在业务依赖性,也可能全部模型之间不存在业务依赖性,但是,有业务依赖性的AI模型应该分为一组。Still taking each group of 10 AI models as an example, among these 10 AI models, there may be business dependencies between some or all models, or there may be no business dependencies between all models, but there are business dependencies. Sexual AI models should be grouped into one group.
在一些示例性实施方式中,控制器11根据组织AI模型运行的策略代码,确定多个AI模型之间的依赖关系(即是否具有业务依赖性)。In some exemplary embodiments, the controller 11 determines dependencies between multiple AI models (ie, whether there are business dependencies) according to the policy code that organizes the operation of the AI models.
本公开实施例所述的业务依赖性,指的是为了达到某一既定目标,设定的多个不同的AI模型之间在某一AI应用或AI业务上的特定逻辑关系,例如:多个AI模型的执行先后顺序、AI模型A的输出作为AI模型B的输入等等。控制器11通过组织AI模型运行的策略代码,来确定多个AI模型之间是否具有业务依赖性,而组织AI模型运行的策略代码,通常存储于代码仓库中。The business dependency described in the embodiments of this disclosure refers to the specific logical relationship between multiple different AI models set in a certain AI application or AI business in order to achieve a certain goal, for example: multiple The execution sequence of AI models, the output of AI model A as the input of AI model B, etc. The controller 11 determines whether there are business dependencies between multiple AI models by organizing the strategy code for running the AI models. The strategy code for organizing the running of the AI models is usually stored in a code warehouse.
示例性的,假设有一个AI应用需要检测穿着红衣服的20岁到30岁的女性。那么,组织AI模型运行的策略代码可能是这样的:通过模型1检测视频流中的所有女性,如果没有检测到,则返回空结果;通过模型2检测模型1输出的女性中20岁到30岁之间的人,如果没有检测到,则返回空结果;通过模型3检测模型2输出的20岁到30岁的女性中穿着红衣服的人,如果没有检测到,则返回空结果。那么,根据该组织AI模型运行的策略代码,模型1、模型2和模型3之间具有业务依赖性,应该分到一组(该组AI模型除模型1、模型2和模型3外,还可以包括其他的AI模型,也可以不包括其他的AI模型,根据测试环境所具备的硬件资源决定),即模型1、模型2和模型3一起进行构建评估。For example, suppose there is an AI application that needs to detect women aged 20 to 30 wearing red clothes. Then, the strategy code for organizing the operation of the AI model may be as follows: detect all women in the video stream through model 1, if not detected, return an empty result; use model 2 to detect women between 20 and 30 years old in the output of model 1 If the person between them is not detected, an empty result will be returned; if the person wearing red clothes among the 20- to 30-year-old women output by Model 2 is detected by Model 3, an empty result will be returned. Then, according to the policy code for running the organization's AI model, model 1, model 2 and model 3 have business dependencies and should be divided into one group (in addition to model 1, model 2 and model 3, this group of AI models can also Including other AI models, or not including other AI models, depending on the hardware resources of the test environment), that is, Model 1, Model 2 and Model 3 are constructed and evaluated together.
在一些示例性实施方式中,控制器11确定模型分组信息,还包括:In some exemplary embodiments, the controller 11 determines model grouping information, further including:
根据对多个AI模型进行AI能力评估时所需的视频流对所述待构建的多个AI模型进行分组,进行AI能力评估时需要相同视频流的AI模型分为一 组。The multiple AI models to be constructed are grouped according to the video streams required for the AI capability assessment of the multiple AI models, and the AI models that require the same video stream for the AI capability assessment are grouped into one group.
此时,各个AI模型可以仅设计一个测试案例,或者,可以设计多个测试案例,多个测试案例需要的视频流可以相同,也可以不同。例如,模型1、模型2和模型3能力评估时均只需要视频流a,那么,可以将模型1、模型2和模型3分为一组。又如,模型1能力评估时需要视频流a、b,模型2能力评估时需要视频流a、c,模型3能力评估时需要视频流a、d,模型4能力评估时需要视频流e、f,那么,仍然可以将模型1、模型2和模型3分为一组。At this time, each AI model can design only one test case, or multiple test cases can be designed. The video streams required by the multiple test cases can be the same or different. For example, model 1, model 2, and model 3 only require video stream a when evaluating their capabilities. Then, model 1, model 2, and model 3 can be grouped into one group. For another example, the capability assessment of Model 1 requires video streams a and b, the capability assessment of Model 2 requires video streams a and c, the capability assessment of Model 3 requires video streams a and d, and the capability assessment of Model 4 requires video streams e and f. , then, model 1, model 2 and model 3 can still be grouped into one group.
在另一些示例性实施方式中,控制器11被配置为:In other exemplary embodiments, the controller 11 is configured to:
确定模型分组信息;按照分组顺序,对每一分组的AI模型,执行如下操作:Determine the model grouping information; according to the grouping order, perform the following operations for the AI models of each group:
构建当前分组的AI模型至测试环境;对当前分组的AI模型的测试案例进行分组;按照分组顺序,对每一分组的测试案例,执行如下操作:发送第一通知至视频流模拟模块1201;接收到视频流模拟模块1201的第二通知,发送第三通知至AI能力评估模块121;接收到AI能力评估模块121的第四通知,发送第五通知至视频流模拟模块1201。Construct the AI model of the current group to the test environment; group the test cases of the AI model of the current group; perform the following operations for the test cases of each group according to the grouping order: send the first notification to the video stream simulation module 1201; receive After receiving the second notification from the video stream simulation module 1201, the third notification is sent to the AI capability evaluation module 121; upon receiving the fourth notification from the AI capability evaluation module 121, the fifth notification is sent to the video stream simulation module 1201.
本公开实施例中,在对每一分组的AI模型进行AI能力评估时,可以对每一分组的AI模型的测试案例进行分组,通过对每一分组的AI模型的测试案例进行分组,使测试效率最高,并使得在资源有限的情况下可测。In the embodiment of the present disclosure, when evaluating the AI capabilities of each grouped AI model, the test cases of each grouped AI model can be grouped, and the test cases of each grouped AI model can be grouped to make the test Maximum efficiency and enables testability with limited resources.
在一些示例性实施方式中,依据运行测试案例所需的视频流消耗的CPU资源对当前分组的AI模型的测试案例进行分组,同时运行每组测试案例所需的视频流消耗的资源小于流媒体平台1202的资源。示例性的,同时运行每组测试案例所需的视频流消耗的CPU资源小于流媒体平台1202的CPU资源。在另外一些示例性实施方式中,也可以根据同时运行每组测试案例所需的视频流消耗的GPU资源小于流媒体平台1202的GPU资源,对当前分组的AI模型的测试案例进行分组,本公开实施例对此不作限制。In some exemplary embodiments, the test cases of the currently grouped AI model are grouped according to the CPU resources consumed by the video streams required to run the test cases, and at the same time, the resources consumed by the video streams required to run each group of test cases are smaller than those of streaming media Platform 1202 resources. For example, the CPU resources consumed by the video streams required to run each set of test cases simultaneously are less than the CPU resources of the streaming media platform 1202 . In some other exemplary embodiments, the test cases of the currently grouped AI model can also be grouped based on the fact that the GPU resources consumed by the video stream required to run each group of test cases simultaneously is less than the GPU resources of the streaming media platform 1202. This disclosure The embodiment does not limit this.
本公开实施例中,由于测试案例与视频流的对应关系已预先设置,通过控制器11根据运行该测试案例所需的视频流所占用的流媒体平台1202的资源大小,对测试案例进行分组,可以降低对流媒体平台1202的资源要求。In this disclosed embodiment, since the corresponding relationship between test cases and video streams has been set in advance, the controller 11 groups the test cases according to the resource size of the streaming media platform 1202 occupied by the video streams required to run the test case. Resource requirements for the streaming media platform 1202 can be reduced.
示例性的,以当前批次分组的AI模型包括10个为例,假设每个AI模型有10个测试案例(即10个待测的AI能力),假设流媒体平台1202的资源(示例性的,资源为CPU资源)可以同时提供10个视频流服务,那么,每个AI模型一次测1个测试案例,则系统一轮可以同时测10个测试案例(假设这10个测试案例的视频流不同),一共需要测10轮,即将测试案例分为10组。实际使用时,每组多个测试案例需要的视频流可能有相同的,也可能均不相同,本公开实施例对此不作限制。控制器11通知视频流模拟模块1201准备好当前分组的测试案例所需的视频文件的视频流内容,并通过视频流模拟模块1201将这些视频文件的视频流内容推送到流媒体平台1202进行视频流的提供,待当前分组的测试案例所需的视频流在流媒体平台1202准备好后,控制器11通知AI能力评估模块121开始测试(AI能力评估模块121通知AI模型拉取流媒体平台1202的视频流,并对AI模型的输出结果进行检测,本公开实施例中,AI模型拉取流媒体平台1202的视频流后,可以一帧一帧的进行处理,也可以多帧多帧的进行处理,本公开实施例对此不作限制)。本组测试案例测试完成后,AI能力评估模块121通知控制器11测试完成。控制器11通知视频流模拟模块1201停止推送视频流内容,视频流模拟模块1201通知流媒体平台1202释放视频流。然后,按照上述方法,控制器11通知视频流模拟模块1201准备好下一分组的测试案例所需的视频文件的视频流内容,直到所有分组的测试案例测试完成。然后,重新构建下一批次分组的AI模型至测试环境,并按照上述方法,对下一批次分组的AI模型的测试案例进行测试。For example, taking the current batch of grouped AI models as including 10, assuming that each AI model has 10 test cases (i.e., 10 AI capabilities to be tested), assuming that the resources of the streaming media platform 1202 (exemplary , resource is CPU resource) can provide 10 video streaming services at the same time. Then, each AI model tests 1 test case at a time, then the system can test 10 test cases at the same time in one round (assuming that the video streams of these 10 test cases are different ), a total of 10 rounds of testing are required, that is, the test cases are divided into 10 groups. In actual use, the video streams required for each group of multiple test cases may be the same or may be different, and the embodiments of the present disclosure do not limit this. The controller 11 notifies the video stream simulation module 1201 to prepare the video stream content of the video files required for the test case of the current group, and pushes the video stream content of these video files to the streaming media platform 1202 for video streaming through the video stream simulation module 1201 Provided, after the video stream required for the current grouped test case is ready on the streaming media platform 1202, the controller 11 notifies the AI capability evaluation module 121 to start testing (the AI capability evaluation module 121 notifies the AI model to pull the streaming media platform 1202 video stream, and detect the output results of the AI model. In the embodiment of the present disclosure, after the AI model pulls the video stream of the streaming media platform 1202, it can be processed frame by frame, or it can be processed in multiple frames. , the embodiment of the present disclosure does not limit this). After the testing of this group of test cases is completed, the AI capability evaluation module 121 notifies the controller 11 that the testing is completed. The controller 11 notifies the video stream simulation module 1201 to stop pushing the video stream content, and the video stream simulation module 1201 notifies the streaming media platform 1202 to release the video stream. Then, according to the above method, the controller 11 notifies the video stream simulation module 1201 to prepare the video stream content of the video file required for the test case of the next group until the test case testing of all groups is completed. Then, re-construct the next batch of grouped AI models to the test environment, and test the test cases of the next batch of grouped AI models according to the above method.
实际使用时,每个测试案例需要的测试时间可能相同,也可能不同,因此,可以将每一分组的测试案例分成多个小组,使用相同视频流的测试案例分为一个小组,当某个测试案例或某个小组的测试案例测试完成后,AI能力评估模块121可以通知控制器11本测试案例或本小组的测试案例测试完成,控制器11通知视频流模拟模块1201停止推送该测试案例或该小组的测试案例对应的视频流内容,视频流模拟模块1201通知流媒体平台1202释放该测试案例或该小组的测试案例对应的视频流,这样可以尽早地释放流媒体平台1202的资源,提高并行效率。示例性的,如图2B所示,假设当前分组的AI 模型的测试案例包括20个测试案例,而该20个测试案例需要三个视频流,其中,A1到A10这10个测试案例需要视频流a,B1到B5这5个测试案例需要视频流b,C1到C5这5个测试案例需要视频流c,假设流媒体平台1202可以同时提供视频流a、b或同时提供视频流a、c,那么,在对当前分组的AI模型的测试案例进行分组时,如图2C所示,可以将这20个测试案例分成10组,其中,第一组测试案例包括A1、B1,第二组测试案例包括A2、B2,…,第五组测试案例包括A5、B5,第六组测试案例包括A6、C1,第七组测试案例包括A7、C2,…,第十组测试案例包括A10、C5,在评估完第五组测试案例时,可以释放视频流b,并提供视频流c,然后再评估第六组测试案例。本公开实施例中,可以将A1到A10这10个测试案例分成一个小组,将B1到B5这5个测试案例分成一个小组,将C1到C5这5个测试案例分成一个小组。当每个小组的测试案例测试完成时,流媒体平台1202释放该小组的测试案例对应的视频流,这样可以尽早地释放流媒体平台1202的资源,提高并行效率。假设流媒体平台1202可以同时提供视频流a、b、c,那么,在对当前分组的AI模型的测试案例进行分组时,如图2D所示,可以将这20个测试案例分成10组,其中,第一组测试案例包括有A1、B1、C1,第二组测试案例包括有A2、B2、C2,…,第五组测试案例包括有A5、B5、C5,第六组测试案例包括有A6,第七组测试案例包括有A7,…,第十组测试案例包括有A10。上述测试过程中,每个AI模型同时只运行一个测试案例,实际使用过程中,每个AI模型可以同时运行多个测试案例,多个测试案例对应的视频流可以相同,也可以不同,本公开实施例对此不作限制。In actual use, the test time required for each test case may be the same or different. Therefore, the test cases of each group can be divided into multiple groups, and the test cases using the same video stream are divided into one group. When a test After the test case or the test case of a certain group is completed, the AI capability evaluation module 121 can notify the controller 11 that the test case or the test case of this group is completed, and the controller 11 notifies the video stream simulation module 1201 to stop pushing the test case or the test case. The video stream content corresponding to the group's test case, the video stream simulation module 1201 notifies the streaming media platform 1202 to release the test case or the video stream corresponding to the group's test case, so that the resources of the streaming media platform 1202 can be released as early as possible and improve parallel efficiency. . For example, as shown in Figure 2B, assume that the test cases of the currently grouped AI model include 20 test cases, and the 20 test cases require three video streams. Among them, the 10 test cases A1 to A10 require video streams. a, the five test cases B1 to B5 require video stream b, and the five test cases C1 to C5 require video stream c. Assume that the streaming media platform 1202 can provide video streams a and b at the same time or provide video streams a and c at the same time. Then, when grouping the test cases of the currently grouped AI model, as shown in Figure 2C, these 20 test cases can be divided into 10 groups. Among them, the first group of test cases includes A1 and B1, and the second group of test cases Including A2, B2,..., the fifth group of test cases includes A5, B5, the sixth group of test cases includes A6, C1, the seventh group of test cases includes A7, C2,..., the tenth group of test cases includes A10, C5, in After evaluating the fifth set of test cases, video stream b can be released and video stream c provided, and then the sixth set of test cases can be evaluated. In this disclosed embodiment, the 10 test cases from A1 to A10 can be divided into one group, the 5 test cases from B1 to B5 can be divided into one group, and the 5 test cases from C1 to C5 can be divided into one group. When each group's test case testing is completed, the streaming media platform 1202 releases the video stream corresponding to the group's test case, so that the resources of the streaming media platform 1202 can be released as early as possible and improve parallel efficiency. Assuming that the streaming media platform 1202 can provide video streams a, b, and c at the same time, then, when grouping the test cases of the currently grouped AI model, as shown in Figure 2D, these 20 test cases can be divided into 10 groups, where , the first group of test cases includes A1, B1, C1, the second group of test cases includes A2, B2, C2,..., the fifth group of test cases includes A5, B5, C5, and the sixth group of test cases includes A6 , the seventh group of test cases includes A7,..., and the tenth group of test cases includes A10. During the above test process, each AI model only runs one test case at the same time. In actual use, each AI model can run multiple test cases at the same time. The video streams corresponding to the multiple test cases can be the same or different. This disclosure The embodiment does not limit this.
示例性的,仍以当前批次分组的AI模型包括10个(即10个待测的AI能力)、每个AI模型有10个测试案例、100个测试案例对应的视频流不同为例,假设流媒体平台1202的CPU资源性能很强,可以同时提供该100个测试案例对应的视频流服务,且测试环境的硬件资源很强,每个AI模型一次可以测10个测试案例,则系统一轮就可以同时测100个测试案例,即所有的测试案例分为一组。此时,控制器11通知视频流模拟模块1201准备好这100个测试案例所需的视频文件的视频流内容,并通过视频流模拟模块1201将这些视频文件的视频流内容推送到流媒体平台1202进行视频流的提供,待 这100个测试案例所需的视频流在流媒体平台1202准备好后,控制器11通知AI能力评估模块121开始测试(AI能力评估模块121通知AI模型拉取流媒体平台1202的视频流,并对AI模型的输出结果进行检测)。待这100个测试案例测试完成后,AI能力评估模块121通知控制器11测试完成,控制器11通知视频流模拟模块1201停止推送视频流内容,视频流模拟模块1201通知流媒体平台1202释放视频流(此处,也可以在某个测试案例或使用相同视频流的某一小组的测试案例测试完成时,控制器11通知视频流模拟模块1201释放该测试案例或该小组的测试案例对应的视频文件,视频流模拟模块1201通知流媒体平台1202释放该测试案例或该小组的测试案例对应的视频流)。然后,按照上述方法,控制器11重新构建下一批次分组的AI模型至测试环境,并按照上述方法,对下一批次分组的AI模型的测试案例进行测试。As an example, the current batch of AI models includes 10 (that is, 10 AI capabilities to be tested), each AI model has 10 test cases, and the 100 test cases correspond to different video streams. Assume The CPU resource performance of the streaming media platform 1202 is very strong, and it can provide video streaming services corresponding to the 100 test cases at the same time, and the hardware resources of the test environment are very strong. Each AI model can test 10 test cases at a time, and the system is in one round. You can test 100 test cases at the same time, that is, all test cases are divided into one group. At this time, the controller 11 notifies the video stream simulation module 1201 to prepare the video stream content of the video files required for these 100 test cases, and pushes the video stream content of these video files to the streaming media platform 1202 through the video stream simulation module 1201 Provide video streams. After the video streams required for these 100 test cases are ready on the streaming media platform 1202, the controller 11 notifies the AI capability evaluation module 121 to start testing (the AI capability evaluation module 121 notifies the AI model to pull the streaming media The video stream of the platform 1202 and detect the output results of the AI model). After the testing of these 100 test cases is completed, the AI capability evaluation module 121 notifies the controller 11 that the test is completed, the controller 11 notifies the video stream simulation module 1201 to stop pushing video stream content, and the video stream simulation module 1201 notifies the streaming media platform 1202 to release the video stream. (Here, when a test case or a test case of a certain group using the same video stream is completed, the controller 11 notifies the video stream simulation module 1201 to release the video file corresponding to the test case or the group's test case. , the video stream simulation module 1201 notifies the streaming media platform 1202 to release the video stream corresponding to the test case or the test case of the group). Then, according to the above method, the controller 11 reconstructs the next batch of grouped AI models to the test environment, and according to the above method, tests the test cases of the next batch of grouped AI models.
在一些示例性实施方式中,对当前分组的AI模型的测试案例进行分组还包括:根据运行测试案例所需的视频流进行分组。In some exemplary implementations, grouping the test cases of the currently grouped AI model further includes: grouping according to video streams required to run the test cases.
示例性的,假设AI模型1需要对人脸进行检测,AI模型2需要对人头进行检测,如图2E所示,如果AI模型1的D1到D5这5个测试案例需要视频流a,E1到E5这5个测试案例需要视频流b,AI模型2的F1到F5这5个测试案例需要视频流a,G1到G5这5个测试案例需要视频流c,流媒体平台1202可以同时提供两个视频流,不能同时提供三个视频流,那么,如图2F所示,第一组测试案例可以包括D1、E1、F1(需要视频流a、b),第二组测试案例可以包括D2、E2、F2(需要视频流a、b),…,第五组测试案例可以包括D5、E5、F5(需要视频流a、b),第六组测试案例可以包括G1、G2和G3(需要视频流c),第七组测试案例可以包括G4和G5(需要视频流c)。实际使用本公开的AI模型构建评估系统时,具体如何对测试案例进行分组可以根据需要进行设置,本公开实施例对此不作限制。For example, assume that AI model 1 needs to detect human faces, and AI model 2 needs to detect human heads, as shown in Figure 2E. If the five test cases from D1 to D5 of AI model 1 require video stream a, E1 to The five test cases of E5 require video stream b, the five test cases of AI model 2 from F1 to F5 require video stream a, and the five test cases of G1 to G5 require video stream c. The streaming media platform 1202 can provide two at the same time. Video streams cannot provide three video streams at the same time. Then, as shown in Figure 2F, the first set of test cases can include D1, E1, and F1 (requiring video streams a and b), and the second set of test cases can include D2 and E2. , F2 (requires video streams a, b), ..., the fifth group of test cases can include D5, E5, F5 (requires video streams a, b), and the sixth group of test cases can include G1, G2 and G3 (requires video streams c), the seventh group of test cases can include G4 and G5 (requires video stream c). When actually using the AI model of the present disclosure to build an evaluation system, the specific method of grouping test cases can be set as needed, and the embodiments of the present disclosure do not limit this.
在一些示例性实施方式中,当某个测试案例没有通过测试时,可以通过发送相应的告警信息、邮件等,提醒相关开发人员,以便开发人员尽早地修改模型代码,提高研发效率。In some exemplary implementations, when a test case fails to pass the test, relevant developers can be reminded by sending corresponding alarm information, emails, etc., so that the developers can modify the model code as early as possible to improve research and development efficiency.
如图3所示,本公开实施例结合DevOps所针对的AI能力目标所需的视 频流环境要求,结合自动化验证所需的案例要求,使用视频文件模拟视频流技术,将媒体文件库中的媒体文件模拟成为视频流,完成构建过程,再进行释放,解决了一些方法同时进行多个AI服务DevOps构建过程中,所带来的巨大的视频流所需的CPU与内存资源开销过大的问题。As shown in Figure 3, this embodiment of the present disclosure combines the video streaming environment requirements required for the AI capability goals targeted by DevOps, combined with the case requirements required for automated verification, uses video files to simulate video streaming technology, and converts the media in the media file library The file is simulated into a video stream, the construction process is completed, and then released, which solves the problem of excessive CPU and memory resource overhead caused by the huge video stream required by some methods to simultaneously carry out the DevOps construction process of multiple AI services.
在一些示例性实施方式中,在当前分组的测试案例测试完成前,视频流模拟模块1201将当前分组的测试案例所需的视频流内容推送至流媒体平台1202进行循环提供。In some exemplary embodiments, before the test case test of the current group is completed, the video stream simulation module 1201 pushes the video stream content required for the test case of the current group to the streaming media platform 1202 for cyclic provision.
本实施例中,通过将视频流内容推送至流媒体平台1202进行循环提供,AI能力评估模块121可以确定AI模型是否可以在相对的一个播放时长内给出推理结果,即针对于每个测试案例有了一个相对的视频开始时间,从而降低了评估难度。例如,假设某个测试案例的视频流播放时长为15s,如果AI模型在15s内给出推理结果,则认为推理成功,那么,由于视频流内容在循环推送,如果从某一时刻起15s内,AI模型没有给出推理结果,则AI能力评估模块121可以确定推理失败。在另外一些示例性实施例中,AI能力评估模块121可以通过视频帧的时间戳来精确确定AI模型拉取视频流的开始时间以及获得推理结果时的推理时间,进而获得准确的推理时长,虽然该种获得准确的推理时长的方法不需要循环推送视频流,但是,执行步骤相对比较复杂,评估难度相对较高。In this embodiment, by pushing the video stream content to the streaming media platform 1202 for cyclic provision, the AI capability evaluation module 121 can determine whether the AI model can provide inference results within a relative playback duration, that is, for each test case Having a relative video start time reduces the difficulty of evaluation. For example, assume that the video stream playback duration of a certain test case is 15s. If the AI model gives the inference result within 15s, the inference is considered successful. Then, since the video stream content is pushed in a loop, if within 15s from a certain moment, If the AI model does not provide an inference result, the AI capability evaluation module 121 may determine that the inference fails. In some other exemplary embodiments, the AI capability evaluation module 121 can accurately determine the start time of the AI model pulling the video stream and the inference time when obtaining the inference result through the timestamp of the video frame, thereby obtaining an accurate inference duration. Although This method of obtaining accurate inference duration does not require looping the video stream, but the execution steps are relatively complex and the evaluation difficulty is relatively high.
本公开实施例中,视频流模拟模块1201将当前分组的测试案例所需的视频流内容推送至流媒体平台1202进行循环提供,包含以下两种情况中的任意一种:1)视频流模拟模块1201将当前分组的测试案例所需的视频流内容循环的推送至流媒体平台1202,以使得流媒体平台1202循环的提供当前分组的测试案例所需的视频流;2)视频流模拟模块1201将当前分组的测试案例所需的视频流内容推送至流媒体平台1202(仅推送一次),但流媒体平台1202循环的提供当前分组的测试案例所需的视频流,即流媒体平台1202带有循环模式,此时,只需要视频流模拟模块1201推送一次视频流内容,流媒体平台1202循环提供该视频流。In this disclosed embodiment, the video stream simulation module 1201 pushes the video stream content required for the current grouped test case to the streaming media platform 1202 for cyclic provision, including any of the following two situations: 1) Video stream simulation module 1201 cyclically pushes the video stream content required for the test case of the current group to the streaming media platform 1202, so that the streaming media platform 1202 cyclically provides the video stream required for the test case of the current group; 2) the video stream simulation module 1201 will The video stream content required for the test case of the current group is pushed to the streaming media platform 1202 (pushed only once), but the streaming media platform 1202 provides the video stream required for the test case of the current group in a loop, that is, the streaming media platform 1202 has a loop mode, at this time, the video stream simulation module 1201 only needs to push the video stream content once, and the streaming media platform 1202 provides the video stream in a loop.
在一些示例性实施方式中,如图2A所示,该AI模型构建评估系统还包括媒体文件库106,其中,媒体文件库106,被配置为存储评估每个分组的 AI模型所需的视频文件。In some exemplary embodiments, as shown in FIG. 2A , the AI model building evaluation system further includes a media file library 106 , wherein the media file library 106 is configured to store video files required for evaluating the AI model of each group. .
本公开实施例中,测试案例对应的视频文件存储在媒体文件库106中。从播放角度来说,视频流模拟模块1201从媒体文件库106播放视频文件,然后将播放的视频文件的视频流内容推送到流媒体平台1202上。本公开实施例中的视频文件是预先存储在媒体文件库106,用于评估AI模型的功能或性能的视频,以实现自动化测试。通过设置媒体文件库106(位于流媒体平台1202之外的服务器上),可以使流媒体平台1202更加专注于实现推拉流功能,流媒体平台1202所需的视频文件的存储由媒体文件库106完成,从而可以提供更加丰富的视频文件内容,进而可以使得AI模型的评估更加准确。In this disclosed embodiment, the video files corresponding to the test cases are stored in the media file library 106 . From a playback perspective, the video stream simulation module 1201 plays the video file from the media file library 106, and then pushes the video stream content of the played video file to the streaming media platform 1202. The video files in the embodiment of the present disclosure are videos that are pre-stored in the media file library 106 and are used to evaluate the function or performance of the AI model to achieve automated testing. By setting up the media file library 106 (located on a server outside the streaming media platform 1202), the streaming media platform 1202 can be more focused on implementing the push-pull streaming function. The storage of video files required by the streaming media platform 1202 is completed by the media file library 106. , which can provide richer video file content, which can make the evaluation of the AI model more accurate.
在一些示例性实施方式中,当视频文件的格式为非流媒体文件格式时,由视频流模拟模块1201通知流媒体平台1202将视频文件的格式转换为流媒体文件格式。In some exemplary implementations, when the format of the video file is a non-streaming media file format, the video stream simulation module 1201 notifies the streaming media platform 1202 to convert the format of the video file into a streaming media file format.
本公开实施例中,视频文件的格式可以为MPEG-1或其他任意的视频文件的格式,流媒体平台1202可以将其转换为MPEG-4或其他任意的流媒体文件格式,本公开实施例对此不作限制。In this embodiment of the present disclosure, the format of the video file may be MPEG-1 or any other video file format, and the streaming media platform 1202 may convert it into MPEG-4 or any other streaming media file format. This embodiment of the present disclosure is suitable for This is not a limitation.
在一些示例性实施方式中,如图4和图5所示,该AI模型构建评估系统按需模拟AI智能服务DevOps过程中所需的视频流环境的构建评估过程,包括以下步骤:In some exemplary implementations, as shown in Figures 4 and 5, the AI model construction evaluation system simulates on demand the construction evaluation process of the video streaming environment required in the AI intelligent service DevOps process, including the following steps:
1)研发人员提交代码至GIT代码仓库,GIT代码仓库自动触发DevOps构建评估过程;1) R&D personnel submit code to the GIT code warehouse, and the GIT code warehouse automatically triggers the DevOps build evaluation process;
2)DevOps控制器将构建过程整理,合并后推送至任务队列;2) The DevOps controller organizes the build process, merges it and pushes it to the task queue;
3)DevOps控制器取得构建任务,从GIT代码仓库拉取分组代码,取得模型分组信息,然后拉取当前批次分组的模型代码,并编译部署至测试环境;3) The DevOps controller obtains the build task, pulls the group code from the GIT code warehouse, obtains the model group information, then pulls the model code of the current batch group, compiles and deploys it to the test environment;
4)DevOps控制器读取当前批次分组内所有AI能力目录(此处,AI能力目录指的是需要测试的AI功能列表,即测试案例)所涉及到的配置(该配置包含AI模型与所需的视频流地址列表),梳理测试所需的视频流地址列表;4) The DevOps controller reads the configuration involved in all AI capability catalogs (here, the AI capability catalog refers to the list of AI functions that need to be tested, that is, test cases) in the current batch group (this configuration includes the AI model and all Required video stream address list), sort out the video stream address list required for testing;
5)DevOps控制器将所需要的视频流地址列表发送至视频流模拟模块处 理;5) The DevOps controller sends the required video stream address list to the video stream simulation module for processing;
6)视频流模拟模块取得案例库中视频流信息(确定视频文件格式是否为流媒体格式,如果不是,通知流媒体平台将视频文件格式转换为流媒体文件格式),拉取相应的视频文件;6) The video stream simulation module obtains the video stream information in the case library (determines whether the video file format is a streaming media format, and if not, notifies the streaming media platform to convert the video file format to a streaming media file format), and pulls the corresponding video file;
7)视频流模拟模块根据视频文件和视频流地址的一一对应关系,将视频文件的视频流内容推送至流媒体平台进行循环提供(视频流模拟模块将视频文件的视频流内容循环的推送至流媒体平台,或者,流媒体平台循环的提供视频文件的视频流内容),并且一一验证;7) The video stream simulation module pushes the video stream content of the video file to the streaming media platform for cyclic provision based on the one-to-one correspondence between the video file and the video stream address (the video stream simulation module cyclically pushes the video stream content of the video file to The streaming media platform, or the streaming media platform provides the video streaming content of the video files in a loop) and verifies them one by one;
8)DevOps控制器得到视频流环境构建完成信号后,启动AI能力评估模块进行模型评估,待模型评估完成后,发送释放指令给视频流模拟模块;8) After receiving the signal that the video streaming environment construction is complete, the DevOps controller starts the AI capability evaluation module to evaluate the model. After the model evaluation is completed, it sends a release instruction to the video streaming simulation module;
9)视频流模拟模块根据视频流的使用情况,停止推送当前不再进行使用的视频流内容,并向流媒体平台发送释放指令,完成视频流的释放。9) The video stream simulation module stops pushing video stream content that is no longer in use based on the usage of the video stream, and sends a release instruction to the streaming media platform to complete the release of the video stream.
在图5中,当DevOps控制器、视频流模拟模块在上述步骤执行过程中出现错误时(示例性的,DevOps控制器没有从GIT代码仓库拉取到分组代码、DevOps控制器没有读取到当前批次分组内所有AI能力目录所涉及到的配置、视频流模拟模块没有取得视频流信息等等),可以通过发送相应的告警信息、邮件等,提醒相关开发人员,以便开发人员尽早地修改构建脚本或配置,提高研发效率。In Figure 5, when an error occurs in the DevOps controller and video stream simulation module during the execution of the above steps (for example, the DevOps controller does not pull the group code from the GIT code repository, the DevOps controller does not read the current Configurations involved in all AI capability directories in the batch group, video stream simulation modules have not obtained video stream information, etc.), relevant developers can be reminded by sending corresponding alarm information, emails, etc., so that developers can modify the build as soon as possible Scripts or configurations to improve R&D efficiency.
本公开实施例提供的AI模型构建评估系统,按照评估对象所需,临时构建所需视频流,完成模型评估后,立刻释放,大幅降低DevOps环境所需资源,同时使得模型评估过程变得更加可控;模型评估过程针对于案例有了视频开始时间,降低了评估难度;构建、评估、上线过程可以分组进行,提升了AI技术研发效率,降低了成本。The AI model construction and evaluation system provided by the embodiments of the present disclosure temporarily builds the required video stream according to the needs of the evaluation object, and releases it immediately after completing the model evaluation, which greatly reduces the resources required in the DevOps environment and makes the model evaluation process more feasible. control; the model evaluation process has a video start time for the case, which reduces the difficulty of evaluation; the construction, evaluation, and online processes can be carried out in groups, which improves the efficiency of AI technology research and development and reduces costs.
如图6所示,本公开实施例还提供了一种AI模型构建评估方法,包括:As shown in Figure 6, embodiments of the present disclosure also provide an AI model construction and evaluation method, including:
步骤601、控制器确定AI模型的分组信息;Step 601: The controller determines the grouping information of the AI model;
步骤602、按照分组顺序,对每一分组的AI模型,执行如下操作:Step 602: According to the grouping order, perform the following operations on the AI models of each group:
控制器构建当前分组的AI模型至测试环境,发送第一通知至模拟测评 模块;模拟测评模块接收到控制器的第一通知,向AI模型提供视频流服务,视频流服务的内容为评估当前分组的AI模型所需的视频文件的视频流内容;对当前分组的AI模型进行AI能力评估;待能力评估完成后,释放视频流。The controller builds the AI model of the current group to the test environment and sends the first notification to the simulation evaluation module; the simulation evaluation module receives the first notification from the controller and provides video streaming services to the AI model. The content of the video streaming service is to evaluate the current grouping. The video stream content of the video file required by the AI model; perform an AI capability assessment on the currently grouped AI model; release the video stream after the capability assessment is completed.
本公开实施例的AI模型构建评估方法,通过对AI模型进行分组,依次构建每组的AI模型至测试环境,并对当前分组的AI模型按需提供评估所需的流媒体服务,在模型评估完成后,释放视频流,不需要始终保持所有AI模型的视频流,不但解决了视频流环境大量资源浪费的问题,使得AI模型DevOps环境所需计算资源大幅降低,同时使得模型评估过程变得更加可控,提升了AI技术研发效率,降低了成本。The AI model construction and evaluation method of the embodiment of the present disclosure groups the AI models, sequentially constructs the AI models of each group to the test environment, and provides the streaming media services required for evaluation on demand for the currently grouped AI models. During the model evaluation After completion, the video stream is released, and there is no need to maintain the video stream of all AI models at all times. This not only solves the problem of wasting a lot of resources in the video streaming environment, but also greatly reduces the computing resources required in the DevOps environment of the AI model, and also makes the model evaluation process more efficient. Controllable, it improves the efficiency of AI technology research and development and reduces costs.
在一些示例性实施方式中,控制器确定AI模型的分组信息,包括:In some exemplary implementations, the controller determines grouping information of the AI model, including:
控制器获取待构建的多个AI模型的构建脚本;The controller obtains the construction scripts of multiple AI models to be built;
控制器根据每个AI模型所消耗的资源对所述待构建的多个AI模型进行分组,每组AI模型所消耗的硬件资源小于所述测试环境所具备的硬件资源。The controller groups the multiple AI models to be built according to the resources consumed by each AI model. The hardware resources consumed by each group of AI models are less than the hardware resources of the test environment.
示例性的,假设在一个系统上部署了10个AI模型,该系统的推理卡资源大小为16G,那么,这10个AI模型总体占用的推理卡资源大小应该小于16G。For example, assuming that 10 AI models are deployed on a system, and the inference card resource size of the system is 16G, then the total inference card resource size occupied by these 10 AI models should be less than 16G.
在一些示例性实施方式中,控制器确定AI模型的分组信息,包括:In some exemplary implementations, the controller determines grouping information of the AI model, including:
控制器获取待构建的多个AI模型的构建脚本;The controller obtains the construction scripts of multiple AI models to be built;
控制器根据每个AI模型所消耗的资源以及不同AI模型之间的关系对所述待构建的多个AI模型进行分组,每组AI模型所消耗的硬件资源小于所述测试环境所具备的硬件资源,有依赖关系的AI模型分为一组。The controller groups the multiple AI models to be built according to the resources consumed by each AI model and the relationship between different AI models. The hardware resources consumed by each group of AI models are less than the hardware of the test environment. Resources, AI models with dependencies are grouped into a group.
仍以上述10个AI模型为例,这10个AI模型中,可能有部分模型之间或全部模型之间存在业务依赖性,有依赖关系的AI模型分为一组。Still taking the above 10 AI models as an example, among these 10 AI models, there may be business dependencies between some or all models, and the AI models with dependencies are grouped into one group.
在一些示例性实施方式中,控制器根据组织AI模型运行的策略代码,确定多个AI模型之间的依赖关系。In some exemplary embodiments, the controller determines dependencies between multiple AI models according to a policy code that organizes the operation of the AI models.
在另一些示例性实施方式中,该AI模型构建评估方法还包括:In other exemplary implementations, the AI model construction and evaluation method further includes:
控制器获取当前分组的AI模型的测试案例的分组信息;The controller obtains the grouping information of the test cases of the currently grouped AI model;
所述对当前分组的AI模型进行AI能力评估,包括:按照测试案例的分组顺序,对每一分组的测试案例进行AI能力评估。The AI capability evaluation of the currently grouped AI models includes: performing an AI capability evaluation on the test cases of each group according to the grouping order of the test cases.
在一些示例性实施方式中,控制器依据模拟测试案例所需的视频流消耗的资源对当前分组的AI模型的测试案例进行分组,同时模拟每组测试案例所需的视频流消耗的资源小于流媒体平台的资源。In some exemplary implementations, the controller groups the test cases of the currently grouped AI model according to the resources consumed by the video stream required to simulate the test case, and at the same time, the resources consumed by the video stream required to simulate each group of test cases are less than the resource consumed by the video stream. Media platform resources.
在一些示例性实施方式中,在当前分组的测试案例测试完成前,视频流模拟模块将当前分组的测试案例所需的视频文件的视频流内容推送至流媒体平台,以循环地提供当前分组的测试案例所需的视频流(视频流模拟模块将评估当前分组的AI模型所需的视频文件的视频流内容循环地推送至流媒体平台,或者,流媒体平台循环地提供视频文件的视频流内容)。In some exemplary embodiments, before the test case test of the current group is completed, the video stream simulation module pushes the video stream content of the video file required by the test case of the current group to the streaming media platform to cyclically provide the test case of the current group. The video stream required for the test case (the video stream simulation module cyclically pushes the video stream content of the video file required to evaluate the current grouped AI model to the streaming media platform, or the streaming media platform cyclically provides the video stream content of the video file ).
在一些示例性实施方式中,在某个测试案例或某个分组的测试案例测试完成后,视频流模拟模块通知流媒体平台释放该测试案例或该分组的测试案例对应的视频流,以尽早释放流媒体平台的资源。In some exemplary implementations, after the test case of a certain test case or a test case of a certain group is tested, the video stream simulation module notifies the streaming media platform to release the video stream corresponding to the test case or the test case of the group so as to release it as soon as possible. Resources for streaming platforms.
在一些示例性实施方式中,控制器构建当前分组的AI模型至测试环境,包括:In some exemplary implementations, the controller builds the current grouped AI model to the test environment, including:
拉取当前分组的AI模型的模型代码;Pull the model code of the currently grouped AI model;
编译当前分组的AI模型的模型代码;Compile the model code of the currently grouped AI model;
部署当前分组的AI模型至测试环境。Deploy the AI model of the current group to the test environment.
在一些示例性实施方式中,AI模型的分组信息、AI模型的代码信息、AI模型的构建脚本、组织AI模型运行的策略代码均存储于代码仓库中。In some exemplary implementations, the grouping information of the AI model, the code information of the AI model, the construction script of the AI model, and the policy code for organizing the operation of the AI model are all stored in the code warehouse.
示例性的,该代码仓库可以为GIT代码仓库。GIT是一个开源的分布式版本控制系统,用于敏捷高效地处理任何或小或大的项目。每当研发人员提交代码至GIT代码仓库时,GIT代码仓库可以自动触发DevOps构建评估过程。For example, the code repository can be a GIT code repository. GIT is an open source distributed version control system for agile and efficient handling of any project, small or large. Whenever developers submit code to the GIT code repository, the GIT code repository can automatically trigger the DevOps build evaluation process.
在一些示例性实施方式中,评估每个分组的AI模型所需的视频文件存储于媒体文件库中。In some example embodiments, the video files required to evaluate the AI model for each group are stored in a media file library.
在一些示例性实施方式中,当视频文件的格式为非流媒体文件格式时,由视频流模拟模块通知流媒体平台将视频文件的格式转换为流媒体文件格式。In some exemplary implementations, when the format of the video file is a non-streaming media file format, the video stream simulation module notifies the streaming media platform to convert the format of the video file into a streaming media file format.
如图7所示,本公开实施例还提供了一种AI模型构建评估方法,应用于控制器,该AI模型构建评估方法包括:As shown in Figure 7, the embodiment of the present disclosure also provides an AI model construction and evaluation method, which is applied to the controller. The AI model construction and evaluation method includes:
步骤701、确定模型分组信息;Step 701: Determine model grouping information;
步骤702、按照分组顺序,对每一分组的AI模型,执行如下操作:构建当前分组的AI模型至测试环境,通知视频流模拟模块将评估当前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台,通知AI能力评估模块使用流媒体平台的视频流对当前分组的AI模型进行AI能力评估,待能力评估完成后,通知视频流模拟模块与流媒体平台释放视频流。Step 702: Perform the following operations on the AI model of each group according to the grouping order: build the AI model of the current group to the test environment, and notify the video stream simulation module to evaluate the video stream content of the video file required by the AI model of the current group. Push it to the streaming media platform, and notify the AI capability evaluation module to use the video stream of the streaming media platform to evaluate the AI capability of the current grouped AI model. After the capability assessment is completed, notify the video stream simulation module and streaming media platform to release the video stream.
本公开实施例的AI模型构建评估方法,通过对AI模型进行分组,依次构建每组的AI模型至测试环境,并对当前分组的AI模型按需提供评估所需的流媒体服务,在模型评估完成后,释放视频流,不需要始终保持所有AI模型的视频流,不但解决了视频流环境大量资源浪费的问题,使得AI模型DevOps环境所需计算资源大幅降低,同时使得模型评估过程变得更加可控,提升了AI技术研发效率,降低了成本。The AI model construction and evaluation method of the embodiment of the present disclosure groups the AI models, sequentially constructs the AI models of each group to the test environment, and provides the streaming media services required for evaluation on demand for the currently grouped AI models. During the model evaluation After completion, the video stream is released, and there is no need to maintain the video stream of all AI models at all times. This not only solves the problem of wasting a lot of resources in the video streaming environment, but also greatly reduces the computing resources required in the DevOps environment of the AI model, and also makes the model evaluation process more efficient. Controllable, it improves the efficiency of AI technology research and development and reduces costs.
在一些示例性实施方式中,确定模型分组信息,包括:In some exemplary implementations, determining model grouping information includes:
获取待构建的多个AI模型的构建脚本;Obtain the construction scripts of multiple AI models to be built;
根据每个AI模型所消耗的资源对所述待构建的多个AI模型进行分组,每组AI模型所消耗的硬件资源小于所述测试环境所具备的硬件资源。The multiple AI models to be built are grouped according to the resources consumed by each AI model, and the hardware resources consumed by each group of AI models are less than the hardware resources of the test environment.
在一些示例性实施方式中,确定模型分组信息,包括:In some exemplary implementations, determining model grouping information includes:
获取待构建的多个AI模型的构建脚本;Obtain the construction scripts of multiple AI models to be built;
根据每个AI模型所消耗的资源以及不同AI模型之间的关系对所述待构建的多个AI模型进行分组,每组AI模型所消耗的硬件资源小于所述测试环境所具备的硬件资源,有依赖关系的AI模型分为一组。The multiple AI models to be built are grouped according to the resources consumed by each AI model and the relationship between different AI models. The hardware resources consumed by each group of AI models are less than the hardware resources of the test environment, AI models with dependencies are grouped into a group.
在一些示例性实施方式中,根据组织AI模型运行的策略代码,确定多个AI模型之间的依赖关系。In some exemplary implementations, dependencies between multiple AI models are determined according to a policy code that organizes the operation of the AI model.
在一些示例性实施方式中,步骤702中的通知视频流模拟模块将评估当 前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台,通知AI能力评估模块使用流媒体平台的视频流对当前分组的AI模型进行AI能力评估,待能力评估完成后,通知视频流模拟模块与流媒体平台释放视频流,包括:In some exemplary embodiments, the video stream simulation module in step 702 pushes the video stream content of the video file required to evaluate the AI model of the current group to the streaming media platform, and notifies the AI capability evaluation module to use the video of the streaming media platform. The stream performs an AI capability assessment on the current grouped AI model. After the capability assessment is completed, it notifies the video stream simulation module and the streaming media platform to release the video stream, including:
对当前分组的AI模型的测试案例进行分组;Group the test cases of the currently grouped AI model;
按照分组顺序,对每一分组的测试案例,执行如下操作:通知视频流模拟模块将当前分组的测试案例所需的视频文件的视频流内容推送至流媒体平台,以在所述流媒体平台上形成可供所述AI模型拉取的视频流;通知AI能力评估模块使用所述流媒体平台的视频流对每一分组的测试案例进行测试,待某一测试案例测试完成后或当前分组的测试案例测试完成后,通知视频流模拟模块停止推送所述视频流内容,并由视频流模拟模块通知流媒体平台释放所述视频流。According to the grouping order, perform the following operations for each grouped test case: notify the video stream simulation module to push the video stream content of the video file required for the current grouped test case to the streaming media platform, so that it can be displayed on the streaming media platform. Form a video stream that can be pulled by the AI model; notify the AI capability evaluation module to use the video stream of the streaming media platform to test the test cases of each group. After the test of a certain test case is completed or the test of the current group After the case test is completed, the video stream simulation module is notified to stop pushing the video stream content, and the video stream simulation module notifies the streaming media platform to release the video stream.
在一些示例性实施方式中,依据模拟测试案例所需的视频流消耗的资源对当前分组的AI模型的测试案例进行分组,同时模拟每组测试案例所需的视频流消耗的资源小于流媒体平台的资源。In some exemplary implementations, the test cases of the currently grouped AI model are grouped according to the resources consumed by the video streams required to simulate the test cases, and at the same time, the resources consumed by the video streams required to simulate each group of test cases are smaller than those of the streaming media platform H.
在一些示例性实施方式中,构建当前分组的AI模型至测试环境,包括:In some exemplary implementations, building the AI model of the current group to the test environment includes:
拉取当前分组的AI模型的模型代码;Pull the model code of the currently grouped AI model;
编译当前分组的AI模型的模型代码;Compile the model code of the currently grouped AI model;
部署当前分组的AI模型至测试环境。Deploy the AI model of the current group to the test environment.
在一些示例性实施方式中,通知视频流模拟模块与流媒体平台释放视频流,包括:In some exemplary implementations, notifying the video stream simulation module and the streaming media platform to release the video stream includes:
通知视频流模拟模块停止推送所述视频流内容,并由视频流模拟模块向流媒体平台发送视频流释放指令。The video stream simulation module is notified to stop pushing the video stream content, and the video stream simulation module sends a video stream release instruction to the streaming media platform.
本公开实施例中,视频源是视频流模拟模块,视频流模拟模块向流媒体平台推流;AI模型从流媒体平台拉流,流媒体平台处于中间,相当于一个转发的功能,相当于AI模型通过流媒体平台与视频流模拟模块建立连接。In this disclosed embodiment, the video source is a video stream simulation module, which pushes streams to the streaming media platform; the AI model pulls streams from the streaming media platform, and the streaming media platform is in the middle, equivalent to a forwarding function, equivalent to AI The model is connected to the video streaming simulation module through the streaming platform.
在一些示例性实施方式中,评估每个分组的AI模型所需的视频文件存储于媒体文件库中。In some example embodiments, the video files required to evaluate the AI model for each group are stored in a media file library.
本公开实施例还提供了一种控制器,包括存储器;和耦接至所述存储器的处理器,所述处理器被配置为基于存储在所述存储器中的指令,执行如本公开任一实施例所述的AI模型构建评估方法的步骤。An embodiment of the present disclosure also provides a controller, including a memory; and a processor coupled to the memory, the processor being configured to execute any implementation of the present disclosure based on instructions stored in the memory. The steps of the AI model construction and evaluation method described in the example.
在一个示例中,控制器可以包括:第一处理器、第一存储器和第一总线系统,其中,第一处理器和第一存储器通过第一总线系统相连,第一存储器用于存储指令,第一处理器用于执行第一存储器存储的指令。具体地,第一处理器确定模型分组信息;按照分组顺序,对每一分组的AI模型,执行如下操作:构建当前分组的AI模型至测试环境,通知视频流模拟模块将评估当前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台,通知AI能力评估模块使用流媒体平台的视频流对当前分组的AI模型进行AI能力评估,待能力评估完成后,通知视频流模拟模块与流媒体平台释放视频流。In one example, the controller may include: a first processor, a first memory and a first bus system, wherein the first processor and the first memory are connected through the first bus system, the first memory is used to store instructions, and the first bus system is used to store instructions. A processor is used to execute instructions stored in the first memory. Specifically, the first processor determines the model grouping information; according to the grouping order, performs the following operations for the AI model of each group: builds the AI model of the current group to the test environment, and notifies the video stream simulation module to evaluate the AI model of the current group The video stream content of the required video file is pushed to the streaming media platform, and the AI capability assessment module is notified to use the video stream of the streaming media platform to evaluate the AI capabilities of the current grouped AI model. After the capability assessment is completed, the video stream simulation module is notified and Streaming platforms unleash video streaming.
应理解,第一处理器可以是中央处理单元(Central Processing Unit,CPU),第一处理器还可以是其他通用处理器、数字信号处理器(DSP)、专用集成电路(ASIC)、现成可编程门阵列(FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。It should be understood that the first processor can be a central processing unit (Central Processing Unit, CPU), and the first processor can also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASICs), off-the-shelf programmable processors, etc. Gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc.
第一存储器可以包括只读存储器和随机存取存储器,并向第一处理器提供指令和数据。第一存储器的一部分还可以包括非易失性随机存取存储器。例如,第一存储器还可以存储设备类型的信息。The first memory may include read-only memory and random access memory and provide instructions and data to the first processor. A portion of the first memory may also include non-volatile random access memory. For example, the first memory may also store device type information.
第一总线系统除包括数据总线之外,还可以包括电源总线、控制总线和状态信号总线等。In addition to the data bus, the first bus system may also include a power bus, a control bus, a status signal bus, etc.
在实现过程中,处理设备所执行的处理可以通过第一处理器中的硬件的集成逻辑电路或者软件形式的指令完成。即本公开实施例的方法步骤可以体现为硬件处理器执行完成,或者用处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器,闪存、只读存储器,可编程只读存储器或者电可擦写可编程存储器、寄存器等存储介质中。该存储介质位于第一存储器,第一处理器读取第一存储器中的信息,结合其硬件完成上述方法的步骤。为避免重复,这里不再详细描述。During implementation, the processing performed by the processing device may be completed by instructions in the form of hardware integrated logic circuits or software in the first processor. That is to say, the method steps of the embodiments of the present disclosure may be implemented by a hardware processor, or may be executed by a combination of hardware and software modules in the processor. Software modules can be located in random access memory, flash memory, read-only memory, programmable read-only memory or electrically erasable programmable memory, registers and other storage media. The storage medium is located in the first memory, and the first processor reads the information in the first memory and completes the steps of the above method in combination with its hardware. To avoid repetition, it will not be described in detail here.
本公开实施例还提供了一种存储介质,其上存储有计算机程序,该程序 被处理器执行时实现如本公开任一实施例所述的AI模型构建评估方法。该AI模型构建评估方法可以确定模型分组信息;按照分组顺序,对每一分组的AI模型,执行如下操作:构建当前分组的AI模型至测试环境,通知视频流模拟模块将评估当前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台,通知AI能力评估模块使用流媒体平台的视频流对当前分组的AI模型进行AI能力评估,待能力评估完成后,通知视频流模拟模块与流媒体平台释放视频流,由于不需要始终保持所有AI模型的视频流,不但解决了视频流环境大量资源浪费的问题,使得AI模型DevOps环境所需计算资源大幅降低,同时使得模型评估过程变得更加可控,提升了AI技术研发效率,降低了成本。通过执行可执行指令驱动AI模型构建评估的方法与本公开上述实施例提供的AI模型构建评估方法基本相同,在此不做赘述。Embodiments of the present disclosure also provide a storage medium on which a computer program is stored. When the program is executed by a processor, the AI model construction and evaluation method described in any embodiment of the present disclosure is implemented. This AI model construction and evaluation method can determine model grouping information; according to the grouping order, perform the following operations for the AI model of each group: build the AI model of the current group to the test environment, and notify the video stream simulation module to evaluate the AI model of the current group The video stream content of the required video file is pushed to the streaming media platform, and the AI capability assessment module is notified to use the video stream of the streaming media platform to evaluate the AI capabilities of the current grouped AI model. After the capability assessment is completed, the video stream simulation module is notified and The streaming media platform releases video streams. Since there is no need to maintain the video streams of all AI models at all times, it not only solves the problem of wasting a lot of resources in the video streaming environment, but also significantly reduces the computing resources required in the DevOps environment of the AI models, and also makes the model evaluation process easier. It is more controllable, improves the efficiency of AI technology research and development, and reduces costs. The method of driving AI model construction and evaluation by executing executable instructions is basically the same as the AI model construction and evaluation method provided by the above embodiments of the present disclosure, and will not be described again here.
如图8所示,本公开实施例还提供了一种视频流模拟方法,包括:As shown in Figure 8, an embodiment of the present disclosure also provides a video stream simulation method, including:
步骤801、视频流模拟模块接收评估当前分组的AI模型所需的视频文件地址列表;Step 801: The video stream simulation module receives a list of video file addresses required to evaluate the AI model of the current group;
步骤802、视频流模拟模块从视频文件地址列表拉取相应的视频文件,并推送所述视频文件的视频流内容至流媒体平台,通知控制器流媒体环境构建完成;Step 802: The video stream simulation module pulls the corresponding video file from the video file address list, and pushes the video stream content of the video file to the streaming media platform, notifying the controller that the streaming media environment is completed;
步骤803、视频流模拟模块接收控制器的释放指令,停止推送所述视频流内容;Step 803: The video stream simulation module receives the release instruction from the controller and stops pushing the video stream content;
步骤804、视频流模拟模块向流媒体平台发送视频流释放指令。Step 804: The video stream simulation module sends a video stream release instruction to the streaming media platform.
在Devops模型评估过程中,如果投入大量资源同时模拟多个视频流,根据请求的需要进行启停,这种视频流模拟方法虽然研发难度比较小,但是所需资源多,Devops环境要求高,所使用的大量CPU与内存计算资源大量浪费。本公开实施例的视频流模拟方法,通过对AI模型进行分组,对当前分组的AI模型按需提供评估所需的流媒体服务,在模型评估完成后,释放视频流,不需要始终保持所有AI模型的视频流,不但解决了视频流环境大量资源浪费的问题,使得AI模型DevOps环境所需计算资源大幅降低,同时 使得模型评估过程变得更加可控,提升了AI技术研发效率,降低了成本。During the Devops model evaluation process, if a large amount of resources are invested in simulating multiple video streams at the same time and starting and stopping according to the needs of the request, although this video stream simulation method is relatively easy to develop, it requires a lot of resources and the Devops environment requirements are high, so The large amount of CPU and memory computing resources used is greatly wasted. The video stream simulation method of the embodiment of the present disclosure provides streaming services required for evaluation on demand by grouping AI models. After the model evaluation is completed, the video stream is released, and there is no need to keep all AI models at all times. The video stream of the model not only solves the problem of wasting a lot of resources in the video streaming environment, but also greatly reduces the computing resources required in the DevOps environment of the AI model. It also makes the model evaluation process more controllable, improves the efficiency of AI technology research and development, and reduces costs. .
在实际应用过程中,视频源可以是摄像头,摄像头向流媒体平台推流;AI推理平台从流媒体平台拉流,流媒体平台处于中间,相当于一个转发的功能,相当于AI推理平台通过流媒体平台与摄像头建立连接。而在系统构建评估过程中,视频源是视频流模拟模块,视频流模拟模块向流媒体平台推流;AI推理平台从流媒体平台拉流,流媒体平台处于中间,AI推理平台通过流媒体平台与视频流模拟模块建立连接。In actual application, the video source can be a camera, and the camera pushes the stream to the streaming media platform; the AI inference platform pulls the stream from the streaming media platform, and the streaming media platform is in the middle, equivalent to a forwarding function, which is equivalent to the AI inference platform passing the stream The media platform establishes a connection with the camera. During the system construction and evaluation process, the video source is the video stream simulation module, which pushes streams to the streaming media platform; the AI inference platform pulls streams from the streaming media platform, the streaming media platform is in the middle, and the AI inference platform passes the streaming media platform Establish a connection with the video streaming simulation module.
在一些示例性实施方式中,评估每个分组的AI模型所需的视频文件存储于媒体文件库中,视频流模拟模块从所述媒体文件库拉取相应的视频文件。In some exemplary embodiments, the video files required to evaluate the AI model of each group are stored in a media file library, and the video stream simulation module pulls the corresponding video files from the media file library.
在一些示例性实施方式中,视频流模拟模块将视频文件的视频流内容推送至流媒体平台进行循环提供。In some exemplary implementations, the video stream simulation module pushes the video stream content of the video file to the streaming media platform for cyclic provision.
本公开实施例中,视频流模拟模块将视频文件的视频流内容推送至流媒体平台进行循环提供,包含以下两种情况中的任意一种:1)视频流模拟模块将视频文件的视频流内容循环地推送至流媒体平台,以使得流媒体平台循环地提供视频文件的视频流;2)视频流模拟模块将视频文件的视频流内容推送至流媒体平台(仅推送一次),但流媒体平台循环地提供视频文件的视频流。In this disclosed embodiment, the video stream simulation module pushes the video stream content of the video file to the streaming media platform for cyclic provision, including any of the following two situations: 1) The video stream simulation module pushes the video stream content of the video file to Cyclically pushed to the streaming media platform, so that the streaming media platform cyclically provides the video stream of the video file; 2) The video stream simulation module pushes the video stream content of the video file to the streaming media platform (only pushed once), but the streaming media platform Provides a video stream of video files in a loop.
本公开实施例还提供了一种视频流模拟模块,包括存储器;和耦接至所述存储器的处理器,所述处理器被配置为基于存储在所述存储器中的指令,执行如本公开任一实施例所述的视频流模拟方法的步骤。Embodiments of the present disclosure also provide a video stream simulation module, including a memory; and a processor coupled to the memory, the processor being configured to execute any of the instructions of the present disclosure based on instructions stored in the memory. The steps of the video stream simulation method according to an embodiment.
在一个示例中,视频流模拟模块可以包括:第二处理器、第二存储器和第二总线系统,其中,第二处理器和第二存储器通过第二总线系统相连,第二存储器用于存储指令,第二处理器用于执行第二存储器存储的指令。具体地,第二处理器接收评估当前分组的AI模型所需的视频文件地址列表,从视频文件地址列表拉取相应的视频文件,并推送所述视频文件的视频流内容至流媒体平台,通知控制器流媒体环境构建完成;接收所述控制器的释放指令,停止推送所述视频流内容,向流媒体平台发送视频流释放指令。In one example, the video stream simulation module may include: a second processor, a second memory, and a second bus system, wherein the second processor and the second memory are connected through the second bus system, and the second memory is used to store instructions. , the second processor is used to execute instructions stored in the second memory. Specifically, the second processor receives the video file address list required to evaluate the AI model of the current group, pulls the corresponding video file from the video file address list, and pushes the video stream content of the video file to the streaming media platform, notifying The construction of the controller streaming media environment is completed; it receives the release instruction of the controller, stops pushing the video stream content, and sends the video stream release instruction to the streaming media platform.
应理解,第二处理器可以是中央处理单元(Central Processing Unit,CPU),第二处理器还可以是其他通用处理器、数字信号处理器(DSP)、专用集成 电路(ASIC)、现成可编程门阵列(FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。It should be understood that the second processor can be a central processing unit (Central Processing Unit, CPU). The second processor can also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASICs), off-the-shelf programmable processors, etc. Gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc.
第二存储器可以包括只读存储器和随机存取存储器,并向第二处理器提供指令和数据。第二存储器的一部分还可以包括非易失性随机存取存储器。例如,第二存储器还可以存储设备类型的信息。The second memory may include read-only memory and random access memory and provide instructions and data to the second processor. A portion of the second memory may also include non-volatile random access memory. For example, the second memory may also store device type information.
第二总线系统除包括数据总线之外,还可以包括电源总线、控制总线和状态信号总线等。In addition to the data bus, the second bus system may also include a power bus, a control bus, a status signal bus, etc.
在实现过程中,处理设备所执行的处理可以通过第二处理器中的硬件的集成逻辑电路或者软件形式的指令完成。即本公开实施例的方法步骤可以体现为硬件处理器执行完成,或者用处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器,闪存、只读存储器,可编程只读存储器或者电可擦写可编程存储器、寄存器等存储介质中。该存储介质位于第二存储器,第二处理器读取第二存储器中的信息,结合其硬件完成上述方法的步骤。为避免重复,这里不再详细描述。During implementation, the processing performed by the processing device may be completed by instructions in the form of hardware integrated logic circuits or software in the second processor. That is to say, the method steps of the embodiments of the present disclosure may be implemented by a hardware processor, or may be executed by a combination of hardware and software modules in the processor. Software modules can be located in random access memory, flash memory, read-only memory, programmable read-only memory or electrically erasable programmable memory, registers and other storage media. The storage medium is located in the second memory, and the second processor reads the information in the second memory and completes the steps of the above method in combination with its hardware. To avoid repetition, it will not be described in detail here.
本公开实施例还提供了一种存储介质,其上存储有计算机程序,该程序被处理器执行时实现如本公开任一实施例所述的视频流模拟方法。该视频流模拟方法可以接收评估当前分组的AI模型所需的视频文件地址列表,从所述视频文件地址列表拉取相应的视频文件,并推送所述视频文件的视频流内容至流媒体平台,通知控制器流媒体环境构建完成;接收所述控制器的释放指令,停止推送所述视频流内容,向所述流媒体平台发送视频流释放指令,不需要始终保持所有AI模型的视频流,不但解决了视频流环境大量资源浪费的问题,使得AI模型DevOps环境所需计算资源大幅降低,同时使得模型评估过程变得更加可控,提升了AI技术研发效率,降低了成本。通过执行可执行指令驱动视频流模拟的方法与本公开上述实施例提供的视频流模拟方法基本相同,在此不做赘述。An embodiment of the present disclosure also provides a storage medium on which a computer program is stored. When the program is executed by a processor, the video stream simulation method as described in any embodiment of the present disclosure is implemented. The video stream simulation method can receive a video file address list required to evaluate the current grouped AI model, pull the corresponding video file from the video file address list, and push the video stream content of the video file to the streaming media platform, Notify the controller that the construction of the streaming media environment is completed; receive the release instruction from the controller, stop pushing the video stream content, and send the video stream release instruction to the streaming media platform. There is no need to maintain the video streams of all AI models at all times. It solves the problem of a large amount of resource waste in the video streaming environment, greatly reduces the computing resources required in the DevOps environment of the AI model, and makes the model evaluation process more controllable, improving the efficiency of AI technology research and development and reducing costs. The method of driving video stream simulation by executing executable instructions is basically the same as the video stream simulation method provided by the above embodiments of the present disclosure, and will not be described again here.
本领域普通技术人员可以理解,上文中所公开方法中的全部或某些步骤、系统、装置中的功能模块/单元可以被实施为软件、固件、硬件及其适当的组合。在硬件实施方式中,在以上描述中提及的功能模块/单元之间的划分不一 定对应于物理组件的划分;例如,一个物理组件可以具有多个功能,或者一个功能或步骤可以由若干物理组件合作执行。某些组件或所有组件可以被实施为由处理器,如数字信号处理器或微处理器执行的软件,或者被实施为硬件,或者被实施为集成电路,如专用集成电路。这样的软件可以分布在计算机可读介质上,计算机可读介质可以包括计算机存储介质(或非暂时性介质)和通信介质(或暂时性介质)。如本领域普通技术人员公知的,术语计算机存储介质包括在用于存储信息(诸如计算机可读指令、数据结构、程序模块或其他数据)的任何方法或技术中实施的易失性和非易失性、可移除和不可移除介质。计算机存储介质包括但不限于RAM、ROM、EEPROM、闪存或其他存储器技术、CD-ROM、数字多功能盘(DVD)或其他光盘存储、磁盒、磁带、磁盘存储或其他磁存储装置、或者可以用于存储期望的信息并且可以被计算机访问的任何其他的介质。此外,本领域普通技术人员公知的是,通信介质通常包含计算机可读指令、数据结构、程序模块或者诸如载波或其他传输机制之类的调制数据信号中的其他数据,并且可包括任何信息递送介质。Those of ordinary skill in the art can understand that all or some steps, systems, and functional modules/units in the devices disclosed above can be implemented as software, firmware, hardware, and appropriate combinations thereof. In hardware implementations, the division between functional modules/units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may consist of several physical components. Components execute cooperatively. Some or all of the components may be implemented as software executed by a processor, such as a digital signal processor or a microprocessor, or as hardware, or as an integrated circuit, such as an application specific integrated circuit. Such software may be distributed on computer-readable media, which may include computer storage media (or non-transitory media) and communication media (or transitory media). As is known to those of ordinary skill in the art, the term computer storage media includes volatile and nonvolatile media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. removable, removable and non-removable media. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, Digital Versatile Disk (DVD) or other optical disk storage, magnetic cassettes, tapes, disk storage or other magnetic storage devices, or may Any other medium used to store the desired information and that can be accessed by a computer. Additionally, it is known to those of ordinary skill in the art that communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media .
虽然本公开所揭露的实施方式如上,但所述的内容仅为便于理解本公开而采用的实施方式,并非用以限定本发明。任何所属领域内的技术人员,在不脱离本公开所揭露的精神和范围的前提下,可以在实施的形式及细节上进行任何的修改与变化,但本发明的专利保护范围,仍须以所附的权利要求书所界定的范围为准。Although the embodiments disclosed in the present disclosure are as above, the described contents are only used to facilitate the understanding of the present disclosure and are not intended to limit the present invention. Any person skilled in the art can make any modifications and changes in the form and details of the implementation without departing from the spirit and scope of the disclosure. However, the patent protection scope of the present invention must still be based on the above. The scope defined by the appended claims shall prevail.

Claims (24)

  1. 一种AI模型构建评估系统,包括:控制器和模拟测评模块,其中:An AI model construction and evaluation system includes: a controller and a simulation evaluation module, wherein:
    所述控制器,被配置为确定AI模型的分组信息;按照分组顺序,对每一分组的AI模型,执行如下操作:构建当前分组的AI模型至测试环境,发送第一通知至模拟测评模块;The controller is configured to determine the grouping information of the AI model; according to the grouping order, perform the following operations for the AI model of each group: construct the AI model of the current group to the test environment, and send the first notification to the simulation evaluation module;
    所述模拟测评模块,被配置为接收到控制器的第一通知,向所述AI模型提供视频流服务,所述视频流服务的内容为评估当前分组的AI模型所需的视频文件的视频流内容;对当前分组的AI模型进行AI能力评估;待能力评估完成后,释放所述视频流。The simulation evaluation module is configured to receive a first notification from the controller and provide a video streaming service to the AI model. The content of the video streaming service is a video stream of video files required to evaluate the AI model of the current group. Content; perform AI capability assessment on the currently grouped AI model; release the video stream after the capability assessment is completed.
  2. 根据权利要求1所述的AI模型构建评估系统,其中,所述模拟测评模块包括视频流模拟服务器和AI能力评估模块;The AI model construction evaluation system according to claim 1, wherein the simulation evaluation module includes a video stream simulation server and an AI capability evaluation module;
    所述视频流模拟服务器,被配置为接收到控制器的第一通知,向所述AI模型提供视频流服务,所述视频流服务的内容为评估当前分组的AI模型所需的视频文件的视频流内容,发送第二通知至控制器,以使得控制器发送第三通知至AI能力评估模块;接收到控制器的第五通知,释放所述视频流;The video stream simulation server is configured to receive a first notification from the controller and provide a video stream service to the AI model. The content of the video stream service is the video of the video file required to evaluate the AI model of the current group. Stream content, send a second notification to the controller, so that the controller sends a third notification to the AI capability evaluation module; receive a fifth notification from the controller, release the video stream;
    所述AI能力评估模块,被配置为接收到控制器的第三通知,对当前分组的AI模型进行AI能力评估;待能力评估完成后,发送第四通知至控制器,以使得控制器发送第五通知至视频流模拟服务器;The AI capability evaluation module is configured to receive the third notification from the controller, perform an AI capability evaluation on the AI model of the current group; after the capability evaluation is completed, send a fourth notification to the controller, so that the controller sends the third notification. Five notifications to the video streaming simulation server;
    所述控制器,还被配置为接收到所述视频流模拟服务器的第二通知,发送第三通知至所述AI能力评估模块;接收到所述AI能力评估模块的第四通知,发送第五通知至所述视频流模拟服务器。The controller is further configured to receive a second notification from the video stream simulation server and send a third notification to the AI capability assessment module; upon receiving a fourth notification from the AI capability assessment module, send a fifth notification. Notify the video stream simulation server.
  3. 根据权利要求2所述的AI模型构建评估系统,其中,所述视频流模拟服务器包括视频流模拟模块和流媒体平台;The AI model construction evaluation system according to claim 2, wherein the video stream simulation server includes a video stream simulation module and a streaming media platform;
    所述视频流模拟模块,被配置为接收到所述控制器的第一通知,将评估当前分组的AI模型所需的视频文件的视频流内容推送至所述流媒体平台,发送第二通知至所述控制器;接收到所述控制器的第五通知,停止推送视频流内容,并发送第六通知至所述流媒体平台;The video stream simulation module is configured to receive a first notification from the controller, push the video stream content of the video file required to evaluate the AI model of the current group to the streaming media platform, and send a second notification to The controller; receiving the fifth notification from the controller, stops pushing the video stream content, and sends the sixth notification to the streaming media platform;
    所述流媒体平台,被配置为接收所述视频流模拟模块推送的视频流内容,并向AI模型提供视频流服务;接收到所述视频流模拟模块的第六通知,释放视频流。The streaming media platform is configured to receive the video stream content pushed by the video stream simulation module and provide video streaming services to the AI model; and release the video stream upon receiving the sixth notification from the video stream simulation module.
  4. 根据权利要求3所述的AI模型构建评估系统,其中,所述视频流模拟模块将评估当前分组的AI模型所需的视频文件的视频流内容循环地推送至所述流媒体平台,或者,所述流媒体平台循环地提供所述视频文件的视频流内容。The AI model construction evaluation system according to claim 3, wherein the video stream simulation module cyclically pushes the video stream content of the video files required to evaluate the currently grouped AI model to the streaming media platform, or, the The streaming media platform cyclically provides video streaming content of the video file.
  5. 根据权利要求3所述的AI模型构建评估系统,其中,评估每个分组的AI模型所需的视频文件存储于媒体文件库中;The AI model construction evaluation system according to claim 3, wherein the video files required to evaluate the AI model of each group are stored in the media file library;
    所述将评估当前分组的AI模型所需的视频文件的视频流内容推送至所述流媒体平台,包括:从所述媒体文件库拉取所述评估当前分组的AI模型所需的视频文件,并将所述视频文件的视频流内容推送至所述流媒体平台。Pushing the video stream content of the video files required to evaluate the AI model of the current group to the streaming media platform includes: pulling the video files required to evaluate the AI model of the current group from the media file library, and push the video stream content of the video file to the streaming media platform.
  6. 根据权利要求1所述的AI模型构建评估系统,其中,所述确定AI模型的分组信息,包括:The AI model construction evaluation system according to claim 1, wherein the determining the grouping information of the AI model includes:
    获取待构建的多个AI模型的构建脚本;Obtain the construction scripts of multiple AI models to be built;
    根据每个AI模型所消耗的资源对所述待构建的多个AI模型进行分组,每组AI模型所消耗的资源小于所述测试环境所具备的资源。The multiple AI models to be built are grouped according to the resources consumed by each AI model, and the resources consumed by each group of AI models are less than the resources of the test environment.
  7. 根据权利要求1所述的AI模型构建评估系统,其中,所述确定AI模型的分组信息,包括:The AI model construction evaluation system according to claim 1, wherein the determining the grouping information of the AI model includes:
    获取待构建的多个AI模型的构建脚本;Obtain the construction scripts of multiple AI models to be built;
    根据每个AI模型所消耗的资源以及不同AI模型之间的关系对所述待构建的多个AI模型进行分组,每组AI模型所消耗的资源小于所述测试环境所具备的资源,且有依赖关系的AI模型分为一组。The multiple AI models to be built are grouped according to the resources consumed by each AI model and the relationship between different AI models. The resources consumed by each group of AI models are less than the resources of the test environment, and there are Dependent AI models are grouped into a group.
  8. 根据权利要求7所述的AI模型构建评估系统,其中,根据组织所述AI模型运行的策略代码,确定多个所述AI模型之间的依赖关系。The AI model construction evaluation system according to claim 7, wherein dependencies between a plurality of the AI models are determined according to a policy code that organizes the operation of the AI models.
  9. 根据权利要求1所述的AI模型构建评估系统,其中,在发送第一通知至所述模拟测评模块之前,所述控制器还被配置为,对当前分组的AI模型的测试案例进行分组;按照所述测试案例的分组顺序,对每一分组的测试案例,执行所述发送第一通知至所述模拟测评模块的操作。The AI model construction evaluation system according to claim 1, wherein before sending the first notification to the simulation evaluation module, the controller is further configured to group the test cases of the currently grouped AI model; according to In the grouping order of the test cases, the operation of sending the first notification to the simulation evaluation module is performed for each grouped test case.
  10. 根据权利要求9所述的AI模型构建评估系统,其中,所述模拟测评模块包括流媒体平台,所述流媒体平台被配置为向AI模型提供视频流服务;The AI model construction evaluation system according to claim 9, wherein the simulation evaluation module includes a streaming media platform, and the streaming media platform is configured to provide video streaming services to the AI model;
    依据运行所述测试案例所需的视频流消耗的资源对所述当前分组的AI模型的测试案例进行分组,同时运行每组测试案例所需的视频流消耗的资源小于所述流媒体平台的资源。Group the test cases of the currently grouped AI model according to the resources consumed by the video stream required to run the test case, and at the same time, the resources consumed by the video stream required to run each group of test cases are less than the resources of the streaming media platform .
  11. 根据权利要求9所述的AI模型构建评估系统,其中,所述待能力评估完成后,释放所述视频流,具体为:待一个所述视频流对应的测试案例测试完成后,释放所述视频流。The AI model construction evaluation system according to claim 9, wherein the video stream is released after the capability evaluation is completed, specifically: after the test case test corresponding to one of the video streams is completed, the video is released. flow.
  12. 根据权利要求1所述的AI模型构建评估系统,其中,所述构建当前分组的AI模型至测试环境,包括:The AI model construction evaluation system according to claim 1, wherein said constructing the current grouped AI model to the test environment includes:
    拉取所述当前分组的AI模型的模型代码;Pull the model code of the AI model of the current group;
    编译所述当前分组的AI模型的模型代码;Compile the model code of the currently grouped AI model;
    部署所述当前分组的AI模型至测试环境。Deploy the AI model of the current group to a test environment.
  13. 根据权利要求1所述的AI模型构建评估系统,其中,所述AI模型的分组信息、所述AI模型的代码信息、所述AI模型的构建脚本、组织所述AI模型运行的策略代码均存储于代码仓库中。The AI model construction evaluation system according to claim 1, wherein the grouping information of the AI model, the code information of the AI model, the construction script of the AI model, and the strategy code for organizing the operation of the AI model are all stored in the code repository.
  14. 根据权利要求1所述的AI模型构建评估系统,其中,所述控制器还被配置为:将多个AI模型的构建脚本进行整理合并后推送至任务队列,所述任务队列包括:所述AI模型的分组信息、所述AI模型分组的部署顺序。The AI model construction evaluation system according to claim 1, wherein the controller is further configured to: organize and merge the construction scripts of multiple AI models and then push them to a task queue, the task queue includes: the AI The grouping information of the model and the deployment order of the AI model grouping.
  15. 根据权利要求1所述的AI模型构建评估系统,其中,所述控制器还被配置为:当确定所述AI模型的分组信息失败时,发送告警信息或告警邮件;The AI model construction evaluation system according to claim 1, wherein the controller is further configured to: when determining that the grouping information of the AI model fails, send alarm information or an alarm email;
    所述模拟测评模块还被配置为:当向所述AI模型提供视频流服务失败时,发送告警信息或告警邮件。The simulation evaluation module is also configured to: when providing the video streaming service to the AI model fails, send an alarm message or an alarm email.
  16. 一种AI模型构建评估方法,包括:An AI model construction and evaluation method, including:
    控制器确定模型分组信息;The controller determines model grouping information;
    按照分组顺序,对每一分组的AI模型,执行如下操作:According to the grouping order, perform the following operations on the AI model of each group:
    所述控制器构建当前分组的AI模型至测试环境,发送第一通知至模拟测评模块;The controller constructs the AI model of the current group to the test environment, and sends the first notification to the simulation evaluation module;
    所述模拟测评模块接收到所述控制器的第一通知,向所述AI模型提供视频流服务,所述视频流服务的内容为评估当前分组的AI模型所需的视频文件的视频流内容;对当前分组的AI模型进行AI能力评估;待能力评估完成后,释放所述视频流。The simulation evaluation module receives the first notification from the controller and provides a video streaming service to the AI model. The content of the video streaming service is the video streaming content of the video file required to evaluate the AI model of the current group; Perform an AI capability assessment on the currently grouped AI model; after the capability assessment is completed, release the video stream.
  17. 一种AI模型构建评估方法,包括:An AI model construction and evaluation method, including:
    控制器确定模型分组信息;The controller determines model grouping information;
    所述控制器按照分组顺序,对每一分组的AI模型,执行如下操作:构建当前分组的AI模型至测试环境,通知视频流模拟模块将评估当前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台,通知AI能力评估模块使用所述流媒体平台的视频流对当前分组的AI模型进行AI能力评估,待能力评估完成后,通知视频流模拟模块与流媒体平台释放视频流。The controller performs the following operations on the AI model of each group in accordance with the grouping order: constructs the AI model of the current group to the test environment, and notifies the video stream simulation module to evaluate the video stream of the video file required for the AI model of the current group. The content is pushed to the streaming media platform, and the AI capability evaluation module is notified to use the video stream of the streaming media platform to evaluate the AI capability of the current grouped AI model. After the capability assessment is completed, the video stream simulation module and the streaming media platform are notified to release the video stream. .
  18. 根据权利要求17所述的AI模型构建评估方法,其中,所述通知视频流模拟模块将评估当前分组的AI模型所需的视频文件的视频流内容推送至流媒体平台,通知AI能力评估模块使用所述流媒体平台的视频流对当前分组的AI模型进行AI能力评估,待能力评估完成后,通知视频流模拟模块与流媒体平台释放所述视频流,包括:The AI model construction and evaluation method according to claim 17, wherein the notification video stream simulation module pushes the video stream content of the video file required to evaluate the currently grouped AI model to the streaming media platform, and notifies the AI capability evaluation module to use The video stream of the streaming media platform performs an AI capability assessment on the currently grouped AI model. After the capability assessment is completed, the video stream simulation module and the streaming media platform are notified to release the video stream, including:
    对当前分组的AI模型的测试案例进行分组;Group the test cases of the currently grouped AI model;
    按照分组顺序,对每一分组的测试案例,执行如下操作:通知视频流模拟模块将当前分组的测试案例所需的视频文件的视频流内容推送至流媒体平 台,以在所述流媒体平台上形成可供所述AI模型拉取的视频流;通知AI能力评估模块使用所述流媒体平台的视频流对每一分组的测试案例进行测试,待测试案例测试完成后,通知视频流模拟模块停止推送所述视频流内容,并由所述视频流模拟模块通知所述流媒体平台释放所述视频流。According to the grouping order, perform the following operations for each grouped test case: notify the video stream simulation module to push the video stream content of the video file required for the current grouped test case to the streaming media platform, so that it can be displayed on the streaming media platform. Form a video stream that can be pulled by the AI model; notify the AI capability evaluation module to use the video stream of the streaming media platform to test the test cases of each group. After the test case test is completed, notify the video stream simulation module to stop The video stream content is pushed, and the video stream simulation module notifies the streaming media platform to release the video stream.
  19. 一种控制器,包括存储器;和耦接至所述存储器的处理器,所述处理器被配置为基于存储在所述存储器中的指令,执行如权利要求17至18中任一项所述的AI模型构建评估方法的步骤。A controller comprising a memory; and a processor coupled to the memory, the processor configured to execute the method of any one of claims 17 to 18 based on instructions stored in the memory Steps of AI model construction and evaluation methods.
  20. 一种存储介质,其上存储有计算机程序,该程序被处理器执行时实现如权利要求17至18中任一项所述的AI模型构建评估方法。A storage medium with a computer program stored thereon, which when executed by a processor implements the AI model construction and evaluation method according to any one of claims 17 to 18.
  21. 一种视频流模拟方法,包括:A video stream simulation method, including:
    视频流模拟模块接收评估当前分组的AI模型所需的视频文件地址列表;The video stream simulation module receives a list of video file addresses required to evaluate the AI model of the current group;
    视频流模拟模块从所述视频文件地址列表拉取相应的视频文件,并将所述视频文件的视频流内容推送至流媒体平台,通知控制器流媒体环境构建完成;The video stream simulation module pulls the corresponding video file from the video file address list, pushes the video stream content of the video file to the streaming media platform, and notifies the controller that the streaming media environment is completed;
    视频流模拟模块接收所述控制器的释放指令,停止推送所述视频流内容;The video stream simulation module receives the release instruction of the controller and stops pushing the video stream content;
    视频流模拟模块向所述流媒体平台发送视频流释放指令。The video stream simulation module sends a video stream release instruction to the streaming media platform.
  22. 根据权利要求21所述的视频流模拟方法,其中,所述视频流模拟模块将所述视频文件的视频流内容循环地推送至所述流媒体平台,或者,流媒体平台循环地提供所述视频文件的视频流内容。The video stream simulation method according to claim 21, wherein the video stream simulation module cyclically pushes the video stream content of the video file to the streaming media platform, or the streaming media platform cyclically provides the video The video stream content of the file.
  23. 一种视频流模拟模块,包括存储器;和耦接至所述存储器的处理器,所述处理器被配置为基于存储在所述存储器中的指令,执行如权利要求21至22中任一项所述的视频流模拟方法的步骤。A video stream simulation module comprising a memory; and a processor coupled to the memory, the processor being configured to execute as claimed in any one of claims 21 to 22 based on instructions stored in the memory The steps of the video stream simulation method described above.
  24. 一种存储介质,其上存储有计算机程序,该程序被处理器执行时实现如权利要求21至22中任一项所述的视频流模拟方法。A storage medium on which a computer program is stored, which implements the video stream simulation method as claimed in any one of claims 21 to 22 when executed by a processor.
PCT/CN2022/102783 2022-06-30 2022-06-30 Ai model establishment evaluation system, video stream simulation module and method, and controller WO2024000387A1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202280002046.XA CN117642728A (en) 2022-06-30 2022-06-30 AI model construction evaluation system, video stream simulation module and method, and controller
PCT/CN2022/102783 WO2024000387A1 (en) 2022-06-30 2022-06-30 Ai model establishment evaluation system, video stream simulation module and method, and controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2022/102783 WO2024000387A1 (en) 2022-06-30 2022-06-30 Ai model establishment evaluation system, video stream simulation module and method, and controller

Publications (1)

Publication Number Publication Date
WO2024000387A1 true WO2024000387A1 (en) 2024-01-04

Family

ID=89383532

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/102783 WO2024000387A1 (en) 2022-06-30 2022-06-30 Ai model establishment evaluation system, video stream simulation module and method, and controller

Country Status (2)

Country Link
CN (1) CN117642728A (en)
WO (1) WO2024000387A1 (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180357543A1 (en) * 2016-01-27 2018-12-13 Bonsai AI, Inc. Artificial intelligence system configured to measure performance of artificial intelligence over time
CN111626319A (en) * 2019-02-27 2020-09-04 英特尔公司 Misuse indicator interpretable of artificial intelligence in a computing environment
CN112304952A (en) * 2019-07-23 2021-02-02 纬创资通股份有限公司 Image recognition device, image recognition method and computer program product thereof
CN112416753A (en) * 2020-11-02 2021-02-26 中关村科学城城市大脑股份有限公司 Method, system and equipment for standardized management of urban brain application scene data
CN113923441A (en) * 2020-07-08 2022-01-11 钉钉控股(开曼)有限公司 Video quality evaluation method and device and electronic equipment
CN114004328A (en) * 2020-07-27 2022-02-01 华为技术有限公司 AI model updating method, device, computing equipment and storage medium
CN114492764A (en) * 2022-02-21 2022-05-13 深圳市商汤科技有限公司 Artificial intelligence model testing method and device, electronic equipment and storage medium
CN114610271A (en) * 2020-11-25 2022-06-10 共达地创新技术(深圳)有限公司 AI model customization method, electronic device and computer-readable storage medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180357543A1 (en) * 2016-01-27 2018-12-13 Bonsai AI, Inc. Artificial intelligence system configured to measure performance of artificial intelligence over time
CN111626319A (en) * 2019-02-27 2020-09-04 英特尔公司 Misuse indicator interpretable of artificial intelligence in a computing environment
CN112304952A (en) * 2019-07-23 2021-02-02 纬创资通股份有限公司 Image recognition device, image recognition method and computer program product thereof
CN113923441A (en) * 2020-07-08 2022-01-11 钉钉控股(开曼)有限公司 Video quality evaluation method and device and electronic equipment
CN114004328A (en) * 2020-07-27 2022-02-01 华为技术有限公司 AI model updating method, device, computing equipment and storage medium
CN112416753A (en) * 2020-11-02 2021-02-26 中关村科学城城市大脑股份有限公司 Method, system and equipment for standardized management of urban brain application scene data
CN114610271A (en) * 2020-11-25 2022-06-10 共达地创新技术(深圳)有限公司 AI model customization method, electronic device and computer-readable storage medium
CN114492764A (en) * 2022-02-21 2022-05-13 深圳市商汤科技有限公司 Artificial intelligence model testing method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN117642728A (en) 2024-03-01

Similar Documents

Publication Publication Date Title
US10909028B1 (en) Multi-version regression tester for source code
US10067863B1 (en) Feature targeting of test automation lab machines
CN110795219A (en) Resource scheduling method and system suitable for multiple computing frameworks
WO2019029160A1 (en) Application construction method and system, computer device, and storage medium
US20180322037A1 (en) Impersonation in test automation
US8978009B2 (en) Discovering whether new code is covered by tests
US11982999B2 (en) Defect detection task processing method, device, apparatus and storage medium
CN110389903B (en) Test environment deployment method and device, electronic equipment and readable storage medium
CN108897557B (en) Updating method and device of microservice architecture
US20210240457A1 (en) Offload server and offload program
US20180322038A1 (en) Segmenting user population to manage dynamic software quality
US20210294730A1 (en) Managing resources used during a development pipeline
CN109992509A (en) The automated execution method, apparatus of test case, electronic equipment
CN114430385B (en) Network equipment detection method and device and electronic equipment
US11194699B2 (en) Compatibility testing with different environment configurations
CN110532182A (en) A kind of automated testing method and device of virtual platform
WO2024000387A1 (en) Ai model establishment evaluation system, video stream simulation module and method, and controller
CN111147541A (en) Node processing method, device and equipment based on parameter server and storage medium
CN107193582B (en) Publishing method and system
CN112860548A (en) Code automatic detection method and device, electronic equipment and storage medium
US20120159445A1 (en) Aspect and system landscape capability-driven automatic testing of software applications
CN110362471A (en) Test case processing method, system, terminal and storage medium
CN111448547A (en) Method for executing and converting a computer program in a computer network, in particular for controlling a microscope
CN113535560B (en) Test execution method, device, storage medium and computing equipment
US20220019522A1 (en) Automated sequencing of software tests using dependency information

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22948496

Country of ref document: EP

Kind code of ref document: A1