A cloud-edge collaborative task scheduling method and device

The cloud-edge collaborative task scheduling method optimizes task allocation between cloud and edge nodes by considering priorities, delays, and costs, addressing inefficiencies and cost overloads in power systems.

CN114595049BActive Publication Date: 2024-12-17GLOBAL ENERGY INTERCONNECTION RES INST CO LTD +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210251795.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-15
Publication Date
2024-12-17
Estimated Expiration
2042-03-15

AI Technical Summary

Technical Problem

Existing cloud computing systems face challenges in meeting low-latency requirements for delay-sensitive tasks in power systems, leading to inefficiencies and increased economic costs, while edge computing alone may overload edge nodes with large task loads.

Method used

A cloud-edge collaborative task scheduling method that determines task priorities, computing delays, and unloading costs to optimize task allocation between cloud centers and edge nodes, using a biogeographic natural evolution algorithm to balance latency and cost objectives.

Benefits of technology

The method improves computing efficiency and reduces costs by ensuring tasks are processed within latency requirements and allocated to optimal resources, enhancing system throughput and user satisfaction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114595049B_ABST
    Figure CN114595049B_ABST
Patent Text Reader

Abstract

The present invention provides a cloud-edge collaborative task scheduling method and device, wherein the method includes: determining the pending tasks of each terminal node and the business priority of each pending task; respectively determining the first total computing delay and the first unloading cost of each pending task unloaded to each edge node, and the second total computing delay and the second unloading cost of each pending task unloaded to the cloud center; establishing an optimization target according to the business priority of each pending task, the first total computing delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total computing delay, and the second unloading cost; solving the optimization target to obtain the scheduling scheme of each pending task; and respectively allocating each pending task to the corresponding edge node or cloud center according to the scheduling scheme. By executing the present invention, both actual business needs are met and computing efficiency is improved and computing cost is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of power system communication technology, and in particular to a cloud-edge collaborative task scheduling method and device. Background Art

[0002] With the advent of the 5G commercial era, many emerging power businesses have emerged in the power industry. With the increase in power terminal equipment, the amount of data generated by power terminals has also exploded. The traditional terminal-to-master mode can no longer quickly respond to the low-latency requirements of the business, and the economic operating costs generated by the surge in business are also increasing. Although cloud computing systems can effectively process intensive big data, they bring challenges to data transmission channels and cannot meet the needs of delay-sensitive tasks. Therefore, some researchers have proposed solutions to relieve the pressure on cloud centers by deploying edge servers with computing and data storage capabilities at the edge of the network, and can meet the latency requirements of some delay-sensitive tasks. Generally accepted edge computing systems include mobile cloud computing (MCC), fog computing, and multi-access edge computing (MEC). Cloud computing and edge computing each have their own advantages and disadvantages. The combination of cloud-edge collaboration can give full play to the advantages of both and provide better services to users. In smart grids, it is necessary to provide cloud-edge collaborative scheduling methods that can further improve the efficiency of task execution. Summary of the invention

[0003] Therefore, the technical problem to be solved by the present invention is to overcome the defect of low task execution efficiency in the prior art, thereby providing a cloud-edge collaborative task scheduling method and device.

[0004] A first aspect of the present invention provides a cloud-edge collaborative task scheduling method, which is applied to a cloud-edge collaborative system, wherein the cloud-edge collaborative system includes a cloud center, at least one edge node, and at least one terminal node, wherein the method includes: determining the tasks to be processed of each terminal node, and the business priority of each task to be processed; respectively determining the first total computing delay and the first unloading cost of each task to be processed when unloading to each edge node, and the second total computing delay and the second unloading cost when unloading to the cloud center; establishing an optimization target according to the business priority of each task to be processed, the first total computing delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total computing delay, and the second unloading cost; solving the optimization target to obtain a scheduling plan for each task to be processed; and assigning each task to be processed to the corresponding edge node or cloud center according to the scheduling plan.

[0005] Optionally, in the cloud-edge collaborative task scheduling method provided by the present invention, an optimization target is established according to the business priority of each task to be processed, the first total computational delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total computational delay, and the second unloading cost, including: establishing a delay optimization sub-target according to the first total delay corresponding to unloading each task to be processed to each edge node, and the second total delay unloading to the cloud center; establishing an unloading cost optimization sub-target according to the first unloading cost corresponding to unloading each task to be processed to each edge node, and the second unloading cost unloading to the cloud center; determining the delay optimization sub-target weight according to the business priority of each task to be processed, and comprehensively evaluating the delay optimization sub-target and the unloading cost optimization sub-target according to the delay optimization sub-target weight to obtain the optimization target.

[0006] Optionally, in the cloud-edge collaborative task scheduling method provided by the present invention, the delay optimization sub-goal after standard normalization and the offloading cost optimization sub-goal after standard normalization are comprehensively evaluated according to the delay optimization sub-goal weight to obtain the optimization target.

