Distributed learning task scheduling method and system for heterogeneous computing cluster

By designing the scheduling objective function and selecting appropriate search strategies in distributed learning tasks, the problem of resource scheduling in heterogeneous computing clusters is solved, efficient task scheduling and resource utilization are achieved, and the training speed of distributed learning tasks is improved.

CN118779080AActive Publication Date: 2024-10-15UNIV OF SCI & TECH OF CHINA

Patent Information

Application Number
CN202410948617.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-16
Publication Date
2024-10-15
Estimated Expiration
2044-07-16

AI Technical Summary

Technical Problem

In distributed learning tasks, the performance and communication overhead of heterogeneous computing clusters increase the difficulty of scheduling. It is difficult for existing technologies to effectively coordinate resources and workloads, affecting task execution efficiency and resource utilization.

Method used

Design a distributed learning task scheduling method for heterogeneous computing clusters. By obtaining task resource requests, matching node pools, and combining computing performance and communication overhead information, use the scheduling objective function score to select nodes or perform cross-node scheduling to select the appropriate search strategies to optimize resource allocation.

Benefits of technology

It achieves task scheduling with high computing performance and low communication overhead, improves the training speed of distributed learning tasks, meets balanced scheduling of different task characteristics, reduces search overhead, and obtains the best scheduling solution.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118779080A_ABST
    Figure CN118779080A_ABST
Patent Text Reader

Abstract

The invention discloses a heterogeneous computing cluster-oriented distributed learning task scheduling method and system, and in the scheme, for a distributed learning training task, a scheduling objective function meeting the characteristics of the distributed learning task is designed, and the computing performance, the communication overhead and the resource utilization rate of a scheduling scheme are comprehensively considered; meanwhile, during cross-node scheduling, a proper scheduling strategy is selected based on the size of a corresponding solution search space, and the search overhead of an allocation scheme and the specific score of the allocation scheme in the scheduling process are comprehensively considered. And finally, the optimal scheduling scheme is obtained with relatively low search overhead on the premise of meeting the characteristics of the distributed learning task, so that the effect of accelerating the distributed learning task is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of operating system task scheduling, and in particular to a distributed learning task scheduling method and system for heterogeneous computing clusters. Background Art

[0002] Faced with increasingly complex computing tasks, distributed learning is considered to be an inevitable development trend and has gradually become a research hotspot in the industry. In the iterative computing process of distributed learning tasks, in addition to the task training of the computing nodes themselves, different computing nodes also need to frequently synchronize the training model parameters so that the model can traverse the complete data set, thereby ensuring that the final model is consistent with the model trained on a single machine. For distributed learning systems, communication overhead and computing overhead will show an exponential growth trend as the system scale increases. In addition, as the number of computing nodes increases, the computing cluster exhibits significant heterogeneity in performance and communication methods. The performance of devices in different computing nodes is different, and the communication methods between computing nodes and between different devices in the node are also different, which greatly increases the difficulty and importance of distributed learning task scheduling.

[0003] Therefore, distributed learning tasks require an efficient task scheduler to coordinate resources and workloads within the cluster to ensure the execution efficiency of distributed learning tasks, resource utilization of computing clusters, etc. Device performance is an important factor affecting computing overhead. Computing devices with different performances used as training carriers for distributed learning tasks will greatly affect the completion time of distributed learning tasks. At the same time, considering the high communication requirements of distributed learning tasks, the differences in communication overhead between computing resources caused by different task scheduling schemes will also greatly affect the completion time of distributed learning tasks.

[0004] In summary, in the process of distributed learning task scheduling, it is necessary to comprehensively consider the two major influencing factors: the computing performance of the equipment and the communication overhead generated by the scheduling scheme. This has important research significance and practical value for further improving the training speed of distributed learning tasks. Summary of the invention

[0005] The purpose of the present invention is to provide a distributed learning task scheduling method and system for heterogeneous computing clusters, analyze the specific computing resource requirements of training tasks, and combine the communication overhead weights within the cluster and the computing device performance information to make more reasonable and efficient task scheduling, ensure high computing performance and low communication overhead of training tasks, thereby improving the training speed of distributed learning tasks.

[0006] The objective of the present invention is achieved through the following technical solutions:

[0007] A distributed learning task scheduling method for heterogeneous computing clusters, comprising:

[0008] Obtain the distributed learning task and its total computing resource request, and match each subtask in the distributed learning task with a node pool that meets the computing resource request;

[0009] Based on the node pools matched by each subtask, determine whether there is a single node that meets the total computing resource request of the scheduling task;

[0010] If so, all single nodes that meet the total computing resource request of the scheduling task are scored using the set scheduling objective function, and the single node with the highest score is selected to assign the distributed learning task to it; the scheduling objective function includes three scheduling objectives: computing performance, communication overhead, and resource concentration;

