Task unloading method, system and equipment for edge computing and program product
By introducing a task queue information awareness mechanism and GPU speedup evaluation in the edge computing environment, and dynamically optimizing task offloading decisions, the problem of unbalanced task-resource matching in heterogeneous edge computing environments is solved, thereby improving task completion rate and resource utilization.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-01
- Publication Date
- 2026-03-24
AI Technical Summary
In heterogeneous edge computing environments, the imbalance between task and resource matching leads to increased task completion delays and low resource utilization. Existing methods cannot effectively cope with the overload of edge computing nodes with limited computing resources and dynamic changes in task load.
By introducing a task queue information awareness mechanism based on rejection feedback, the cost value is dynamically recalculated and the node preference list is iteratively updated to optimize task offloading decisions to adapt to changes in the load status of edge computing nodes. The GPU acceleration ratio is used to evaluate the processing capabilities of heterogeneous nodes, thereby achieving Pareto optimal matching of tasks and resources.
It significantly improves the adaptability of task offloading and system performance, reduces latency and energy consumption under high load, increases task completion rate and resource utilization, and achieves synergistic optimization of latency and energy efficiency.
Smart Images

Figure CN121722501A_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of edge computing, specifically to a task offloading method, device, and program product for edge computing. Background Technology
[0002] With the rapid development of digitalization, various innovative applications are constantly emerging. New workloads such as artificial intelligence inference and autonomous driving place stringent demands on ultra-low latency, while the terminal side also faces the dual challenges of resource constraints and energy consumption limitations. Although traditional cloud computing has driven digital transformation, its centralized processing model has increasingly shown limitations in terms of real-time performance, bandwidth consumption, privacy, and security. As an important extension technology of cloud computing, edge computing, with its distributed architecture, deploys edge computing nodes close to the network edge of terminal devices, allowing terminal devices to offload computing tasks to nearby edge computing nodes instead of remote cloud servers. This solution not only significantly reduces data transmission latency but also effectively alleviates the computing pressure on cloud servers.
[0003] However, the heterogeneity of computing resources and tasks makes task-resource matching a major challenge. On the one hand, different types of processors (such as CPUs and GPUs) differ significantly in performance and functionality, and the tasks generated by different terminal devices also vary in type, scale, and computing requirements. On the other hand, as system workload increases, the workload of edge devices changes dynamically. Some edge computing nodes may become overloaded due to limited computing resources. This imbalance not only increases task completion latency but also reduces overall resource utilization. Therefore, a precise task-resource matching mechanism is urgently needed to ensure task execution efficiency and resource utilization. Summary of the Invention
[0004] This disclosure provides a task offloading method, device, and program product for edge computing.
[0005] According to one aspect of this disclosure, a task offloading method for edge computing is provided, comprising: receiving a task to be offloaded to an edge computing node; calculating the cost value of executing the task on each edge node; arranging the cost values in ascending order to obtain an edge computing node preference list for the task; sending an offloading request for the task to the edge computing node at the top of the edge computing node preference list; in response to receiving a rejection message corresponding to the offloading request, parsing the rejection message to obtain task queue information, the task queue information including the number of tasks in the task queue corresponding to the edge computing node and the computational workload of each task in the task queue; recalculating the cost value of executing the task on each edge node according to the task queue information; updating the edge computing node preference list in response to recalculating the cost value; and sending the offloading request for the task to the edge computing node at the top of the updated edge computing node preference list in response to the update of the edge computing node preference list.
[0006] According to one technical solution, by introducing a task queue information awareness mechanism based on rejection feedback during the task unloading process, and dynamically recalculating cost values and iteratively updating the node preference list accordingly, the task unloading decision can adapt to changes in the load status of edge computing nodes in real time. This can avoid high latency or task droppage caused by continuously sending requests to overloaded edge computing nodes.
[0007] According to at least one embodiment of this disclosure, the cost value is a weighted sum of the total latency and total energy consumption of the task performed on the edge computing node.
[0008] According to the technical solution of this embodiment, energy efficiency can be taken into account while ensuring the timeliness of the task, and the unloading decision can be adapted to different load scenarios.
[0009] According to at least one embodiment of this disclosure, the total latency is the sum of transmission latency, waiting latency, and computation latency. The transmission latency is the ratio of the amount of data of the task generated by the terminal device to the transmission rate of the uplink channel between the terminal device and the edge computing node. The computation latency is the ratio of the computational workload required for the task to be executed on the edge computing node to the effective processor frequency of the edge computing node. The waiting latency is the sum of the computational latencies of each task in the task queue corresponding to the edge computing node that precedes the task being executed on the edge computing node.
[0010] According to the technical solution of this embodiment, the dynamic load status of heterogeneous edge nodes can be accurately reflected, making cost assessment and offloading decisions more in line with the actual execution sequence, thereby significantly improving the predictability and stability of task scheduling and achieving synergistic optimization of latency and energy efficiency (avoiding deadline violations caused by underestimating queuing time under high load, and guiding tasks to select low-power paths under low load).
[0011] According to at least one embodiment of this disclosure, when the edge computing node is equipped with a GPU processor, the computational workload required for the task to be executed on the edge computing node is the ratio of the computational workload required for the task to be executed on an edge computing node equipped with only a CPU processor to the speedup ratio, wherein the speedup ratio is the multiple by which the computational speedup obtained when the task is executed on an edge computing node equipped with a GPU processor is compared to when it is executed on an edge computing node equipped with only a CPU processor.
[0012] According to the technical solution of this embodiment, by introducing a GPU acceleration ratio to dynamically calculate the computational workload, the actual processing power of heterogeneous edge nodes (CPU or GPU) can be more accurately evaluated. This ensures that task offloading decisions truly reflect the hardware acceleration benefits, thereby guiding computationally intensive tasks to be efficiently offloaded to GPU nodes. This can significantly improve system throughput and resource utilization while maintaining low latency.
[0013] According to at least one embodiment of this disclosure, the total energy consumption includes transmission energy consumption and computing energy consumption, wherein the transmission energy consumption is the product of transmission delay and transmit power of terminal device, and the computing energy consumption is the product of computing delay and power of edge computing node.
[0014] According to the technical solution of this embodiment, fine-grained modeling and optimization of end-to-edge collaborative energy efficiency can be achieved, making task offloading decisions physically interpretable and operable when dynamically balancing latency and energy consumption.
[0015] According to at least one embodiment of this disclosure, the power of the edge computing node is the product of the effective switched capacitor of the edge computing node and the cube of the effective processor frequency of the edge computing node.
[0016] According to the technical solution of this embodiment, the nonlinear energy consumption characteristics of the processor can be accurately reflected, making the computing energy consumption assessment highly consistent with the physical behavior of the hardware. This allows for a precise balance between the advantages and disadvantages of "speeding up and reducing latency" and "reducing frequency and saving energy" in cost calculations, guiding tasks to rationally select high-frequency, high-computing-power nodes to ensure deadlines under high loads, and favoring low-frequency, low-power nodes to achieve energy savings under low loads.
[0017] According to another aspect of this disclosure, an electronic device is provided, comprising: a memory storing execution instructions; and a processor executing the execution instructions stored in the memory, such that the processor performs a task offloading method for edge computing according to any embodiment of this disclosure.
[0018] According to another aspect of this disclosure, a readable storage medium is provided, wherein executable instructions are stored therein, which, when executed by a processor, are used to implement the task offloading method for edge computing according to any embodiment of this disclosure.
[0019] According to another aspect of this disclosure, a computer program product is provided, including a computer program that, when executed by a processor, implements a task offloading method for edge computing according to any embodiment of this disclosure.
[0020] According to another aspect of this disclosure, a task offloading system is provided, including: an electronic device and an edge computing node as described in the embodiments of this disclosure.
[0021] According to one technical solution, a Pareto-optimal allocation of tasks and resources can be achieved in a heterogeneous edge environment based on a multi-stage stable matching mechanism with dynamic feedback.
[0022] According to at least one embodiment of this disclosure, the method performed by the edge computing node includes: receiving at least one offload request and calculating the relaxation time of the task corresponding to each offload request; executing the task corresponding to the minimum relaxation time; refusing to execute all tasks other than the task corresponding to the minimum relaxation time and generating corresponding rejection information, the rejection information including task queue information corresponding to the task queue; and sending the rejection information to the electronic device.
[0023] According to the technical solution of this embodiment, a dynamic task acceptance and rejection mechanism prioritizing the least-relaxation-time approach is adopted on the edge computing node side, and rejection information including task queue information is fed back. This ensures that tasks with the highest latency urgency are executed first, reducing the deadline violation rate. Simultaneously, it provides real-time load awareness data for electronic devices to drive the updating of the edge computing node preference list and re-unloading decisions. This collaboratively improves the task completion rate under high load and maintains matching stability.
[0024] According to at least one embodiment of this disclosure, the relaxation time is the difference between the maximum tolerable latency of the task and the total latency of the task being executed on the edge computing node.
[0025] According to the technical solution of this embodiment, the urgency margin of tasks can be accurately quantified, providing dynamic and comparable priority criteria for edge computing nodes. This ensures that high-urgency tasks (such as tasks with low relaxation time) are completed on time during queuing and scheduling, thereby improving the deadline fulfillment rate of latency-sensitive tasks.
[0026] According to at least one embodiment of this disclosure, executing the task corresponding to the minimum relaxation time includes: adding the task corresponding to the minimum relaxation time to the tail of the task queue; and executing the task at the head of the task queue.
[0027] According to the technical solution of this embodiment, a dynamic scheduling strategy prioritizing minimum relaxation time can be implemented. This ensures that the most urgent tasks are executed first, while maintaining the orderly execution of the task queue. Attached Figure Description
[0028] The accompanying drawings illustrate exemplary embodiments of the present disclosure and, together with the description thereof, serve to explain the principles of the present disclosure. These drawings are included to provide a further understanding of the present disclosure and are incorporated in and constitute a part of this specification.
[0029] Figure 1 This is a schematic diagram of the structure of a task unloading system according to one embodiment of the present disclosure.
[0030] Figure 2 This is a flowchart illustrating a task offloading method for edge computing according to one embodiment of the present disclosure.
[0031] Figure 3 This is a schematic block diagram of the structure of a task unloading device according to one embodiment of the present disclosure.
[0032] Figure 4 This is a schematic structural block diagram of an electronic device employing a processor-based hardware implementation according to one embodiment of the present disclosure.
[0033] Figure 5 This is a flowchart illustrating a task execution method according to one embodiment of the present disclosure. Detailed Implementation
[0034] The present disclosure will now be described in further detail with reference to the accompanying drawings and examples. It should be understood that the specific examples described herein are for illustrative purposes only and are not intended to limit the scope of the disclosure. Furthermore, it should be noted that, for ease of description, only the parts relevant to the present disclosure are shown in the accompanying drawings.
[0035] It should be noted that, where there is no conflict, the embodiments and features described in this disclosure can be combined with each other. The technical solutions of this disclosure will now be described in detail with reference to the accompanying drawings and embodiments.
[0036] Edge computing effectively alleviates the problems of high transmission latency, large bandwidth consumption, and privacy and security risks inherent in traditional cloud computing due to its centralized architecture by offloading computing tasks to nearby edge nodes. However, in heterogeneous edge environments, the high heterogeneity of computing resources (such as mixed CPU and GPU nodes) and tasks poses a severe challenge to efficient task-resource matching: on the one hand, existing stable matching methods (such as the classic delayed acceptance algorithm) usually assume homogeneous resources and adopt a one-to-one matching, resulting in low resource utilization and an inability to cope with many-to-one scenarios where the number of tasks far exceeds the number of nodes; on the other hand, most offloading strategies ignore the externalities in the matching process (i.e., the waiting time of subsequent tasks is affected by the scheduling of existing tasks) and do not consider task priority in queue scheduling, causing latency-sensitive tasks to easily time out due to queuing.
[0037] To address this, this disclosure proposes the following technical solution. First, based on the cost of task execution on each edge node, an unloading request is initiated to the edge computing node with the lowest cost value. When the request is rejected (i.e., a rejection message corresponding to the unloading request is received), the rejection message is parsed to obtain the real-time task queue information of the edge computing node (including the number of tasks and the computational workload of each task in the task queue). Based on this, the cost value of each edge computing node is recalculated, and the edge computing node preference list is updated. Then, an unloading request is re-initiated to the edge computing node with the lowest newly calculated cost value until a match is successful (i.e., the unloading request is not rejected). This technical solution adapts to changes in the load state of edge computing nodes through iteration, achieving stable and efficient matching between tasks and heterogeneous edge computing nodes. Through this technical solution, this disclosure significantly improves the adaptability of task unloading and the overall system performance in heterogeneous edge environments. On the one hand, by introducing task queue information as a real-time feedback factor to dynamically adjust task preferences, the overload and uneven load problems of edge computing nodes can be effectively alleviated, ensuring the priority scheduling of latency-sensitive tasks. On the other hand, the resulting stable and Pareto-optimal matching relationship avoids performance fluctuations caused by frequent task migrations. It reduces system energy consumption by 20.9% under low load and improves task completion rate by 29.1% under high load, balancing the multi-objective optimization needs of energy efficiency and service quality.
[0038] To facilitate description and make the technical solutions of this disclosure easier to understand, the terminology of this disclosure will be explained before describing the technical solutions of this disclosure.
[0039] Task offloading refers to the process of migrating some or all of the computing tasks generated on resource-constrained terminal devices (such as smartphones, IoT devices, and in-vehicle units) to edge computing nodes for execution. The core objective of task offloading is to alleviate terminal resource bottlenecks (such as computing power, battery energy, and storage space) and meet application requirements in terms of latency, energy efficiency, and reliability.
[0040] Edge computing nodes are distributed computing entities deployed at the network edge (close to terminal devices or data sources) and possessing certain computing, storage, and networking capabilities. They are used to process computing tasks generated by terminal devices locally or in the vicinity, thereby reducing dependence on remote cloud data centers.
[0041] This disclosure is applicable to distributed computing scenarios where resource-constrained terminals need to efficiently offload computing tasks to heterogeneous edge nodes, and is particularly suitable for high-dynamic, high-concurrency edge environments with stringent requirements for task completion rate and latency assurance. Examples include real-time perception and decision-making (such as target detection and path planning) in intelligent connected vehicle systems, low-latency closed-loop control in industrial IoT, and edge AI inference service clusters.
[0042] Figure 1 A schematic diagram of the structure of a task unloading system according to one embodiment of this disclosure is shown. Figure 1 The system shown consists of edge computing nodes 100, terminal devices 200, and electronic devices 300. The set of edge computing nodes 100 is represented as follows: , This indicates that the nth edge computing node is 100. N represents the total number of edge computing nodes 100. The set of terminal devices consisting of terminal devices 200 is represented as... , This indicates the m-th terminal device, 200. M represents the total number of terminal devices 200. In this system, some edge computing nodes 100 are equipped with only CPU processors, while others are equipped with both CPU and GPU processors. Each edge computing node 100 possesses different computing capabilities. To offload tasks, the terminal device 200 first sends the task to the electronic device 300. After receiving at least one task from different terminal devices 200, the electronic device 300 determines which edge computing node 100 each task matches (i.e., to which it needs to be offloaded), and then sends the offload request for each task to the corresponding edge computing node 100. Figure 2 A schematic diagram illustrating the overall flow of a task offloading method for edge computing according to one embodiment of this disclosure is shown. Figure 2The method shown includes steps S210 to S280. This method can be executed by a terminal device.
[0043] In step S210, the task to be unloaded to the edge computing node is received.
[0044] As one possible implementation, each terminal device generates an independent task, and the task set is denoted as... , This represents the task generated by the m-th terminal device.
[0045] In step S220, the cost of executing the task on each edge node is calculated.
[0046] Due to the limited computing power of terminal devices, local computation is not possible; therefore, tasks are processed by nearby edge computing nodes. The adaptability of tasks to different types of edge computing nodes varies significantly. Therefore, in one possible implementation, the task... Modeling as .in, This represents the task generated by the m-th terminal device. Data volume (unit: Mbit). Indicates task The amount of computational work required when executed on an edge computing node equipped only with a CPU processor (in CPU cycles). Indicates task When executing on edge computing nodes equipped with different GPU processors, the speedup compared to executing on edge computing nodes equipped with only CPU processors (which can be a factor of speedup). It should be noted that the speedup of a GPU is dynamically affected by various factors such as task characteristics, hardware status, and software environment, and is not determined solely by the number of cores and core frequency. Therefore, different GPU resources have different GPU speedup ratios. Indicates task The maximum tolerable delay.
[0047] In one possible implementation, task offloading focuses on two key optimization objectives: minimizing system cost (i.e., cost value) and maximizing the number of tasks completed. As one possible implementation, the cost value is a weighted sum of the total latency and total energy consumption of tasks executed on edge computing nodes. By calculating the cost value, tasks can be offloaded to the edge computing nodes with the lowest cost. For example, the cost value is calculated as follows: in, Indicates task (Can be a set of tasks) AAny task in the edge computing node) (Can be a set of edge computing nodes) B The cost value executed on any edge computing node in the process. Indicates task At edge computing nodes Total latency of execution. Indicates task At edge computing nodes Total energy consumption of the above execution The weighting coefficient represents the task completion time.
[0048] In a network environment, terminal devices communicate with edge computing nodes via wireless networks. The total latency of task offloading can be comprised of four parts: upload latency, computation latency, waiting latency, and download latency. Since the amount of downloaded data is negligible, as a possible implementation, download latency is ignored, and the total latency is set as the sum of transmission latency, waiting latency, and computation latency. The formula for calculating the total latency is as follows: ,in, Indicates task At edge computing nodes Total latency of execution. Indicates task At edge computing nodes The computational delay during execution. Indicates task At edge computing nodes The transmission delay during execution. Indicates task At edge computing nodes The waiting delay during execution.
[0049] Transmission delay is the ratio of the amount of data generated by the task from the terminal device to the transmission rate of the uplink channel between the terminal device and the edge computing node. The formula for calculating transmission delay is: in, express and The transmission rate of the uplink channel between them. express and The bandwidth between. Indicates channel gain, and and The distance between them is relevant. Channel gain can be calculated using the following formula: . ,express and Spatial path loss between them. express and The distance between them. Indicates noise power. express The transmission power.
[0050] Computational latency is the ratio of the computational workload required to execute a task on an edge computing node to the effective processor frequency of that node. Since a task can only be offloaded to one edge computing node, and in edge computing nodes equipped with GPUs, the GPU handles the primary computation while the CPU handles only a small amount of auxiliary computation, CPU latency and power consumption are ignored to focus on GPU performance analysis. Tasks executed on edge computing nodes equipped with GPUs have different speedup ratios.
[0051] In one possible implementation, when the edge computing node is equipped with a GPU processor, the computational workload required to execute a task on the edge computing node is the ratio of the computational workload required to execute the task on an edge computing node equipped with only a CPU processor to the speedup ratio, where the speedup ratio is the multiple of computational speed improvement obtained when the task is executed on an edge computing node equipped with a GPU processor compared to when it is executed on an edge computing node equipped with only a CPU processor.
[0052] In one example, the formula for calculating the computational latency of a task executed on an edge computing node equipped only with a CPU is: in, Indicates task Edge computing nodes equipped only with CPUs The computational delay during execution. This indicates an edge computing node equipped only with a CPU. The effective processor frequency.
[0053] In another example, the formula for calculating the computational latency of a task executed on an edge computing node equipped with a GPU is: in, Indicates task Edge computing nodes equipped with GPUs The computational delay during execution. This indicates an edge computing node equipped with a GPU. The effective processor frequency.
[0054] It is important to note that tasks offloaded to edge computing nodes may not execute immediately. Tasks will wait on the edge computing node according to their queuing order in the task queue. The waiting latency is the sum of the computation latencies of all tasks preceding this task in the task queue on the edge computing node. For example, the formula for calculating the waiting latency is expressed as: in, Represents edge computing nodes The length of the task queue (i.e., the number of tasks in the task queue). i represents the sequence number. This indicates the task queue is in the order of the task. The previous i-th task was on the edge computing node. The computational workload required for execution (unit: CPU cycles).
[0055] As one possible implementation, total energy consumption includes transmission energy consumption and computing energy consumption. For example, the formula for calculating total energy consumption is expressed as: ,in, Indicates task At edge computing nodes The energy consumption of the computation performed on it. Indicates task At edge computing nodes The energy consumption of transmission performed on the platform.
[0056] Transmission power consumption is the product of transmission delay and the transmit power of the terminal device. For example, the formula for calculating transmission power consumption is: .
[0057] Computational energy consumption is the product of computational latency and the power of the edge computing node. In one example, the formula for calculating the computational energy consumption of a task executed on an edge computing node equipped only with a CPU is: .in, Indicates task Edge computing nodes equipped only with CPUs The energy consumption of the computation performed on it. This indicates an edge computing node equipped only with a CPU. The power consumption. In another example, the formula for calculating the computational energy consumption of a task performed on an edge computing node equipped with a GPU is: .in, Indicates task Edge computing nodes equipped with GPUs The energy consumption of the computation performed on it. This indicates an edge computing node equipped with a GPU. The power.
[0058] In one possible implementation, the computing power of an edge computing node is the product of the effective switched capacitor of the edge computing node and the cube of the effective processor frequency of the edge computing node. In one example, an edge computing node equipped only with a CPU... power The calculation formula is: ,in, This refers to the effective switched capacitors of the CPU processor. In another example, an edge computing node equipped with a GPU... power The calculation formula is: ,in, This refers to the effective switched capacitor of the GPU processor.
[0059] In step S230, the cost values are arranged in ascending order to obtain the edge computing node preference list for the task.
[0060] As one possible implementation, each row in the edge computing node preference list corresponds to one edge computing node, and the row number corresponds to the cost value. That is, the edge computing node with the lowest cost value is set in row 1, the edge computing node with the second lowest cost value is set in row 2, and so on.
[0061] In step S240, a task unloading request is sent to the edge computing node that is at the top of the edge computing node preference list.
[0062] In the above implementation, the first edge computing node refers to the edge computing node in the first row. Since the optimization objective of task unloading is to minimize system cost (i.e., cost value), by calculating the cost value, tasks can select the edge computing node with the lowest cost value (i.e., the one at the top of the edge computing node preference list) for unloading.
[0063] The unloading request can include the data required for task execution, enabling edge computing nodes to execute the corresponding tasks based on the unloading request.
[0064] It's important to note that when multiple tasks are being unloaded simultaneously within the same timeframe, the edge computing nodes with the lowest cost values for these tasks may be the same or different. In the same case, unloading requests for multiple tasks can be sent to the same edge computing node concurrently.
[0065] In step S250, in response to receiving the rejection information corresponding to the unload request, the rejection information is parsed to obtain task queue information. The task queue information includes the number of tasks in the task queue corresponding to the edge computing node and the computational workload of each task in the task queue.
[0066] Task queue information can be included in the rejection information for subsequent cost recalculation. In one possible implementation, in addition to task queue information, the rejection information may also include task identifiers (IDs), edge computing node identifiers (IDs), etc.
[0067] In step S260, the cost value of executing the task on each edge node is recalculated based on the task queue information.
[0068] The method for recalculating the cost value is the same as the method for calculating the cost value in step S220, and will not be repeated here.
[0069] In step S270, the edge computing node preference list is updated in response to recalculating the cost value.
[0070] As one possible implementation, in updating the edge computing node preference list, each edge computing node in the edge computing node preference list is rearranged in ascending order of its recalculated cost value.
[0071] In step S280, in response to the update of the edge computing node preference list, a task unloading request is sent to the edge computing node that is first in the updated edge computing node preference list.
[0072] Steps S210 to S280 introduce a task queue information awareness mechanism based on rejection feedback during the task unloading process, and dynamically recalculate the cost value and iteratively update the node preference list accordingly. This enables the task unloading decision to adapt to changes in the load status of the edge computing nodes in real time. During the iteration process, steps S250 to S280 are repeated until the unloading request is executed by the edge computing node (no rejection information corresponding to the unloading request is received). This embodiment can avoid high latency or task drop caused by continuously sending requests to overloaded edge computing nodes. This implementation can also work in conjunction with a relaxed time-first queue scheduling strategy, which can significantly improve the completion rate of latency-sensitive tasks in high-concurrency heterogeneous environments (29.1% improvement under high load), while reducing system energy consumption (20.9% reduction) under low load, achieving a Pareto optimal trade-off between system cost and service quality, and ensuring the stability and anti-disturbance capability of the matching results.
[0073] According to any of the above embodiments, this disclosure also provides a task unloading device 300. Figure 3 This is a schematic block diagram of a task unloading device 300 according to one embodiment of this disclosure. Figure 3As shown, the task unloading device 300 includes: a task receiving module 310, a cost value calculation module 320, a preference list generation module 330, an unloading request sending module 340, a task queue information acquisition module 350, a cost value recalculation module 360, a preference list update module 370, and an unloading request resending module 380. The task receiving module 310 receives tasks to be unloaded to edge computing nodes. The cost value calculation module 320 calculates the cost value of the task execution on each edge node. The preference list generation module 330 arranges the cost values in ascending order to obtain an edge computing node preference list for the task. The unloading request sending module 340 sends an unloading request to the edge computing node at the top of the edge computing node preference list. The task queue information acquisition module 350, in response to a received rejection message for the unloading request, parses the rejection message to obtain task queue information, which includes the number of tasks in the task queue corresponding to the edge computing node and the computational workload of each task in the task queue. The cost recalculation module 360 recalculates the cost of executing tasks on each edge node based on the task queue information. The preference list update module 370 updates the edge computing node preference list in response to the cost recalculation. The unload request resend module 380 sends an unload request for the task to the first edge computing node in the updated preference list in response to the updated preference list.
[0074] According to further embodiments of this disclosure, an electronic device is also provided. Figure 4This diagram illustrates a schematic block diagram of an electronic device employing a processor-based hardware implementation according to an embodiment of the present disclosure. The hardware structure of the electronic device of the present disclosure can be implemented using a bus architecture. The bus architecture can include any number of interconnect buses and bridges, depending on the specific application and overall design constraints of the hardware. Bus 1100 connects various circuits including one or more processors 1200, memory 1300, and / or hardware modules. Bus 1100 can also connect various other circuits 1400 such as peripheral devices, voltage regulators, power management circuits, external antennas, etc. Bus 1100 can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Component (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc. For ease of illustration, only one connecting line is used in this figure, but this does not imply that there is only one bus or one type of bus. Memory 1300 stores a computer program, and when processor 1200 executes the computer program, processor 1200 is able to perform the following processes. Receive tasks to be offloaded to edge computing nodes. Calculate the cost of executing the tasks on each edge node. Sort the cost values in ascending order to obtain the edge computing node preference list for the tasks. Send an offload request for the task to the edge computing node at the top of the preference list. In response to a rejection message received for the offload request, parse the rejection message to obtain task queue information, which includes the number of tasks in the task queue corresponding to the edge computing node and the computational workload of each task in the task queue. Based on the task queue information, recalculate the cost of executing the tasks on each edge node. In response to the recalculated cost values, update the edge computing node preference list. In response to the updated edge computing node preference list, send an offload request for the task to the edge computing node at the top of the updated preference list.
[0075] This disclosure also provides a readable storage medium storing a computer program that, when executed by a processor, is used to implement the methods described above. A "readable storage medium" can be any means capable of containing, storing, communicating, propagating, or transmitting a program for use by or in conjunction with an instruction execution system, apparatus, or device. More specific examples of a readable storage medium include: an electrical connection with one or more wires (electronic device), a portable computer disk drive (magnetic device), random access memory (RAM), read-only memory (ROM), erasable and programmable read-only memory (EPROM or flash memory), fiber optic devices, and portable read-only memory (CDROM), etc.
[0076] This disclosure also provides a computer program product, the methods of which can be implemented wholly or partially through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented wholly or partially as a computer program product. The computer program product includes one or more computer programs or instructions. When the computer program or instructions are loaded and executed, all or part of the processes or functions of this disclosure are performed.
[0077] Computer programs or instructions can be stored in a readable storage medium or transferred from one readable storage medium to another. For example, the computer program or instructions can be transferred from one website, computer, server, or data center to another website, computer, server, or data center via wired or wireless means. The readable storage medium can be any available medium capable of access, or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium, such as a floppy disk, hard disk, or magnetic tape; an optical medium, such as a digital video optical disc; or a semiconductor medium, such as a solid-state drive. The computer-readable storage medium can be a volatile or non-volatile storage medium, or it can include both volatile and non-volatile types of storage media.
[0078] Those skilled in the art will understand that embodiments of this disclosure can be provided as methods, systems, or computer program products. Therefore, this disclosure can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this disclosure can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0079] This disclosure is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus, and computer program products according to this disclosure. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0080] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0081] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0082] Figure 5 A schematic diagram illustrating the overall flow of a task execution method according to one embodiment of this disclosure is shown. Figure 5 The method shown includes steps S510 to S540. This method can be executed by an edge computing node.
[0083] In step S510, at least one unload request is received, and the relaxation time of the task corresponding to each unload request is calculated.
[0084] Relaxation time refers to the time remaining before the task deadline. When multiple task offload requests are sent to the same edge computing node simultaneously (or within the same time period) in step S240, the relaxation time for each task corresponding to the offload request needs to be calculated. As one possible implementation, the relaxation time is the difference between the task's maximum tolerable latency and the total latency of the task's execution on the edge computing node.
[0085] As a further implementation, since the edge computing node needs to determine whether to execute the task based on the task's relaxation time after receiving the unload request, the total delay used to calculate the relaxation time can be added to the unload request to avoid redundant calculations.
[0086] In step S520, the task corresponding to the minimum relaxation time is executed.
[0087] To maximize the number of tasks completed, edge computing nodes need to prioritize tasks with closer deadlines (i.e., minimum relaxation time). One possible implementation involves executing the task with the minimum relaxation time, which includes: adding the task with the minimum relaxation time to the tail of the task queue; and executing the task at the head of the task queue.
[0088] In step S530, all tasks except those corresponding to the task with the minimum relaxation time are rejected, and corresponding rejection information is generated. The rejection information includes the task queue information corresponding to the task queue.
[0089] When a task matches an edge computing node (i.e., the edge computing node receives an offload request for the task) but the total latency exceeds the task's deadline, the task should be discarded (i.e., execution should be refused) to prevent resource waste. This allocates the edge computing node's resources to tasks that can be completed within the deadline, further improving resource utilization efficiency and task completion rate.
[0090] As one possible implementation, the tasks corresponding to the received uninstallation requests are arranged in ascending order of relaxation time, and only the task at the top of the list is executed, while the other tasks are rejected.
[0091] In step S540, a rejection message is sent to the electronic device.
[0092] Through steps S510 to S540, the edge computing node only receives the unloading request of the task with the most urgent deadline, and the other unloading requests are rejected. This can avoid overload caused by multiple tasks being unloaded to the same edge computing node at the same time, and can achieve a stable and Pareto optimal match between tasks and edge computing nodes.
[0093] As a further implementation, before step S510, the method further includes: determining whether the number of tasks in the task queue is equal to a task number threshold. If the number is not equal to the task number threshold, steps S510 to S540 are executed. If the number is equal to the task number threshold, the tasks corresponding to each received unloading request are rejected, corresponding rejection information is generated, and returned to the electronic device. The task number threshold can be set according to business needs and hardware conditions, and is not limited here.
[0094] In the description of this specification, the references to terms such as "one embodiment / mode," "some embodiments / modes," "example," "specific example," or "some examples," etc., refer to specific features, structures, or characteristics described in connection with that embodiment / mode or example, which are included in at least one embodiment / mode or example of this disclosure. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment / mode or example. Moreover, the specific features, structures, or characteristics described may be combined in any suitable manner in one or more embodiments / modes or examples. Furthermore, without contradiction, those skilled in the art can combine and integrate the different embodiments / modes or examples described in this specification, as well as the features of different embodiments / modes or examples.
[0095] Those skilled in the art should understand that the above embodiments are merely for illustrating the present disclosure and are not intended to limit the scope of the disclosure. Those skilled in the art can make other changes or modifications based on the above disclosure, and these changes or modifications still fall within the scope of the present disclosure.
Claims
1. A task offloading method for edge computing, characterized in that, include: Receive tasks to be unloaded to edge computing nodes; Calculate the cost of executing the task on each edge node; Arrange the cost values in ascending order to obtain the edge computing node preference list for the task; Send the task unload request to the edge computing node that is at the top of the edge computing node preference list; In response to receiving the rejection information corresponding to the uninstallation request, the rejection information is parsed to obtain task queue information, which includes the number of tasks in the task queue corresponding to the edge computing node and the computational workload of each task in the task queue. Based on the task queue information, recalculate the cost value of the task executed on each edge node; In response to recalculating the cost value, the edge computing node preference list is updated; as well as In response to an update to the edge computing node preference list, an unload request for the task is sent to the edge computing node that is first in the updated edge computing node preference list.
2. The method as described in claim 1, characterized in that, The cost value is the weighted sum of the total latency and total energy consumption of the task executed on the edge computing node.
3. The method as described in claim 2, characterized in that, The total latency is the sum of transmission latency, waiting latency, and computation latency. The transmission latency is the ratio of the amount of data generated by the task produced by the terminal device to the transmission rate of the uplink channel between the terminal device and the edge computing node. The computation latency is the ratio of the computational workload required for the task to be executed on the edge computing node to the effective processor frequency of the edge computing node. The waiting latency is the sum of the computational latencies of all tasks in the task queue corresponding to the edge computing node that precede the task being executed on the edge computing node.
4. The method as described in claim 3, characterized in that, When the edge computing node is equipped with a GPU processor, the computational workload required for a task to be executed on the edge computing node is the ratio of the computational workload required for the task to be executed on an edge computing node equipped with only a CPU processor to the speedup ratio, where the speedup ratio is the multiple by which the computational speedup is achieved when the task is executed on an edge computing node equipped with a GPU processor compared to when it is executed on an edge computing node equipped with only a CPU processor.
5. The method as described in claim 2, characterized in that, The total energy consumption includes transmission energy consumption and computing energy consumption. The transmission energy consumption is the product of transmission delay and the transmit power of the terminal device, and the computing energy consumption is the product of computing delay and the power of the edge computing node.
6. The method as described in claim 5, characterized in that, The power of the edge computing node is the product of the effective switched capacitor of the edge computing node and the cube of the effective processor frequency of the edge computing node.
7. An electronic device, characterized in that, include: The memory stores execution instructions; as well as A processor that executes execution instructions stored in the memory, causing the processor to perform the task offloading method for edge computing as described in any one of claims 1 to 6.
8. A readable storage medium, characterized in that, The readable storage medium stores execution instructions, which, when executed by a processor, are used to implement the task offloading method for edge computing as described in any one of claims 1 to 6.
9. A task unloading system, characterized in that, include: The electronic device and edge computing node as described in claim 7.
10. The system as described in claim 9, characterized in that, The method executed by the edge computing node includes: Receive at least one uninstallation request and calculate the relaxation time for the task corresponding to each uninstallation request; Execute the task corresponding to the minimum relaxation time; Refuse to execute any tasks other than the task corresponding to the minimum relaxation time, and generate corresponding rejection information, which includes task queue information corresponding to the task queue; and The rejection message is sent to the electronic device.