[0007] Optionally, in the cloud-edge collaborative task scheduling method provided by the present invention, the step of solving the optimization objective and obtaining a scheduling scheme for each task to be processed includes: determining the cloud center and each edge node as habitats, initializing the correspondence between each habitat and the task to be processed, and one habitat corresponds to one or more tasks to be processed; calculating the habitat suitability index of each task to be processed corresponding to the habitat according to the objective function; the objective function is determined according to the optimization objective, and is used to calculate the total cost when the task to be processed is unloaded to any edge node or cloud center, and the total cost is determined as the habitat suitability index of the task to be processed in the habitat corresponding to the edge node or cloud center; for each habitat, sorting the tasks to be processed corresponding to the habitat according to the habitat suitability index, and dividing the tasks to be processed corresponding to the habitat into a non-dominated set and a dominated set according to the sorting result, and the habitat suitability index of the tasks to be processed in the non-dominated set is greater than the habitat suitability index of the tasks to be processed in the dominated set. index; determine the habitat to be migrated into and the habitat to be migrated out according to the migration rate and migration rate of each habitat, randomly migrate one or more pending tasks in the dominating set of the habitat to be migrated out into the habitat to be migrated into, and calculate the habitat applicability index of each pending task corresponding to each habitat after the migration operation; determine the habitat to be mutated according to the mutation rate of each habitat, perform mutation operation on the habitat to be mutated, and calculate the habitat applicability index of each pending task corresponding to each habitat after the mutation operation; if the current iteration result does not meet the preset conditions, for each habitat, sort the pending tasks corresponding to the habitat according to the habitat applicability index, update the non-dominated set and the dominating set according to the sorting result, return to the step of determining to perform the migration operation on one or more pending tasks in the dominating set corresponding to the habitat according to the migration rate and migration rate of each habitat, until the current iteration result meets the preset conditions, and determine the corresponding relationship between the current habitats and the pending tasks as the scheduling plan for each pending task.

[0008] Optionally, in the cloud-edge collaborative task scheduling method provided by the present invention, the correspondence between each habitat and the tasks to be processed is initialized, including: if the density of the tasks to be processed is greater than a preset value, the habitat to which the tasks to be processed belong corresponds to the cloud center.

[0009] Optionally, in the cloud-edge collaborative task scheduling method provided by the present invention, the dynamic selection probability of each habitat is calculated according to the emigration rate of each habitat, and the habitat to be emigrated is determined in combination with the dynamic selection probability; the dynamic selection probability is calculated by the following formula: Among them, μ i and μ j Represents habitat D i and D j The migration rate, t is the current iteration number, and T is the iteration cutoff number.

[0010] Optionally, in the cloud-edge collaborative task scheduling method provided by the present invention, the mutation rate of each habitat is calculated by an adaptive Lévy mutation operator: i (SIV)←H i (SIV)+L SIV (N(0.5,0.1)), Among them, H i represents the SIV value of the i-th habitat, 0<β<2 is used to control the shape of the curve; γ is the proportional factor; L SIV (·) indicates that each fitness index variable vector generates a random number according to the Lévy distribution; N(0.5,0.1) means that the Gaussian distribution will be distributed around 0.5 with a high probability.

[0011] The second aspect of the present invention provides a cloud-edge collaborative task scheduling device, which is applied to a cloud-edge collaborative system, wherein the cloud-edge collaborative system includes a cloud center, at least one edge node, and at least one terminal node, wherein the device includes: a business priority determination module, used to determine the pending tasks of each terminal node, and the business priority of each pending task; a cost calculation module, used to respectively determine the first total computing delay and the first unloading cost of each pending task unloaded to each edge node, and the second total computing delay and the second unloading cost of unloading to the cloud center; an optimization target establishment module, used to establish an optimization target according to the business priority of each pending task, the first total computing delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total computing delay, and the second unloading cost; an optimization target solving module, used to solve the optimization target and obtain a scheduling plan for each pending task; a task scheduling module, used to assign each pending task to the corresponding edge node or cloud center according to the scheduling plan.

[0012] The third aspect of the present invention provides a computer device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, thereby executing the cloud-edge collaborative task scheduling method provided in the first aspect of the present invention.

[0013] A fourth aspect of the present invention provides a computer-readable storage medium, which stores computer instructions, and the computer instructions are used to enable the computer to execute the cloud-edge collaborative task scheduling method provided in the first aspect of the present invention.

[0014] The technical solution of the present invention has the following advantages:

[0015] The cloud-edge collaborative task scheduling method and device provided by the present invention establish an optimization target according to the business priority of each task to be processed, the first total computing delay and the first unloading cost of unloading each task to be processed to each edge node, and the second total computing delay and the second unloading cost of unloading each task to be processed to the cloud center. Since the optimization target is established in combination with the first total computing delay, the first unloading cost, the second total computing delay, and the second unloading cost, the scheduling scheme obtained by calculating the optimization target can complete the calculation of the task to be processed in a shorter time and at a lower cost. Moreover, since the optimization target is established in combination with the business priority of the task to be processed, the scheduling scheme obtained by calculating the optimization target can meet the delay requirements of each task to be processed. It can be seen that by executing the present invention, both actual business needs are met and the computing efficiency is improved and the computing cost is reduced. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0017] Figure 1 A schematic diagram of a model of a cloud-edge collaborative system in an embodiment of the present invention;

[0018] Figure 2 This is a flowchart of a specific example of the cloud-edge collaborative task scheduling method in an embodiment of the present invention;

[0019] Figure 3 A flowchart of a specific example of a process for solving an optimization target in an embodiment of the present invention;

[0020] Figure 4 It is a principle block diagram of a specific example of a cloud-edge collaborative task scheduling device in an embodiment of the present invention;

[0021] Figure 5 It is a principle block diagram of a specific example of a computer device in an embodiment of the present invention. DETAILED DESCRIPTION

[0022] The technical solution of the present invention will be described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them. 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.

[0023] In the description of the present invention, it should be noted that the terms “first”, “second” and “third” are only used for descriptive purposes and cannot be understood as indicating or implying relative importance.

