Edge scene-oriented prediction method based on space-time quantum federated learning

By constructing a spatiotemporal graph and quantum state encoding for edge device clusters, the problem of non-independent and identically distributed data in traditional federated learning is solved, enabling efficient model training and prediction in edge computing architectures and improving the convergence speed and generalization performance of the models.

CN121503589AActive Publication Date: 2026-02-10CHINA TOWER CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202610018463.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-01-08
Publication Date
2026-02-10
Estimated Expiration
2046-01-08

AI Technical Summary

Technical Problem

Traditional federated learning methods assume that edge device data is independent and identically distributed, resulting in poor model generalization performance and unstable global model convergence. Existing quantum federated solutions rely on real quantum hardware, have high deployment thresholds, and are difficult to apply in conventional edge computing architectures.

Method used

By constructing a dual graph structure based on geographical distance and temporal similarity, spatiotemporal data of edge device clusters are obtained, client model parameters are encoded as quantum states, and dual pruning is performed using spatiotemporal correlation matrix and parameter difference matrix to filter target client set, generate global model, and perform dynamic aggregation and prediction.

Benefits of technology

It accurately captures the spatiotemporal dynamic patterns of edge data, improves the generalization performance of the global model, reduces communication overhead, enhances model convergence speed and generalization performance, and adapts to the narrow bandwidth and low computing power environment of edge devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121503589A_ABST
    Figure CN121503589A_ABST
Patent Text Reader

Abstract

The invention discloses an edge scene-oriented prediction method based on space-time quantum federated learning, relates to the technical field of federated learning, and aims to construct a space-time diagram of an edge device cluster by using space-time data and calculate a space-time incidence matrix, accurately capture a space-time dynamic mode of the edge data, and break through the limitation of neglecting space-time heterogeneity in a traditional method; the local model parameter of each client is coded into a quantum state, and the model parameter difference degree between any two clients in the edge device cluster is calculated, so that the communication overhead is further reduced, and the network resource consumption of the edge devices is greatly reduced; based on a double pruning strategy, a target client set is screened out from a plurality of clients by utilizing a space-time incidence matrix and a parameter difference matrix, and dynamic aggregation operation is executed to obtain a global model for scene prediction, so that remarkable advantages are shown in an edge computing architecture, space-time isomerism among equipment can be effectively processed, communication overhead is reduced, and the scene prediction efficiency is improved. And the convergence speed and generalization performance of the model are improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of federated learning, and in particular to a prediction method based on spatiotemporal quantum federated learning for edge scenarios. BACKGROUND

[0002] With the rapid development of edge computing technology, perception and decision-making tasks in the fields of intelligent driving, industrial Internet of Things, smart cities, etc. increasingly rely on AI models deployed on terminal devices. In order to utilize widely distributed edge data while protecting data privacy, federated learning, as a distributed machine learning paradigm, is widely used in model collaborative training in edge scenarios.

[0003] In related technologies, traditional federated learning algorithms such as FedAvg, FedProx, etc. mainly aggregate model updates of each client by direct averaging or weighted averaging to generate a global model. However, the applicant realizes that the traditional method generally assumes that the data generated by edge devices is independent and identically distributed, which makes it difficult for the trained model to capture real spatiotemporal dynamic patterns, and the generalization performance is severely limited. Secondly, the non-uniform data distribution of the traditional method leads to performance fluctuations of the global model in the spatiotemporal dimension, thereby affecting the convergence stability and final accuracy of the global model. In addition, some existing federated learning schemes that introduce quantum computing need to rely on real quantum hardware, which has a high practical threshold and is difficult to deploy in conventional edge computing architectures. SUMMARY

[0004] Therefore, the present application provides a prediction method based on spatiotemporal quantum federated learning for edge scenarios, which mainly aims to solve the problems of poor generalization performance and unstable convergence of the global model due to the assumption of independent and identically distributed data in traditional federated learning, and the high deployment threshold in conventional edge computing architectures due to the reliance on real quantum hardware in existing quantum federated schemes.

[0005] According to a first aspect of the present application, a prediction method based on spatiotemporal quantum federated learning for edge scenarios is provided, which comprises: obtaining spatiotemporal data of an edge device cluster and local model parameters of each client in the edge device cluster; constructing a dual graph structure based on geographical distance and temporal similarity using the spatiotemporal data to obtain a spatiotemporal graph of the edge device cluster, and calculating a spatiotemporal correlation matrix of the edge device cluster; encoding the local model parameters of each client into quantum states, and calculating the model parameter difference degree between any two clients in the edge device cluster using the quantum states of multiple clients to obtain a parameter difference matrix of the edge device cluster; Based on a dual pruning strategy, the spatiotemporal correlation matrix and the parameter difference matrix are used to filter out the target client set from the multiple clients, and a dynamic aggregation operation is performed on the local model parameters of the target client set to generate a global model. If the detection determines that the global model meets the model convergence condition, then the global model is used as the target global model for the edge device cluster. The real-time spatiotemporal data of the edge device cluster is obtained, and the real-time spatiotemporal data is input into the target global model for prediction to obtain the edge scene prediction result of the edge device cluster.

[0006] By employing the above technical solutions, the technical solutions provided in the embodiments of this application have at least the following advantages: This application provides a prediction method based on spatiotemporal quantum federated learning for edge scenarios. This method acquires spatiotemporal data of an edge device cluster and the local model parameters of each client within the cluster. It constructs a dual graph structure based on geographical distance and temporal similarity using the spatiotemporal data to obtain the spatiotemporal graph of the edge device cluster and calculates its spatiotemporal correlation matrix. The spatiotemporal data includes geographical coordinates and time-series data, accurately capturing the spatiotemporal dynamic patterns of edge data and overcoming the limitation of traditional methods that ignore spatiotemporal heterogeneity, thus improving the generalization performance of the global model. Next, the local model parameters of each client are encoded into quantum states. The model parameter difference degree between any two clients in the edge device cluster is calculated using the quantum states of multiple clients, resulting in the parameter difference matrix of the edge device cluster. Edge devices generally suffer from narrow bandwidth and weak computing power. This application compresses high-dimensional model parameters into low-dimensional quantum state vectors through quantum state encoding, reducing the amount of parameter transmission. Simultaneously, the parameter difference matrix only transmits the difference degree rather than the complete parameters, further reducing communication overhead and significantly reducing the network resource consumption of edge devices. Then, based on a dual pruning strategy, a target client set is selected from multiple clients using the spatiotemporal correlation matrix and parameter difference matrix. Dynamic aggregation is then performed on the local model parameters of the target client set to generate a global model for scene prediction. The dual pruning strategy includes pruning from the parameter anomaly dimension and pruning from both spatial and temporal dimensions, effectively addressing the spatiotemporal non-independent and identically distributed problem of data distribution on edge devices. If the global model is determined to meet the model convergence condition, it is used as the target global model for the edge device cluster. This demonstrates significant advantages in edge computing architecture, effectively handling spatiotemporal heterogeneity between devices, reducing communication overhead, and improving model convergence speed and generalization performance.

[0007] The above description is only an overview of the technical solution of this application. In order to better understand the technical means of this application and to implement it in accordance with the contents of the specification, and to make the above and other objects, features and advantages of this application more obvious and understandable, the following are specific embodiments of this application. Attached Figure Description

[0008] Various other advantages and benefits will become apparent to those skilled in the art upon reading the following detailed description of preferred embodiments. The accompanying drawings are for illustrative purposes only and are not intended to limit the scope of this application. Furthermore, the same reference numerals denote the same parts throughout the drawings. In the drawings: Figure 1 This paper illustrates a flowchart of a prediction method based on spatiotemporal quantum federated learning for edge scenarios, provided by an embodiment of this application. Figure 2 This paper illustrates a flowchart of another prediction method based on spatiotemporal quantum federated learning for edge scenarios provided in an embodiment of this application. Figure 3 This illustration shows a schematic diagram of the logical architecture of a spatiotemporal quantum federated learning algorithm for edge scenarios provided in an embodiment of this application. Detailed Implementation

[0009] In the description of this application, it should be understood that the terms "center", "longitudinal", "lateral", "length", "width", "thickness", "upper", "lower", "front", "rear", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", "clockwise", "counterclockwise", etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are used only for the convenience of describing this application 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, they should not be construed as limitations on this application.

[0010] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this application, "multiple" means two or more, unless otherwise explicitly specified.

[0011] In this application, unless otherwise expressly specified and limited, the terms "installation," "connection," "linking," and "fixing," etc., should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection between two components. Those skilled in the art can understand the specific meaning of the above terms in this application according to the specific circumstances.

[0012] Exemplary embodiments of the present application will now be described in more detail with reference to the accompanying drawings. While exemplary embodiments of the present application are shown in the drawings, it should be understood that the present application may be implemented in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this application will be thorough and complete, and will fully convey the scope of the present application to those skilled in the art.

[0013] Existing technologies mainly include three categories: classical federated averaging algorithms (such as FedAvg), adaptive federated optimization schemes, and quantum-inspired federated learning. All of them have significant adaptability defects: classical federated averaging algorithms only update the model by weighted averaging aggregation, completely ignoring the geographical proximity and temporal dynamic correlation of edge data, and cannot cope with spatiotemporally heterogeneous non-independent identically distributed (Non-IID) data, resulting in insufficient model generalization ability; although adaptive federated optimization introduces client-side adaptive learning rates, it fails to solve the problem of global model convergence instability caused by non-uniform data distribution; although quantum-inspired federated learning attempts to represent parameters with qubits, it only stays at the theoretical simulation level, relies on dedicated quantum hardware, has poor compatibility with conventional edge computing architectures, has high deployment thresholds, and does not fully utilize quantum resources, making it difficult to implement in practice.

