An economic and efficient federated learning method based on digital twin assistance
By constructing a digital twin-assisted federated learning framework and optimizing edge selection and resource allocation, the model training problem for resource-constrained vehicles in intelligent driving scenarios is solved, achieving efficient model training with low energy consumption and low latency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHONGQING UNIV OF POSTS & TELECOMM
- Filing Date
- 2023-02-20
- Publication Date
- 2026-04-21
AI Technical Summary
In intelligent driving scenarios, it is difficult to guarantee model quality when performing federated learning on resource-constrained vehicles. Furthermore, the latency and energy consumption of the federated learning process cannot be ignored. Directly reducing communication, computing, and energy may reduce the model convergence speed and training quality.
A federated learning framework assisted by digital twins is constructed. By making decisions on edge selection and resource allocation through the cloud center, the computing and communication resources of edge servers are optimized. The P-DQN algorithm is used to solve the optimization problem to reduce energy consumption and latency.
Without affecting the accuracy of the global model, the cumulative energy consumption for creating digital twins and the latency and energy consumption in the federated learning process are reduced, thereby improving the efficiency and quality of model training.
Smart Images

Figure CN116306988B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of digital twins and federated learning, and relates to a cost-effective federated learning method based on digital twin assistance. Background Technology
[0002] In intelligent driving scenarios, various tasks require vehicles to collaborate in training, such as collision warning. Federated learning is an effective technical solution to obtain a high-precision global model. However, for some resource-constrained vehicles, performing federated learning can compromise model quality, and the latency and energy consumption of the federated learning process cannot be ignored.
[0003] Digital Twin (DT) in 6G enables extremely reliable and instantaneous connections between virtual objects and physical entities. Specifically, DT can create virtual objects in the digital space that map to the physical world, and these virtual objects are continuously updated using real-time sensor data. In autonomous driving scenarios, resource-constrained vehicles can choose to create their DT on edge servers, allowing the vehicle DT to leverage the computing resources of the edge servers to participate in federated learning to train machine learning models.
[0004] Because virtual vehicle objects in a constantly evolving digital space powered by real-time sensor data are extremely energy-intensive, and given the sheer number and high mobility of vehicles on the road, deploying data processing (DT) for all vehicles participating in federated learning is impractical. On the other hand, directly reducing communication, computation, and energy costs could decrease model convergence speed and the quality of trained models, thus offsetting the benefits of DT. Summary of the Invention
[0005] In view of this, the purpose of this invention is to provide a cost-effective federated learning method based on digital twin assistance. In dynamic and complex intelligent driving environments, it should reduce the cumulative energy consumption of creating DT and the latency and energy consumption in the federated learning process by jointly optimizing edge selection, computing resource allocation and communication resource allocation, without affecting the accuracy of the global model.
[0006] To achieve the above objectives, the present invention provides the following technical solution:
[0007] A cost-effective federated learning method based on digital twin assistance includes the following steps:
[0008] S1: In intelligent driving scenarios, construct a federated learning framework assisted by digital twins, including vehicles with limited computing and storage resources, infrastructure with monitoring capabilities, base stations with edge servers, and cloud centers with parameter servers.
[0009] S2: Vehicles and edge servers inform the cloud center of their resource information and task lists;
[0010] S3: The cloud center makes decisions based on the resource status and operating status of the vehicle and the edge server, and uses the edge selection model to determine whether to use the edge server for model training and to select which edge server to create the vehicle digital twin model (DT).
[0011] S4: Based on the edge selection results, the vehicle performs model training locally or its DT (Data Technology) uses the computing resources of the edge server to train the model.
[0012] S5: The edge server aggregates the vehicle model to obtain a local model, and then uploads the model to the cloud center;
[0013] S6: The cloud center performs global aggregation to obtain a global model;
[0014] S7: The system updates resource status and running status. The cloud center uses P-DQN to solve the optimization problem of the digital twin-assisted cost-effective federated learning model, and explores edge selection strategy and resource allocation strategy for the next round of federated learning.
[0015] S8: Repeat steps S2-S7 until the global model converges to the preset accuracy.
[0016] Furthermore, the federated learning framework for constructing digital twin assistance includes a terminal layer, an edge layer, and a cloud layer;
[0017] The terminal layer consists of vehicles with limited computing and storage resources and monitoring infrastructure, connected to base stations in the edge layer via wireless channels, where the set of N vehicles is represented as...
[0018] The edge layer comprises K base stations with edge servers, and their set is represented as follows: Digital twins used to perform computational tasks and to create and maintain multiple physical entities or multiple physical subsystems;
[0019] The cloud layer includes a cloud center with parameter servers, which aggregates local models uploaded by edge servers to obtain a global model.
[0020] Furthermore, step S3, which involves using an edge selection model to determine whether to use an edge server for model training and selecting which edge server to create the vehicle digital twin model, specifically includes:
[0021] Using binary variables The edge selection strategy for vehicle n is represented as:
[0022]
[0023] parameter This means that vehicle n chooses to create and maintain its digital twin on edge server k. Each edge server first merges the local model trained by the virtual object in the digital space with the local models uploaded by other vehicles within the communication range, and then uploads the merged model parameters to the cloud center for global fusion to obtain the global model.
[0024] This means that vehicle n completes model training locally and uploads the model parameters to the nearest edge server for local fusion;
[0025] This indicates whether vehicle n is associated with edge server k, specifically as follows:
[0026]
[0027] The energy consumed in creating a DT is expressed as
[0028] Furthermore, in step S4, the resulting computational latency and energy consumption include: the computational latency and energy consumption of vehicle n during local training are as follows: and The computational latency and energy consumption of the edge server using the vehicle DT training model in the digital space are as follows: and
[0029] Furthermore, in step S5, the resulting computational latency and energy consumption include: the transmission latency and energy consumption from vehicle n to edge server k are respectively: and The aggregate latency and energy consumption of edge server k are as follows: and The total computation time for K edge servers is: Energy consumption of edge server maintenance vehicle DT: The transmission latency and energy consumption from edge server k to the cloud center are as follows: and
[0030] Furthermore, in step S6, the resulting computational latency and energy consumption include: the computational latency and energy consumption of the local model uploaded by the cloud center aggregation edge server are as follows: and
[0031] Furthermore, the optimization problem of the digital twin-assisted cost-effective federated learning model described in step S7 is as follows:
[0032] The total system time consumption is expressed as follows:
[0033]
[0034] Among them, T k (l) and T n (l) represents the total latency of edge server k and vehicle n in a single round of federated learning iteration;
[0035] The total energy consumption of the system is expressed as:
[0036]
[0037] Among them, E n (l) and E k (l) represents the total energy consumption of edge server k and vehicle n in one round of federated learning iteration. Energy consumption for creating vehicle DT in edge server k;
[0038] Based on the analysis of time and energy consumption, the following optimization objectives are obtained:
[0039]
[0040] Where μ1 and μ2 are the coefficients for latency and energy consumption, respectively; in the constraints, C1 represents the convergence requirement for model training, where the global model converges to the target accuracy after L rounds of global updates, and ε is the convergence threshold, representing the accuracy of model training; C2 represents the constraint on the value of the edge selection metric; C3 represents the maximum number of M edge servers that can be created by a single edge server. max DT for each vehicle; C4 represents the range of CPU cycle frequency; C5 represents the total number of channels constraint; C6 represents the channel allocation constraint.
[0041] Furthermore, the optimization problem of the digital twin-assisted cost-effective federated learning model using P-DQN described in step S7 specifically includes:
[0042] The optimization problem is formulated as a Markov Decision Process (MDP), where the system state, action space, and reward function are defined as follows:
[0043] State: The system state describes the characteristics and training state of each edge server, including the current computing resources of all edge servers. Communication resource state γ(t) and training state F(ω) t ).Right now,
[0044] Action: Action space is represented as in Action a t Including edge selection CPU cycle frequency allocation f(t) and channel allocation d(t);
[0045] Reward: By finding suitable edge selection and resource allocation strategies to minimize the total cost in DT-assisted FL, the reward function is expressed as:
[0046]
[0047] The P-DQN algorithm is used to solve the problem.
[0048] The beneficial effects of this invention are as follows: In dynamic and complex intelligent driving environments, this invention reduces the cumulative energy consumption of creating DT and the latency and energy consumption during federated learning processes by jointly optimizing edge selection, computing resource allocation, and communication resource allocation, without affecting the accuracy of the global model.
[0049] Other advantages, objectives, and features of the invention will be set forth in part in the description which follows, and in part will be apparent to those skilled in the art from the following examination, or may be learned from practice of the invention. The objectives and other advantages of the invention can be realized and obtained through the following description. Attached Figure Description
[0050] To make the objectives, technical solutions, and advantages of the present invention clearer, the preferred embodiments of the present invention will be described in detail below with reference to the accompanying drawings, wherein:
[0051] Figure 1 A diagram of a cost-effective federated learning framework for digital twins;
[0052] Figure 2 A flowchart for a cost-effective federated learning method based on digital twin assistance. Detailed Implementation
[0053] The following specific examples illustrate the implementation of the present invention. Those skilled in the art can easily understand other advantages and effects of the present invention from the content disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and various details in this specification can be modified or changed based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the illustrations provided in the following embodiments are only schematic representations of the basic concept of the present invention. Unless otherwise specified, the following embodiments and features can be combined with each other.
[0054] The accompanying drawings are for illustrative purposes only and are schematic diagrams, not actual pictures. They should not be construed as limiting the invention. To better illustrate the embodiments of the invention, some parts in the drawings may be omitted, enlarged, or reduced, and do not represent the actual product dimensions. It is understandable to those skilled in the art that some well-known structures and their descriptions may be omitted in the drawings.
[0055] In the accompanying drawings of the embodiments of the present invention, the same or similar reference numerals correspond to the same or similar components. In the description of the present invention, it should be understood that if terms such as "upper," "lower," "left," "right," "front," and "rear" indicate the orientation or positional relationship based on the orientation or positional relationship shown in the drawings, they are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, the terms used to describe positional relationships in the drawings are only for illustrative purposes and should not be construed as limiting the present invention. For those skilled in the art, the specific meaning of the above terms can be understood according to the specific circumstances.
[0056] Please see Figures 1-2 This invention provides a cost-effective federated learning method based on digital twin assistance.
[0057] Figure 1 This is a diagram of a digital twin-assisted, cost-effective federated learning framework, which specifically includes:
[0058] The digital twin-assisted cost-effective federated learning framework consists of three layers: 1) terminal layer; 2) edge layer; 3) cloud layer.
[0059] The terminal layer consists of entities such as vehicles with limited computing and storage resources and infrastructure with monitoring capabilities. These physical entities are connected to base stations in the edge layer via wireless channels, where the set of N vehicles can be represented as...
[0060]
[0061] In the edge layer, there are K base stations with edge servers, and their set is represented as follows: To avoid resource waste, not all base stations are equipped with edge servers. Base stations without edge servers are primarily responsible for providing wireless communication services to end users, while other base stations are responsible for performing computing tasks and creating and maintaining digital twins. Since the number of physical entities in the edge layer far exceeds the number of edge servers, it is assumed that one edge server can create and maintain digital twins of multiple physical entities or multiple physical subsystems.
[0062] The cloud layer contains a cloud center with parameterized servers, which can be represented as B. cl The parameter server has more powerful computing, communication and storage capabilities. It is mainly responsible for aggregating the local models uploaded by the edge servers to obtain the global model.
[0063] See Figure 2 , Figure 2 The system flowchart contains the following details:
[0064] Vehicles and edge servers inform the cloud center of their resource information and task lists. The cloud center then makes decisions based on the resource and operational status of the vehicles and edge servers, specifically whether to utilize edge servers for model training and on which edge server to create the vehicle data processing unit (DT). Depending on the edge selection result, vehicles either train their models locally or their DTs utilize the computing resources of the edge servers for model training. Edge servers need to aggregate vehicle models to obtain local models before uploading them to the cloud center. The cloud center performs global aggregation to obtain the global model. The system updates its resource and operational status, and the cloud center uses P-DQN to explore edge selection and resource allocation strategies for the next round of federated learning. This process is repeated until the global model converges to a preset accuracy.
[0065] In this invention, it is first necessary to construct an edge selection model, a federated learning model, a computation model, and a communication model;
[0066] The edge selection model specifically uses binary variables. This represents the edge selection strategy for vehicle n. Specifically, it is expressed as: This indicates that vehicle n chooses to create and maintain its digital twin on edge server k. Each edge server first fuses the local model trained on the virtual object in the digital space with the local models uploaded by other vehicles within its communication range, and then uploads the fused model parameters to the cloud center for global fusion to obtain the global model. This indicates that vehicle n completes model training locally and uploads the model parameters to the nearest edge server for local fusion. To facilitate subsequent characterization of the impact of edge selection on the latency and energy consumption of the federated learning process, it is assumed that... This indicates whether vehicle n is associated with edge server k, specifically as follows:
[0067] The energy consumed in creating a DT is expressed as
[0068]
[0069] Among them, e DT c represents the unit energy required to create a DT. n This indicates that creating vehicle n's DT requires consuming c. n One unit of energy, As a penalty, it is specifically the ratio of the total resources of edge server k to the remaining available resources. This represents the total resources of edge server k. This represents the remaining available resources of edge server k.
[0070] The federated learning model is as follows:
[0071] In federated learning for autonomous driving, to improve learning accuracy and resist malicious attacks, parameters uploaded by high-quality nodes should have a greater weight in the aggregation process. Model quality is represented as: Where l represents the current iteration round of federated learning, This represents the DT bias of vehicle n in the edge server. If vehicle n did not choose to use DT for model training on the edge server... Then it is set to a constant value. It represents the number of models that actively contribute to edge server k. It represents the number of malicious models in edge server k. This is the model contribution value, calculated as follows: in This represents the average value of all model parameters in edge server k. This represents the local model parameters of vehicle n in edge server k, where n represents vehicle n and N represents the number of models to be aggregated in the edge server.
[0072] The computational model includes local computation where vehicles use their own real-time data for model training, edge computation where edge servers use vehicle data points (DTs) in the digital space for model training, local aggregation computation where edge servers aggregate model parameters, and global aggregation computation where the cloud center aggregates local models uploaded from edge servers.
[0073] Assume the number of CPU cycles required to train one byte of data for a vehicle is λ. n The number of CPU cycles required for an edge server to train one byte of data is λ. k The number of CPU cycles required for an edge server to aggregate one byte of data is λ. k The number of CPU cycles required for the cloud center to aggregate one byte of data is ''. The CPU cycle frequency for DT training assigned to vehicle n is f. nk (l).
[0074] The computation time for local training of vehicle n is expressed as:
[0075]
[0076] Among them, D n (l) represents the data size of vehicle n participating in the training in the l-th iteration, f n This represents the CPU cycle frequency during local training of vehicle n.
[0077] The computation time for edge server k is:
[0078]
[0079]
[0080] in, This indicates the training time of the edge server. Represents the aggregation time of the edge servers, |ω n | represents the model size of vehicle n. Specifically, the total computation time for K edge servers is...
[0081]
[0082] The computation time for the local model uploaded by the cloud center aggregation edge server is:
[0083]
[0084] Where, |ω k |The size of the local model uploaded to edge server k. B cl CPU cycle frequency of the aggregation model.
[0085] The system's computational energy consumption is divided into five parts: computational energy consumption for local vehicle training, computational energy consumption for edge servers to train vehicle DT models using the digital space, aggregation energy consumption for edge servers to aggregate models, energy consumption for edge servers to maintain vehicle DT models, and aggregation energy consumption for cloud center to aggregate local models. These are represented as follows:
[0086]
[0087]
[0088]
[0089]
[0090]
[0091] Where σ1 and σ2 represent the training capabilities of the vehicle and the edge server, respectively; σ3 represents the aggregation capability of the edge server; σ4 represents the ability of the edge server to maintain a single data center (DT) in the digital space; and σ5 represents the aggregation capability of the cloud center. This indicates the number of DTs maintained in edge server k.
[0092] In DT-assisted federated learning, the communication model involves frequent transmission of model parameters between vehicles, edge servers, and the cloud center to achieve preset accuracy or model convergence. However, communication resources are limited in intelligent driving systems, so channel allocation is considered to achieve better system performance. This study focuses on channel allocation between edge servers and vehicles. Assuming that vehicles and edge servers are allocated C channels, and the bandwidth of a sub-channel is denoted as W0, the constraints on channel allocation can be expressed as:
[0093]
[0094] Where d n and d k Let n and k represent the number of channels allocated to vehicle n and edge server k, respectively. Therefore, the data rate from vehicle n to edge server k can be easily derived as:
[0095] r n,k (l)=W0·d n (l)·log2(1+γ n,k (l))
[0096] in, This represents the channel state between vehicle n and edge server k, where h n,k (l) represents the channel gain between vehicle n and edge server k. N represents the transmission power of vehicle n, and N0 represents the noise power.
[0097] From edge server k to cloud center B cl The data rate is:
[0098]
[0099] in, This represents edge server k and cloud center B. cl The channel state between them.
[0100] In the communication model, the main analysis focuses on the transmission time and energy consumption of federated learning based on DT technology. The transmission time includes three parts: from vehicle to edge server, from edge server to cloud center, and from cloud center to edge server and vehicle.
[0101] For vehicles that choose to train their models locally, the trained models need to be transferred to an edge server for local aggregation. Therefore, the transfer time from vehicle n to edge server k is...
[0102]
[0103] In a network of K edge servers, if vehicle DT exists, these edge servers will use the vehicle mapping data in the digital space to train the model. Then, the trained model parameters will be fused with the model parameters uploaded by other vehicles that have chosen to train their models locally. Finally, the fused model parameters will be uploaded to the cloud center. Thus, the distance from edge server k to cloud center B... cl The transmission time is:
[0104]
[0105] After receiving the model parameters from the edge server, the cloud center aggregates them to obtain a global model, and then sends the model parameters to the edge server and the vehicle for the next iteration. Considering that the cloud center's transmission capacity is far greater than that of the edge server, the time consumed by the cloud center in sending the global model parameters is negligible.
[0106] Transmission energy consumption also includes three parts: from vehicle to edge server, from edge server to cloud center, and from cloud center to edge server and vehicle. The energy consumption from cloud center to edge server and vehicle is negligible. The other two parts can be expressed as follows:
[0107]
[0108]
[0109] in, Let n be the transmission power of vehicle n. The transmission power of edge server k.
[0110] In this invention, the optimization problem of a digital twin-assisted cost-effective federated learning model is also modeled, as follows:
[0111] Based on the above analysis, the total latency of vehicle n in one round of federated learning iteration is expressed as:
[0112]
[0113] The total latency of edge server k is expressed as:
[0114]
[0115] Therefore, the total system time consumption is expressed as:
[0116]
[0117] The total energy consumption of vehicles and edge servers are as follows:
[0118]
[0119]
[0120] in, The energy consumption for creating vehicle DT in edge server k is specifically expressed as:
[0121]
[0122] The total energy consumption in one iteration is expressed as:
[0123]
[0124] Based on the above analysis of time and energy consumption, the following optimization objectives are obtained:
[0125]
[0126] Where μ1 and μ2 are the coefficients for latency and energy consumption, respectively. In the above constraints, C1 represents the convergence requirement for model training; the global model converges to the target accuracy after L rounds of global updates, where ε is the convergence threshold, representing the accuracy of model training; C2 represents the constraint on the value of the edge selection metric; C3 represents the maximum number of edge servers that can be created by a single edge server. max DT for each vehicle; C4 represents the range of CPU cycle frequency; C5 represents the total number of channels constraint; C6 represents the channel allocation constraint.
[0127] Using deep reinforcement learning to solve the cost-effective federated learning optimization problem assisted by digital twins, specifically defined as:
[0128] The data size, channel state, and available computing resources of the vehicle and edge servers dynamically change during different iterations of the DT-assisted FL. Under resource constraints, careful consideration of edge selection and resource allocation in DT-assisted FL is necessary to reduce the overall cost. Traditional methods struggle to handle constrained joint optimization problems. Therefore, the joint optimization problem is formulated as a Markov Decision Process (MDP), where the system state, action space, and reward function are defined as follows.
[0129] State: The system state describes the characteristics and training state of each edge server, including the current computing resources of all edge servers. Communication resource state γ(t) and training state F(ω) t ).Right now,
[0130] Action: Action space is represented as in Action a t Including edge selection CPU cycle frequency allocation f(t) and channel allocation d(t).
[0131]
[0132] f(t) = {f1(t), f2(t), ..., f k (t)}
[0133] d(t)={d n (t),d1(t),d2(t),...,d k (t)}
[0134] Channel allocation should comply with constraints Furthermore, the total time and energy consumption in edge selection, computational resource allocation, and channel allocation must meet the optimization objectives.
[0135] Reward: The objective of this invention is to minimize the total cost in DT-assisted FL by finding suitable edge selection and resource allocation strategies. The reward function is expressed as:
[0136]
[0137] The action space described above includes discrete actions and continuous actions, while most reinforcement learning models are designed only for discrete or continuous action spaces. The P-DQN algorithm is used to solve this space.
[0138] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
Claims
1. A cost-effective federated learning method based on digital twin assistance, characterized in that: Includes the following steps: S1: In intelligent driving scenarios, construct a federated learning framework assisted by digital twins, including vehicles with limited computing and storage resources, infrastructure with monitoring capabilities, base stations with edge servers, and cloud centers with parameter servers. S2: Vehicles and edge servers inform the cloud center of their resource information and task lists; S3: The cloud center makes decisions based on the resource status and operating status of the vehicle and the edge server, and uses the edge selection model to determine whether to use the edge server for model training and to select which edge server to create the vehicle digital twin model (DT). S4: Based on the edge selection results, the vehicle performs model training locally or its DT (Data Technology) uses the computing resources of the edge server to train the model. S5: The edge server aggregates the vehicle model to obtain a local model, and then uploads the model to the cloud center; S6: The cloud center performs global aggregation to obtain a global model; S7: The system updates resource and operational status. The cloud center uses a parameterized deep Q-network (P-DQN) to solve the optimization problem of the digital twin-assisted cost-effective federated learning model, exploring edge selection and resource allocation strategies for the next round of federated learning. The optimization problem of the digital twin-assisted cost-effective federated learning model mentioned in step S7 is as follows: The total system time consumption is expressed as follows: in, Let k be the total latency of edge server k in one round of federated learning iteration. The computation latency of the local model uploaded to the cloud center's aggregated edge server; The total energy consumption of the system is expressed as: in, and These represent the total energy consumption of edge server k and vehicle n respectively during a round of federated learning iteration; Energy consumption of local models uploaded to the cloud center's aggregated edge servers; Based on the analysis of time and energy consumption, the following optimization objectives are obtained: in, and These are the coefficients for latency and energy consumption, respectively; in the constraints, C1 represents the convergence requirement for model training, where the global model converges to the target accuracy after L rounds of global updates. C1 represents the convergence threshold, indicating the accuracy of model training; C2 represents the constraint on the edge selection metric, and the parameters are... This indicates that vehicle n chooses to create and maintain its digital twin in edge server k, parameter This means that vehicle n chooses to create and maintain its digital twin on edge server k. Each edge server first merges the local model trained by the virtual object in the digital space with the local models uploaded by other vehicles within the communication range, and then uploads the merged model parameters to the cloud center for global fusion to obtain the global model. This indicates that vehicle n completes model training locally and then uploads the model parameters to the nearest edge server for local fusion. C3 represents the set of edge servers; C3 represents the maximum number of edge servers that can be created. One vehicle DT, Let C be a set of N vehicles; C4 represents the range of CPU cycle frequency values; C5 represents the total number of channels constraint. The bandwidth of the sub-channel. and C represents the number of channels allocated to vehicle n and edge server k, respectively. C represents the number of channels allocated to the vehicle and the edge server; C6 represents the channel allocation constraint. S8: Repeat steps S2-S7 until the global model converges to the preset accuracy.
2. The cost-effective federated learning method based on digital twin assistance according to claim 1, characterized in that: The federated learning framework for building digital twin assistance includes a terminal layer, an edge layer, and a cloud layer; The terminal layer consists of vehicles with limited computing and storage resources and monitoring infrastructure, connected to base stations in the edge layer via wireless channels, where the set of N vehicles is represented as... ; The edge layer comprises K base stations with edge servers, and their set is represented as follows: It is used to perform computing tasks and to create and maintain digital twins of multiple physical entities or multiple physical subsystems; The cloud layer includes a cloud center with parameter servers, which aggregates local models uploaded by edge servers to obtain a global model.
3. The cost-effective federated learning method based on digital twin assistance according to claim 1, characterized in that: Step S3, which involves using an edge selection model to determine whether to use an edge server for model training and to select which edge server to create the vehicle digital twin model, specifically includes: Using binary variables The edge selection strategy for vehicle n is represented as: parameter This means that vehicle n chooses to create and maintain its digital twin on edge server k. Each edge server first merges the local model trained by the virtual object in the digital space with the local models uploaded by other vehicles within the communication range, and then uploads the merged model parameters to the cloud center for global fusion to obtain the global model. This means that vehicle n completes model training locally and uploads the model parameters to the nearest edge server for local fusion; This indicates whether vehicle n is associated with edge server k, specifically as follows: The energy consumed in creating a DT is expressed as .
4. The cost-effective federated learning method based on digital twin assistance according to claim 1, characterized in that: In step S4, the resulting computational latency and energy consumption include: the computational latency and energy consumption of vehicle n during local training are as follows: and The computational latency and energy consumption of the edge server using the vehicle DT training model in the digital space are as follows: and .
5. The cost-effective federated learning method based on digital twin assistance according to claim 1, characterized in that: In step S5, the resulting computational latency and energy consumption include: the transmission latency and energy consumption from vehicle n to edge server k are as follows: and The aggregate latency and energy consumption of edge server k are as follows: and The total computation time for the K edge servers is: Energy consumption of edge server maintenance vehicle DT: The transmission latency and energy consumption from edge server k to the cloud center are as follows: and .
6. The cost-effective federated learning method based on digital twin assistance according to claim 1, characterized in that: In step S6, the resulting computational latency and energy consumption include: the computational latency and energy consumption of the local model uploaded by the cloud center aggregation edge server are as follows: and .
7. The cost-effective federated learning method based on digital twin assistance according to claim 1, characterized in that: Step S7, which describes using P-DQN to solve the optimization problem of the digital twin-assisted cost-effective federated learning model, specifically includes: The optimization problem is formulated as a Markov Decision Process (MDP), where the system state, action space, and reward function are defined as follows: State: The system state describes the characteristics and training state of each edge server, including the current computing resources of all edge servers. Communication resource status and training status ,Right now, Action: Action space is represented as ,in ;action Including edge selection CPU cycle frequency allocation and channel allocation ; Reward: By finding suitable edge selection and resource allocation strategies to minimize the total cost in DT-assisted FL, the reward function is expressed as: The P-DQN algorithm is used to solve the problem.
Citation Information
Patent Citations
High-energy-efficiency federated learning framework based on digital twinning
CN113537514A
Service function chain deployment method based on federal reinforcement learning
CN114726743A