[0024] In addition, the technical features involved in the different embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other.

[0025] With the increase in power terminal devices, the business generated by power terminal devices is also increasing. In order to achieve efficient processing of all pending tasks in the system, the existing technology uses the cloud-edge collaborative scheduling method to assign each pending task to different edge nodes and cloud centers for execution. However, the existing scheduling method only considers the single goal of optimizing latency, and does not take into account the priority of pending tasks, scheduling between edge nodes, and other issues.

[0026] The embodiment of the present invention provides a cloud-edge collaborative task scheduling method, which is applied to Figure 1 The cloud-edge collaborative system shown in the figure includes a cloud center, at least one edge node, and at least one terminal node. The cloud center is mainly composed of virtual machines, including a computing module for computing tasks, a core network transmission module, and a program scheduling module for coordinating the batch processing tasks of the entire system resource nodes. The edge node is composed of a base station and a deployed MEC server, which is deployed near the terminal node. If the cloud-edge collaborative system is used to process power business, the terminal node is a power terminal device.

[0027] The cloud-edge collaborative task scheduling method provided by the embodiment of the present invention is as follows Figure 2 As shown, the following steps are included:

[0028] Step S11: Determine the tasks to be processed of each terminal node and the service priority of each task to be processed.

[0029] In an optional embodiment, in the smart grid, the services are generally divided into power grid control services, information collection services and mobile application services. Among them, power grid control services have millisecond-level low latency and high reliability business characteristics, mainly including distribution network differential protection, precise load control, distributed power supply control, etc.; information collection services have business characteristics of wide coverage and large links, accounting for a large proportion of the total data volume, mainly including electricity information collection, etc.; mobile application services have business characteristics of large bandwidth and flexible access, mainly including robot inspection, mobile operation, etc. Different types of services have different requirements for latency. The service priority referred to in the implementation of the present invention refers to the latency priority. The service priority of the task to be processed is determined according to the service type to which the task to be processed belongs.

[0030] Step S12: Determine the first total computing delay and the first offloading cost of each to-be-processed task being offloaded to each edge node, and the second total computing delay and the second offloading cost being offloaded to the cloud center.

[0031] In an embodiment of the present invention, the cloud-edge collaborative system includes multiple edge nodes. Unloading the tasks to be processed to different edge nodes will result in different first total computing delays and first offloading costs.

[0032] In an optional embodiment, the first total calculation delay includes a transmission delay when the terminal node transmits the task to be processed to the edge node and a calculation delay when the edge node calculates the task to be processed.

[0033] In an optional embodiment, the first offloading cost includes a computational cost when the edge node executes the task to be processed and a traffic cost when the terminal node transmits the task to be processed to the edge node.

[0034] In an optional embodiment, the second total calculation delay includes the transmission delay when the terminal node transmits the task to be processed to the edge node, the transmission delay when the edge node transmits the task to be processed to the cloud center, and the calculation delay when the cloud center calculates the task to be processed.

[0035] In an optional embodiment, the second offloading cost includes the computing cost when the cloud center executes the task to be processed, the traffic cost when the terminal node transmits the task to be processed to the edge node, and the traffic cost when the edge node transmits the task to be processed to the cloud center.

[0036] Step S13: Establish an optimization target according to the service priority of each task to be processed, the first total calculation delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total calculation delay, and the second unloading cost.

[0037] Business priority refers to latency priority. Different tasks have different business priorities and different latency requirements. Therefore, establishing optimization goals based on business priorities can meet the latency requirements of each task on the basis of reducing the total computing latency and offloading cost of all tasks to be processed.

[0038] Step S14: Solve the optimization target and obtain the scheduling plan for each task to be processed.

[0039] In an embodiment of the present invention, the scheduling scheme is used to characterize the correspondence between each task to be processed and each edge node and cloud center, so that the computing platform of each task to be processed can be determined according to the scheduling scheme.

[0040] Step S15: Allocate each task to be processed to the corresponding edge node or cloud center according to the scheduling plan.

[0041] In the embodiment of the present invention, one task to be processed can only correspond to one edge node or cloud center, that is, one task to be processed can only be calculated in one edge node or cloud center.

[0042] The cloud-edge collaborative task scheduling method provided by the embodiment of the present invention establishes an optimization target according to the business priority of each task to be processed, the first total computing delay and the first unloading cost of unloading each task to be processed to each edge node, and the second total computing delay and the second unloading cost of unloading each task to be processed to the cloud center. Since the optimization target is established in combination with the first total computing delay, the first unloading cost, the second total computing delay, and the second unloading cost, the scheduling scheme obtained by calculating the optimization target can complete the calculation of the task to be processed in a shorter time and at a lower cost. Moreover, since the optimization target is established in combination with the business priority of the task to be processed, the scheduling scheme obtained by calculating the optimization target can meet the delay requirements of each task to be processed. It can be seen that the cloud-edge collaborative task scheduling method provided by the embodiment of the present invention not only meets actual business needs, but also improves computing efficiency and reduces computing costs.

[0043] In an optional embodiment, assume that there is a cloud center, I edge nodes and J power terminal devices in the system. i represents the i-th base station in the system, 1≤i≤I, Represents a collection of base stations, whose computing and storage capabilities are limited. Indicates base station D i The set of j terminal nodes within the range. Assume that there are K edge nodes in the system that can provide business computing capabilities, n k Represents the kth computing node, using Represents a collection of compute nodes.

