Parallel task scheduling method based on node dynamic load and task relevance measurement
By introducing node dynamic load and task correlation measurements in multi-sample parallel task scheduling, combining global and local schedulers to achieve parallelism between samples and models, the problem of inefficiency of parallel simulation of multi-sample and multi-model is solved, and simulation efficiency and resource utilization are improved.
Patent Information
- Application Number
- CN202411840334.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-13
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2044-12-13
AI Technical Summary
The prior art has not yet considered the parallel simulation efficiency optimization of multi-sample and multi-models within samples, resulting in inefficiency in real-time simulation of GPUs with multiple scenarios and multi-samples.
A parallel task scheduling method based on node dynamic load and task correlation measurement is proposed. Combined with the global scheduler and local scheduler, parallelism between samples and inter-sample models is realized. Through technical means such as computing resource virtualization, GPU virtualization multiplexing, task prediction model and multi-arm gambling machine algorithm, task allocation and model execution order are optimized.
It improves the simulation efficiency of multiple scenarios and samples, optimizes the total task running time, reduces cluster energy consumption, and makes full use of the computing resources and bandwidth resources of high-performance servers.
Smart Images

Figure CN119806771A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of cloud computing and parallel computing, and in particular relates to a parallel task scheduling method based on node dynamic load and task correlation measurement. Background Art
[0002] In order to improve the efficiency of GPU real-time simulation of multiple scenes and multiple samples, it is necessary to study the parallel execution methods of multiple samples and the parallel execution methods of models within samples.
[0003] In terms of sample parallelization, its essence is to establish a mapping between sample models and resources so that more samples can be executed in parallel under resource-constrained conditions. Foreign research considers more about resource allocation for samples with complex constraints. Considering constraints such as localized cold start, tasks are preferentially assigned to virtual machines that already have relevant service software, which can reduce preparation time and virtual machine rental costs. The University of Melbourne in Australia and others proposed a heuristic algorithm for assigning workflow tasks to heterogeneous services, considering data transmission between tasks and the selection of different virtual machine types, but did not consider virtual machine loading time and installation time of related professional software; the Polytechnic University of Valencia in Spain and others proposed to use idle time slots to establish task execution copies to increase reliability. This method also did not consider software localization factors. Domestic research considers more about the resource matching problem of independent samples, with response speed, data processing efficiency, load prediction, and optimal configuration of virtual machines or servers as the main considerations. The National University of Defense Technology and others proposed a computing power division method with front-end and back-end virtual machine layers to achieve parallel load merging based on priority rules and improve task response time; Beijing University of Posts and Telecommunications and others proposed an adaptive particle swarm algorithm to solve the problem of minimizing the rental cost of independent task services with deadlines; related research at Tsinghua University pointed out that fuzzy prediction and time series analysis are the main means of task load prediction, which can calculate the number and type of servers required by the cloud system and achieve the optimal configuration of cloud service resources; when the load increases to the point where existing resources cannot meet the demand, the number of virtual machines is increased, and the automatic application and release of virtual machines can be predicted through admission control and feedback control.
[0004] In terms of model parallelization, mainstream business modeling platforms at home and abroad provide their own business parallel modeling and execution methods. They use the workflow process definition language to achieve a clear and accurate description of serial and parallel models, including the parameter type and output data type of the model, and also describe the calling relationship between models, which plays an auxiliary role in model disassembly during the simulation process. For example, IBM's webSphere platform is based on SOA and supports the writing and parallel execution of business processes based on application business rules; other domestic and foreign business modeling platforms include Oracle's BPEL Process Manager in the United States, SAP's BPM platform in Germany, Kingdee APusicBPM in China, and Yanhuang Yingdong bpmPaaS platform, all of which support the parallel construction and execution of business models. In terms of theoretical research, Chongshi University in South Korea and Imperial College London in the United Kingdom have proposed business model parallel reconstruction methods based on matching pattern mining; the University of Duisburg-Essen in Germany uses deep reinforcement learning methods to optimize the business processes of business support systems and trigger active process adjustments in business process monitoring. In China, Shandong University mines association rules between historical logs to optimize business activity structure reshaping and business processes; Southeast University designs a business process reorganization solution based on deep reinforcement learning (DRL) for the adaptive combination of large-scale business models.
[0005] In summary, current research has not considered the optimization of simulation efficiency for multiple samples and multiple models in a sample. Combining model parallelism with sample parallelism, studying multi-level model parallelism methods driven by domain knowledge and data hybridization, and hierarchical load balancing scheduling strategies based on cold start can effectively improve the simulation efficiency of multiple scenarios and multiple samples. Summary of the invention
[0006] The present invention proposes a parallel task scheduling method based on node dynamic load and task correlation measurement, which comprehensively utilizes the global scheduler and the local scheduler to achieve parallelism between samples and parallelism between models within the sample.
[0007] The technical solution to realize the present invention is: a parallel task scheduling method based on node dynamic load and task relevance measurement, including the following stages:
[0008] A. Preprocessing stage of hierarchical dynamic scheduling: Based on the collected resource environment, the resources include computer servers, storage devices, network devices and other resources; then perform computing resource virtualization, through virtualization technology, abstract physical computing resources into virtual resources, thereby improving resource utilization and flexibility, and divide physical GPU resources into multiple virtual GPUs, thereby realizing GPU resource sharing and reuse; finally, use the high parallel computing capability of GPU to accelerate scientific computing and data processing tasks, as follows:
[0009] A1. Resource and environment data collection and recording: Record the real-time data of the server's GPU utilization, memory utilization, and network bandwidth utilization to form a data set; in addition, it is also necessary to record the utilization of resources such as each computer server, storage device, network device, etc. to ensure a comprehensive understanding of the current resource status.
[0010] A2. Data analysis and frequency distribution diagram drawing: Sampling and analyzing the data set in step A1, we obtain the frequency distribution diagrams of GPU utilization, memory utilization, and network bandwidth utilization. Based on the frequency distribution diagram and mathematical model, we determine the membership functions of GPU utilization, memory utilization, and network bandwidth utilization of each server, providing data support for further resource scheduling.
[0011] A3. Computing resource virtualization: Through virtualization technology, physical computing resources are abstracted into virtual resources, thereby improving resource utilization and flexibility. Specifically, it includes virtualization operations on servers, storage devices, and network devices to ensure that various resources can operate effectively in a virtualized environment.
[0012] A4. GPU virtualization reuse: Physical GPU resources are divided into multiple virtual GPUs to achieve GPU resource sharing and reuse. Through time slice scheduling or hardware partitioning technology, each virtual machine can use GPU resources efficiently.
[0013] A5. GPU acceleration task configuration: Use the high parallel computing power of the GPU to accelerate scientific computing and data processing tasks. Specifically, it includes decomposing tasks and assigning them to the GPU for execution, so as to give full play to the computing performance of the GPU, accelerate the processing process, and improve the overall system efficiency.
[0014] B. Global scheduling phase for parallel optimization of test tasks: Based on the collected historical task operation data, a task prediction model based on random forest is trained, and the task resource demand is obtained based on the model prediction results. In addition, the execution time of the task is estimated using an execution time window model based on probability distribution. The node load rate is introduced to evaluate the performance of each computing node, and the performance threshold is used to determine whether the node participates in task distribution. Finally, the multi-armed bandit theory algorithm framework is used to design the feedback mechanism, reward model and environmental information, and the EXP3 algorithm is constructed to select the optimal node corresponding to the task, as follows:
[0015] B1. Integrate the historical task features and computing resource usage obtained in phase A. Split the data into feature part and label part. The feature part includes the number of server instances, the number of worker instances, the data set size, and the batch task size. The label part includes the gpu core usage, gpu memory usage, and bandwidth usage. Use Bootstrap self-service sampling method to generate the training set for each decision tree.
[0016] B2. Input the data integrated in stage B1 into a random forest model with 20 initial decision trees. The decision tree learning algorithm is usually a process of recursively selecting the optimal feature and splitting the training data set according to the feature, so that each sub-data set has the best classification process. This process corresponds to the division of the feature space and the construction of the decision tree. The estimated resource requirements of the task are obtained.
[0017] Among them, the random forest resource prediction method includes the following steps:
[0018] B21. Select n samples from the sample set by random sampling with replacement.
[0019] B22. Randomly select k features from all features and use these features to build a decision tree for the selected samples.
[0020] B23. Repeat the above two steps 20 times to generate 20 decision trees and form a random forest.
[0021] B24. For new data, each tree makes a decision and finally votes to confirm which category it should be classified into.
[0022] B25. Integrate the results of all decision numbers and convert all results into a task resource requirement vector.
[0023] B3. Construct a multi-armed bandit method with an adversarial reward model to use Bandit theory to analyze the load balancing problem of computing nodes. Design feedback mechanism, reward model and environmental information. Among them, when considering the adversarial bandit problem with expert advice, use the EXP3 algorithm to solve it.
[0024] Among them, the multi-armed bandit method of analyzing the load balancing problem of computing nodes is used by Bandit theory. The multi-armed bandit problem can be simply described as:
[0025] B31. A dispatcher has a possible action to choose from, and each option can be called an arm. Consider that the dispatching process will execute rounds. In each round, the dispatcher selects an arm to pull, and the pulled arm will feedback a reward value. The ultimate goal is to make the reward value as large as possible after T rounds.
[0026] B32. For each arm a∈[K], the arbitrary cost is r t (a) ≥ 0;
[0027] B33. Get the sample space of the selected arm as a t ∈[K];
[0028] B34. The cost of obtaining the selected arm is r t (a t );
[0029] B35. The cost of all arms is r t (a), a∈[K];
[0030] B36. Define the optimal arm as argmin a∈[K] cost(a), then regret is defined as: Represents the expected value of the average loss cost of all options.
[0031] The B4.EXP3 algorithm first initializes the weight function of each computing node, randomly selects an arm in the multi-armed bandit according to the probability formula, randomly selects a computing node according to the probability distribution, and obtains the cost values of all current computing nodes according to the setting of the full feedback mechanism.
[0032] C. Multi-level model parallelization stage based on domain knowledge and data hybrid drive: This stage is mainly a local scheduler for model parallelism. The models within the sample are interdependent and have priority constraints, which can be represented by a DAG graph. The constraint relationships between models in different samples are heterogeneous. First, the priority structure between models within the sample, that is, the DAG graph, is parsed, and the model scheduling sequence decider is called to analyze the scheduling sequence of each model according to the DAG graph between models, and is sequentially transferred into the reward function of reinforcement learning for scoring. At the same time, the instance utilization of each GPU is referred to, and finally it is allocated to the corresponding GPU for execution according to the score. The details are as follows:
[0033] C1. Perform priority structural analysis on the models with dependency and priority constraints in the sample, and access the model scheduling sequence decider.
[0034] C2. In the scheduler, the model that needs to be prioritized is calculated by applying a combination and dynamically adjusted resource placement algorithm in the reinforcement learning reward function, and the order of model execution is obtained according to the size of the score, as follows:
[0035] C21. Initialize the resource placement algorithm parameters for application combination and dynamic adjustment, including the number of limited instances that can run on the server, the difference between the maximum and minimum resource amounts, and the number of placement models;
[0036] C22. Compute the complementary model set of the model, obtain all non-idle GPUs on the server, and select the GPU with the largest number of remaining idle instances that can meet the instance requirements;
[0037] C23. Perform a loop operation, use the vector distance formula to calculate the corresponding GPU cores and GPU memory points that can be placed, and select the target placement point;
[0038] C24. After confirming the priority execution model, calculate the placement point of the subsequent model accordingly and get the score;
[0039] C25. To reduce the time consumption caused by model data transmission, the GPU where all predecessor models are located should be considered first; this can reduce the delay of data transmission and improve the overall system efficiency; if the GPU where the predecessor model is located has insufficient resources, the GPU where other models in the same sample are located can be considered to ensure the continuity and efficiency of model execution.
[0040] C3. Execute the models on the server GPU in sequence according to the obtained model execution order.
[0041] Compared with the prior art, the present invention has the following significant advantages: the present invention can determine the execution relationship of the model by analyzing the serial and parallel constraint relationship between simulation models. Theoretical methods are used to establish parallel optimization problem modeling, calculate the model parallelism, and improve the hardware parallel capability. Considering factors such as local resource utilization, load balancing, resource usage, hierarchical scheduling, GPU acceleration, etc., intelligent methods are used to perform global allocation and scheduling of services and resources, perform task allocation, learn scheduling knowledge, and schedule samples in real time; considering factors such as model reconstruction, model optimization, and model placement, model acceleration is performed using application combination and dynamically adjusted resource placement algorithms. Therefore, the present invention comprehensively considers sample deadlines, resource utilization, and sample and model acceleration, optimizes the total task running time during the test run, and thus reduces cluster energy consumption. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] Figure 1 It is a schematic diagram of the service and resource scheduling model of the present invention.
[0043] Figure 2 It is a schematic diagram of model parallelism within the test task in the present invention.
[0044] Figure 3 It is a schematic diagram of the parallel implementation process of the model of the present invention.
[0045] Figure 4 It is a schematic diagram of the framework of the two-layer scheduling system of the present invention.
[0046] Figure 5 It is a local resource scheduling flow chart of the present invention.
[0047] Figure 6 It is a schematic diagram of the task topology relationship model of the present invention. DETAILED DESCRIPTION
[0048] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0049] The technical solutions between the various embodiments of the present invention can be combined with each other, but it must be based on the fact that ordinary technicians in the field can implement it. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such combination of technical solutions does not exist and is not within the scope of protection required by the present invention.
[0050] The following will further introduce the specific implementation method, as well as the technical difficulties and inventive points of this invention in combination with this design example.
[0051] Combination Figure 1 to Figure 6 The present invention discloses a parallel task scheduling method based on node dynamic load and task correlation measurement, which comprehensively utilizes the global scheduler and the local scheduler to achieve parallelism between samples and parallelism between models within samples, and fully utilizes the computing resources and bandwidth resources provided by high-performance servers to improve the test efficiency. The method includes the following stages:
[0052] A. Preprocessing stage of hierarchical dynamic scheduling: Based on the collected resource environment, the resources include computer servers, storage devices, network devices and other resources; then perform computing resource virtualization. Through virtualization technology, physical computing resources are abstracted into virtual resources, thereby improving resource utilization and flexibility, and physical GPU resources are divided into multiple virtual GPUs, thereby realizing GPU resource sharing and reuse; finally, use the high parallel computing capability of GPU to accelerate scientific computing and data processing tasks.
[0053] The specific steps of the pre-processing stage are as follows:
[0054] A1. Resource and environment data collection and recording: Record the real-time data of the server's GPU utilization, memory utilization, and network bandwidth utilization to form a data set; in addition, it is also necessary to record the utilization of resources such as each computer server, storage device, network device, etc. to ensure a comprehensive understanding of the current resource status.
[0055] A2. Data analysis and frequency distribution diagram drawing: Sampling and analyzing the data set in step A1, we can obtain the frequency distribution diagrams of GPU utilization, memory utilization, and network bandwidth utilization. Based on the frequency distribution diagram and mathematical model, we can determine the membership functions of GPU utilization, memory utilization, and network bandwidth utilization of each server, and provide data support for further resource scheduling, as shown in the following table:
[0056]
[0057]
[0058] A3. Computing resource virtualization: Through virtualization technology, physical computing resources are abstracted into virtual resources, thereby improving resource utilization and flexibility. Specifically, it includes virtualization operations on servers, storage devices, and network devices to ensure that various resources can operate effectively in a virtualized environment.
[0059] A4. GPU virtualization reuse: Physical GPU resources are divided into multiple virtual GPUs to achieve GPU resource sharing and reuse. Through time slice scheduling or hardware partitioning technology, each virtual machine can use GPU resources efficiently.
[0060] A5. GPU acceleration task configuration: Use the high parallel computing power of the GPU to accelerate scientific computing and data processing tasks. Specifically, it includes decomposing tasks and assigning them to the GPU for execution, so as to give full play to the computing performance of the GPU, accelerate the processing process, and improve the overall system efficiency.
[0061] B. Global scheduling phase (i.e., solution phase) for parallel optimization of test tasks: The required resources for incoming tasks are obtained based on the random forest prediction model. A multi-armed bandit method with an adversarial reward model is constructed to use Bandit theory to analyze the load balancing problem of computing nodes. Finally, the EXP3 algorithm is used to calculate the node cost value and schedule the tasks, including the following steps:
[0062] B1. Integrate the historical task features and computing resource usage obtained in phase A. Split the data into feature part and label part. The feature part includes the number of server instances, the number of worker instances, the data set size, and the batch task size. The label part includes the gpu core usage, gpu memory usage, and bandwidth usage. Use Bootstrap self-service sampling method to generate the training set for each decision tree.
[0063] B2. Input the data integrated in stage B1 into a random forest model with 20 initial decision trees. The decision tree learning algorithm is usually a process of recursively selecting the optimal feature and splitting the training data set according to the feature, so that each sub-data set has the best classification process. This process corresponds to the division of the feature space and the construction of the decision tree. The estimated resource requirements of the task are obtained.
[0064] B21. Select n samples from the sample set by random sampling with replacement;
[0065] B22. Randomly select k features from all features and use these features to build a decision tree for the selected samples;
[0066] B23. Repeat the above two steps 20 times to generate 20 decision trees and form a random forest.
[0067] B24. For new data, each tree makes a decision and finally votes to confirm which category it is classified into;
[0068] B25. Integrate the results of all decision numbers, convert all results into a task resource requirement vector, and obtain the final strategy.
[0069] B3. Construct a multi-armed bandit method with an adversarial reward model to use Bandit theory to analyze the load balancing problem of computing nodes. Design feedback mechanism, reward model and environmental information. Among them, when considering the adversarial bandit problem with expert advice, use the EXP3 algorithm to solve it.
[0070] The multi-armed bandit problem can be simply described as:
[0071] B31. A dispatcher has a possible action to choose from, and each option can be called an arm. Consider that the dispatching process will execute rounds. In each round, the dispatcher selects an arm to pull, and the pulled arm will feedback a reward value. The ultimate goal is to make the reward value as large as possible after T rounds.
[0072] B32. For each arm a∈[K], the arbitrary cost is r t (a) ≥ 0;
[0073] B33. Get the sample space of the selected arm as a t ∈[K];
[0074] B34. The cost of obtaining the selected arm is r t (a t );
[0075] B35. The cost of all arms is r t (a), a∈[K];
[0076] B36. Define the optimal arm as argmin a∈[K] cost(a), then regret is defined as: cost(ALG) represents the expected average loss cost of all options.
[0077] The B4.EXP3 algorithm first initializes the weight function of each computing node, randomly selects an arm in the multi-armed bandit according to the probability formula, randomly selects a computing node according to the probability distribution, and obtains the cost values of all current computing nodes according to the setting of the full feedback mechanism.
[0078] C. Multi-level model parallelization stage based on domain knowledge and data hybrid drive: This stage is mainly a local scheduler for model parallelism. The models within the sample are interdependent and have priority constraints, which can be represented by a DAG graph. The constraint relationships between models in different samples are heterogeneous. First, the priority structure between models within the sample, that is, the DAG graph, is parsed, and the model scheduling sequence decider is called to analyze the scheduling sequence of each model according to the DAG graph between models, and is sequentially transferred into the reward function of reinforcement learning for scoring. At the same time, the instance utilization of each GPU is referred to, and finally it is allocated to the corresponding GPU for execution according to the score.
[0079] The multi-level model parallelization stage based on domain knowledge and data hybrid driving includes the following steps (such as Figure 5 shown):
[0080] C1. Perform priority structural analysis on the models with dependency and priority constraints in the sample, and access the model scheduling sequence decision maker, such as Figure 6 ;
[0081] C2. In the scheduler, for the models that need to be prioritized, a combined and dynamically adjusted resource placement algorithm is applied in the reinforcement learning reward function to calculate the scores of the models, and the order of model execution is obtained according to the size of the scores.
[0082] C21. Initialize the resource placement algorithm parameters for application combination and dynamic adjustment, including the number of limited instances that can run on the server, the difference between the maximum and minimum resource amounts, and the number of placement models;
[0083] C22. Compute the complementary model set of the model, obtain all non-idle GPUs on the server, and select the GPU with the largest number of remaining idle instances that can meet the instance requirements;
[0084] C23. Perform a loop operation, use the vector distance formula to calculate the corresponding GPU cores and GPU memory points that can be placed, and select the target placement point;
[0085] C24. After confirming the priority execution model, calculate the placement point of the subsequent model accordingly and get the score;
[0086] C25. To reduce the time consumption caused by model data transmission, the GPU where all predecessor models are located should be considered first; this can reduce the delay of data transmission and improve the overall system efficiency; if the GPU where the predecessor model is located has insufficient resources, the GPU where other models in the same sample are located can be considered to ensure the continuity and efficiency of model execution.
[0087] The meanings of model symbols are as follows:
[0088]
[0089] C3. Execute the models on the server GPU in sequence according to the obtained model execution order.
[0090] The present invention determines the execution relationship of the model by analyzing the serial and parallel constraint relationship between simulation models. (1) Theoretical methods are used to establish parallel optimization problem modeling, calculate the model parallelism, and improve the hardware parallel capability. (2) Considering factors such as local resource utilization, load balancing, resource usage, hierarchical scheduling, GPU acceleration, etc., intelligent methods are used to perform global allocation and scheduling of services and resources, perform task allocation, learn scheduling knowledge, and schedule samples in real time; (3) Considering factors such as model reconstruction, model optimization, and model placement, model acceleration is performed using application combination and dynamically adjusted resource placement algorithms. Therefore, the present invention comprehensively considers sample deadlines, resource utilization, and sample and model acceleration, optimizes the total task running time during the test run, and thus reduces cluster energy consumption.
[0091] The local scheduler should call the model scheduling priority decider to effectively analyze the priority scheduling order according to the DAG graph to schedule each model in sequence: after determining all the export models of the sample, starting from the export model of the sample, the scheduling sequence of all models can be obtained according to the reverse order of the priority relationship between models represented by the DAG graph. The reverse order of the scheduling sequence is the correct priority scheduling order of all models in the sample.
[0092] The local scheduler should call the model, including the following steps (such as Figure 5 shown):
[0093] S1. Analysis sample S i Inner priority structure, obtain sample S i The scheduling order M of each model within.
[0094] S2. Obtaining the allocation set and GPU set in the sample includes the following steps:
[0095] S21. Collect sample Si The allocation set of each model in
[0096] S22. Collect sample S i Current serverψ i The set of GPUs that have been assigned the model
[0097] S3. Traverse each GPUΦ on the server where the sample is currently located xy ,y∈{1,2,...,β}, specifically including the following steps:
[0098] S31. If the current traversal reaches GPUΦ xy If there is a non-idle GPU instance in , the GPU set G of the allocated model is updated to G and Φ xy The union of;
[0099] S4. According to the first scheduling model M i1 The size of the GPU instance, the processing power, and the estimated M i1 The required number of instances g1.
[0100] S5. Traverse each GPU in G and select the GPU with the remaining idle instances Maximum number of idle instances GPUs greater than or equal to g1 are used as Φ i1 .
[0101] S6. If the final Φ i1 If it is empty, a GPU is randomly selected from the GPU set G.
[0102] S7. M i1 Assign to Φ i1 Execute and store the allocation plan in the allocation set ≡ i ←≡ i ∪(M i1 ,Φ i1 ).
[0103] S8. If S i If there are still models that need to be scheduled, then traverse all models M ij Perform the following steps:
[0104] S81. According to M ij The size of the GPU instance and the processing power of the GPU instance are used to estimate the number of GPU instances required. j ;
[0105] S82. Search the DAG graph and obtain M ij All front-wheel drive models of M pre ;
[0106] S83. Query allocation plan ≡ i , select M pre The number of idle instances remaining on the GPU where each model is located Most and Greater than or equal to g j GPU and mark it with Φ ij The label for subsequent use;
[0107] S84. If Φ ij is empty, perform the following steps:
[0108] S841. Search the DAG graph and obtain M ij The set of all non-precursor models M npre ;
[0109] S842. Query allocation plan ≡ i , select M npre The number of idle instances remaining on the GPU where each model is located Most and Greater than or equal to g j GPU and mark it with Φ ij The label for subsequent use;
[0110] S843. If Φ ij If it is still empty, jump to step D3 and select the number of remaining idle instances in G Most and GPUs greater than or equal to g1 are marked with Φ ij Labels;
[0111] S9. Calculate sample S i Server i Total GPU instance utilization μ i And returns the utilization.
Claims
1. A parallel task scheduling method based on node dynamic load and task relevance measurement, characterized in that: The details are as follows: A. Preprocessing stage of hierarchical dynamic scheduling: Based on the collected resource environment, the resources include computer servers, storage devices, and network devices; then perform computing resource virtualization. Through virtualization technology, physical computing resources are abstracted into virtual resources to improve resource utilization and flexibility, and physical GPU resources are divided into multiple virtual GPUs to achieve GPU resource sharing and reuse; finally, use the high parallel computing capability of GPU to accelerate scientific computing and data processing tasks; B. Global scheduling phase for parallel optimization of test tasks: Based on the collected historical task operation data, a task prediction model based on random forest is trained, and the task resource demand is obtained based on the prediction results of the above task prediction model; in addition, the execution time window model based on probability distribution is used to estimate the execution time of the task; the node load rate is introduced to evaluate the performance of each computing node, and the performance threshold is used to determine whether the node participates in task distribution; finally, the multi-armed bandit theory algorithm framework is used to design the feedback mechanism, reward model and environmental information, and the EXP3 algorithm is constructed to select the optimal node corresponding to the task; C. Multi-level model parallelization stage based on domain knowledge and data hybrid drive: This stage is mainly a local scheduler for model parallelism. The models within the sample are interdependent and have priority constraints, which are represented by a DAG graph. The constraint relationships between models in different samples are heterogeneous. First, the priority structure between models within the sample, that is, the DAG graph, is parsed, and the model scheduling sequence decider is called to analyze the scheduling sequence of each model according to the DAG graph between models, and then they are called into the reinforcement learning reward function in sequence for scoring. At the same time, the utilization rate of each GPU instance is referred to, and finally they are allocated to the corresponding GPUs for execution according to the scores.
2. The parallel task scheduling method based on node dynamic load and task relevance measurement according to claim 1 is characterized in that: The specific steps of the preprocessing stage of hierarchical dynamic scheduling are as follows: A1. Resource and environment data collection and recording: Record the real-time data of the server's GPU utilization, memory utilization, and network bandwidth utilization to form a data set; in addition, it is also necessary to record the resource utilization of each computer server, storage device, and network device to ensure a comprehensive understanding of the current resource status; A2. Data analysis and frequency distribution diagram drawing: Sampling and analyzing the data set in A1, obtaining the frequency distribution diagrams of GPU utilization, memory utilization, and network bandwidth utilization; determining the membership functions of GPU utilization, memory utilization, and network bandwidth utilization of each server based on the frequency distribution diagram and mathematical model, providing data support for further resource scheduling; A3. Computing resource virtualization: Through virtualization technology, physical computing resources are abstracted into virtual resources, thereby improving resource utilization and flexibility. Specifically, it includes virtualization operations on servers, storage devices, and network devices to ensure that various resources can operate effectively in a virtualized environment. A4. GPU virtualization reuse: physical GPU resources are divided into multiple virtual GPUs to achieve GPU resource sharing and reuse; time slice scheduling or hardware partitioning technology is used to ensure that each virtual machine can use GPU resources efficiently; A5. GPU acceleration task configuration: Utilize the high parallel computing capability of GPU to accelerate scientific computing and data processing tasks; specifically, decompose the tasks and assign them to the GPU for execution, so as to give full play to the computing performance of GPU, accelerate the processing process, and improve the overall system efficiency.
3. The parallel task scheduling method based on node dynamic load and task relevance measurement according to claim 2 is characterized in that: The global scheduling phase for parallel optimization of test tasks includes the following steps: B1. Integrate the historical task features and computing resource usage obtained in the preprocessing stage of hierarchical dynamic scheduling, and divide the data into feature part and label part; the data of the feature part includes the number of server instances, the number of worker instances, the data set size, and the batch task size; the data of the label part includes the GPU core usage, GPU memory usage, and bandwidth usage; use the Bootstrap self-service sampling method to generate the training set for each decision tree; B2. Input the data obtained by integrating B1 into a random forest model with 20 initial decision trees. The decision tree learning algorithm recursively selects the optimal feature and divides the training data set according to the feature, so that each sub-data set has the best classification process. This process corresponds to the division of the feature space and the construction of the decision tree, thereby obtaining the estimated resource demand of the task; B3. Construct a multi-armed bandit method with an adversarial reward model to use Bandit theory to analyze the problem of load balancing of computing nodes: design feedback mechanism, reward model and environmental information. When considering the adversarial bandit problem with expert advice, use the EXP3 algorithm to solve it; The B4.EXP3 algorithm first initializes the weight function of each computing node, randomly selects an arm in the multi-armed bandit according to the probability formula, randomly selects a computing node according to the probability distribution, and obtains the cost values of all current computing nodes according to the setting of the full feedback mechanism, and finally selects the optimal node corresponding to the task.
4. The parallel task scheduling method based on node dynamic load and task relevance measurement according to claim 3 is characterized in that: In B2, the random forest model is used for resource prediction, that is, the random forest model is applied to integrate multiple decision trees to obtain the final strategy. The steps are as follows: B21. Select n samples from the sample set by random sampling with replacement; B22. Randomly select k features from all features and use these features to build a decision tree for the selected samples; B23. Repeat the above two steps 20 times to generate 20 decision trees and form a random forest. B24. For new data, each tree makes a decision and finally votes to confirm which category it is classified into; B25. Integrate the results of all decision numbers, convert all results into a task resource requirement vector, and obtain the final strategy.
5. The parallel task scheduling method based on node dynamic load and task correlation measurement according to claim 3 is characterized in that: In B3, the multi-armed bandit method for computing node load balancing problem is analyzed using Bandit theory, as follows: The multi-armed bandit problem can be simply described as: B31. A dispatcher has a possible action to choose from, and each option can be called an arm. Consider that the dispatching process will execute rounds. In each round, the dispatcher selects an arm to pull, and the pulled arm will feedback a reward value. The ultimate goal is to make the reward value as large as possible after T rounds. B32. For every arma∈[K], the arbitrary cost is r t (a) ≥ 0; B33. Get the sample space of the selected arm as a t ∈[K]; B34. The cost of obtaining the selected arm is r t (a t ); B35. The cost of all arms is r t (a), a∈[K]; B36. Define the optimal arm as argmin a∈[K] cost(a), then regret is defined as: cost(ALG) represents the expected average loss cost of all options.
6. The parallel task scheduling method based on node dynamic load and task relevance measurement according to claim 1 is characterized in that: The multi-level model parallelization phase driven by domain knowledge and data mixing includes the following steps: C1. Perform priority structural analysis on the models with dependency and priority constraints in the sample, and access the model scheduling sequence decision maker; C2. In the scheduler, the model that needs to be prioritized is scored by applying a combination and dynamically adjusted resource placement algorithm in the reinforcement learning reward function, and the order of model execution is obtained according to the size of the score; C3. Execute the models on the server GPU in sequence according to the obtained model execution order.
7. The parallel task scheduling method based on node dynamic load and task relevance measurement according to claim 6 is characterized in that: The resource placement algorithm for application combination and dynamic adjustment in C2 includes the following steps: C21. Initialize the resource placement algorithm parameters for application combination and dynamic adjustment, including the number of limited instances that can run on the server, the difference between the maximum and minimum resource amounts, and the number of placement models; C22. Compute the complementary model set of the model, obtain all non-idle GPUs on the server, and select the GPU with the largest number of remaining idle instances that can meet the instance requirements; C23. Perform a loop operation, use the vector distance formula to calculate the corresponding GPU cores and GPU memory points that can be placed, and select the target placement point; C24. After confirming the priority execution model, calculate the placement point of the subsequent model accordingly and get the score; C25. To reduce the time consumption caused by model data transmission, the GPU where all predecessor models are located should be considered first; this can reduce the delay of data transmission and improve the overall system efficiency; if the GPU where the predecessor model is located has insufficient resources, the GPU where other models in the same sample are located can be considered to ensure the continuity and efficiency of model execution.
Citation Information
Patent Citations
Complex task parallel scheduling method under multiple cross scenes
CN116703060A
Parallel workflow optimization scheduling method based on time constraint
CN116880403A
Automatic tuning load balancing method for heterogeneous computing system
CN118034909A
Parallel task scheduling method based on dynamic I / O load awareness
CN118034939A
DAG task scheduling method and apparatus, device, and storage medium
WO2023241000A1
Cited By
Micro-service concurrent scheduling method and system based on DAG drive
CN121210144A
A micro-service concurrent scheduling method and system based on DAG driving
CN121210144B
Heterogeneous model task scheduling method and system based on parallel policy metadata
CN121934984A
Heterogeneous model task scheduling method and system based on parallel strategy metadata
CN121934984B