Directed acyclic graph task scheduling method, system, medium, device and terminal
By decomposing energy consumption and delay constraints in mobile edge computing, constructing a subtask priority list and scheduling DAG tasks, the problems of not considering energy consumption and high complexity in the existing technology are solved, and task execution in mobile edge computing is realized Maximize reliability and optimize energy consumption.
Patent Information
- Application Number
- CN202011304179.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-11-19
- Publication Date
- 2024-12-17
- Estimated Expiration
- 2040-11-19
AI Technical Summary
The existing DAG task scheduling methods only consider minimizing task execution time, fail to effectively consider other factors such as energy consumption, and the algorithm to maximize task execution reliability under given time delay and energy consumption constraints is relatively complex.
By obtaining task parameters and system parameters in mobile edge computing, decomposing user equipment energy consumption constraints and task execution delay constraints, building a subtask priority list, scheduling each subtask in turn, decomposing the energy consumption and delay constraints to each On subtasks, the processor that meets the constraints and performs the most reliable execution is selected as the processing location of the subtask.
Given the energy consumption of user equipment and task execution delay constraints, maximize task execution reliability, shorten task execution time, reduce user equipment energy consumption, and reduce the complexity of task scheduling scheme.
Smart Images

Figure CN112506627B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of mobile edge computing technology, and in particular relates to a directed acyclic graph task scheduling method, system, medium, device and terminal. Background Art
[0002] At present: With the rapid development of machine learning and artificial intelligence technology, applications such as face recognition, virtual reality, smart home, and Internet of Vehicles have emerged. These computationally intensive and latency-sensitive applications pose great challenges to mobile devices with limited computing power and battery life. Mobile edge computing provides mobile devices with abundant computing resources at the edge of the network. Users can offload part or all of the tasks to edge computing servers for execution, thereby reducing the execution latency of tasks and the energy consumption of user devices. For an actual application, it is usually represented by a directed acyclic graph (DAG). The DAG task model describes the subtasks contained in the application and the dependencies between them.
[0003] Among the existing DAG task scheduling studies, some are studying scheduling methods that aim to minimize task completion time. For example, C. Shu et al. proposed a task offloading strategy based on game theory in a multi-user and multi-server scenario in the document “Multi-User Offloading for Edge Computing Networks: A Dependency-Aware and Latency-Optimal Approach” (IEEE Internet of Things Journal, vol. 7, no. 3, Mar. 2020., pp. 1678-1689). P. Sun et al. proposed a scheduling strategy for a single user to offload tasks to multiple access points based on ultra-dense networking technology in the document “Task Allocation for Multi-APs with Mobile Edge Computing” (2018 IEEE / CIC International Conference on Communications in China (ICCC Workshops), Beijing, China, 2018, pp. 314-318) to minimize task execution time. Y. Liu et al. proposed a scheduling strategy for a single user to offload tasks to multiple access points based on ultra-dense networking technology in the document “Dependency-Aware Task Scheduling in Vehicular Edge Computing” (IEEE Internet of Things Journal, vol. 7, no. 3, Mar. 2020., pp. 1678-1689). Journal, vol.7, no.6, Jun.2020, pp.4961-4971) proposed a scheduling algorithm for multiple DAG tasks in the Internet of Vehicles scenario to minimize the average completion time of multiple tasks. These studies only aim to minimize the task execution time without considering other factors such as energy consumption.
[0004] In addition, the execution reliability of processors has gradually attracted attention. For example, H. Liu et al., in the document “A Fast Algorithm for Energy-Saving Offloading With Reliability and Latency Requirements in Multi-Access Edge Computing” (IEEE Access, vol. 8, Jan. 2020, pp. 151-161), took into account the instantaneous failure rate of the processor and proposed a task scheduling method that minimizes the energy consumption of user devices under given reliability and latency constraints. Z. Quan et al., in the document “Task Scheduling for Energy Consumption Constrained Parallel Applications on Heterogeneous Computing Systems” (IEEE Transactions on Parallel and Distributed Systems, vol. 31, no. 5, May 2020), proposed a task scheduling method in a heterogeneous computing system that uses dynamic voltage and frequency adjustment technology. The goal is to maximize the reliability of task execution under given latency and energy consumption constraints, but the complexity of the proposed algorithm is relatively high.
[0005] Through the above analysis, the problems and defects of the prior art are as follows:
[0006] (1) Existing DAG task scheduling research only takes minimizing task execution time as the goal, without considering other factors such as energy consumption.
[0007] (2) The existing technology uses a task scheduling method in a heterogeneous computing system using dynamic voltage and frequency adjustment technology, with the goal of maximizing task execution reliability under given latency and energy consumption constraints. However, the complexity of the proposed algorithm is relatively high.
[0008] The difficulty of solving the above problems and defects is: the designed heuristic task scheduling algorithm must be effective and of low complexity. Since the application tasks adopted are modeled as directed acyclic graphs, the task execution order obtained by the designed task scheduling algorithm must also satisfy the dependencies between subtasks, and it is necessary to maximize the reliability of task execution under the given user equipment energy consumption constraints and task execution delay constraints.
[0009] The significance of solving the above problems and defects is that there is an instantaneous failure rate during the execution of tasks on computing devices. Although re-execution after a failure is a solution to meet reliability requirements, this method that requires extra time and energy consumption is not advisable in practice for user devices with limited energy. Therefore, the application is divided into multiple subtasks and assigned to different processors for parallel execution, which can reduce the task execution delay, save energy consumption of user devices, and ensure the reliability of task execution. For computationally intensive and delay-sensitive applications, an effective and low-complexity task scheduling algorithm is used to solve when and where subtasks are executed and maximize execution reliability while ensuring delay and energy constraints. This is of great significance in practical application problems. Summary of the invention
[0010] In view of the problems existing in the prior art, the present invention provides a directed acyclic graph task scheduling method, system, medium, device and terminal.
[0011] The present invention is implemented as follows: a scheduling method for directed acyclic graph tasks, which utilizes the sufficient computing resources provided by mobile edge computing for mobile devices at the edge of the network. Under given user device energy consumption constraints and task execution delay constraints, the user device energy consumption constraints and the task execution delay constraints are decomposed to meet the given constraints while maximizing the task execution reliability.
[0012] Furthermore, the directed acyclic graph task scheduling method comprises the following steps:
[0013] (1) Obtaining task parameters, system parameters, and user equipment energy consumption constraints E given and the task execution delay constraint D given ;
[0014] (2) Perform initial processor mapping on all subtasks in the DAG and preliminarily assign each subtask to the processor that maximizes its execution reliability;
[0015] (3) Build a priority list of subtasks. The specific steps include:
[0016] 3a) Calculate the rank value of each subtask;
[0017] 3b) Sort the subtasks in non-increasing order according to the rank value and construct a priority list T p ={t 1' ,t 2' ,...,t N'};
[0018] (4) Schedule each subtask in turn according to the priority list, decompose the energy consumption and delay constraints of the entire task into each subtask, and select the processor that meets the decomposed constraints and has the highest execution reliability as the processing location of the subtask.
[0019] Furthermore, in step (2), each subtask is initially mapped to a processor that maximizes its execution reliability in turn in a breadth-first search order.
[0020] Furthermore, the energy consumption constraint of the entire task described in step (4) is decomposed into each subtask, specifically: for subtask t i' , the energy consumed by the user equipment must meet the constraints:
[0021]
[0022] Where E(t i' ) is to uninstall or execute the current subtask locally i' Energy consumed by the user equipment, E given is a given constraint on the energy consumption of user equipment, E s (t k' ) is for uninstallation or local execution i' High priority, that is, in the priority list T p Ranked in t i' Previous tasks k' The energy consumed by the user equipment, for priority levels lower than t i' Subtask t j' , respectively calculate the energy consumed by the user device when it is executed locally and the results are transmitted and offloaded to each edge server, and pre-allocate it to the processor that minimizes the energy consumption of the user device. The minimum energy consumption is E min (t j' ).
[0023] Furthermore, step (4) of decomposing the delay constraint of the entire task into each subtask specifically includes:
[0024] 4a) For the current subtask t i , calculate it on each processor s m The latest completion time LFT(t i ,s m ) and the modified latest completion time MLFT(t i ,s m ), if t i is an export subtask, then the latest completion time LFT and the modified latest completion time MLFT are both equal to the given delay constraint D given , otherwise t i In processors mThe latest completion time LFT(t i ,s m ) and the modified latest completion time MLFT(t i ,s m ) are:
[0025]
[0026]
[0027] Where LFT(t j ) is t i The successor task t j The latest completion time, MLFT(t j ) is t i The successor task t j The latest corrected completion time, For subtask t j In processors n The execution time on For subtask t i The processing results are transmitted to the execution j Processors n The communication time required;
[0028] 4b) For the current subtask t i , calculate the earliest completion time corresponding to its execution on all processors, and take the minimum value as t i The earliest completion time EFT(t i );
[0029] 4c) Compare LFT(t i ,s m )、MLFT(t i ,s m ) and EFT(t i ) size, if EFT(t i ) is less than MLFT(t i ,s m ), then subtask t i In processors m The final latest completion time FLFT(t i ,s m ) is equal to MLFT(t i ,s m ), if EFT(t i ) is greater than MLFT(t i ,s m ) and is less than LFT(t i ,s m ), then FLFT(t i,s m ) is equal to EFT(t i ), if neither of the above two conditions is satisfied, the last scheduled task is reallocated and the suboptimal processor is selected as the execution location;
[0030] 4d) Through subtask t i The earliest completion time EFT(t i ), in processor s m The final latest completion time FLFT(t i ,s m ) and execution time Get the decomposed delay constraint:
[0031]
[0032] Another object of the present invention is to provide a mobile device, which includes a memory and a processor, wherein the memory stores application tasks, and the processor is responsible for executing subtasks in the application that need to be executed locally, transmitting execution results, and transmitting subtasks that need to be executed at the edge to an edge computing server.
[0033] Another object of the present invention is to provide a heterogeneous edge computing server cluster, in which servers have different computing processing capabilities and are responsible for receiving and executing subtasks in applications transmitted by mobile devices and transmitting execution results.
[0034] Another object of the present invention is to provide a centralized controller, which performs the following steps: collecting task information, mobile device information, edge computing server information and network status information in the mobile edge computing network, and under given user device energy consumption constraints and task execution delay constraints, by decomposing the user device energy consumption constraints and the task execution delay constraints, providing a task scheduling strategy that maximizes the task execution reliability while satisfying the given constraints.
[0035] Another object of the present invention is to provide a vehicle networking information data processing terminal, which is used to implement the scheduling method of the directed acyclic graph task.
[0036] Another object of the present invention is to provide a directed acyclic graph task scheduling system for implementing the directed acyclic graph task scheduling method, the directed acyclic graph task scheduling system comprising:
[0037] A parameter acquisition module is used to obtain task parameters and system parameters as well as user equipment energy consumption constraints and task execution delay constraints;
[0038] The initial task allocation module is used to make initial processor mapping for all subtasks in the DAG;
[0039] List building module, used to build a priority list of subtasks;
[0040] The constraint decomposition module is used to schedule each subtask in turn according to the priority list, decompose the energy consumption and delay constraints of the entire task into each subtask, and select the processor that meets the decomposed constraints and has the highest execution reliability as the processing location of the subtask.
[0041] In combination with all the above technical solutions, the advantages and positive effects of the present invention are as follows: when the energy consumption constraint is fixed, the delay constraint is changed, and the delay constraint is fixed and the energy consumption constraint is changed, compared with other task scheduling methods, the task scheduling method proposed by the present invention can achieve higher task execution reliability while satisfying the given constraints. The present invention aims to maximize the reliability of task execution, and under the given user equipment energy consumption constraint and task execution delay constraint, proposes a scheduling method for directed acyclic graph (DAG) tasks in mobile edge computing. In order to achieve the task scheduling goal, the present invention decomposes the energy consumption and delay constraints of the entire task into each subtask of the DAG, and dynamically adjusts the delay constraint of each subtask to maximize the reliability of task execution.
[0042] The present invention makes full use of the rich computing resources provided by mobile edge computing at the edge of the network, schedules computationally intensive and delay-sensitive tasks on user devices, and selects the execution location of each subtask according to given energy consumption and delay constraints, which can shorten the execution time of the entire task and reduce the energy consumption of the user device. The present invention decomposes the given energy consumption and delay constraints during the task scheduling process, and the designed scheduling strategy can reduce the complexity of solving the task scheduling solution and maximize the reliability of task execution under the condition of meeting the energy consumption and delay constraints. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments of the present application. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0044] Figure 1 It is a flow chart of a method for scheduling directed acyclic graph tasks provided by an embodiment of the present invention.
[0045] Figure 2 It is a structural schematic diagram of a directed acyclic graph task scheduling system provided by an embodiment of the present invention;
[0046] Figure 2 In: 1. Parameter acquisition module; 2. Initial task assignment module; 3. List construction module; 4. Constraint decomposition module.
[0047] Figure 3 It is a flow chart of an implementation of a method for scheduling directed acyclic graph tasks provided by an embodiment of the present invention.
[0048] Figure 4 It is a directed acyclic graph (DAG) task model diagram provided by an embodiment of the present invention.
[0049] Figure 5 It is a system model diagram provided by an embodiment of the present invention.
[0050] Figure 6 It is a schematic diagram of the execution reliability of the scheduling method provided by an embodiment of the present invention under different energy consumption and delay constraints.
[0051] Figure 7 It is a simulation result diagram of execution reliability under different delay constraints provided by an embodiment of the present invention.
[0052] Figure 8 It is a simulation result diagram of execution reliability under different energy consumption constraints provided by an embodiment of the present invention.
[0053] Fig. 9 It is a schematic diagram of the influence of the number of edge servers on execution reliability provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0054] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0055] In view of the problems existing in the prior art, the present invention provides a directed acyclic graph task scheduling method, system, medium, device and terminal. The present invention is described in detail below with reference to the accompanying drawings.
[0056] like Figure 1 As shown, the directed acyclic graph task scheduling method provided by the present invention comprises the following steps:
[0057] S101: Acquire task parameters and system parameters as well as user equipment energy consumption constraints and task execution delay constraints;
[0058] S102: Initially map all subtasks in the DAG to processors;
[0059] S103: Construct a subtask priority list;
[0060] S104: Schedule each subtask in turn according to the priority list, decompose the energy consumption and delay constraints of the entire task into each subtask, and select a processor that meets the decomposed constraints and has the highest execution reliability as the processing position of the subtask.
[0061] The directed acyclic graph task scheduling method provided by the present invention can also be implemented by other steps by ordinary technicians in the industry. Figure 1 The directed acyclic graph task scheduling method provided by the present invention is only a specific embodiment.
[0062] like Figure 2 As shown, the directed acyclic graph task scheduling system provided by the present invention includes:
[0063] Parameter acquisition module 1, used to acquire task parameters and system parameters as well as user equipment energy consumption constraints and task execution delay constraints;
[0064] Initial task allocation module 2, used to make initial processor mapping for all subtasks in DAG;
[0065] List building module 3, used to build a priority list of subtasks;
[0066] The constraint decomposition module 4 is used to schedule each subtask in turn according to the priority list, decompose the energy consumption and delay constraints of the entire task into each subtask, and select the processor that meets the decomposed constraints and has the highest execution reliability as the processing position of the subtask.
[0067] The technical solution of the present invention is further described below in conjunction with the accompanying drawings.
[0068] Example 1
[0069] The present invention is a scheduling method for directed acyclic graph (DAG) tasks in mobile edge computing, and the DAG task model used is as follows: Figure 4 As shown, use G t =(V,E) represents DAG tasks, where V = {t 1 ,t 2 ,...,t N} represents a task set consisting of N subtasks in DAG, where subtask t i The predecessor task set and the successor task set are respectively represented by pred(t i )、succ(t i ) means that if This subtask is called the entry subtask t entry ,if This subtask is called the export subtask exit . E={e i,j |t i ,tj ∈V} describes the dependency relationship between subtasks, e i,j Indicates t i To t j The size of the calculation result data transmitted, if the subtask t i and t j If there is no dependency between them, then e i,j is 0.
[0070] The system model of the DAG task scheduling scenario provided by the present invention is as follows: Figure 5 As shown, the system includes a user equipment UE and M edge servers, and all processors are S = {s 0 ,s 1 ,s 2 ,...,s M} means, where s 0 is the user equipment UE, S e ={s 1 ,s 2 ,...,s M The present invention assumes that the edge server has sufficient computing resources and energy, and therefore only considers the energy consumption of UE unloading or local execution of subtasks during the execution of DAG tasks.
[0071] The present invention provides a method for scheduling directed acyclic graph (DAG) tasks in mobile edge computing, referring to Figure 3 The specific implementation steps of the present invention include:
[0072] (1) Obtaining task parameters, system parameters, and user equipment energy consumption constraints E given and task execution delay constraint D given .
[0073] (2) For all subtasks in the DAG, each subtask is initially mapped to the processor that maximizes its execution reliability in the order of breadth-first search, where subtask t i In processors m The execution reliability on is calculated by the following formula:
[0074] R im =exp(-ρ m c i / f m );
[0075] where ρ m For processors m Instantaneous failure rate per unit time, c i Indicates execution of t i The number of CPU cycles required, f m Indicates processors mThe number of CPU cycles per second.
[0076] (3) Build a priority list of subtasks. The specific steps include:
[0077] 3a) For each subtask t i , calculate its rank value:
[0078]
[0079] in For subtask t i The average execution time on all processors is calculated as follows:
[0080]
[0081] In the formula For subtask t i In processors m The execution time on is:
[0082]
[0083] is the subtask t obtained according to the initial mapping result i The execution result is transmitted to its successor subtask t j The communication time is calculated by the following formula:
[0084]
[0085] Where r m,n For processors m to n The transmission rate, f(t i )=s m Represents subtask t i Assigned to processors m In addition, if t i and its successor task t j If they are assigned to the same processor for execution, the communication time between them is ignored;
[0086] 3b) Sort the subtasks in non-increasing order according to the rank value and construct a priority list T p ={t 1' ,t 2' ,...,t N'}, where subtask t 1' has the highest priority;
[0087] (4) According to the priority list T pSchedule each subtask in turn. First, decompose the energy consumption constraint of the entire task into each subtask. i When traversing all processors, calculate t i Assigned to the current processor m If the energy consumed by the UE meets the decomposed energy consumption constraint, the subtask t is further calculated. i In processors m The final latest completion time FLFT on the decomposed delay constraint is determined, and t i Assign to s m The processor that satisfies the decomposed delay constraint and has the highest execution reliability is selected as the processing position of the subtask. After all subtasks are scheduled, the execution reliability of the entire task is the product of the execution reliabilities of all subtasks.
[0088] Example 2
[0089] The scheduling method of directed acyclic graph (DAG) tasks in mobile edge computing of the present invention is the same as that in Example 1. In step (4), the energy consumption constraint of the entire task is decomposed into each subtask, specifically: i' , the energy consumed by the user equipment must meet the constraints:
[0090]
[0091] Where E(t i' ) is to uninstall or execute the current subtask locally i' Energy consumed by the user equipment, E s (t k' ) is used by the UE to offload or execute i' High priority, that is, in the priority list T p Ranked in t i' Previous tasks k' The energy consumption is calculated by the following formula:
[0092]
[0093] If t k' Executed on the UE, that is, f(t k' )=s 0 , then the energy consumption of UE is t k' Execution energy consumption With transmission k' The energy consumption of the execution result The sum of the execution energy consumption for:
[0094]
[0095] Where δ 0 is the energy consumption of UE per CPU cycle, if t k' On edge servers m Execute on, that is, f(t k' )=s m , then for subtask t k' , the energy consumption of UE is only the unloading energy consumption
[0096]
[0097] Where P 0 is the transmit power of UE, For UE, the subtask t k' Offload to edge servers m The time is:
[0098]
[0099] Where m k' Represents subtask t k' The size of r 0,m For UE and processors m For the transmission rate between the priority and the i' Subtask t j' , calculate the sum of its energy consumption executed locally on the UE and the energy consumption of the transmission result, as well as the energy consumption corresponding to offloading to each edge server, and convert t j' Pre-allocated to the processor that minimizes the UE's energy consumption, the minimum energy consumption is recorded as E min (t j' ).
[0100] Example 3
[0101] The scheduling method of directed acyclic graph (DAG) tasks in mobile edge computing of the present invention is the same as that of Embodiment 1-Embodiment 2. In step (4), the final latest completion time FLFT of the subtask on each processor is calculated and the decomposed delay constraint is determined. The specific steps include:
[0102] 4a) For subtask t i , calculate it on each processor s m The latest completion time LFT(t i ,s m ) and the modified latest completion time MLFT(t i ,s m ), if t i is an exit subtask, then its latest completion time LFT and modified latest completion time MLFT executed on all processors are equal to the given delay constraint D given , otherwise it is in the processor sm The latest completion time LFT(t i ,s m ) and the modified latest completion time MLFT(t i ,s m ) are:
[0103]
[0104]
[0105] Where LFT(t j ) is t i The successor task t j The latest completion time is t j The minimum value of the latest completion time corresponding to execution on all processors, that is:
[0106]
[0107] Where MLFT(t j ) is t i The successor task t j The latest corrected completion time, For subtask t j In processors n The execution time on For subtask t i The processing result is from processor s m Transfer to execution j Processors n The communication time required;
[0108] 4b) For the current subtask t i , traverse all processors and calculate on each processor s m The earliest completion time EFT(t i ,s m ):
[0109]
[0110] Among them, EST(t i ,s m ) is t i In processors m The earliest start time for the execution, t i In processors m The execution time on EST(t i ,s m ) is calculated as follows:
[0111]
[0112] Among them, avail(s m ) is the processor s m The earliest idle time, AFU(i,m) is t i Arrival Processors m time, FT(t j ,s n ) is t i The predecessor task t j The time when the execution is completed, when it is determined that t j Dispatching to processors n When t j In s n The earliest completion time of the execution is equal to the completion time FT. The specific expression of AFU(i,m) is:
[0113]
[0114] The first summation term is the sum of all priorities higher than t by UE. i And the subtask t assigned to the edge server j Offload to edge servers n The second summation term is the time for the UE to execute all the tasks with a priority higher than t locally. i And the subtask t assigned to the UE j The time required, For subtask t i Arrival Processors m time, if the currently traversed processor s m If it is UE, then AFU(i,m) is 0. After the traversal is completed, t i The minimum value of the earliest completion time on all processors is recorded as EFT(t i );
[0115] 4c) Compare LFT(t i ,s m )、MLFT(t i ,s m ) and EFT(t i ) size, if EFT(t i ) is less than MLFT(t i ,s m ), then subtask t i In processors m The final latest completion time FLFT(t i ,s m ) is equal to MLFT(t i ,s m ), if EFT(t i) is greater than MLFT(t i ,s m ) and is less than LFT(t i ,s m ), then FLFT(t i ,s m ) is equal to EFT(t i ), if neither of the above two conditions is satisfied, the last scheduled task is reallocated and the suboptimal processor is selected as the execution location;
[0116] 4d) Through subtask t i The earliest completion time EFT(t i ), in processor s m The final latest completion time FLFT(t i ,s m ) and execution time Get the decomposed delay constraint:
[0117]
[0118] The technical effects of the present invention are described in detail below in conjunction with simulation.
[0119] The scheduling method of directed acyclic graph (DAG) tasks in mobile edge computing of the present invention is the same as that of Examples 1 to 3. By simulating the present invention, the implementation effect of the method of the present invention is further illustrated.
[0120] 1. Simulation conditions
[0121] In the simulation of the present invention, the DAG task parameters and user equipment and edge server parameters in the task scheduling scenario must first be set. The specific parameter selection is shown in Table 1:
[0122] Table 1
[0123]
[0124] 2. Simulation content
[0125] The simulation uses the random algorithm, the earliest completion time (HEFT) algorithm in a heterogeneous computing environment, and the local execution strategy as the comparison algorithms of the present invention. The random algorithm randomly selects a processor as the execution location for each subtask. After all selections are completed, it determines whether the given energy consumption and delay constraints are met. If not, the above steps are repeated until all constraints are met. In order to eliminate the impact of the randomness of the random algorithm on the performance of the algorithm, the average of the results of running the random algorithm 50 times is taken as the final result. The HEFT algorithm aims to minimize the execution time of the task. First, a priority list of DAG is constructed, and then each subtask is scheduled in order of priority. Based on the interval insertion technology, each subtask is assigned to the processor with the smallest earliest completion time. The algorithm does not consider the energy consumption of the user device and the execution reliability of the processor during the entire task execution process. Local execution executes all subtasks in DAG sequentially according to the priority list constructed by the HEFT algorithm.
[0126] The specific simulation content includes:
[0127] (1) Impact of changes in delay constraints and energy consumption constraints on the task execution reliability of the algorithm proposed in the present invention. It is assumed that the DAG task consists of 12 subtasks. There is one user equipment UE and four edge computing servers in the system. The given energy consumption constraint on the UE varies in the range of 4 to 10 mJ, and the delay constraint of task execution varies in the range of 0.13 to 0.17 s.
[0128] (2) The impact of delay constraints on task execution reliability
[0129] It is assumed that the DAG task consists of 12 subtasks, there is 1 user equipment UE and 4 edge computing servers in the system, and the energy consumption constraint on the UE is fixed to 20mJ. The task execution reliability obtained by the four algorithms and the impact of the delay constraint change on the task execution reliability are compared.
[0130] (3) Impact of energy consumption constraints on task execution reliability
[0131] It is assumed that the DAG task consists of 12 subtasks, there is 1 user equipment UE and 4 edge computing servers in the system, and the delay constraint of task execution is fixed to 0.2s. The task execution reliability obtained by the four algorithms and the impact of energy consumption constraint changes on task execution reliability are compared.
[0132] (4) Impact of the number of edge servers on task execution reliability
[0133] The DAG task is set to consist of 12 subtasks, the delay constraint of fixed task execution is 0.3s, and the energy consumption constraint of UE is 30mJ. The task execution reliability obtained by the four algorithms and the impact of the number of edge servers on the task execution reliability are compared.
[0134] 3. Simulation results
[0135] Figure 6 The impact of changes in user device energy consumption constraints and task execution delay constraints on task execution reliability in the algorithm proposed by the present invention is demonstrated. As energy consumption constraints and delay constraints are gradually relaxed, subtasks in the DAG are more likely to be assigned to processors with higher execution reliability and strong computing power but distributed far away from the user device, thereby improving the execution reliability of the entire DAG task.
[0136] Figure 7 The influence of delay constraints on task execution reliability is demonstrated. Compared with random algorithms, HEFT algorithms, and local execution strategies, the algorithm proposed in the present invention can achieve higher task execution reliability under given energy consumption and delay constraints. As the constraints of the given task execution delay are gradually relaxed, more sufficient execution time is provided for the algorithm proposed in the present invention, and more subtasks will be scheduled to processors with higher execution reliability, thereby improving the overall execution reliability of the task. Since the random algorithm ends immediately after finding a scheduling scheme that satisfies the constraints, the resulting scheduling scheme is not necessarily optimal, so the overall execution reliability of the task is lower than that of the algorithm proposed in the present invention. Since the goal of the HEFT algorithm is to minimize the scheduling time of the task, the change in the delay constraint has no effect on the execution reliability of the task. When the HEFT algorithm schedules subtasks with higher priority, since it selects a processor that can minimize the earliest completion time of the subtask, it may choose to assign the subtask to an edge server that is closer to the user device but has slightly weaker computing power for execution, so that when scheduling subtasks with lower priority, the earliest completion time of local execution is the smallest, which in turn leads to an extension of the task completion time. In addition, since the task completion times obtained by the HEFT algorithm and the local execution strategy are 0.16s and 0.17s respectively, when the given delay constraint is tight, both scheduling methods cannot meet the delay constraint.
[0137] Figure 8 The influence of energy consumption constraint on task execution reliability is demonstrated. Compared with random algorithm, HEFT algorithm and local execution strategy, the algorithm proposed in this invention can achieve higher task execution reliability under given energy consumption and delay constraints. As the energy consumption constraint on UE is gradually relaxed, the available energy increases, more subtasks have the opportunity to be scheduled to processors with higher execution reliability, and when the available energy is large enough, the execution reliability will no longer increase. The instability of random algorithm is Figure 7 and Figure 8This is reflected in the performance of the algorithm. When the constraints change, the algorithm performance fluctuates within a certain range. Although the HEFT algorithm and the local execution strategy can meet the energy consumption constraints, they will select processors with weak computing power for execution, which will affect the overall reliability of the DAG task. In addition, since energy consumption is not considered in the scheduling process, the execution reliability of these two scheduling methods remains unchanged when the energy consumption constraints change.
[0138] Fig. 9 The effect of the number of edge servers on the reliability of task execution is demonstrated. Compared with the random algorithm, HEFT algorithm, and local execution strategy, the algorithm proposed in the present invention can achieve higher task execution reliability under given energy consumption and delay constraints. When the number of edge servers is 0, that is, only user devices in the system execute all subtasks in the DAG, the execution time is the longest and the task execution reliability is the lowest. As the number of edge servers in the system increases, the task execution reliability obtained by the random algorithm gradually increases, and the task execution reliability obtained by the HEFT algorithm also increases when the number of edge servers begins to increase. Since the executed DAG tasks have an average of three or four parallel subtasks, when the number of edge servers increases to 3, the execution reliability obtained by the algorithm proposed in the present invention no longer increases.
[0139] It should be noted that the embodiments of the present invention can be implemented by hardware, software, or a combination of software and hardware. The hardware part can be implemented using dedicated logic; the software part can be stored in a memory and executed by an appropriate instruction execution system, such as a microprocessor or dedicated design hardware. It can be understood by a person of ordinary skill in the art that the above-mentioned devices and methods can be implemented using computer executable instructions and / or contained in a processor control code, such as a carrier medium such as a disk, CD or DVD-ROM, a programmable memory such as a read-only memory (firmware), or a data carrier such as an optical or electronic signal carrier. Such code is provided on the carrier medium. The device and its modules of the present invention can be implemented by hardware circuits such as very large-scale integrated circuits or gate arrays, semiconductors such as logic chips, transistors, etc., or programmable hardware devices such as field programmable gate arrays, programmable logic devices, etc., can also be implemented by software executed by various types of processors, and can also be implemented by a combination of the above-mentioned hardware circuits and software, such as firmware.
[0140] The above description is only a specific implementation mode of the present invention, but the protection scope of the present invention is not limited thereto. Any modifications, equivalent substitutions and improvements made by any technician familiar with the technical field within the technical scope disclosed by the present invention and within the spirit and principle of the present invention should be covered by the protection scope of the present invention.
Claims
1. A directed acyclic graph task scheduling method, It is characterized in that The directed acyclic graph task scheduling method utilizes the sufficient computing resources provided by mobile edge computing for mobile devices at the edge of the network, and under given user device energy consumption constraints and task execution delay constraints, by decomposing the user device energy consumption constraints and the task execution delay constraints, the given constraints are met while maximizing the reliability of task execution; The directed acyclic graph task scheduling method comprises the following steps: (1) Obtaining task parameters and system parameters as well as user equipment energy consumption constraint Egiven and task execution delay constraint Dgiven; (2) Perform initial processor mapping on all subtasks in the directed acyclic graph (DAG), and preliminarily assign each subtask to the processor that maximizes its execution reliability; (3) Build a priority list of subtasks. The specific steps include: 3a) Calculate the rank value of each subtask; 3b) Sort the subtasks in non-increasing order according to the rank value and construct a priority list T p ={t 1 ',t 2 ',...,t N '}; (4) Schedule each subtask in turn according to the priority list, decompose the energy consumption and delay constraints of the entire task into each subtask, and select the processor that meets the decomposed constraints and has the highest execution reliability as the processing location of the subtask; For all subtasks in the DAG, each subtask is initially mapped to the processor that maximizes its execution reliability in the order of breadth-first search. i In processors m The execution reliability on is calculated by the following formula: R im =exp(-ρ m c i / f m ); where ρ m For processors m Instantaneous failure rate per unit time, c i Indicates execution of t i The number of CPU cycles required, f m Indicates processors m The number of CPU cycles per second.
2. The method for scheduling directed acyclic graph tasks as claimed in claim 1, It is characterized in that The energy consumption constraint of the entire task described in step (4) is decomposed into each subtask, specifically: i ', the energy consumed by the user equipment must meet the constraints: Where E(t i' ) is to uninstall or execute the current subtask locally i 'Energy consumed by the user device, E given is a given constraint on the energy consumption of user equipment, E s (t k ') for uninstallation or local execution i 'High priority, that is, in the priority list T p Ranked in t i 'Previous task t k 'The energy consumed by the user equipment, for priority lower than t i 'Subtask t j ', calculate the energy consumed by the user device when it is executed locally and the results are transmitted and unloaded to each edge server, and pre-allocate it to the processor that minimizes the energy consumption of the user device. The minimum energy consumption is E min (t j ').
3. The method for scheduling directed acyclic graph tasks as claimed in claim 1, It is characterized in that Step (4) of decomposing the delay constraint of the entire task into each subtask specifically includes: 4a) For the current subtask t i , calculate it on each processor s m The latest completion time LFT(t i ,s m ) and the modified latest completion time MLFT(t i ,s m ), if t i is an export subtask, then the latest completion time LFT and the modified latest completion time MLFT are both equal to the given delay constraint Dgiven, otherwise t i The latest completion time LFT(t i ,s m ) and the modified latest completion time MLFT(t i ,s m ) are: Where LFT(t j ) is t i The successor task t j The latest completion time, MLFT(t j ) is t i The successor task t j The latest corrected completion time of subtask t j The execution time on processor sn is the execution time of subtask t i The processing results are transmitted to the execution j The communication time required by processor sn; 4b) For the current subtask t i , calculate the earliest completion time corresponding to its execution on all processors, and take the minimum value as t i The earliest completion time EFT(t i ); 4c) Compare LFT(t i ,s m )、MLFT(t i ,s m ) and EFT(t i ) size, if EFT(t i ) is less than MLFT(t i ,s m ), then subtask t i The final latest completion time FLFT(t i ,s m ) is equal to MLFT(t i ,s m ), if EFT(t i ) is greater than MLFT(t i ,s m ) and is less than LFT(t i ,s m ), then FLFT(t i ,s m ) is equal to EFT(t i ), if neither of the above two conditions is satisfied, the last scheduled task is reallocated and the suboptimal processor is selected as the execution location; 4d) Through subtask t i The earliest completion time EFT(t i ), the final latest completion time FLFT (t i ,s m ) and the latency constraints whose execution time is decomposed.
4. A centralized controller, It is characterized in that The controller executes the scheduling method of the directed acyclic graph task described in any one of claims 1 to 3, comprising the following steps: collecting task information, mobile device information, edge computing server information and network status information in the mobile edge computing network, and under given user device energy consumption constraints and task execution delay constraints, by decomposing the user device energy consumption constraints and the task execution delay constraints, providing a task scheduling strategy that maximizes the task execution reliability while satisfying the given constraints.
5. A vehicle networking information data processing terminal, It is characterized in that The Internet of Vehicles information data processing terminal is used to implement the directed acyclic graph task scheduling method described in any one of claims 1 to 3.
6. A directed acyclic graph task scheduling system implementing the directed acyclic graph task scheduling method according to any one of claims 1 to 3, It is characterized in that The directed acyclic graph task scheduling system includes: A parameter acquisition module is used to obtain task parameters and system parameters as well as user equipment energy consumption constraints and task execution delay constraints; The initial task allocation module is used to make initial processor mapping for all subtasks in the DAG; List building module, used to build a priority list of subtasks; The constraint decomposition module is used to schedule each subtask in turn according to the priority list, decompose the energy consumption and delay constraints of the entire task into each subtask, and select the processor that meets the decomposed constraints and has the highest execution reliability as the processing location of the subtask.
