Split federal learning method and system based on Internet of Vehicles, and computing device
By dividing the model in the cloud and performing clustering and gradient updates, the problem of limited vehicle computing resources in the Internet of Vehicles is solved, the coordinated training and wide application of global models is realized, the computing and communication burden on the vehicle side is reduced, and the non-independent and homogeneous distribution characteristics of vehicle data are adapted.
Patent Information
- Application Number
- CN202510759950.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-09
- Publication Date
- 2025-07-04
- Estimated Expiration
- 2045-06-09
AI Technical Summary
The existing federated learning methods are limited by vehicle computing resources and have limited application scenarios, so they cannot effectively use vehicles widely distributed and limited computing resources in the Internet of Vehicles for data collaborative training.
The preset complete models are divided by the cloud, and a cluster model is generated for the local model of the vehicle end and the cloud end. The vehicle end only performs feature extraction and uploads data features to the cloud for clustering and in-cluster training. The cloud calculates gradient update parameters and issues them to the vehicle end to update the local model. Finally, the cloud aggregates the update models of all vehicle ends.
It reduces the computing and communication needs of the vehicle side, realizes collaborative training of the global model, and has a wider range of applicable scenarios. It overcomes the limitations of network bandwidth, privacy and security and massive data scale in the Internet of Vehicles, and adapts to the non-independent and homogeneous distribution characteristics of vehicle data.
Smart Images

