Computing Offloading and Resource Allocation Method Applicable to CPU-GPU Heterogeneous Clusters

By decomposing the tasks into serial and parallel segments and allocating computing resources based on GPU resource sharing technology, the problem of low resource utilization efficiency in CPU-GPU heterogeneous networks is solved, lower system overhead and higher GPU utilization rate are achieved, and the user experience quality is improved.

CN115442851BActive Publication Date: 2025-07-29SHANGHAI TECH UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211051646.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-08-31
Publication Date
2025-07-29
Estimated Expiration
2042-08-31

AI Technical Summary

Technical Problem

The prior art fails to effectively utilize the computing resources of CPU and GPU in CPU-GPU heterogeneous networks, resulting in the computing resource requirements of computing intensive and delay-sensitive applications that cannot be efficiently met, especially in multi-access edge computing scenarios, task scheduling and resource allocation are inefficient.

Method used

The task is decomposed into serial segments and parallel segments, offloaded to the CPU and GPU respectively, and calculated resource allocation is performed based on the GPU's resource sharing technology. Through mixed integer nonlinear planning problems and joint simulation annealing and convex optimization algorithms, the total overhead of minimizing delay and energy consumption is achieved.

Benefits of technology

It improves the computing offloading and resource allocation efficiency of CPU-GPU heterogeneous clusters, reduces system overhead, improves GPU utilization, and significantly improves the quality of user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115442851B_ABST
    Figure CN115442851B_ABST
Patent Text Reader

Abstract

The present invention relates to a computing offloading and resource allocation method applicable to a CPU-GPU heterogeneous cluster, which considers joint computing offloading and resource allocation in a CPU-GPU heterogeneous network to achieve lower system overhead and higher GPU utilization. Each task is decomposed into a serial segment and a parallel segment, which can be offloaded to the CPU and GPU respectively. Based on the resource sharing technology of the GPU, the computing power of the GPU is discretized, and the computing resource allocation is formulated as an integer programming. Then the task scheduling is modeled as a mixed integer non-linear programming problem to minimize the total overhead composed of latency and energy consumption. We decompose the mixed integer non-linear programming problem so that the computing offloading and resource allocation can be alternately optimized, which leads to an algorithm combining simulated annealing and convex optimization. Numerical simulations are carried out to evaluate the performance of the proposed solution, which is optimal in terms of system overhead, the number of benefited UEs and speedup ratio compared with traditional methods.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a computer technology, and particularly to a computing offloading and resource allocation method applicable to a CPU-GPU heterogeneous cluster. Background Art

[0002] With the development of 5G technology and the large-scale commercialization of artificial intelligence, users' demand for computing continues to grow. Emerging compute-intensive and latency-sensitive applications (such as virtual reality, augmented reality, autonomous driving, and intelligent interaction) cannot provide high quality of experience due to the distance from cloud computing centers and limited local computing resources. In view of this, the concept of Multi-Access Edge Computing (MEC) has emerged. Different from cloud computing and local computing, MEC provides better services by offloading user tasks to the edge of the network. Edge nodes are closer to users than cloud computing centers and have more powerful computing capabilities than local devices. Specifically, they can complete tasks faster through the trade-off between communication and computing, that is, using the saved computing time to make up for the transmission delay.

[0003] Compared with the CPU, the powerful floating-point computing ability of the GPU greatly reduces the training time of the Deep Neural Network (DNN). At the same time, high-performance GPUs produced by NVIDIA and AMD have met the computing needs of many applications, such as computer vision and natural language processing. Therefore, more and more CPU-GPU clusters are used for DNN training and inference. At the same time, Kubernetes (an open-source container orchestration engine developed by Google, which supports automated deployment, large-scale scalability, and application containerization management. When deploying an application in a production environment, multiple instances of the application are usually deployed to load balance application requests), an open-source container orchestration system, is introduced to achieve orchestration on heterogeneous devices. The above points indicate that task scheduling in a CPU-GPU heterogeneous network will become a natural trend.