[0044] Task i,j Indicates base station D i The task to be processed by the jth power terminal device in the range for unloading is The unit is bits. In order to define the computational complexity of different tasks, C i,j Indicates the computing power required to calculate unit data, in cycles / bit. Assuming that all pending tasks are generated at the same time and the tasks are independent of each other, then the pending tasks Task i,j The total amount of computation required for:

[0045] Assume that a task to be processed is indivisible and can only be offloaded to the cloud center or left on the edge node. i,j Indicates whether the pending task is offloaded to the cloud center for processing, where x i,j=0 indicates pending tasks i,j is transmitted to the cloud center for processing, instead x i,j =1 indicates pending tasks i,j Leave it to the edge node for processing.

[0046] Define R i,j For Task i,j The expected channel capacity of the terminal node, then the task to be processed Task i,j The average transmission delay from the terminal node to the associated edge node is:

[0047] Assuming that all task information is transmitted to the node before scheduling and execution, the computing node allocates computing resources according to the allocated computing amount. The total computing load allocated to the computing node nk is The calculation rate is When a task to be processed is selected to be processed at an edge node, the scheduler needs to further determine whether the task is at node n. k Execute on, using x i,j, k represents the task i,j Whether it is scheduled to execute on node nk, if k Execute on, then let x i,j, k=1, otherwise, let x i,j, k=0. For the convenience of representation, m is used. i,j Indicates the tasks to be processed after scheduling i,j The node number assigned, in particular, is represented by m i,j =0 means offloading the task to the cloud center for execution, then m i,j ={0,1,...,K}. When the edge node uses CPU parallel computing for the assigned tasks to be processed, the waiting time of the tasks to be processed can be ignored. i,j At node n k Assigned speed and computational latency It can be calculated by the following formula:

[0048]

[0049]

[0050] Then the pending tasks Task i,j Select the total latency of the first calculation performed on the edge node for:

[0051] If the task to be processed is chosen to be executed in the cloud center, it must pass through the link between the cloud center and the edge node. Since the task transmission line from each base station to the cloud center is independent, the bandwidth allocated to the task to be processed is set to be constant, represented by B, in bit / s, and the computing power of the cloud center is set to v center , then the transmission time of the task to be processed from the edge node to the cloud center is and computing time in the cloud center They are:

[0052]

[0053]

[0054] Then the pending tasks Task i,j Select the total latency of the second calculation to be performed in the cloud center for:

[0055] Generally speaking, the computing module and transmission scheduling module of the edge node do not affect each other. In the embodiment of the present invention, the delay overhead of transmission execution between the edge node and the cloud center is mainly considered. The running time of the scheduler and the return time of the calculation result can be ignored. Therefore, Task i,j The total delay can be expressed as:

[0056]

[0057] Considering that in 5G networks, the data of pending tasks is unloaded at the edge and unloaded at the cloud center, and the data traffic transmitted and billed is significantly different, which also directly affects the service carrying cost. Therefore, the factor of unloading cost is considered in the embodiment of the present invention. The unloading cost includes computing cost and traffic cost. The computing cost refers to the cost of edge nodes and cloud centers to calculate the pending tasks. The stronger the computing power, the higher the hardware cost of the equipment. The traffic cost refers to the traffic consumed by uploading the pending tasks to the cloud center and edge nodes, and the traffic cost generated.

[0058] When edge nodes and cloud centers execute tasks, they will incur operating costs related to computing load. e is the unit time running cost of the edge node, which is proportional to the square of the computing power of the edge node. In the embodiment of the present invention, the unit time running cost of all edge nodes is the same, and the expression is:

[0059]

[0060] in It is the cost coefficient related to the edge node CPU.

[0061] Use αc represents the unit time operation cost of the cloud center. It is known that task K is obtained i,j The execution time at the edge node and the cloud center is respectively calculated as:

[0062]

[0063]

[0064] Traffic cost refers to the traffic consumed by uploading the task to be processed to the edge node and the cloud center. Assume that the bandwidth from the terminal node to the edge node is W, then the task to be processed Task i,j The traffic generated by offloading to edge nodes and cloud centers is:

[0065]

[0066]

[0067] The first offloading cost of offloading the pending task to the edge node is:

[0068] The second offloading cost of offloading pending tasks to the cloud center is:

[0069] Therefore, the pending task K i,j The cost of offloading can be expressed as:

[0070]

[0071] In an optional embodiment, the above step S13 specifically includes the following steps:

[0072] First, a latency optimization sub-goal is established based on the first total latency corresponding to offloading each pending task to each edge node and the second total latency to offload to the cloud center. The latency optimization sub-goal is used to reduce the total computation latency of each pending task.

[0073] Then, an offloading cost optimization sub-goal is established according to the first offloading cost corresponding to offloading each pending task to each edge node and the second offloading cost to the cloud center. The offloading cost optimization sub-goal is used to reduce the offloading cost of each pending task.

[0074] Finally, the weight of the delay optimization sub-goal is determined according to the business priority of each task to be processed. The delay optimization sub-goal and the offloading cost optimization sub-goal are comprehensively evaluated according to the weight of the delay optimization sub-goal to obtain the optimization goal.