[0011] If not, cross-node scheduling is performed: the size of the solution search space is calculated in combination with the node pool matched by each subtask. When the size of the search space is not greater than the set threshold, the global search of the allocation scheme is completed through the greedy depth-first search scheduling strategy, and the best scheme is selected from all the global search allocation schemes in combination with the set scheduling objective function as the scheduling scheme; when the size of the search space is greater than the set threshold, the local search of the allocation scheme is completed through the improved metaheuristic algorithm, and the best scheme is selected from all the local search allocation schemes in combination with the set scheduling objective function as the scheduling scheme.

[0012] A distributed learning task scheduling system for heterogeneous computing clusters, comprising:

[0013] The task acquisition and node pool matching unit is used to acquire the distributed learning task and its total computing resource request, and match each subtask in the distributed learning task with a node pool that meets the computing resource request;

[0014] A condition judgment unit, used to judge whether there is a single node that meets the total computing resource request of the scheduling task according to the node pool matched by each subtask;

[0015] The single-node scheduling unit is used to score all single nodes that meet the total computing resource request of the scheduling task using the set scheduling objective function when there is a single node that meets the total computing resource request of the scheduling task, and select the single node with the highest score to allocate the distributed learning task to it; wherein the scheduling objective function includes three scheduling objectives: computing performance, communication overhead, and resource concentration;

[0016] The cross-node scheduling unit is used to perform cross-node scheduling when there is no single node that meets the total computing resource request of the scheduling task: the solution search space size is calculated in combination with the node pool matched by each subtask. When the search space size is not greater than the set threshold, the global search of the allocation scheme is completed through the greedy depth-first search scheduling strategy, and the best scheme is selected as the scheduling scheme from all the global search allocation schemes in combination with the set scheduling objective function; when the search space size is greater than the set threshold, the local search of the allocation scheme is completed through the improved meta-heuristic algorithm, and the best scheme is selected as the scheduling scheme from all the local search allocation schemes in combination with the set scheduling objective function.

[0017] A processing device, comprising: one or more processors; a memory for storing one or more programs;

[0018] When the one or more programs are executed by the one or more processors, the one or more processors implement the aforementioned method.

[0019] A readable storage medium stores a computer program, which implements the above method when the computer program is executed by a processor.

[0020] It can be seen from the technical solution provided by the present invention that for distributed learning training tasks, a scheduling objective function that meets the characteristics of distributed learning tasks is designed, which comprehensively considers the computing performance, communication overhead and resource utilization of the scheduling scheme to meet the balanced scheduling between different distributed learning task characteristics. At the same time, when scheduling across nodes, a suitable scheduling strategy is selected based on the corresponding solution search space size, and the search overhead of the allocation scheme and the specific score of the allocation scheme are comprehensively considered during the scheduling process. Finally, the best scheduling scheme is obtained with a smaller search overhead while meeting the characteristics of the distributed learning task, thereby achieving the effect of accelerating the distributed learning task. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative work.

[0022] Figure 1 A flowchart of a distributed learning task scheduling method for heterogeneous computing clusters provided by an embodiment of the present invention;

[0023] Figure 2 A schematic diagram of a distributed learning task scheduling system for heterogeneous computing clusters provided by an embodiment of the present invention;

[0024] Figure 3 A schematic diagram of a processing device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0025] The following is a clear and complete description of the technical solutions in the embodiments of the present invention in conjunction with the drawings 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 protection scope of the present invention.

[0026] First, the terms that may be used in this article are explained as follows:

[0027] The terms "include", "comprises", "contains", "has" or other descriptions with similar semantics should be interpreted as non-exclusive inclusion. For example, including certain technical feature elements (such as raw materials, components, ingredients, carriers, dosage forms, materials, dimensions, parts, components, mechanisms, devices, steps, procedures, methods, reaction conditions, processing conditions, parameters, algorithms, signals, data, products or products, etc.) should be interpreted as including not only certain technical feature elements explicitly listed, but also other technical feature elements known in the art that are not explicitly listed.

[0028] The term "consisting of..." means excluding any technical feature elements not explicitly listed. If this term is used in a claim, it will make the claim closed, so that it does not contain technical feature elements other than the technical feature elements explicitly listed, except for the conventional impurities related to them. If this term only appears in a clause of a claim, it only limits the elements explicitly listed in the clause, and the elements recorded in other clauses are not excluded from the overall claim.

[0029] The following is a detailed description of a distributed learning task scheduling method and system for heterogeneous computing clusters provided by the present invention. The contents not described in detail in the embodiments of the present invention belong to the prior art known to professional and technical personnel in the field. If no specific conditions are specified in the embodiments of the present invention, they shall be carried out according to the conventional conditions in the field or the conditions recommended by the manufacturer.