[0004] Since the concept of MEC was proposed, it has attracted a great deal of attention. A series of methods and algorithms have been developed to address the challenges of task scheduling and improve different global performance metrics in MEC scenarios. On the one hand, users offload tasks in a homogeneous network composed of homogeneous devices with the same computing power. The literature (G. Zhao, H. Xu, Y. Zhao, C. Qiao and L. Huang, ”Offloading Tasks With Dependency and Service Caching in Mobile Edge Computing,” in IEEE Transactions on Parallel and Distributed Systems, vol. 32, no. 11, pp. 2777-2792, 1 Nov. 2021) defined a problem of offloading dependent tasks to homogeneous edge nodes with service caching and designed an efficient convex optimization-based algorithm to solve this problem. Xiao et al. (S. Xiao, D. Li and S. Wang, ”Periodic Task Scheduling Algorithm for Homogeneous Multi-core Parallel Processing System”, 2019 IEEE International Conference on Unmanned Systems (ICUS), pp. 710-713, 2019) proposed a new heuristic algorithm for periodic task scheduling in a homogeneous multi-core processor environment. On the other hand, users offload tasks in a heterogeneous network composed of devices with different computing powers. The work adopted the method of distributed game theory to achieve efficient computing offloading in heterogeneous environments. Tran et al. (T. X. Tran and D. Pompili, ”Joint Task Offloading and Resource Allocation for Multi-Server Mobile-Edge Computing Networks,” in IEEE Transactions on Vehicular Technology, vol. 68, no. 1, pp. 856-868, Jan. 2019) proposed a Mixed Integer Nonlinear Programming (MINLP) and suggested decomposing it into several subproblems. There are also those who have adopted deep reinforcement learning to determine offloading strategies.However, all of the above work only uses a general computing device, i.e., the CPU, without considering the case of using the CPU-GPU combination.

[0005] The field of CPU-GPU cooperation has been studied. The literature (A. Dhakal, S. G. Kulkarni and K. K. Ramakrishnan, “Machine Learning at the Edge: Efficient Utilization of Limited CPU / GPU Resources by Multiplexing,” 2020 IEEE 28th International Conference on Network Protocols (ICNP), pp. 1-6, 2020.) adopted a multiplexing method to improve the utilization rate of the CPU and GPU during the calculation process of machine learning tasks. The literature (N. Tsog, S. Mubeen, F. Bruhn, M. Behnam and M. ”Offloading Accelerator-intensive Workloads in CPU-GPU Heterogeneous Processors,” 2021 26th IEEE International Conference on Emerging Technologies and Factory Automation (ETFA), pp. 1-8, 2021) studied the calculation offloading process in CPU-GPU heterogeneous processors and improved the efficiency of the entire cluster, but it ignored the resource allocation process. Summary of the Invention

[0006] Aiming at the high requirements for computing resources of emerging compute-intensive and latency-sensitive applications, a calculation offloading and resource allocation method suitable for a CPU-GPU heterogeneous cluster is proposed.

[0007] The technical solution of the present invention is: a calculation offloading and resource allocation method suitable for a CPU-GPU heterogeneous cluster, equipped with an edge cluster EC composed of a CPU and a GPU, modeling the task problem for user tasks, aiming to minimize the total overhead composed of latency and energy consumption, determining a task scheduling scheme, and the task scheduling scheme includes whether the task is executed locally or offloaded to be executed by the edge cluster. If the task is executed by the edge cluster, the task problem modeling is decomposed into three subtasks: offloading decision, transmission power allocation, and computing resource allocation, matching the corresponding algorithms for subtask scheduling calculation, and obtaining a scheduling scheme for the edge cluster to execute the task for task execution.

[0008] Furthermore, the task model in which the CPU and GPU cooperate to execute tasks is as follows: A user task is decomposed into three segments, which are divided into two types, namely two serial segments and one parallel segment; The task starts from the serial segment executed on the CPU, which is a data preprocessing stage; Then, the GPU is used to execute a parallel segment, which is parallelized into several subtasks, and the several subtasks end with the results aggregated to the next serial segment to be executed, and the next serial segment runs on the CPU; Each user n has a task A n , that is where represents the size of the task, represents the floating-point operations required at the start and end of the serial segment, represents the floating-point operations required for the parallel segment, represents the number of parallel subtasks.

[0009] Furthermore, the model for building the edge cluster: Use to represent M ECs, each of which is equipped with multiple CPUs and GPUs. A complete GPU is divided into several parts, and each part is regarded as a non-parallelizable GPU to serve a parallel subtask. The EC has the following limitations:

