A method and system for real-time traffic analysis of edge network routing
By collecting and processing packet interval sequences of data streams at edge network nodes, extracting traffic state features and constructing a weight allocation model, and dynamically adjusting the weight vector, the problem of inaccurate path selection in existing technologies is solved, and more efficient link resource allocation is achieved.
Patent Information
- Application Number
- CN202611274195.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-21
- Publication Date
- 2026-11-06
- Estimated Expiration
- 2046-08-21
AI Technical Summary
In existing technologies, edge devices cannot perceive traffic differences under the same service type label, which means that the path selected by the preset weight score may not be the optimal experience in reality, resulting in a link resource mismatch problem.
By collecting packet interval sequences and byte-weighted packet interval sequences of data streams at edge network nodes, performing phase space embedding processing, extracting traffic state features, and constructing a weight allocation model, the weight vector is dynamically adjusted to optimize path selection.
It improves the accuracy of link resource allocation, reduces link resource mismatch, and makes the routing results more consistent with the actual business experience.
Smart Images

Figure CN122824659B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data transmission technology, and more specifically, to a real-time traffic analysis method and system for edge network routing. Background Technology
[0002] Wide area network (WAN) interconnection is a fundamental requirement for enterprise networks. With the widespread adoption of cloud computing and remote work, branch offices need to simultaneously handle various types of business traffic, such as video conferencing, web browsing, and file synchronization. Different services have significantly different network quality requirements. SD-WAN technology emerged in this context, and one of its core capabilities is to route different business traffic to the most suitable path based on the real-time quality status of each candidate link.
[0003] In existing technologies, edge devices typically continuously monitor metrics such as latency, packet loss rate, and available bandwidth for each candidate link. When a data stream arrives, deep packet inspection is used to determine its service type. Then, a weighted sum of the measured metrics for each path is calculated according to a pre-defined set of weights corresponding to that type, and the path with the highest score is selected to carry the traffic. This set of weights is manually configured by the administrator during the deployment phase based on business characteristics; for example, video conferencing traffic has a high latency weight, while file transfer traffic has a high bandwidth weight. Once configured, this set remains fixed for a long period. However, traffic under the same service type label can also have significant differences. Current technology can only apply the same set of weights to traffic with the same type label, failing to perceive these differences. Furthermore, the weights themselves rely on administrator experience for setting, lacking objective quantitative evidence of experience. This means that the path selected based on this weighted score may have the highest score at the rule level, but it may not be the optimal path for the actual experience of that traffic. There is a systematic deviation between the routing results and the actual business experience, which can easily lead to link resource mismatch. Summary of the Invention
[0004] To overcome the aforementioned problems in the prior art, this invention proposes a real-time traffic analysis method and system for edge network routing to solve the above problems.
[0005] This invention provides the following technical solution: A real-time traffic analysis method for edge network routing includes: At edge network nodes, the packet interval sequence and byte-weighted packet interval sequence of the arriving data stream are collected. Phase space embedding is performed on the packet interval sequence and the byte-weighted packet interval sequence to obtain the phase space density matrix and the byte-weighted phase space density matrix; Flow state features are extracted from the phase space density matrix and the byte-weighted phase space density matrix. The flow state features are then combined with the flow type to obtain the comprehensive flow features. The comprehensive traffic characteristics are input into a pre-built weight allocation model to obtain a weight vector; The weight vector is substituted into the path quality scoring function to calculate the path quality score for each candidate link and perform link selection for the data flow.
[0006] Preferably, the step of collecting the packet interval sequence and byte-weighted packet interval sequence of the arriving data stream includes: Set up traffic mirroring collection points at edge network nodes to extract the arrival timestamp sequence and byte length sequence of each data packet in the data stream; The difference between adjacent timestamps is calculated from the arrival timestamp sequence to obtain the packet interval sequence of the data stream; Based on the byte length sequence, the packet interval sequence is weighted by the combined value of the byte size of two adjacent packets to obtain the byte-weighted packet interval sequence of the data stream.
[0007] Preferably, the phase space embedding process for the packet interval sequence and the byte-weighted packet interval sequence includes: Monotonic compression transformations are applied to the packet interval sequence and the byte-weighted packet interval sequence of the data stream, respectively; Map each adjacent interval value in the compressed packet interval sequence to a point in a two-dimensional phase space with the former as the x-axis and the latter as the y-axis, to obtain a scatter set; map each adjacent interval value in the compressed byte-weighted packet interval sequence to a point in a two-dimensional phase space with the former as the x-axis and the latter as the y-axis, to obtain a byte-weighted scatter set. The two-dimensional phase space is uniformly divided into grids of fixed specifications according to a preset boundary. The number of scattered points falling into each grid cell is counted and normalized to obtain the phase space density matrix. The byte-weighted scattered point set is accumulated and normalized with the combined value of the byte amounts of two adjacent packets as weights to obtain the byte-weighted phase space density matrix.
[0008] Preferably, the extraction of flow state features from the phase space density matrix and the byte-weighted phase space density matrix includes: Phase space structure features are extracted from the phase space density matrix. The phase space structure features consist of density centroid coordinates, principal axis orientation angles of density distribution, anisotropy ratio, number of high-density connected regions, and autocorrelation coefficient of the main diagonal. The probability distribution divergence between the two is calculated based on the phase space density matrix and the byte-weighted phase space density matrix. The density distribution features are extracted from the phase space density matrix and the byte-weighted phase space density matrix, respectively. The density distribution features consist of diagonal concentration, anti-diagonal concentration, upper and lower triangular asymmetry, density information entropy, short-interval region density, and long-interval region density. By combining the phase space structure features, probability distribution divergence, phase space density matrix, and density distribution features corresponding to the byte-weighted phase space density matrix, the flow state features are obtained.
[0009] Preferably, the method for extracting the phase space structure features includes: The weighted mean of row and column indices is calculated using each element of the phase space density matrix as probability weights to obtain the density centroid coordinates; The second-order central moments of the row and column indices are calculated using each element of the phase space density matrix as probability weights to obtain the covariance matrix. The covariance matrix is then decomposed into eigenvalues to extract the direction angles of the principal eigenvectors, which gives the direction angle of the principal axis of the density distribution. The proportion of the larger eigenvalue in the sum of the two eigenvalues is then calculated to obtain the proportion of anisotropy. The number of high-density connected regions is counted after binarizing the phase space density matrix according to a preset ratio threshold. The first-order autocorrelation coefficients of the main diagonal elements of the phase space density matrix are extracted to obtain the main diagonal autocorrelation coefficients.
[0010] Preferably, the method for extracting the density distribution features includes: The grid is selected and the density is accumulated based on the relationship between the absolute value of the row and column index difference and a preset threshold to obtain the diagonal concentration. The concentration of anti-diagonal lines is obtained by filtering cells and accumulating their density based on the relationship between the sum of row and column indices and the matrix size. The density of the regions where the row index is greater than the column index and the regions where the row index is less than the column index are accumulated separately, and the degree of asymmetry of the upper and lower triangles is calculated based on the two. Based on each element of the density matrix, the density information entropy is calculated; the density of short-interval regions is obtained by accumulating the density of cells where both row and column indices are in low-value regions; and the density of long-interval regions is obtained by accumulating the density of cells where both row and column indices are in high-value regions.
[0011] Preferably, the construction steps of the weight allocation model include: For each training data stream in history, the data stream is transmitted through each candidate link, and the experience quality on each link is collected according to the traffic type. The link with the best experience quality is determined as the optimal experience link. Based on the link quality index measurement values of each candidate link and the link with the best experience, the label weight vector is calculated in reverse. The comprehensive traffic characteristics of each training data stream are paired with the corresponding label weight vector to form a training dataset. The weight allocation model is trained by taking comprehensive traffic characteristics as input and labeled weight vector as output target.
[0012] Preferably, the inverse calculation of the label weight vector includes: The weight vector is constrained by the fact that each dimension of the weight vector is not less than zero and the sum of each dimension is one. It is also constrained by the fact that the weight values of each dimension do not exceed a preset upper limit. Furthermore, it is constrained by the fact that the path quality score of the optimal link is not lower than the path quality scores of all other candidate links. The intersection of these three types of constraints is determined as the feasible region of the weight vector. Find the center point of the constraint range of each dimension within the feasible region of the weight vector, and use the weight vector corresponding to the center point as the labeled weight vector.
[0013] Preferably, the step of finding the center point of the constraint range of each dimension within the feasible region of the weight vector includes: For each dimension in the feasible region of the weight vector, under the condition of satisfying the constraints of the other dimensions, the maximum feasible value and the minimum feasible value of that dimension are respectively obtained, and the mean of the maximum feasible value and the minimum feasible value is taken as the center point of that dimension. The values of the center points of each dimension are combined and normalized so that the sum of each dimension satisfies the basic constraints, thus obtaining the labeled weight vector.
[0014] This invention also provides a real-time traffic analysis system for edge network routing, used to implement a real-time traffic analysis method for edge network routing, including: The traffic acquisition module is used at edge network nodes to collect the packet interval sequence and byte-weighted packet interval sequence of the incoming data stream; The phase space embedding module is used to perform phase space embedding processing on packet interval sequences and byte-weighted packet interval sequences to obtain phase space density matrices and byte-weighted phase space density matrices. The feature extraction module is used to extract flow state features from the phase space density matrix and the byte-weighted phase space density matrix, and merge the flow state features with the flow type to obtain the comprehensive flow features. The weight vector generation module is used to input the comprehensive traffic characteristics into a pre-built weight allocation model to obtain a weight vector; The link selection module is used to substitute the weight vector into the path quality scoring function, calculate the path quality score for each candidate link, and perform link selection for the data flow.
[0015] This invention provides a real-time traffic analysis method and system for edge network routing, which has the following advantages: This invention collects packet interval sequences and byte-weighted packet interval sequences from data streams arriving at edge network nodes. After phase space embedding, a phase space density matrix is constructed. Traffic state features reflecting packet transmission characteristics are extracted, and combined with traffic type input into a weight allocation model, a path quality score weight vector is directly output. The training annotation of the weight allocation model is obtained by collecting end-to-end experience quality data as the data stream actually travels through each candidate link and then calculating the weight vector that maximizes the score of the link with the best experience. The annotation is based directly on actual business experience rather than administrator experience judgment. Compared with existing technologies that match preset static weight templates according to business type, data streams with different transmission characteristics under the same business type label can obtain their respective corresponding weight configurations. This improves the systematic deviation between routing results and actual business experience and reduces link resource mismatch.
[0016] This invention transforms packet interval sequences into a two-dimensional density matrix through phase space embedding processing, extracting multi-dimensional structural features such as density centroid, principal axis direction, anisotropy, number of connected regions, diagonal autocorrelation, and probability distribution divergence. It characterizes the state transition rules between adjacent packet intervals of data streams from different levels such as point cloud distribution location, direction, concentration, and topology, and can capture fine-grained differences in packet sending characteristics of different data streams within the same business type, providing a more discriminative input representation for weight allocation models. Attached Figure Description
[0017] Figure 1 This is a flowchart illustrating a real-time traffic analysis method for edge network routing according to the present invention. Figure 2 This is a schematic diagram of a real-time traffic analysis system for edge network routing according to the present invention. Detailed Implementation
[0018] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0019] Example 1
[0020] Please see Figure 1 In this embodiment, a real-time traffic analysis method for edge network routing includes: S1. At the edge network node, collect the packet interval sequence and byte-weighted packet interval sequence of the incoming data stream; The process of collecting the packet interval sequence and byte-weighted packet interval sequence of the arriving data stream includes: Set up traffic mirroring collection points at edge network nodes to extract the arrival timestamp sequence and byte length sequence of each data packet in the data stream; The difference between adjacent timestamps is calculated from the arrival timestamp sequence to obtain the packet interval sequence of the data stream; Based on the byte length sequence, the packet interval sequence is weighted by the combined value of the byte size of two adjacent packets to obtain the byte-weighted packet interval sequence of the data stream.
[0021] In this embodiment, a traffic mirroring collection point is configured at the network interface of the edge node to mirror the data flow passing through that interface. For the collected arrival timestamp sequence, the difference between adjacent timestamps is calculated sequentially. The difference between the arrival time of the first packet and the arrival time of the second packet is the first packet interval, and so on, until a packet interval sequence with one less than the total number of data packets is obtained, in milliseconds.
[0022] Different sized data packets contribute differently to the actual bandwidth usage of the link, and describing the packet transmission rhythm solely by time intervals ignores this difference. Therefore, a byte-weighted packet interval sequence is constructed: for each interval value in the packet interval sequence, the average length of the two adjacent packets is used as the weight to multiply the interval value, resulting in the byte-weighted packet interval at the corresponding position. The calculation results for all positions constitute the byte-weighted packet interval sequence, which is the same length as the packet interval sequence.
[0023] S2. Perform phase space embedding processing on the packet interval sequence and the byte-weighted packet interval sequence to obtain the phase space density matrix and the byte-weighted phase space density matrix. The phase space embedding process for the packet interval sequence and the byte-weighted packet interval sequence includes: Monotonic compression transformations are applied to the packet interval sequence and the byte-weighted packet interval sequence of the data stream, respectively; Map each adjacent interval value in the compressed packet interval sequence to a point in a two-dimensional phase space with the former as the x-axis and the latter as the y-axis, to obtain a scatter set; map each adjacent interval value in the compressed byte-weighted packet interval sequence to a point in a two-dimensional phase space with the former as the x-axis and the latter as the y-axis, to obtain a byte-weighted scatter set. The two-dimensional phase space is uniformly divided into grids of fixed specifications according to a preset boundary. The number of scattered points falling into each grid cell is counted and normalized to obtain the phase space density matrix. The byte-weighted scattered point set is accumulated and normalized with the combined value of the byte amounts of two adjacent packets as weights to obtain the byte-weighted phase space density matrix.
[0024] In this embodiment, it should be noted that the numerical range of the packet interval sequence is usually very large. Even for data streams of the same service type, the distribution of packet intervals varies significantly between different data streams or at different stages of the same data stream. If phase space coordinates are constructed directly using millisecond values, a few maxima will cause the coordinate axis range to be stretched very wide, with a large number of scattered points squeezed into a corner of the grid, making it difficult to reflect subtle rhythmic differences between data streams in the matrix. Each value in the packet interval sequence can be incremented by 1 and then its natural logarithm taken. After this transformation, the numerical range narrows and the distribution becomes more uniform. The same logarithmic transformation can be applied to the byte-weighted packet interval sequence.
[0025] Each pair of adjacent values in the logarithmically transformed packet interval sequence is mapped to a point on a two-dimensional plane, with the former as the x-coordinate and the latter as the y-coordinate, resulting in a scatter plot. The correlation between adjacent packet intervals is determined by the underlying packet transmission characteristics of the data stream, forming a point cloud structure unique to that stream on the two-dimensional plane. Data streams of the same service type may have different packet transmission characteristics in specific parameters and states, and these differences will be reflected in the shape, distribution, and concentration of the point cloud. A byte-weighted scatter plot is constructed for the byte-weighted packet interval sequence in the same way.
[0026] The coordinate range of the two-dimensional phase space is divided into a uniform grid of fixed specifications according to a preset boundary. The preset boundary is usually determined based on the first and ninety-ninth percentiles of the transformed values of all flows in the training dataset. The grid size can be 16×16. For each scatter point in the scatter point set, its corresponding grid cell is determined. The number of scatter points in each cell is counted and normalized by dividing by the total number of scatter points to obtain the phase space density matrix. The sum of all elements in the matrix is 1. For the byte-weighted scatter point set, the average value of the two adjacent packets corresponding to each scatter point is accumulated to its corresponding grid cell and normalized by dividing by the sum of the average values of all scatter point bytes to obtain the byte-weighted phase space density matrix.
[0027] S3. Extract flow state features from the phase space density matrix and the byte-weighted phase space density matrix, and merge the flow state features with the flow type to obtain the comprehensive flow features. The extraction of flow state features from the phase space density matrix and the byte-weighted phase space density matrix includes: Phase space structure features are extracted from the phase space density matrix. The phase space structure features consist of density centroid coordinates, principal axis orientation angles of density distribution, anisotropy ratio, number of high-density connected regions, and autocorrelation coefficient of the main diagonal. The probability distribution divergence between the two is calculated based on the phase space density matrix and the byte-weighted phase space density matrix. The density distribution features are extracted from the phase space density matrix and the byte-weighted phase space density matrix, respectively. The density distribution features consist of diagonal concentration, anti-diagonal concentration, upper and lower triangular asymmetry, density information entropy, short-interval region density, and long-interval region density. By combining the phase space structure features, probability distribution divergence, phase space density matrix, and density distribution features corresponding to the byte-weighted phase space density matrix, the flow state features are obtained.
[0028] The method for extracting the phase space structure features includes: The weighted mean of row and column indices is calculated using each element of the phase space density matrix as probability weights to obtain the density centroid coordinates; The second-order central moments of the row and column indices are calculated using each element of the phase space density matrix as probability weights to obtain the covariance matrix. The covariance matrix is then decomposed into eigenvalues to extract the direction angles of the principal eigenvectors, which gives the direction angle of the principal axis of the density distribution. The proportion of the larger eigenvalue in the sum of the two eigenvalues is then calculated to obtain the proportion of anisotropy. The number of high-density connected regions is counted after binarizing the phase space density matrix according to a preset ratio threshold. The first-order autocorrelation coefficients of the main diagonal elements of the phase space density matrix are extracted to obtain the main diagonal autocorrelation coefficients.
[0029] The method for extracting the density distribution features includes: The grid is selected and the density is accumulated based on the relationship between the absolute value of the row and column index difference and a preset threshold to obtain the diagonal concentration. The concentration of anti-diagonal lines is obtained by filtering cells and accumulating their density based on the relationship between the sum of row and column indices and the matrix size. The density of the regions where the row index is greater than the column index and the regions where the row index is less than the column index are accumulated separately, and the degree of asymmetry of the upper and lower triangles is calculated based on the two. Based on each element of the density matrix, the density information entropy is calculated; the density of short-interval regions is obtained by accumulating the density of cells where both row and column indices are in low-value regions; and the density of long-interval regions is obtained by accumulating the density of cells where both row and column indices are in high-value regions.
[0030] In this embodiment, the density centroid coordinates are obtained by calculating the weighted average index of the row and column directions using each element of the matrix as probability weights, reflecting the overall level of the spacing between adjacent packets in the flow. The principal axis direction angle and anisotropy ratio of the density distribution are obtained through covariance analysis. The second-order central moments of the row and column indices about the centroid are calculated using each element of the matrix as probability weights, forming a 2×2 covariance matrix. Eigenvalue decomposition is then performed on this matrix. The eigenvector direction corresponding to the larger eigenvalue is the principal axis direction of the density distribution, expressed in radians. The proportion of the larger eigenvalue to the sum of the two eigenvalues is the anisotropy ratio. The centroid position, principal axis direction, and anisotropy ratio together reflect the overall distribution pattern of the point cloud in phase space.
[0031] The number of high-density connected regions can be obtained by binarizing the matrix at 20% of the maximum element value and then counting the number of connected regions formed by high-density lattice cells according to the four-connectivity rule. The main diagonal autocorrelation coefficient is obtained by extracting the 16 elements of the main diagonal of the matrix to form a one-dimensional sequence and calculating the Pearson correlation coefficient between this sequence and its version shifted one position to the right. The number of connected regions and the main diagonal autocorrelation coefficient supplement the description of the point cloud morphology from the perspective of structural compactness. A large number of high-density regions indicates that the packet transmission rhythm of the flow has multiple modes coexisting within the acquisition window. The main diagonal autocorrelation coefficient reflects the smoothness of the change in the magnitude of adjacent intervals along the diagonal direction. Even if the centroid positions and main axis directions of two flows are close, the number of high-density regions and the smoothness of the diagonal energy distribution may be different, corresponding to different link stability requirements.
[0032] Probability distribution divergence is usually calculated using KL divergence. Divergence supplements the description of the transmission characteristics of the stream from the perspective of the difference between the byte dimension and the time dimension. When the two matrix structures are significantly different, it indicates that data packets of different sizes in the stream follow different rules in terms of packet sending timing.
[0033] The density distribution features are illustrated using the phase space density matrix as an example. The corresponding terms in the byte-weighted phase space density matrix are calculated in the same way. Diagonal concentration is obtained by filtering cells whose absolute difference between row and column indices does not exceed a preset threshold (usually 1 to 2) and accumulating their densities. Anti-diagonal concentration is obtained by filtering cells whose absolute difference between the sum of their row and column indices and the maximum index value of the matrix does not exceed a preset threshold and accumulating their densities. For a 16×16 matrix, the maximum index value is 15. The asymmetry of the upper and lower triangles is obtained by accumulating the densities of cells with row indices greater than column indices and those with row indices less than column indices, calculating the difference between the two, and dividing by their sum. The result is between -1 and +1. These three terms quantify the distribution proportions of the point cloud in the diagonal direction, anti-diagonal direction, and upper and lower triangles from different perspectives. They are a refined supplement to the principal axis direction and anisotropy proportions, enabling the differentiation of data streams with similar principal axis directions but different specific distribution proportions.
[0034] Density information entropy is calculated by summing the negative of the product of each non-zero element's value and its natural logarithm. A lower entropy value indicates a more concentrated point cloud and a more regular packet sending rhythm. The density in short-interval regions is the cumulative density of cells with both row and column indices not exceeding 3, while the density in long-interval regions is the cumulative density of cells with both row and column indices not less than 12. Both directly quantify the probabilistic quality of the flow in extremely short and extremely long interval regions, and serve as a supplementary description of the tail characteristics of the distribution beyond the centroid.
[0035] The above features are concatenated into a vector in a fixed order and then normalized to obtain the traffic status features. Traffic type is identified by the existing deep packet inspection module on the edge node, and the output typically includes discrete category labels such as real-time audio / video, interactive, and batch transmission. Traffic type labels are usually represented as one-hot encoded vectors, which are then concatenated with the traffic status features to obtain the comprehensive traffic features.
[0036] S4. Input the comprehensive traffic characteristics into the pre-built weight allocation model to obtain the weight vector; The construction steps of the weight allocation model include: For each training data stream in history, the data stream is transmitted through each candidate link, and the experience quality on each link is collected according to the traffic type. The link with the best experience quality is determined as the optimal experience link. Based on the link quality index measurement values of each candidate link and the link with the best experience, the label weight vector is calculated in reverse. The comprehensive traffic characteristics of each training data stream are paired with the corresponding label weight vector to form a training dataset. The weight allocation model is trained by taking comprehensive traffic characteristics as input and labeled weight vector as output target.
[0037] The inverse-calculated annotation weight vector includes: The weight vector is constrained by the fact that each dimension of the weight vector is not less than zero and the sum of each dimension is one. It is also constrained by the fact that the weight values of each dimension do not exceed a preset upper limit. Furthermore, it is constrained by the fact that the path quality score of the optimal link is not lower than the path quality scores of all other candidate links. The intersection of these three types of constraints is determined as the feasible region of the weight vector. Find the center point of the constraint range of each dimension within the feasible region of the weight vector, and use the weight vector corresponding to the center point as the labeled weight vector.
[0038] The step of finding the center point of the constraint range for each dimension within the feasible region of the weight vector includes: For each dimension in the feasible region of the weight vector, under the condition of satisfying the constraints of the other dimensions, the maximum feasible value and the minimum feasible value of that dimension are respectively obtained, and the mean of the maximum feasible value and the minimum feasible value is taken as the center point of that dimension. The values of the center points of each dimension are combined and normalized so that the sum of each dimension satisfies the basic constraints, thus obtaining the labeled weight vector.
[0039] In this embodiment, the construction of the training dataset requires obtaining real service experience data for each data stream on different candidate links. In a test network environment or on a test node with mirroring capabilities, the same data stream is transmitted simultaneously through various candidate links via a splitting mechanism. Quality of Experience (QoE) data is synchronously collected at the receiving end of each link. QoE data reflects the actual service effect of the service on that link and is a commonly used experience evaluation method in the network field. For different types of services, the QoE value is usually selected from quantities that can be directly observed at the endpoint or service proxy side. Taking real-time video traffic as an example, it is usually measured by the stuttering rate and picture quality score statistically obtained at the receiving end. The stuttering rate is the percentage of time the picture is paused due to data not arriving in time during playback. The picture quality score can be obtained using existing objective video quality evaluation methods such as VMAF (Multi-Method Evaluation Fusion). Both comprehensively reflect the user's actual viewing experience. For interactive services such as web page access, the application layer end-to-end response time or page completion time can be used; the shorter the time, the better the experience. After obtaining experience quality data for each candidate link, the experience quality data of different dimensions are generally normalized in the direction of "the larger the better" or "the smaller the better". Then, a simple summary and comparison are performed to determine the best link as the optimal link for experience.
[0040] After obtaining the optimal link for user experience, based on the measured values of latency, jitter, and packet loss obtained from network probing devices for each candidate link and the path quality scoring function, the latency weight, jitter weight, and packet loss weight that maximize the score of the optimal link are calculated. The latency weight, jitter weight, and packet loss weight must meet three conditions: all three weights are not less than zero and their sum is one; any single weight does not exceed a preset upper limit (usually 0.7) to avoid the scoring function degenerating into considering only a single metric; under this weight configuration, the measured values of latency, jitter, and packet loss for each link are normalized and then weighted and summed, ensuring that the score of the optimal link is not lower than that of all other candidate links. The weight vectors that satisfy these three conditions constitute the feasible region.
[0041] For the three dimensions of latency weight, jitter weight, and packet loss weight, the maximum and minimum feasible values for each dimension are calculated while keeping the other two dimensions fixed. The maximum and minimum feasible values are usually obtained by performing a univariate search or linear programming solution within the candidate range. The mean value is then taken as the center point value for that dimension. After taking values for all three dimensions, the results are normalized so that the sum of the three values is one, resulting in the labeled weight vector.
[0042] The training dataset is constructed by pairing the comprehensive traffic features of each training data stream with their corresponding labeled weight vectors, while recording the mean and standard deviation of each feature dimension. The weight allocation model typically employs a multilayer perceptron, taking the comprehensive traffic features as input and processing them through several fully connected hidden layers. The number of nodes in the output layer is consistent with the number of dimensions of the weight vector. The training objective is usually to minimize the mean squared error between the model output and the labeled weight vector. The model is trained using the Adam optimizer, and convergence is criterion when the validation set loss no longer decreases. The model parameters at which the validation set loss is minimized are saved.
[0043] S5. Substitute the weight vector into the path quality scoring function to calculate the path quality score for each candidate link and perform link selection for the data flow.
[0044] In this embodiment, the edge node continuously detects the real-time latency, jitter, and packet loss metrics of each candidate link, and inputs the weight vector as latency weight, jitter weight, and packet loss weight into the path quality scoring function. The path quality scoring function can adopt the weighted scoring function commonly used in the field of software-defined wide area network (SD-WAN), calculate the path quality score based on the network metrics of each candidate link, and select the path with the highest score to carry the data stream.
[0045] Compared to existing technologies that match preset static weight templates based on service type, this solution dynamically determines the weight vector by the weight allocation model based on the comprehensive traffic characteristics of the data stream itself, and the training annotation is based on real service experience measurement results. The structural differences in the phase space density matrix between real-time transmission streams and recorded upload streams, which belong to the same video category, will cause the model to output different weight vectors, allowing each to select the path with the optimal experience, rather than applying the same set of static weights to all video traffic, thereby improving the quality of link resource allocation.
[0046] Example 2
[0047] Please see Figure 2 This invention provides a real-time traffic analysis system for edge network routing, used to implement a real-time traffic analysis method for edge network routing, including: The traffic acquisition module is used at edge network nodes to collect the packet interval sequence and byte-weighted packet interval sequence of the incoming data stream; The phase space embedding module is used to perform phase space embedding processing on packet interval sequences and byte-weighted packet interval sequences to obtain phase space density matrices and byte-weighted phase space density matrices. The feature extraction module is used to extract flow state features from the phase space density matrix and the byte-weighted phase space density matrix, and merge the flow state features with the flow type to obtain the comprehensive flow features. The weight vector generation module is used to input the comprehensive traffic characteristics into a pre-built weight allocation model to obtain a weight vector; The link selection module is used to substitute the weight vector into the path quality scoring function, calculate the path quality score for each candidate link, and perform link selection for the data flow.
[0048] In the several embodiments provided by this invention, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only one method, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.
[0049] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in the present invention should be included within the scope of protection of the present invention.
[0050] In conclusion, the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A real-time traffic analysis method for edge network routing, characterized in that, include: At edge network nodes, the packet interval sequence and byte-weighted packet interval sequence of the arriving data stream are collected. Phase space embedding is performed on the packet interval sequence and the byte-weighted packet interval sequence to obtain the phase space density matrix and the byte-weighted phase space density matrix; Flow state features are extracted from the phase space density matrix and the byte-weighted phase space density matrix. The flow state features are then combined with the flow type to obtain the comprehensive flow features. The comprehensive traffic characteristics are input into a pre-built weight allocation model to obtain a weight vector; The weight vector is substituted into the path quality scoring function to calculate the path quality score for each candidate link and perform link selection for the data flow.
2. The real-time traffic analysis method for edge network routing according to claim 1, characterized in that, The process of collecting the packet interval sequence and byte-weighted packet interval sequence of the arriving data stream includes: Set up traffic mirroring collection points at edge network nodes to extract the arrival timestamp sequence and byte length sequence of each data packet in the data stream; The difference between adjacent timestamps is calculated from the arrival timestamp sequence to obtain the packet interval sequence of the data stream; Based on the byte length sequence, the packet interval sequence is weighted by the combined value of the byte size of two adjacent packets to obtain the byte-weighted packet interval sequence of the data stream.
3. The real-time traffic analysis method for edge network routing according to claim 1, characterized in that, The phase space embedding process for the packet interval sequence and the byte-weighted packet interval sequence includes: Monotonic compression transformations are applied to the packet interval sequence and the byte-weighted packet interval sequence of the data stream, respectively; Map each adjacent interval value in the compressed packet interval sequence to a point in a two-dimensional phase space with the former as the x-axis and the latter as the y-axis, to obtain a scatter set; map each adjacent interval value in the compressed byte-weighted packet interval sequence to a point in a two-dimensional phase space with the former as the x-axis and the latter as the y-axis, to obtain a byte-weighted scatter set. The two-dimensional phase space is uniformly divided into grids of fixed specifications according to a preset boundary. The number of scattered points falling into each grid cell is counted and normalized to obtain the phase space density matrix. The byte-weighted scattered point set is accumulated and normalized with the combined value of the byte amounts of two adjacent packets as weights to obtain the byte-weighted phase space density matrix.
4. The real-time traffic analysis method for edge network routing according to claim 1, characterized in that, The extraction of flow state features from the phase space density matrix and the byte-weighted phase space density matrix includes: Phase space structure features are extracted from the phase space density matrix. The phase space structure features consist of density centroid coordinates, principal axis orientation angles of density distribution, anisotropy ratio, number of high-density connected regions, and autocorrelation coefficient of the main diagonal. The probability distribution divergence between the two is calculated based on the phase space density matrix and the byte-weighted phase space density matrix. The density distribution features are extracted from the phase space density matrix and the byte-weighted phase space density matrix, respectively. The density distribution features consist of diagonal concentration, anti-diagonal concentration, upper and lower triangular asymmetry, density information entropy, short-interval region density, and long-interval region density. By combining the phase space structure features, probability distribution divergence, phase space density matrix, and density distribution features corresponding to the byte-weighted phase space density matrix, the flow state features are obtained.
5. The real-time traffic analysis method for edge network routing according to claim 4, characterized in that, The method for extracting the phase space structure features includes: The weighted mean of row and column indices is calculated using each element of the phase space density matrix as probability weights to obtain the density centroid coordinates; The second-order central moments of the row and column indices are calculated using each element of the phase space density matrix as probability weights to obtain the covariance matrix. The covariance matrix is then decomposed into eigenvalues to extract the direction angles of the principal eigenvectors, which gives the direction angle of the principal axis of the density distribution. The proportion of the larger eigenvalue in the sum of the two eigenvalues is then calculated to obtain the proportion of anisotropy. The number of high-density connected regions is counted after binarizing the phase space density matrix according to a preset ratio threshold. The first-order autocorrelation coefficients of the main diagonal elements of the phase space density matrix are extracted to obtain the main diagonal autocorrelation coefficients.
6. The real-time traffic analysis method for edge network routing according to claim 4, characterized in that, The method for extracting the density distribution features includes: The grid is selected and the density is accumulated based on the relationship between the absolute value of the row and column index difference and a preset threshold to obtain the diagonal concentration. The concentration of anti-diagonal lines is obtained by filtering cells and accumulating their density based on the relationship between the sum of row and column indices and the matrix size. The density of the regions where the row index is greater than the column index and the regions where the row index is less than the column index are accumulated separately, and the degree of asymmetry of the upper and lower triangles is calculated based on the two. Based on each element of the density matrix, the density information entropy is calculated; the density of short-interval regions is obtained by accumulating the density of cells where both row and column indices are in low-value regions; and the density of long-interval regions is obtained by accumulating the density of cells where both row and column indices are in high-value regions.
7. The real-time traffic analysis method for edge network routing according to claim 1, characterized in that, The construction steps of the weight allocation model include: For each training data stream in history, the data stream is transmitted through each candidate link, and the experience quality on each link is collected according to the traffic type. The link with the best experience quality is determined as the optimal experience link. Based on the link quality index measurement values of each candidate link and the link with the best experience, the label weight vector is calculated in reverse. The comprehensive traffic characteristics of each training data stream are paired with the corresponding label weight vector to form a training dataset. The weight allocation model is trained by taking comprehensive traffic characteristics as input and labeled weight vector as output target.
8. The real-time traffic analysis method for edge network routing according to claim 7, characterized in that, The inverse-calculated annotation weight vector includes: The weight vector is constrained by the fact that each dimension of the weight vector is not less than zero and the sum of each dimension is one. It is also constrained by the fact that the weight values of each dimension do not exceed a preset upper limit. Furthermore, it is constrained by the fact that the path quality score of the optimal link is not lower than the path quality scores of all other candidate links. The intersection of these three types of constraints is determined as the feasible region of the weight vector. Find the center point of the constraint range of each dimension within the feasible region of the weight vector, and use the weight vector corresponding to the center point as the labeled weight vector.
9. The real-time traffic analysis method for edge network routing according to claim 8, characterized in that, The step of finding the center point of the constraint range for each dimension within the feasible region of the weight vector includes: For each dimension in the feasible region of the weight vector, under the condition of satisfying the constraints of the other dimensions, the maximum feasible value and the minimum feasible value of that dimension are respectively obtained, and the mean of the maximum feasible value and the minimum feasible value is taken as the center point of that dimension. The values of the center points of each dimension are combined and normalized so that the sum of each dimension satisfies the basic constraints, thus obtaining the labeled weight vector.
10. A real-time traffic analysis system for edge network routing, used to implement the real-time traffic analysis method for edge network routing as described in any one of claims 1-9, characterized in that, include: The traffic acquisition module is used at edge network nodes to collect the packet interval sequence and byte-weighted packet interval sequence of the incoming data stream; The phase space embedding module is used to perform phase space embedding processing on packet interval sequences and byte-weighted packet interval sequences to obtain phase space density matrices and byte-weighted phase space density matrices. The feature extraction module is used to extract flow state features from the phase space density matrix and the byte-weighted phase space density matrix, and merge the flow state features with the flow type to obtain the comprehensive flow features. The weight vector generation module is used to input the comprehensive traffic characteristics into a pre-built weight allocation model to obtain a weight vector; The link selection module is used to substitute the weight vector into the path quality scoring function, calculate the path quality score for each candidate link, and perform link selection for the data flow.
Citation Information
Patent Citations
Path selection for application based on performance score in software-defined network
CN110945842A
Intelligent routing method and device based on link quality and storage medium
CN119629110A