[0030] Embodiment 1

[0031] The embodiment of the present invention provides a distributed learning task scheduling method for heterogeneous computing clusters, which mainly includes the following steps:

[0032] Step 1: Obtain the distributed learning task and its total computing resource request, and match each subtask in the distributed learning task with a node pool that meets the computing resource request.

[0033] Step 2: Based on the node pools matched by each subtask, determine whether there is a single node that meets the total computing resource request of the scheduling task; if so, proceed to step 3; if not, proceed to step 4.

[0034] Step 3: For all individual nodes that meet the total computing resource request of the scheduling task, score them using the set scheduling objective function, and select the individual node with the highest score to assign the distributed learning task to it; among them, the scheduling objective function includes three scheduling objectives: computing performance, communication overhead, and resource concentration.

[0035] Step 4: Perform cross-node scheduling: Calculate the size of the solution search space in combination with the node pool matched by each subtask. When the size of the search space is not greater than the set threshold, complete the global search of the allocation scheme through a greedy depth-first search scheduling strategy, and select the best scheme from all the global search allocation schemes as the scheduling scheme in combination with the set scheduling objective function; when the size of the search space is greater than the set threshold, complete the local search of the allocation scheme through the improved metaheuristic algorithm, and select the best scheme from all the local search allocation schemes as the scheduling scheme in combination with the set scheduling objective function.

[0036] In order to more clearly demonstrate the technical solution and technical effects provided by the present invention, the method provided by the embodiment of the present invention is described in detail with reference to specific embodiments below.

[0037] 1. Overview of the plan.

[0038] When a distributed learning task is submitted, the task scheduler will first obtain the specific computing resource request information of the scheduling task. In the traditional scheduling method, after obtaining the specific computing resource request of the scheduling task, the cluster usually adopts the first-come-first-served (FCFS) algorithm, and preliminarily screens the nodes in the cluster in the order of the subtask requests in the training task, leaving the nodes that meet the computing resource requests of the corresponding subtasks, and then sorts the screened nodes in ascending order according to the corresponding idle computing resources, and assigns the subtasks to the corresponding nodes in turn. In this scheduling process, although the training task can meet its own resource request and run successfully, it is difficult to meet the high computing performance and low communication overhead required by the distributed learning task, which makes the completion time of the distributed learning task increase sharply. In order to better meet the characteristics of distributed learning tasks, the computing device performance and training communication overhead in different scheduling schemes are comprehensively considered, so as to achieve the effect of accelerating the training of distributed learning tasks.

[0039] Those skilled in the art will appreciate that there are several computing devices (eg, GPU devices) in each node.

[0040] like Figure 1 As shown in the figure, the overall process of the solution is shown, which can be summarized into the following parts:

[0041] (1) Task submission.

[0042] When receiving a distributed learning task submission request, it first collects the training task computing resource request information, the current cluster communication overhead information, and the computing resource performance information. When the minimum requirements of the training task are met, it enters the specific scheduling.

[0043] (2)Task scheduling.

[0044] Taking into account the multi-dimensional weights such as communication overhead, equipment performance and resource utilization, we first determine whether the single-node scheduling is met. If so, we enter the single-node scheduling scheme. If not, we enter the cross-node scheduling scheme. Based on the different solution search space sizes of the allocation scheme, we select the appropriate scheduling algorithm to balance the search overhead of the allocation scheme and the corresponding comprehensive score of the allocation scheme.

[0045] (3)Task binding.

[0046] After the scheduling plan selection is completed, the specific allocation plan will be fine-grained scheduled to ensure that the computing resource requests in the training tasks are allocated in sequence according to the computing device scores within the node, realizing the optimization from coarse-grained scheduling at the node level to fine-grained scheduling at the device level.

[0047] After the final scheduling plan is generated through the above scheme, the resource information in the cluster nodes is updated, and the scheduling plan is fed back to the corresponding distributed learning task (training task).

[0048] 2. Introduction to the details of the plan.

[0049] 1. Scheduling objective function.

[0050] In the embodiment of the present invention, a corresponding scheduling objective function is designed based on the characteristics of the distributed learning task (training task). The scheduling objective function is theoretically expressed as:

[0051] The scheduling objective function is expressed as:

[0052] F(x)=Y1f perfo (x)+Y2f commu (x)+Y3f utili (x)

[0053] Among them, F(x) represents the scheduling objective function, x is the allocation scheme, including the calculation performance f perfo (x), communication overhead f commu (x) and resource concentration f utili (x) Three scheduling objectives, γ1, Y2, and Y3 represent the balance factors of different scheduling objectives, which are used to indicate the emphasis of the allocation scheme on different scheduling objectives.

