A QoS-aware multi-path routing control method based on LSTM prediction
Patent Information
- Application Number
- CN202610469653.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-04-10
- Publication Date
- 2026-08-18
AI Technical Summary
随着网络业务类型日益复杂,传统仅关注能耗的路由机制已难以同时满足不同业务对时延、可靠性和带宽的差异化要求
(1)本发明利用LSTM模型对链路未来状态进行预测,使路由决策能够依据未来时延、丢包率和带宽变化趋势主动避开拥塞路径和高风险路径,从而将传统被动响应式路由提升为主动预测式路由。
Smart Images

Figure CN122601545A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of wireless sensor network routing technology, specifically relating to a QoS-aware multipath routing control method based on LSTM prediction. Background Technology
[0002] Wireless Sensor Networks (WSNs), as a crucial communication infrastructure in the Internet of Things (IoT), are widely used in various scenarios such as environmental monitoring, industrial control, video surveillance, and military reconnaissance. With the increasing complexity of network services, traditional routing mechanisms that only focus on energy consumption are no longer sufficient to simultaneously meet the diverse requirements of different services regarding latency, reliability, and bandwidth.
[0003] Many existing QoS routing control methods rely on the current network state to make passive decisions, and can only switch paths after congestion, packet loss, or link deterioration has already occurred. They lack the ability to predict future network state changes. Therefore, in scenarios with sudden service load or rapid link fluctuations, problems such as path oscillation, increased end-to-end latency, and increased packet loss are likely to occur.
[0004] Furthermore, while existing multi-path routing control methods can alleviate single-path overload to some extent, they typically treat multi-path as a simple traffic sharing mechanism, failing to fully integrate service priorities with dynamic adjustments to routing targets. This results in real-time services, critical services, and general services struggling to obtain truly differentiated service guarantees within the same network. Meanwhile, some solutions incorporating reinforcement learning or complex intelligent optimization algorithms, while improving decision-making capabilities, suffer from high computational and communication overhead, making them unsuitable for deployment in resource-constrained wireless sensor network nodes.
[0005] In summary, there is an urgent need to propose a QoS-aware routing control method that can predict future link states under resource-constrained conditions, dynamically optimize routing objectives for different services, and combine multi-path mechanisms to achieve fine-grained traffic allocation. Summary of the Invention
[0006] To address the technical problems mentioned in the background section, this invention proposes a QoS-aware multipath routing control method based on LSTM prediction.
[0007] The technical solution of this invention is as follows: In a wireless sensor network, firstly, historical QoS state sequences of links are collected, including latency, packet loss rate, and available bandwidth; then, the LSTM model is used to predict the link state within a future time window; next, the latency weight, reliability weight, and energy consumption weight in the path cost function are dynamically configured according to different service types to construct a prediction cost function; further, a K-shortest path search and constraint filtering mechanism is used to select candidate paths that meet the service QoS requirements; finally, a heuristic traffic allocation algorithm based on the reciprocal of the path prediction cost is used to adaptively allocate the service flow to multiple paths for transmission.
[0008] The service flow is represented using a six-tuple: f =<s,d,ζ,r,π,Q> Where s represents the source node, d represents the destination node, ζ represents the service type, r represents the average generation rate, π represents the service priority scalar, and Q represents the corresponding QoS constraint set. For real-time streams, For critical data streams, For those who do their best to flow, .
[0009] For a path p from source node s to destination node d, its end-to-end QoS attributes are defined as follows: (1) Path delay:
[0010] in Indicates link transmission delay. This indicates the node queuing delay.
[0011] (2) Packet loss rate along the path:
[0012] in This indicates the packet loss rate of the link.
[0013] (3) Available bandwidth of the path:
[0014] Where H is the number of hops in the path. This indicates the available bandwidth of the link.
[0015] (4) The calculation process of the LSTM prediction model at each time step is as follows:
[0016] in, For the input vector, In hidden state, It is in the cellular state.
[0017] (5) The QoS-aware prediction cost function is defined as:
[0018] And it satisfies: α + β + γ = 1.
[0019] in, and Let E(p) represent the predicted latency and predicted packet loss rate of path p within a future time window, respectively, and let E(p) represent the path energy cost, defined as follows:
[0020] This allows for the penalty of low-energy bottleneck nodes. For different service types, the dynamic weight allocation method is as follows: for the real-time stream REALTIME, α is set to the maximum weight; for the critical data stream CRITICAL, β is set to the maximum weight; and for the best-effort stream BEST_EFFORT, γ is set to the maximum weight.
[0021] (6) The path selection problem is modeled as a multi-constraint path problem:
[0022] The constraints include:
[0023] In the multi-path traffic allocation phase, suppose there are M candidate paths that satisfy the constraints, and the traffic ratio is... The optimization objective is: To reduce computational complexity on resource-constrained nodes, the following heuristic allocation algorithm is further adopted:
[0024] In other words, the lower the cost of path prediction, the more traffic is allocated to that path.
[0025] The beneficial effects of adopting the above technical solution are as follows: (1) This invention uses the LSTM model to predict the future state of the link, so that the routing decision can actively avoid congested paths and high-risk paths based on the future trends of delay, packet loss rate and bandwidth changes, thereby upgrading the traditional passive response routing to active predictive routing.
[0026] (2) The present invention dynamically configures the path cost weight according to different service types, so that real-time flow, critical data flow and best-effort flow can respectively prioritize meeting the requirements of low latency, high reliability and low energy consumption, and achieve true differentiated QoS guarantee.
[0027] (3) The present invention adopts a heuristic multi-path traffic allocation algorithm based on the inverse of path prediction cost, which achieves multi-path adaptive load balancing while ensuring low computational complexity, effectively avoiding single-point congestion and improving network throughput.
[0028] (4) This invention avoids the overuse of nodes with low remaining energy by using energy consumption penalty terms, which helps to extend the network life cycle and improve the overall energy efficiency of the network. Attached Figure Description
[0029] Figure 1 This is a flowchart of the QoS-aware multipath routing control method based on LSTM prediction of the present invention; Figure 2 This is a schematic diagram of the QoS-aware multipath routing network structure based on LSTM prediction in this invention; Detailed Implementation
[0030] The technical solution of the present invention will be described in detail below with reference to the accompanying drawings.
[0031] The basic idea of this invention is as follows: In wireless sensor networks, for heterogeneous service scenarios, the LSTM model is used to predict the link QoS status within a future time window; then, the optimization objective preference in the path cost function is dynamically adjusted according to the service type; on this basis, multiple candidate paths that meet the QoS constraints are searched, and traffic is allocated proportionally according to the path quality, so as to achieve coordinated optimization between low latency, high reliability and low energy consumption.
[0032] like Figure 1 As shown, the QoS-aware multipath routing control method based on LSTM prediction proposed in this invention comprises the following steps: (1) During network operation, each node periodically collects the latency, packet loss rate and available bandwidth information of the link it is on and puts them into a link status time series.
[0033] (2) Extract the historical link state sequence using a fixed time step T, and feed it into the LSTM model to predict the link delay, link packet loss rate and available bandwidth within the future prediction step τ.
[0034] (3) Represent the traffic flow to be transmitted as a six-tuple f =<s,d,ζ,r,π,Q> Based on the service type, determine whether it belongs to real-time flow, critical data flow, or best-effort flow, and determine the corresponding QoS constraints.
[0035] (4) Based on the predicted state values of the links in each path, calculate the predicted end-to-end delay, predicted packet loss rate and predicted available bandwidth of each candidate path using the aforementioned path formula.
[0036] (5) Determine the weight coefficients α, β, and γ according to the business type, and calculate the prediction cost C_p of the candidate path.
[0037] (6) Use the K-shortest path search method to obtain K candidate paths with smaller prediction costs, and then filter out paths that do not meet the requirements according to business constraints.
[0038] (7) If there is only one path in the set of feasible paths, all traffic is forwarded directly along that path; if there are multiple paths in the set of feasible paths, the traffic ratio λ_m of each path is calculated using the heuristic allocation formula, and the traffic is transmitted in parallel according to the ratio.
[0039] (8) During transmission, continuously monitor the link status and prediction error, and update the LSTM model online according to changes in network status to correct model parameters and improve subsequent prediction accuracy.
[0040] (9) Repeat the above process until the business data transmission ends or the network stops operating.
[0041] 2. According to claim 1, the calculation process of path attributes and prediction cost in this embodiment is as follows: (201) For path p, the path delay is calculated as follows: calculate.
[0042] (202) For path p, the path packet loss rate is calculated as follows: calculate.
[0043] (203) For path p, the available bandwidth of the path is calculated as follows: calculate.
[0044] (204) Substitute the predicted values of each link in the path within the future time window into the above formula to obtain the predicted QoS attributes of the path.
[0045] (205) Select the corresponding weight coefficients α, β, and γ according to the business type, and substitute them into the prediction cost function. Calculate the cost of path prediction.
[0046] (206) Utilization The node with the lowest remaining energy on the path is penalized to prevent overuse of nodes that are about to run out of energy.
[0047] 3. In this embodiment, the candidate path search and constraint filtering process can be implemented using the following preferred scheme, namely step (6) above: (301) Predicting costs As the basis for path expansion, Dijkstra's algorithm is first used to find the first shortest path from the source node s to the destination node d. .
[0048] (302) Based on P_1, the Yen algorithm is used to generate the remaining K-1 candidate paths in sequence, forming a candidate path set. .
[0049] (303) For each path in the candidate path set A, calculate its predicted latency, predicted packet loss rate and predicted available bandwidth.
[0050] (304) If the service flow is a real-time flow, then remove all paths with a predicted latency greater than Dmax; if the service flow is a critical data flow, then remove all paths with a predicted packet loss rate greater than Lmax; if the service flow has bandwidth requirements, then remove all paths with a predicted available bandwidth less than the service rate r.
[0051] (305) The remaining paths are combined into a set of feasible paths for subsequent multi-path traffic allocation.
[0052] 4. In this embodiment, the following preferred scheme can be used to implement the multi-path traffic allocation process, namely step (7) above: (401) Suppose there are M paths in the feasible path set, and their predicted costs are respectively .
[0053] (402) If only one path satisfies the constraint, then set the traffic ratio of that path to 1.
[0054] (403) If multiple paths exist, then use Calculate the traffic ratio for each path .
[0055] (404) Distribute the service traffic proportionally to each path for parallel transmission. The smaller the path prediction cost, the larger the proportion of traffic it carries.
[0056] (405) If the predicted state of a certain path deteriorates during subsequent transmission, the candidate path search and traffic redistribution steps are re-executed to complete path reselection and traffic redistribution.
[0057] The embodiments are merely illustrative of the technical concept of the present invention and should not be construed as limiting the scope of protection of the present invention. Any modifications made to the technical solution based on the technical concept proposed in this invention shall fall within the scope of protection of this invention.
Claims
1. A QoS-aware multipath routing control method based on LSTM prediction, characterized in that... The specific process is as follows: (101) Establish a link status monitoring mechanism in the wireless sensor network to sample the QoS status of each link at discrete times. The QoS status includes at least link delay, link packet loss rate and link available bandwidth. (102) Extract the historical state sequence of each link with a fixed-length time window, construct LSTM input samples, and perform multi-step prediction of the link QoS parameters within the future prediction step; (103) For any business flow, it can be formally represented as a six-tuple f =<s,d,ζ,r,π,Q> Where s represents the source node, d represents the destination node, ζ represents the service type, r represents the average generation rate, π represents the service priority scalar, and Q represents the QoS constraint set corresponding to the service flow. (104) Calculate the predicted end-to-end delay, predicted end-to-end packet loss rate and predicted available bandwidth of the path based on the predicted state values of each link in the path. (105) Construct a QoS-aware prediction cost function, and normalize and weight the prediction latency, prediction packet loss rate and path energy consumption cost to obtain the comprehensive prediction cost of the candidate path. (106) Dynamically configure the weight coefficients in the cost function according to the business flow type: give a larger weight to the latency term for real-time flow, give a larger weight to the reliability term for critical data flow, and give a larger weight to the energy consumption term for best-effort flow. (107) The path search problem is represented as a multi-constraint path problem. The K-shortest path search and constraint filtering are combined. First, K candidate paths are obtained based on the prediction cost function, and then the set of feasible paths that meet the business QoS constraints is selected from them. (108) When there is only one path in the set of feasible paths, all traffic is allocated to that path; when there are multiple paths in the set of feasible paths, a heuristic allocation algorithm based on the inverse of the path prediction cost is used to allocate traffic to multiple paths for parallel transmission in proportion. (109) Continuously update the link status observations during network operation and adjust the LSTM model online according to the prediction error to improve the accuracy of subsequent path prediction; (110) Each node forwards data in groups according to the obtained path and traffic allocation ratio until the business data transmission ends.
2. The QoS-aware multipath routing control method based on LSTM prediction according to claim 1, characterized in that, The six-tuple representation of the business flow is as follows: (201) Represent the business flow as a six-tuple f =<s,d,ζ,r,π,Q> ; (202) Where s represents the source node and d represents the destination node; (203) ζ∈{REALTIME, CRITICAL, BEST_EFFORT}, representing real-time stream, critical data stream and best-effort stream respectively; (204) r represents the average generation rate of the business flow; (205)π represents a business priority scalar; (206) Q represents the set of QoS constraints for the service flow, where for real-time flows, Q = {Dmax}; for critical data flows, Q = {Lmax}; and for best-effort flows, Q = .
3. The QoS-aware multipath routing control method based on LSTM prediction according to claim 1, characterized in that, The path QoS attribute is calculated as follows: (301) Path delay is defined as the sum of the transmission delay of each link on the path and the queuing delay of each intermediate node: ; (302) The end-to-end packet loss rate of a path is defined as: ; (303) The available bandwidth of a path is defined as the available bandwidth of the bottleneck link in the path: 。 4. The QoS-aware multipath routing control method based on LSTM prediction according to claim 1, characterized in that, The calculation process of the LSTM prediction model at each time step t is as follows: (401) The forgetting gate is calculated as follows: ; (402) The input gate is calculated as follows: ; (403) The candidate cell state is calculated as follows: ; (404) Cell state updated to: ; (405) The output gate is calculated as follows: ; (406) Hidden state updated to: ; (407) Among them, The input vector at time step t, In hidden state, Let σ represent the cellular state, σ be the sigmoid activation function, and ⊙ denote element-wise multiplication. as well as These are the weight matrix and bias vector to be trained, respectively.
5. The QoS-aware multipath routing control method based on LSTM prediction according to claim 1, characterized in that, The QoS-aware prediction cost function is defined as follows: (501) The path prediction cost is defined as: ; (502) Where C_p is the prediction cost of path p; The predicted delay of path p within a future time window; The predicted packet loss rate for path p within a future time window; Let p be the energy consumption cost of path p; These are the normalization factors; (503) α, β, γ are weighting coefficients, and satisfy α + β + γ = 1.
6. The QoS-aware multipath routing control method based on LSTM prediction according to claim 5, characterized in that, The energy consumption cost of the path is defined as: (601) The path energy consumption cost is defined as: ; (602) Among them, Represents the nodes on path p The remaining energy is used to penalize the node with the smallest remaining energy on the path, so that the path containing the low-energy bottleneck node pays a higher cost, thus avoiding it during routing decisions.
7. The QoS-aware multipath routing control method based on LSTM prediction according to claim 1, characterized in that, The dynamic weight allocation method includes: (701) When the service type is REALTIME, set α > β and α > γ; (702) When the business type is CRITICAL, set β > α and β > γ; (703) When the service type is BEST_EFFORT, set γ > α and γ > β.
8. The QoS-aware multipath routing control method based on LSTM prediction according to claim 1, characterized in that, The multi-constraint path selection satisfies the following conditions: (801) The path selection objective is: ; (802) When the business type is REALTIME, it satisfies ; (803) When the business type is CRITICAL, the following conditions are met. ; (804) When the service requires bandwidth guarantee, it shall meet the following requirements. ; (805) Among them, This represents the path with the minimum prediction cost while satisfying the service QoS constraints.
9. The QoS-aware multipath routing control method based on LSTM prediction according to claim 1, characterized in that, The multipath traffic allocation problem can be expressed as: (901) The optimization objective is: ; (902) The flow ratio satisfies ; (903) The allocation ratio of each path satisfies ; (904) Each path also satisfies the bandwidth constraint. ; (905) Where M represents the number of candidate paths that satisfy the constraints, This indicates that the path is assigned to the m-th path. The proportion of traffic on the platform Representing a path The predicted cost, Representing a path The predicted available bandwidth.
10. The QoS-aware multipath routing control method based on LSTM prediction according to claim 9, characterized in that, The heuristic traffic allocation algorithm is defined as follows: (1001) The heuristic flow allocation formula is: ; (1002) Wherein, the lower the path prediction cost, the higher the proportion of traffic allocated to that path; the higher the path prediction cost, the lower the proportion of traffic allocated to that path, so as to achieve adaptive load balancing among multiple paths.