[0075] Usually, the computing power of the cloud center is 100 to 10K times that of the edge node. Although the transmission to the cloud center for unloading can reduce the computing delay, it brings more transmission delay and cost. If all the calculations are offloaded to the nearby edge nodes, although the delay can be reduced, when the number of tasks is large enough, it will bring a huge load to the edge nodes. As a result, the performance of the edge nodes will be reduced, and the needs of delay-sensitive tasks cannot be met. If only a single optimization goal is considered, it is meaningless. Therefore, in the embodiment of the present invention, the delay and cost functions are combined as the cost overhead of the cloud-edge collaborative system to consider the multi-objective joint optimization problem. In addition, it can be seen from the analysis that there is a conflict between the two optimization sub-goals. In the embodiment of the present invention, the delay optimization sub-goal weight will be introduced to comprehensively evaluate the delay and cost of the task scheduling scheme, and the optimization of delay and cost will be combined into a new optimization goal.

[0076] In an optional embodiment, when establishing an optimization target in the cloud-edge collaborative task scheduling method provided in an embodiment of the present invention, a comprehensive evaluation is performed on the delay optimization sub-target after standard normalization and the unloading cost optimization sub-target after standard normalization according to the delay optimization sub-target weight to obtain the optimization target.

[0077] By normalizing the delay optimization sub-goal and the unloading cost optimization sub-goal, the vertical difference caused by different goals can be reduced.

[0078] In an optional embodiment, the two sub-goals can be normalized by using an aggregation function.

[0079] In an optional embodiment, in the cloud-edge collaborative task scheduling method provided in the embodiment of the present invention, the optimization goal is:

[0080] min

[0081] st(C1)x i,j ∈{0,1},

[0082]

[0083]

[0084] (C4)θ∈[0,1]

[0085] T min 、T max , Q min , Q maxThey represent the minimum and maximum values ​​of latency and cost when a single task to be executed chooses different offloading paths. The C1 constraint means that the task to be processed can only be offloaded in the cloud center or edge node; the C2 and C3 constraints mean that the task to be processed can be offloaded and executed on the only computing node including the cloud center.

[0086] In an optional embodiment, when solving the optimization goal, x is used to represent the result of the scheduling feasible solution, and X is the set of all x solution vectors, that is, the solution space. According to the problem model, x can be represented by a three-dimensional vector:

[0087]

[0088] For the convenience of representation, in the embodiment of the present invention, the computing node k=0 is represented as a cloud center.

[0089] In an optional embodiment, in the cloud-edge collaborative task scheduling method provided by an embodiment of the present invention, a biogeographic Natural Evolution (BNE) algorithm that considers business priorities to meet the latency requirements of power business is used. The algorithm continuously evolves the algorithm solution population with the help of migration and mutation operations, thereby solving the task scheduling optimization problem of cloud-edge collaboration.

[0090] In the BNE algorithm, each individual is located in a different habitat, and the suitability of the individual in the habitat is represented by the Habitat Suitability Index (HIS). The HIS is related to the habitat factor called the Suitability Index Variable (SIV). Each habitat with D-dimensional SIV is considered a feasible solution, and each dimensional SIV is considered a variable of the feasible solution. Habitats with high HIS have high emigration rates and low immigration rates due to the large population size. On the contrary, habitats with low HIS have low emigration rates and high immigration rates.

[0091] In an optional embodiment, in the cloud-edge collaborative task scheduling method provided in the embodiment of the present invention, the specific solution process of the optimization target is as follows: Figure 3 As shown, the following steps are included:

[0092] Step S141: The cloud center and each edge node are determined as habitats, and the corresponding relationship between each habitat and the tasks to be processed is initialized. One habitat corresponds to one or more tasks to be processed.

[0093] In the embodiment of the present invention, the number of habitats is the total number of cloud centers and edge nodes. One habitat corresponds to one population, and one population includes one or more tasks to be processed.

[0094] In an optional embodiment, the initialized data also includes the size of the habitat population, and the size of the habitat population is used to characterize the maximum amount of computing that the habitat can bear.

[0095] In an optional embodiment, the pending tasks that need to be offloaded generated by all terminal nodes in the system are regarded as a group and each task individual is numbered, i is used to represent the numbering order of the tasks in the set, 1≤i≤I. The node number of the cloud center is defined as k=0, and the node is represented by k, 0≤k≤K. The fitness index variable SIV of N habitats is randomly generated, corresponding to a D-dimensional variable, and one population survives in one habitat. In the embodiment of the present invention, D i It is represented as the schedule of pending tasks i, so the constraints of the optimization objective can be transformed into D i ∈{0,1,2,...,K}, the solution to the problem can be obtained by using the vector D=[D1,D2,...D N ],D i =(d i1 ,d i2 ,...d iD ). The vector D corresponds to the SIVs vector of the individual, and the joint objective function value corresponds to the HIS of the habitat. The HIS of each habitat is calculated based on D and the objective function.

[0096] Step S142: Calculate the habitat suitability index of each pending task corresponding to the habitat according to the objective function; the objective function is determined according to the optimization goal, and is used to calculate the total cost when the pending task is unloaded to any edge node or cloud center, and the total cost is determined as the habitat suitability index of the pending task in the habitat corresponding to the edge node or cloud center.

[0097] In an alternative embodiment, the objective function is

[0098] Step S143: For each habitat, sort the pending tasks corresponding to the habitat according to the habitat suitability index, and divide the pending tasks corresponding to the habitat into a non-dominated set and a dominated set according to the sorting result, and the habitat suitability index of the pending tasks in the non-dominated set is greater than the habitat suitability index of the pending tasks in the dominated set.

[0099] In an optional embodiment, the larger the habitat suitability index value of the pending task in the current habitat, the more likely the current habitat is to meet the needs of the pending task. Therefore, after sorting the pending tasks according to the habitat usage index, the first n pending tasks are added to the non-dominated set, and there is no need to perform migration operations on the pending tasks in the non-dominated set subsequently, thereby improving the efficiency of solving the optimization objective, wherein the value of n can be set according to actual needs.