[0014] Traditional federated learning also faces core challenges and dual bottlenecks in technology and engineering: At the core level, the explosive growth of edge devices brings spatiotemporal heterogeneous data, narrow bandwidth communication pressure, and resource constraints such as low computing power and limited storage of edge devices, making it difficult to adapt to the needs of real-world scenarios; At the technical level, the cross-theory of quantum and federated learning is incomplete, spatiotemporal modeling leads to superlinear growth in algorithm complexity, and convergence under nonlinear quantum operations lacks rigorous verification; At the engineering level, the heterogeneity of edge devices makes deployment standardization difficult, monitoring and debugging tools for quantum-classical hybrid systems are lacking, and quantum state transmission may introduce privacy leakage risks, resulting in insufficient compliance and operational feasibility in sensitive scenarios such as medical care and autonomous driving.

[0015] To address the aforementioned issues, this application aims to overcome the fundamental limitations of traditional federated learning in edge computing scenarios by deeply integrating quantum computing concepts with spatiotemporal modeling to construct a new generation of edge intelligence framework. This not only solves the practical engineering problems currently faced by federated learning but also explores feasible paths for the application of the quantum-classical hybrid computing paradigm in distributed machine learning. Therefore, this application proposes a Spatio-Temporal Quantum Amplitude Federated Aggregation (ST-QAFA) algorithm for edge computing scenarios. This innovative algorithm combines quantum amplitude estimation with a federated learning framework, effectively addressing the spatiotemporal non-independent and identically distributed problem of data distribution on edge devices by introducing a spatiotemporal dynamic pruning mechanism. Its core technological breakthrough lies in utilizing the superposition property of quantum states to process multi-client model updates in parallel, while combining a spatiotemporal attention weight matrix to significantly improve the model's convergence speed and generalization performance. After rigorous theoretical verification, this algorithm achieves a 3.8-fold improvement in training efficiency and a 67% reduction in communication overhead in typical edge scenarios, while remaining fully compatible with existing classical computing architectures. The implementing entity of this application may be a medical service platform, which provides services to users by relying on the computing power of a server. The server may be an independent server or a server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms.

[0016] This application provides a prediction method based on spatiotemporal quantum federated learning for edge computing scenarios, such as... Figure 1 As shown, the method includes: 101. Obtain the spatiotemporal data of the edge device cluster, as well as the local model parameters of each client in the edge device cluster.

[0017] In this embodiment, spatiotemporal data and local model parameters from each client in the edge device cluster are collected. The spatiotemporal data includes geographic coordinate data and business time-series data. Specifically, geographic coordinate data refers to the latitude and longitude information of each edge device's location, while business time-series data records the device's business activities within a specific time period, reflecting the device's operating status and business processes. Furthermore, local model parameters refer to the model parameters generated by each edge client after training based on its own collected local data. To ensure data consistency and processability, these model parameters need to be uniformly formatted as tensors to enable efficient data processing and model optimization during subsequent data analysis and model fusion. In this way, comprehensive collection and effective utilization of data from each client in the edge device cluster can be achieved, providing a solid data foundation for subsequent intelligent analysis and decision-making.

[0018] 102. Construct a dual graph structure based on geographic distance and temporal similarity using spatiotemporal data to obtain the spatiotemporal graph of the edge device cluster, and calculate the spatiotemporal correlation matrix of the edge device cluster.

[0019] In this embodiment, traditional implementations of federated learning often neglect the geographical proximity and temporal dynamics of edge data, which significantly impacts model performance in edge scenarios. To address this issue, a dual-graph structure is employed to accurately capture the spatiotemporal relationships between data points. This structure not only better adapts to the non-independent identically distributed (Non-IID) data characteristics in edge scenarios but also quantifies the contribution of each client to the data through multiple spatiotemporal correlation weights in the spatiotemporal correlation matrix. This approach avoids the accuracy loss associated with traditional equal-weighted aggregation, thereby significantly improving the generalization performance of the global model. This method allows for more effective utilization of edge data, enhancing model performance and accuracy in edge scenarios.

[0020] 103. Encode the local model parameters of each client into quantum states, and use the quantum states of multiple clients to calculate the model parameter difference between any two clients in the edge device cluster, thereby obtaining the parameter difference matrix of the edge device cluster.

[0021] In this embodiment, quantum state encoding is a highly efficient data compression technique that can compress high-dimensional parameter information into low-dimensional quantum state vectors. This compression method significantly reduces the number of parameters required during data transmission, making it particularly suitable for edge computing scenarios where bandwidth resources are often severely limited. By compressing high-dimensional data into low-dimensional quantum states, quantum state encoding effectively reduces the bandwidth requirements for data transmission, making it possible to process large amounts of data on edge devices. Furthermore, the quantum state encoding process can be completely simulated using classical GPU clusters, meaning that dedicated quantum hardware is not required in practical applications. This simulation method not only reduces the deployment cost of quantum state encoding but also improves its accessibility, as GPU clusters are already quite common in current computing environments. Therefore, quantum state encoding can directly interface with mainstream edge devices without additional hardware investment, thereby accelerating its application and promotion in the field of edge computing. Thus, by compressing high-dimensional parameters into low-dimensional quantum state vectors, quantum state encoding effectively reduces the amount of parameter transmission, making it particularly suitable for the narrow bandwidth constraints of edge scenarios. Meanwhile, by using classical GPU clusters to simulate quantum coding, no dedicated quantum hardware is required, reducing deployment costs and enabling quantum state coding technology to directly connect to mainstream edge devices, providing an efficient data processing solution for edge computing.

[0022] 104. Based on a dual pruning strategy, the target client set is selected from multiple clients using the spatiotemporal correlation matrix and parameter difference matrix. Dynamic aggregation operation is then performed on the local model parameters of the target client set to generate a global model.

[0023] In this embodiment, the first pruning step in the dual pruning strategy, also known as parameter anomaly pruning, primarily functions to finely filter the parameter difference matrix. Specifically, it selects clients whose average difference reaches or exceeds a preset threshold. This step aims to initially filter out clients with insignificant parameter changes, thereby reducing the complexity of subsequent processing. Next, the second pruning step in the dual pruning strategy, namely spatiotemporal importance pruning, further filters the remaining clients. This filtering criterion is the spatiotemporal correlation weight; only clients with a spatiotemporal correlation weight greater than a preset threshold are retained. Taking the intersection of the results of these two filtering steps yields a target client set. Determining this set effectively reduces invalid aggregation operations and improves overall efficiency.

[0024] After determining the target client set, the next step is to renormalize the initial aggregate weights of these target clients to ensure that the weights of each client are reasonable and balanced in the new aggregation process. Subsequently, an element-wise weighted average is performed on the local model parameters of these clients. The global model parameters generated in this way ensure that clients that contribute more to the model receive higher weights. This weight allocation mechanism not only reflects the contributions of each client more fairly but also significantly improves the convergence speed of the global model, thereby accelerating the entire model training process and improving the final performance of the model.

[0025] 105. If the detection determines that the global model meets the model convergence condition, then the global model will be used as the target global model for the edge device cluster.

[0026] In this embodiment, during each training round, the L2 norm difference between the global model parameters of the current round and the global model parameters of the previous round needs to be calculated. The L2 norm difference is a method to measure the difference between two vectors, reflecting the degree of spatial variation of the model parameters. Specifically, the L2 norm difference is obtained by calculating the square root of the sum of the squares of the differences between corresponding elements of the two vectors. If this L2 norm difference is less than a preset convergence threshold, the model can be considered to have converged. In this case, the target global model is output. However, if the L2 norm difference is greater than the preset convergence threshold, the model has not yet reached the expected performance, and the global model needs to be fed back to the client, initiating the next training cycle. This method allows for continuous optimization of the model parameters, enabling them to better adapt to the spatiotemporal dynamics of edge data.

[0027] 106. Obtain real-time spatiotemporal data of the edge device cluster, input the real-time spatiotemporal data into the target global model for prediction, and obtain the edge scene prediction results of the edge device cluster.

[0028] In this embodiment, real-time spatiotemporal data of the edge device cluster is acquired, including the real-time geographic coordinates of the devices (such as the real-time latitude and longitude of vehicle-mounted devices and the location coordinates of wind turbines) and business time-series data (such as the real-time road condition perception sequence of intelligent driving, the real-time vital sign sequence of ICU patients, and the real-time operating parameter sequence of wind turbines in wind farms). The real-time spatiotemporal data is input into the target global model. The model calls the spatiotemporal correlation features learned during the training phase plus quantum-encoded optimization parameters to analyze and calculate the input data, generating prediction results for the corresponding edge scenarios. For example, in the intelligent driving scenario, the model outputs the obstacle category (pedestrian / vehicle), distance, and trajectory prediction for real-time road conditions; in the cross-hospital ICU scenario, it outputs the patient's sepsis risk level and the risk occurrence time window; and in the distributed wind farm scenario, it outputs the wind turbine fault type, fault probability, and estimated fault time.

