Method and apparatus for determining execution order, storage medium, and electronic device
By determining the dependencies and processing speeds between algorithms and adjusting the execution order, a combination of parallel and serial algorithms is achieved, solving the problem of low processing efficiency caused by the sequential execution of multiple algorithm tasks and improving processing efficiency and throughput.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- ZHEJIANG DAHUA TECH CO LTD
- Filing Date
- 2020-06-19
- Publication Date
- 2026-06-30
AI Technical Summary
In existing technologies, the sequential execution of multiple algorithm tasks leads to low processing efficiency.
By identifying the dependencies between algorithms, determining the execution order, processing algorithms with dependencies in parallel, and adjusting the execution order according to processing speed, a combination of parallel and serial algorithms can be achieved.
It improves the efficiency of algorithm processing, and enhances the throughput and performance of algorithm processing.
Smart Images

Figure CN111737075B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of surveillance, and more specifically, to a method and apparatus for determining the execution order, a storage medium, and an electronic device. Background Technology
[0002] In the field of video surveillance products, there are often multiple services, and each service contains multiple sub-algorithms. A related technology provides an "Algorithm Integration Framework and Method", which mainly solves the problem of how to quickly complete the system integration and debugging of algorithms, including parameter input, result export and distributed computing scheduling. Its function is to quickly achieve algorithm integration, but its main drawback is that the algorithm processing solutions mentioned in the video surveillance field are relatively general and the algorithm processing efficiency is low.
[0003] In the relevant technologies, for multiple algorithms for a task (containing multiple subtasks), multiple algorithms are simply executed sequentially, which leads to low processing efficiency during the execution of multiple algorithms. No effective technical solution has yet been proposed. Summary of the Invention
[0004] This invention provides a method, apparatus, storage medium, and electronic device for determining the execution order, to at least solve the problem in related technologies where multiple algorithms for a task (containing multiple subtasks) are executed sequentially, resulting in low processing efficiency during the execution of multiple algorithms.
[0005] This invention provides a method for determining the execution order, comprising: obtaining the dependency relationship between any two algorithms among a plurality of algorithms, wherein the plurality of algorithms are used to execute a target business, and the dependency relationship is used to indicate whether the result of one algorithm is used for another algorithm; and determining the execution order of the plurality of algorithms based on the dependency relationship.
[0006] In this embodiment of the invention, determining the execution order of the plurality of algorithms based on the dependency relationship includes: for any one of the plurality of algorithms, obtaining a first target algorithm that has a dependency relationship with the first target algorithm and a second target algorithm that does not have a dependency relationship with the first target algorithm; and branching the processing flow of the first target algorithm so that after the first target algorithm is completed, the first target algorithm and the second target algorithm are executed in parallel.
[0007] In this embodiment of the invention, the processing flow of any one of the algorithms is branched so that after the first target algorithm and the second target algorithm are executed in parallel, the method further includes: obtaining a third target algorithm that has a dependency relationship with the first target algorithm and a fourth target algorithm that does not have a dependency relationship with the third target algorithm; and branching the processing flow of the first target algorithm so that after the first target algorithm is executed, the third target algorithm and the fourth target algorithm are executed in parallel.
[0008] In this embodiment of the invention, determining the execution order of the plurality of algorithms based on the dependency relationship includes: obtaining the processing speed of each of the plurality of algorithms; and determining the execution order of the plurality of algorithms based on the processing speed of each algorithm and the dependency relationship.
[0009] In this embodiment of the invention, determining the execution order of the plurality of algorithms based on the processing speed of each algorithm and the dependency relationship includes: for any two algorithms that have a dependency relationship, obtaining a second target algorithm with a faster processing speed and a third target algorithm with a slower processing speed; and setting the execution order of the second target algorithm earlier than the execution order of the third target algorithm.
[0010] According to another aspect of the present invention, an apparatus for determining the execution order is also provided, comprising: an acquisition module, configured to acquire a dependency relationship between any two algorithms among a plurality of algorithms, wherein the plurality of algorithms are used to perform a target business, and the dependency relationship is used to indicate whether the result of one algorithm is used for the other algorithm; and a determination module, configured to determine the execution order of the plurality of algorithms based on the dependency relationship.
[0011] In this embodiment of the invention, the determining module is further configured to, for any one of the plurality of algorithms, obtain a first target algorithm that has a dependency relationship with the first target algorithm and a second target algorithm that does not have a dependency relationship with the first target algorithm; and to perform branch processing on the processing flow of the first target algorithm so that after the first target algorithm is executed, the first target algorithm and the second target algorithm are executed in parallel.
[0012] In this embodiment of the invention, the determining module is further configured to obtain the processing speed of each of the plurality of algorithms; and determine the execution order of the plurality of algorithms based on the processing speed of each algorithm and the dependency relationship.
[0013] According to yet another embodiment of the present invention, a storage medium is also provided, wherein a computer program is stored therein, wherein the computer program is configured to execute the steps in any of the above method embodiments when running.
[0014] According to yet another embodiment of the present invention, an electronic device is also provided, including a memory and a processor, wherein the memory stores a computer program and the processor is configured to run the computer program to perform the steps in any of the above method embodiments.
[0015] This invention obtains the dependency relationship between any two algorithms from a plurality of algorithms, wherein the plurality of algorithms are used to execute a target business, and the dependency relationship is used to indicate whether the result of one algorithm is used in another algorithm; the execution order of the plurality of algorithms is determined according to the dependency relationship. By adopting the above technical solution, the problem in related technologies is solved, where for multiple algorithms of a task (including multiple subtasks), multiple algorithms are simply executed sequentially, resulting in low processing efficiency during the execution of multiple algorithms. Furthermore, for multiple algorithms, the execution process can be adjusted according to the dependency relationship, thereby improving the processing efficiency of the algorithms. Attached Figure Description
[0016] The accompanying drawings, which are included to provide a further understanding of the invention and form part of this application, illustrate exemplary embodiments of the invention and, together with their description, serve to explain the invention and do not constitute an undue limitation thereof. In the drawings:
[0017] Figure 1 A flowchart illustrating a method for determining the execution order according to an embodiment of the present invention;
[0018] Figure 2 This is a flowchart illustrating the method for determining the execution order according to an optional embodiment of the present invention;
[0019] Figure 3 This is a flowchart illustrating the method for determining the execution order according to an optional embodiment two of the present invention;
[0020] Figure 4 This is a structural block diagram of an execution order determination device according to an embodiment of the present invention. Detailed Implementation
[0021] The present invention will be described in detail below with reference to the accompanying drawings and embodiments. It should be noted that, unless otherwise specified, the embodiments and features described in the present application can be combined with each other.
[0022] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate for the embodiments of this application described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0023] According to one embodiment of the present invention, a method for determining the execution order is provided. Figure 1 A flowchart of a method for determining the execution order according to an embodiment of the present invention is shown below. Figure 1 As shown, it includes:
[0024] Step S102: Obtain the dependency relationship between any two algorithms among a plurality of algorithms, wherein the plurality of algorithms are used to execute the target business, and the dependency relationship is used to indicate whether the result of one algorithm is used for another algorithm among any two algorithms;
[0025] Step S104: Determine the execution order of the multiple algorithms based on the dependency relationship.
[0026] This invention obtains the dependency relationship between any two algorithms among multiple algorithms, wherein the multiple algorithms are used to execute a target business, and the dependency relationship is used to indicate whether the result of one algorithm is used in another algorithm; the execution order of the multiple algorithms is determined according to the dependency relationship. By adopting the above technical solution, the problem in related technologies is that for multiple algorithms of a task (containing multiple subtasks), multiple algorithms are simply executed sequentially, resulting in low processing efficiency during the execution of multiple algorithms. Therefore, for multiple algorithms, the execution process of the algorithms can be adjusted according to the dependency relationship, thereby improving the processing efficiency of the algorithms.
[0027] There are multiple ways to implement step S104 above. In one optional embodiment, for any one of the multiple algorithms, a first target algorithm that has a dependency relationship with the first target algorithm and a second target algorithm that does not have a dependency relationship with the first target algorithm are obtained. The processing flow of the first target algorithm is branched so that after the first target algorithm is completed, the first target algorithm and the second target algorithm are executed in parallel. In actual operation, there may be multiple first target algorithms and second target algorithms, but the processing flow can adopt the above technical solution. That is, in the embodiment of the present invention, for each algorithm, one or more first target algorithms that have a dependency relationship with the algorithm and a second target algorithm that does not have a dependency relationship with the first target algorithm are found, thereby realizing what can be understood as parallel processing of the first target algorithm and the second target algorithm.
[0028] In an optional embodiment of the present invention, after executing the first target algorithm and the second target algorithm in parallel, the method further includes:
[0029] Obtain a third target algorithm that is dependent on the first target algorithm, and a fourth target algorithm that is not dependent on the third target algorithm; branch the processing flow of the first target algorithm so that the third target algorithm and the fourth target algorithm are executed in parallel after the first target algorithm is completed.
[0030] In this embodiment of the invention, step S104 can also refer to the processing speed of each algorithm, i.e., obtain the processing speed of each of the plurality of algorithms; determine the execution order of the plurality of algorithms according to the processing speed of each algorithm and the dependency relationship. Specifically, this can be achieved through the following scheme: for any two algorithms with a dependency relationship, obtain the second target algorithm with a faster processing speed and the third target algorithm with a slower processing speed; execute the second target algorithm before the third target algorithm. That is, in this embodiment of the invention, the execution order of serial processing in the execution order of the plurality of algorithms can be determined according to the processing speed. The algorithm with the faster processing speed is processed first. Thus, through this embodiment of the invention, different frame rate algorithms process different processes in the concurrent processing of algorithms, thereby maximizing the asynchronous concurrent processing operation of the algorithms and improving the processing throughput of the algorithms.
[0031] As can be seen, the embodiments of the present invention provide a technical solution that realizes the scheduling of data in the algorithm pipeline and improves the performance of products that apply the above-mentioned multiple algorithms, that is, designing a specific algorithm pipeline based on the algorithm throughput and dependency relationship.
[0032] The following explanation of the above-described process for determining the execution order is provided in conjunction with several optional embodiments, but is not intended to limit the technical solutions of the embodiments of the present invention.
[0033] Option 1: The technical solution of Option 1 of the present invention is as follows:
[0034] 1) In a video stream, input an algorithm pipeline and output the result, such as... Figure 2 As shown, this pipeline includes algorithms A, B, C, D, E, F, and G. Algorithm A is the input, and algorithms E, F, and G output some or all of the results. Assume that the processing capacity of algorithms A, B, and E is *a* frames per second; the processing capacity of algorithms C and F is *b* frames per second; and the processing capacity of algorithms D and G is *c* frames per second, with a > b > c, meaning algorithm D is the slowest. It should be noted that the technical solutions of this embodiment and optional embodiments are preferably applied in application scenarios where the processing speed satisfies a > b > c. Algorithms C and E depend on the processing results of algorithm B, algorithms D and F depend on the processing results of algorithm C, and algorithm G depends on the processing results of algorithm D. The algorithm results are stored sequentially in the result node G. It can be seen that under the condition of a pipeline being serial, the maximum throughput of the entire algorithm is *c* frames per second.
[0035] 2) The C algorithm takes a long time, and the E algorithm does not depend on the processing result of the C algorithm. After the B algorithm obtains the result, the pipeline branch will be opened so that the C algorithm and the E algorithm can obtain the result of the B algorithm at the same time.
[0036] 3) Output the processing results directly according to the E algorithm in step 2).
[0037] 4) According to 1), the D algorithm takes a long time, and the F algorithm does not depend on the processing result of the D algorithm. After the C algorithm obtains the result, the pipeline branch will be opened so that the D algorithm and the F algorithm can obtain the result of the C algorithm at the same time.
[0038] 5) Output the algorithm results directly according to the F algorithm in 4).
[0039] 6) Based on the dependency relationship of the algorithms in 1), the G algorithm obtains input from the D algorithm and outputs the algorithm results.
[0040] That is, through the above technical solution, a video stream is input from algorithm A, partial results are obtained in algorithm E and algorithm F, and the final result is obtained in algorithm G.
[0041] Optional Example 2
[0042] In the optional embodiment two of this invention, multiple algorithms are used to complete tasks such as human attribute detection, human tracking, and area intrusion alarm. Human attributes include the color of clothing worn, etc. Figure 3 As shown,
[0043] First, for the input video stream, images are preprocessed frame by frame, and human bodies are detected from these preprocessed images. If a sequential algorithm pipeline is followed, subsequent algorithms include real-time human position tracking, intelligent perimeter detection, human attribute detection, drawing human bounding boxes, and area intrusion alarms. If the processing speed for video frames, human detection, and human attribute detection is 25 frames per second, the processing speed for human position tracking and bounding box output is 15 frames per second, and the processing speed for intelligent perimeter detection and area intrusion alarms is 2 frames per second, in actual algorithm operation, the slow processing speed of intelligent perimeter detection results in a processing speed of only 2 frames per second for subsequent algorithms. In this case, when the human position changes rapidly, the output human bounding box may lag significantly behind the actual position on the video screen.
[0044] Using the method proposed in the optional embodiments of this invention, human attributes are directly identified and output based on the human detection results, including clothing color, whether a hat or helmet is worn, etc. Simultaneously, the human detection results are output to a tracking algorithm, which tracks the human's position in real time and then outputs a bounding box based on the human's position. The tracking algorithm's results are also output to an intelligent perimeter algorithm, which determines whether the human has crossed the boundary based on the real-time human position and issues an intrusion alarm. The actual processing speed is as follows: Figure 3 As shown, the throughput of human attribute detection can reach 25 frames per second; while the human body location bounding box is output at a rate of 15 frames per second, which can accurately outline the human body position on the video screen even when the human body position changes rapidly; and the area intrusion detection alarm is output twice per second.
[0045] As can be seen, through the technical solution of the embodiments of the present invention, a serial algorithm pipeline can be transformed into a pipeline in which serial and parallel coexistence is achieved based on the throughput of each sub-algorithm and the dependencies between them; algorithm modules with high real-time requirements and fast processing speed are processed serially, while algorithm modules with slower processing speed and low real-time requirements are processed in parallel separately from the main pipeline based on the algorithm dependencies.
[0046] In summary, it is possible to improve the efficiency of algorithm processing without changing the final result of the algorithm implementation. Different algorithms handle different processes, and the performance of algorithm processing can be improved. The goal is to improve the processing speed of the algorithm in a shorter time, with a more efficient and robust algorithm pipeline, and to ensure the reliability of the algorithm implementation.
[0047] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods according to the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of the present invention.
[0048] This embodiment also provides an execution order determination device for implementing the above embodiments and preferred embodiments; details already described will not be repeated. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.
[0049] Figure 4 This is a structural block diagram of an execution order determination device according to an embodiment of the present invention, such as... Figure 4 As shown, the device includes:
[0050] The acquisition module 40 is used to acquire the dependency relationship between any two algorithms among a plurality of algorithms, wherein the plurality of algorithms are used to execute the target business, and the dependency relationship is used to indicate whether the result of one algorithm is used for another algorithm among the arbitrary two algorithms;
[0051] The determination module 42 is used to determine the execution order of the multiple algorithms based on the dependencies.
[0052] This invention obtains the dependency relationship between any two algorithms among multiple algorithms, wherein the multiple algorithms are used to execute a target business, and the dependency relationship is used to indicate whether the result of one algorithm is used in another algorithm; the execution order of the multiple algorithms is determined according to the dependency relationship. By adopting the above technical solution, the problem in related technologies is that for multiple algorithms of a task (containing multiple subtasks), multiple algorithms are simply executed sequentially, resulting in low processing efficiency during the execution of multiple algorithms. Therefore, for multiple algorithms, the execution process of the algorithms can be adjusted according to the dependency relationship, thereby improving the processing efficiency of the algorithms.
[0053] In this embodiment of the invention, the determining module 42 is further configured to, for any one of the plurality of algorithms, obtain a first target algorithm that has a dependency relationship with the first target algorithm, and a second target algorithm that does not have a dependency relationship with the first target algorithm; and to branch the processing flow of the first target algorithm so that after the first target algorithm is executed, the first target algorithm and the second target algorithm are executed in parallel. In actual operation, there may be multiple first target algorithms and multiple second target algorithms, but the processing flow can adopt the above technical solution. That is, in this embodiment of the invention, for each algorithm, one or more first target algorithms that have a dependency relationship with the algorithm and a second target algorithm that does not have a dependency relationship with the first target algorithm are found, thereby realizing what can be understood as parallel processing of multiple first target algorithms.
[0054] In this embodiment of the invention, the determining module 42 is further configured to obtain a third target algorithm that has a dependency relationship with the first target algorithm, and a fourth target algorithm that does not have a dependency relationship with the third target algorithm; and to branch the processing flow of the first target algorithm so that the third target algorithm and the fourth target algorithm are executed in parallel after the first target algorithm is completed.
[0055] In this embodiment of the invention, the determining module 42 is further configured to obtain the processing speed of each of the plurality of algorithms; and determine the execution order of the plurality of algorithms based on the processing speed of each algorithm and the dependency relationship.
[0056] In this embodiment of the invention, the determining module 42 is further configured to, for any two algorithms with a dependency relationship, obtain a second target algorithm with a faster processing speed and a third target algorithm with a slower processing speed; and to execute the second target algorithm before the third target algorithm. That is, in this embodiment of the invention, the execution order of serial processing among multiple algorithms can be determined according to the processing speed. The algorithm with the faster processing speed is processed first. Thus, through this embodiment of the invention, algorithms with different frame rates can process different processes in concurrent processing of algorithms, thereby maximizing asynchronous concurrent processing operations of the algorithms and improving the processing throughput of the algorithms.
[0057] In summary, the technical solution of this invention addresses the problem that multiple different algorithms in video surveillance need to be arranged in a pipeline according to certain serial and parallel relationships. These algorithms have some dependencies on each other, and the dependencies must be considered when the same batch of data is processed concurrently among multiple algorithms. At the same time, there are multiple parallel algorithms in the pipeline, and the multiple parallel algorithms have different processing speeds.
[0058] It should be noted that the above modules can be implemented by software or hardware. For the latter, they can be implemented in the following ways, but are not limited to: all the above modules are located in the same processor; or, the above modules are located in different processors in any combination.
[0059] Embodiments of the present invention also provide a storage medium storing a computer program, wherein the computer program is configured to execute the steps in any of the above method embodiments when running.
[0060] Optionally, in this embodiment, the storage medium may be configured to store a computer program for performing the following steps:
[0061] S1, obtain the dependency relationship between any two algorithms among a plurality of algorithms, wherein the plurality of algorithms are used to execute the target business, and the dependency relationship is used to indicate that the result of one algorithm is used for another algorithm between any two algorithms;
[0062] S2, determine the execution order of the multiple algorithms based on the dependencies.
[0063] Optionally, in this embodiment, the storage medium may include, but is not limited to, various media capable of storing computer programs, such as USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks.
[0064] Embodiments of the present invention also provide an electronic device including a memory and a processor, the memory storing a computer program and the processor being configured to run the computer program to perform the steps in any of the above method embodiments.
[0065] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor and the input / output device is connected to the processor.
[0066] Optionally, in this embodiment, the processor can be configured to perform the following steps via a computer program:
[0067] S1, obtain the dependency relationship between any two algorithms among a plurality of algorithms, wherein the plurality of algorithms are used to execute the target business, and the dependency relationship is used to indicate that the result of one algorithm is used for another algorithm between any two algorithms;
[0068] S2, determine the execution order of the multiple algorithms based on the dependencies.
[0069] Optionally, specific examples in this embodiment can refer to the examples described in the above embodiments and optional implementations, and will not be repeated here.
[0070] Optionally, in this embodiment, the storage medium may include, but is not limited to, various media capable of storing program code, such as USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks.
[0071] It is obvious to those skilled in the art that the modules or steps of the present invention described above can be implemented using general-purpose computing devices. They can be centralized on a single computing device or distributed across a network of multiple computing devices. Optionally, they can be implemented using computer-executable program code, thereby storing them in a storage device for execution by a computing device. In some cases, the steps shown or described can be performed in a different order than those presented herein, or they can be fabricated as separate integrated circuit modules, or multiple modules or steps can be fabricated as a single integrated circuit module. Thus, the present invention is not limited to any particular combination of hardware and software.
[0072] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, or improvements made within the principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for determining the execution order, characterized in that, Applications include human attribute detection, human tracking, and area intrusion alarm tasks, including: Obtain the dependency relationship between any two algorithms from a plurality of algorithms, wherein the plurality of algorithms are used to execute a target business, and the dependency relationship is used to indicate whether the result of one algorithm is used for another algorithm; The execution order of the multiple algorithms is determined based on the dependencies; Determining the execution order of the multiple algorithms based on the dependencies includes: For any one of the plurality of algorithms, obtain a first target algorithm that has a dependency relationship with any one of the algorithms, and a second target algorithm that does not have a dependency relationship with the first target algorithm; The processing flow of any one of the algorithms is branched so that after any one of the algorithms is completed, the first target algorithm and the second target algorithm are executed in parallel. The method further includes branching the processing flow of any one of the algorithms so that after any one algorithm has been executed, the first target algorithm and the second target algorithm are executed in parallel. Obtain a third target algorithm that has a dependency relationship with the first target algorithm, and a fourth target algorithm that has no dependency relationship with the third target algorithm; The processing flow of the first target algorithm is branched so that the third target algorithm and the fourth target algorithm are executed in parallel after the first target algorithm is completed. The aforementioned algorithms are used to complete tasks such as human attribute detection, human tracking, and area intrusion alarm, including: For the input video stream, images are preprocessed frame by frame, and human bodies are detected from the preprocessed images first; Based on the human body detection results, perform human body attribute recognition and output the human body attributes; The human detection results are output to the tracking algorithm, which tracks the human body position in real time based on the detected human body and outputs the human body position bounding box in real time based on the human body position. The results of the tracking algorithm are output to the intelligent perimeter algorithm, which determines whether the human body has crossed the boundary based on its real-time position and issues an intrusion alarm for the area.
2. The method according to claim 1, characterized in that, Determining the execution order of the multiple algorithms based on the dependencies includes: Obtain the processing speed of each of the multiple algorithms; The execution order of the multiple algorithms is determined based on the processing speed of each algorithm and the dependencies.
3. The method according to claim 2, characterized in that, Determining the execution order of the multiple algorithms based on the processing speed of each algorithm and the dependencies includes: For any two algorithms that have a dependency relationship, obtain the fifth target algorithm with the faster processing speed and the sixth target algorithm with the slower processing speed among the two algorithms. The execution order of the fifth objective algorithm is earlier than the execution order of the sixth objective algorithm.
4. An apparatus for determining the execution order of the method as described in any one of claims 1 to 3, characterized in that, include: An acquisition module is used to acquire the dependency relationship between any two algorithms among a plurality of algorithms, wherein the plurality of algorithms are used to execute the target business, and the dependency relationship is used to indicate whether the result of one algorithm is used for the other algorithm; A determination module is used to determine the execution order of the multiple algorithms based on the dependencies; The determining module is further configured to, for any one of the plurality of algorithms, obtain a first target algorithm that has a dependency relationship with the first target algorithm and a second target algorithm that does not have a dependency relationship with the first target algorithm; and to perform branch processing on the processing flow of the first target algorithm so that the first target algorithm and the second target algorithm are executed in parallel after the first target algorithm is completed. The determining module is further configured to obtain a third target algorithm that has a dependency relationship with the first target algorithm, and a fourth target algorithm that does not have a dependency relationship with the third target algorithm; and to branch the processing flow of the first target algorithm so that the third target algorithm and the fourth target algorithm are executed in parallel after the first target algorithm is completed.
5. The apparatus according to claim 4, characterized in that, The determining module is further configured to obtain the processing speed of each of the plurality of algorithms; and determine the execution order of the plurality of algorithms based on the processing speed of each algorithm and the dependency relationship.
6. A computer-readable storage medium, characterized in that, The storage medium stores a computer program, wherein the computer program is configured to execute the method described in any one of claims 1 to 3 when it is run.
7. An electronic device comprising a memory and a processor, characterized in that, The memory stores a computer program, and the processor is configured to run the computer program to perform the method described in any one of claims 1 to 3.