[0010] The computing resources of each GPU in the same EC are the same;

[0011] Multiple GPUs in the same EC can run simultaneously, and each GPU can only be assigned to one parallel subtask;

[0012] The edge cluster composed of M ECs is represented as:

[0013] where represents the number of CPUs in the EC m , represents the CPU computing power, that is, the number of floating-point operations per second, represents the working power of the CPU, represents the standby power of the CPU. The parameters of the GPU are similar to those of the CPU.

[0014] Furthermore, the task problem modeling: The total cost of the tasks of all N users is:

[0015]

[0016] where represents the offloading variables of all users; is the computing resource allocation variable of all users; is the transmission power allocation variable of all users; T n, E n are the total delay and energy consumption of user n, respectively; λ t , λe are the weight coefficients of the total delay and energy consumption;

[0017] The minimized system cost of the modeling is:

[0018]

[0019]

[0020]

[0021]

[0022]

[0023]

[0024] The objective of this model is to minimize the total system cost, and the constraints are: (1) The value of the offloading decision x n,m is 0 and 1, and x n,m = 1 means that user n offloads the task to the EC m , and if m = 0, the task is executed locally; (2) represents that for all users' offloading variables, the user either executes the task locally or offloads it to the edge cluster; (3) The transmission power p n of user n is restricted by the maximum power P n ; (4) k m represents the total number of tasks offloaded to the cluster EC m ; (5) The number of GPUs allocated to all tasks offloaded to the cluster EC m does not exceed the total number of GPUs in this cluster.

[0025] Furthermore, the task problem modeling is decomposed into 3 sub - task solving objectives: The first task Q1 represents optimizing the user offloading decision variable and on the basis of optimization of under the constraints (1) and (2); The second task Q2 represents optimizing the transmission power when is determined under the constraint (3); The third task Q3 represents optimizing the computing power resource when is determined under the constraints (4) and (5).

[0026] Furthermore, the Q1 offloading decision is a non - linear integer programming problem. The heuristic algorithm simulated annealing method is selected, and a random sampling method is used to select an offloading decision variable close to the current solution. The quality of the system is judged by the system cost under this system decision, and it moves to this solution according to the temperature - related probability of choosing a better or worse solution; for Q2 transmission power allocation, according to p n constraints, the transmission power allocation is approximated as a quasiconvex optimization problem and solved by the bisection method. Within the maximum power limit P n range, the middle value of the interval is continuously selected until the optimal solution is obtained; for Q3 computing resource allocation, the problem is integer programming. By relaxing the relevant integer variables it is approximated as a non - linear programming, and a non - integer solution is obtained through convex optimization, and then approximated as an integer solution as the optimal solution.

[0027] The beneficial effects of the present invention are as follows: The present invention is applicable to the computing offloading and resource allocation method of a CPU - GPU heterogeneous cluster, considering the joint computing offloading and resource allocation in a CPU - GPU heterogeneous network to achieve lower system overhead and higher GPU utilization. We decompose each task into serial segments and parallel segments, which can be offloaded to the CPU and GPU respectively. Based on the GPU - based resource sharing technology, we discretize the computing power of the GPU, so that the computing resource allocation is expressed as integer programming. Then we model the task scheduling as a MINLP problem to minimize the total overhead composed of latency and energy consumption. We decompose the MINLP so that the computing offloading and resource allocation can be alternately optimized, which leads to the Joint Simulated Annealing and Convex Optimization Based Algorithm (JSAC). We conduct numerical simulations to evaluate the performance of the proposed solution. Compared with traditional methods, it is the best in terms of system overhead, the number of benefited UEs, and speedup ratio. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Figure 1 It is a schematic diagram of the application scenario of the present invention;

[0029] Figure 2 It is a schematic diagram of the task model of the present invention;

[0030] Figure 3 It is a schematic diagram of the problem decomposition of the present invention;

[0031] Figure 4 It is a pseudo - code diagram of the JSAC algorithm of the present invention;

[0032] Figure 5 It is a comparison diagram of the system overhead under different algorithms of the present invention;

[0033] Figure 6 This is a comparison chart of the number of benefited users under different algorithms of the present invention;

[0034] Figure 7 This is a comparison chart of the convergence rate under different numbers of users of the present invention;

[0035] Figure 8 This is a graph of the overall probability mass function and cumulative distribution function of the speedup ratio of the present invention. Detailed implementation manners

