APN6 network dynamic switching optimization method based on QoS prediction

By constructing a dynamic switching optimization method of APN6 network based on QoS prediction, using the time convolution network, graph neural network and sliding window incremental learning model, the network performance problem of APN6 switching in the IPv6 environment is solved, and network resource scheduling efficiency and service transmission stability are improved.

CN120358525BActive Publication Date: 2025-08-15SHANDONG FUTURE NETWORK RES INST (PURPLE MOUNTAIN LAB IND INTERNET INNOVATION APPL BASE)
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510837443.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-06-23
Publication Date
2025-08-15
Estimated Expiration
2045-06-23

AI Technical Summary

Technical Problem

Traditional APN6 switching relies on static policies and cannot adapt to dynamic network environments. Especially in IPv6 environments, it is difficult to coordinate optimization of attributes such as bandwidth, delay and security, resulting in poor network performance.

Method used

The APN6 network dynamic switching optimization method based on QoS prediction is used to collect QoS indicators of link nodes, build a time convolution network, graph neural network and sliding window incremental learning model, perform multi-dimensional prediction, and use time trends, spatial influences and dynamic changes analysis to trigger path switching.

Benefits of technology

It realizes comprehensive and real-time monitoring and intelligent prediction of network status, improves the efficiency and service quality of APN6 network resource scheduling, and ensures the stability and reliability of service transmission.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120358525B_ABST
    Figure CN120358525B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of next-generation network communication technology, and specifically provides an APN6 network dynamic switching optimization method, system, terminal, and medium based on QoS prediction, including: collecting QoS indicators of different nodes in the APN6 network link, building a time dimension prediction model, and the model outputting a predicted time result; building a space dimension prediction model, the model inputting QoS indicators, and outputting a predicted space result; building a dynamic dimension prediction model, the model inputting QoS indicators, and outputting a predicted dynamic result for updating model parameters; and weighting and integrating the time prediction result, the space prediction result, and the dynamic prediction result to obtain a predicted link quality score. When the predicted link quality score is less than a preset threshold, the APN6 path switching is triggered. This method effectively improves the APN6 network resource scheduling efficiency and service quality, and ensures the stability and reliability of service transmission.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of next generation network communication technology, and specifically relates to an APN6 network dynamic switching optimization method, system, terminal and medium based on QoS prediction. Background Art

[0002] An APN (Access Point Name) is a parameter that mobile devices (such as phones and tablets) must configure when connecting to a mobile network. Due to changes in network service types, usage scenarios, or device capabilities, APN switching is often performed to connect devices to a network channel that better suits their current needs.

[0003] With the deployment of 5G networks and the widespread adoption of IPv6, APN6 has gradually become a core configuration for mobile data services. APN6 (Access Point Name 6) is an access point name designed for IPv6 networks, primarily used to enable terminals to access the IPv6 internet via mobile networks.

[0004] Traditional APN6 handover relies on static policies (such as manual user selection or pre-configuration) and cannot adapt to dynamic network environments (such as sudden congestion scenarios). Furthermore, in an IPv6 environment, APN6 has multiple attributes, such as bandwidth, latency, and security. Coordinating and optimizing these attributes to achieve optimal network performance is challenging. Summary of the Invention

[0005] In view of the above-mentioned deficiencies in the prior art, the present invention provides an APN6 network dynamic switching optimization method, system, terminal and medium based on QoS prediction to solve the above-mentioned technical problems.

[0006] In a first aspect, the present invention provides an APN6 network dynamic switching optimization method based on QoS prediction, comprising:

[0007] QoS metrics are collected at different nodes on the APN6 network based on a preset sampling strategy. QoS metrics include microsecond-level one-way latency, jitter calculated based on IETF RFC 3393, sliding window packet loss rate, current flow rate, and the DSCP field from the APN6 header.

[0008] A time dimension prediction model is constructed based on a temporal convolutional network combined with a temporal attention mechanism. The model inputs QoS indicators and outputs a time prediction result that predicts the QoS trend in the short term.

[0009] A spatial dimension prediction model is built based on a graph neural network. The model inputs QoS indicators and outputs a prediction spatial result of the mutual influence strength of each node in the predicted network topology.

[0010] A dynamic dimension prediction model is built based on sliding window incremental learning. The model inputs QoS indicators and outputs dynamic prediction results for updating model parameters.

[0011] The predicted link quality score is obtained by weighted integration of the time prediction result, the spatial prediction result and the dynamic prediction result. When the predicted link quality score is less than the preset threshold, the APN6 path switching is triggered.

[0012] In an optional embodiment, the sampling strategy includes a basic sampling period and a burst traffic trigger;

[0013] The basic sampling period is the preset value;

[0014] The burst traffic trigger is when the flow rate change rate is greater than 15%, and sampling is performed every 1ms.

[0015] In an optional embodiment, the time dimension prediction model includes a dilated convolution layer and a multi-head attention layer, and the output of the predicted time result for predicting the QoS trend in the short term in the future specifically includes:

[0016] After preprocessing the QoS indicators, a time series data matrix is obtained. The time series data matrix includes batch size, time step, and feature dimension.

[0017] Set different dilation rates, insert holes between convolution kernel elements based on the dilation rate to expand the convolution layer, extract temporal features of different time scales, and obtain a sequence of multi-scale features;

