Dual-time-scale joint optimization service caching and calculation unloading method of unmanned aerial vehicle assisted MEC

Through the dual time scale joint optimization method, the service caching strategy is improved and the deep reinforcement learning algorithm is embedded, which solves the energy and storage limitations of service caching and computing offloading in the UAV MEC system, and achieves the effect of reducing system delay and energy consumption. .

CN118612797APending Publication Date: 2024-09-06SHENYANG AEROSPACE UNIVERSITY
View PDF 0 Cites 7 Cited by

Patent Information

Application Number
CN202410736472.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-07
Publication Date
2024-09-06

AI Technical Summary

Technical Problem

Collaborative service caching and computation offloading in UAV-assisted MEC systems face energy and storage capacity constraints, resulting in frequent service cache updates that increase latency and energy consumption, and reduce computing performance.

Method used

A dual time scale joint optimization method is adopted to improve the service caching strategy through the greedy dual size frequency algorithm and embed it into the dual delay depth deterministic policy gradient algorithm to construct a dual time scale TD3 scheme to optimize service caching and computational offloading decisions and resources. Distribution ratio.

Benefits of technology

Under the energy constraints of drones and ground equipment, the total time delay of the system is significantly reduced, computing performance is improved, and the delay and energy consumption of the wireless backhaul link are reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118612797A
    Figure CN118612797A
Patent Text Reader

Abstract

The invention discloses a dual-time-scale joint optimization service caching and calculation unloading method for an unmanned aerial vehicle assisted MEC. The method comprises the following steps: S1, constructing a system model, a communication model, a caching model, a calculation unloading model and an energy consumption model; s2, taking the minimization of the total time delay of the multi-unmanned aerial vehicle assisted mobile edge computing system as an optimization target, and constructing an optimization problem model; s3, updating the service cache according to a service cache strategy improved by a greedy dual-size frequency algorithm; s4, constructing the optimization problem as a Markov decision process; s5, embedding a service caching strategy improved based on a greedy double-size frequency algorithm into a TD3 algorithm, and constructing a double-time-scale TD3 (DTTD3) scheme; and solving an unloading decision and a resource allocation proportion by using the optimization target. According to the method, the service cache is jointly optimized on different time scales, the unloading and resource allocation proportion is calculated, the service cache is updated on a large time scale, the time delay problem caused by updating of the service cache is effectively reduced, and the energy consumption of the unmanned aerial vehicle is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of emerging information technology, and in particular to a dual-time-scale joint optimization service caching and computation offloading method for unmanned aerial vehicle-assisted MEC. Background Art

[0002] Mobile edge computing (MEC) is one of the core technologies of 5G networks. It extends storage and computing resources to the edge of the network by deploying edge servers closer to IoT devices, thereby reducing service latency and energy consumption and network congestion. However, the infrastructure costs associated with deploying edge servers are huge, which makes it very challenging to provide mobile edge computing services to remote areas or disaster-stricken areas that lack sufficient infrastructure. Drones are widely used in the field of mobile edge computing due to their mobility, flexibility and low cost.

[0003] In recent years, some researchers have begun to jointly optimize communication, computing, and caching resources in MEC systems. The input data, output data, and programs that the computing tasks rely on can be reused by multiple users, so they can be pre-stored in the edge server to save communication and computing resources in the MEC network. Existing work mainly focuses on two paradigms, namely content caching and service caching. Content caching refers to caching the input or output data of a task; service caching refers to caching the programs or databases used to perform tasks. At present, existing work has demonstrated the advantages of jointly optimizing computing offloading and content caching in drone-assisted MEC systems, but the real-world situation is that the input data or output results of applications rarely coincide precisely, which reduces the possibility of frequent reuse. In addition, compared with edge servers deployed on the ground, drones are usually powered by onboard energy and can only be equipped with small edge servers, which cannot cache too much task data. Therefore, it is necessary and meaningful to consider computing service caching on drone edge servers to improve computing performance.

[0004] From a practical perspective, there are many challenges in coordinating service caching and computation offloading in drone-assisted MEC systems. Drones have limited energy and storage capacity, and the wireless backhaul link between the base station and the drone may be limited compared to the limited backhaul link. Frequent service cache updates may bring unnecessary delays and increase energy consumption, or even make the cache meaningless. Summary of the invention

[0005] In view of this, the present invention discloses a dual-time-scale joint optimization service caching and computation offloading method for UAV-assisted MEC, so as to meet the dynamic needs of users while minimizing the total time delay of the system under the energy constraints of UAVs and ground equipment.

[0006] The technical solution provided by the present invention is specifically a dual-time-scale joint optimization service caching and computation offloading method of drone-assisted MEC, including:

[0007] S1: Based on wireless transmission and mobile edge computing, build system model, communication model, cache model, computing offloading model and energy consumption model;

[0008] S2: Under the energy constraints of UAVs and ground equipment, the optimization problem model is constructed with the minimization of the total delay of the multi-UAV assisted mobile edge computing system as the optimization goal;