[0036] The present invention will be described in detail below with reference to the accompanying drawings and specific embodiments. This embodiment is implemented on the premise of the technical solution of the present invention, and gives detailed implementation manners and specific operation processes, but the protection scope of the present invention is not limited to the following embodiments.

[0037] I. System model

[0038] 1. Application scenario

[0039] Consider a multi-user, multi-cluster scenario, as Figure 1 shown. At the center of the cell, each base station is equipped with an edge cluster (EC) composed of a CPU and a GPU to serve mobile users with limited resources. The tasks of each user can be executed locally or offloaded to a nearby EC through a wireless channel. Similar to many other works, the resources used for transmitting the final result can be ignored because the size of the result is negligible compared to the size of the task, and the downlink bandwidth is usually larger than the uplink bandwidth.

[0040] 2. Task model

[0041] The training and inference of DNN require a considerable amount of computing resources. Since the GPU has powerful parallel computing capabilities, it can meet this requirement. In view of this, a task model composed of a CPU and a GPU is adopted instead of only using a general-purpose CPU. As Figure 2The schematic diagram of the task model is shown. A user task (Task) can be decomposed into three segments, and the three segments are of two types, namely two sequential segments and one parallel segment. The task starts with the sequential segment executed on the CPU, which is a data preprocessing stage. Then, the GPU is used to execute a parallel segment, which can be parallelized into several subtasks. Due to the powerful computing power of the GPU, offloading the task to the GPU reduces the computing latency. The whole process ends with the result aggregated to the next sequential segment executed, and the next sequential segment runs on the CPU.

[0042] For expression and analysis, assume there are N users, denoted by Each user has a task A n , that is. Among them denotes the size (bits) of the task, denotes the floating point operations (FLOPs) required at the start and end of the sequential segment. denotes the FLOPs required for the parallel segment, denotes the number of parallel subtasks. This task can be executed locally or offloaded to the entire EC.

[0043] 3. Edge Cluster Model

[0044] Denoted by Denote M ECs. Each EC is equipped with multiple CPUs and GPUs. Regarding GPUs, resource sharing is already a topic to be studied. On the one hand, resource sharing requires resource isolation. NVIDIA has developed a solution (NVIDIA Multi-Instance GPU User Guide) to evenly distribute computing resources and fully achieve resource isolation. On the other hand, the parallel mode of GPUs is also an issue to be considered. The parallel mode refers to the way in which multiple tasks run on the same GPU simultaneously. Currently, there are two types: (i) Time-slice multiplexing. It means dividing time slices so that different tasks occupy a separate time slice. In this mode, tasks are actually concurrent rather than parallel because only one task is running at the same time. (ii) Coalesced sharing. It means merging multiple tasks into one context so that multiple tasks can run simultaneously. This mode is truly parallel. The most representative is Nvidia's MPS (Z. Liu, K. Li, L. Wu, Z. Wang, Y. Yang. "CATS: Cost Aware Task Scheduling in Multi-Tier Computing Networks", Journal of Computer Research and Development, vol. 57, no. 9, pp. 1810-1822, 2020). Based on the above two aspects, a complete GPU is divided into several parts. Each part is regarded as a non-parallelizable GPU to serve a parallel sub-task. Then we make the following assumptions:

[0045] The computing resources of each GPU in the same EC are the same.

[0046] Multiple GPUs in the same EC can run simultaneously. Each GPU can only be assigned to one parallel sub-task, and the utilization rate can reach 100%.

[0047] Based on the above assumptions, we represent the EC m as:

[0048] where represents the number of CPUs in the EC m , represents the CPU computing power, i.e., the number of floating-point operations per second (Floating Point of Per Second, FLOPS), represents the working power (W) of the CPU, represents the standby power (W) of the CPU. The parameters of the GPU are similar to those of the CPU.

[0049] 4. Computational Model

[0050] Users can execute their tasks locally or offload them to the EC m . Using x n,m ∈ {0, 1} to represent the offloading decision, where x n,m = 1 indicates that user n offloads the task to the EC m . If m = 0, the task is executed locally. represents the offloading variables of all users. We assume that user n has only one CPU locally, and its computing power is The computing power is If user n decides not to offload, both the serial segment and the parallel segment will be executed by the local CPU. The computing latency and energy consumption of local computing are expressed as:

[0051]

[0052]

[0053] When deciding to offload the task to the EC m , user n will be assigned one CPU and GPUs. is the computing resource allocation variable for all users. Using to represent the set of users offloaded to the EC m , the number of this set is expressed as Assume that the task fully occupies the device during the computing process. The CPU and GPU computing latencies of user n related to the EC m can be expressed as:

[0054]

[0055]

[0056] In summary, the computing latency of user n is:

[0057] Computing devices consume energy not only when working but also when on standby. Therefore, the CPU and GPU computing energy consumption of user n related to the EC m can be expressed as:

[0058]

[0059]

[0060] In summary, the computing energy consumption of user n is:

[0061]

[0062] 5. Communication Model

[0063] The communication model is divided into two parts, the uplink process and the transmission of intermediate results within the edge cluster. In particular, the latter can be ignored because the bandwidth within the EC is very large compared to the uplink. Therefore, only the uplink process is concerned about.

[0064] Consider using Orthogonal Frequency Division Multiple Access (OFDMA) as the multiple access scheme for the uplink, where the total bandwidth W0 is divided into J subbands of equal size, W = W0 / J. is the set of users occupying subband j. Denote the maximum transmission power of user n as P n . Then, the transmission power allocation variable can be expressed as Meanwhile, the channel gain matrix can be represented by where d n,m represents the distance from user n to the EC m . From the Shannon formula, the transmission rate from user n to the EC m can be obtained as:

[0065]

[0066] where η n,m represents the Signal-to-interference-noise ratio (SINR) from user n to the EC m , and can be expressed in the following way:

[0067]

[0068] where σ 2 is the noise power, and j is the subband occupied by user n. The second term in the denominator represents the inter-cell interference generated among users under OFDMA. If user n decides to execute the task locally, there will be no transmission delay and energy consumption.

[0069] Express the transmission delay and energy consumption of user n as follows:

[0070]

[0071]

[0072] 6. Problem Modeling

[0073] For a certain user n, its total delay and energy consumption are expressed as:

[0074]

[0075]

[0076] Therefore, the total cost for all N users is:

[0077]

[0078] where λ t and λe are the weight coefficients of the total delay and energy consumption.

[0079] The minimized system cost model for modeling is:

[0080]

[0081]

[0082]

[0083]

[0084]

[0085]

[0086] The objective of this model is to minimize the total system cost, and the constraints are as follows: 1. The value of the offloading decision x n,m is 0 and 1; 2. Users either execute tasks locally or offload them to the edge cluster; 3. The transmission power p n of the user is limited by the maximum power P n ; 4. k m represents the total number of tasks offloaded to the cluster EC m ; 5. The number of GPUs allocated to all tasks offloaded to the cluster EC m does not exceed the total number of GPUs in the cluster.

[0087] II. JSAC Algorithm

[0088] 1. MINLP Decomposition

[0089] The above problem is equivalent to substituting all the above formulas into the system model and then combining like terms, and another form of the system model can be obtained:

[0090]

[0091]

[0092]

[0093]

[0094] Through observation, we can split this problem into three sub - problems:

[0095]

[0096]

[0097] Q1 represents the optimization of the user uninstallation decision variable and on the basis of optimization, with the constraints being Constraint 1 and Constraint 2 in the system model. Q2 represents the optimization of the transmission power when [a certain condition is determined], with the constraint being Constraint 3 in the system model. Q3 represents the optimization of the computing power resource when [a certain condition is determined], with the constraints being Constraint 4 and Constraint 5 in the system model.

[0098] Figure 3

[0099] The logical relationship between its sub - problems is as Figure 3 shown. The decomposed sub - problems (MINLP Problem) are Q1 uninstallation decision, Q2 transmission power allocation, and Q3 computing resource allocation. The corresponding solutions (JSAC Algorithm). The decomposed sub - problems and the corresponding solutions are bridged by intermediate parameters (Parameter).

[0099] 2. Algorithm Description