[0100] Step S144: Determine the habitat to be migrated into and the habitat to be migrated out according to the migration rate and migration rate of each habitat, randomly migrate one or more pending tasks in the dominant set of the habitat to be migrated out into the habitat to be migrated into, and calculate the habitat suitability index of each pending task corresponding to each habitat after the migration operation is performed.

[0101] Step S145: determining the habitat to be mutated according to the mutation rate of each habitat, performing a mutation operation on the habitat to be mutated, and calculating the habitat suitability index of each task to be processed corresponding to each habitat after the mutation operation.

[0102] Determine whether the current iteration result meets the preset conditions. If the current iteration result does not meet the preset conditions, perform the following steps:

[0103] Step S146: For each habitat, sort the pending tasks corresponding to the habitat according to the habitat suitability index, and update the non-dominated set and the dominated set according to the sorting result.

[0104] In an optional embodiment, when updating the non-dominated set, the first m pending tasks are added to the non-dominated set to form an updated non-dominated set. At this time, the non-dominated set of the habitat includes the pending tasks in the non-dominated set in the previous iteration process and the first m pending tasks in the current sorting result.

[0105] In an optional embodiment, the values ​​of n and m may be the same or different, that is, the number of tasks to be processed added to the non-dominated set in each iteration may be the same or different.

[0106] In an optional embodiment, the pending tasks ranked last n and the pending tasks added to the non-dominated set may be removed, and the remaining pending tasks may be used as a new dominating set to complete the updating of the dominating set.

[0107] Return to the above step S144, and execute step S147 until the current iteration result meets the preset condition.

[0108] Step S147: Determine the correspondence between each current habitat and the tasks to be processed as a scheduling plan for each task to be processed.

[0109] In an optional embodiment, if the current number of iterations reaches an iteration threshold, the current iteration result is determined to meet a preset condition. The iteration threshold is set when initializing parameters in the above step S141. Exemplarily, the iteration threshold may be 600 CPU cycle / bit.

[0110] In an optional embodiment, in the cloud-edge collaborative system, for some tasks with super-intensive tasks, if the tasks to be processed are offloaded to the edge nodes for processing, it will overload the edge nodes and cause high overhead costs. Therefore, for super-intensive tasks, it is more reasonable to dispatch them to the cloud center for processing. Therefore, when initializing the correspondence between each habitat and the tasks to be processed, if the density of the tasks to be processed is greater than the preset value C thre , the habitat to which the task to be processed belongs is determined as the habitat corresponding to the cloud center, thereby improving the HIS value and evolution efficiency of the initialized population.

[0111] In an optional embodiment, in the above step S144, the immigration rate λ is calculated for each habitat. i and the emigration rate μ i , first select the most suitable habitat to be migrated according to the size of the migration rate D i Then, according to the migration rate, the habitat D to be migrated is selected. j From D j Randomly select SIV components to replace D i The corresponding component in the above equation is used to calculate the new habitat fitness HIS. i and the emigration rate μ i The expression is as follows:

[0112]

[0113]

[0114] Among them, S i and S max Indicates the population size of the habitat and the maximum value that can be accommodated, and I and E represent the maximum values ​​of the immigration rate and the emigration rate. When the immigration rate and the emigration rate are equal, the population size reaches an equilibrium state. In order to allow the tasks with lower HIS to be processed to migrate to the habitat of larger HIS with a higher probability in the early stage of evolution, and to allow the better solution to continue to participate in the migration in the later stage of evolution, thereby improving the accuracy of the solution, the embodiment of the present invention adopts a dynamic selection probability P i Replace the previous random selection probability to determine the habitat D to be migrated i , P i is defined as follows:

[0115]

[0116]

[0117] Among them, μ i and μ j Corresponding to habitat D i and D jThe migration rate, t is the current number of iterations, and T is the iteration cutoff number.

[0118] In an optional embodiment, the mutation operator will affect the fitness of the current habitat, so that the habitat with low fitness will mutate with a high probability, providing more opportunities for the habitat with low fitness to be searched, and the mutation probability m i It is inversely proportional to the number of individuals in the habitat and can be expressed as:

[0119]

[0120] Among them, m max The maximum mutation rate is user-defined; P(S i ) is the population size S i The probability of max P(S i ) is the maximum value of .

[0121] In the cloud-edge collaborative system, the cloud center is regarded as a special edge node, but the proportion of the cloud center is very small, and the probability of being randomly selected for mutation is very low, which will affect the search for the optimal solution. Therefore, in order to increase the probability of cloud center mutation, the mutation operator is adjusted in the embodiment of the present invention to increase the probability of cloud center mutation, and an adaptive Lévy mutation operator is introduced:

[0122] H i (SIV)←H i (SIV)+L SIV (N(0.5,0.1)),

[0123] The probability density function expression of Lévy distribution is:

[0124]

[0125] Among them, H i represents the SIV value of the i-th habitat, 0<β<2 is used to control the shape of the curve; γ is the proportional factor, generally 1; L SIV (·) means that each variable in the vector SIVs generates a random number according to the Lévy distribution; N(0.5,0.1) means that the Gaussian distribution will be distributed around 0.5 with a high probability; x is a real number.