[0029] This application provides a prediction method based on spatiotemporal quantum federated learning for edge scenarios. Compared with existing technologies, this application obtains spatiotemporal data of an edge device cluster and the local model parameters of each client in the edge device cluster. It then constructs a dual graph structure based on geographical distance and temporal similarity using the spatiotemporal data to obtain the spatiotemporal graph of the edge device cluster and calculates the spatiotemporal correlation matrix of the edge device cluster. The spatiotemporal data includes geographical coordinates and time series data, which can accurately capture the spatiotemporal dynamic patterns of edge data, overcoming the limitation of traditional methods that ignore spatiotemporal heterogeneity and improving the generalization performance of the global model. Next, the local model parameters of each client are encoded into quantum states. The model parameter difference degree between any two clients in the edge device cluster is calculated using the quantum states of multiple clients, resulting in the parameter difference matrix of the edge device cluster. Edge devices generally suffer from narrow bandwidth and weak computing power. This application compresses high-dimensional model parameters into low-dimensional quantum state vectors through quantum state encoding, reducing the amount of parameter transmission. Simultaneously, the parameter difference matrix only transmits the difference degree rather than the complete parameters, further reducing communication overhead and significantly reducing the network resource consumption of edge devices. Then, based on a dual pruning strategy, a target client set is selected from multiple clients using the spatiotemporal correlation matrix and parameter difference matrix. Dynamic aggregation is then performed on the local model parameters of the target client set to generate a global model. The dual pruning strategy includes pruning from the parameter anomaly dimension and pruning from both spatial and temporal dimensions, effectively addressing the spatiotemporal non-independent and identically distributed problem of data distribution on edge devices. If the global model is determined to meet the model convergence condition, it is used as the target global model for the edge device cluster. This demonstrates significant advantages in edge computing architectures, effectively handling spatiotemporal heterogeneity between devices, reducing communication overhead, and improving model convergence speed and generalization performance.

[0030] Furthermore, as a refinement and extension of the specific implementation methods of the above embodiments, and to fully illustrate the specific implementation process of this embodiment, this application provides another prediction method based on spatiotemporal quantum federated learning for edge scenarios, such as... Figure 2 As shown, the method includes: 201. Obtain the spatiotemporal data of the edge device cluster, as well as the local model parameters of each client in the edge device cluster.

[0031] In this embodiment, before acquiring data, a detailed and comprehensive check of the client list is performed to verify its validity and completeness, ensuring that each client in the list strictly possesses the following four essential attributes: device_id (device identifier), spatial_coords (spatial coordinate information), temporal_data (temporal data), and model_params (model parameters). The completeness and accuracy of these four attributes are the foundation for subsequent data processing and analysis. At this stage, an empty undirected graph object is constructed, which serves as the basic framework for receiving and storing node and edge information. It should be noted that the undirected graph is chosen based on its flexibility and applicability, effectively representing and handling complex relationships between clients. To further improve system performance, especially in scenarios involving repetitive computation, a client metadata caching mechanism can be added. This mechanism caches client metadata information, avoiding the overhead of repeatedly acquiring and processing the same data in multiple computations, thereby significantly improving overall computational efficiency and response speed. It not only optimizes resource utilization but also greatly enhances the user experience.

[0032] Next, the system iterates through all connected client devices, meticulously extracting the spatial coordinate information provided by each device, and converting this raw data into a unified, efficient NumPy array format for subsequent efficient data processing and analysis. During data extraction, it strictly ensures that all acquired coordinate data adheres to the standard (longitude, latitude) format. Specifically, longitude values ​​must be strictly limited to the range [-180, 180], while latitude values ​​must be controlled within the range [-90, 90] to guarantee data accuracy and consistency. To further improve data quality, the system introduces an advanced coordinate correction algorithm. This algorithm can intelligently identify and automatically correct common geographic coordinate format errors, such as reversed latitude and longitude, or values ​​exceeding reasonable ranges, thereby ensuring that the preprocessed coordinate data is more accurate and reliable for subsequent spatial analysis and applications.

[0033] Subsequently, time-series data is extracted from each client system one by one. During the extraction process, the length of each data set is carefully checked to ensure it meets the preset requirements, and the uniformity of the data format is strictly verified to ensure that all data conforms to the established standards and specifications, thus laying a solid foundation for subsequent data processing and analysis. After data extraction is completed, a comprehensive scan and review of the data is conducted. Once any abnormal data is found, such as missing data, format errors, or numerical anomalies, the system will immediately activate the logging mechanism to record detailed information about the abnormal data, including the time, location, and specific manifestation of the anomaly. Then, necessary standardization processing is performed on these abnormal data. Through a series of data cleaning, transformation, and correction operations, the abnormal data is transformed into valid data that conforms to the standards, ensuring the quality and integrity of the overall dataset. To further improve the usability and diversity of the data, the system supports various types of time-series formats. Specifically, these include common equal-interval sampling sequences, which collect data at fixed time intervals and are regular and predictable; and event-driven sequences, which record data based on the occurrence of specific events and are flexible and dynamic. By being compatible with these two major time series formats, the system can provide a solid and rich data foundation for various application scenarios, thereby greatly expanding the possibilities of data analysis and application.

[0034] This detailed spatial coordinate information, along with precise time-series data—a series of data points arranged chronologically—is organically integrated to form a complete and multidimensional spatiotemporal data system. This spatiotemporal data can not only accurately describe the spatial location at a specific moment but also dynamically demonstrate the spatial evolution process over time, providing a solid foundation for data analysis and decision support in various complex scenarios.

[0035] 202. Obtain spatial coordinate data and time series data from spatiotemporal data.

[0036] In this embodiment of the application, spatial coordinate data and time series data are obtained from spatiotemporal data. The spatial coordinate data includes the geographic location coordinates of each client, and the time series data includes the time series of each client, as shown in Formula 1 below: Formula 1:

[0037]

[0038]

[0039] in, Represents spatial coordinate data, Representing time series data, This represents the geographic coordinates of the i-th client. This represents the longitude of the i-th client. This represents the dimension of the i-th client. , This represents the time series of the i-th client. Represents the time series of the i-th client. Data points, This represents the client's sequence number index. This represents the length of the time series for the i-th client. This represents the time series of the j-th client. Represents the time series of the j-th client. Data points, This represents the length of the time series for the j-th client. Indicates the number of clients.

[0040] 203. Construct a spatial similarity matrix for the edge device cluster using spatial coordinate data, and construct a spatial graph of the edge device cluster using the spatial similarity matrix.

[0041] In this embodiment, the `cdist` function from the scientific computing library `scipy` can be used to accurately calculate the Euclidean distance between any two clients within an edge device cluster by inputting spatial coordinate data. This process generates a matrix containing multiple distance values, each representing the spatial distance between a pair of clients, ensuring computational stability and efficiency, thereby providing basic data support for subsequent data analysis and processing. The calculation formula is shown in Formula 2 below:

[0042] in, This represents the distance between the i-th client and the j-th client. This represents the longitude of the i-th client. This represents the dimension of the i-th client. This represents the longitude of the j-th client. This represents the dimension of the j-th client. In the specific technical implementation, the distance matrix used is designed as a... The matrix is ​​a 3D square matrix, where each element precisely represents the distance metric between two data points at the corresponding location. The diagonal elements of this matrix are uniformly set to 0, indicating that the distance between any data point and itself is naturally zero. Therefore, this representation not only conforms to reality but also effectively simplifies the calculation process and avoids unnecessary redundant operations. To further improve the system's operating efficiency under high load, especially in scenarios requiring the handling of large-scale client requests, a block-based computation strategy can be adopted for performance optimization. Specifically, this strategy divides the entire distance matrix into multiple smaller sub-matrix blocks, and then performs independent computation on these sub-blocks. This not only significantly reduces the memory resources required for a single computation but also fully utilizes the multi-core parallel processing capabilities of modern computers. Thus, while maintaining computational accuracy, it greatly improves memory utilization efficiency, ensuring that the system maintains a highly efficient and stable operating state even when facing large-scale concurrent client access.

[0043] Next, the multiple distance values ​​are converted into corresponding similarity values, ensuring that all output similarity values ​​are strictly within the range of (0, 1], thus constructing the spatial similarity matrix. The calculation formula is shown in Formula 3 below: Formula 3:

[0044] in, This represents the spatial similarity value between the i-th client and the j-th client in the spatial similarity matrix. This represents the distance between the i-th client and the j-th client. This represents the distance scaling factor, with a default value of 1. To further optimize the algorithm, a diverse range of similarity conversion function options can be systematically introduced and integrated. This aims to comprehensively meet and flexibly adapt to the specific needs of various differentiated application scenarios, thereby effectively improving the algorithm's universality and practicality. Users can select the most suitable similarity conversion function based on their actual application background and specific needs, ensuring that the algorithm performs optimally in different contexts, thus significantly improving work efficiency and result accuracy.

[0045] Subsequently, based on the spatial edge generation decision, a spatial graph is constructed using the spatial similarity matrix, and the calculation formula is shown in Formula 4 below: Formula 4:

[0046] in, Represents the set of edges in a spatial graph. This represents the edge between the i-th client and the j-th client. This represents the spatial similarity value between the i-th client and the j-th client in the similarity matrix. This represents the spatial similarity threshold in the spatial edge generation decision, with a default value of 1, used to control the generation of spatial edges. In the specific implementation, the system traverses all client pairs one by one, calculating their spatial similarity. When the similarity value exceeds the preset threshold, the system adds an edge to the graph and records the specific value of the similarity. This edge generation mechanism based on a preset threshold effectively controls the sparsity of the graph, ensuring that the graph structure is neither too dense nor too sparse, thereby optimizing the graph's storage and computation efficiency. To further enhance the system's intelligence, a local density-aware mechanism is introduced. When clients are spatially unevenly distributed, this mechanism automatically adjusts the threshold strategy, allowing the threshold to dynamically change according to changes in local density, thus more accurately reflecting the actual similarity relationship between clients. In addition, the system adds support for geohashing encoding. The introduction of this innovative technology significantly improves the query efficiency of neighboring clients, making it possible to quickly find neighboring nodes among a large number of clients, further optimizing the overall performance and response speed of the system.