[0009] S3: updating the service cache according to the service caching policy (SCP) improved based on the greedy dual size frequency algorithm (GDSF);

[0010] S4: Based on the updated UAV cache status, the optimization problem is constructed as a Markov decision process (MDP);

[0011] S5: Embed the improved service caching strategy based on the greedy dual-size frequency algorithm into the twin delayed deep deterministic policy gradient (TD3: twin delayed deep deterministic policy gradient) algorithm to construct a dual time scale TD3 (DTTD3: Dual Timescale TD3) solution; then use the optimization objective to solve the unloading decision and resource allocation ratio.

[0012] Preferably, the system model in S1 includes a ground base station, U drones and M ground equipment, and the drones and ground equipment are respectively represented as and The ground equipment is not within the service coverage of the ground base station, and the ground equipment is served by the drone equipped with a small edge server; the drone's flight altitude is fixed as H, and it is equipped with a directional antenna with a fixed beam width of θ. The service range of the drone is represented by Htanθ;

[0013] The system model sets the total duration to be divided into T service time slots. In each service time slot t, the device position remains unchanged and a computing task is generated. Each task calculation needs to rely on a specific program, generating a total of K different types of computing tasks. Represents the set of programs required to complete all tasks; choose to calculate the task locally or offload it based on the size and type of the computing task, the program cached by the drone, and the power;

[0014] The communication model assumes that the wireless communication between the device and the drone is mainly dominated by the LoS (Line of Sight) link, and the distance between the device m and the drone u is expressed as d m,u , the uplink data rate is represented by R m,u express;

[0015] The cache model: Due to the high communication delay between the base station and the drone, the service cache is updated every T′ time slot, using the binary variable c k,u =0,1 to indicate whether program k is cached on the drone; c k,u =1 means program k is cached on the drone, c k,u = 0 means that program k is not cached on the drone; the cache capacity required by program k is l k express;

[0016] The computing offloading model: unloading is performed in binary mode, that is, all tasks are calculated locally or all offloaded to drones or base stations for computing; using a m,u (k) = 0, 1 to indicate whether the device task in time slot t needs to be unloaded, a m,u (k) = 1 means to offload the task, otherwise it is calculated locally; the offloading location of the task is express;

[0017] The energy consumption model: The energy consumption of ground equipment consists of two parts: calculating energy consumption and the energy consumption of transmitting the uploaded data of the computing task to the drone The energy consumption of drones consists of two parts: computing energy consumption and the energy consumption of transmitting the uploaded data of the computing task to the base station

[0018] The energy consumption of ground equipment is expressed as

[0019] The energy consumption of the drone is expressed as

[0020] Preferably, the total delay of the multi-UAV assisted mobile edge computing system is:

[0021] If calculated locally, the total system delay is the local calculation time of the device.

[0022] If the task is offloaded to the drone, the delay from the task offload to the drone is the transmission time of the task from the device to the drone. Computational latency with drones The task is offloaded to the base station for calculation. Considering the powerful computing power of the base station, it is believed that the task execution time is approximately 0, so the delay of offloading the task to the base station is approximately equal to the transmission time of the task from the drone to the base station. The delay of task offloading is

[0023] Therefore, the total delay of the system is

[0024] The optimization problem model is expressed as:

[0025] The restrictions are as follows: C1:

[0026] C2:

[0027] C3:

[0028] C4:

[0029] C5:

[0030] C6:

[0031] C7:

[0032] C8:

[0033] C9:

[0034] Among them, C1 and C2 represent service cache and computation offloading decisions as binary variables; C3 represents resource allocation ratio as a continuous variable, s m,u It indicates the ratio of task computing resources allocated by UAV u to device m; C4 and C5 ensure that the energy consumption of ground equipment and UAVs does not exceed their energy budget; C6 indicates that the tasks generated by each device can only be executed in one place; C7 indicates that the computing resources allocated by UAVs to devices cannot exceed the computing power of each UAV; C8 ensures that the total capacity of the UAV cache program is within its cache capacity; C9 limits the users served by the UAV to be within its service scope.

[0035] Preferably, the service cache strategy improved based on the greedy dual-size frequency algorithm:

[0036] The access frequency of the data item is calculated based on the number of requests n by the program in the past T′ time slots; the size of the data item is the size of each program;

[0037] Calculate the popularity coefficient of each task according to the Zipf distribution:

[0038]

[0039] Where W represents the frequency of each task generation, S represents the parameter of the zipf distribution, and C is a normalization constant to ensure that the sum of the probabilities is 1;

[0040] The evaluation score of each program is calculated using the following evaluation function:

[0041]

[0042] Among them, l k is the size of the program, p and n are the task popularity and the access frequency of the program, respectively, and β and γ are adjustment factors used to balance the task popularity and access frequency;

[0043] Update service cache based on the improved service cache strategy of greedy dual-size frequency algorithm:

[0044] Calculate the evaluation score of each program in each T′ time slot, and sort each program from high to low according to the evaluation score; wherein multiple programs with the same score are sorted from small to large according to program size;