[0018] The multi-head attention mechanism is used to project the sequence of multi-scale features into multiple attention heads. The attention score of each attention head is calculated separately and then concatenated according to the feature dimension to obtain the features with temporal weights as the most accurate prediction time result for QoS trends in the short term in the future.

[0019] In an optional embodiment, outputting the prediction spatial result of the mutual influence strength of each node in the predicted network topology specifically includes:

[0020] Construct a node feature matrix of the shape [number of nodes, feature dimension], which stores the QoS indicators of each node in the network; construct an adjacency matrix for each node;

[0021] Calculate the feature similarity between all nodes based on the dot product operation combined with the node feature matrix;

[0022] Calculate the product of the feature similarity of each node and the adjacency matrix, and convert the product into the degree of attention of each node to different adjacent nodes through softmax;

[0023] Each node obtains new features by weighted aggregation of features of adjacent nodes according to the degree of attention;

[0024] After the attention mechanism based on the GAT layer performs attention calculation and multi-head attention fusion on the new features, the weight matrix between nodes is output as the prediction space result of the mutual influence intensity of each node in the predicted network topology.

[0025] In an optional embodiment, outputting the prediction dynamic results for updating the model parameters specifically includes:

[0026] The latest QoS indicators are stored in a fixed-size array. When the array is filled with data and the latest data arrives, the oldest data is overwritten.

[0027] When the sliding window is filled with data, the model is forward-propagated based on the current batch of data to obtain the prediction result, and the loss function of the batch of data is calculated; based on the loss function, the gradient of the loss with respect to all parameters is calculated through the back-propagation algorithm;

[0028] Accumulate the gradient of the current batch into a cumulative gradient variable. When the number of accumulated batches reaches the preset value, update the model parameters in combination with the learning rate as the prediction dynamic result.

[0029] Calculate the ratio of the current batch loss to the average loss of the previous N batches, and adjust the learning rate based on the ratio.

[0030] In an optional implementation, when the predicted link quality score is less than a preset threshold, the specific steps of triggering the APN6 path switch include:

[0031] The APN6-CP protocol header extends the relevant message types for path switching control, including PRE_SWITCH_REQ, PATH_RESERVE_ACK, and FAST_FAILOVER.

[0032] When the predicted link quality score is less than the preset threshold, the requester sends a PRE_SWITCH_REQ message to the target node, which carries the link quality prediction result and a request to reserve the target path resources;

[0033] After receiving the PRE_SWITCH_REQ message, if the target node's own resources meet the requester's reservation requirements, it returns a PATH_RESERVE_ACK message to confirm the reserved resources. When the requester receives the PATH_RESERVE_ACK message and confirms that the resource reservation is successful, a low-latency backup path is established based on the target node with the reserved resources. The control plane sends a FAST_FAILOVER fast switch execution instruction to the data plane, instructing the data plane to preferentially forward data to the pre-established low-latency backup path based on the identifier, while keeping the original path session state synchronized.

[0034] After receiving the PRE_SWITCH_REQ message, if the target node has insufficient resources, it returns a PATH_RESERVE_NACK message to inform the requester to switch to the backup path.

[0035] In an optional implementation, switching the backup path specifically includes:

[0036] After receiving the PATH_RESERVE_NACK message, the requester starts searching the local path table for the backup path.

[0037] After obtaining the backup path information, the requester updates the forwarding rules of the data plane;

[0038] Migrate the session state of the original path to the backup path to complete the switchover operation, and perform local testing to confirm that data can be transmitted normally on the backup path.

[0039] In a second aspect, the present invention provides an APN6 network dynamic switching optimization system based on QoS prediction. When the system is implemented, the above-mentioned APN6 network dynamic switching optimization method based on QoS prediction is executed. The system includes:

[0040] The data collection module collects QoS metrics for different nodes in the APN6 network link based on a preset sampling strategy. QoS metrics include microsecond-level one-way latency, jitter calculated based on IETF RFC 3393, sliding window packet loss rate, current flow rate, and the DSCP field from the APN6 header.

[0041] The model building module builds a time-dimensional prediction model based on a temporal convolutional network combined with a temporal attention mechanism. The model inputs QoS indicators and outputs a predicted time result for predicting QoS trends in the short term. It builds a spatial-dimensional prediction model based on a graph neural network. The model inputs QoS indicators and outputs a predicted spatial result for predicting the mutual influence strength of each node in the network topology. It builds a dynamic-dimensional prediction model based on sliding window incremental learning. The model inputs QoS indicators and outputs a predicted dynamic result for updating model parameters.

[0042] The path switching module weightedly integrates the temporal prediction results, spatial prediction results, and dynamic prediction results to obtain a predicted link quality score. When the predicted link quality score is less than a preset threshold, the APN6 path switching is triggered.

[0043] According to a third aspect, a terminal is provided, including:

[0044] processor, memory, wherein

[0045] The memory is used to store computer programs,

[0046] The processor is used to call and run the computer program from the memory, so that the terminal executes the above-mentioned terminal method.

[0047] In a fourth aspect, a computer-readable storage medium is provided, wherein instructions are stored in the computer-readable storage medium, and when the computer-readable storage medium is run on a computer, the computer executes the methods described in the above aspects.