[0047] 204. Based on the improved DTW algorithm, a time similarity matrix of the edge device cluster is constructed using time series data, and a time map of the edge device cluster is constructed using the time similarity matrix.

[0048] In this embodiment, an improved DTW algorithm is used to calculate the morphological similarity distance between any two client time series in the time series data, resulting in multiple dynamic time warping distances. The calculation formula is shown in Formula 5 below: Formula 5:

[0049] in, This represents the dynamic time-warped distance between the time series of the i-th client and the time series of the j-th client. This represents the normalized path between the time series of the i-th client and the time series of the j-th client. Represents points on a regular path. This represents the p-th data point in the time series of the i-th client. Let represent the q-th data point in the time series of the j-th client. It's important to note that the core ideas of the improved DTW algorithm mainly revolve around three aspects: path constraints, local weight adjustment, and optimization of the algorithm itself. The introduction of path constraints limits the slope range of the regularized path, preventing it from being too steep or flat, thus more accurately reflecting the similarity between sequences. Secondly, the purpose of local weight adjustment is to dynamically adjust the weights based on the importance of different time points, allowing the algorithm to focus more on key feature points in the sequence, thereby improving matching accuracy. The improved DTW algorithm significantly alleviates the sensitivity of traditional methods to sequence length, making it applicable to sequence matching problems of varying lengths. In terms of technological innovation, a fast DTW approximation algorithm is introduced. This algorithm significantly improves computational efficiency while maintaining accuracy, enabling the algorithm to complete sequence matching tasks faster.

[0050] Next, the multiple dynamic time-normalized distances are normalized to obtain multiple time series dissimilarity measures, calculated using the formula shown in Formula 6 below: Formula 6:

[0051] in, This represents the time series difference between the time series of the i-th client and the time series of the j-th client. This represents the dynamic time-warped distance between the time series of the i-th client and the time series of the j-th client. This represents the length of the time series for the i-th client. This represents the length of the time series for the j-th client. Normalization is an effective technique that can eliminate biases that may arise when comparing sequences of different lengths. For sequences of various lengths encountered in practical applications, the system provides a variety of flexible normalization strategies for users to choose from. These strategies include, but are not limited to, maximum-based normalization, minimum-maximum-based normalization, and mean-based normalization. Users can select the most suitable normalization method based on their specific needs and data characteristics, better adapting to data processing requirements in different scenarios and further improving the accuracy and efficiency of sequence comparisons.

[0052] The differences between multiple time series are then converted into similarity values ​​to construct a time similarity matrix, calculated using the formula shown in Formula 7 below: Formula 7:

[0053] in, This represents the time similarity value between the i-th client and the j-th client in the time similarity matrix. This represents the time series difference between the time series of the i-th client and the time series of the j-th client. This represents the attenuation coefficient, with a default value of 2, which more accurately reflects the timeliness characteristics of the time series.

[0054] Then, decisions are generated based on time edges, and a time graph is constructed using the time similarity matrix. The calculation formula is shown in Formula 8 below: Formula 8:

[0055] in, Represents the set of edges in a time graph. This represents the edge between the i-th client and the j-th client. This represents the time similarity value between the i-th client and the j-th client in the time similarity matrix. This represents the temporal similarity threshold in the temporal edge generation decision. The default value is 0.15, which is used to control the generation of temporal edges.

[0056] 205. Use spatial similarity matrix and temporal similarity matrix to perform spatiotemporal feature fusion to obtain the spatiotemporal correlation matrix of the edge device cluster. Based on the spatiotemporal correlation matrix of the edge device cluster, fuse the spatial graph and temporal graph to obtain the spatiotemporal graph of the edge device cluster.

[0057] In this embodiment, spatiotemporal feature fusion is performed using spatial similarity matrix and temporal similarity matrix to obtain the spatiotemporal correlation matrix of the edge device cluster. The calculation formula is as follows: Formula 9: Formula 9:

[0058] in, This represents the spatiotemporal association weight between the i-th client and the j-th client in the spatiotemporal association matrix of the edge device cluster. This represents the spatial similarity value between the i-th client and the j-th client in the spatial similarity matrix. This represents the spatial weighting coefficient, with a default value of 0.5. This represents the time similarity value between the i-th client and the j-th client in the time similarity matrix. This represents the time weighting coefficient, with a default value of 0.5. To meet the needs of different application scenarios and users, the system provides a variety of fusion algorithm options, covering a full range of choices from traditional statistical methods to cutting-edge machine learning technologies.

[0059] Then, based on the spatiotemporal correlation matrix of the edge device cluster, the spatial and temporal graphs are deeply fused to construct a spatiotemporal graph of the edge device cluster. Each node contains complete client metadata information, ensuring data comprehensiveness and accuracy. The edge weights accurately reflect the actual correlation strength between clients, providing reliable data support for subsequent analysis and decision-making. Furthermore, this spatiotemporal graph supports dynamic graph updates, flexibly adapting to the complex scenarios of dynamic client joining and leaving in a federated learning environment, ensuring the system's real-time performance and robustness. Through this dynamic update mechanism, the system can continuously maintain the latest data state, thereby better responding to ever-changing practical application needs.

[0060] Optionally, to further improve the efficiency of the system in calculating the spatiotemporal correlation matrix and generating the spatiotemporal graph, an advanced lazy loading mechanism can be adopted. This mechanism can intelligently delay loading unnecessary resources during system operation, thereby effectively avoiding resource waste and performance loss caused by premature loading. At the same time, an efficient incremental update algorithm can be implemented. This algorithm can accurately identify the changed parts in the data and recalculate only for these changed parts, greatly reducing the ineffective consumption of computing resources. In addition, a cache management interface can be designed. This interface not only supports temporary caching of calculation results but also supports persistent storage of calculation results for quick retrieval in subsequent operations, further improving system performance.

[0061] Therefore, to improve system performance, this application establishes a comprehensive performance monitoring system to ensure stable and efficient performance under various operating environments. Regarding data format anomalies, such as when the system detects an error in the coordinate format, it will automatically adopt a preset default coordinate value and simultaneously record detailed alarm information for subsequent troubleshooting and repair. In terms of fault tolerance design, common data anomalies have been analyzed in depth, and corresponding classification and processing strategies have been established. The effective implementation of these strategies significantly improves the system's robustness and anti-interference capabilities. For threshold adjustment strategies, a flexible dynamic threshold adjustment interface can be provided. This interface supports adaptive threshold calculation based on the current data distribution, ensuring that the threshold setting always matches the actual data characteristics. Simultaneously, a threshold sensitivity analysis function can be introduced, which helps users deeply understand the impact of threshold changes on system performance, thereby more accurately setting optimal parameters and improving the overall operating efficiency of the system. For runtime anomaly handling, multi-layered protection measures can be adopted. Specifically, a block-based processing mechanism is implemented to address the risk of memory overflow. This mechanism can decompose large-scale data processing tasks into multiple small blocks and process them one by one, effectively supporting stable operation in ultra-large-scale client scenarios. For computation timeout issues, a strict upper limit on computation time is set. Once the computation time of a single client is detected to exceed the preset threshold, the system will immediately take measures to prevent it from affecting the overall computation progress.

[0062] It's worth noting that, in addition to basic spatiotemporal features, the system also supports the fusion of various other features such as device type and network status. Through multi-dimensional feature fusion, a more comprehensive and refined client-related network is constructed. The system also features an innovative incremental learning mechanism that dynamically updates the spatiotemporal graph structure based on changes in client behavior patterns during federated learning training, ensuring the model's timeliness and accuracy. For user convenience, the system provides a wealth of visualization tools that help users intuitively understand the structural characteristics of the spatiotemporal graph, quickly diagnose potential problems, and optimize parameter configurations, thereby further improving system performance and user experience.

[0063] 206. Encode the local model parameters of each client into quantum states.

[0064] In this embodiment of the application, for each client, the local model parameters of the client are subjected to L2 normalization to obtain the normalized model parameter vector, and the calculation formula is as follows: Formula 10: Formula 10:

[0065]

[0066] in, This represents the client's local model parameters. Let N represent the i-th component of the local model parameters, and let N represent the parameter dimension of the local model parameters. This represents the L2 norm of the local model parameters. This represents the normalized model parameter vector. This represents a very small constant value, a small constant used to prevent division by zero; the default value is... .

[0067] The normalized model parameter vector is subjected to dimension adaptation processing to obtain the target parameter vector, and the calculation formula is shown in Formula 11 below: Formula 11:

[0068] in, Represents the target parameter vector. This represents the normalized model parameter vector, where N represents the parameter dimension of the local model parameters, and k represents the number of qubits (an integer with a default value of 8, corresponding to a quantum state dimension of 256). This parameter determines the balance between encoding precision and computational complexity, and must be chosen based on the parameter scale in the actual application. In the field of quantum computing, the number of qubits is a crucial technical detail, directly affecting the processing power and computational accuracy of a quantum computer. The number of qubits is typically controlled between 6 and 10, depending on the scale of the model parameters. When the model parameter scale is small, the number of qubits can be appropriately reduced to effectively decrease computational resource consumption and avoid unnecessary computational overhead. When facing large-scale parameter scenarios, using 8 to 10 qubits ensures encoding precision, thereby guaranteeing the accuracy of the computational results. In summary, the choice of the number of qubits needs to be determined based on the specific application scenario and the model parameter scale to achieve both meeting computational requirements and minimizing resource consumption.

[0069] Based on the above process, the input parameters are L2 normalized to ensure that the magnitude of each parameter vector is 1, thus meeting the basic requirements of quantum state representation and ensuring the accuracy and stability of subsequent quantum computing. If the number of input parameters is less than the dimension of the quantum state, zero-padding is performed to ensure that the parameter vector completely covers all dimensions of the quantum state; if the number of input parameters exceeds the dimension of the quantum state, a truncation operation is performed to remove redundant parameters to ensure that the parameter vector perfectly matches the dimension of the quantum state, thereby guaranteeing the smooth progress of quantum computing and the accuracy of the results.

[0070] Next, the target parameter vector is converted into an array format to obtain the quantum state of the client. The calculation formula is shown in Formula 12 below: Formula 12:

[0071]

[0072]

[0073] in, Represents the quantum state of the client. Represents the amplitude of the quantum state. This represents the i-th component in the target parameter vector. The base state represents the quantum state, and k represents the number of qubits. The preprocessed and adjusted parameter data is converted into an array format supported by the NumPy library to facilitate efficient construction and representation of the quantum state. To ensure the accuracy and reliability of the constructed quantum state, the quantum state vector needs to be carefully verified again, re-verifying its normalization properties to ensure its magnitude is 1. Only quantum state vectors that satisfy the normalization condition can conform to the fundamental constraints of quantum mechanics, thus guaranteeing their effectiveness and legitimacy in quantum computing and quantum information processing.

[0074] 207. Calculate the model parameter difference between any two clients in the edge device cluster using the quantum states of multiple clients, and obtain the parameter difference matrix of the edge device cluster.

[0075] In this embodiment of the application, the inner product of any two quantum states in the quantum states of multiple clients is calculated to obtain multiple inner products, and the calculation formula is as follows: Formula 13: Formula 13:

[0076] in, Represents the quantum state of the i-th client. Quantum state with the j-th client The inner product of the two parameters is such that a larger inner product value indicates that the parameter distributions are more similar. Represents the quantum state of the i-th client. The complex conjugate of the amplitude in the r-th ground state Represents the quantum state of the j-th client. The amplitude in the r-th ground state.

[0077] The similarity between any two quantum states in the quantum states of multiple clients is calculated using multiple inner products, resulting in multiple parameter similarities. The calculation formula is shown in Formula 14 below:

[0078] in, Represents the quantum state of the i-th client. Quantum state with the j-th client Parameter similarity, Represents the quantum state of the i-th client. Quantum state with the j-th client The inner product; The amplitude difference between any two quantum states in the quantum states of multiple clients is calculated using multiple parameter similarity to obtain the parameter difference matrix of the edge device cluster. The calculation formula is shown in Formula 15 below:

[0079] in, This represents the amplitude difference between the i-th and j-th clients in the parameter difference matrix, ranging from [0,1], where 0 indicates complete agreement and 1 indicates complete orthogonality. Represents the quantum state of the i-th client. Quantum state with the j-th client The system iterates through all client pairs, calculating the amplitude difference between each pair. Through this series of calculations, a detailed and complete difference relationship graph is constructed, comprehensively displaying the amplitude differences between each client. During the calculation process, the system generates a symmetrical inner product. The difference matrix is ​​characterized by having all elements on its diagonal as 0, indicating that the amplitude difference between each client and itself is 0.

[0080] Optionally, the system calculates the average amplitude difference between each client and all other clients, effectively identifying isolated nodes that differ significantly from other clients. After calculating the average difference, the system makes a judgment based on a preset threshold. If the average difference of a client exceeds this threshold, it is marked as an abnormal state. It is worth noting that this threshold is not fixed but can be flexibly adjusted according to actual security level requirements to ensure the accuracy and adaptability of the detection.

[0081] The advantage of quantum amplitude encoding lies in its unique dimensionality expansion capability, which maps parameters from classical space to quantum space. This quantum space has exponentially increasing dimensions, fully utilizing the high-dimensional representation capabilities of quantum states. This high-dimensional representation capability gives quantum amplitude encoding a significant advantage in handling complex problems, enabling it to capture subtle features that classical methods cannot. Furthermore, the enhanced sensitivity of quantum amplitude encoding is another important advantage. The inner product calculation of quantum states is more sensitive to subtle changes in parameters, enabling the detection of minute anomalies that are difficult to detect using traditional methods. This makes quantum amplitude encoding a promising candidate for applications in anomaly detection, fault diagnosis, and other fields. In terms of security, quantum amplitude encoding also has significant advantages. Through anomaly detection, quantum amplitude encoding can effectively identify potential malicious model updates, thereby preventing security threats such as model poisoning. Compared to traditional similarity calculation methods, quantum amplitude encoding has a significant advantage in parallel computing when handling high-dimensional parameters, making it more efficient in processing large-scale data and providing new approaches to solving complex problems.

[0082] Parameter encoding time is a key indicator of computational efficiency. The optimized system achieves a breakthrough in average processing time of less than 50 milliseconds (based on CPU computation), significantly improving data processing speed and enabling seamless support for real-time federated learning scenarios, meeting high real-time requirements. Secondly, considering scenarios with large-scale client concurrent processing, the system effectively reduces resource consumption by optimizing memory allocation strategies, ensuring high efficiency even during multi-task parallelism. Furthermore, algorithm convergence directly affects model training performance. Experimental results on standard test datasets show that compared to traditional aggregation methods, the proposed algorithm improves convergence speed by 15–30%, shortening training time and enhancing model stability and reliability. In addition, anomaly detection accuracy is a crucial indicator for system security. In simulated attack tests, the system achieved an accuracy rate of over 92% against various model poisoning attacks, effectively enhancing the system's defense capabilities and ensuring data security.

[0083] To ensure smooth operation in various environments, the system supports mainstream CPU architectures and does not rely on dedicated quantum hardware. Implementing quantum algorithms through classical simulation not only lowers the hardware barrier but also enhances the system's versatility and ease of use. Regarding software dependencies, the system is built on the widely used PyTorch and NumPy libraries, maintaining good compatibility with mainstream federated learning frameworks. This allows users to easily integrate and utilize existing resources, reducing development costs and the learning curve.

[0084] 208. Calculate the normalized weight of each client using the spatiotemporal correlation matrix and parameter difference matrix.

[0085] In this embodiment, all clients are traversed, and the initial aggregation weight of each client is calculated using the spatiotemporal correlation matrix and the parameter difference matrix. The calculation formula is as follows: Formula 16: Formula 16:

[0086]

[0087] in, This represents the initial aggregation weight of the i-th client. This represents the spatiotemporal association weight of the i-th client in the spatiotemporal association matrix. This represents the amplitude difference between the i-th and j-th clients in the parameter difference matrix. This represents the attenuation coefficient. The exponential function ensures that the greater the difference in amplitude, the more significant the weight attenuation.

[0088] Next, the initial aggregate weights for each client are normalized to ensure that the sum of all weights is 1. The calculation formula is shown in Formula 17 below: Formula 17:

[0089] in, This represents the normalized weight of the i-th client. This represents the initial aggregation weight of the i-th client. This represents the initial aggregate weight of the j-th client, and N represents the number of clients.

[0090] 209. By employing a dual pruning strategy, the target client set is selected from multiple clients using the normalized weights and parameter difference matrices of each client.

[0091] In this embodiment, a dual pruning strategy is employed to obtain first and second pruning conditions. The first pruning is amplitude threshold pruning, where the maximum amplitude difference between clients must be less than a pre-set threshold. This aims to retain clients with relatively consistent parameter distributions and small fluctuations, ensuring data consistency and stability, and effectively excluding clients that significantly deviate from the group or exhibit abnormal amplitude fluctuations, thus ensuring data quality for subsequent analysis. The second pruning is spatiotemporal importance pruning, where the client's aggregation weight must be greater than a set importance threshold. This aims to filter out marginal clients with low contribution and minimal impact on the overall analysis, further improving data effectiveness and analytical accuracy. This pruning method effectively prevents a few important clients from being diluted by a large number of ordinary clients, ensuring that the influence of key data is not weakened, thereby improving the accuracy and reliability of the overall analysis.

[0092] Specifically, the parameter difference matrix is ​​used to filter out the set of clients that meet the first pruning condition from multiple clients, and the calculation formula is as follows: Formula 18: Formula 18:

[0093] in, This represents the set of clients that meet the first-level pruning criteria. This represents the amplitude difference between the i-th and j-th clients in the parameter difference matrix. This represents the amplitude threshold, with a default value of 0.25.

[0094] Using the normalized weights of each client, a set of clients that meet the second-level pruning criteria is selected from multiple clients. The calculation formula is shown in Formula 19 below: Formula 19:

[0095] in, This represents the set of clients that meet the second-order pruning criteria. This represents the normalized weight of the j-th client. This represents the importance threshold, with a default value of 0.1.