[0045] Select the top K′ programs according to the sorting results and cache them in the next T′ time slots;

[0046] If the total size of the selected 1′ programs exceeds the total cache capacity of the drone, they are replaced in sequence from the K′+1th program to the last program until the total size of the programs is lower than the upper limit of the drone cache capacity.

[0047] 5. The dual-time-scale joint optimization service cache and computation offloading method for UAV-assisted MEC according to claim 1 is characterized in that the Markov decision process is represented by a multi-tuple *S, A, R, P, γ+, which are state space, action space, reward function, state transition probability and reward discount factor respectively;

[0048] The state space is used to represent the environment and is set as:

[0049] in, represents the position of the UAV at time slot t, A program representing the drone cache, Indicates the remaining battery capacity of the drone. represents the location of the ground equipment in time slot t, represents the task size generated by the ground equipment, Indicates the task type generated by the ground equipment;

[0050] The action space consists of the ground equipment ID being served, the computation offloading decision and the resource allocation ratio; the action space is set as: Where x(t) is the ID of the ground equipment being served, For uninstallation decision, Allocate proportions for resources;

[0051] The reward function is defined as the negative of the total system delay: R t =-T m .

[0052] Preferably, the service cache strategy improved based on the greedy dual-size frequency algorithm is embedded into the TD3 algorithm to construct a dual time scale TD3 (DTTD3) scheme, and solve the offloading decision and resource allocation ratio according to the optimization goal, including:

[0053] Construct and initialize the TD3 network: The TD3 network includes an actor current network, an actor target network, two critic current networks, and two critic target networks. The system state is input into the actor current network of the TD3 network. The actor current network makes action decisions according to the strategy function π and enters the noise Expand the exploration capability of the action and finally obtain the action a of time slot t t , the formula is:

[0054]

[0055] According to the action execution task calculation in time slot t, the system state s of the next time slot t+1 is obtained t+1 , and calculate the reward r of time slot t; the sample (s t ,a t ,r,s t+1 ) is saved in the experience pool. If the samples in the sample experience pool do not reach the experience pool capacity, the system state of the next time slot is input into the actor's current network to generate the action of the next time slot. This step is repeated until the sample experience pool is full.

[0056] If the experience pool is full, N samples are extracted from the experience pool to train the TD3 network and update the TD3 network parameters;

[0057] Randomly extract N samples and set the next time slot state s t+1 Input the actor-target network and add random noise ∈ to improve the robustness of the action strategy to obtain the actor-target network action The actions of the actor-target network are:

[0058]

[0059] The state-action pair of the next time slot is input into the two critic target networks to obtain the target state-action value Q′1(s t+1 ,π′(s t+1 )), target state action value Q′2(s) of critic target network 2 t+1 ,π′( s t +1 )), and finally the smaller value of the two critic target network state action values ​​is used to calculate the actual gain of the critic target network, the formula is: y = r + γmin (Q ′1 (s t+1 ,π′(s t+1 )),Q′2(s t+1 ,π′(s t+1 )) / ;

[0060] Using the mean square error function, the critic's current network parameters are updated through the gradient back propagation of the neural network:

[0061]

[0062] Determine whether the critic's current network parameter update reaches the set number of times d. If so, the actor's current network parameters are updated through the loss gradient:

[0063]

[0064] Use soft update to update the actor target network parameters and the critic target network parameters:

[0065]

[0066] θ π′ =τθ π +(1-τ)θ π′ .

[0067] The dual-time-scale joint optimization service cache and computation offloading method for UAV-assisted MEC provided by the present invention focuses on optimizing computation service cache, offloading decision and resource allocation ratio at different time scales. A service cache strategy (SCP) improved by the greedy dual-size frequency (GDSF) algorithm is proposed in the method. In a longer time interval, the service cache is updated according to the task popularity, task access frequency and the program size required for task execution. The service cache strategy is embedded in the dual-delay deep deterministic policy gradient (TD3) algorithm, and a dual-time-scale TD3 (DTTD3) scheme is proposed. Based on the service cache decision and the environment state, the offloading decision and resource allocation ratio are optimized at a smaller time scale.

[0068] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0069] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

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

[0071] Figure 1 A schematic diagram of an application scenario of a dual-time-scale joint optimization service cache and computation offloading method for UAV-assisted MEC provided in an embodiment disclosed in the present invention;

[0072] Figure 2 A DTTD3 structure diagram provided for an embodiment of the present invention;

[0073] Figure 3 The task execution delay of different DRL schemes provided by the embodiments disclosed in the present invention;

[0074] Figure 4 The task execution delay of different cache strategies provided by the embodiments disclosed in the present invention;

[0075] Figure 5 The task execution delay of different UAV cache capacities provided by the disclosed embodiment of the present invention;

[0076] Figure 6 The task execution delay of different drone computing capabilities provided by the embodiments disclosed in the present invention. DETAILED DESCRIPTION

[0077] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present invention. Instead, they are merely examples of systems consistent with some aspects of the present invention as detailed in the appended claims.