[0126] The cloud-edge collaborative task scheduling method provided by the embodiment of the present invention adopts the biogeographic natural evolution algorithm to calculate the optimization target, and can calculate the end-to-end delay and cost weighted sum of the pending tasks under different unloading paths according to the needs of different pending tasks, and select the method with the lowest cost overhead for unloading processing. At the same time, it can ensure that the pending tasks with high priority are allocated to sufficient resources, and schedule the pending tasks to be unloaded to other edge nodes with idle resources, thereby reducing the total delay of the pending tasks in the system, thereby improving the throughput of the system and user satisfaction. The method provided by the embodiment of the present invention can effectively solve the problems of resource waste and non-compliance with delay requirements caused by unreasonable task scheduling in the system.

[0127] The embodiment of the present invention provides a cloud-edge collaborative task scheduling device, which is applied to Figure 1 The cloud-edge collaborative system shown in the figure includes a cloud center, at least one edge node, and at least one terminal node. Figure 4 As shown, the device comprises:

[0128] The service priority determination module 21 is used to determine the pending tasks of each terminal node and the service priority of each pending task. For details, please refer to the description of step S11 in the above embodiment, which will not be repeated here.

[0129] The cost calculation module 22 is used to respectively determine the first total computing delay and the first unloading cost of each task to be processed when unloading to each edge node, and the second total computing delay and the second unloading cost when unloading to the cloud center. For details, please refer to the description of step S12 in the above embodiment, which will not be repeated here.

[0130] The optimization target establishing module 23 is used to establish the optimization target according to the business priority of each task to be processed, the first total calculation delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total calculation delay, and the second unloading cost. For details, please refer to the description of step S13 in the above embodiment, which will not be repeated here.

[0131] The optimization target solving module 24 is used to solve the optimization target and obtain the scheduling plan for each task to be processed. For details, please refer to the description of step S14 in the above embodiment, which will not be repeated here.

[0132] The task scheduling module 25 is used to allocate each task to be processed to the corresponding edge node or cloud center according to the scheduling plan. For details, please refer to the description of step S15 in the above embodiment, which will not be repeated here.

[0133] An embodiment of the present invention provides a computer device, such as Figure 5 As shown, the computer device mainly includes one or more processors 31 and a memory 32. Figure 5 A processor 31 is taken as an example.

[0134] The computer device may further include: an input device 33 and an output device 34 .

[0135] The processor 31, the memory 32, the input device 33 and the output device 34 may be connected via a bus or other means. Figure 5 The example of connecting through bus is taken in the following.

[0136] The processor 31 may be a central processing unit (CPU). The processor 31 may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, or a combination of the above chips. The general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc. The memory 32 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the cloud-edge collaborative task scheduling device, etc. In addition, the memory 32 may include a high-speed random access memory, and may also include a non-transitory memory, such as at least one disk storage device, a flash memory device, or other non-transitory solid-state storage device. In some embodiments, the memory 32 may optionally include a memory remotely arranged relative to the processor 31, and these remote memories may be connected to the cloud-edge collaborative task scheduling device via a network. The input device 33 can receive the calculation request (or other digital or character information) input by the user, and generate key signal input related to the cloud-edge collaborative task scheduling device. The output device 34 can include a display device such as a display screen to output the calculation results.

[0137] An embodiment of the present invention provides a computer-readable storage medium, which stores computer instructions, and the computer storage medium stores computer executable instructions, which can execute the cloud-edge collaborative task scheduling method in any of the above method embodiments. Among them, the storage medium can be a disk, an optical disk, a read-only memory (ROM), a random access memory (RAM), a flash memory (Flash Memory), a hard disk (HDD) or a solid-state drive (SSD), etc.; the storage medium can also include a combination of the above types of memory.

[0138] Obviously, the above embodiments are merely examples for the purpose of clear explanation, and are not intended to limit the implementation methods. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the implementation methods here. The obvious changes or modifications derived therefrom are still within the scope of protection of the invention.

Claims

1. A cloud-edge collaborative task scheduling method, applied to a cloud-edge collaborative system, wherein the cloud-edge collaborative system includes a cloud center, at least one edge node, and at least one terminal node, characterized in that: The method comprises: Determine the tasks to be processed for each terminal node and the business priority of each task to be processed; Determine respectively a first total computing delay and a first offloading cost of each to-be-processed task being offloaded to each edge node, and a second total computing delay and a second offloading cost of each to-be-processed task being offloaded to the cloud center; Establishing an optimization target according to the service priority of each task to be processed, the first total computing delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total computing delay, and the second unloading cost; Solving the optimization goal to obtain a scheduling plan for each task to be processed; Allocate each task to be processed to the corresponding edge node or cloud center according to the scheduling scheme; An optimization target is established according to the business priority of each task to be processed, the first total computing delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total computing delay, and the second unloading cost, including: Establishing a latency optimization sub-goal according to a first total latency corresponding to offloading each to-be-processed task to each edge node and a second total latency corresponding to offloading to the cloud center; Establishing an offloading cost optimization sub-goal according to a first offloading cost corresponding to offloading each to-be-processed task to each edge node and a second offloading cost corresponding to offloading to the cloud center; Determine the delay optimization sub-goal weight according to the service priority of each task to be processed, and comprehensively evaluate the delay optimization sub-goal and the offloading cost optimization sub-goal according to the delay optimization sub-goal weight to obtain the optimization goal; The optimization goal is: , , , They represent the minimum and maximum values ​​of latency and cost when a single task to be executed selects different offloading paths; The constraint means that the tasks to be processed can only be offloaded in the cloud center or edge nodes; and The constraint means that all pending tasks can be offloaded and executed on a unique computing node including the cloud center.