[0096] Then, the intersection of the client set that meets the first pruning condition and the client set that meets the second pruning condition is taken to ensure that no client that meets the conditions is missed, thus obtaining the target client set.

[0097] 210. Perform dynamic aggregation operations on the local model parameters of the target client set to generate a global model.

[0098] In this embodiment of the application, the normalized weight of each client in the target client set is normalized to obtain the final aggregate weight of each client in the target client set. The calculation formula is as follows: Formula 20: Formula 20:

[0099] in, This represents the final aggregate weight of the i-th client in the target client set. This represents the normalized weight of the i-th client in the target client set. Let S represent the normalized weight of the j-th client in the target client set.

[0100] Next, a dynamic aggregation operation is performed using the final aggregate weight of each client in the target client set and the local model parameters of each client in the target client set to obtain the global model. The calculation formula is shown in Formula 21 below: Formula 21:

[0101] in, This represents the model parameters of the global model, and S represents the target client set. This represents the final aggregate weight of the i-th client in the target client set. This represents the local model parameters of the i-th client in the target client set.

[0102] 211. If the detection determines that the global model meets the model convergence condition, then the global model will be used as the target global model for the edge device cluster.

[0103] In this embodiment, if the global model is determined through testing to fully meet the preset model convergence conditions—that is, the model's performance indicators and stability have reached the expected standards—then the system will officially designate this global model as the target global model that the edge device cluster follows and uses. This ensures that the edge device cluster can work efficiently and stably together when performing various tasks, further improving the overall system performance and reliability.

[0104] 212. If the detection determines that the global model does not meet the model convergence condition, the global model is sent to multiple clients in the edge device cluster so that the multiple clients can use the global model as the initial model for the next round of training and obtain the local model parameters for the next round of training for the multiple clients.

[0105] In this embodiment of the application, if it is determined that the global model does not meet the model convergence condition, the global model is sent to multiple clients in the edge device cluster, so that the multiple clients can use the global model as the initial model for the next round of training and obtain the local model parameters for the next round of training of the multiple clients. The calculation formula is as follows: Formula 22: Formula 22:

[0106] in, This represents the model parameters of the global model obtained in the current training round. This represents the model parameters of the global model obtained in the previous training round. This represents the convergence threshold in the convergence criteria, with a default value. .

[0107] 213. Obtain real-time spatiotemporal data of the edge device cluster, input the real-time spatiotemporal data into the target global model for prediction, and obtain the edge scene prediction results of the edge device cluster.

[0108] In this embodiment, real-time spatiotemporal data of the edge device cluster is acquired. This real-time spatiotemporal data includes spatial data and time-series data. Spatial data refers to the real-time geographic coordinates (e.g., GPS latitude and longitude) and deployment location information of the edge devices. Time-series data refers to the data stream collected in real-time by the device sensors and arranged chronologically. For example, in intelligent driving scenarios, time-series data may include real-time vehicle speed, acceleration, camera video streams, and LiDAR point clouds; in industrial IoT scenarios, time-series data may include vibration frequency, temperature, and pressure readings during device operation; in smart city scenarios, time-series data may include real-time footage from surveillance cameras and traffic flow sensor data. The real-time spatiotemporal data is then input into a target global model for prediction, yielding edge scenario prediction results for the edge device cluster. The prediction results are not isolated but consider the overall state of the device cluster. For example, predicting the overall traffic congestion in a certain area, not just the trajectory of a single vehicle. The target global model is based on an efficient design using spatiotemporal graphs and quantum encoding, with extremely short inference time, meeting the needs of low-latency sensitive scenarios such as intelligent driving obstacle avoidance and real-time medical monitoring, ensuring timely decision-making. Furthermore, the model fully learns the spatiotemporal heterogeneity of edge data during the training phase. Since the input real-time data and training data are from the same spatiotemporal source, it can be adapted to prediction tasks in various edge scenarios such as autonomous driving, healthcare, and industrial operations and maintenance, significantly reducing the development cost of multi-scenario adaptation. Due to the use of dual graphs to capture spatiotemporal correlations, quantum encoding to ensure parameter consistency, and dual pruning to select high-quality updates during the training phase, the model's prediction accuracy for real-time data is significantly higher than that of traditional methods.

[0109] like Figure 3The diagram illustrates a spatiotemporal quantum federated learning algorithm architecture for edge computing scenarios. It comprises data acquisition at the data layer, three core modules (a spatiotemporal graph construction module for processing edge device clusters, constructing a spatiotemporal graph, and clustering clients; a quantum amplitude encoding module for performing local model training, gradient quantum encoding, and amplitude difference calculation; and a dynamic weight adjustment module for global model updates via central server aggregation and dynamic weight adjustment), ultimately delivering application layer output. The overall workflow is as follows: edge device clustering, spatiotemporal graph construction, client clustering, local model training, gradient quantum encoding, amplitude difference calculation, central server aggregation, dynamic weight adjustment, and global model update. The spatiotemporal graph construction module defines edge devices as graph nodes, constructing a dual graph structure based on geographical distance and temporal similarity. An improved DTW algorithm is used to calculate time series similarity, forming a spatiotemporal correlation matrix, and outputting client importance weights through a graph attention network. This module effectively captures the spatiotemporal correlation between edge devices, providing crucial information for subsequent federated aggregation. The quantum amplitude encoding module maps traditional model parameters to n-dimensional quantum states, calculates parameter differences using quantum amplitude estimation, and establishes a parameter difference matrix, thereby effectively identifying anomalous updates. Leveraging the superposition property of quantum states, this module can process model updates from multiple clients in parallel, significantly improving computational efficiency. The dynamic weight adjustment module combines spatiotemporal weights with quantum amplitude differences to generate aggregated weights and implements a dual pruning strategy: amplitude threshold pruning and spatiotemporal importance pruning. Global model updates employ a weighted average approach. This system demonstrates significant advantages in edge computing architectures, effectively addressing spatiotemporal heterogeneity between devices, reducing communication overhead, and improving model convergence speed and generalization performance.

[0110] Scenario 1: Collaborative prediction model for air quality in urban areas.

[0111] Multiple air quality monitoring stations are deployed within the city as federated learning clients, with each station continuously collecting time-series data on local pollutants such as PM2.5 and SO2. The goal is to collaboratively train a global air quality prediction model while ensuring the data privacy of each station, effectively addressing the uneven spatiotemporal distribution of data caused by meteorological conditions and geographical differences.

[0112] The core steps of data processing are as follows: The spatiotemporal graph construction module takes as input: 24-hour pollutant concentration time-series data from each monitoring station, and GPS coordinates for each station. Spatial edges: Based on the geographical distance between stations, a Gaussian kernel function is used to convert distance into spatial connection weights. Temporal edges: An improved DTW algorithm is used to evaluate the similarity of time-series patterns between stations, forming temporal-dimensional connection weights. Weight calculation: The graph structure containing both spatiotemporal associations is input into the Graph Attention Network (GAT). GAT adaptively learns to assign importance weights to each client; for example, upwind stations or stations highly synchronized with multi-regional patterns may receive higher weights.

[0113] The quantum amplitude encoding module takes as input the model parameter updates (such as gradient information) uploaded by each monitoring station after training based on local data. Quantum encoding and difference estimation utilize quantum amplitude encoding to map the parameter vectors of each client to quantum states, achieving parallel representation in a log2(N) scale quantum system. Through a quantum amplitude estimation algorithm, the distance between any two quantum states is calculated in parallel to construct an N×N parameter difference matrix, enabling efficient identification of abnormal model updates caused by sensor malfunctions or localized contamination events.

[0114] Input to the dynamic weight adjustment module: The spatiotemporal weights output by the spatiotemporal graph construction module and the parameter difference matrix generated by the quantum amplitude encoding module. Aggregate weight synthesis and pruning generation: The final aggregate weight for each client is the product of its spatiotemporal weight and the "reliability factor" obtained based on the parameter difference matrix. Amplitude threshold pruning: Clients with excessively high parameter differences (abnormal updates) have their aggregate weights reset to zero. Spatiotemporal importance pruning: Clients with marginalized long-term contributions undergo weight pruning. Global update: The server performs a weighted average update based on the pruned weighted clients to generate a new generation of global prediction models.

[0115] Scenario 2: Early warning system for sepsis in ICU patients across hospitals.

[0116] Multiple hospital ICUs, acting as federated learning clients, continuously collect time-series data on patients' vital signs (such as heart rate, blood pressure, and blood oxygen saturation). The goal is to jointly train a high-precision early warning model for sepsis without sharing sensitive patient information, and to overcome statistical heterogeneity caused by differences in patient populations and treatment methods among hospitals.

[0117] The core steps of data processing are as follows: The spatiotemporal graph construction module takes the following inputs: time series of physiological parameters from each hospital's ICU after de-identification processing, as well as geographical location or referral relationship data between hospitals. Spatial edges are constructed based on geographical distance or referral frequency between hospitals. Temporal edges utilize an improved DTW algorithm to analyze the overall morphological similarity of vital sign sequences from patients across different hospitals, identifying typical pathological waveforms. Weight calculation: The graph attention network assigns differentiated weights to each hospital client based on data quality and the representativeness of pathological patterns.

[0118] The quantum amplitude encoding module takes as input the sepsis early warning model updates trained on local data from each hospital. Quantum encoding and difference estimation encode the model updates as quantum states. Quantum amplitude estimation rapidly constructs a comprehensive picture of the differences between model updates, identifying anomalous updates caused by inconsistent labeling standards or training biases.