[0048] The beneficial effect of the present invention is that the APN6 network dynamic switching optimization method, system, terminal and medium based on QoS prediction provided by the present invention accurately collect APN6 network link QoS indicators through a preset sampling strategy, and use time convolutional network and temporal attention, graph neural network, and sliding window incremental learning to respectively construct three-dimensional prediction models, analyze data from multiple perspectives of time trend, spatial impact, and dynamic change, and obtain a link quality score by weighted comprehensive prediction results. When the score is lower than the threshold, path switching is triggered, realizing comprehensive, real-time monitoring and intelligent prediction of network status, effectively improving APN6 network resource scheduling efficiency and service quality, and ensuring the stability and reliability of business transmission.

[0049] In addition, the present invention has a reliable design principle, a simple structure and a very broad application prospect. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0051] Figure 1 This is a schematic flowchart of an APN6 network dynamic switching optimization method based on QoS prediction according to an embodiment of the present invention.

[0052] Figure 2 It is the hybrid prediction model architecture in the embodiment of this application.

[0053] Figure 3It is a schematic block diagram of an APN6 network dynamic switching optimization system based on QoS prediction according to an embodiment of the present invention.

[0054] Figure 4 A schematic diagram of the structure of a terminal provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0055] In order to enable those skilled in the art to better understand the technical solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of the present invention.

[0056] Key Terms:

[0057] QoS (Quality of Service) is a key concept in network communications. It is used to measure the network's ability to provide service assurance for specific business flows. It involves multiple indicators such as bandwidth, latency, and packet loss rate. Its core goal is to ensure differentiated service assurance for different types of services (such as voice, video, and data) when network resources are limited.

[0058] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art of the present invention. The terms used in this specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention.

[0059] The APN6 network dynamic switching optimization method based on QoS prediction provided in an embodiment of the present invention is executed by a computer device. Accordingly, the APN6 network dynamic switching optimization system based on QoS prediction runs in the computer device.

[0060] Figure 1 This is a schematic flow chart of an APN6 network dynamic switching optimization method based on QoS prediction according to an embodiment of the present invention. Figure 1 The execution subject may be an APN6 network dynamic switching optimization system based on QoS prediction. According to different requirements, the order of the steps in the flowchart may be changed, and some steps may be omitted.

[0061] like Figure 1 and Figure 2 As shown, the method includes:

[0062] Step S1: QoS indicators of different nodes in the APN6 network link are collected based on a preset sampling strategy. The QoS indicators include microsecond-level one-way delay, jitter calculated based on IETF RFC 3393, sliding window packet loss rate, current flow rate, and the DSCP field obtained from the APN6 header.

[0063] After collecting QoS metrics, preprocess the data: Use the NTPv4 protocol to calibrate the system clock to an error of less than 1ms to ensure accurate sampling. If an abnormal value significantly differs from the previous sampling period, log it and take the average of the values from the two adjacent sampling periods as the value for that sampling period. If continuous sampling anomalies occur, report an anomaly alarm.

[0064] Step S2: A time dimension prediction model is constructed based on a temporal convolutional network combined with a temporal attention mechanism. The model inputs the QoS indicator and outputs a prediction time result for the QoS trend in the short term.

[0065] By capturing the dynamic temporal patterns of QoS metrics (such as microsecond-level latency and jitter), accurate predictions of network performance trends over short periods of time can be achieved. For example, potential risks such as sudden increases in link latency and jitter can be detected in advance, providing a "time lead" for path switching and avoiding service interruptions caused by delayed real-time response. This is particularly applicable to latency-sensitive real-time services (such as industrial control and video conferencing).

[0066] A spatial dimension prediction model is built based on a graph neural network. The model inputs QoS indicators and outputs a prediction spatial result of the mutual influence strength of each node in the predicted network topology.

[0067] Using the network topology as a graph, this model models the strength of interactions between nodes and explores the spatial dependencies of link quality (e.g., the cascading impact of an increase in packet loss on a node on surrounding nodes). Unlike isolated analysis of a single node, this model can assess the spread of network congestion from a global perspective, avoiding misjudgments due to localized metric anomalies and improving the accuracy of handover decisions. It is suitable for network resource scheduling in complex topologies.

[0068] A dynamic dimension prediction model is built based on sliding window incremental learning. The model inputs QoS indicators and outputs dynamic prediction results for updating model parameters.

[0069] By continuously receiving new QoS data and updating model parameters, the system adapts to dynamic changes in network traffic (such as traffic bursts and service tidal effects), preventing model failure due to data distribution drift. For example, when network load fluctuates frequently, the model can adjust its prediction logic in real time to ensure long-term prediction accuracy, reduce the risk of misjudgment caused by "model staleness," and improve the system's robustness in dynamic scenarios.

[0070] Step S3: weightedly integrate the time prediction result, the spatial prediction result, and the dynamic prediction result to obtain a predicted link quality score. When the predicted link quality score is less than a preset threshold, APN6 path switching is triggered.

[0071] Optionally, as an embodiment of the present invention, before step S1, a dedicated hardware embedded probe module is integrated into the network processing unit of the router interface chip to support parallel processing of 8*100Gbps interfaces, and a P4 programmable pipeline is used to achieve zero-copy data acquisition, reducing CPU intervention.

[0072] Optionally, as an embodiment of the present invention, in the time dimension prediction model:

[0073] Microsecond-level one-way latency: As a timing-sensitive metric, time series fluctuations in latency directly reflect changes in link transmission efficiency. By capturing historical latency trends (such as continuous increases and decreases) and sudden jumps, the model predicts the risk of latency increases in the short term, providing a basis for real-time service scheduling.

