Resource scheduling methods, apparatus, equipment, storage media and computer program products
By employing task offloading and resource scheduling methods among neighboring MEC devices in IoT devices, and utilizing adaptive degree functions and SSA algorithms to optimize resource allocation, the real-time and robustness issues of IoT devices are solved, achieving decentralized and efficient resource utilization.
Patent Information
- Application Number
- CN202411177830.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-26
- Publication Date
- 2026-07-10
- Estimated Expiration
- 2044-08-26
AI Technical Summary
The real-time processing requirements of IoT devices in existing technologies are insufficient due to centralized architecture, resulting in poor real-time performance, poor robustness, and unreasonable resource utilization, which cannot meet the decentralized requirements of IoT devices.
By issuing task offloading requests among neighboring MEC devices, assessing their processing capabilities, and determining the target MEC device based on energy consumption and latency information, resource scheduling is optimized using an adaptive degree function and SSA algorithm, thereby achieving decentralized task migration and resource allocation.
It improves the real-time processing capabilities of IoT devices, enhances the robustness and resource utilization efficiency of the system, reduces latency and energy consumption, and realizes the efficiency and flexibility of distributed computing.
Smart Images

Figure CN119094528B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of communication technology, and in particular to a resource scheduling method, apparatus, device, storage medium, and computer program product. Background Technology
[0002] Currently, centralized data processing architectures are primarily used for resource scheduling, where data is transmitted from users to the cloud, processed by the cloud, and then returned. This architecture presents several problems for the real-time processing needs of Internet of Things (IoT) devices: Insufficient real-time performance: Centralized architecture leads to significant data transmission delays, failing to meet the real-time requirements of IoT devices; Poor robustness: If the central node fails, the entire system may collapse, lacking the robustness provided by decentralization; Inefficient resource utilization: The central node may be overloaded due to concentrated tasks, while the computing power of edge nodes is not fully utilized. Therefore, how to achieve decentralized resource scheduling has become an urgent problem to be solved. Summary of the Invention
[0003] This invention provides a resource scheduling method, apparatus, device, storage medium, and computer program product to address the shortcomings of existing technologies in achieving decentralized resource scheduling, thereby realizing decentralized resource scheduling.
[0004] This invention provides a resource scheduling method, comprising the following steps:
[0005] In response to a task unloading request sent by a terminal device, the task to be unloaded carried in the task unloading request is published to a nearby MEC device;
[0006] The evaluation result of the task to be unloaded, sent by the nearby MEC device, is received; the evaluation result is used to characterize whether the nearby MEC device has the ability to process the task to be unloaded.
[0007] If, based on the evaluation results, it is determined that the task to be unloaded needs to be migrated, at least one target MEC device is identified according to the energy consumption information and latency information of the MEC device, and the task to be unloaded is scheduled to the target MEC device.
[0008] According to a resource scheduling method provided by the present invention, the energy consumption information includes an energy consumption weighting coefficient and the energy consumed by the MEC device in processing the task to be unloaded; the latency information includes a latency weighting coefficient and the total latency required by the MEC device in processing the task to be unloaded.
[0009] Based on the energy consumption and latency information of the MEC devices, at least one target MEC device is identified, including:
[0010] An adaptive function is determined based on the energy consumption weight coefficient, the energy consumed by the MEC device in processing the task to be offloaded, the time consumption weight coefficient, and the total time required by the MEC device in processing the task to be offloaded; the adaptive function satisfies the balance between minimizing energy consumption and QoS satisfaction.
[0011] Based on the adaptive function, the MEC device is searched to determine the optimal combination of offloading strategies;
[0012] Based on the optimal combination offloading strategy, at least one target MEC device is identified.
[0013] According to a resource scheduling method provided by the present invention, the step of searching the MEC device based on the adaptive degree function to determine the optimal combination offloading strategy includes:
[0014] The MEC devices in the idle state are encoded and marked as population particles for initialization to obtain the MEC device population;
[0015] A subpopulation is initialized for a single MEC device that is in an idle state to obtain a subpopulation;
[0016] Update the positions of the leader and followers in the subpopulation according to the adaptive function;
[0017] The food source locations of the subpopulation are updated based on the fitness values of each individual in the subpopulation after the location update; the food source locations represent the optimal solution.
[0018] The food source locations of the MEC device population are updated based on the comparison results between the subpopulation and the MEC device population.
[0019] Based on the fitness value of each individual in the MEC device population after the food source location is updated, the search operation of the MEC device is iterated, and the optimal combination unloading strategy is output.
[0020] According to a resource scheduling method provided by the present invention, updating the positions of the leader and followers in the subpopulation based on the adaptive degree function includes:
[0021] Calculate the first fitness value of each sub-individual in the subpopulation based on the adaptive fitness function;
[0022] Sort the first fitness values in descending order to obtain a sorted sequence;
[0023] The first sub-individual ranked first in the sorting sequence is designated as the leader of the subpopulation, and the remaining sub-individuals in the sorting sequence are designated as the followers of the subpopulation.
[0024] According to a resource scheduling method provided by the present invention, updating the food source location of the MEC device population includes updating the positions of the leader and followers in the MEC device population;
[0025] The step of updating the food source location of the MEC device population based on the comparison results of food source locations between the subpopulation and the MEC device population includes:
[0026] The results of the comparison between the leader's position and the follower's position are determined between the subpopulation and the MEC device population; the comparison results of the food source positions include the results of the comparison between the leader's position and the follower's position.
[0027] If the comparison result of the leader's position is that the position of the leader of the subpopulation is better than the position of the leader of the MEC device population, then the position of the leader of the MEC device population is updated to the position of the leader of the subpopulation.
[0028] If the position comparison result of the followers is that the position of the followers of the subpopulation is better than the position of the followers of the MEC device population, then the position of the followers of the MEC device population is updated to the position of the followers of the subpopulation.
[0029] According to a resource scheduling method provided by the present invention, the energy consumption weight coefficient and time consumption weight coefficient of the MEC device are determined based on the terminal attribute document of the MEC device; the terminal attribute document is established in the following manner:
[0030] Obtain the basic device information of the MEC device; the basic device information includes at least one of energy consumption sensitive information, basic power, computing power, storage capacity, and latency sensitive information;
[0031] Based on the device's basic information, the terminal attribute document is created.
[0032] The present invention also provides a resource scheduling device, comprising the following modules:
[0033] The request-response module is used to respond to the task unloading request sent by the terminal device and publish the task to be unloaded carried in the task unloading request to the nearby MEC device.
[0034] A receiving module is configured to receive the evaluation result of the task to be unloaded sent by the nearby MEC device; the evaluation result is used to characterize whether the nearby MEC device has the ability to process the task to be unloaded.
[0035] The scheduling module is used to determine at least one target MEC device based on the energy consumption information and latency information of the MEC device when it is determined from the evaluation results that the task to be unloaded needs to be migrated, and to schedule the task to be unloaded to the target MEC device.
[0036] The present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement any of the resource scheduling methods described above.
[0037] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the resource scheduling method as described above.
[0038] The present invention also provides a computer program product, including a computer program that, when executed by a processor, implements any of the resource scheduling methods described above.
[0039] The resource scheduling method, apparatus, device, storage medium, and computer program product provided by this invention, in response to a task offloading request sent by a terminal device, publishes the task to be offloaded carried in the task offloading request to a nearby MEC device; receives the evaluation result of the task to be offloaded sent by the nearby MEC device; the evaluation result is used to characterize whether the nearby MEC device has the ability to process the task to be offloaded; if it is determined based on the evaluation result that the task to be offloaded needs to be migrated, at least one target MEC device is determined according to the energy consumption information and latency information of the MEC device, and the task to be offloaded is scheduled to the target MEC device. In this invention, the task does not need to be offloaded from the cloud central node to the edge device, but the local edge device accepts the task request, uses a distributed computing strategy, and autonomously completes resource allocation, realizing decentralized resource scheduling. Attached Figure Description
[0040] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0041] Figure 1 This is a flowchart illustrating the resource scheduling method provided by the present invention.
[0042] Figure 2 This is a flowchart illustrating the process for determining the energy consumption weighting coefficient and time consumption weighting coefficient of MEC equipment, provided by the present invention.
[0043] Figure 3 This is a schematic diagram of the framework of the decentralized MEC system provided by the present invention.
[0044] Figure 4 This is a flowchart illustrating the task unloading process provided by the present invention.
[0045] Figure 5 This is a flowchart illustrating the resource allocation process provided by the present invention.
[0046] Figure 6 This is a schematic diagram of the resource scheduling device provided by the present invention.
[0047] Figure 7 This is a schematic diagram of the structure of the electronic device provided by the present invention. Detailed Implementation
[0048] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.
[0049] The following is combined with Figures 1-7 The present invention describes a resource scheduling method, apparatus, device, storage medium, and computer program product.
[0050] Figure 1 This is a flowchart illustrating the resource scheduling method provided by the present invention, as follows: Figure 1 As shown, the method includes the following:
[0051] Step 101: In response to the task unloading request sent by the terminal device, publish the task to be unloaded carried in the task unloading request to the nearby MEC device;
[0052] As can be understood, task offloading refers to the process of transferring computing tasks from smart terminal devices or mobile devices (such as smartphones, sensors, etc.) to mobile edge computing (MEC) devices for processing. The purpose of task offloading is to improve processing efficiency, reduce the computing burden and energy consumption of terminal devices, and simultaneously reduce task processing latency.
[0053] In this embodiment of the invention, the MEC device deployed at the network edge can be understood as an MEC node, responsible for processing data, executing tasks, and providing low-latency computing resources. Each MEC node is pre-configured with a micro-evaluation system that can quickly assess key parameters of a task, such as energy consumption, latency, and communication costs. Simultaneously, the evaluation system can optimize task allocation based on the specific requirements of the task (such as computational complexity and data volume) and the current network and device status (such as transmission distance and terminal device battery level). This evaluation capability enables MEC nodes to make more accurate decisions, improving resource utilization and reducing overall energy consumption.
[0054] MEC nodes are highly autonomous, capable of handling task allocation and resource management independently, without relying on a central control system. Furthermore, MEC nodes can freely connect, forming a dynamic network structure. This ability to freely connect allows the MEC cluster to adjust its network topology as needed, adapting to different load and task requirements. In this structure, there is no fixed central node or single point of control; each node can become the central node at a specific stage, coordinating task processing and resource allocation, achieving decentralization and thus improving the system's flexibility and robustness.
[0055] In a distributed computing environment, after a terminal device generates a task offload request, it sends this request to the nearest MEC device. The task offload request includes the task to be offloaded and its related information, such as task type, data volume, and processing requirements. The MEC device receiving the task offload request first assesses the task's requirements, including computing power, data volume, and time constraints. Simultaneously, it checks whether its own resources (such as computing power, memory, and network bandwidth) are sufficient to handle the task. If the MEC device finds its resources insufficient, or believes that task processing can be completed more efficiently on other devices, it will publish the task to be offloaded to neighboring MEC devices; alternatively, it will directly forward the task offload request to neighboring MEC devices. The forwarded request will carry all information about the original task, including a detailed description of the task, data, and processing requirements. Neighboring MEC devices refer to devices that are physically close, thus reducing data transmission latency.
[0056] Step 102: Receive the evaluation results of the unloaded tasks sent by the nearby MEC device.
[0057] Upon receiving a task to be unloaded or a task unloading request, each neighboring MEC device evaluates the task, including parameters such as computational load, energy consumption, and latency. Then, the neighboring MEC devices share the evaluation results and task parameters. The evaluation results characterize whether a neighboring MEC device has the capability to handle the task to be unloaded, including assessing its computing power, resource availability, energy consumption, and latency requirements. The task parameters include task load, task type, processing time, energy consumption requirements, data transmission volume, latency requirements, priority, and current status.
[0058] MEC devices receive evaluation results and mission parameters shared by neighboring MEC devices.
[0059] Step 103: If it is determined from the evaluation results that the task to be unloaded needs to be migrated, at least one target MEC device is identified based on the energy consumption information and latency information of the MEC device, and the task to be unloaded is scheduled to the target MEC device.
[0060] As is understandable, task migration refers to the process of moving computing tasks from one MEC device to another, with the aim of optimizing resource utilization, improving system performance, and reducing latency and energy consumption.
[0061] After receiving the evaluation results from each neighboring MEC device, the MEC device evaluates the task migration strategy based on the evaluation results to determine whether the task to be unloaded needs to be migrated. For example, if the resources of the current node (such as CPU, memory, and storage) are close to saturation and the neighboring MEC devices have the ability to handle the task to be unloaded, task migration can be performed to reduce the load; or, if the load of each node is uneven, task migration is required to achieve load balancing and improve the overall system performance.
[0062] After determining that the task to be unloaded requires task migration, at least one target MEC device is identified based on the energy consumption and latency information of the MEC device, and the task to be unloaded is scheduled to the target MEC device. The energy consumption information includes an energy consumption weighting coefficient and the energy consumed by the MEC device to process the task to be unloaded; the latency information includes a time consumption weighting coefficient and the total time required for the MEC device to process the task to be unloaded.
[0063] For example, a distributed resource allocation model can be established, and the SSA algorithm (Salp Swarm Algorithm) can be used to find the optimal strategy for idle MEC devices (i.e., MEC devices in an idle state), and the individual optimal values can be shared with each other to output the optimal combination of offloading strategies.
[0064] The resource scheduling method provided in this invention responds to a task offloading request sent by a terminal device by publishing the task to be offloaded carried in the task offloading request to a nearby MEC device; receives the evaluation result of the task to be offloaded sent by the nearby MEC device; the evaluation result is used to characterize whether the nearby MEC device has the ability to process the task to be offloaded; if it is determined based on the evaluation result that the task to be offloaded needs to be migrated, at least one target MEC device is determined according to the energy consumption information and latency information of the MEC device, and the task to be offloaded is scheduled to the target MEC device. In this invention, the task does not need to be offloaded from the cloud central node to the edge device, but the local edge device accepts the task request, uses a distributed computing strategy, and autonomously completes resource allocation, thereby realizing decentralized resource scheduling.
[0065] Based on the above embodiments, at least one target MEC device is determined according to the energy consumption information and latency information of the MEC device, including:
[0066] Step 1030: Determine the adaptive degree function based on the energy consumption weight coefficient, the energy consumed by the MEC device to process the offloaded task, the time consumption weight coefficient, and the total time required for the MEC device to process the offloaded task; the adaptive degree function satisfies the balance between minimizing energy consumption and QoS satisfaction.
[0067] Step 1031: Based on the adaptive degree function, search the MEC devices to determine the optimal combination of offloading strategies;
[0068] Step 1032: Based on the optimal combination offloading strategy, identify at least one target MEC device.
[0069] Establish a distributed resource allocation model and determine an adaptive function that balances energy consumption minimization and service quality (QoS) satisfaction:
[0070] ;
[0071] in, This represents the energy consumed by the MEC device to process the offloading tasks, i.e., the MEC node. Processing tasks The energy consumed; This represents the energy consumption weighting coefficient; This represents the total time required for the MEC device to process the unloading task, i.e., the time required for the MEC node to complete the task. Processing tasks Total time spent; This represents the time-consuming weighting coefficient.
[0072] After determining the adaptive function, the SSA algorithm is used to find the optimal value for all MEC devices, and the individual optimal values are shared among them to output the optimal combination offloading strategy.
[0073] For example, the task set is:
[0074] ;
[0075] Assuming each MEC device Processing tasks The energy consumed is and each MEC device Up processing tasks The total time spent is , For MEC devices The energy consumed in performing all tasks. For MEC devices power consumption, Task allocation matrix for the size of the task set The size is Task allocation matrix Each element in is represented as , To carry out the mission Required power The total latency for executing application A on the MEC node. For MEC devices and MEC equipment The transmission distance between them. Under the constraints of latency and computational resource limitations, the optimization objective can be described as:
[0076] (1) Total energy consumption:
[0077] ;
[0078] (2) Total delay:
[0079] ;
[0080] The steps for finding the optimal combination of unloading strategies using the SSA algorithm include:
[0081] (1) Encode the idle MEC devices and mark them as population particles for initialization to obtain the MEC device population. For example, first assign a unique code to each idle MEC device to represent the state or characteristics of the device; then, initialize these codes as particles in the SSA algorithm to form the initial population of the algorithm. Each particle represents a possible solution or strategy, through which the algorithm can explore the solution space of the optimization problem.
[0082] (2) Initialize a subpopulation for a single idle MEC device to obtain a subpopulation. For example, select one MEC device to initialize the subpopulation, set the algorithm parameters, and define a subpopulation initialization size of n, a number of MEC devices of m, and a population of D tunicates, denoted as [missing information]. ,in The third particle in the MEC device with code 2.
[0083] (3) Update the positions of the leader and followers in the subpopulation according to the fitness function. Specifically, calculate the first fitness value of each individual in the subpopulation according to the fitness function; sort the first fitness values in descending order to obtain the sorting sequence; take at least one individual ranked first in the sorting sequence as the leader of the subpopulation, and take the remaining individuals in the sorting sequence as the followers of the subpopulation.
[0084] For example, initialize each The leader's position. Calculate the fitness values of the N salps (i.e., child individuals or MEC child individuals), i.e., calculate the value of the adaptive fitness function; then, sort all i×j salps in descending order of fitness value (i.e., from largest to smallest), and update the position of the salps with the best fitness at the top of the list to the latest food position in the node group. Further, perform position updates: for the remaining N-1 salps in the group, sort them in descending order of fitness value, and consider the top N / 2 salps as leaders, and the remaining N / 2 as followers.
[0085] Understandably, the leader is the currently optimal particle, representing the best solution or strategy. Within each subpopulation, the leader is the particle with the highest fitness, guiding the movement of other particles and helping to optimize the search process. Followers are particles that follow the leader and are second-best particles with relatively good fitness. Followers adjust their positions based on the leader's position to better follow the leader and explore the solution space during the optimization process. The goal of the followers is to gradually approach the leader, thereby improving the overall optimization performance of the population.
[0086] (4) Update the food source location of the subpopulation based on the fitness value of each individual in the subpopulation after the location update. Here, the food source location represents the optimal solution, signifying the target location for finding the optimal solution. For example, each independent MEC device... Prioritize updating the latest leader of your own subpopulation. and followers .
[0087] Understandingly, updating the leader's position signifies finding the current optimal food source location, i.e., optimizing the current solution. Updating the followers' positions involves following the leader's adjustment, helping other individuals approach this optimized location, thereby spreading a superior solution throughout the population. Changes in the leader's position directly impact the updating of food source locations, as the leader's position represents the optimal solution or a location close to it. Therefore, updating the positions of both the leader and followers can be viewed as a way to update food source locations, as this helps optimize the entire search space and find better solutions.
[0088] (5) Update the food source positions of the MEC device population based on the comparison results of food source positions between the subpopulation and the MEC device population. The comparison results include the leader's position comparison and the follower's position comparison; updating the food source positions of the MEC device population includes updating the positions of the leader and followers within the MEC device population. Specifically, determine the leader's position comparison results and the follower's position comparison results between the subpopulation and the MEC device population; if the leader's position comparison results show that the subpopulation's leader's position is superior to the MEC device population's leader's position, then update the MEC device population's leader's position to the subpopulation's leader's position; if the follower's position comparison results show that the subpopulation's follower's position is superior to the MEC device population's follower's position, then update the MEC device population's follower's position to the subpopulation's follower's position.
[0089] For example, the leader of a single MEC device subpopulation and followers Each with the leader of the MEC device population and followers In comparison, if If it's better, then update. for ;if If it's better, then update. for ,vice versa.
[0090] (6) Based on the fitness value of each individual in the MEC device population after the food source location is updated, iterate the search operation of the MEC device and output the optimal combination unloading strategy.
[0091] For example, the fitness value of the updated MEC device population is calculated, and the fitness value of each updated salps is compared with the fitness value of the current food. If the updated salps have a better fitness value than the food, the location of the salps with the better fitness value is taken as the new food location. The position update operation for the population leader and followers is repeated until a set number of iterations is reached or the fitness value meets certain requirements. After the termination condition is met, the current food location is output as the estimated location of the target.
[0092] This invention utilizes idle MEC devices as population particles in the SSA algorithm, resulting in a population composed of MEC devices. Each individual MEC device can then reinitialize its subpopulations, forming a two-layer heuristic computing model. By leveraging the distributed and efficient computing characteristics of MECs, the improved SSA algorithm is upgraded from one-dimensional to two-dimensional computation, resulting in exponential growth in capability. This saves latency in multi-objective optimization and improves MEC resource utilization.
[0093] Based on the above embodiments, the energy consumption weighting coefficient and time consumption weighting coefficient of the MEC device are determined based on the terminal attribute document of the MEC device; the terminal attribute document is established in the following way:
[0094] Obtain the basic equipment information of the MEC device; the basic equipment information includes at least one of the following: energy consumption sensitive information, basic power, computing power, storage capacity, and latency sensitive information; based on the basic equipment information, establish a terminal attribute document.
[0095] For example, creating device cloud profiles based on device attributes facilitates the allocation of different task offloading and resource scheduling priorities for specific devices. (Reference) Figure 2 This involves collecting basic information about MEC devices, including energy-sensitive information, base power, computing power, storage capacity, and latency-sensitive information, to provide a basis for MEC device decision-making. For marked terminal attributes, a terminal attribute document is created. Then, based on the device's own performance, power supply method, computing, and communication capabilities, energy consumption weighting coefficients and latency weighting coefficients are assigned to the MEC device without affecting QoS. For example, considering two terminal devices, a monitoring device and an alarm device, the monitoring device has higher bandwidth requirements and heavier computing tasks, tending towards higher energy consumption. With delay The ratio is 8:2, and alarm devices tend to respond more quickly, so energy consumption... and latency The ratio is 2:8.
[0096] This invention takes into account the different requirements of each terminal device, constructs a cloud profile for the terminal device, and sets energy consumption weight coefficient and latency weight coefficient to effectively improve resource allocation efficiency.
[0097] To further explain the resource scheduling method provided by the present invention, please refer to the following embodiments.
[0098] This invention proposes a distributed computing resource scheduling method based on edge computing, specifically a task offloading and resource rational scheduling method in a decentralized regional neighbor MEC system. This method comprehensively considers the transmission time, energy consumption, task dependencies, and communication and computation costs arising from distribution distances between MEC devices. The method mainly includes: establishing cloud profiles for intelligent terminal devices, including terminal device communication volume, location, energy consumption requirements, and time parameters. Because different device types have different priorities in energy consumption and latency requirements, the original path involved terminal tasks being uploaded to the cloud center, with the cloud center handling computation offloading and resource allocation. The new method proposed in this invention distributes the computation from the original cloud center to the Layer 2 MEC devices, reducing the excessive load on the cloud center caused by task concentration. Each MEC device has a pre-configured microsystem that quickly calculates energy consumption, latency, and communication costs based on task transmission distance, task set size, and data volume. Dynamic task strategy management allows MEC nodes to prioritize tasks suitable for their own attributes. Multiple nodes asynchronously exchange information and combine to output the optimal task combination processing strategy for dependent tasks. For tasks requiring combined processing, the computational load of the model increases exponentially with the increase of tasks and edge devices. To save processing latency, the heuristic algorithm SSA is proposed. To improve convergence speed, each MEC device uses a random walk method to update the location of the food source, which is equivalent to each MEC device becoming a particle, thus accelerating the convergence speed of the mainstream SSA and improving the speed of the decision model. The practical problem is transformed into a minimum optimization problem of the adaptive degree function, which quickly finds the adaptive global optimum and outputs the decisions on task unloading, communication resource allocation, and computing resource allocation.
[0099] refer to Figure 3 The edge computing-based distributed computing resource scheduling method mainly includes the following:
[0100] S1 constructs weighted coefficients: establish MEC device cloud profiles for smart devices, including device communication network status, location, energy consumption, and latency parameters, etc., because different device types have different focuses on energy consumption and latency requirements, and balance the energy consumption weight coefficient and latency weight coefficient of the device.
[0101] S2 Task Unloading Process: A decentralized, dynamic node task management strategy is proposed to reduce task spillover and lower communication costs. Terminal devices autonomously select nearby MEC devices to establish regional neighbor topology relationships based on their distance from MEC devices, and then complete a connection (information authentication) with these neighbors. If a MEC device cannot handle the current task or experiences task waiting, requiring task migration, nearby neighbors proactively take on part of the task, and so on. Multiple MEC devices form a directed acyclic graph, reducing latency for task upload to the cloud center and task unloading from the cloud center.
[0102] S3 Resource Allocation Process: The main focus of the resource allocation problem is the rationality of resource allocation. Based on the characteristics of heuristic algorithms and the feature of particle swarm optimization (PSO) in finding and updating optimal values through dispersion, all idle MECs are randomly initialized as particles to find the optimal value. The positions of the group of particles are updated in real time, and the position of each particle is also updated. This accelerates the convergence speed of mainstream SSA algorithms. Compared with other optimal algorithms, the SSA algorithm has high exploratory power and avoids local optima.
[0103] refer to Figure 4 The task uninstallation process mainly includes the following:
[0104] S2-1: The terminal device sends an uninstallation task request;
[0105] S2-2: The nearest regional MEC node receives the unload task request;
[0106] S2-3: The task is horizontally published to the neighboring MEC nodes in the region. After distributed task evaluation, the neighboring MEC nodes share the task parameters with each other.
[0107] S2-4: Evaluate whether the current task set needs task migration, for example, task set The terminal device uploads its nearest MEC node. The MEC node calculates the parameters and determines whether it can be unloaded. Excess tasks unload neighboring MEC nodes in the region to complement each other. S2-3 are repeated according to the task volume until there are no more migration tasks.
[0108] S2-5: Establish a distributed resource allocation model that satisfies the balance between minimizing energy consumption and QoS satisfaction using an adaptive function (energy consumption weight coefficient). and time consumption weighting coefficient ):
[0109] ;
[0110] The SSA algorithm is used to find the optimal value for all MEC devices, and the individual optimal values are shared among them to output the optimal combination of offloading strategies.
[0111] S2-6: Dynamic policy management. After each MEC node completes its task, it actively requests a new task if the communication cost threshold and latency requirements are met. This policy is deployed on the MEC nodes and mainly performs real-time status scanning, migration evaluation, and migration decisions on the tasks in the current queue to ensure that the execution of tasks with different priorities achieves a trade-off between energy consumption and latency.
[0112] S2-7: According to the unloading strategy, qualified MEC devices automatically receive and execute tasks;
[0113] S2-8: Upload results.
[0114] refer to Figure 5 The resource allocation process mainly includes the following:
[0115] S3-1: Encode the idle MEC devices and mark them as population particles for initialization;
[0116] S3-2: A single MEC node initializes a subpopulation and sets algorithm parameters. The initial subpopulation consists of a population of *Triticum aestivum* with a size of n, a number of MEC devices of m, and a dimension of D, denoted as […]. ,in The third particle in the MEC device with code 2;
[0117] S3-3: Initialize each The leader's position. Calculate the fitness values of N salps (i.e., child individuals or MEC child individuals), that is, calculate the value of the adaptive fitness function; then, sort all i×j salps in descending order of fitness value (i.e., sort from largest to smallest), and update the position of the salps with the best fitness at the top of the list to the latest food position of the node group;
[0118] Position update: There are N-1 salps remaining in the group. Sort them in descending order according to the fitness value of the salps group. The top N / 2 salps are regarded as leaders, and the remaining N / 2 salps are regarded as followers.
[0119] S3-4: Each individual MEC device Prioritize updating the latest leader of your own subpopulation. and followers ;
[0120] S3-5: Leader of a single MEC device subpopulation and followers Each with the leader of the MEC device population and followers In comparison, if If it's better, then update. for ;if If it's better, then update. for ,vice versa
[0121] S3-6: Calculate fitness. Calculate the fitness value of the updated MEC device population. Compare the updated fitness value of each salps with the fitness value of the current food. If the updated salps have a better fitness value than the food, then the location of the salps with the better fitness value is taken as the new food location.
[0122] S3-7: Repeat S3-3 to S3-6 until the set number of iterations is reached or the fitness value meets certain requirements. After the termination condition is met, output the current food position as the estimated position of the target.
[0123] S3-8: End.
[0124] The decentralized service request distribution method based on edge computing proposed in this invention eliminates the need for tasks to be unloaded from the cloud center node to edge devices. Instead, local edge devices accept task requests, employ distributed computing strategies, and autonomously allocate resources. Simultaneously, nearby MEC nodes become stage centers, reducing communication nodes and saving latency in uploading terminal tasks to the cloud center and unloading tasks from the cloud center. Horizontal distributed task unloading also improves task unloading efficiency. By making decisions based on different device attributes and task priority differences, energy consumption and latency weight coefficients are generated in the scheduling target resource allocation, improving service quality (QoS) and resource allocation efficiency. Furthermore, an optimized resource allocation algorithm, SSA, is proposed. Leveraging the low latency and high bandwidth characteristics of MEC devices and their rapid information exchange, all idle MEC devices are treated as a population for the SSA algorithm. Each particle in the population can represent the population itself, and individual MEC devices can reinitialize sub-populations, forming a two-layer heuristic computing mode. This not only improves the convergence and speed of the SSA algorithm but also makes reasonable use of idle MEC resources.
[0125] The resource scheduling device provided by the present invention is described below. The resource scheduling device described below and the resource scheduling method described above can be referred to in correspondence.
[0126] refer to Figure 6 The resource scheduling device provided by the present invention includes a request response module 601, a receiving module 602 and a scheduling module 603.
[0127] The request response module 601 is used to respond to the task unloading request sent by the terminal device and publish the task to be unloaded carried in the task unloading request to the nearby MEC device.
[0128] The receiving module 602 is used to receive the evaluation result of the task to be unloaded sent by the nearby MEC device; the evaluation result is used to characterize whether the nearby MEC device has the ability to process the task to be unloaded.
[0129] The scheduling module 603 is used to determine at least one target MEC device based on the energy consumption information and latency information of the MEC device when it is determined from the evaluation results that the task to be unloaded needs to be migrated, and to schedule the task to be unloaded to the target MEC device.
[0130] The resource scheduling device provided in this invention, in response to a task offloading request sent by a terminal device, publishes the task to be offloaded carried in the task offloading request to a nearby MEC device; receives the evaluation result of the task to be offloaded sent by the nearby MEC device; the evaluation result is used to characterize whether the nearby MEC device has the ability to process the task to be offloaded; if it is determined based on the evaluation result that the task to be offloaded needs to be migrated, at least one target MEC device is determined according to the energy consumption information and latency information of the MEC device, and the task to be offloaded is scheduled to the target MEC device. In this invention, tasks do not need to be offloaded from the cloud central node to the edge device; instead, the local edge device accepts the task request, uses a distributed computing strategy, and autonomously completes resource allocation, achieving decentralized resource scheduling.
[0131] In one embodiment, the energy consumption information includes an energy consumption weighting coefficient and the energy consumed by the MEC device to process the task to be unloaded; the latency information includes a time consumption weighting coefficient and the total time required for the MEC device to process the task to be unloaded; the scheduling module 603 is specifically used for:
[0132] An adaptive function is determined based on the energy consumption weight coefficient, the energy consumed by the MEC device in processing the offloaded task, the time consumption weight coefficient, and the total time required by the MEC device in processing the offloaded task. The adaptive function satisfies a balance between minimizing energy consumption and QoS satisfaction. Based on the adaptive function, the MEC devices are searched to determine the optimal combined offload strategy. Based on the optimal combined offload strategy, at least one target MEC device is determined.
[0133] In one embodiment, the scheduling module 603 is specifically used for:
[0134] Idle MEC devices are encoded and marked as population particles for initialization to obtain a MEC device population. A subpopulation is initialized for each idle MEC device to obtain a subpopulation. The positions of the leader and followers in the subpopulation are updated according to the adaptive function. The food source positions of the subpopulation are updated according to the fitness value of each individual in the updated subpopulation; the food source positions represent the optimal solution. The food source positions of the MEC device population are updated according to the comparison results between the subpopulation and the MEC device population. The search operation of the MEC devices is iterated according to the fitness value of each individual in the updated MEC device population, and the optimal combination unloading strategy is output.
[0135] In one embodiment, the scheduling module 603 is specifically used for:
[0136] According to the adaptiveness function, calculate the first fitness value of each individual in the subpopulation; sort the first fitness values in descending order to obtain a sorting sequence; designate at least one individual ranked first in the sorting sequence as the leader of the subpopulation, and designate the remaining individuals in the sorting sequence as the followers of the subpopulation.
[0137] In one embodiment, updating the food source location of the MEC device population includes updating the positions of the leader and followers in the MEC device population; the scheduling module 603 is specifically used for:
[0138] The comparison results of the leader's position and the follower's position between the subpopulation and the MEC device population are determined; the comparison results of the food source positions include the comparison results of the leader's position and the follower's position; if the comparison result of the leader's position is that the position of the leader of the subpopulation is better than the position of the leader of the MEC device population, then the position of the leader of the MEC device population is updated to the position of the leader of the subpopulation; if the comparison result of the follower's position is that the position of the follower of the subpopulation is better than the position of the follower of the MEC device population, then the position of the follower of the MEC device population is updated to the position of the follower of the subpopulation.
[0139] In one embodiment, the energy consumption weighting coefficient and time consumption weighting coefficient of the MEC device are determined based on the terminal attribute document of the MEC device; the terminal attribute document is established in the following manner:
[0140] Obtain the basic device information of the MEC device; the basic device information includes at least one of energy consumption sensitive information, basic power, computing power, storage capacity and latency sensitive information; and establish the terminal attribute document based on the basic device information.
[0141] Figure 7 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 7 As shown, the electronic device may include: a processor 710, a communications interface 720, a memory 730, and a communication bus 740, wherein the processor 710, the communications interface 720, and the memory 730 communicate with each other through the communication bus 740. The processor 710 can call logical instructions in the memory 730 to execute a resource scheduling method, which includes: responding to a task offloading request sent by a terminal device, publishing the task to be offloaded carried in the task offloading request to a nearby MEC device; receiving an evaluation result of the task to be offloaded sent by the nearby MEC device; the evaluation result being used to characterize whether the nearby MEC device has the ability to process the task to be offloaded; if it is determined based on the evaluation result that the task to be offloaded needs to be migrated, determining at least one target MEC device according to the energy consumption information and latency information of the MEC device, and scheduling the task to be offloaded to the target MEC device.
[0142] Furthermore, the logical instructions in the aforementioned memory 730 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, essentially, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0143] On the other hand, the present invention also provides a computer program product, the computer program product including a computer program, which can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the resource scheduling method provided by the above methods. The method includes: responding to a task offloading request sent by a terminal device, publishing the task to be offloaded carried in the task offloading request to a nearby MEC device; receiving an evaluation result of the task to be offloaded sent by the nearby MEC device; the evaluation result is used to characterize whether the nearby MEC device has the ability to process the task to be offloaded; if it is determined based on the evaluation result that the task to be offloaded needs to be migrated, determining at least one target MEC device according to the energy consumption information and latency information of the MEC device, and scheduling the task to be offloaded to the target MEC device.
[0144] In another aspect, the present invention also provides a non-transitory computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the resource scheduling method provided by the above methods. The method includes: responding to a task offloading request sent by a terminal device, publishing the task to be offloaded carried in the task offloading request to a nearby MEC device; receiving an evaluation result of the task to be offloaded sent by the nearby MEC device; the evaluation result being used to characterize whether the nearby MEC device has the ability to process the task to be offloaded; and, if it is determined based on the evaluation result that the task to be offloaded needs to be migrated, determining at least one target MEC device according to the energy consumption information and latency information of the MEC device, and scheduling the task to be offloaded to the target MEC device.
[0145] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0146] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0147] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A resource scheduling method, characterized in that, Mobile edge computing (MEC) devices include: In response to a task unloading request sent by a terminal device, the task to be unloaded carried in the task unloading request is published to a nearby MEC device; The evaluation result of the task to be offloaded is sent by the nearby MEC device; the evaluation result is used to characterize whether the nearby MEC device has the ability to process the task to be offloaded; the evaluation result includes at least the evaluation parameters of the nearby MEC device for the task to be offloaded, such as computing load, energy consumption and latency. If, based on the evaluation results, it is determined that the task to be unloaded needs to be migrated, at least one target MEC device is identified according to the energy consumption information and latency information of the MEC device, and the task to be unloaded is scheduled to the target MEC device; the energy consumption information includes an energy consumption weighting coefficient and the energy consumed by the MEC device to process the task to be unloaded; the latency information includes a time consumption weighting coefficient and the total time required by the MEC device to process the task to be unloaded. Based on the energy consumption and latency information of the MEC devices, at least one target MEC device is identified, including: An adaptive function is determined based on the energy consumption weight coefficient, the energy consumed by the MEC device in processing the task to be offloaded, the time consumption weight coefficient, and the total time required by the MEC device in processing the task to be offloaded; the adaptive function satisfies the balance between minimizing energy consumption and QoS satisfaction. Based on the adaptive function, the MEC device is searched to determine the optimal combination of offloading strategies; Based on the optimal combination offloading strategy, at least one of the target MEC devices is identified; The process of searching the MEC device based on the adaptive function to determine the optimal combination of offloading strategies includes: The MEC devices in the idle state are encoded and marked as population particles for initialization to obtain the MEC device population; A subpopulation is initialized for a single MEC device that is in an idle state to obtain a subpopulation; Update the positions of the leader and followers in the subpopulation according to the adaptive function; The food source locations of the subpopulation are updated based on the fitness values of each individual in the subpopulation after the location update; the food source locations represent the optimal solution. The food source locations of the MEC device population are updated based on the comparison results between the subpopulation and the MEC device population. Based on the fitness value of each individual in the MEC device population after the food source location is updated, the search operation of the MEC device is iterated, and the optimal combination unloading strategy is output. The adaptive function is: ; in, This represents the energy consumed by the MEC device to process the offloading tasks, i.e., the MEC node. Processing tasks The energy consumed; Indicates the first One MEC node; Indicates the first One task; Indicates the total number of tasks; This represents the energy consumption weighting coefficient; This represents the total time required for the MEC device to process the unloading task, i.e., the time required for the MEC node to complete the task. Processing tasks Total time spent; This represents the time-consuming weighting coefficient; Assuming each MEC device Processing tasks The energy consumed is and each MEC device Up processing tasks The total time spent is , For MEC devices The energy consumed in performing all tasks. For MEC devices power consumption, Task allocation matrix for the size of the task set The size is Task allocation matrix Each element in is represented as , To carry out the mission Required power The total latency for executing application A on the MEC node. For MEC devices and MEC equipment The transmission distance between them; under the constraints of latency and computational resource limitations, the optimization objective is: Total energy consumption: ; Total latency: 。 2. The resource scheduling method according to claim 1, characterized in that, The step of updating the positions of the leader and followers in the subpopulation according to the adaptive function includes: Calculate the first fitness value of each sub-individual in the subpopulation based on the adaptive fitness function; Sort the first fitness values in descending order to obtain a sorted sequence; The first sub-individual ranked first in the sorting sequence is designated as the leader of the subpopulation, and the remaining sub-individuals in the sorting sequence are designated as the followers of the subpopulation.
3. The resource scheduling method according to claim 1, characterized in that, Updating the food source locations of the MEC device population includes updating the locations of the leaders and followers within the MEC device population; The step of updating the food source location of the MEC device population based on the comparison results of food source locations between the subpopulation and the MEC device population includes: The results of the comparison between the leader's position and the follower's position are determined between the subpopulation and the MEC device population; the comparison results of the food source positions include the results of the comparison between the leader's position and the follower's position. If the comparison result of the leader's position is that the position of the leader of the subpopulation is better than the position of the leader of the MEC device population, then the position of the leader of the MEC device population is updated to the position of the leader of the subpopulation. If the position comparison result of the followers is that the position of the followers of the subpopulation is better than the position of the followers of the MEC device population, then the position of the followers of the MEC device population is updated to the position of the followers of the subpopulation.
4. The resource scheduling method according to claim 1, characterized in that, The energy consumption weighting coefficient and time consumption weighting coefficient of the MEC device are determined based on the terminal attribute document of the MEC device; the terminal attribute document is established in the following way: Obtain the basic device information of the MEC device; the basic device information includes at least one of energy consumption sensitive information, basic power, computing power, storage capacity, and latency sensitive information; Based on the device's basic information, the terminal attribute document is created.
5. A resource scheduling device, characterized in that, include: The request-response module is used to respond to the task unloading request sent by the terminal device and publish the task to be unloaded carried in the task unloading request to the nearby MEC device. A receiving module is configured to receive the evaluation result of the task to be offloaded sent by the nearby MEC device; the evaluation result is used to characterize whether the nearby MEC device has the ability to process the task to be offloaded; the evaluation result includes at least the evaluation parameters of the nearby MEC device for the task to be offloaded, such as computing load, energy consumption and latency. The scheduling module is used to determine at least one target MEC device based on the energy consumption information and latency information of the MEC device when it is determined from the evaluation results that the task to be unloaded needs to be migrated, and to schedule the task to be unloaded to the target MEC device; the energy consumption information includes an energy consumption weighting coefficient and the energy consumed by the MEC device to process the task to be unloaded; the latency information includes a time consumption weighting coefficient and the total time required by the MEC device to process the task to be unloaded. The scheduling module is further configured to determine an adaptive function based on the energy consumption weight coefficient, the energy consumed by the MEC device in processing the task to be offloaded, the time consumption weight coefficient, and the total time required by the MEC device in processing the task to be offloaded; the adaptive function satisfies the balance between minimizing energy consumption and QoS satisfaction. Based on the adaptive function, the MEC device is searched to determine the optimal combination of offloading strategies; Based on the optimal combination offloading strategy, at least one of the target MEC devices is identified; The scheduling module is further configured to encode idle MEC devices and mark them as population particles for initialization to obtain a MEC device population; initialize a subpopulation for a single idle MEC device to obtain a subpopulation; update the positions of the leader and followers in the subpopulation according to the adaptive function; update the food source positions of the subpopulation according to the fitness value of each individual in the subpopulation after position update; the food source positions represent the optimal solution; and update the food source positions of the MEC device population according to the comparison results of the food source positions between the subpopulation and the MEC device population. Based on the fitness value of each individual in the MEC device population after the food source location is updated, the search operation of the MEC device is iterated, and the optimal combination unloading strategy is output. The adaptive function is: ; in, This represents the energy consumed by the MEC device to process the offloading tasks, i.e., the MEC node. Processing tasks The energy consumed; Indicates the first One MEC node; Indicates the first One task; Indicates the total number of tasks; This represents the energy consumption weighting coefficient; This represents the total time required for the MEC device to process the unloading task, i.e., the time required for the MEC node to complete the task. Processing tasks Total time spent; This represents the time-consuming weighting coefficient; Assuming each MEC device Processing tasks The energy consumed is and each MEC device Up processing tasks The total time spent is , For MEC devices The energy consumed in performing all tasks. For MEC devices power consumption, Task allocation matrix for the size of the task set The size is Task allocation matrix Each element in is represented as , To carry out the mission Required power The total latency for executing application A on the MEC node. For MEC devices and MEC equipment The transmission distance between them; under the constraints of latency and computational resource limitations, the optimization objective is: Total energy consumption: ; Total latency: 。 6. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the resource scheduling method as described in any one of claims 1 to 4.
7. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the resource scheduling method as described in any one of claims 1 to 4.
8. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the resource scheduling method as described in any one of claims 1 to 4.
Citation Information
Patent Citations
Mobile user terminal task unloading method under distributed edge computing service system
CN111262906A
Mobile edge computing unloading method and system based on Harris eagle algorithm
CN116932086A