[0054] Specifically speaking of resource allocation details, the allocation scheme designed by the present invention is different from the traditional coarse-grained node-level scheduling. It adopts fine-grained device-level scheduling. The resource allocation scheme not only includes nodes allocated to different subtasks, but also accurately allocates them to specific computing devices. Therefore, different allocation schemes are expressed as follows:

[0055] Gplan=gid1,gid2,...,gid ngpu

[0056] Among them, ngpu represents the total number of computing resource requests for a subtask, corresponding to ngpu computing devices, gid k is the computing device id corresponding to the k-th computing resource, k=1, 2, ..., ngpu.

[0057] The computational performance of the allocation scheme is expressed as:

[0058]

[0059] Among them, P(gid k ) is the performance score of the device corresponding to the kth computing resource. That is, the computing performance of the allocation scheme is determined by the sum of the performance of the allocated computing devices.

[0060] When using single-node scheduling, the communication overhead of the allocation scheme only includes the communication overhead between computing devices within the node, which is expressed as:

[0061]

[0062]

[0063] S l =(gid a ,gid b ), gid a ∈Gplan,gid b ∈Gplan

[0064] Among them, Comm represents the communication overhead between two computing devices, and m represents the total number of computing devices selected from any two computing devices in ngpu. S l Indicates the two computing device IDs (i.e., gid a With gid b ). That is, the communication overhead of the current allocation scheme is determined by the sum of the communication overheads between the corresponding computing devices.

[0065] In addition, it should be noted that if there is cross-node scheduling in the scheduling process, the communication overhead between different nodes should be added after calculating the internal communication overhead of all subtasks. node-commu(x), the communication overhead at this time is specifically expressed as follows:.

[0066]

[0067] Nplan=nid1,nid2,...,nid nodes

[0068]

[0069] N v =(nid a ,nid b ), nid a ∈Nplan,nid b ∈Nplan

[0070] Among them, Nplan represents the set of nodes corresponding to all subtasks, nodes represents the number of nodes allocated after removing the same nodes, and nid t represents the node id corresponding to the t-th node, t = 1, 2, ..., nodes, NodeComm represents the calculation of the communication cost between two nodes, and n represents the total number of any two nodes selected from nodes. N v Indicates the two node IDs (i.e. nid a With HID b ).

[0071] The resource concentration of the allocation scheme is expressed as:

[0072]

[0073] Among them, nfree represents the number of idle computing resources of the currently allocated node. That is, the resource concentration of the current allocation scheme is determined by the usage ratio of idle computing resources of the nodes before and after the allocation.

[0074] The score of the allocation plan for each subtask is calculated through the above scheduling objective function, and finally the sum of the scores of all subtask allocation plans is used as the allocation plan score of the distributed learning task.

[0075] 2. Obtain the total computing resource request of the distributed learning task, and arrange the different subtasks in the task in order according to the computing resource request size (for example, in descending order), and match each subtask in the arrangement with a node pool that meets the corresponding computing resource request.

[0076] T=T1,T2,T3,...,T X

[0077] N=N1,N2,N3,...,N y

[0078] NPool i =Match(T i , N), T i ∈T

[0079] Among them, T i is the i-th subtask after sorting, i = 1, 2, 3, .., X, X is the number of subtasks, N is the number of nodes, N1, N2, N3, ..., N y Represents the 1st, 2nd, 3rd, ..., yth node, where y is the number of nodes; NPool i For subtask T i The matching node pool. Match is the matching function.

[0080] After completing the node pool matching, the scheduling algorithm needs to preliminarily determine whether there are remaining computing resources on a single node that can satisfy the sum of the computing resource requests of all subtasks of the training task (i.e., the total computing resource request). If so, it enters the single-node scheduling process; if not, it performs the cross-node scheduling process.

[0081] 3. Single node scheduling.

[0082] If the distributed learning task meets the requirements of single-node scheduling, all single nodes that meet the total computing resource request conditions of the training task are counted. The algorithm sorts the subtask computing resource requests in descending order, and scores the subtasks in turn according to the above scheduling objective function. Finally, the scores of all subtasks are summed up as the total score of the entire scheduling node. Finally, the single nodes that meet the total computing resource requirements of the training task are sorted in descending order according to the score results, and the node with the highest score is selected and assigned to the corresponding distributed learning task.

[0083] 4. Cross-node scheduling.

[0084] If the single-node scheduling is not satisfied, the distributed learning task enters the cross-node scheduling. First, the solution search space size is calculated, which is expressed as:

[0085]