[0100] The Q1 uninstallation decision is a non - linear integer programming problem, which can be solved by some exact solution algorithms, such as the branch - and - bound method, and some approximate solution algorithms, such as heuristic algorithms. Since the branch - and - bound method can only solve integer linear programming problems, we choose the heuristic algorithm, simulated annealing. This algorithm starts from a relatively high initial temperature T and decreases to the lowest temperature T min with the parameter β ∈ (0, 1). At each step, this algorithm selects an uninstallation decision variable close to the current solution through a random sampling method and judges the quality of the system by the system cost under this system decision, and moves to this solution according to the temperature - related probability of choosing a better or worse solution. Regarding Q2 transmission power allocation, according to the constraint of p n , the transmission power allocation is approximated as a quasi - convex optimization problem, which can be solved by the bisection method (because this problem is a quasi - convex optimization problem, with the maximum power limit P nWithin the range, continuously select the intermediate value of the interval until the optimal solution is selected). Regarding the Q3 computing resource allocation, the problem is an integer programming. By relaxing the relevant integer variables (computing resource allocation variables) approximate it as a non-linear programming, and obtain a non-integer solution through convex optimization, and then approximate it as an integer solution as the optimal solution. The pseudo-code of the JSAC algorithm is as Figure 4 shown.

[0101] III. Parameter Settings

[0102] Show the comparison results between the JSAC algorithm of the present invention and other baseline algorithms. We consider a total of 10 cells, each cell has an EC, and users are randomly distributed in the cells. For the computing devices, we assume that the standby power is one-fourth of the computing power. In addition, the computing power is proportional to the computing ability. The specific parameter settings are shown in Table 1 Simulation Parameter Settings.

[0103] Table 1

[0104]

[0105] Compare the JSAC of the present invention with the following baselines:

[0106] Local computing (Local): Each user chooses to execute the task locally.

[0107] Random offloading (Random): Each user executes the task locally or offloads it to a random EC.

[0108] Greedy offloading (Greedy): Each user offloads its task to the EC with the highest computing ability.

[0109] CATS offloading (CATS): A distributed task scheduling algorithm based on game theory.

[0110] IV. Simulation Results:

[0111] Figure 5 Illustrates the system overhead under different numbers of users, showing the best performance of the JSAC algorithm. At the same time, the significant improvement in performance between various algorithms and local computing indicates the powerful parallel computing ability of the GPU. The benefited UEs are those users who can reduce their overhead by offloading tasks to the EC m That is As Figure 6 shown. When there are 20 and 30 users, under the JSAC algorithm, the percentage of benefited UEs is as high as 100%. In addition, the percentage of benefited UEs is inversely proportional to the total number of users because the resources allocated to users are less and less.

[0112] Figure 7Shows the convergence rate of the JSAC algorithm under different numbers of users, which means the effectiveness of the algorithm. The speedup is an indicator that measures the multiple of multi-node parallel computing to single-node sequential computing and is used to describe the effect of parallel computing, that is The overall probability mass function (PMF) and cumulative distribution function (CDF) of the speedup (which is the ratio of the time consumed by the same task running on a single-processor system and a parallel-processor system) are plotted as a bar chart and a line chart respectively in Figure 8 . In the bar chart, when the speedup is less than 4, JSAC is shorter, while in the case where the speedup is greater than 4, JSAC is longer than CATS, which indicates that under the JSAC algorithm, more users obtain a higher speedup. In the line chart, the JSAC curve is more concentrated on the right, which means that users obtain a more obvious average speed increase through the JSAC algorithm. All of the above show that the GPU can bring computing acceleration to the task, and the JSAC algorithm can better utilize the computing performance of the GPU.

[0113] The above-described embodiments merely represent several implementation manners of the present invention, and their descriptions are relatively specific and detailed, but should not be construed as limiting the scope of the invention patent. It should be noted that for those of ordinary skill in the art, without departing from the concept of the present invention, several deformations and improvements can still be made, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the present invention patent shall be subject to the appended claims.

Claims