[0074] Jitter based on IETF RFC 3393: Jitter is essentially the rate of change of delay. The model analyzes the temporal distribution of jitter (such as variance and peak interval) to predict the deterioration trend of delay stability. For example, it can identify jitter exacerbation caused by network congestion in advance to avoid affecting the quality of streaming services such as voice and video.

[0075] Current traffic rate: The time series of traffic rate reflects changes in traffic load. The model combines historical traffic rate peaks with periodic patterns (such as morning and evening rush hours) to predict congestion that may be caused by short-term traffic surges and assist in determining the changing trends of latency and packet loss rate.

[0076] In the spatial dimension prediction model:

[0077] Sliding Window Packet Loss Rate: Packet loss rate is a direct indicator of node or link failure. Graph neural networks use the packet loss rate of each node as a graph node feature and calculate the spatial propagation effect of the packet loss rate using the edge weights (topological connections) between nodes. For example, when the packet loss rate of a core node increases, the model can predict its cascading impact on adjacent nodes, preventing local failures from being misidentified as global issues.

[0078] DSCP field (Service Differentiator in the APN6 header): DSCP identifies service priority (e.g., real-time vs. non-real-time services). The model uses this as a node attribute and, combined with the topology, analyzes resource competition among services of different priorities within the network. For example, the DSCP field of high-priority services can influence the model's calculation of inter-node resource allocation weights, thereby more accurately predicting the risk of QoS degradation for low-priority services.

[0079] In the dynamic dimension prediction model:

[0080] Incremental learning uses a sliding window to continuously ingest the latest data on metrics such as latency, jitter, packet loss rate, flow rate, and DSCP, updating model parameters in real time. For example, when a network traffic burst causes a sudden increase in flow rate, the model can quickly adjust its prediction weights for packet loss rate and latency, avoiding prediction bias caused by outdated historical data and ensuring robustness in scenarios with fluctuating traffic.

[0081] This model captures the real-time coupling relationships between QoS metrics (e.g., the chain reaction of increased traffic rate, increased latency, and increased packet loss), and continuously optimizes the correlation weights between metrics through incremental learning. For example, when the DSCP distribution changes due to the launch of new services, the model can dynamically adjust the QoS metric prediction logic for services of different priority levels, improving prediction accuracy in dynamic scenarios.

[0082] Optionally, as an embodiment of the present invention, the sampling strategy includes a basic sampling period and a burst traffic trigger;

[0083] The basic sampling period is a preset value (10ms is used in this embodiment, and this value can be adjusted dynamically);

[0084] The burst traffic trigger is when the flow rate change rate is greater than 15%, and millisecond-level high-frequency sampling is started, with a sampling rate of 1ms.

[0085] Optionally, as an embodiment of the present invention, in step S2, the construction process of the three prediction models are:

[0086] Determine the prediction task type (objective function) and define the evaluation metrics;

[0087] Collect historical QoS indicator data and perform feature extraction, dividing the data into training sets, validation sets, and test sets;

[0088] After selecting the appropriate model architecture, the model is trained based on the training set, and the model is continuously corrected through the validation set to obtain the trained model;

[0089] After testing the trained model based on the test set, the performance of the model is evaluated, and the parameters of the model are corrected to obtain the final prediction model.

[0090] Optionally, as an embodiment of the present invention, the time dimension prediction model includes a dilated convolution layer and a multi-head attention layer, and the time dimension prediction model algorithm is implemented as follows:

[0091] class TemporalPredictor(nn.Module):

[0092] def __init__(self):

[0093] self.tcn = TCNBlock(dilation=[1,2,4,8])

[0094] self.attention = MultiHeadAttention(heads=4)

[0095] def forward(self, x):

[0096] x = self.tcn(x) # [B, T, C]

[0097] return self.attention(x, x, x)

[0098] The output of the prediction time results for the QoS trend in the short term includes:

[0099] After preprocessing the QoS indicators, a time series data matrix is obtained. The time series data matrix includes batch size, time step, and feature dimension.

[0100] Different dilation rates are set, and holes are inserted between the convolution kernel elements based on the dilation rate to expand the convolution layer. Time series features at different time scales are extracted to obtain a sequence of fused multi-scale features. Assuming the input feature map is X, taking dilation (dilation rate) = 2 as an example, the specific calculation steps are as follows:

[0101] Assuming the convolution kernel size is k=3 and dilation=2, the actual convolution span is k+(k-1)×(dilation-1)=3+2×1=5 time steps, but it is only sampled at the original kernel position (with an interval of 1 time step).

[0102] For each time step t, the convolution operation aggregates the features of the three positions t-2, t, and t+2 (the span is 5 time steps, but only 3 points are taken). The formula is:

[0103] ,

[0104] Among them, W is the convolution kernel weight and b is the bias.

[0105] Four layers of dilated convolution with dilation=[1,2,4,8] process the input in sequence, capturing the dependencies of 1, 2, 4, and 8 time steps respectively, and finally output a sequence that integrates multi-scale features.

[0106] The multi-head attention mechanism is used to project the sequence of multi-scale features into multiple attention heads. The attention score of each attention head is calculated separately and then concatenated according to the feature dimension to obtain the features with temporal weights as the most accurate prediction time result for QoS trends in the short term in the future.

[0107] Let the input features be Q, K, V, (Q = query vector, K = key vector, V = value vector, usually Q = K = V = X), map the input to query, key, and value vectors:

[0108] , , ,

[0109] in, 、 、 , / Number of attention heads;

[0110] The correlation between time steps is calculated by dot product to obtain the attention score:

[0111] ,

[0112] in, is a scaling factor to prevent large values from causing the softmax gradient to vanish. (For example, if a sudden increase in flow rate occurs at a certain time step t, the corresponding The score will be significantly higher than other time steps, and the weight will be close to 1 after softmax, thereby strengthening the characteristics of this time step in V (such as the sudden change in delay corresponding to high flow rate).

[0113] Multiple attention heads perform the above steps independently. In this embodiment, four are used to obtain , concatenate the multi-head outputs according to the feature dimension:

[0114] ,

[0115] in, The output projection matrix is the same as the input dimension after stitching.

[0116] In summary, dilated convolution ensures that the output of each time step depends solely on the input at the past and current moments, preventing future information leakage and conforming to the causal logic of time series prediction. When calculating the attention score, the influence of future time steps is masked, ensuring that the model makes predictions based solely on historical data.

[0117] Optionally, as an embodiment of the present invention, the spatial dimension prediction model algorithm is implemented as follows:

[0118] class TopoGAT(nn.Module):

[0119] def forward(self, h, adj):

[0120] # h: node feature matrix [N, F]

[0121] # adj: adjacency matrix [N, N]

[0122] attention = torch.matmul(h, hT) * adj

[0123] return torch.softmax(attention, dim=1)

[0124] The prediction spatial results of the mutual influence intensity of each node in the output prediction network topology specifically include:

[0125] Construct a node feature matrix h of shape [number of nodes, feature dimension], which stores the QoS indicators of each node in the network; construct an adjacency matrix for each node;

[0126] The feature similarity between all nodes is calculated based on the dot product operation combined with the node feature matrix: h·h T , get the N×N similarity matrix, where similarity i,j Represents the dot product of the feature vectors of node i and node j.

[0127] Calculate the product of the feature similarity of each node and the adjacency matrix (only retain the similarity of topologically connected nodes, and set the similarity of disconnected nodes to 0), and convert the product through softmax to the degree of attention each node pays to different adjacent nodes;

[0128] Each node obtains new features by weighted aggregation of the features of adjacent nodes based on the degree of attention. For example, there are nodes 1, 2, and 3. Node 1 is connected to nodes 2 and 3, node 2 is connected to node 1, and node 3 is connected to node 1. The new feature of node 1 is the weighted average of the features of its neighboring nodes 2 and 3 according to the attention weight. If node 2 is congested (increased latency, increased packet loss rate), its node feature matrix will change, resulting in a decrease in its similarity with the adjacent node 1. The node's attention to node 2 will decrease, while node 1's attention to node 3 may increase. That is, node 1 pays more attention to the non-congested node 3. When node 1 needs to switch paths, based on the updated attention weight, it will give priority to paths connected to low-congestion nodes (such as node 3).

[0129] After performing attention calculation and multi-head attention fusion on the new features based on the attention mechanism of the GAT layer (the above calculation method is used, the only difference is that the node feature matrix is transformed into the feature matrix of the new space before subsequent calculation), the inter-node weight matrix is output as the prediction space result of the mutual influence intensity of each node in the predicted network topology.

[0130] Optionally, as an embodiment of the present invention, the dynamic dimension prediction model algorithm is implemented as follows:

[0131] def dynamic_update(new_data):

[0132] # Sliding Window Cache

[0133] buffer.append(new_data)

[0134] if len(buffer)>= BATCH_SIZE:

[0135] # Incremental training

[0136] loss = model.train_on_batch(buffer)

[0137] # Dynamically adjust the learning rate

[0138] adjust_lr(based_on=loss)

[0139] The output of the prediction dynamic results used to update the model parameters specifically includes:

[0140] The latest QoS metrics are stored in a fixed-size array. When the array is full and the latest data arrives, the oldest data is overwritten. (Based on the above strategy, data is collected and the rate of change between the current sampling point and the previous sampling point is calculated in real time. When a sudden change in flow rate is detected, the sampling period is switched and the sliding window is reset.)

[0141] When the sliding window is filled with data, batch training is started. The prediction results are obtained based on the current batch data through forward propagation of the model, and the loss function of the batch data is calculated. Based on the loss function, the gradient of the loss with respect to all parameters is calculated through the back propagation algorithm.

[0142] The gradient of the current batch is accumulated into a cumulative gradient variable. When the number of accumulated batches reaches the preset value, the model parameters are updated in combination with the learning rate as the prediction dynamic result:

[0143] θ←θ-α·▽ θ L(θ;batch_data)

[0144] Among them, α is the learning rate and L is the loss function.

[0145] Calculate the ratio of the current batch loss to the average loss of the previous N batches, and adjust the learning rate based on the ratio.

[0146] Optionally, as an embodiment of the present invention, the weighted integration of the time prediction result, the spatial prediction result, and the dynamic prediction result to obtain the predicted link quality score specifically includes:

[0147] ,

[0148] in, The final QoS prediction result is mapped to a link quality score of 0-100;

[0149] : The output of the time dimension prediction model, which represents the temporal trend (such as the delay change in the next 5 seconds).

[0150] : The output of the spatial dimension prediction model, quantifying the impact of topological correlation (such as the cascading effect of congestion in adjacent nodes on the current link).

[0151] : The output of the dynamic dimension prediction model reflects the ability to adapt to sudden changes (such as immediate response when flow rate suddenly increases).

[0152] 、 、 : Dynamic weight coefficient, which ensures that the sum of the three coefficients is 1 and is adaptively adjusted according to the network scenario.

[0153] Optionally, as an embodiment of the present invention, when the predicted link quality score is less than a preset threshold, the specific steps of triggering the APN6 path switch include:

[0154] The APN6-CP protocol header extends the relevant message types for path switching control. The message types are shown in Table 1:

[0155] Table 1 Message types

[0156] Type Code Message Name direction Functional Description 0x0A PRE_SWITCH_REQ Requester → Target Path reservation request with prediction results 0x0B PATH_RESERVE_ACK Target → Requester Confirmation of reserved resources 0x0C FAST_FAILOVER Control plane → Data plane Quickly switch execution instructions

[0157] When the predicted link quality score is less than the preset threshold, the requester sends a PRE_SWITCH_REQ message to the target node, which carries the link quality prediction result and a request to reserve the target path resources;

[0158] After receiving the PRE_SWITCH_REQ message, if the target node's own resources meet the requester's reservation requirements, it returns a PATH_RESERVE_ACK message to confirm the reserved resources. When the requester receives the PATH_RESERVE_ACK message and confirms that the resource reservation is successful, a low-latency backup path is established based on the target node with the reserved resources. The control plane sends a FAST_FAILOVER fast switch execution instruction to the data plane, instructing the data plane to preferentially forward data to the pre-established low-latency backup path based on the identifier, while keeping the original path session state synchronized.

[0159] After receiving the PRE_SWITCH_REQ message, if the target node has insufficient resources, it returns a PATH_RESERVE_NACK message to inform the requester to switch to the backup path.

[0160] Optionally, as an embodiment of the present invention, switching the backup path specifically includes:

[0161] After receiving the PATH_RESERVE_NACK message, the requester starts searching its local path table for an alternative path. (In some network architectures, the requester device queries its built-in path table to find an alternative path that meets service bandwidth, latency, and other requirements. If the local path table contains insufficient information, it may send a path query request to the network controller (such as an SDN controller). The controller calculates and returns an appropriate alternative path based on the global network topology and resource information.)

[0162] After obtaining the backup path information, the requester updates the forwarding rules of the data plane. Taking the SRv6 (Segment Routing over IPv6) network as an example, the requester will modify the destination address or routing header information of the data packet to the Segment Identifier (SID) list of the backup path. These SIDs represent a path in the network, thereby guiding the data packet to be transmitted along the backup path.

[0163] The switchover operation is completed by migrating the session state on the original path to the backup path. For example, in a TCP connection, state information such as the sequence number and window size must be migrated. In some network architectures, specific state synchronization mechanisms, such as sharing session state information between network nodes, enable fast switchover without service interruption. Local testing is performed to confirm that data can be transmitted normally on the backup path. The switchover results are then notified to relevant network nodes, including the source device, destination device, and intermediate nodes along the path, so that they can update their own state and cooperate with data transmission on the new path.

[0164] This approach builds a comprehensive and precise guarantee system centered around dynamic handover optimization for APN6 networks. It establishes a multi-dimensional prediction mechanism, leveraging a temporal convolutional network combined with temporal attention, graph neural networks, and sliding window incremental learning to capture QoS metrics from temporal trends, spatial correlations, and dynamic changes. It also meticulously collects key data such as microsecond latency and, through weighted fusion, outputs a link quality score, providing a reliable basis for handover decisions.

[0165] Furthermore, it implements proactive intelligent scheduling. When the score falls below the threshold, it triggers an APN6 path switch, shifting from passive response to proactive avoidance, effectively minimizing service interruptions. Furthermore, the algorithm boasts a flexible architecture and incremental learning to reduce overhead. Combining standardization with foresight, it can adapt to diverse network environments, providing an efficient solution for traffic scheduling in future networks such as 6G.

[0166] In some embodiments, the APN6 network dynamic switching optimization system based on QoS prediction may include multiple functional modules composed of computer program segments. The computer program of each program segment in the APN6 network dynamic switching optimization system based on QoS prediction may be stored in a memory of a computer device and executed by at least one processor to perform (see Figure 1 Description) APN6 network dynamic switching optimization function based on QoS prediction.

[0167] In this embodiment, the APN6 network dynamic switching optimization system based on QoS prediction can be divided into multiple functional modules according to the functions it performs, such as Figure 3 As shown. The functional modules of the system may include: a data acquisition module, a model building module, and a path switching module. The module referred to in the present invention refers to a series of computer program segments that can be executed by at least one processor and can perform fixed functions, which are stored in the memory. In this embodiment, the functions of each module will be described in detail in subsequent embodiments. The system includes:

[0168] The data collection module collects QoS metrics for different nodes in the APN6 network link based on a preset sampling strategy. QoS metrics include microsecond-level one-way latency, jitter calculated based on IETF RFC 3393, sliding window packet loss rate, current flow rate, and the DSCP field from the APN6 header.

[0169] The model building module builds a time-dimensional prediction model based on a temporal convolutional network combined with a temporal attention mechanism. The model inputs QoS indicators and outputs a predicted time result for predicting QoS trends in the short term. It builds a spatial-dimensional prediction model based on a graph neural network. The model inputs QoS indicators and outputs a predicted spatial result for predicting the mutual influence strength of each node in the network topology. It builds a dynamic-dimensional prediction model based on sliding window incremental learning. The model inputs QoS indicators and outputs a predicted dynamic result for updating model parameters.

[0170] The path switching module weightedly integrates the temporal prediction results, spatial prediction results, and dynamic prediction results to obtain a predicted link quality score. When the predicted link quality score is less than a preset threshold, the APN6 path switching is triggered.

[0171] Figure 4 A structural diagram of a terminal provided in an embodiment of the present invention, which can be used to execute the method for APN6 network dynamic switching optimization based on QoS prediction provided in an embodiment of the present invention.

[0172] The terminal may include a processor, a memory, and a communication unit. These components communicate via one or more buses. Those skilled in the art will appreciate that the server structure shown in the figure does not limit the present invention. It may be a bus structure or a star structure, and may include more or fewer components than shown, or combine certain components or arrange the components differently.

[0173] The memory can be used to store execution instructions for the processor. The memory can be implemented by any type of volatile or non-volatile storage terminal, or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk, or optical disk. When the execution instructions in the memory are executed by the processor, the terminal is able to perform some or all of the steps in the above-described method embodiments.

[0174] The processor is the control center of the storage terminal, which uses various interfaces and lines to connect the various parts of the entire electronic terminal. It executes various functions of the electronic terminal and / or processes data by running or executing software programs and / or modules stored in the memory, and calling data stored in the memory. The processor can be composed of an integrated circuit (IC), for example, it can be composed of a single packaged IC, or it can be composed of multiple packaged ICs with the same or different functions. For example, the processor can only include a central processing unit (CPU). In the embodiment of the present invention, the CPU can have a single computing core or multiple computing cores.

[0175] The communication unit is used to establish a communication channel so that the storage terminal can communicate with other terminals, receive user data sent by other terminals, or send user data to other terminals.

[0176] The present invention also provides a computer storage medium, wherein the computer storage medium may store a program that, when executed, may include some or all of the steps of each embodiment provided herein. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).