[0086] Among them, NPool i Represents subtask T i The matching node pool, X is the number of subtasks, Len represents the length of the computing node pool; Π is the product symbol.

[0087] Determine whether the following formula is satisfied:

[0088]

[0089] Among them, λ is the set threshold (solution search space threshold).

[0090] If the above formula is satisfied, it indicates that the solution search space corresponding to the scheduling scheme is of appropriate size and is suitable for adopting a deterministic scheduling strategy (precise search strategy), that is, completing the global search for the allocation scheme through the greedy DFS (depth-first search) scheduling strategy. Specifically: Use the greedy depth-first search scheduling strategy to perform the following traversal process: select any node from the node pool matching the subtask and recursively perform a depth-first search until the last subtask; at the same time, during the traversal process, the computing resources requested by the subtask are deducted in advance. If there is a shortage of resources in the allocation process, pruning interruption operations are performed in time to improve the search efficiency, and finally all allocation schemes for the global search are obtained; according to the aforementioned scheduling objective function, the comprehensive score is evaluated for each allocation scheme, and the allocation scheme with the highest score is the best scheme and will be used as the scheduling scheme.

[0091] If the above is not met, it means that the solution search space corresponding to the scheduling scheme is larger than the preset solution search space threshold, and it is suitable to adopt an approximate scheduling strategy (approximate search strategy), that is, to complete the local search of the scheduling scheme through the metaheuristic algorithm, and select the best scheme in all local searches for scheduling.

[0092] In the embodiment of the present invention, a simulated annealing (SA) metaheuristic algorithm is firstly adopted. The algorithm first gives an initial temperature T0, an initial solution S0 and a score F(S0) of a scheduling objective function F. One solution represents an allocation scheme, and the initial solution represents the initial allocation scheme. Randomly exchanging the allocation positions of any two subtasks in the initial solution S0 represents the allocation scheme after random disturbance. If the allocation scheme after random disturbance is greater than the corresponding score of the allocation scheme before random disturbance according to the scheduling objective function score, the allocation scheme corresponding to the current solution is updated, that is, the update probability P=1 at this time. If the score of the allocation scheme after random disturbance is less than the score of the allocation scheme before random disturbance, the allocation scheme after random disturbance is selected according to the following probability P, and the specific probability is expressed as:

[0093]

[0094] Among them, S old is the solution corresponding to the allocation scheme before random perturbation, S new is the solution corresponding to the allocation scheme after random perturbation; exp is an exponential function with a natural constant as the base.

[0095] After completing a random disturbance, the initial temperature T0 is cooled down and the next random disturbance cycle is entered. The corresponding cooling strategy is:

[0096] T0←η×T0,η∈(0,1)

[0097] Among them, η is the coefficient in the cooling strategy, and the symbol ← is the assignment symbol, indicating that the calculation result on the right is assigned to T0.

[0098] Each random perturbation is a local search process, and the updated current solution is retained; when the temperature drops to the specified temperature T end After that, the random perturbation loop is jumped out, and the current solution retained after all local search processes is returned, and its corresponding allocation scheme is used as the scheduling scheme.

[0099] Those skilled in the art can understand that the temperature in the simulated annealing algorithm mainly plays a role in adjusting the probability of accepting a bad solution. As the temperature decreases, the probability of the algorithm accepting a bad solution decreases.

[0100] Preferably, the meta-heuristic algorithm of simulated annealing (SA) is improved to prevent the traditional heuristic algorithm from falling into a local optimal solution or a bad solution. The present invention uses two optimization strategies, namely, a global optimal solution and multi-threaded concurrency, to ensure the effect of the allocation scheme.

[0101] Among them, after each random disturbance, the global optimal solution S is updated in the following way best :

[0102]

[0103] In the above formula, when the distribution scheme after random perturbation corresponds to the solution S new The score F(S new ) is higher than the global optimal solution S best The score F(S best ), then the global optimal solution S best Updated to S new Otherwise, just probabilistically update S as in the traditional SA algorithm above new , and finally by returning the global optimal solution for scheduling, the possibility of the current solution falling into the local optimal solution and bad solution is reduced.

[0104] Use multi-threaded concurrency, and each thread eventually returns a global optimal solution S best , all global optimal solutions S best The allocation scheme corresponding to the solution with the highest score is the best scheme, which will be used as the scheduling scheme and is expressed as:

[0105] S gbest =Sort(S pool ).Pop

[0106]

[0107]