[0119] The dynamic weight adjustment module takes into account the importance weights of hospitals and the model update difference matrix. Aggregated weight synthesis and pruning: It combines spatiotemporal weights and quantum differences to generate the final aggregated weights for each hospital. A dual pruning strategy is implemented: amplitude threshold pruning is performed on updates with significant quantum amplitude differences; spatiotemporal importance pruning is performed on clients with long-term low contributions. Global update: The model updates from each hospital are integrated through weighted averaging to improve the generalization ability and robustness of the global model.

[0120] Scenario 3: Predictive maintenance of wind turbines in distributed wind farms.

[0121] In wind farms distributed across different regions, each wind turbine acts as a client, continuously collecting time-series data on its operating status, including vibration, temperature, and rotational speed. The goal is to jointly train fault prediction models for key wind turbine components (such as gearboxes), reduce communication costs, and mitigate spatiotemporal heterogeneity caused by differences in operating conditions such as wind speed and load.

[0122] The core steps of data processing are as follows: The spatiotemporal graph construction module takes the following inputs: the time series of vibration signals from each wind turbine and their location coordinates. Spatial edges are constructed based on the physical distance between wind turbines; adjacent turbines may exhibit related vibration characteristics due to similar wind conditions. Temporal edges are analyzed using an improved DTW algorithm to detect the similarity of vibration waveforms from different wind turbines and detect early warning patterns of faults. Weight calculation is performed by assigning weights to wind turbines based on their influence in the spatiotemporal graph; turbines in critical locations or those capable of predicting rare faults receive higher weights.

[0123] The quantum amplitude encoding module takes as input the fault prediction model updates trained locally for each wind turbine. Quantum encoding and difference estimation map the model parameters to quantum states. Quantum amplitude estimation is used to compute the difference matrix of all wind turbine model updates in parallel, identifying anomalous updates caused by sensor drift or sudden changes in wind turbine health.

[0124] The dynamic weight adjustment module takes into account the spatiotemporal weights and quantum amplitude difference matrix of the wind turbines. Aggregated weight synthesis and pruning: Aggregated weights for each wind turbine are generated by integrating both information. A dual pruning strategy is implemented: amplitude threshold pruning is applied to abnormal updates; spatiotemporal importance pruning is performed on wind turbines with consistently low contribution. Global update: The global fault prediction model is updated using a weighted average, reducing communication overhead and accelerating model convergence.

[0125] The beneficial effects of this application include the following aspects: In terms of technical benefits, firstly, the convergence speed is significantly improved. Specifically, during testing on standard datasets, the number of training epochs required for the model to reach the predetermined target accuracy is greatly reduced, which means a significant reduction in training time and improved overall R&D efficiency. Secondly, communication efficiency is significantly optimized. Through efficient data compression technology, the amount of data that needs to be transmitted in each training epoch is effectively reduced, which not only reduces the burden on network bandwidth but also increases the data transmission rate. Finally, the model's generalization ability is significantly enhanced. When validating on test sets outside the spatiotemporal distribution, the performance degradation phenomenon of the model is significantly improved, indicating that the model has stronger adaptability and higher stability under different environments and conditions.

[0126] In terms of economic benefits, firstly, direct costs are significantly reduced. In typical edge computing deployment scenarios, due to technological optimization and improved resource utilization, the total cost of ownership is greatly reduced, saving enterprises substantial financial investment. Secondly, opportunity costs are effectively converted. The shortened model development cycle enables enterprises to respond more quickly to market changes and customer needs, seize market opportunities, and enhance their competitiveness and market share. Finally, incremental revenue is generated. In multiple different application scenarios, the improved model accuracy leads to more precise services and higher user satisfaction, thereby creating additional service value and economic benefits.

[0127] In terms of social benefits: First, privacy protection capabilities are significantly enhanced. The application of quantum amplitude encoding technology naturally protects the security and privacy of raw data, fully complies with relevant laws and regulations, and increases user trust. Second, energy consumption is significantly reduced. The average energy consumption of edge devices is significantly reduced after technological optimization. This not only reduces operating costs but also actively responds to the concept of sustainable development and contributes to environmental protection. Finally, digital inclusion is effectively promoted. Through technological innovation, resource-constrained regions can also participate in the collaborative training of high-quality AI models, narrowing the digital divide, promoting the popularization and application of artificial intelligence technology, and promoting balanced social development.

[0128] This application provides a prediction method based on spatiotemporal quantum federated learning for edge scenarios. Compared with existing technologies, this application obtains spatiotemporal data of an edge device cluster and the local model parameters of each client in the edge device cluster. It then constructs a dual graph structure based on geographical distance and temporal similarity using the spatiotemporal data to obtain the spatiotemporal graph of the edge device cluster and calculates the spatiotemporal correlation matrix of the edge device cluster. The spatiotemporal data includes geographical coordinates and time series data, which can accurately capture the spatiotemporal dynamic patterns of edge data, overcoming the limitation of traditional methods that ignore spatiotemporal heterogeneity and improving the generalization performance of the global model. Next, the local model parameters of each client are encoded into quantum states. The model parameter difference degree between any two clients in the edge device cluster is calculated using the quantum states of multiple clients, resulting in the parameter difference matrix of the edge device cluster. Edge devices generally suffer from narrow bandwidth and weak computing power. This application compresses high-dimensional model parameters into low-dimensional quantum state vectors through quantum state encoding, reducing the amount of parameter transmission. Simultaneously, the parameter difference matrix only transmits the difference degree rather than the complete parameters, further reducing communication overhead and significantly reducing the network resource consumption of edge devices. Then, based on a dual pruning strategy, a target client set is selected from multiple clients using the spatiotemporal correlation matrix and parameter difference matrix. Dynamic aggregation is then performed on the local model parameters of the target client set to generate a global model. The dual pruning strategy includes pruning from the parameter anomaly dimension and pruning from both spatial and temporal dimensions, effectively addressing the spatiotemporal non-independent and identically distributed problem of data distribution on edge devices. If the global model is determined to meet the model convergence condition, it is used as the target global model for the edge device cluster. This demonstrates significant advantages in edge computing architectures, effectively handling spatiotemporal heterogeneity between devices, reducing communication overhead, and improving model convergence speed and generalization performance.

[0129] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties.

[0130] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0131] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

[0132] In an exemplary embodiment, a computer device is also provided, comprising a bus, a processor, a memory, and a communication interface. It may also include an input / output interface and a display device, wherein the various functional units can communicate with each other via the bus. The memory stores a computer program, and the processor executes the program stored in the memory to perform the prediction method based on spatiotemporal quantum federated learning for edge scenarios described in the above embodiment.

[0133] A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the aforementioned prediction method based on spatiotemporal quantum federated learning for edge scenarios.

[0134] Through the above description of the embodiments, those skilled in the art can clearly understand that this application can be implemented in hardware or by using software plus necessary general-purpose hardware platforms. Based on this understanding, the technical solution of this application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, external hard drive, etc.) and includes several instructions to cause a computer device (such as a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0135] Those skilled in the art will understand that the accompanying drawings are merely schematic diagrams of a preferred embodiment, and the modules or processes shown in the drawings are not necessarily essential for implementing this application.

[0136] Those skilled in the art will understand that the modules in the apparatus of the implementation scenario can be distributed within the apparatus of the implementation scenario as described, or they can be located in one or more apparatuses different from this implementation scenario, with corresponding changes. The modules of the above-described implementation scenario can be combined into one module, or they can be further divided into multiple sub-modules.

[0137] The serial numbers in this application are for descriptive purposes only and do not represent the superiority or inferiority of the implementation scenario.

[0138] The above disclosures are only a few specific implementation scenarios of this application. However, this application is not limited to these. Any variations that can be conceived by those skilled in the art should fall within the protection scope of this application.

Claims

1. A prediction method based on spatiotemporal quantum federated learning for edge computing scenarios, characterized in that, include: Acquire spatiotemporal data of the edge device cluster, as well as local model parameters of each client in the edge device cluster; Using the spatiotemporal data, a dual graph structure based on geographical distance and temporal similarity is constructed to obtain the spatiotemporal graph of the edge device cluster, and the spatiotemporal correlation matrix of the edge device cluster is calculated; The local model parameters of each client are encoded into quantum states, and the model parameter difference degree between any two clients in the edge device cluster is calculated using the quantum states of multiple clients to obtain the parameter difference matrix of the edge device cluster. Based on a dual pruning strategy, the spatiotemporal correlation matrix and the parameter difference matrix are used to filter out the target client set from the multiple clients, and a dynamic aggregation operation is performed on the local model parameters of the target client set to generate a global model. If the detection determines that the global model meets the model convergence condition, then the global model is used as the target global model for the edge device cluster. The real-time spatiotemporal data of the edge device cluster is obtained, and the real-time spatiotemporal data is input into the target global model for prediction to obtain the edge scene prediction result of the edge device cluster.