Figure CN120258176A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of vehicle networking, and particularly to a split federated learning method, system, and computing device based on vehicle networking. Background Art
[0002] The rapid development of vehicle networking has given rise to a large amount of diverse data, which has become the key foundation for supporting applications such as intelligent transportation, autonomous driving, vehicle-road collaboration, and remote monitoring. However, vehicles are widely distributed, data sources are scattered and diverse, and there are many challenges in efficiently utilizing this data.
[0003] Traditional centralized training methods gather all data to a unified location for processing, but have high requirements for resource allocation and are difficult to effectively deploy. Federated learning allows vehicles distributed everywhere to train models locally and share model updates through encryption or other means to achieve collaborative construction of a global model. However, the computing resources of in-vehicle systems are limited and cannot run a complete machine learning model locally. For this reason, split federated learning hierarchically partitions the complete model, enabling vehicles to only need to train the partitioned model locally, and finally the cloud aggregates the training models of the vehicles to achieve collaborative training of the complete model.
[0004] That is to say, existing federated learning methods all require vehicles to train models locally. However, not all vehicle models have sufficient computing resources to support the local model training process, and the above methods have certain limitations in practical applications. Summary of the Invention
[0005] In view of this, the present invention provides a split federated learning method, system, and computing device based on vehicle networking to solve the problem that existing federated learning methods are limited by vehicle computing resources and have limited application scenarios.
[0006] In a first aspect, the present invention provides a split federated learning method based on vehicle networking, which is applied to the cloud. This method includes multiple rounds of training, and each round of training includes: Sending a local model applicable to the vehicle side to all vehicle sides, so that each vehicle side extracts data features from local data based on the local model and uploads the extracted data features to the cloud; Clustering all vehicle sides based on the data features to obtain multiple clustering clusters; Performing intra-cluster training based on the cluster model corresponding to each clustering cluster and the data features to obtain first gradient update parameters; the cluster model and the local model in the first round of training are obtained by partitioning a preset complete model; Update the cluster model using the first gradient update parameter, and send the first gradient update parameter to the corresponding vehicle side, so that the corresponding vehicle side calculates the second gradient update parameter based on the first gradient update parameter and the data feature, updates the local model using the second gradient update parameter, and uploads the updated local model to the cloud; Aggregate the updated local models uploaded by all vehicle sides to obtain an aggregated model; the aggregated model obtained in the last round of training is used to be deployed to all vehicle sides.
[0007] This application uses the cloud to divide a preset complete model into a local model applicable to the vehicle side and a cluster model applicable to the cloud. The vehicle side extracts data features from local data using the local model distributed by the cloud and uploads them to the cloud. The cloud first clusters all vehicle sides using the data features to capture the non-independent and identically distributed characteristics of the vehicle side data, and then performs intra-cluster training on the cluster model associated with each cluster based on the data features, calculates the first gradient update parameter for updating the cluster model, and sends it to the vehicle sides included in the corresponding cluster. Without local training, the vehicle side can calculate the second gradient update parameter by combining the first gradient update parameter and the local data features to update the local model, reducing the local computing and communication requirements of the vehicle side, achieving collaborative training of the global model, and having a wider range of application scenarios. Finally, the cloud aggregates the updated local models of all vehicle sides, generates an aggregated model, and deploys it to the vehicle side after the training is completed for the vehicle side to perform data collection work.
[0008] In an optional implementation manner, the data feature includes a low-dimensional data feature, a decoder, and a label of local data, where the low-dimensional data feature is obtained by compressing the high-dimensional data feature using the encoder corresponding to the decoder after the vehicle side converts the local data into a high-dimensional data feature using the local model; Clustering all vehicle sides based on the data feature to obtain multiple clusters, including: Reconstruct the low-dimensional data feature using the decoder to obtain a reconstructed feature; Calculate the similarity between all vehicle sides pairwise according to the reconstructed feature to obtain a similarity matrix, and cluster all vehicle sides according to the similarity matrix to obtain multiple clusters; where each cluster contains at least one vehicle side.
[0009] This application uses the vehicle side to compress the high-dimensional data features extracted from local data into low-dimensional data features, and by uploading the compressed low-dimensional data features to the cloud, it greatly reduces the communication burden between the vehicle side and the cloud. Moreover, the vehicle side uploads a decoder to the cloud to ensure that the cloud can decode and reconstruct the low-dimensional data features to obtain reconstructed features similar to the extracted features of the vehicle side, so as to perform clustering analysis on all vehicle sides and capture the non-independent and identically distributed characteristics of vehicle data.
[0010] In an alternative embodiment, the method further includes: When detecting the offline first vehicle side, merging or splitting the clustering cluster to which the first vehicle side belongs; When detecting the newly online second vehicle side, determining the clustering cluster to which the second vehicle side belongs.
[0011] After clustering all vehicle sides, this application considers the offline situation of the first vehicle side and merges or splits the affected clustering clusters; and considers the online situation of the second vehicle side, dividing the second vehicle side into the existing clustering clusters or creating a new clustering cluster for it. Thus, when the vehicle side frequently switches between the online and offline states, by dynamically adjusting the clustering clusters, the stability and adaptability of the training process are improved, and the applicable scenario range is wider.
[0012] In an alternative embodiment, intra-cluster training is performed according to the cluster model and data features corresponding to each clustering cluster to obtain the first gradient update parameter, including: According to the cluster model and the reconstructed features corresponding to the clustering cluster, obtaining a predicted value, and calculating the deviation value between the predicted value and the label of the local data; According to the deviation value, the predicted value, and the cluster model in the previous round of training, performing backpropagation to calculate and obtain the first gradient update parameter.
[0013] In this application, each clustering cluster in the cloud uses the reconstructed features similar to the features extracted by the vehicle side to train the cluster model of the clustering cluster, performs backpropagation based on the predicted value of the cluster model, the predicted deviation value, and the cluster model in the previous round of training in the current round, and calculates and obtains the first gradient update parameter of the cluster model, so as to update the cluster model in the cloud and the local model of the vehicle side. Thus, by using the computing resources of the cloud to perform the clustering and training steps, the vehicle side can update the local model by using the first gradient update parameter calculated by the cloud without training, reducing the computing pressure on the vehicle side.
[0014] In an alternative embodiment, the method further includes: Determining the average computing load of all vehicles, and based on the average computing load, dividing the preset complete model into a first model suitable for the cloud and a second model suitable for the vehicle side; Take the first model as the cluster model corresponding to each cluster in the first-round training, and take the second model as the local model applicable to the vehicle side in the first-round training.
[0015] Based on the average computing power of all vehicle sides, the cloud of this application dynamically divides the preset complete model into a first model applicable to the cloud and a second model applicable to the vehicle side, lightening the computing pressure on the vehicle side and ensuring that the computing resources of the vehicle side are sufficient to complete collaborative training with the cloud.
[0016] In an optional implementation manner, aggregating the updated local models uploaded by all vehicle sides to obtain an aggregated model, including: Performing federated averaging on the updated local models uploaded by all vehicle sides to obtain an aggregated model; wherein, the aggregated model is the local model applicable to the vehicle side in the next-round training.
[0017] This application performs federated averaging on the updated local models uploaded by all vehicle sides to obtain an aggregated model, realizes collaborative training between the cloud and the vehicle side, and sends the aggregated model to all vehicle sides for the next-round training.
[0018] In a second aspect, the present invention provides a split federated learning method based on the vehicle networking, which is applied to any vehicle side. This method includes multiple rounds of training, and each round of training includes: Receiving the local model applicable to the vehicle side sent by the cloud; Extracting data features from local data based on the local model, and uploading the extracted data features to the cloud, so that the cloud clusters all vehicle sides based on the data features to obtain multiple clusters, and performs intra-cluster training according to the cluster model and data features corresponding to each cluster to obtain first gradient update parameters, and updates the cluster model by using the first gradient update parameters; wherein, the cluster model and the local model in the first-round training are obtained by dividing the preset complete model. Receiving the first gradient update parameters sent by the cloud, calculating second gradient update parameters based on the first gradient update parameters and the data features, updating the local model by using the second gradient update parameters, and uploading the updated local model to the cloud, so that the cloud aggregates the updated local models uploaded by all vehicle sides to obtain an aggregated model; wherein, the aggregated model obtained in the last round of training is used to be deployed to all vehicle sides.
[0019] In this application, the preset complete model is partitioned using the cloud to obtain a local model applicable to the vehicle side and a cluster model applicable to the cloud side. The vehicle side extracts data features from local data using the local model distributed by the cloud and uploads them to the cloud. The cloud first clusters all vehicle sides using the data features to capture the non-independent and identically distributed characteristics of the vehicle-side data, and then performs intra-cluster training on the cluster model associated with each cluster based on the data features, calculates the first gradient update parameter for updating the cluster model, and sends it to the vehicle sides included in the corresponding cluster. Without local training, the vehicle side can calculate the second gradient update parameter by combining the first gradient update parameter and the local data features to update the local model, reducing the local computing and communication requirements of the vehicle side and achieving collaborative training of the global model. Finally, the cloud aggregates the updated local models of all vehicle sides to generate an aggregated model and deploys it to the vehicle side after the training is completed for the vehicle side to perform data collection work.
[0020] In an alternative embodiment, feature extraction is performed on local data based on the local model, and the extracted data features are uploaded to the cloud, including: The local model is used to convert local data into high-dimensional data features, and an encoder is used to compress the high-dimensional data features into low-dimensional data features; The low-dimensional data features, the decoder corresponding to the encoder, and the label of the local data are uploaded to the cloud, so that the cloud uses the decoder to reconstruct the low-dimensional data features to obtain reconstructed features, calculates the similarity between all pairs of vehicle sides based on the reconstructed features to obtain a similarity matrix, and clusters all vehicle sides based on the similarity matrix to obtain multiple clusters; each cluster includes at least one vehicle side.
[0021] The vehicle side of this application compresses the high-dimensional data features extracted from local data into low-dimensional data features, and by uploading the compressed low-dimensional data features to the cloud, greatly reduces the communication burden between the vehicle side and the cloud. And the vehicle side uploads the decoder to the cloud to ensure that the cloud can decode and reconstruct the low-dimensional data features to obtain reconstructed features similar to the extracted features of the vehicle side, so as to perform clustering analysis.
[0022] In an alternative embodiment, the method further includes: The decoder is used to reconstruct the low-dimensional data features to obtain reconstructed features; Based on the first gradient update parameter and the data features, calculating the second gradient update parameter includes: Based on the first gradient update parameter, the reconstructed features, the high-dimensional data features, and the local model in the previous round of training, perform backpropagation to calculate the second gradient update parameter.
[0023] In this application, by splitting the preset complete model, the vehicle side uses the local model for feature extraction, and the cloud side is responsible for the inference training of the cluster model, enabling the vehicle side to update the local model with the first gradient update parameters calculated by the cloud computing without training, effectively reducing the computational load of the vehicle side.
[0024] In a third aspect, the present invention provides a split federated learning system based on the vehicle network. The system includes a cloud side and multiple vehicle sides. In each round of interaction, the cloud side and the vehicle sides are used for: The cloud side sends the local model applicable to the vehicle sides to all vehicle sides; The vehicle sides receive the local model sent by the cloud side; based on the local model, perform feature extraction on the local data, and upload the extracted data features to the cloud side; The cloud side clusters all vehicle sides based on the data features to obtain multiple clustering clusters; performs intra-cluster training according to the cluster model and data features corresponding to each clustering cluster to obtain the first gradient update parameters; the cluster model and the local model in the first round of interaction are obtained by dividing the preset complete model; updates the cluster model with the first gradient update parameters; The vehicle sides receive the first gradient update parameters sent by the cloud side, calculate the second gradient update parameters based on the first gradient update parameters and the data features, update the local model with the second gradient update parameters, and upload the updated local model to the cloud side; The cloud side aggregates the updated local models uploaded by all vehicle sides to obtain an aggregated model; among them, the aggregated model obtained in the last round of interaction is used to be deployed to all vehicle sides.
[0025] In a fourth aspect, the present invention provides a computing device, including: a memory and a processor, which are communicatively connected to each other. The memory stores computer instructions, and the processor executes the computer instructions to execute the split federated learning method based on the vehicle network in the first aspect or any corresponding embodiment thereof, or execute the split federated learning method based on the vehicle network in the second aspect or any corresponding embodiment thereof.
[0026] The beneficial effects of the present invention are: The present invention divides a preset complete model using the cloud to obtain a local model applicable to the vehicle side and a cluster model applicable to the cloud side. The vehicle side extracts data features from local data using the local model distributed by the cloud and uploads them to the cloud. The cloud first clusters all vehicle sides using the data features to capture the non-independent and identically distributed characteristics of vehicle-side data, and then performs intra-cluster training on the cluster model associated with each cluster based on the data features, calculates the first gradient update parameter for updating the cluster model, and sends it to the vehicle sides included in the corresponding cluster. Without local training, the vehicle side can calculate the second gradient update parameter by combining the first gradient update parameter and local data features to update the local model, reducing the local computing and communication requirements of the vehicle side, achieving collaborative training of the global model, and having a wider range of application scenarios. Finally, the cloud aggregates the updated local models of all vehicle sides to generate an aggregated model and deploys it to the vehicle side after the training is completed for the vehicle side to perform data collection work.
[0027] Compared with traditional centralized data processing and training methods, the present application does not need to collect all vehicle data to a unified location for feature extraction and training, is less restricted by the network bandwidth, privacy and security requirements, and the massive data scale of the vehicle network, and is easier to deploy and implement.
[0028] Compared with most federated learning schemes that run a complete machine learning model locally on vehicles, the present application has lower requirements for real-time data processing, latency, security, and computing resources on the vehicle side.
[0029] Compared with the scheme of using vehicles to train part of the model and finally aggregating the model by the cloud, the present application does not require the vehicle side to perform model training. It only needs the vehicle side to extract features based on the local model, and the extracted data features will be uploaded to the cloud for the cloud to perform cluster model training, thereby reducing the local computing and communication requirements of the vehicle side and achieving collaborative training of the global model. Moreover, the present application considers the non-independent and identically distributed characteristics of data affected by different environments and driving behaviors of different vehicles in the vehicle network, and clusters the data features of the vehicle side using the cloud to fully capture data diversity. Description of the Drawings
[0030] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the following will briefly introduce the drawings required for use in the description of the specific embodiments or the prior art. Obviously, the following drawings are some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0031] Figure 1 is a structural block diagram of a split federated learning system based on a vehicle network according to an embodiment of the present invention; Figure 2 Schematic diagram of the interaction process of the split federated learning system according to an embodiment of the present invention; Figure 3 Schematic diagram of the interaction process of another split federated learning system according to an embodiment of the present invention; Figure 4 Schematic flowchart of a split federated learning method according to an embodiment of the present invention; Figure 5 Schematic diagram of the hardware structure of a computing device according to an embodiment of the present invention. Detailed implementation manners
[0032] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.
[0033] According to an embodiment of the present invention, a split federated learning system based on a vehicle networking is provided. As Figure 1 shown, the split federated learning system based on the vehicle networking includes: a cloud 101 and a plurality of vehicle terminals 102. The cloud 101 and the plurality of vehicle terminals 102 perform multiple rounds of interaction. Among them, the cloud 101 may be a cloud server. In each round of interaction, the cloud 101 and the vehicle terminals 102 are specifically used for: The cloud 101 sends a local model applicable to the vehicle terminals 102 to all the vehicle terminals 102.
[0034] The vehicle terminals 102 receive the local model sent by the cloud 101; extract data features from the local data based on the local model, and upload the extracted data features to the cloud 101.
[0035] The cloud 101 clusters all the vehicle terminals 102 based on the data features to obtain a plurality of clustering clusters; performs intra-cluster training according to the cluster model and data features corresponding to each clustering cluster to obtain first gradient update parameters, and updates the cluster model using the first gradient update parameters. Among them, the cluster model and the local model in the first round of interaction are obtained by dividing a preset complete model.
[0036] The vehicle terminals 102 receive the first gradient update parameters sent by the cloud 101, calculate second gradient update parameters based on the first gradient update parameters and the data features, update the local model using the second gradient update parameters, and upload the updated local model to the cloud 101.
[0037] The cloud 101 aggregates the updated local models uploaded by all vehicle terminals 102 to obtain an aggregated model; among them, the aggregated model obtained in the last round of interaction is used to be deployed to all vehicle terminals 102.
[0038] In the split federated learning system based on the vehicle network provided by the embodiments of the present invention, in each round of interaction between the cloud 101 and the vehicle terminal 102, the vehicle terminal 102 extracts data features in the local data by using the local model distributed by the cloud 101 and uploads them to the cloud 101. The cloud 101 first clusters all vehicle terminals 102 by using the data features to capture the non-independent and identically distributed characteristics of the data of the vehicle terminals 102, and then performs intra-cluster training on the cluster models associated with each clustering cluster based on the data features, calculates the first gradient update parameters for updating the cluster models, and sends them to the vehicle terminals 102 included in the corresponding clustering clusters. Without local training, the vehicle terminal 102 can calculate the second gradient update parameters by combining the first gradient update parameters and the local data features to update the local model, reducing the local computing and communication requirements of the vehicle terminal 102 and realizing the collaborative training of the global model, with a wider range of application scenarios. Finally, the cloud 101 aggregates the updated local models of all vehicle terminals 102, generates an aggregated model, and deploys it to the vehicle terminals after the training is completed, so that the vehicle terminals can perform data collection work.
[0039] For the specific working principle and working process of the cloud 101 and the vehicle terminal 102, refer to the relevant descriptions in the method embodiments below, and details will not be elaborated here.
[0040] According to the embodiments of the present invention, there is provided an embodiment of a split federated learning method based on a vehicle network. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order than here.
[0041] In this embodiment, there is provided a split federated learning method based on a vehicle network. This split federated learning method based on a vehicle network can be used for Figure 1 the cloud 101 and the vehicle terminal 102 as shown in Figure 2 FIG. 16 is a schematic diagram of the interaction process of the split federated learning system based on the vehicle network according to the embodiments of the present invention. Among them, the cloud 101 is used to execute steps S101 to S105, and the vehicle terminal 102 is used to execute steps S201 to S203. The specific interaction process between the cloud 101 and the vehicle terminal 102 is as follows: Step S101: Send the local model applicable to the vehicle terminal to all vehicle terminals.
[0042] Specifically, to ensure that the computing resources of all vehicle terminals are sufficient for federated learning with the cloud, the preset complete model is dynamically partitioned to obtain a local model suitable for vehicle terminals and distributed to all vehicle terminals. The local model at least includes the module responsible for feature extraction in the preset complete model. In the first round of training, the cluster model in the cloud is the part of the preset complete model except the feature extraction module. The preset complete model can be a neural network model, a machine learning model, etc.
[0043] Step S201: Receive the local model suitable for vehicle terminals sent by the cloud.
[0044] Specifically, the vehicle terminal receives the local model uniformly sent by the cloud, and all vehicle terminals perform feature extraction based on the unified local model.
[0045] Step S202: Extract data features from local data based on the local model, and upload the extracted data features to the cloud.
[0046] Specifically, the local data of the vehicle terminal can be data from in-vehicle sensors, intelligent driving assistance systems, in-vehicle entertainment systems, and other vehicle terminal devices. The vehicle terminal uses the local model to extract data features from the local data and uploads the data features to the cloud for training.
[0047] Step S102: Cluster all vehicle terminals based on the data features to obtain multiple clustering clusters.
[0048] Specifically, for the non-independent and identically distributed problem of vehicle terminal data, the cloud clusters all vehicle terminals according to the data features uploaded by each vehicle terminal. Vehicle terminals with similar data features will be assigned to the same clustering cluster, and each clustering cluster is associated with at least one vehicle terminal.
[0049] Step S103: Perform intra-cluster training according to the cluster model and data features corresponding to each clustering cluster to obtain the first gradient update parameter.
[0050] Specifically, the local model of the vehicle terminal interacts with the cluster model corresponding to the clustering cluster to which the vehicle terminal belongs. The data features extracted by the local model are uploaded to the cluster model corresponding to the cloud clustering cluster, forming intra-cluster collaborative training between the local model of the vehicle terminal and the cluster model of the cloud clustering cluster. The cloud is used to train the cluster model of each clustering cluster, thereby obtaining the first gradient update parameter required for cluster model update.
[0051] Step S104: Update the cluster model using the first gradient update parameter and send the first gradient update parameter to the corresponding vehicle terminal.
[0052] Specifically, for the first gradient update parameter corresponding to the cluster model of each cluster, the first gradient update parameter is sent to the vehicle terminals included in the cluster.
[0053] Step S203: Receive the first gradient update parameter sent by the cloud. Based on the first gradient update parameter and the data features, calculate the second gradient update parameter. Use the second gradient update parameter to update the local model, and upload the updated local model to the cloud.
[0054] Specifically, since the cluster model and the local model are obtained by dividing a preset complete model, the first gradient update parameter during the update of the cloud cluster model can be combined with the data features of the vehicle terminals to calculate the second gradient update parameter required for the update of the local model.
[0055] In the embodiment of the present application, by dividing the preset complete model into a local model applicable to the vehicle terminals and a cluster model applicable to the cloud, the vehicle terminals use the local model for feature extraction, and the cloud clusters all vehicle terminals using the data features uploaded by the vehicle terminals, and perform intra-cluster training on the cluster model corresponding to each cluster, thereby reducing the computational pressure on the vehicle terminals. Moreover, the vehicle terminals can update their own local models using the first gradient update parameter sent by the cloud without local training, further reducing the requirements for the computational resources required for collaborative training of the vehicle terminals, and having stronger applicability.
[0056] Step S105: Aggregate the updated local models uploaded by all vehicle terminals to obtain an aggregated model; among them, the aggregated model obtained in the last round of training is used to be deployed to all vehicle terminals.
[0057] Specifically, the cloud generates an aggregated model by aggregating the updated local models of all vehicle terminals. After the training is completed, the aggregated model is deployed on all vehicle terminals for the vehicle terminals to perform data collection work.
[0058] Compared with the traditional centralized data processing and training methods, the present application does not need to collect all vehicle data to a unified location for feature extraction and training, is less restricted by the network bandwidth, privacy and security requirements of the vehicle network and the scale of massive data, and is easier to deploy and implement.
[0059] Compared with most federated learning solutions that run a complete machine learning model locally on vehicles, the present application has lower requirements for real-time data processing, latency, security and computational resources of vehicle terminals.
[0060] Compared with the solution of using vehicles to train part of the model and finally aggregating the models by the cloud, this application does not require the vehicle side to perform model training. It only needs the vehicle side to extract data features based on the local model, and the extracted data features will be uploaded to the cloud, where the cloud will perform the training of the cluster model, thereby reducing the local computing and communication requirements of the vehicle side and realizing the collaborative training of the global model. Moreover, this application takes into account the non-independent and identically distributed characteristics of data caused by different vehicles in the vehicle network being affected by different environments and driving behaviors, and uses the cloud to cluster the data features of the vehicle side to fully capture data diversity.
[0061] The split federated learning method based on the vehicle network provided in this embodiment uses the cloud to divide a preset complete model to obtain a local model applicable to the vehicle side and a cluster model applicable to the cloud. The vehicle side uses the local model distributed by the cloud to extract data features in the local data and uploads them to the cloud. The cloud first clusters all vehicle sides using the data features to capture the non-independent and identically distributed characteristics of the vehicle-side data, and then performs intra-cluster training on the cluster model associated with each cluster based on the data features, calculates the first gradient update parameter for updating the cluster model, and sends it to the vehicle sides included in the corresponding cluster. The vehicle side can update the local model by combining the first gradient update parameter and the local data features without local training, reducing the local computing and communication requirements of the vehicle side and realizing the collaborative training of the global model, with a wider range of application scenarios. Finally, the cloud aggregates the updated local models of all vehicle sides to generate an aggregated model and deploys it to the vehicle side after the training is completed for the vehicle side to perform data collection work.
[0062] In this embodiment, a split federated learning method based on the vehicle network is provided. The split federated learning method based on the vehicle network can be used for the cloud 101 and the vehicle side 102 as shown in Figure 1 Figure 10, Figure 3 is a schematic diagram of the interaction process of the split federated learning system based on the vehicle network according to an embodiment of the present invention. Among them, the cloud 101 is used to execute steps S301 to S307, and the vehicle side 102 is used to execute steps S401 to S405. The specific interaction process between the cloud 101 and the vehicle side 102 is as follows: Step S301, send the local model applicable to the vehicle side to all vehicle sides.
[0063] Specifically, before the first round of interaction between the cloud and the vehicle side, the split federated learning system based on the vehicle network is initialized first, and the system initialization includes dividing the preset complete model.
[0064] In some optional implementation manners, the cloud determines the average computing load of all vehicles, and based on the average computing load, divides the preset complete model into a first model applicable to the cloud and a second model applicable to the vehicle side . The cloud dynamically adjusts the segmentation point of the preset complete model according to the average computing load of all vehicle sides, and dynamically divides the preset complete model into a first model and a second model .
[0065] In some embodiments, the second model at least includes the module responsible for feature extraction in the preset complete model, and the first model is the part of the preset complete model except the feature extraction module. The preset complete model can be a neural network model, a machine learning model, etc. At the beginning of the first round of interaction, the first model is used as the cluster model corresponding to each cluster in the first round of training, and the second model is used as the local model applicable to the vehicle side in the first round of training. The cloud broadcasts the initialized local model to all vehicle sides to establish a unified initial training benchmark.
[0066] In this embodiment, the cloud dynamically divides the preset complete model into a first model applicable to the cloud and a second model applicable to the vehicle side based on the average computing power of all vehicle sides, lightens the computing pressure on the vehicle side, and ensures that the computing resources of the vehicle side are sufficient to complete collaborative training with the cloud.
[0067] Step S401, receive the local model applicable to the vehicle side sent by the cloud. For specific details, please refer to Figure 2 the detailed description of step S201 in the illustrated embodiment, which will not be elaborated here.
[0068] Step S402, use the local model to convert local data into high-dimensional data features, use an encoder to compress the high-dimensional data features into low-dimensional data features, and use the decoder corresponding to the encoder to reconstruct the low-dimensional data features to obtain reconstructed features.
[0069] Specifically, for the i th vehicle side , the vehicle side performs forward propagation calculation on the local model based on local data to calculate the high-dimensional data features , and the specific formula is as follows: (1) where is the local model of the vehicle side t in the th round of training, represents performing forward propagation calculation on the local model. Exemplarily, , where represents The corresponding weight denotes the corresponding bias vector
[0070] Furthermore, the vehicle side maps the high-dimensional data features to a low-dimensional feature space through an encoder so as to compress the high-dimensional data features into low-dimensional data features , and the specific formula is as follows (2) where denotes the encoding calculation
[0071] Even further, the vehicle side uses the decoder corresponding to the encoder F to reconstruct the compressed low-dimensional data features and generate reconstructed features approximating the high-dimensional data features , and the specific formula is as follows (3) where denotes the decoding calculation
[0072]
[0072] In some alternative embodiments, during each round of training, the vehicle side calculates the variance loss function and optimizes the parameters of the encoder and the decoder F by minimizing the variance loss function G in multiple rounds of training. Among them, the specific formula of the variance loss function is as follows (4) where denotes the number of features denotes the vehicle side the high-dimensional data feature the j th feature data denotes the vehicle side the reconstructed feature the j th feature data
[0073] It should be noted that the number of rounds required for the encoder F and the decoder G to converge is much less than the maximum number of iterations required for split federated learning T . Generally, the encoderF Decoder G It can converge during the 4th to 5th rounds of training.
[0074] Step S403: Upload the low-dimensional data features, the decoder, and the labels of the local data to the cloud.
[0075] Specifically, the local data refers to the data collected by the vehicle terminal and stored locally. On the premise of compliance and privacy protection, the vehicle terminal sends the stored local data to the data administrator through an encrypted channel. The local data is manually labeled by the administrator, and the labels of the local data are set and returned to the corresponding vehicle terminal in an encrypted manner. Taking the image data collected by the camera as the local data as an example, the bounding box area in the image data is manually labeled to set the label of the image data. The label of the image data can be "pedestrian", "vehicle", "obstacle", etc.
[0076] In some embodiments, the vehicle terminal can also use the unsupervised learning model deployed on itself to automatically label the labels of the local data. For specific references, please refer to the description of related technologies and will not be elaborated here.
[0077] Specifically, the vehicle terminal will store the local data and the labels of the local data. After the vehicle terminal converts and compresses the local data into low-dimensional data features, the vehicle terminal uploads the decoder G , the low-dimensional data features and the local data labels to the cloud.
[0078] Step S302: Use the decoder to reconstruct the low-dimensional data features to obtain reconstructed features.
[0079] Specifically, the cloud uses the decoder G to reconstruct the low-dimensional data features to obtain the reconstructed features , that is . It should be noted that in the case of no data transmission error or decoding error, the reconstructed features on the cloud and the reconstructed features on the vehicle terminal are consistent.
[0080] Step S303: Calculate the similarity between every two vehicle terminals according to the reconstructed features to obtain a similarity matrix, and cluster all vehicle terminals according to the similarity matrix to obtain multiple clusters; where each cluster contains at least one vehicle terminal.
[0081] Specifically, the cloud can construct a similarity matrix with a size of , represents the total number of active vehicles and initializes the similarity matrix . Based on the reconstructed features, the cloud calculates the cosine similarity between the vehicle side and the vehicle side . Among them, the calculation formula of the cosine similarity is as follows: (5) Among them, represents the reconstructed feature of the vehicle side .
[0082] Furthermore, by calculating the similarity between vehicle sides pairwise, the similarity matrix is maintained, and all vehicle sides are clustered using the similarity matrix to obtain multiple clustering clusters. The specific clustering process can refer to the detailed description of related technologies and will not be elaborated here.
[0083] In some embodiments, the cloud determines the clustering cluster to which each vehicle side belongs, assigns a unique cluster identifier to the vehicle side , determines the cluster model t corresponding to the clustering cluster in the th round of training, and maintains . Among them, in the first round of training, the cluster model of each clustering cluster is the first model obtained by the cloud's division of the preset complete model.
[0084] In some embodiments, the cloud establishes a dynamic binding relationship between the local model of the vehicle side and the cluster model of the clustering cluster to which the vehicle side belongs according to the cluster identifier of the vehicle side , that is , where .
[0085] In the embodiments of the present application, the vehicle side compresses the high-dimensional data features extracted from local data into low-dimensional data features, and by uploading the compressed low-dimensional data features to the cloud, the communication burden between the vehicle side and the cloud is greatly reduced. And the vehicle side uploads a decoder to the cloud to ensure that the cloud can decode and reconstruct the low-dimensional data features to obtain reconstructed features approximating the extracted features of the vehicle side, so as to perform clustering analysis on all vehicle sides and capture the non-independent and identically distributed characteristics of vehicle data.
[0086] In some alternative embodiments, when detecting the offline first vehicle side, the clustering cluster to which the first vehicle side belongs is merged or split.
[0087] Specifically, when the vehicle terminal exits the connection with the cloud, that is, when the first vehicle terminal is detected to be offline, the entries corresponding to the first vehicle terminal in the similarity matrix are deleted, and the affected clustering clusters are re-evaluated to determine whether the merging or splitting conditions are met. In some embodiments, after the first vehicle terminal exits, the average cosine distance between the clustering cluster to which the first vehicle terminal belongs and other clustering clusters is calculated. When the average cosine distance between two clustering clusters is less than the set merging threshold
[0088] it indicates that the clustering cluster to which the first vehicle terminal belongs can be merged with other clustering clusters. Among them, the calculation formula of the average cosine distance is as follows: When it is less than the set merging threshold, it means that the clustering cluster to which the first vehicle terminal belongs can be merged with other clustering clusters. Among them, the calculation formula of the average cosine distance is as follows: (6) where represents the average cosine distance between the clustering cluster and the clustering cluster
[0089] In some embodiments, for the clustering clusters that meet the merging conditions, that is the cloud uses the federated averaging algorithm to generate a new cluster model for the clustering cluster : of (7) In this embodiment, when the first vehicle terminal is offline, the clustering cluster to which the first vehicle terminal belongs is merged with other clustering clusters, and the cluster model of the new clustering cluster is determined to realize the dynamic adjustment of the clustering cluster.
[0090] In some embodiments, after the first vehicle terminal exits, it is determined whether the clustering cluster to which the first vehicle terminal belongs meets the splitting conditions. When the clustering cluster meets the following splitting conditions, the splitting operation is performed: (8) where represents the set splitting threshold, represents the within-cluster sum of squares of the clustering cluster and represents the centroid of the clustering cluster
[0091] Furthermore, for the clustering cluster that meets the splitting conditions, the cloud calculates the average within-cluster sum of squares after removing the first vehicle terminal . If , then the first vehicle terminal Marked for removal. Repeat the above process for each first vehicle terminal in the offline vehicle terminal set until there is no first vehicle terminal that can further reduce the average within-cluster sum of squares.
[0092] In this embodiment, when the first vehicle terminal is offline, the clustering cluster to which the first vehicle terminal belongs is split to achieve dynamic adjustment of the clustering cluster.
[0093] In some alternative embodiments, when a newly online second vehicle terminal is detected, the clustering cluster to which the second vehicle terminal belongs is determined.
[0094] Specifically, when the new second vehicle terminal joins the vehicle network, that is, when the second vehicle terminal is detected to be online, the cloud calculates the cosine similarity between the second vehicle terminal and the existing vehicle terminals : (9) Furthermore, if the cosine similarity between the second vehicle terminal and the existing vehicle terminals is greater than the maximum cosine similarity exceeding the set similarity threshold , then the second vehicle terminal is assigned to the clustering cluster where the vehicle terminal is located; otherwise, a new clustering cluster containing the second vehicle terminal is created, and the cluster model of this new clustering cluster can be the first model .
[0095] For the problem of non-independent and identically distributed data, various personalized strategies have been proposed in related technologies. For example, the multi-task learning method is used to regard the data collected by each vehicle as multiple tasks that are related but different; the model interpolation technology realizes the trade-off between the model generalization ability and the personalized specialization by balancing the influence of the global model and the local model; the clustering-based joint learning method groups vehicles with similar data features to further improve the adaptability of the model to the non-independent and identically distributed data environment.
[0096] Although related technologies have improved the training performance of the model in non-independent and identically distributed scenarios to a certain extent, they often assume that the vehicle population is in a static state or require high computational resources. In the face of the actual dynamic environment where vehicles go online or offline frequently, their scalability and stability are significantly restricted.
[0097] In the embodiments of the present application, after clustering all vehicle terminals, the offline situation of the first vehicle terminal is considered, and the affected clustering clusters are merged or split; and the online situation of the second vehicle terminal is considered, and the second vehicle terminal is divided into an existing clustering cluster or a new clustering cluster is created for it. Thus, when the vehicle terminal frequently switches between the online and offline states, the stability and adaptability of the training process are improved by dynamically adjusting the clustering clusters, and the applicable scenario range is wider.
[0098] Step S304: Obtain a predicted value according to the cluster model and the reconstructed feature corresponding to the clustering cluster, and calculate the deviation value between the predicted value and the label of the local data.
[0099] Specifically, the local model of the vehicle terminal performs parameter interaction with the cluster model corresponding to the clustering cluster to which it belongs. The high-dimensional data features extracted by the local model are compressed and uploaded to the cloud for decoding and reconstruction after compression. The obtained reconstructed features are input into the corresponding cluster model, forming collaborative training between the local model of the vehicle terminal and the cluster model of the cloud clustering cluster.
[0100] In some embodiments, the cloud performs intra-cluster training for each clustering cluster For each vehicle terminal in the clustering cluster , based on the reconstructed feature perform forward propagation calculation on the cluster model to obtain a predicted value , where represents performing forward propagation calculation on the cluster model. Exemplarily, , where represents the corresponding weight, represents the corresponding bias vector. And the prediction deviation is evaluated through the following loss function L: (10) where represents the predicted value and the label of the local data the deviation value between them.
[0101] Step S305: Perform backpropagation according to the deviation value, the predicted value, and the cluster model in the previous round of training to calculate and obtain the first gradient update parameter.
[0102] Specifically, the first gradient update parameter can be calculated according to the following formula: (11) where represents the clustering cluster in the The first gradient update parameter in the round of training indicating the cluster model corresponding to the cluster in the round of training
[0103] In the embodiment of the present application, each cluster in the cloud uses the reconstructed features approximated to the features extracted by the vehicle side to train the cluster model of the cluster. Based on the predicted value of the cluster model, the predicted deviation value, and the cluster model in the previous round of training in the current round, backpropagation is performed to calculate the first gradient update parameter of the cluster model, so as to update the cluster model in the cloud and the local model of the vehicle side. Thus, the clustering and training steps are executed using the computing resources of the cloud, enabling the vehicle side to update the local model using the first gradient update parameter calculated by the cloud without training, reducing the computing pressure on the vehicle side.
[0104] Step S306: Update the cluster model using the first gradient update parameter and send the first gradient update parameter to the corresponding vehicle side.
[0105] Specifically, the formula for updating the cluster model using the first gradient update parameter is as follows: (12) where represents the updated cluster model corresponding to the cluster and represents the set learning rate.
[0106] In some embodiments, the relevant information of the first gradient update parameter of the cluster is sent to the vehicle side belonging to the cluster .
[0107] Step S404: Receive the first gradient update parameter sent by the cloud, and perform backpropagation based on the first gradient update parameter, the reconstructed features, the high-dimensional data features, and the local model in the previous round of training to calculate the second gradient update parameter.
[0108] Specifically, the calculation formula of the second gradient update parameter is as follows: (13) where represents the second gradient update parameter of the vehicle side in the round of training, represents the round of training, and represents the local model of the vehicle side
[0109] Step S405: Update the local model using the second gradient to update the parameters, and upload the updated local model to the cloud.
[0110] Specifically, the formula for updating the local model using the second gradient to update the parameters is as follows: (14) where represents the updated local model at the vehicle side of the vehicle.
[0111] In this application, by splitting the preset complete model, the vehicle side uses the local model for feature extraction, and the cloud is responsible for the inference training of the cluster model, enabling the vehicle side to update the local model using the first gradient updated by the cloud computing without training, effectively reducing the computational load of the vehicle side.
[0112] Step S307: Perform federated averaging on the updated local models uploaded by all vehicle sides to obtain an aggregated model; among them, the aggregated model is the local model applicable to the vehicle side in the next round of training, and the aggregated model obtained in the last round of training is used to be deployed to all vehicle sides.
[0113] Specifically, the cloud receives the updated model parameters of all vehicle sides , and uses the federated averaging algorithm to generate an aggregated model , and the calculation formula can be as follows: (15) where represents the number of vehicle sides that upload the updated local model.
[0114] Furthermore, distribute the aggregated model to each vehicle side as the training benchmark for the next round of training to complete the federated learning closed loop. Repeat the above interaction process until the training round reaches the maximum number of iterations .
[0115] In the embodiment of this application, perform federated averaging on the updated local models uploaded by all vehicle sides to obtain an aggregated model, realizing the collaborative training between the cloud and the vehicle side, and sending the aggregated model to all vehicle sides for the next round of training.
[0116] The split federated learning method based on the vehicle network provided in this embodiment performs model training based on split federated learning, divides the preset complete model into front-end feature extraction at the vehicle side and back-end inference at the cloud, compresses the high-dimensional data features extracted by the vehicle side into low-dimensional data features and uploads them to the cloud for inference training, which can effectively reduce the computational load of the vehicle side and the system communication pressure, and at the same time ensure the data privacy of users.
[0117] In view of the non - independent and identically - distributed heterogeneous vehicle data, the dynamic change of the online status of the vehicle terminal, and the bandwidth limitation in the vehicle - to - everything (V2X) scenario, this application dynamically adjusts the clustering clusters in the cloud according to the offline or online situation of the vehicle terminal, so as to realize the collaborative update of the cluster model and the local model, significantly improving the training effect and speed in the heterogeneous environment, being applicable to complex application scenarios, and having stronger scalability and adaptability.
[0118] The split federated learning based on the vehicle - to - everything (V2X) of the present invention will be described in detail below in combination with a specific application example. As Figure 4 shown, this application example includes the following steps: Step 1, system initialization.
[0119] Step 1.1, the cloud dynamically adjusts the splitting point of the preset complete model according to the average computing load of all vehicle terminals, and dynamically splits the preset complete model into a first model and a second model to ensure the computing pressure of lightweight vehicle terminals.
[0120] Step 1.2, the cloud broadcasts the initialized local model, which is the second model applicable to vehicle terminals in the first - round training, to all vehicle terminals to establish a unified initial training benchmark.
[0121] Step 1.3, the cloud can construct a similarity matrix and initialize the similarity matrix .
[0122] Step 2: Auto - encoder training.
[0123] Step 2.1, the vehicle terminal performs forward - propagation calculation on the local model based on local data to calculate high - dimensional data features .
[0124] Step 2.2, the vehicle terminal maps the high - dimensional data features to the low - dimensional feature space through the encoder to compress the high - dimensional data features into low - dimensional data features .
[0125] Step 2.3, the vehicle terminal uses the decoder F corresponding to the encoder to reconstruct the compressed low - dimensional data features to generate reconstructed features approximate to the high - dimensional data features .
[0126] Step 2.4, during each round of training, on the vehicle side Calculate the variance loss function , and optimize the encoder by minimizing the variance loss function over multiple rounds of training F and the decoder G parameters.
[0127] Step 2.5, on the vehicle side Upload the decoder G , the low-dimensional data features and the local data labels to the cloud.
[0128] Step 3: Clustering management.
[0129] Step 3.1, the cloud uses the decoder G to reconstruct the low-dimensional data features to obtain the reconstructed features .
[0130] Step 3.2, the cloud maintains the similarity matrix by calculating the similarity between vehicle sides pairwise, and clusters all vehicle sides using the similarity matrix to obtain multiple clusters.
[0131] Specifically, when a new second vehicle side joins, the cloud calculates the cosine similarity between the second vehicle side and the existing vehicle sides . If the maximum cosine similarity between the second vehicle side and the existing vehicle sides exceeds the set similarity threshold , then the second vehicle side is assigned to the cluster where the vehicle side is located; otherwise, a new cluster containing the second vehicle side is created .
[0132] Specifically, when the first vehicle side exits, delete the corresponding entry of the first vehicle side in the similarity matrix , and re-evaluate the affected clusters to determine whether they meet the merge or split conditions. For the clusters that meet the merge conditions, the cloud uses the federated averaging algorithm to generate new clusters cluster model
[0133] Specifically, for a clustering cluster that meets the splitting condition, the cloud calculates the average within-cluster sum of squares after removing the first vehicle end . If , the first vehicle end is marked for removal, and the above process is repeated until there is no first vehicle end that can further reduce the average within-cluster sum of squares .
[0134] Step 4: Model binding
[0135] Step 4.1, the cloud assigns a unique cluster identifier to the vehicle end , determines the cluster model corresponding to the clustering cluster in the th round of training t , and maintains . .
[0136] Step 4.2, the cloud establishes a dynamic binding relationship between the local model of the vehicle end and the cluster model of the clustering cluster to which the vehicle end belongs according to the cluster identifier of the vehicle end , that is , ensuring that the vehicle end only collaboratively trains with the cluster model of the clustering cluster to which it belongs .
[0137] Step 5: Model collaborative training and aggregation
[0138] Step 5.1, the cloud performs in-cluster training for each clustering cluster . For each vehicle end in the clustering cluster , a forward propagation calculation is performed on the cluster model based on the reconstructed features to obtain a predicted value . The prediction deviation is evaluated through the loss function L and the first gradient update parameter is calculated through backpropagation . The cluster model of the clustering cluster is updated using the first gradient update parameter . The cloud sends the first gradient update parameter to the vehicle ends in the clustering cluster .
[0139] Step 5.2, the vehicle end receives the first gradient update parameter sent by the cloud , calculates the second gradient update parameter required for local model update , and uses the second gradient update parameter Update the local model.
[0140] In step 5.3, the cloud receives the updated model parameters of all vehicle terminals , and uses the federated averaging algorithm to generate an aggregated model .
[0141] In step 5.4, the aggregated model is sent to each vehicle terminal as the initialization benchmark for the next round of training, completing the federated learning loop.
[0142] Repeat the above steps 2 to 5 until the maximum number of training iterations is reached .
[0143] In view of the problem of non-independent and identically distributed data in the vehicle networking environment, the present invention clusters vehicle terminals, assigns vehicles with similar data characteristics to the same cluster, and customizes different cluster models for each cluster, thereby significantly improving the performance and adaptability of the overall model. At the same time, in order to cope with the dynamic characteristics of frequent online and offline of vehicles in vehicle networking, a clustering management mechanism is introduced, which can efficiently achieve the merging and splitting between clusters. In addition, feature compression is used to reduce the communication overhead during data transmission.
[0144] An embodiment of the present invention further provides a computing device, which can be applied to the cloud 101 or the vehicle terminal 102 shown above Figure 1 .
[0145] Please refer to Figure 5 , Figure 5 which is a schematic structural diagram of a computing device provided by an optional embodiment of the present invention. As shown in Figure 5 , the computing device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including a high-speed interface and a low-speed interface. Each component communicates with each other using different buses and can be installed on a common motherboard or installed in other ways as needed. The processor can process instructions executed within the computing device, including instructions stored in the memory or on the memory to display graphical information of the GUI on an external input / output device (such as a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computing devices can be connected, and each device provides some necessary operations (such as a server array, a set of blade servers, or a multi-processor system). Figure 5 In
[0146] The processor 10 may be a central processing unit, a network processor, or a combination thereof. Among them, the processor 10 may further include a hardware chip. The above-mentioned hardware chip may be an application-specific integrated circuit, a programmable logic device, or a combination thereof. The above-mentioned programmable logic device may be a complex programmable logic device, a field programmable gate array, a generic array logic, or any combination thereof.
[0147] Among them, the memory 20 stores instructions executable by at least one processor 10, so that the at least one processor 10 executes the method shown in the above embodiments.
[0148] The memory 20 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system and application programs required for at least one function; the data storage area may store data created according to the use of the computing device, etc. In addition, the memory 20 may include a high-speed random access memory, and may further include a non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state storage devices. In some alternative embodiments, the memory 20 may optionally include a memory remotely provided with respect to the processor 10, and these remote memories may be connected to the computing device through a network. Examples of the above network include but are not limited to the Internet, an enterprise intranet, a local area network, a mobile communication network, and combinations thereof.
[0149] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk, or a solid-state drive; the memory 20 may further include a combination of the above types of memories.
[0150] The computing device further includes a communication interface 30 for the computing device to communicate with other devices or communication networks.
[0151] The embodiments of the present invention also provide a computer-readable storage medium. The method according to the embodiments of the present invention can be implemented in hardware, firmware, or be implemented as computer code that can be recorded on a storage medium, or be implemented as computer code originally stored in a remote storage medium or a non-temporary machine-readable storage medium and downloaded through a network and will be stored in a local storage medium, so that the method described herein can be stored in such software processed on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium may be a magnetic disk, an optical disc, a read-only memory, a random access memory, a flash memory, a hard disk, or a solid-state drive, etc.; further, the storage medium may further include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code, and when the software or computer code is accessed and executed by the computer, the processor, or the hardware, the method shown in the above embodiments is implemented.
[0152] A part of the present invention can be applied as a computer program product, for example, computer program instructions, which, when executed by a computer, can call or provide the method or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the forms of existence of computer program instructions in a computer-readable medium include but are not limited to source files, executable files, installation package files, etc. Correspondingly, the ways in which computer program instructions are executed by a computer include but are not limited to: the computer directly executes the instructions, or the computer compiles the instructions and then executes the corresponding compiled program, or the computer reads and executes the instructions, or the computer reads and installs the instructions and then executes the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium accessible to the computer.
[0153] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations all fall within the scope defined by the appended claims.
Claims
1. A split federated learning method based on the vehicle networking, applied to the cloud, characterized in that The method includes multiple rounds of training, and each round of training includes: Sending a local model applicable to the vehicle side to all vehicle sides, so that each vehicle side extracts data features from local data based on the local model and uploads the extracted data features to the cloud; Clustering all vehicle sides based on the data features to obtain multiple clustering clusters; Performing in-cluster training according to the cluster model and data features corresponding to each clustering cluster to obtain first gradient update parameters; the cluster model and the local model in the first round of training are obtained by dividing a preset complete model; Updating the cluster model using the first gradient update parameters and sending the first gradient update parameters to the corresponding vehicle sides, so that the corresponding vehicle sides calculate second gradient update parameters based on the first gradient update parameters and the data features, update the local model using the second gradient update parameters, and upload the updated local model to the cloud; Aggregating the updated local models uploaded by all vehicle sides to obtain an aggregated model; the aggregated model obtained in the last round of training is used to be deployed to all vehicle sides.
2. The split federated learning method based on vehicle networking according to claim 1, wherein The data features include low-dimensional data features, a decoder, and labels of local data, where the low-dimensional data features are obtained by compressing the high-dimensional data features using an encoder corresponding to the decoder after the vehicle side converts the local data into high-dimensional data features using the local model; The clustering all vehicle sides based on the data features to obtain multiple clustering clusters includes: Reconstructing the low-dimensional data features using the decoder to obtain reconstructed features; Calculating the similarity between all vehicle sides pairwise according to the reconstructed features to obtain a similarity matrix, and clustering all vehicle sides according to the similarity matrix to obtain multiple clustering clusters; where each clustering cluster includes at least one vehicle side.
3. The split federated learning method based on the vehicle networking according to claim 2, wherein The method further includes: When detecting a first vehicle side that is offline, merging or splitting the clustering cluster to which the first vehicle side belongs; When detecting a newly online second vehicle side, determining the clustering cluster to which the second vehicle side belongs.
4. The split federated learning method based on vehicle networking according to claim 2, characterized in that, The performing in-cluster training according to the cluster model and data features corresponding to each clustering cluster to obtain first gradient update parameters includes: Obtaining a predicted value according to the cluster model and the reconstructed features corresponding to the clustering cluster, and calculating the deviation value between the predicted value and the label of the local data; Performing backpropagation according to the deviation value, the predicted value, and the cluster model in the previous round of training to calculate and obtain first gradient update parameters.
5. The split federated learning method based on the vehicle Internet of Things according to claim 1, wherein The method further includes: Determining the average computing load of all vehicles, and based on the average computing load, dividing a preset complete model into a first model applicable to the cloud and a second model applicable to the vehicle side; Using the first model as the cluster model corresponding to each clustering cluster in the first round of training, and using the second model as the local model applicable to the vehicle side in the first round of training.
6. The split federated learning method based on vehicle networking according to claim 5, wherein, The aggregating the updated local models uploaded by all vehicle sides to obtain an aggregated model includes: Perform federated averaging on the updated local models uploaded by all vehicle terminals to obtain an aggregated model; wherein, the aggregated model is the local model applicable to the vehicle terminals in the next round of training.
7. A split federated learning method based on the vehicle networking, which is applied to any vehicle terminal, is characterized in that, The method includes multiple rounds of training, and each round of training includes: Receiving the local model applicable to the vehicle terminals sent by the cloud; Performing feature extraction on local data based on the local model, and uploading the extracted data features to the cloud, so that the cloud clusters all vehicle terminals based on the data features to obtain multiple clustering clusters, and performing intra-cluster training according to the cluster model and data features corresponding to each clustering cluster to obtain first gradient update parameters, and updating the cluster model using the first gradient update parameters; wherein, the cluster model and the local model in the first round of training are obtained by dividing a preset complete model. Receiving the first gradient update parameters sent by the cloud, calculating second gradient update parameters based on the first gradient update parameters and the data features, updating the local model using the second gradient update parameters, and uploading the updated local model to the cloud, so that the cloud aggregates the updated local models uploaded by all vehicle terminals to obtain an aggregated model; wherein, the aggregated model obtained in the last round of training is used to be deployed to all vehicle terminals.
8. The split federated learning method based on the vehicle networking according to claim 7, wherein The performing feature extraction on local data based on the local model and uploading the extracted data features to the cloud includes: Converting the local data into high-dimensional data features using the local model, and compressing the high-dimensional data features into low-dimensional data features using an encoder; Uploading the low-dimensional data features, the decoder corresponding to the encoder, and the label of the local data to the cloud, so that the cloud reconstructs the low-dimensional data features using the decoder to obtain reconstructed features, calculates the similarity between all vehicle terminals pairwise based on the reconstructed features to obtain a similarity matrix, and clusters all vehicle terminals based on the similarity matrix to obtain multiple clustering clusters; wherein, each clustering cluster includes at least one vehicle terminal.
9. The split federated learning method based on vehicle networking according to claim 8, wherein, The method further includes: Reconstructing the low-dimensional data features using the decoder to obtain reconstructed features; The calculating second gradient update parameters based on the first gradient update parameters and the data features includes: Performing backpropagation based on the first gradient update parameters, the reconstructed features, the high-dimensional data features, and the local model in the previous round of training to calculate the second gradient update parameters.
10. A split federated learning system based on the vehicle networking, characterized in that, The system includes a cloud and multiple vehicle terminals. The cloud and the vehicle terminals are used in each round of interaction for: The cloud sending the local model applicable to the vehicle terminals to all vehicle terminals; The vehicle terminals receiving the local model sent by the cloud; performing feature extraction on local data based on the local model, and uploading the extracted data features to the cloud; The cloud clustering all vehicle terminals based on the data features to obtain multiple clustering clusters; performing intra-cluster training according to the cluster model and data features corresponding to each clustering cluster to obtain first gradient update parameters; the cluster model and the local model in the first round of interaction are obtained by dividing a preset complete model; updating the cluster model using the first gradient update parameters; The vehicle side receives the first gradient update parameter sent by the cloud, calculates the second gradient update parameter based on the first gradient update parameter and the data features, updates the local model using the second gradient update parameter, and uploads the updated local model to the cloud; The cloud aggregates the updated local models uploaded by all vehicle sides to obtain an aggregated model; among them, the aggregated model obtained in the last round of interaction is used to be deployed to all vehicle sides.
11. A computing device, characterized in that, It includes: A memory and a processor, the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the computer instructions to execute the split federated learning method based on the vehicle network according to any one of claims 1 to 6, or executes the split federated learning method based on the vehicle network according to any one of claims 7 to 9.
Citation Information
Patent Citations
Data screening method and device, electronic equipment and computer storage medium
CN115294368A
Industrial robot fault diagnosis method and system based on federated learning
CN116415506A
Clustering federal learning method based on perception of data difference between clients
CN117494846A
GNN-based semi-federated learning system and operation method thereof
CN117592556A
Multi-task processing system for realizing graph federation transfer learning based on graph subtree difference
CN118036706A
Cited By
Alliance-based Internet of Vehicles federal learning method, system and device
CN121935758A