[0177] Those skilled in the art will clearly understand that the techniques in the embodiments of the present invention can be implemented using software plus a necessary general-purpose hardware platform. Based on this understanding, the technical solutions in the embodiments of the present invention, or the portion that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium such as a USB flash drive, a mobile hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, among other media capable of storing program code, and includes instructions for causing a computer terminal (which can be a personal computer, a server, or a second terminal, a network terminal, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention.

[0178] In this specification, the same or similar parts between the various embodiments can be referred to each other. In particular, for the terminal embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description in the method embodiment.

[0179] In the several embodiments provided by the present invention, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are merely illustrative. For example, the division of the modules is merely a logical function division. In actual implementation, there may be other division methods, such as multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of systems or modules, and can be electrical, mechanical or other forms.

[0180] The modules described as separate components may or may not be physically separate, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules may be selected to achieve the purpose of the present embodiment according to actual needs.

[0181] In addition, each functional module in each embodiment of the present invention may be integrated into one processing module, or each module may exist physically separately, or two or more modules may be integrated into one module.

[0182] Although the present invention has been described in detail with reference to the accompanying drawings and in conjunction with preferred embodiments, the present invention is not limited thereto. Without departing from the spirit and essence of the present invention, persons of ordinary skill in the art may make various equivalent modifications or substitutions to the embodiments of the present invention, and such modifications or substitutions shall be within the scope of the present invention. Any changes or substitutions that can be easily conceived by persons skilled in the art within the technical scope disclosed in the present invention shall be within the scope of protection of the present invention.

Claims

1. A method for optimizing dynamic handover of APN6 network based on QoS prediction, characterized in that: include: QoS metrics are collected at different nodes on the APN6 network based on a preset sampling strategy. QoS metrics include microsecond-level one-way latency, jitter calculated based on IETF RFC 3393, sliding window packet loss rate, current flow rate, and the DSCP field from the APN6 header. A time dimension prediction model is constructed based on a temporal convolutional network combined with a temporal attention mechanism. The model inputs QoS indicators and outputs a time prediction result that predicts the QoS trend in the short term. A spatial dimension prediction model is built based on a graph neural network. The model inputs QoS indicators and outputs a prediction spatial result of the mutual influence strength of each node in the predicted network topology. A dynamic dimension prediction model is built based on sliding window incremental learning. The model inputs QoS indicators and outputs dynamic prediction results for updating model parameters. The weighted comprehensive time prediction results, spatial prediction results and dynamic prediction results are used to obtain the predicted link quality score. When the predicted link quality score is less than the preset threshold, the APN6 path switching is triggered.

2. The APN6 network dynamic switching optimization method based on QoS prediction according to claim 1, characterized in that: The sampling strategy includes basic sampling period and burst traffic trigger; The basic sampling period is the preset value; The burst traffic trigger is when the flow rate change rate is greater than 15%, and sampling is performed every 1ms.

3. The APN6 network dynamic switching optimization method based on QoS prediction according to claim 1, characterized in that: The time dimension prediction model includes a dilated convolution layer and a multi-head attention layer, and the output of the predicted time results for predicting the QoS trend in the short term in the future specifically includes: After preprocessing the QoS indicators, a time series data matrix is obtained. The time series data matrix includes batch size, time step, and feature dimension. Set different dilation rates, insert holes between convolution kernel elements based on the dilation rate to expand the convolution layer, extract temporal features of different time scales, and obtain a sequence of multi-scale features; The multi-head attention mechanism is used to project the sequence of multi-scale features into multiple attention heads. The attention score of each attention head is calculated separately and then concatenated according to the feature dimension to obtain the features with temporal weights as the most accurate prediction time result for QoS trends in the short term in the future.

4. The APN6 network dynamic switching optimization method based on QoS prediction according to claim 1, characterized in that: The prediction spatial results of the mutual influence intensity of each node in the output prediction network topology specifically include: Construct a node feature matrix of the shape [number of nodes, feature dimension], which stores the QoS indicators of each node in the network; construct an adjacency matrix for each node; Calculate the feature similarity between all nodes based on the dot product operation combined with the node feature matrix; Calculate the product of the feature similarity of each node and the adjacency matrix, and convert the product into the degree of attention of each node to different adjacent nodes through softmax; Each node obtains new features by weighted aggregation of features of adjacent nodes according to the degree of attention; After the attention mechanism based on the GAT layer performs attention calculation and multi-head attention fusion on the new features, the weight matrix between nodes is output as the prediction space result of the mutual influence intensity of each node in the predicted network topology.

5. The APN6 network dynamic switching optimization method based on QoS prediction according to claim 1, characterized in that: The output of the prediction dynamic results used to update the model parameters specifically includes: The latest QoS indicators are stored in a fixed-size array. When the array is filled with data and the latest data arrives, the oldest data is overwritten. When the sliding window is filled with data, the model is forward-propagated based on the current batch of data to obtain the prediction result, and the loss function of the batch of data is calculated; based on the loss function, the gradient of the loss with respect to all parameters is calculated through the back-propagation algorithm; Accumulate the gradient of the current batch into a cumulative gradient variable. When the number of accumulated batches reaches the preset value, update the model parameters in combination with the learning rate as the prediction dynamic result. Calculate the ratio of the current batch loss to the average loss of the previous N batches, and adjust the learning rate based on the ratio.

6. The APN6 network dynamic switching optimization method based on QoS prediction according to claim 1, characterized in that: When the predicted link quality score is less than the preset threshold, the specific steps to trigger APN6 path switching include: The APN6-CP protocol header extends the relevant message types for path switching control, including PRE_SWITCH_REQ, PATH_RESERVE_ACK, and FAST_FAILOVER. When the predicted link quality score is less than the preset threshold, the requester sends a PRE_SWITCH_REQ message to the target node, which carries the link quality prediction result and a request to reserve the target path resources; After receiving the PRE_SWITCH_REQ message, if the target node's own resources meet the requester's reservation requirements, it returns a PATH_RESERVE_ACK message to confirm the reserved resources. When the requester receives the PATH_RESERVE_ACK message and confirms that the resource reservation is successful, a low-latency backup path is established based on the target node with the reserved resources. The control plane sends a FAST_FAILOVER fast switch execution instruction to the data plane, instructing the data plane to preferentially forward data to the pre-established low-latency backup path based on the identifier, while keeping the original path session state synchronized. After receiving the PRE_SWITCH_REQ message, if the target node has insufficient resources, it returns a PATH_RESERVE_NACK message to inform the requester to switch to the backup path.

7. The APN6 network dynamic switching optimization method based on QoS prediction according to claim 6, characterized in that: Switching to the backup path specifically includes: After receiving the PATH_RESERVE_NACK message, the requester starts searching the local path table for the backup path. After obtaining the backup path information, the requester updates the forwarding rules of the data plane; Migrate the session state of the original path to the backup path to complete the switchover operation, and perform local testing to confirm that data can be transmitted normally on the backup path.

8. An APN6 network dynamic switching optimization system based on QoS prediction, characterized in that: When implemented, the system performs the APN6 network dynamic switching optimization method based on QoS prediction according to any one of claims 1 to 7, and the system includes: The data collection module collects QoS metrics for different nodes in the APN6 network link based on a preset sampling strategy. QoS metrics include microsecond-level one-way latency, jitter calculated based on IETF RFC 3393, sliding window packet loss rate, current flow rate, and the DSCP field from the APN6 header. The model building module builds a time-dimensional prediction model based on a temporal convolutional network combined with a temporal attention mechanism. The model inputs QoS indicators and outputs a predicted time result for predicting QoS trends in the short term. It builds a spatial-dimensional prediction model based on a graph neural network. The model inputs QoS indicators and outputs a predicted spatial result for predicting the mutual influence strength of each node in the network topology. It builds a dynamic-dimensional prediction model based on sliding window incremental learning. The model inputs QoS indicators and outputs a predicted dynamic result for updating model parameters. The path switching module weightedly integrates the temporal prediction results, spatial prediction results, and dynamic prediction results to obtain a predicted link quality score. When the predicted link quality score is less than a preset threshold, the APN6 path switching is triggered.

9. A terminal, characterized in that: include: A memory, used for storing an APN6 network dynamic switching optimization program based on QoS prediction; A processor is used to implement the steps of the APN6 network dynamic switching optimization method based on QoS prediction as described in any one of claims 1-7 when executing the APN6 network dynamic switching optimization program based on QoS prediction.

10. A computer-readable storage medium, characterized in that The readable storage medium stores an APN6 network dynamic switching optimization program based on QoS prediction. When the APN6 network dynamic switching optimization program based on QoS prediction is executed by the processor, the steps of the APN6 network dynamic switching optimization method based on QoS prediction as described in any one of claims 1-7 are implemented.

Citation Information

Patent Citations

  • Streaming media QoE prediction method based on convolutional recurrent neural network under attention mechanism

    CN115883528A

  • Fault-tolerant method for improving underwater robot networking robustness

    CN118741573A