[0078] Existing research works use traditional optimization algorithms to solve the joint optimization problems of communication, caching and offloading in mobile edge computing. However, the solutions of these algorithms usually require complex iterative optimization and cannot adapt to changes in the environment. Reinforcement learning is an important branch of machine learning. Its main goal is to train intelligent agents to make decisions in an environment to optimize performance. The fusion of reinforcement learning and deep learning has produced deep reinforcement learning, which is considered to be an effective strategy for achieving asymptotic optimal solutions in dynamic environments.

[0079] The present invention proposes a collaborative optimization method for service caching, computation offloading and resource allocation at different time scales in a multi-UAV assisted mobile edge computing system based on deep reinforcement learning. Among them, the traditional base station is at a certain distance from the ground infrastructure, and the edge server embedded in the UAV performs key tasks such as relaying, caching and computing services for ground users. In view of the limitations of ground equipment and UAV battery capacity, the present invention jointly optimizes service caching, computation offloading and resource allocation ratios at different time scales, with the overall goal of reducing system service latency. When the UAV caches the programs required for the task, this difference in time scale reduces the wireless backhaul time and energy consumption. Figure 1 This is the application scenario of the present invention.

[0080] The dual-time-scale joint optimization service caching and computation offloading method for UAV-assisted MEC includes:

[0081] S1: Based on wireless transmission and mobile edge computing, build system model, communication model, cache model, computing offloading model and energy consumption model;

[0082] Specifically, it includes the following: System model, a multi-UAV assisted mobile edge computing system is proposed, which consists of a ground base station, U UAVs and M ground devices. The UAVs and ground devices are represented as and The ground equipment is not within the service coverage of the base station. The drone is equipped with a small edge server to provide services for the ground equipment. The drone's flight altitude is fixed as H, and it is equipped with a directional antenna with a fixed beam width of θ. The service range of the drone is represented as Htanθ. The total duration is divided into T service time slots. In each service time slot t, the device position remains unchanged and a computing task is generated. Each task calculation requires a specific program, generating a total of K different types of computing tasks. Represents the set of programs required to complete all tasks; choose to calculate the task locally on the device or offload the task based on the size and type of the computing task, the program cached by the drone, and the power.

[0083] Communication model: Considering the flight altitude of the drone, the wireless communication between the device and the drone is assumed to be dominated by the LoS link. The distance between the device m and the drone u is represented by d m,u , the uplink data rate is represented by R m,u express.

[0084] Cache model: To reduce computational latency, consider caching the programs required for task computation in the UAV. Due to the high communication latency between the base station and the UAV, the service cache is updated every T′ time slot. Using the binary variable c k,u =*0,1+ to indicate whether program k is cached on the drone. k,u =1 means program k is cached on the drone, c k,u = 0 means that program k is not cached on the drone. The cache capacity required by program k is l k express.

[0085] Computation offloading model: In each time slot, the ground equipment will generate computing tasks, and whether the tasks are offloaded is determined based on the current system status. The offloading is performed in a binary manner, that is, all tasks are calculated locally or all are offloaded to the drone or base station for calculation. We use a m,u (k) = *0,1+ to indicate whether the device task in time slot t needs to be unloaded, a m,u (k) = 1 means to offload the task, otherwise it is calculated locally; the offloading location of the task is express;

[0086] Energy consumption model: The energy consumption of ground equipment consists of two parts: calculating energy consumption and the energy consumption of transmitting the uploaded data of the computing task to the drone The energy consumption of drones consists of two parts: computing energy consumption and the energy consumption of transmitting the uploaded data of the computing task to the base station

[0087] The energy consumption of ground equipment is expressed as

[0088] The energy consumption of the drone is expressed as

[0089] S2: Under the energy constraints of UAVs and ground equipment, the optimization problem model is constructed with the minimization of the total delay of the multi-UAV assisted mobile edge computing system as the optimization goal;

[0090] If calculated locally, the total system delay is the local calculation time of the device.

[0091] If the task is offloaded to the drone, the delay from the task offload to the drone is the transmission time from the device to the drone. Computational latency with drones The task is offloaded to the base station for calculation. Considering the powerful computing power of the base station, it is believed that the task execution time is approximately 0, so the delay of offloading the task to the base station is approximately equal to the transmission time from the drone to the base station. The delay of task offloading is

[0092] Therefore, the total delay of the system is

[0093] The optimization goal is to minimize the total system delay under the energy constraints of the UAV and ground equipment. The optimization problem is expressed as:

[0094] The restrictions are as follows: C1:

[0095] C2:

[0096] C3:

[0097] C4:

[0098] C5:

[0099] C6:

[0100] C7:

[0101] C8:

[0102] C9:

[0103] Constraints C1 and C2 indicate that service cache and computation offloading decisions are binary variables. C3 indicates that the resource allocation ratio is a continuous variable. m,u Indicates the ratio of task computing resources allocated by drone u to device m. C4 and C5 ensure that the energy consumption of ground equipment and drones does not exceed their energy budget. C6 indicates that the tasks generated by each device can only be executed in one place. C7 indicates that the computing resources allocated by drones to devices cannot exceed the computing power of each drone. C8 ensures that the total capacity of the drone cache program is within its cache capacity. C9 limits the users served by the drone to be within its service scope.