[0108] in, The global optimal solution returned by the zth thread, Thread z .SA indicates that the zth thread uses the improved simulated annealing metaheuristic algorithm, S pool Represents the set of global optimal solutions returned by all tnum threads, Sort(S pool Pop means sorting the global optimal solutions returned by each thread in descending order according to the scores of the scheduling objective function, and popping out the solution with the highest score S gbest Used as a scheduling scheme.

[0109] Therefore, by combining the above optimization strategies, we can avoid the local optimal solution and bad solution that are easy to appear in the traditional SA algorithm, and ensure the quality of the searched solution.

[0110] The above-mentioned scheme provided by the embodiment of the present invention mainly obtains the following beneficial effects: for distributed learning training tasks, a scheduling objective function that meets the characteristics of distributed learning tasks is first designed, which comprehensively considers the computing performance, communication overhead and resource utilization of the scheduling scheme to meet the balanced scheduling between different task characteristics of distributed learning. At the same time, in specific cross-node scheduling, a suitable scheduling strategy is selected based on the corresponding solution search space size, and the search overhead of the allocation scheme and the specific score of the allocation scheme are comprehensively considered during the scheduling process. Finally, the best scheduling scheme is obtained with a smaller search overhead while meeting the characteristics of the distributed learning task, thereby achieving the effect of accelerating the distributed learning task.

[0111] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above embodiments can be implemented by software, or by means of software plus necessary general hardware platforms. Based on such understanding, the technical solutions of the above embodiments can be embodied in the form of software products, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.), including several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in the various embodiments of the present invention.

[0112] Embodiment 2

[0113] The present invention also provides a distributed learning task scheduling system for heterogeneous computing clusters, which is mainly used to implement the method provided in the above embodiment, such as Figure 2 As shown, the system mainly includes:

[0114] The task acquisition and node pool matching unit is used to acquire the distributed learning task and its total computing resource request, and match each subtask in the distributed learning task with a node pool that meets the computing resource request;

[0115] A condition judgment unit, used to judge whether there is a single node that meets the total computing resource request of the scheduling task according to the node pool matched by each subtask;

[0116] The single-node scheduling unit is used to score all single nodes that meet the total computing resource request of the scheduling task using the set scheduling objective function when there is a single node that meets the total computing resource request of the scheduling task, and select the single node with the highest score to allocate the distributed learning task to it; wherein the scheduling objective function includes three scheduling objectives: computing performance, communication overhead, and resource concentration;

[0117] The cross-node scheduling unit is used to perform cross-node scheduling when there is no single node that meets the total computing resource request of the scheduling task: the solution search space size is calculated in combination with the node pool matched by each subtask. When the search space size is not greater than the set threshold, the global search of the allocation scheme is completed through the greedy depth-first search scheduling strategy, and the best scheme is selected as the scheduling scheme from all the global search allocation schemes in combination with the set scheduling objective function; when the search space size is greater than the set threshold, the local search of the allocation scheme is completed through the improved meta-heuristic algorithm, and the best scheme is selected as the scheduling scheme from all the local search allocation schemes in combination with the set scheduling objective function.

[0118] Considering that the specific technical details involved in the above system have been introduced in detail in the previous embodiments, they will not be repeated here.

[0119] Technical personnel in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the system can be divided into different functional modules to complete all or part of the functions described above.

[0120] Embodiment 3

[0121] The present invention also provides a processing device, such as Figure 3 As shown, it mainly includes: one or more processors; a memory for storing one or more programs; wherein, when the one or more programs are executed by the one or more processors, the one or more processors implement the methods provided in the aforementioned embodiments.

[0122] Furthermore, the processing device also includes at least one input device and at least one output device; in the processing device, the processor, memory, input device, and output device are connected via a bus.

[0123] In the embodiment of the present invention, the specific types of the memory, input device and output device are not limited; for example:

[0124] The input device may be a touch screen, an image acquisition device, a physical button or a mouse, etc.;

[0125] The output device may be a display terminal;

[0126] The memory may be a random access memory (RAM) or a non-volatile memory, such as a disk memory.

[0127] Embodiment 4

[0128] The present invention also provides a readable storage medium storing a computer program, which implements the method provided in the above embodiment when the computer program is executed by a processor.

[0129] In the embodiment of the present invention, the readable storage medium is a computer-readable storage medium and can be set in the aforementioned processing device, for example, as a memory in the processing device. In addition, the readable storage medium can also be a U disk, a mobile hard disk, a read-only memory (ROM), a disk or an optical disk, etc., which can store program codes.

[0130] The above is only a preferred specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present invention should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.

Claims