2. The method according to claim 1, characterized in that, The process of constructing a dual graph structure based on geographical distance and temporal similarity using the spatiotemporal data to obtain the spatiotemporal graph of the edge device cluster, and calculating the spatiotemporal correlation matrix of the edge device cluster, includes: Spatial coordinate data and time series data are obtained from the spatiotemporal data. The spatial coordinate data includes the geographic location coordinates of each client, and the time series data includes the time series of each client. in, This represents the spatial coordinate data. This refers to the time series data. This represents the geographic coordinates of the i-th client. This represents the longitude of the i-th client. This represents the dimension of the i-th client. , This represents the time series of the i-th client. Represents the time series of the i-th client. Data points, This represents the client's sequence number index. This represents the length of the time series for the i-th client. This represents the time series of the j-th client. This represents the time series of the j-th client. Data points, This represents the length of the time series for the j-th client. Indicates the number of clients; The spatial similarity matrix of the edge device cluster is constructed using the spatial coordinate data, and the spatial similarity matrix is ​​used to construct the spatial graph of the edge device cluster. Based on the improved DTW algorithm, a time similarity matrix of the edge device cluster is constructed using the time series data, and a time map of the edge device cluster is constructed using the time similarity matrix; By fusing the spatial similarity matrix and the temporal similarity matrix to obtain the spatiotemporal correlation matrix of the edge device cluster, spatiotemporal features are fused. in, This represents the spatiotemporal association weight between the i-th client and the j-th client in the spatiotemporal association matrix of the edge device cluster. This represents the spatial similarity value between the i-th client and the j-th client in the spatial similarity matrix. Indicates the spatial weighting coefficient. This represents the time similarity value between the i-th client and the j-th client in the time similarity matrix. Indicates the time weighting coefficient; The spatial graph and the temporal graph are fused based on the spatiotemporal correlation matrix of the edge device cluster to obtain the spatiotemporal graph of the edge device cluster.

3. The method according to claim 2, characterized in that, The step of constructing a spatial similarity matrix of the edge device cluster using the spatial coordinate data, and constructing a spatial graph of the edge device cluster using the spatial similarity matrix, includes: The Euclidean distance between any two clients in the edge device cluster is calculated using the spatial coordinate data, resulting in multiple distance values. in, This represents the distance between the i-th client and the j-th client. This represents the longitude of the i-th client. This represents the dimension of the i-th client. This represents the longitude of the j-th client. This represents the dimension of the j-th client; The multiple distance values ​​are converted into similarity values ​​to construct a spatial similarity matrix. in, This represents the spatial similarity value between the i-th client and the j-th client in the spatial similarity matrix. This represents the distance between the i-th client and the j-th client. Indicates the distance scaling factor; Based on the spatial edge generation decision, the spatial graph is constructed using the spatial similarity matrix. in, Denotes the set of edges in the spatial graph. This represents the edge between the i-th client and the j-th client. This represents the spatial similarity value between the i-th client and the j-th client in the similarity matrix. This represents the spatial similarity threshold in the spatial edge generation decision.

4. The method according to claim 3, characterized in that, The step of constructing a time similarity matrix of the edge device cluster using the time series data based on the improved DTW algorithm, and constructing a time map of the edge device cluster using the time similarity matrix, includes: The improved DTW algorithm is used to calculate the morphological similarity distance between any two client time series in the time series data, resulting in multiple dynamic time warping distances. in, This represents the dynamic time-warped distance between the time series of the i-th client and the time series of the j-th client. This represents the normalized path between the time series of the i-th client and the time series of the j-th client. This represents a point on the regularized path. This represents the p-th data point in the time series of the i-th client. This represents the q-th data point in the time series of the j-th client; The multiple dynamic time-warped distances are normalized to obtain multiple time series dissimilarity levels. in, This represents the time series difference between the time series of the i-th client and the time series of the j-th client. This represents the dynamic time-warped distance between the time series of the i-th client and the time series of the j-th client. This represents the length of the time series for the i-th client. This represents the length of the time series for the j-th client; The multiple time series differences are converted into similarity values ​​to construct a time similarity matrix. in, This represents the time similarity value between the i-th client and the j-th client in the time similarity matrix. This represents the time series difference between the time series of the i-th client and the time series of the j-th client. Indicates the attenuation coefficient; Based on the time edge generation decision, the time graph is constructed using the time similarity matrix. in, This represents the set of edges in the time graph. This represents the edge between the i-th client and the j-th client. This represents the time similarity value between the i-th client and the j-th client in the time similarity matrix. This represents the time similarity threshold in the time edge generation decision.

5. The method according to claim 1, characterized in that, The step of encoding the local model parameters of each client into quantum states includes: For each client, the local model parameters of the client are subjected to L2 normalization to obtain a normalized model parameter vector. in, This represents the local model parameters of the client. Let N represent the i-th component of the local model parameters, and let N represent the parameter dimension of the local model parameters. This represents the L2 norm of the local model parameters. This represents the normalized model parameter vector. Indicates a very small constant value; The normalized model parameter vector is subjected to dimension adaptation processing to obtain the target parameter vector. in, Represents the target parameter vector. The normalized model parameter vector is represented by k, where k represents the number of qubits and N represents the parameter dimension of the local model parameters. The target parameter vector is converted into an array format to obtain the quantum state of the client. in, This represents the quantum state of the client. Represents the amplitude of the quantum state. , This represents the i-th component in the target parameter vector. The base state represents the quantum state, and k represents the number of qubits.

6. The method according to claim 1, characterized in that, The step of calculating the model parameter difference between any two clients in the edge device cluster using the quantum states of multiple clients to obtain the parameter difference matrix of the edge device cluster includes: Calculate the inner product of any two quantum states among the multiple clients' quantum states to obtain multiple inner products. in, Represents the quantum state of the i-th client. Quantum state with the j-th client The inner product, Represents the quantum state of the i-th client. The complex conjugate of the amplitude in the r-th ground state Represents the quantum state of the j-th client. The amplitude in the r-th ground state; The similarity between any two quantum states among the multiple client quantum states is calculated using the multiple inner products, resulting in multiple parameter similarity scores. in, Represents the quantum state of the i-th client. Quantum state with the j-th client Parameter similarity, Represents the quantum state of the i-th client. Quantum state with the j-th client The inner product; The amplitude difference between any two quantum states in the quantum states of the multiple clients is calculated using the multiple parameter similarity, thus obtaining the parameter difference matrix of the edge device cluster. in, This represents the amplitude difference between the i-th client and the j-th client in the parameter difference matrix. Represents the quantum state of the i-th client. Quantum state with the j-th client Parameter similarity, Represents the quantum state of the i-th client. Quantum state with the j-th client The inner product of.

7. The method according to claim 1, characterized in that, The method based on dual pruning, which utilizes the spatiotemporal correlation matrix and the parameter difference matrix to filter out the target client set from multiple clients, includes: The initial aggregation weights for each client are calculated using the spatiotemporal correlation matrix and the parameter difference matrix. in, This represents the initial aggregation weight of the i-th client. This represents the spatiotemporal association weight of the i-th client in the spatiotemporal association matrix. This represents the amplitude difference between the i-th client and the j-th client in the parameter difference matrix. Indicates the attenuation coefficient; The initial aggregate weights of each client are normalized. The normalized weights of each client are then processed. in, This represents the normalized weight of the i-th client. This represents the initial aggregation weight of the i-th client. This represents the initial aggregate weight of the j-th client, and N represents the number of clients; The target client set is selected from the multiple clients using the dual pruning strategy, with the normalized weights of each client and the parameter difference matrix.

8. The method according to claim 7, characterized in that, The step of using the dual pruning strategy to filter out the target client set from the multiple clients by utilizing the normalized weights of each client and the parameter difference matrix includes: In the dual pruning strategy, the first pruning condition and the second pruning condition are obtained; The parameter difference matrix is ​​used to filter out a set of clients that meet the first pruning condition from among the multiple clients. in, This represents the set of clients that meet the first pruning condition. This represents the amplitude difference between the i-th client and the j-th client in the parameter difference matrix. Indicates the amplitude threshold; Using the normalized weights of each client, a set of clients that meet the second pruning condition is selected from the multiple clients. in, This represents the set of clients that meet the second pruning condition. This represents the normalized weight of the j-th client. Indicates the importance threshold; The target client set is obtained by taking the intersection of the client set that meets the first pruning condition and the client set that meets the second pruning condition.

9. The method according to claim 1, characterized in that, The step of performing dynamic aggregation operations on the local model parameters of the target client set to generate a global model includes: The normalized weights of each client in the target client set are normalized to obtain the final aggregated weights of each client in the target client set. in, This represents the final aggregate weight of the i-th client in the target client set. This represents the normalized weight of the i-th client in the target client set. Let S represent the normalized weight of the j-th client in the target client set; The global model is obtained by performing a dynamic aggregation operation using the final aggregate weight of each client in the target client set and the local model parameters of each client in the target client set. in, Here, S represents the model parameters of the global model, and S represents the target client set. This represents the final aggregate weight of the i-th client in the target client set. This represents the local model parameters of the i-th client in the target client set.

10. The method according to claim 1, characterized in that, The method further includes: If the detection determines that the global model does not meet the model convergence condition, the global model is sent to multiple clients in the edge device cluster, so that the multiple clients use the global model as the initial model for the next round of training and obtain the local model parameters for the next round of training on the multiple clients. in, This represents the model parameters of the global model obtained in the current training round. This represents the model parameters of the global model obtained in the previous training round. This represents the convergence threshold in the convergence condition.

Citation Information

Patent Citations

  • Data anomaly detection method and system based on quantum graph federated learning

    CN118964626A

  • Edge node heterogeneous network heterogeneous platform access management method and system

    CN120090889A

  • Federal map learning method and system based on feature space construction and sharing

    CN120449993A

  • Personalized federal learning method and system for heterogeneous multi-source industrial internet

    CN120498734A

  • Private weight adaptive heterogeneous data federal cooperative training method and system

    CN120974543A