[0104] S3: Update the service cache according to the improved service cache strategy (SCP) based on the greedy dual-size frequency (GDSF) algorithm;

[0105] For the service cache update problem, the present invention proposes an improved service cache strategy based on the principle of greedy double-size frequency algorithm.

[0106] GDSF is a cache management algorithm that aims to optimize cache performance by making service cache update decisions based on the size and access frequency of data items, thereby improving the hit rate and reducing the waste of cache space. In our service cache strategy, the access frequency of a data item is calculated based on the number of program requests n in the past T′ time slots; the size of a data item is the size of each program.

[0107] In addition, we considered the popularity of tasks and calculated the popularity coefficient of each task according to the Zipf distribution:

[0108]

[0109] Where W represents the frequency of each task generation. S represents the parameter of the zipf distribution, which is usually a positive real number. C is a normalization constant that ensures that the sum of the probabilities is 1.

[0110] Taking into account the popularity of the task, the size of the program and the access frequency, an evaluation function is used to calculate the evaluation score of each program:

[0111]

[0112] Among them, l k is the size of the program, p and n are the task popularity and the access frequency of the program, respectively, and β and γ are adjustment factors used to balance task popularity and access frequency.

[0113] The present invention establishes a threshold K′ for the service cache, sorts all programs according to the evaluation score, and then updates the service cache according to the score sequence and the program size. Specifically, the evaluation score of each program in each T′ time slot is calculated, and each program is sorted from high to low according to the evaluation score. If multiple programs have the same score, they are sorted from small to large according to the program size. The top K′ programs are selected according to the sorting results, and they are cached in the next T′ time slots. If the total size of the selected K′ programs exceeds the total cache capacity of the drone, they are replaced in sequence from the K′+1th program to the last program in the sequence until the total program size is lower than the upper limit of the drone cache capacity.

[0114] S4: According to the updated UAV cache status, the optimization problem is constructed as a Markov decision process (MDP) based on the goal of minimizing the total system delay;

[0115] The Markov decision process can be represented by a multi-tuple *S, A, R, P, γ+, which represent the state space, action space, reward function, state transition probability and reward discount factor respectively.

[0116] State Space: The environment is represented by a state space, which is set as:

[0117] in, represents the position of the UAV at time slot t, A program representing the drone cache, Indicates the remaining battery capacity of the drone. represents the location of the ground equipment in time slot t, represents the task size generated by the ground equipment, Indicates the task type generated by the ground equipment. The present invention uses the interval between the highest value and the lowest value of the state as a scaling variable and utilizes the state normalization method to minimize the magnitude difference between different states.

[0118] Action space: The action space consists of the ground device ID being served, the computation offloading decision, and the resource allocation ratio. In each time slot t, the drone can provide services to all ground devices within its range, but can only serve one device at a time. The agent chooses whether to offload tasks from ground devices or perform these tasks locally on the device based on the system state. Tasks are uploaded to the drone for execution, and the drone needs to allocate a certain proportion of computing resources for calculation. Therefore, the action space is set as: Where x(t) is the ID of the ground equipment being served, For uninstallation decision, Allocate a ratio for resources.

[0119] Reward function: The agent selects actions and continuously updates the strategy to maximize the reward by calculating the expected reward. The optimization goal of the present invention is to minimize the total delay of the system, which is the opposite of maximizing the cumulative discounted reward in reinforcement learning. Therefore, the reward function is defined as the negative value of the total delay of the system: R t =-T m .

[0120] S5: embed the service cache strategy improved based on the greedy dual-size frequency algorithm into the TD3 algorithm to construct a dual-time scale TD3 (DTTD3) solution; and then use the optimization goal to solve the offloading decision and resource allocation ratio. Figure 2 This is the structural diagram of DTTD3.

[0121] The service cache strategy is embedded into the dual-delay deep deterministic policy gradient (TD3) algorithm, and a dual-time scale TD3 (DTTD3) scheme is proposed to solve the offloading decision and resource allocation ratio based on the optimization objective. The specific steps are as follows:

[0122] Construct and initialize the TD3 network. The TD3 network consists of an actor current network, an actor target network, two critic current networks, and two critic target networks. Input the system state into the actor current network of the TD3 network. The actor current network makes action decisions according to the policy function π and enters the noise Expand the exploration capability of the action and finally obtain the action a of time slot t t , the formula is:

[0123]

[0124] According to the action execution task calculation in time slot t, the system state s of the next time slot t+1 is obtained t+1 , and calculate the reward r of time slot t; the sample (s t ,a t ,r,s t+1 ) is saved in the experience pool. If the samples in the sample experience pool do not reach the experience pool capacity, the system state of the next time slot is input into the actor's current network to generate the action of the next time slot. This step is repeated until the sample experience pool is full.