1. A distributed learning task scheduling method for heterogeneous computing clusters. It is characterized in that include: Obtain the distributed learning task and its total computing resource request, and match each subtask in the distributed learning task with a node pool that meets the computing resource request; Based on the node pools matched by each subtask, determine whether there is a single node that meets the total computing resource request of the scheduling task; If so, all single nodes that meet the total computing resource request of the scheduling task are scored using the set scheduling objective function, and the single node with the highest score is selected to assign the distributed learning task to it; the scheduling objective function includes three scheduling objectives: computing performance, communication overhead, and resource concentration; If not, cross-node scheduling is performed: the size of the solution search space is calculated in combination with the node pool matched by each subtask. When the size of the search space is not greater than the set threshold, the global search of the allocation scheme is completed through the greedy depth-first search scheduling strategy, and the best scheme is selected from all the global search allocation schemes in combination with the set scheduling objective function as the scheduling scheme; when the size of the search space is greater than the set threshold, the local search of the allocation scheme is completed through the improved metaheuristic algorithm, and the best scheme is selected from all the local search allocation schemes in combination with the set scheduling objective function as the scheduling scheme.

2. A distributed learning task scheduling method for heterogeneous computing clusters according to claim 1, It is characterized in that The obtaining of the distributed learning task and its computing resource request, and matching each subtask in the distributed learning task with a node pool that meets the computing resource request, comprises: Get the distributed learning task and its computing resource request, arrange the different subtasks in the distributed learning task in order according to the size of the computing resource request, and match each subtask in the arrangement with a node pool that meets the computing resource request, expressed as: T=T 1 ,T 2 ,T 3 ,…,T X N=N 1 ,n 2 ,N 3 ,…,N y NPool i =Match(T i ,N),T i ∈T Among them, T i is the i-th subtask after sorting, i = 1, 2, 3, .., X, X is the number of subtasks, N is the number of nodes, N 1 ,N 2 ,N 3 ,…,N y Represents the 1st, 2nd, 3rd, ..., yth node, where y is the number of nodes; NPool i For subtask T i The matching node pool. Match is the matching function.

3. A distributed learning task scheduling method for heterogeneous computing clusters according to claim 1, It is characterized in that The solution search space size is calculated as follows: Among them, NPool i Represents subtask T i The matching node pool, X is the number of subtasks, Len represents the length of the computing node pool; ∏ is the product symbol.

4. The method for scheduling distributed learning tasks for heterogeneous computing clusters according to claim 1, It is characterized in that The method of completing the global search of the allocation scheme by using a greedy depth-first search scheduling strategy and selecting the best scheme as the scheduling scheme from all the allocation schemes searched globally in combination with the set scheduling objective function includes: The following traversal process is performed using a greedy depth-first search scheduling strategy: any node is selected from the node pool matching the subtask and a recursive depth-first search is performed until the last subtask; at the same time, during the traversal process, resources are deducted in advance for the calculation of the subtask request. If there is insufficient resources in the allocation process, pruning interruption operations are performed in time, and finally all allocation plans for global searches are obtained; Each allocation plan of the global search is scored using the set scheduling objective function. The plan with the highest score is the best plan and will be used as the scheduling plan.

5. The method for scheduling distributed learning tasks for heterogeneous computing clusters according to claim 1, It is characterized in that The method of completing the local search of the allocation scheme by the improved meta-heuristic algorithm and selecting the best scheme as the scheduling scheme from all the allocation schemes of the local search in combination with the set scheduling objective function includes: Using the simulated annealing meta-heuristic algorithm, we first give the initial temperature T 0 , the initial solution S 0 and the score F(S 0 ), a solution represents an allocation scheme, the initial solution represents the initial allocation scheme, and in the initial solution S 0 The random exchange of the allocation positions of any two subtasks in represents the allocation scheme after random disturbance. If the allocation scheme after random disturbance is scored greater than the corresponding score of the allocation scheme before random disturbance according to the scheduling objective function, the allocation scheme corresponding to the current solution is updated, that is, the update probability P = 1 at this time. If the score of the allocation scheme after random disturbance is less than the score of the allocation scheme before random disturbance, the allocation scheme after random disturbance is selected according to the following probability P, which is expressed as: Among them, S old is the solution corresponding to the allocation scheme before random perturbation, S new is the solution corresponding to the allocation scheme after random perturbation, and exp is an exponential function with a natural constant as the base; Each random perturbation is a local search process. After completing a random perturbation, the initial temperature T 0 Cool down and enter the next random perturbation cycle. When the temperature drops to the specified temperature T end After that, the random disturbance cycle is jumped out, and the cooling strategy is: T 0 ←η×T 0 ,η∈(0,1) Among them, η is the coefficient in the cooling strategy, and the symbol ← is the assignment symbol, indicating that the calculation result on the right is assigned to T 0 ; The metaheuristic algorithm of simulated annealing is improved by introducing two optimization strategies: global optimal solution and multi-threaded concurrency. After each random perturbation, it is determined whether to use the allocation plan after random perturbation to update the global optimal solution, and multi-threaded concurrency is adopted to finally obtain the global optimal solution of all threads. The best plan is selected from all allocation plans of the global optimal solution as the scheduling plan through the set scheduling objective function.