1. A computing offloading and resource allocation method applicable to a CPU-GPU heterogeneous cluster, characterized in that, Equipped with an edge cluster EC composed of a CPU and a GPU, task problem modeling is carried out for user tasks. With the goal of minimizing the total overhead composed of latency and energy consumption, a task scheduling scheme is determined. The task scheduling scheme includes whether the task is executed locally or offloaded to the edge cluster for execution. If the task is executed by the edge cluster, the task problem modeling is decomposed into three subtasks: offloading decision, transmission power allocation, and computing resource allocation. Corresponding algorithms are matched for subtask scheduling calculation to obtain the scheduling scheme for the edge cluster to execute the task for task execution; The task model for task problem modeling of user tasks is as follows: A user task is decomposed into three segments, and the three segments are of two types, namely two serial segments and one parallel segment; The task starts from the serial segment executed on the CPU, which is a data preprocessing stage; Then, the GPU is used to execute a parallel segment, which is parallelized into several subtasks, and the several subtasks end with the result aggregated to the next executed serial segment, and the next executed serial segment runs on the CPU; Suppose there are N users, denoted by , and each user n has a task A n , that is where represents the size of the task, represents the floating-point operations required at the start and end of the serial segment, represents the floating-point operations required for the parallel segment, represents the number of parallel subtasks; The task problem modeling: The total cost of tasks for all N users is: where represents the uninstallation variable of all users; is the computing resource allocation variable of all users; is the transmission power allocation variable of all users; T n and E n are the total delay and energy consumption of user n respectively; λ t and λe are the weight coefficients of the total delay and energy consumption; The minimized system cost of the modeling is: The goal of this model is to minimize the total system cost, and the constraints are as follows: (1) represents M edge clouds (ECs), and an edge cluster composed of m ECs is denoted as EC m , the offloading decision x n,m takes values of 0 and 1. x n,m = 1 means that user n offloads the task to EC m . If m = 0, the task is executed locally; (2) represents the offloading variables of all users. A user either executes the task locally or offloads it to the edge cluster. Specifically, each x n,m takes a value of 0 or 1. For a certain user n, there is only one choice: execute locally or offload to a certain EC for execution. That is, for a given n, x n,m has only one value of 1, and the rest are 0; (3) The transmission power p n of user n is restricted by the maximum transmission power P n of user n; (4) k m represents the total number of tasks offloaded to cluster EC m , where represents the set of users offloading to EC m , and is restricted by the number of CPUs m of EC ; (5) The number of GPUs allocated to all users for tasks offloaded to cluster EC m does not exceed the total number of GPUs of this cluster. represents the number of GPUs allocated by EC m to user n, and represents the number of GPUs of EC m ; The above task problem is modeled and decomposed into three sub-task solution objectives: The first task, offloading decision Q1, represents the optimization of the user offloading decision variable and on the basis of the optimization under the constraints (1) and (2); The second task, transmission power allocation Q2, represents the optimization of under the constraint (3) when is determined; The third task, computing resource allocation Q3, represents the optimization of under the constraints (4) and (5) when is determined; is optimized; The Q1 offloading decision is a non-linear integer programming problem. The heuristic algorithm simulated annealing is selected, and a random sampling method is used to select an offloading decision variable close to the current solution. The quality of the system is judged by the system cost under the system decision, and the selected offloading decision variable is moved according to the temperature-related probability of selecting a better or worse solution. This solution; Q2 transmission power allocation. According to the constraint of p n The transmission power allocation is approximated as a quasi-convex optimization problem and solved by the bisection method. Within the maximum power limit P n range, the intermediate value of the interval is continuously selected until the optimal solution is selected; Q3 computing resource allocation. The problem is integer programming. By relaxing the relevant integer variables it is approximated as a non-linear programming, and a non-integer solution is obtained through convex optimization, and then approximated as an integer solution as the optimal solution.

2. The computing offloading and resource allocation method applicable to the CPU-GPU heterogeneous cluster according to claim 1, wherein The model constructed by the edge cluster: Use to represent M ECs, each of which is equipped with multiple CPUs and GPUs. A complete GPU is divided into several parts, and each part is regarded as a non-parallelizable GPU to serve a parallel sub-task. The ECs have the following limitations: The computing resources of each GPU in the same EC are the same; Multiple GPUs in the same EC run simultaneously, and each GPU can only be assigned to one parallel subtask; The edge cluster composed of m ECs is represented as: Among them represents the number of CPUs of EC m The number of CPUs, represents the computing power of the CPU, that is, the number of floating-point operations per second, represents the working power of the CPU, represents the standby power of the CPU. The parameters of the GPU are similar to those of the CPU.

Citation Information

Patent Citations

  • LTE power wireless private network task unloading and resource allocation method based on cloud side cooperation

    CN111585916A

  • Task unloading and resource allocation method in uncertain network environment

    CN113242568A