[0125] If the experience pool is full, N samples are extracted from the experience pool to train the TD3 network and update the TD3 network parameters.

[0126] Randomly extract N samples and set the next time slot state s t+1 Input the actor-target network and add random noise ∈ to improve the robustness of the action strategy to obtain the actor-target network action The actions of the actor-target network are:

[0127]

[0128] The state-action pair of the next time slot is input into the two critic target networks to obtain the target state-action value Q′1(s t+1 ,π′(s t+1 )), target state action value Q′2(s) of critic target network 2 t+1 ,π′(s t+1 )), and finally the smaller value of the two critic target network state action values ​​is used to calculate the actual gain of the critic target network, the formula is: y = r + γmin (Q ′1 (s t+1 ,π′(s t+1 )),Q′2(s t+1,π′(s t+1 )) /

[0129] Using the mean square error function, the critic's current network parameters are updated through the gradient back propagation of the neural network:

[0130]

[0131] Determine whether the critic's current network parameter update reaches the set number of times d. If so, the actor's current network parameters are updated through the loss gradient:

[0132]

[0133] Use soft update to update the actor target network parameters and critic target network parameters. Soft update means that each time the target network parameters only change by a minimum value on the original basis, and increase the target network parameters. The value of τ is very small, usually 0.01, and the formula for soft update is:

[0134]

[0135] θ π′ =τθ π +(1-τ)θ π′

[0136] This implementation scheme simulates the proposed service cache and computation offloading scheme based on deep reinforcement learning on Pycharm and compares it with other benchmark schemes. The experiment is set up in an area of ​​200m*200m, with 30 ground devices randomly distributed and 3 drones randomly hovering at a height of 100m to provide cache and computing services for the devices. In each time slot t, the ground device generates a computing task with an input data size of [0.1, 0.2] Mbits, and the execution of each task requires a specific program. The area contains 10 different types of computing tasks, and the program on which each task depends requires a cache capacity of [0.1, 0.2] Mbits. All drones have the same cache capacity, computing power, and energy budget. Each drone has a cache capacity of 1.0 Mbits and a computing power of 10GHZ.

[0137] Attached Figure 3The experimental simulation results of different deep reinforcement learning schemes are shown, and the performance comparison of DTTD3 and different algorithms in terms of latency applied to the scenario of the present invention is performed. The service caching strategy of the present invention is embedded in the DDPG and AC algorithms to obtain DTDDPG and DTAC. As shown in the figure, DTTD3 and DTDDPG of the present invention are superior to DTAC in terms of system latency. This is due to the one-step update strategy of AC and the lack of an experience replay pool, which leads to a slow convergence speed. In contrast, the DDPG-based method improves the effectiveness of DNN learning by using an experience replay pool and a dual network topology. Compared with DDPG, TD3 uses technologies such as dual networks and delayed updates to achieve faster convergence speed and higher performance. Therefore, DTTD3 of the present invention is superior to DTDDPG and DTAC in terms of convergence and system latency.

[0138] Attached Figure 4 The total delay of computing tasks under different cache strategies when the cache capacity is 1.0Mbits is shown. It can be seen that the total system delay of the Local-Only solution is very high, because its computing tasks are all executed locally on the device and do not rely on the drone, and the limited computing power of the device leads to excessive computing delay. The Random-Cache solution randomly updates the cached programs of the drone. The randomly cached programs may not meet the programs required for task calculations, but instead occupy the cache capacity of the drone. The system delay of this solution is significantly higher than that of the DTTD3 of the present invention. The TD3 solution optimizes the cache and offload decisions on the same time scale, and its delay is lower than that of Random-Cache and Local-Only, but frequent service cache updates may cause unnecessary delays and drone energy consumption. Compared with DTTD3, ​​the total system delay of TD3 is higher. The performance of the DTTD3 of the present invention in system delay is better than that of TD3, Random-Cache and Local-Only solutions. Compared with TD3, Random-Cache and Local-Only solutions, the system delay is reduced by 8.7%, 13.7% and 55.8%, respectively. Therefore, it is meaningful to update service cache and offloading decisions at different time scales.

[0139] Attached Figure 5The performance of DTTD3 is compared with TD3, Random-Cache, and Local-Only schemes in terms of latency for different UAV cache capacities. The total latency of the system decreases as the cache capacity of the UAV increases. This is because when the cache capacity of the UAV is small, the UAV can cache very few programs and the types of tasks that can be calculated are very limited, resulting in a higher total latency of the system. UAVs with larger cache capacities are able to cache more services, allowing the UAV to perform more types of computing tasks, thereby reducing system latency. DTTD3 performs better than TD3, Random-Cache, and Local-Only schemes. The performance difference between DTTD3 and other schemes increases as the cache capacity increases. This is because DTTD3 makes service cache decisions over a longer time frame, and the larger cache capacity also reduces service cache updates, saving the time delay associated with frequent service cache updates.

[0140] Attached Figure 6 The relationship between the computing power and latency of the drone is shown. The computing power of the drone is an important factor affecting the computing latency. As can be seen from the figure, under different computing powers, since DTTD3 makes cache decisions within a larger time scale, thereby reducing the time required for cache updates, the system latency of the DTTD3 scheme is lower than that of TD3, Random-Cache, and Local-Only schemes. In addition, when the computing power of the drone is lower than 14GHZ, the overall system latency under different cache strategies gradually decreases with the increase of computing power. However, when the computing power exceeds 14GHZ, the reduction in latency becomes insignificant. This is mainly because the drone consumes energy in the process of calculating each task, but the energy of the drone is limited. When the computing power reaches a certain threshold (14GHZ), the main factor affecting the drone task offloading is the drone's energy.

[0141] Those skilled in the art will readily appreciate other embodiments of the present invention after considering the specification and practicing the invention disclosed herein. This application is intended to cover any variations, uses or adaptations of the present invention that follow the general principles of the present invention and include common knowledge or customary techniques in the art that are not disclosed by the present invention. The specification and examples are to be considered exemplary only, and the true scope and spirit of the present invention are indicated by the claims.

Claims

1. A dual-time-scale joint optimization service cache and computation offloading method for UAV-assisted MEC, characterized in that: include: S1: Based on wireless transmission and mobile edge computing, build system model, communication model, cache model, computing offloading model and energy consumption model; S2: Under the energy constraints of UAVs and ground equipment, the optimization problem model is constructed with the minimization of the total delay of the multi-UAV assisted mobile edge computing system as the optimization goal; S3: Update the service cache according to the service cache strategy improved based on the greedy dual-size frequency algorithm; S4: Based on the updated UAV cache status, the optimization problem is constructed as a Markov decision process; S5: embed the service cache strategy improved based on the greedy dual-size frequency algorithm into the TD3 algorithm to construct a dual-time scale TD3 solution; and then use the optimization goal to solve the offloading decision and resource allocation ratio.

2. The dual-time-scale joint optimization service cache and computation offloading method for UAV-assisted MEC according to claim 1 is characterized in that: The system model described in S1 includes a ground base station, U drones and M ground equipment. The drones and ground equipment are represented as and The ground equipment is not within the service coverage of the ground base station, and the ground equipment is served by the drone equipped with a small edge server; the drone's flight altitude is fixed as H, and it is equipped with a directional antenna with a fixed beam width of θ. The service range of the drone is represented by Htanθ; The system model sets the total duration to be divided into T service time slots. In each service time slot t, the device position remains unchanged and a computing task is generated. Each task calculation needs to rely on a specific program, generating a total of K different types of computing tasks. Represents the set of programs required to complete all tasks; choose to calculate the task locally or offload it based on the size and type of the computing task, the program cached by the drone, and the power; The communication model assumes that the wireless communication between the device and the drone is mainly dominated by the LoS link, and the distance between the device m and the drone u is expressed as d m,u , the uplink data rate is represented by R m,u express; The cache model: Due to the high communication delay between the base station and the drone, the service cache is updated every T′ time slot, using the binary variable c k,u = {0,1} to indicate whether program k is cached on the drone; c k,u =1 means program k is cached on the drone, c k,u = 0 means that program k is not cached on the drone; the cache capacity required by program k is l k express; The computing offloading model: unloading is performed in binary mode, that is, all tasks are calculated locally or all are offloaded to edge servers for computing; using a m,u (k) = {0, l} to indicate whether the device task in time slot t needs to be unloaded, a m,u (k) = 1 means to offload the task, otherwise it is calculated locally; the offloading location of the task is express; The energy consumption model: The energy consumption of ground equipment consists of two parts: calculating energy consumption and the energy consumption of uploading data of computing tasks to the drone The energy consumption of drones consists of two parts: computing energy consumption and the energy consumption of transmitting the uploaded data of the computing task to the base station The energy consumption of ground equipment is expressed as The energy consumption of the drone is expressed as 3. The dual-time-scale joint optimization service cache and computation offloading method for drone-assisted MEC according to claim 1 is characterized in that: include: The total delay of the multi-UAV assisted mobile edge computing system: If calculated locally, the total system delay is the local calculation time of the device. If the task is offloaded to the drone, the delay from the task offload to the drone is the transmission time of the task from the device to the drone. Computational latency with drones The task is offloaded to the base station for calculation. Considering the powerful computing power of the base station, it is believed that the task execution time is approximately 0, so the delay of offloading the task to the base station is approximately equal to the transmission time of the task from the drone to the base station. The latency of task offloading is Therefore, the total delay of the system is The optimization problem model is expressed as: The restrictions are as follows: C1: C2: C3: C4: C5: C6: C7: C8: C9: Among them, C1 and C2 represent service cache and computation offloading decisions as binary variables; C3 represents resource allocation ratio as a continuous variable, s m,u It indicates the ratio of task computing resources allocated by UAV u to device m; C4 and C5 ensure that the energy consumption of ground equipment and UAVs does not exceed their energy budget; C6 indicates that the tasks generated by each device can only be executed in one place; C7 indicates that the computing resources allocated by UAVs to devices cannot exceed the computing power of each UAV; C8 ensures that the total capacity of the UAV cache program is within its cache capacity; C9 limits the users served by the UAV to be within its service scope.

4. The dual-time-scale joint optimization service caching and computation offloading method for drone-assisted MEC according to claim 1 is characterized in that: The service cache strategy improved based on the greedy dual-size frequency algorithm: The access frequency of the data item is calculated based on the number of requests n by the program in the past T′ time slots; the size of the data item is the size of each program; Calculate the popularity coefficient of each task according to the Zipf distribution: Where W represents the frequency of each task generation, S represents the parameter of the zipf distribution, and C is a normalization constant to ensure that the sum of the probabilities is 1; The evaluation score of each program is calculated using the following evaluation function: Among them, l k is the size of the program, p and n are the task popularity and the access frequency of the program, respectively, and β and γ are adjustment factors used to balance the task popularity and access frequency; Update service cache based on the improved service cache strategy of greedy dual-size frequency algorithm: Calculate the evaluation score of each program in each T′ time slot, and sort each program from high to low according to the evaluation score; wherein multiple programs with the same score are sorted from small to large according to program size; Select the top K′ programs according to the sorting results and cache them in the next T′ time slots; If the total size of the selected K′ programs exceeds the total cache capacity of the drone, they are replaced in sequence from the K′+1th program to the last program until the total size of the programs is lower than the upper limit of the drone cache capacity.

5. The dual-time-scale joint optimization service cache and computation offloading method for drone-assisted MEC according to claim 1 is characterized in that: The Markov decision process is represented by a multi-tuple {S, A, R, P, γ}, which are state space, action space, reward function, state transition probability and reward discount factor respectively; The state space is used to represent the environment and is set as: in, represents the position of the UAV at time slot t, A program representing the drone cache, Indicates the remaining battery capacity of the drone. represents the location of the ground equipment in time slot t, represents the task size generated by the ground equipment, Indicates the task type generated by the ground equipment; The action space consists of the ground equipment ID being served, the computation offloading decision and the resource allocation ratio; the action space is set as: in, The ID of the ground equipment being served. For uninstallation decision, Allocate proportions for resources; The reward function is defined as the negative of the total system delay: R t =-T m .

6. The dual-time-scale joint optimization service caching and computation offloading method for UAV-assisted MEC according to claim 1 is characterized in that: The improved service cache strategy based on the greedy dual-size frequency algorithm is embedded into the TD3 algorithm to construct a dual-time-scale TD3 solution, and the offloading decision and resource allocation ratio are solved according to the optimization goal, including: Construct and initialize the TD3 network: The TD3 network includes an actor current network, an actor target network, two critic current networks, and two critic target networks. The system state is input into the actor current network of the TD3 network. The actor current network makes action decisions according to the strategy function π and enters the noise Expand the exploration capability of the action and finally obtain the action a of time slot t t , the formula is: According to the action execution task calculation in time slot t, the system state s of the next time slot t+1 is obtained t+1 , and calculate the reward r of time slot t; the sample (s t ,a t ,r,s t+1 ) is saved in the experience pool. If the samples in the sample experience pool do not reach the experience pool capacity, the system state of the next time slot is input into the actor's current network to generate the action of the next time slot. This step is repeated until the sample experience pool is full. If the experience pool is full, N samples are extracted from the experience pool to train the TD3 network and update the TD3 network parameters; Randomly extract N samples and set the next time slot state s t+1 Input the actor-target network and add random noise ∈ to improve the robustness of the action strategy to obtain the actor-target network action The actions of the actor-target network are: The state-action pair of the next time slot is input into the two critic target networks to obtain the target state-action value Q′1(s t+1 ,π′(s t+1 )), target state action value Q′2(s) of critic target network 2 t+1 ,π′(s t+1 )), and finally the smaller value of the two critic target network state action values ​​is used to calculate the actual gain of the critic target network, the formula is: y = r + γmin (Q ′1 (s t+1 ,π′(s t+1 )),Q′2(s t+1 ,π′(s t+1 )) / ; Using the mean square error function, the critic's current network parameters are updated through the gradient back propagation of the neural network: Determine whether the critic's current network parameter update reaches the set number of times d. If so, the actor's current network parameters are updated through the loss gradient: Use soft update to update the actor target network parameters and the critic target network parameters: i π′ =tθ π +(1-τ)θ π′ 。

Citation Information

Cited By

  • Intelligent network connection automobile data transmission method and system

    CN119676769A

  • Edge calculation method and device for multi-task parallel execution assisted by unmanned aerial vehicle

    CN120050724A

  • Cloud side information collaboration and content delivery method for air-based high-mobility network

    CN120416918A

  • Double-time-scale optimization method for assisting task unloading and caching in cooperation of multiple unmanned aerial vehicles

    CN121541943A

  • Multi-uav cooperative auxiliary task unloading and cache double-time-scale optimization method

    CN121541943B