6. A distributed learning task scheduling method for heterogeneous computing clusters according to claim 5, It is characterized in that After each random perturbation, the global optimal solution S is updated in the following way best : In the above formula, when the distribution scheme after random perturbation corresponds to the solution S new The score F(S new ) is higher than the global optimal solution S best The score F(S best ), then the global optimal solution S best Updated to S new ; Use multi-threaded concurrency, and each thread eventually returns a global optimal solution S best , all global optimal solutions S best The allocation scheme corresponding to the solution with the highest score is the best scheme, which will be used as the scheduling scheme and is expressed as: S gbest =Sort(S pool ).Pop in, The global optimal solution returned by the zth thread, Thread z .SA indicates that the zth thread uses the improved simulated annealing metaheuristic algorithm, S pool represents the set of global optimal solutions returned by all tnum threads, S gbest Sort(S pool ).Pop means sorting the global optimal solution returned by each thread in descending order according to the score of the scheduling objective function.

7. A distributed learning task scheduling method for heterogeneous computing clusters according to any one of claims 1 to 6, It is characterized in that The scheduling objective function includes: computing performance f perfo (x), communication overhead f commu (x) and resource concentration f utili (x) Three scheduling objectives, expressed as: F(x)=γ 1 f perfo (x)+γ 2 f commu (x)+γ 3 f utili (x) Among them, F(x) represents the scheduling objective function, x is the allocation scheme, γ 1 , γ 2 , γ 3 represents the balancing factor for different scheduling objectives; Computational performance perfo (x) is expressed as: Among them, gid k is the computing device id corresponding to the k-th computing resource, k = 1, 2, ..., ngpu, P(gid k ) is the performance score of the device corresponding to the k-th computing resource, and gpu represents the total number of computing resource requests for a subtask; When using single-node scheduling, the communication overhead f commu (x) is expressed as: Where Comm represents the communication overhead between two computing devices, m represents the total number of any two computing devices selected from ngpu computing devices, and S l Indicates the two computing device IDs that were taken out; When using cross-node scheduling, add the communication overhead f between different nodes node-commu (x), communication overhead f commu (x) is expressed as: Resource concentration utili (x) is expressed as: Among them, nfree represents the number of idle computing resources of the currently allocated node.

8. A distributed learning task scheduling system for heterogeneous computing clusters. It is characterized in that include: The task acquisition and node pool matching unit is used to acquire the distributed learning task and its total computing resource request, and match each subtask in the distributed learning task with a node pool that meets the computing resource request; A condition judgment unit, used to judge whether there is a single node that meets the total computing resource request of the scheduling task according to the node pool matched by each subtask; The single-node scheduling unit is used to score all single nodes that meet the total computing resource request of the scheduling task using the set scheduling objective function when there is a single node that meets the total computing resource request of the scheduling task, and select the single node with the highest score to allocate the distributed learning task to it; wherein the scheduling objective function includes three scheduling objectives: computing performance, communication overhead, and resource concentration; The cross-node scheduling unit is used to perform cross-node scheduling when there is no single node that meets the total computing resource request of the scheduling task: the solution search space size is calculated in combination with the node pool matched by each subtask. When the search space size is not greater than the set threshold, the global search of the allocation scheme is completed through the greedy depth-first search scheduling strategy, and the best scheme is selected as the scheduling scheme from all the global search allocation schemes in combination with the set scheduling objective function; when the search space size is greater than the set threshold, the local search of the allocation scheme is completed through the improved meta-heuristic algorithm, and the best scheme is selected as the scheduling scheme from all the local search allocation schemes in combination with the set scheduling objective function.

9. A processing device, It is characterized in that include: one or more processors; A memory for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.

10. A readable storage medium storing a computer program, It is characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Distributed training task scheduling method, system and device for intelligent computing

    CN115248728A

  • Cloud computing resource scheduling method and scheduling system based on historical data perception

    CN115934333A

  • Multi-agent cooperative computing resource scheduling method, device and system

    CN116909742A

  • Task unloading method for improving task execution efficiency and edge node resource utilization rate

    CN117608700A

  • Workflow scheduling method and system based on multi-target particle swarm algorithm, and storage medium

    US20220405129A1

Cited By

  • Method and device for determining distributed parallel scheme, equipment and medium

    CN119046022A

  • Large model parallel task scheduling method based on space-time two-dimensional segmentation and intelligent sharing

    CN119645609A

  • Large model parallel task scheduling method based on spatiotemporal two-dimensional segmentation and intelligent sharing

    CN119645609B