2. The cloud-edge collaborative task scheduling method according to claim 1 is characterized in that: According to the delay optimization sub-objective weight, a comprehensive evaluation is performed on the delay optimization sub-objective after standard normalization and the offloading cost optimization sub-objective after standard normalization to obtain the optimization objective.

3. The cloud-edge collaborative task scheduling method according to claim 1 is characterized in that: The step of solving the optimization objective and obtaining a scheduling solution for each task to be processed includes: Determine the cloud center and each edge node as a habitat, initialize the corresponding relationship between each habitat and the task to be processed, and one habitat corresponds to one or more tasks to be processed; Calculate the habitat suitability index of each pending task corresponding to the habitat according to the objective function; the objective function is determined according to the optimization goal and is used to calculate the total cost when the pending task is unloaded to any edge node or cloud center, and the total cost is determined as the habitat suitability index of the pending task in the habitat corresponding to the edge node or cloud center; For each habitat, sorting the pending tasks corresponding to the habitat according to the habitat suitability index, and dividing the pending tasks corresponding to the habitat into a non-dominated set and a dominated set according to the sorting result, wherein the habitat suitability index of the pending tasks in the non-dominated set is greater than the habitat suitability index of the pending tasks in the dominated set; Determine the habitats to be migrated into and the habitats to be migrated out according to the migration rate and migration rate of each habitat, randomly migrate one or more pending tasks in the dominant set of the habitat to be migrated out into the habitat to be migrated into, and calculate the habitat suitability index of each pending task corresponding to each habitat after the migration operation is performed; Determine the habitat to be mutated according to the mutation rate of each habitat, perform mutation operation on the habitat to be mutated, and calculate the habitat suitability index of each task to be processed corresponding to each habitat after the mutation operation; If the current iteration result does not meet the preset conditions, for each habitat, the tasks to be processed corresponding to the habitat are sorted according to the habitat applicability index, the non-dominated set and the dominated set are updated according to the sorting result, and the step of determining the migration operation for one or more tasks to be processed in the dominated set corresponding to the habitat according to the immigration rate and the migration rate of each habitat is returned until the current iteration result meets the preset conditions, and the corresponding relationship between the current habitats and the tasks to be processed is determined as the scheduling plan for each task to be processed.

4. The cloud-edge collaborative task scheduling method according to claim 3 is characterized in that: Initialize the correspondence between each habitat and the tasks to be processed, including: If the density of the tasks to be processed is greater than a preset value, the habitat to which the tasks to be processed belong corresponds to the cloud center.

5. The cloud-edge collaborative task scheduling method according to claim 3 is characterized in that: Calculating the dynamic selection probability of each habitat according to the emigration rate of each habitat, and determining the habitat to be emigrated based on the dynamic selection probability; The dynamic selection probability is calculated by the following formula: , , in, and Represents habitat and The emigration rate, is the current iteration number, is the number of iteration cutoffs.

6. The cloud-edge collaborative task scheduling method according to claim 3 is characterized in that: The mutation rate of each habitat is calculated by the adaptive Lévy mutation operator: , , in, represents the SIV value of the ith habitat, Used to control the curve shape; is the scale factor; Indicates that each fitness index variable vector generates a random number according to the Lévy distribution; This means that the Gaussian distribution will be distributed around 0.5 with a high probability.

7. A cloud-edge collaborative task scheduling device, applied to a cloud-edge collaborative system, wherein the cloud-edge collaborative system includes a cloud center, at least one edge node, and at least one terminal node, characterized in that: The device comprises: A service priority determination module is used to determine the pending tasks of each terminal node and the service priority of each pending task; A cost calculation module, used to respectively determine a first total computing delay and a first unloading cost of each to-be-processed task being unloaded to each edge node, and a second total computing delay and a second unloading cost of each to-be-processed task being unloaded to a cloud center; An optimization target establishment module is used to establish an optimization target according to the business priority of each task to be processed, the first total calculation delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total calculation delay, and the second unloading cost; An optimization target solving module is used to solve the optimization target and obtain a scheduling plan for each task to be processed; A task scheduling module is used to assign each to-be-processed task to a corresponding edge node or cloud center according to the scheduling scheme; An optimization target is established according to the business priority of each task to be processed, the first total computing delay corresponding to unloading to each edge node, the first unloading cost corresponding to unloading to each edge node, the second total computing delay, and the second unloading cost, including: Establishing a latency optimization sub-goal according to a first total latency corresponding to offloading each to-be-processed task to each edge node and a second total latency corresponding to offloading to the cloud center; Establishing an offloading cost optimization sub-goal according to a first offloading cost corresponding to offloading each to-be-processed task to each edge node and a second offloading cost corresponding to offloading to the cloud center; Determine the delay optimization sub-goal weight according to the service priority of each task to be processed, and comprehensively evaluate the delay optimization sub-goal and the offloading cost optimization sub-goal according to the delay optimization sub-goal weight to obtain the optimization goal; The optimization goal is: , , , They represent the minimum and maximum values ​​of latency and cost when a single task to be executed selects different offloading paths; The constraint means that the tasks to be processed can only be offloaded in the cloud center or edge nodes; and The constraint means that all pending tasks can be offloaded and executed on a unique computing node including the cloud center.

8. A computer device, characterized in that: include: at least one processor; And a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, thereby executing the cloud-edge collaborative task scheduling method as described in any one of claims 1-6.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the cloud-edge collaborative task scheduling method as described in any one of claims 1-6.