Long-time sequence information prediction method based on multi-scale double-source fusion network model
Through a long-term sequence information prediction method based on a multi-scale dual-source fusion network model, the problems of stripping noise, outliers and large memory from complex nonlinear and periodic data in the prior art are solved, efficient and accurate prediction results are achieved, and computational complexity and memory requirements are reduced.
Patent Information
- Application Number
- CN202510174777.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-18
- Publication Date
- 2025-03-21
AI Technical Summary
The prior art requires a long time to accurately strip noise and outliers from complex nonlinear and periodic data, large memory, and is sensitive to noise and outliers, lack of feature utilization, and high computational complexity.
A long-term sequence information prediction method based on a multi-scale dual-source fusion network model is adopted, and the multi-scale feature capture and dynamic recombination, standardization and size projection are used to reduce feature deviation and calculation complexity, and the model's anti-interference ability is enhanced by using the gating mechanism, and the time and frequency domain features are fully explored and utilized.
It effectively improves prediction accuracy, reduces computing complexity and memory requirements, enhances the robustness of noise and outliers, and is suitable for many fields such as energy, transportation, and finance.
Smart Images

Figure CN119670019A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing, and in particular to a long-term series information prediction method based on a multi-scale dual-source fusion network model. Background Art
[0002] Time series prediction is a very important task in data analysis and is widely used in many practical scenarios, such as predicting energy usage, traffic flow, financial market trends, and even weather conditions. However, this kind of data usually contains complex change patterns, such as nonlinear relationships (the association between data is not simply linear) and periodicity (certain patterns will repeat), so it is very difficult to make accurate long-term predictions for this kind of data. With the development of deep learning technology, neural network-based methods have gradually become mainstream, such as recurrent neural networks (RNN), long short-term memory networks (LSTM), and gated recurrent units (GRU). Recently, the Transformer architecture has attracted much attention because it can better handle long-term data and high-dimensional complex data. However, these deep learning methods also have their own problems: high computational complexity, not suitable for some resource-limited environments; sensitive to noise and outliers; insufficient feature utilization, only analyzing the time-varying patterns of data (time domain features), but not considering the periodic patterns or local details (frequency domain features) in the data comprehensively. Therefore, the above solutions require high processing time, memory, and computing resources.
[0003] In addition, the Time Evidence Fusion Network (TEFN) is superior to other methods in terms of efficiency and interpretability, but it has the following limitations: 1. Limited ability to mine nonlinear complex patterns: TEFN's BPA module is more suitable for linear or simple distributions, and may not perform well in the face of high-dimensional nonlinear data. 2. Lack of multi-scale feature modeling: Its architecture lacks a specially designed mechanism to capture information at different time scales, which may lead to the loss of short-term or long-term dependent information. 3. Insufficient modeling of feature relationships: TEFN's information source fusion framework is relatively rough in modeling feature relationships, which may affect prediction accuracy.
[0004] Therefore, how to accurately remove noise and outliers from complex nonlinear and periodic data, analyze data patterns and obtain prediction results under the constraints of time, memory and computing resources is a problem currently existing in existing technologies. Summary of the invention
[0005] In response to the problems of long time and large memory required for accurately stripping noise and outliers from complex nonlinear and periodic data in the prior art, the present invention provides a long time series information prediction method based on a multi-scale dual-source fusion network model, which improves the depth and breadth of data understanding through multi-scale feature capture and dynamic reorganization, reduces feature deviation through standardization and size projection, and enhances the model's anti-interference ability through a gating mechanism. It fully mines and utilizes time domain and frequency domain features, which can effectively improve prediction accuracy, reduce computational complexity, and enhance robustness to noise and outliers. It performs excellently in applications in multiple fields such as energy, transportation, and finance, and provides an efficient and reliable solution for long time series information prediction, thereby overcoming many defects of the prior art.
[0006] The following is the technical solution of the present invention.
[0007] The long-term series information prediction method based on the multi-scale dual-source fusion network model includes the following steps: S1: Input time series information from different channels, extract the corresponding time domain features, and convert the time domain features into frequency domain features; S2: normalize the time domain features and frequency domain features and then perform size projection to obtain the projected time domain features and frequency domain features; S3: Dual-source branch processing: For time domain sources: the time domain features of different channels are captured at multiple scales through an efficient multi-scale attention module, and the attention mechanism is used for cross-channel interaction and fusion to obtain time domain fusion information; For frequency domain sources: the frequency domain features of different channels are captured using an efficient multi-scale attention module, and the attention mechanism is used for cross-channel interaction and fusion to obtain frequency domain fusion information; S4: Use the gating weights to dynamically reorganize the time domain fusion information and the frequency domain fusion information to obtain the fusion features, perform denormalization processing on the fusion features considering the gating weights, restore the feature values to the numerical range of the original data, and output the final results.
[0008] In the present invention: The impact of feature dimension differences on model training is eliminated through standardization, and the computational deviation and memory usage caused by different feature dimensions are reduced. Dimension projection makes different features more compatible in the subsequent fusion and prediction process, and reduces the computational complexity and memory consumption caused by feature size mismatch. By reducing feature deviation and unifying feature size, the model can converge faster during training, thereby reducing the overall computational complexity and memory requirements.
[0009] Through the efficient multi-scale attention module, small-scale convolution kernels are used to capture short-term feature information (such as noise and local outliers), while large-scale convolution kernels are used to capture long-term feature information (such as periodic trends). Through the attention mechanism, cross-channel interaction and fusion are carried out to integrate feature information of different scales and channels, so as to more accurately identify and weaken the impact of noise and outliers. The introduction of the attention mechanism enables the model to adaptively adjust the weights of different feature information, give priority to processing features that have a greater impact on the prediction results (such as periodic trends), thereby relatively ignoring or weakening the impact of noise and outliers. This mechanism not only improves the efficiency of processing noise and outliers, but also reduces the large amount of computing and memory resources that may be required in traditional methods.
[0010] The gating mechanism can dynamically adjust feature weights according to the complexity and noise level of the data, making the model more robust when processing complex nonlinear and periodic data. By dynamically adjusting feature weights, the model can prioritize feature information that has a greater impact on the prediction results, relatively ignore or weaken the impact of noise and outliers, thereby reducing unnecessary calculations and memory consumption. This mechanism not only improves the prediction accuracy and robustness of the model, but also reduces the time and memory resources required to process complex data.
[0011] The present invention effectively solves the problem of long time and large memory usage for accurately removing noise and outliers from complex nonlinear and periodic data through unique technical effects such as efficient multi-scale feature capture and fusion, standardization and size projection, and gating mechanism. These technical effects are interrelated and work together to make the model more efficient and accurate in processing complex time series data.
[0012] Preferably, the S1: inputting time series information from different channels, extracting corresponding time domain features, and converting the time domain features to obtain frequency domain features, comprises: Select different data sources, treat each data source as an independent channel, and obtain the time series information of the channel; Use sliding windows to divide time series information into multiple overlapping or non-overlapping subsequences to extract time domain features; Perform Fourier transform on the extracted time domain features to obtain frequency domain features. The formula is: ; Where x[k] represents the complex value of the kth frequency component in the frequency domain, encapsulating the amplitude and phase information in the frequency domain. Here, x[n] represents the time domain input signal, a sequence of length n, where n ranges from 0 to N-1, and N corresponds to the number of sampling points in the input signal. k represents the frequency component being calculated, ranging from 0 to N-1. The complex exponential function with j as the imaginary unit is used to convert the time domain signal to the frequency domain, revealing the phase and amplitude of different frequency components.
[0013] Preferably, S2: normalize the time domain features and the frequency domain features and then perform size projection to obtain the projected time domain features and the frequency domain features, including: The time domain features and frequency domain features are scaled to a standard normal distribution with a mean of 0 and a standard deviation of 1 by using the standardization formula for each feature. For the standardized time domain features, use the convolution layer to perform size projection, and adjust the convolution kernel size, step size and padding to obtain the desired size; or use maximum pooling or average pooling to perform size projection to obtain the desired size; obtain the projected time domain features; For the standardized frequency domain features, size projection is performed through frequency domain cropping or interpolation to obtain the desired size; or, a frequency domain-specific convolution kernel is used for size projection, and the desired size is obtained by adjusting the convolution kernel size, step size, and padding amount; or, a frequency domain pooling operation is used for size projection, and the frequency domain features are downsampled or integrated to obtain the desired size; the projected frequency domain features are obtained.
[0014] Preferably, the multi-scale feature capture of the time domain features of different channels by using an efficient multi-scale attention module includes: For the normalized and size-projected temporal features, convolution operations are performed using small-scale convolution kernels in the efficient multi-scale attention module to capture short-term feature information. At the same time, the time domain features are convolved through the large-scale convolution kernel in the efficient multi-scale attention module to obtain long-term scale feature information.
[0015] Preferably, the use of the attention mechanism to perform cross-channel interaction and fusion to obtain time-domain fusion information includes: By calculating the similarity or correlation matrix between short-term features and long-term features, attention weights are generated, and then the weights are applied to the weighted combination of features of different scales to achieve cross-scale feature fusion and obtain time domain fusion information, where the local detail information in the short-term features is used to adjust the local focus of long-term features, and the trend information in the long-term features is used to guide the overall trend perception of short-term features.
[0016] Preferably, the method of capturing multi-scale features of frequency domain features of different channels by using an efficient multi-scale attention module comprises: For the frequency domain features that have been standardized and resized, convolution operations are performed through small-scale convolution kernels in the efficient multi-scale attention module to capture short-term scale feature information; At the same time, the frequency domain features are convolved through the large-scale convolution kernel in the efficient multi-scale attention module to obtain long-term scale feature information.
[0017] Preferably, the cross-channel interaction and fusion using the attention mechanism to obtain frequency domain fusion information includes: By calculating the similarity or correlation matrix between short-term features and long-term features, attention weights are generated, and then the weights are applied to the weighted combination of features of different scales to achieve cross-scale feature fusion and obtain frequency domain fusion information, where the local detail information in the short-term features is used to adjust the local focus of long-term features, and the trend information in the long-term features is used to guide the overall trend perception of short-term features.
[0018] Preferably, in S4, the time domain fusion information and the frequency domain fusion information are dynamically reorganized by using the gated weight to obtain the fusion feature, including: The gating mechanism calculates the corresponding gating weights through learnable parameters according to the characteristics of the input time domain fusion information and frequency domain fusion information, and controls the throughput in the time domain and / or frequency domain by dynamically adjusting the weights; Among them, let Ft and Ff be the time domain fusion information and frequency domain fusion information respectively, Wt and Wf are the gating weights for the time domain fusion information and frequency domain fusion information respectively, Ft and Ff are respectively input into one or more fully connected layers to obtain the intermediate representations Ht and Hf of the time domain fusion information and the frequency domain fusion information, and Ht and Hf are obtained through the activation function to obtain the final gating weights as well as ,in represents the Sigmoid function, the values of Wt and Wf range from 0 to 1; The calculated gating weights Wt and Wf are used to dynamically reorganize the time domain fusion information Ft and the frequency domain fusion information Ff to obtain the fusion feature ,in Represents element-wise multiplication.
[0019] Preferably, in S4, the fusion feature is subjected to denormalization processing taking into account the gate weight, the feature value is restored to the numerical range of the original data, and the final result is output, including: According to the normalization formula used in the normalization in step S2, a denormalization formula is obtained; Obtain the mean and standard deviation of the time domain features and the frequency domain features calculated by the normalization process in step S2, and recombine and calculate the mean and standard deviation according to the gating weights of the time domain fusion information and the frequency domain fusion information to obtain the mean and standard deviation of the fusion features; Based on the mean and standard deviation of the fused features, the final result is calculated using the denormalization formula.
[0020] The present invention also provides a long-term series information prediction system based on a multi-scale dual-source fusion network model, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor calls the computer program in the memory, the steps of the long-term series information prediction method based on the multi-scale dual-source fusion network model are implemented.
[0021] The present invention also provides a storage medium, in which computer executable instructions are stored. When the computer executable instructions are loaded and executed by a processor, the steps of the long-term series information prediction method based on the multi-scale dual-source fusion network model are implemented.
[0022] The substantial effects of the present invention include: The application of standardization and size projection technology not only eliminates the difference in feature dimensions and reduces calculation deviation, but also unifies the feature size, reducing the calculation complexity and memory requirements of subsequent fusion and prediction. In particular, the introduction of the gating mechanism enables the model to dynamically adjust the weights of time domain and frequency domain information according to the input features, enhancing the model's adaptability to complex data and significantly improving the accuracy and robustness of the prediction.
[0023] Through the efficient multi-scale attention module, small-scale convolution kernels are used to capture short-term features (such as noise, local outliers), large-scale convolution kernels are used to capture long-term trends (such as periodic laws), and cross-channel interactive fusion is achieved through the attention mechanism, which effectively weakens the impact of noise and outliers, while accelerating feature extraction and processing speed.
[0024] In addition, the model's functions have been further refined and improved by using Fourier transform to extract frequency domain features and calculating gate weights through fully connected layers and activation functions. These technical features work together to improve the model's efficiency and accuracy in processing complex nonlinear and periodic data, effectively solving the problems of long time and large memory required by traditional methods when processing such data. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] Figure 1 is a flow chart of an embodiment of the present invention; Figure 2 It is a data flow diagram of dual-source branch processing in an embodiment of the present invention. DETAILED DESCRIPTION
[0026] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution will be clearly and completely described below in combination with the embodiments. 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 creative work are within the scope of protection of the present invention.
[0027] It should be understood that in various embodiments of the present invention, the size of the sequence number of each process does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0028] It should be understood that in the present invention, "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or apparatus comprising a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to these processes, methods, products or apparatuses.
[0029] It should be understood that in the present invention, "plurality" refers to two or more than two. "And / or" is merely a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "Contains A, B and C", "Contains A, B, C" means that A, B, and C are all included, "Contains A, B or C" means that one of A, B, and C is included, and "Contains A, B and / or C" means that any one, any two, or any three of A, B, and C are included.
[0030] The technical solution of the present invention is described in detail with specific embodiments below. The embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments.
[0031] Example:
[0032] Long-term time series information prediction method based on multi-scale dual-source fusion network model, such as Figure 1 As shown, the following steps are included: S1: Input time series information from different channels, extract the corresponding time domain features, and convert the time domain features into frequency domain features; S2: normalize the time domain features and frequency domain features and then perform size projection to obtain the projected time domain features and frequency domain features; S3: Dual-source branch processing: For time domain sources: the time domain features of different channels are captured at multiple scales through an efficient multi-scale attention module, and the attention mechanism is used for cross-channel interaction and fusion to obtain time domain fusion information; For frequency domain sources: the frequency domain features of different channels are captured using an efficient multi-scale attention module, and the attention mechanism is used for cross-channel interaction and fusion to obtain frequency domain fusion information; S4: Use the gating weights to dynamically reorganize the time domain fusion information and the frequency domain fusion information to obtain fusion features, perform denormalization on the fusion features considering the gating weights, restore the feature values to the numerical range of the original data, and output the final result.
[0033] This embodiment relates to the technical field of long-term series information prediction, and aims to solve the problem of how to accurately remove noise and outliers from complex nonlinear and periodic data, analyze data patterns and obtain prediction results when time, memory and computing resources are limited. In the prior art, time series prediction is widely used in energy usage, traffic flow, financial market trends, etc., but due to the complexity of the data, the existing methods have limitations in terms of computational complexity, sensitivity to noise and outliers, and insufficient feature utilization.
[0034] The reasons why existing technologies require large memory are: 1. Data volume: Time series data is usually organized by time step (t) and number of features (c). Especially in the prediction of long time series, the amount of data will be very large. A large number of time steps and features will require a large amount of memory for data storage and processing.
[0035] 2. Feature Engineering: Preprocessing and feature engineering of data will increase the dimensionality of the data, thus taking up more memory.
[0036] 3. Model parameter count: Many advanced time series forecasting models have a large number of parameters. As the complexity of the model increases, the memory required by the model will also increase significantly.
[0037] 4. Gradient storage: During the training process of deep learning models, the gradient information of each layer of the network needs to be stored in order to perform back-propagation to update parameters. For larger models and long time series, the storage of these gradient data will consume a lot of memory.
[0038] 5. Modeling long-term and short-term dependencies of sequences: Many advanced time series prediction models need to handle dependencies with long time steps, which usually requires passing and storing long historical information in internal states. Dependencies of long sequences make calculations and storage more complex and expensive.
[0039] This embodiment avoids the above problems through multiple technical optimizations. Standardization and size projection reduce feature deviation and memory usage, accelerate model convergence, and reduce overall memory requirements. The efficient multi-scale attention module accurately captures features, weakens the impact of noise and outliers, and reduces unnecessary calculations and memory consumption. The gating mechanism dynamically adjusts feature weights, prioritizes key information, and reduces memory requirements. These technologies work together to allow the model to process complex data without the need for a large amount of memory to store data, intermediate calculation results, and model parameters, effectively overcoming the memory problems of the prior art.
[0040] For example, in the application of energy usage prediction, the method of this embodiment can extract multi-scale features from time series data from different sources, and obtain high-precision prediction results through dynamic reorganization and denormalization. Compared with traditional methods, the method of this application shows higher accuracy and efficiency when processing complex nonlinear and periodic data. It is suitable for a variety of practical application scenarios such as energy usage, traffic flow, and financial market trends.
[0041] In this embodiment, the S1: inputting time series information from different channels, extracting corresponding time domain features, and converting the time domain features to obtain frequency domain features, includes: Select different data sources, treat each data source as an independent channel, and obtain the time series information of the channel; Use sliding windows to divide time series information into multiple overlapping or non-overlapping subsequences to extract time domain features; Perform Fourier transform on the extracted time domain features to obtain frequency domain features. The formula is: ; Where x[k] represents the complex value of the kth frequency component in the frequency domain, encapsulating the amplitude and phase information in the frequency domain. Here, x[n] represents the time domain input signal, a sequence of length n, where n ranges from 0 to N-1, and N corresponds to the number of sampling points in the input signal. k represents the frequency component being calculated, ranging from 0 to N-1. The complex exponential function with j as the imaginary unit is used to convert the time domain signal to the frequency domain, revealing the phase and amplitude of different frequency components.
[0042] By selecting different data sources, each data source is used as an independent channel to obtain the time series information of the channel, and the time series information is divided into multiple overlapping or non-overlapping subsequences using a sliding window to extract time domain features. The extracted time domain features are Fourier transformed to obtain frequency domain features. In this way, time domain features and frequency domain features can be effectively extracted from the time series information of different data sources, and the time domain features can be converted into frequency domain features, providing a basis for subsequent feature fusion and information prediction.
[0043] Specifically, when selecting different data sources, you can select multiple data sources according to the characteristics and requirements of the data sources, such as sensor data, market data, etc. When obtaining time series information, you can use conventional data collection methods, such as collecting environmental data through sensors. When using sliding windows to divide subsequences, you can select the window size and step size as needed to ensure that the subsequences can cover enough information. When extracting time domain features, you can use common time domain feature extraction methods, such as mean, variance, peak, etc. When performing Fourier transform on time domain features, you can use the fast Fourier transform (FFT) algorithm to improve computational efficiency.
[0044] Therefore, this embodiment processes the information of different data sources as independent channels and utilizes the sliding window and Fourier transform methods to effectively extract and convert time domain features and frequency domain features. Compared with the prior art, the method of the present application can more comprehensively analyze the time variation and periodicity of the data, thereby improving the accuracy and reliability of the prediction.
[0045] In this embodiment, the step S2: normalizing the time domain features and the frequency domain features and performing size projection to obtain the projected time domain features and frequency domain features includes: The time domain features and frequency domain features are scaled to a standard normal distribution with a mean of 0 and a standard deviation of 1 by using the standardization formula for each feature. For the standardized time domain features, use the convolution layer to perform size projection, and adjust the convolution kernel size, step size and padding to obtain the desired size; or use maximum pooling or average pooling to perform size projection to obtain the desired size; obtain the projected time domain features; For the standardized frequency domain features, size projection is performed through frequency domain cropping or interpolation to obtain the desired size; or, a frequency domain-specific convolution kernel is used for size projection, and the desired size is obtained by adjusting the convolution kernel size, step size, and padding amount; or, a frequency domain pooling operation is used for size projection, and the frequency domain features are downsampled or integrated to obtain the desired size; the projected frequency domain features are obtained.
[0046] The dual-source branch processing of this embodiment is as follows Figure 2 shown.
[0047] In this embodiment, the multi-scale feature capture of the time domain features of different channels by the efficient multi-scale attention module includes: For the normalized and size-projected temporal features, convolution operations are performed using small-scale convolution kernels in the efficient multi-scale attention module to capture short-term feature information. At the same time, the time domain features are convolved through the large-scale convolution kernel in the efficient multi-scale attention module to obtain long-term scale feature information.
[0048] This embodiment can capture time domain features at different scales, and solves the problem of how to perform multi-scale feature capture of time domain features of different channels through an efficient multi-scale attention module.
[0049] New technical features for multi-scale feature capture of time domain features of different channels through efficient multi-scale attention modules include using small-scale convolution kernels and large-scale convolution kernels to perform convolution operations respectively to capture feature information of short-term and long-term scales. Specifically, small-scale convolution kernels are suitable for capturing detail changes in the short term, while large-scale convolution kernels are used to capture long-term trend information. As a preferred implementation, the small-scale convolution kernel can select a convolution kernel size of 1x1, while the large-scale convolution kernel can select a convolution kernel size of 3x3 or larger. In addition, the step size and padding of the convolution kernel can be adjusted according to the specific application scenario to optimize the feature capture effect.
[0050] The formula for global average pooling is: ; In the formula, is the output feature of feature group c, is the input feature value at position (i, j) in channel c, and H and W are the height and width of the input feature map, respectively. The formula calculates the average value of all pixels in the feature map. Here, the global average of the channel is determined by adding the pixel values at position (i, j) and dividing by the total number of pixels. This pooling operation aggregates pixel values, allowing the module to capture the correlation between channel and spatial features through cross-dimensional interactions, while maintaining the integrity and accuracy of the features through parallel multi-scale feature processing.
[0051] This embodiment captures time domain features at different scales through an efficient multi-scale attention module, and can simultaneously obtain short-term and long-term feature information. Compared with the prior art, the combination of multi-scale convolution kernels can more comprehensively capture the details and trend information of time domain features; the attention mechanism is used for cross-channel interaction and fusion to improve the accuracy and efficiency of feature capture; compared with the single-scale feature capture method, this embodiment shows better robustness and adaptability when processing complex time domain data.
[0052] In this embodiment, the attention mechanism is used to perform cross-channel interaction and fusion to obtain time domain fusion information, including: By calculating the similarity or correlation matrix between short-term features and long-term features, attention weights are generated, and then the weights are applied to the weighted combination of features of different scales to achieve cross-scale feature fusion and obtain time domain fusion information, where the local detail information in the short-term features is used to adjust the local focus of long-term features, and the trend information in the long-term features is used to guide the overall trend perception of short-term features.
[0053] The local detail information in the short-term features is used to adjust the local focus of the long-term features, and the trend information in the long-term features is used to guide the overall trend perception of the short-term features. In this way, the time domain features of different channels are interacted and fused using the attention mechanism, which can integrate the information of different channels, so that the model can learn the relationship between data from different sources and enhance the understanding of the data. For example, in a multi-sensor monitoring system, the time series information of sensors at different locations is fused to better perceive the overall system status. It helps to discover the hidden connections between different time domain channels, improve the understanding of the overall structure of the data, and reduce the impact of noise and uncertainty in the data.
[0054] Among them, the implementation method of the attention mechanism: the similarity or correlation matrix between short-term features and long-term features can be calculated through self-attention or multi-head attention. Specifically, the self-attention mechanism calculates the similarity between features through dot products, while the multi-head attention mechanism captures different attention patterns through multiple attention heads to generate richer attention weights. The implementation method of weighted combination: after generating the attention weights, the features of different scales can be combined by weighted summation. Specifically, the attention weights can be element-wise multiplied with the corresponding features, and then the products can be summed to obtain the final fused features. The implementation method of feature adjustment: the local detail information in the short-term features can be captured by convolution operations, and the local focus of the long-term features can be adjusted by the attention mechanism. The trend information in the long-term features can be captured by long-span convolutions or recurrent neural networks (such as LSTM), and the overall trend perception of the short-term features can be guided by the attention mechanism.
[0055] This embodiment uses the attention mechanism for cross-channel interaction and fusion, effectively solving the problem of how to generate attention weights by calculating the similarity or correlation matrix between short-term features and long-term features, and then applying the weights to the weighted combination of features of different scales to achieve cross-scale feature fusion and obtain time domain fusion information. Compared with the prior art, the method of the present application can better integrate information from different channels, enhance the understanding of data, discover hidden connections between different time domain channels, improve the understanding of the overall structure of data, and reduce the impact of noise and uncertainty in the data.
[0056] In this embodiment, the multi-scale feature capture of frequency domain features of different channels by using an efficient multi-scale attention module includes: For the frequency domain features that have been standardized and resized, convolution operations are performed through small-scale convolution kernels in the efficient multi-scale attention module to capture short-term scale feature information; At the same time, the frequency domain features are convolved through the large-scale convolution kernel in the efficient multi-scale attention module to obtain long-term scale feature information.
[0057] In this embodiment, the use of the attention mechanism to perform cross-channel interaction and fusion to obtain frequency domain fusion information includes: By calculating the similarity or correlation matrix between short-term features and long-term features, attention weights are generated, and then the weights are applied to the weighted combination of features of different scales to achieve cross-scale feature fusion and obtain frequency domain fusion information, where the local detail information in the short-term features is used to adjust the local focus of long-term features, and the trend information in the long-term features is used to guide the overall trend perception of short-term features.
[0058] The processing here is similar to that of time domain information, so no further explanation is given.
[0059] In this embodiment, in S4, the time domain fusion information and the frequency domain fusion information are dynamically reorganized using the gated weight to obtain fusion features, including: The gating mechanism calculates the corresponding gating weights through learnable parameters according to the characteristics of the input time domain fusion information and frequency domain fusion information, and controls the throughput in the time domain and / or frequency domain by dynamically adjusting the weights; Among them, let Ft and Ff be the time domain fusion information and frequency domain fusion information respectively, Wt and Wf are the gating weights for the time domain fusion information and frequency domain fusion information respectively, Ft and Ff are respectively input into one or more fully connected layers to obtain the intermediate representations Ht and Hf of the time domain fusion information and the frequency domain fusion information, and Ht and Hf are obtained through the activation function to obtain the final gating weights as well as ,in Represents the Sigmoid function, the values of Wt and Wf range from 0 to 1; The calculated gating weights Wt and Wf are used to dynamically reorganize the time domain fusion information Ft and the frequency domain fusion information Ff to obtain the fusion feature ,in Represents element-wise multiplication.
[0060] The gating mechanism calculates the gating weights through learnable parameters to control the amount of time and frequency domain information passing through. Fully connected layers and activation functions are used to calculate and adjust the gating weights. Element-wise multiplication is used to combine different information sources to ultimately obtain fused features. Through the above scheme, the time domain fusion information and the frequency domain fusion information are dynamically reorganized using gating weights, which can effectively integrate the two types of feature information and ensure that the weights of the two types of information can be flexibly adjusted in different situations, thereby obtaining more accurate and comprehensive fusion features. For example, when the periodicity in the data is more important, it will make the frequency domain features more effective; when the time change is more important, it will give priority to the time domain features. In this way, the model can better adapt to the noise or outliers in the data, making the prediction results more stable and reliable.
[0061] The gating mechanism calculates the corresponding gating weights through learnable parameters according to the characteristics of the input time domain fusion information and frequency domain fusion information, and controls the throughput in the time domain and / or frequency domain by dynamically adjusting the weights.
[0062] Furthermore, the gating mechanism can be optimized through different learning strategies, such as updating parameters through gradient descent method, to ensure that the calculation of gating weights is more accurate. In addition, the calculation of gating weights can be combined with attention mechanism to further improve the selectivity of time domain and frequency domain information. As a preferred embodiment, multiple layers of fully connected layers and different types of activation functions can be used to enhance the expressiveness of the model and the ability to capture nonlinear features.
[0063] This embodiment introduces a gating mechanism to dynamically adjust the weights of time domain fusion information and frequency domain fusion information, thereby flexibly adjusting the contribution of the two types of information in different situations to ensure the accuracy and comprehensiveness of the fusion features. Compared with the prior art, this embodiment shows higher robustness and adaptability when processing complex nonlinear and periodic data, can effectively reduce the impact of noise and outliers, and improve the stability and reliability of the prediction results. Therefore, this application has significant technical advantages in the field of long-term series information prediction.
[0064] Preferably, in S4, the fusion feature is subjected to denormalization processing taking into account the gate weight, the feature value is restored to the numerical range of the original data, and the final result is output, including: According to the normalization formula used in the normalization in step S2, a denormalization formula is obtained; Obtain the mean and standard deviation of the time domain features and the frequency domain features calculated by the normalization process in step S2, and recombine and calculate the mean and standard deviation according to the gating weights of the time domain fusion information and the frequency domain fusion information to obtain the mean and standard deviation of the fusion features; Based on the mean and standard deviation of the fused features, the final result is calculated using the denormalization formula.
[0065] This step can ensure data accuracy and consistency. Standardization is to facilitate model training, and this de-standardization can restore the data to the original range, making the prediction results explainable and usable in actual scenarios. For example, the energy usage prediction can intuitively present the scale; with the help of gating weight optimization results, the gating weight reflects the importance of time domain and frequency domain information. Considering it when calculating the mean and standard deviation can make de-standardization more accurate and improve prediction accuracy; enhance model adaptability and robustness. In the face of complex data and noise, the gating mechanism reduces the impact of abnormalities. Combined with the de-standardization of the gating weight, when restoring the data range, the model's anti-interference ability is maintained to ensure stable and reliable prediction results.
[0066] This embodiment also provides a long time series information prediction system based on a multi-scale dual-source fusion network model, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor calls the computer program in the memory, the steps of the long time series information prediction method based on the multi-scale dual-source fusion network model are implemented.
[0067] By combining the features of the time domain and frequency domain, and utilizing the multi-scale attention mechanism and gating mechanism, it is possible to accurately remove noise and outliers from complex nonlinear and periodic data, analyze data patterns, and obtain prediction results when time, memory, and computing resources are limited. This embodiment can accurately remove noise and outliers from complex nonlinear and periodic data, analyze data patterns, and obtain prediction results when time, memory, and computing resources are limited. Compared with the prior art, this embodiment has significant advantages in processing complex data and improving prediction accuracy.
[0068] Through the description of the above implementation methods, technical personnel in the relevant field can understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the specific device can be divided into different functional modules to complete all or part of the functions described above.
[0069] In the embodiments provided in the present application, it should be understood that the disclosed structures and methods can be implemented in other ways. For example, the embodiments of the structure described above are only schematic. For example, the division of modules or units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another structure, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, structures or units, which can be electrical, mechanical or other forms.
[0070] The units described as separate components may or may not be physically separated, and the components shown as units may be one physical unit or multiple physical units, that is, they may be located in one place or distributed in multiple different places. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0071] In addition, each functional unit in the embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0072] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium, including several instructions to enable a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to perform all or part of the steps of the various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program code.
[0073] The above contents are only specific implementation methods of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A long-term series information prediction method based on a multi-scale dual-source fusion network model, characterized in that: The following steps are involved: S1: Input time series information from different channels, extract the corresponding time domain features, and convert the time domain features into frequency domain features; S2: normalize the time domain features and frequency domain features and then perform size projection to obtain the projected time domain features and frequency domain features; S3: Dual-source branch processing: For time domain sources: the time domain features of different channels are captured at multiple scales through an efficient multi-scale attention module, and the attention mechanism is used for cross-channel interaction and fusion to obtain time domain fusion information; For frequency domain sources: the frequency domain features of different channels are captured using an efficient multi-scale attention module, and the attention mechanism is used for cross-channel interaction and fusion to obtain frequency domain fusion information; S4: Use the gating weights to dynamically reorganize the time domain fusion information and the frequency domain fusion information to obtain fusion features, perform denormalization on the fusion features considering the gating weights, restore the feature values to the numerical range of the original data, and output the final result.
2. The long-term series information prediction method based on the multi-scale dual-source fusion network model according to claim 1 is characterized in that: S1: inputting time series information from different channels, extracting corresponding time domain features, and converting the time domain features to obtain frequency domain features, including: Select different data sources, treat each data source as an independent channel, and obtain the time series information of the channel; Use sliding windows to divide time series information into multiple overlapping or non-overlapping subsequences to extract time domain features; Perform Fourier transform on the extracted time domain features to obtain frequency domain features. The formula is: ; Where x[k] represents the complex value of the kth frequency component in the frequency domain, encapsulating the amplitude and phase information in the frequency domain. Here, x[n] represents the time domain input signal, a sequence of length n, where n ranges from 0 to N-1, and N corresponds to the number of sampling points in the input signal. k represents the frequency component being calculated, ranging from 0 to N-1. The complex exponential function with j as the imaginary unit is used to convert the time domain signal to the frequency domain, revealing the phase and amplitude of different frequency components.
3. The long-term series information prediction method based on the multi-scale dual-source fusion network model according to claim 1 is characterized in that: S2: Standardize the time domain features and frequency domain features and then perform size projection to obtain the projected time domain features and frequency domain features, including: The time domain features and frequency domain features are scaled to a standard normal distribution with a mean of 0 and a standard deviation of 1 by using the standardization formula for each feature. For the standardized time domain features, use the convolution layer to perform size projection, and adjust the convolution kernel size, step size and padding to obtain the desired size; or use maximum pooling or average pooling to perform size projection to obtain the desired size; obtain the projected time domain features; For the standardized frequency domain features, size projection is performed through frequency domain cropping or interpolation to obtain the desired size; or, a frequency domain-specific convolution kernel is used for size projection, and the desired size is obtained by adjusting the convolution kernel size, step size, and padding amount; or, a frequency domain pooling operation is used for size projection, and the frequency domain features are downsampled or integrated to obtain the desired size; the projected frequency domain features are obtained.
4. The long-term series information prediction method based on the multi-scale dual-source fusion network model according to claim 1 is characterized in that: The multi-scale feature capture of the time domain features of different channels by using an efficient multi-scale attention module includes: For the normalized and size-projected temporal features, convolution operations are performed using small-scale convolution kernels in the efficient multi-scale attention module to capture short-term feature information. At the same time, the time domain features are convolved through the large-scale convolution kernel in the efficient multi-scale attention module to obtain long-term scale feature information.
5. The long-term series information prediction method based on the multi-scale dual-source fusion network model according to claim 1 is characterized in that: The attention mechanism is used to perform cross-channel interaction and fusion to obtain time domain fusion information, including: By calculating the similarity or correlation matrix between short-term features and long-term features, attention weights are generated, and then the weights are applied to the weighted combination of features of different scales to achieve cross-scale feature fusion and obtain time domain fusion information, where the local detail information in the short-term features is used to adjust the local focus of long-term features, and the trend information in the long-term features is used to guide the overall trend perception of short-term features.
6. The long-term series information prediction method based on the multi-scale dual-source fusion network model according to claim 1 is characterized in that: The multi-scale feature capture of frequency domain features of different channels by using an efficient multi-scale attention module includes: For the frequency domain features that have been standardized and resized, convolution operations are performed through small-scale convolution kernels in the efficient multi-scale attention module to capture short-term scale feature information; At the same time, the frequency domain features are convolved through the large-scale convolution kernel in the efficient multi-scale attention module to obtain long-term scale feature information.
7. The long-term series information prediction method based on the multi-scale dual-source fusion network model according to claim 1 is characterized in that: The attention mechanism is used to perform cross-channel interaction and fusion to obtain frequency domain fusion information, including: By calculating the similarity or correlation matrix between short-term features and long-term features, attention weights are generated, and then the weights are applied to the weighted combination of features of different scales to achieve cross-scale feature fusion and obtain frequency domain fusion information, where the local detail information in the short-term features is used to adjust the local focus of long-term features, and the trend information in the long-term features is used to guide the overall trend perception of short-term features.
8. The long-term series information prediction method based on the multi-scale dual-source fusion network model according to claim 1 is characterized in that: In S4, the time domain fusion information and the frequency domain fusion information are dynamically reorganized using the gated weights to obtain fusion features, including: The gating mechanism calculates the corresponding gating weights through learnable parameters according to the characteristics of the input time domain fusion information and frequency domain fusion information, and controls the throughput in the time domain and / or frequency domain by dynamically adjusting the weights; Among them, let Ft and Ff be the time domain fusion information and frequency domain fusion information respectively, Wt and Wf are the gating weights for the time domain fusion information and frequency domain fusion information respectively, Ft and Ff are respectively input into one or more fully connected layers to obtain the intermediate representations Ht and Hf of the time domain fusion information and the frequency domain fusion information, and Ht and Hf are obtained through the activation function to obtain the final gating weights as well as ,in represents the Sigmoid function, the values of Wt and Wf range from 0 to 1; The calculated gating weights Wt and Wf are used to dynamically reorganize the time domain fusion information Ft and the frequency domain fusion information Ff to obtain the fusion feature ,in Represents element-wise multiplication.
9. The long-term series information prediction method based on the multi-scale dual-source fusion network model according to claim 1 is characterized in that: In S4, the fusion feature is denormalized by taking the gating weight into consideration, the feature value is restored to the numerical range of the original data, and the final result is output, including: According to the normalization formula used in the normalization in step S2, a denormalization formula is obtained; Obtain the mean and standard deviation of the time domain features and the frequency domain features calculated by the normalization process in step S2, and recombine and calculate the mean and standard deviation according to the gating weights of the time domain fusion information and the frequency domain fusion information to obtain the mean and standard deviation of the fusion features; Based on the mean and standard deviation of the fused features, the final result is calculated using the denormalization formula.
10. A long-term series information prediction system based on a multi-scale dual-source fusion network model, comprising a memory and a processor, wherein a computer program is stored in the memory, and when the processor calls the computer program in the memory, the steps of the long-term series information prediction method based on the multi-scale dual-source fusion network model as described in any one of claims 1 to 9 are implemented.
Citation Information
Cited By
Current transformer error state evaluation method and system based on multi-stage CNN cascade
CN119939358A
Time sequence prediction method based on FFT and interactive depth separable convolution
CN120030284A
Multi-modal space-time sequence prediction method and device for multi-scale time sequence data imaging
CN120105347A
Fault diagnosis method for multi-sensor time-frequency fusion equipment under quasi-unbalance condition
CN120145127A
Foamed aluminum material strength prediction method based on multi-source data
CN120452640A