An industrial time series prediction method fusing local trend features
By integrating trend and numerical features through adaptive local linear fitting and attention mechanisms, the problem of neglecting local trend state information in deep learning prediction methods is solved, thereby improving the accuracy and robustness of industrial time series prediction.
Patent Information
- Application Number
- CN202611438310.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-16
- Publication Date
- 2026-11-20
AI Technical Summary
Existing deep learning-based industrial time series forecasting methods neglect local trend information within the time series, making it difficult to distinguish the evolution direction and persistent effects of industrial processes, thus limiting forecast accuracy and robustness.
Local trend information is extracted by an error-constrained adaptive local linear fitting method, and the trend and numerical features are fused using an attention mechanism to construct local trend features with adaptive span segmentation, which are then input into a deep learning prediction model for prediction.
It improves the ability of the prediction model to identify and respond to non-stationary fluctuations, trend reversals and local mutations, enhances prediction accuracy and adaptability, and is applicable to a variety of deep learning frameworks.
Smart Images

Figure CN123138673A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of industrial time series forecasting, and particularly relates to an industrial time series forecasting method that integrates local trend features. Background Technology
[0002] Industrial time series forecasting is a crucial foundational technology for industrial intelligence, predictive maintenance, production scheduling optimization, and process safety control. In typical industrial scenarios such as thermal power units, chemical processes, energy systems, and equipment operation monitoring, key operating variables such as load, temperature, pressure, and flow rate typically exhibit significant dynamic time-varying characteristics. Accurately predicting the future trends of these variables is of significant engineering value for understanding production status in advance, optimizing control strategies, reducing operational risks, and improving overall system efficiency. With the rapid development of the Industrial Internet and sensing and control technologies, industrial sites can continuously collect and store large amounts of high-dimensional time series data. Deep learning-based forecasting methods, due to their powerful nonlinear feature extraction capabilities, have been widely applied to industrial time series forecasting tasks. For example, forecasting models based on recurrent neural networks, convolutional neural networks, and transformer structures and their improved forms can learn time dependencies from historical observation data and output prediction results for one or more future time steps.
[0003] However, existing deep learning-based industrial time series forecasting methods primarily rely on numerical features for modeling. Their core flaw lies in neglecting the local trend information inherent within the time series, thus weakening the capture of industrial process evolution patterns. Specifically, in actual industrial processes, the same numerical value may correspond to drastically different local states of change, such as a continuously rising phase, a continuously falling phase, or a relatively stable phase. If the forecasting model maps identical sampling points equally, it becomes difficult to distinguish the underlying evolutionary direction and persistence effects. This results in insufficient model perception of dynamic features such as non-stationary fluctuations, trend reversals, and local mutations, thereby limiting further improvements in forecast accuracy and robustness. Although some existing technologies attempt to introduce trend decomposition or difference transformation to assist forecasting, these methods often treat trends as an independent preprocessing step, failing to deeply integrate trend information with numerical features at the model's underlying level. Furthermore, their trend extraction methods often rely on global or fixed window parameters, making it difficult to adapt to the differentiated fluctuation characteristics exhibited by industrial data at different operational stages. Therefore, how to provide a time series prediction method that can organically integrate local trend states into numerical features, achieve collaborative perception of trends and numerical values, and possess good versatility and adaptability, while adapting to mainstream deep learning prediction architectures, remains a technical problem that urgently needs to be solved in this field. Summary of the Invention
[0004] To address the aforementioned technical problems, this invention provides an industrial time series forecasting method that integrates local trend features, comprising: Time series observation data of industrial processes are acquired, and after preprocessing, the original input sequence is constructed. Based on the original input sequence, an initial neighborhood window is constructed with each observation point as the center. Under error constraints, the initial neighborhood window is expanded bidirectionally and linearly fitted to obtain local trend information of adaptive span segmentation. Based on the local trend information of the adaptive span segmentation, the trend direction feature and trend duration feature corresponding to each observation point are determined, and a point-by-point sliding window strategy is used to traverse all time points to obtain the trend sequence corresponding to the original input sequence. The numerical features of the original input sequence are used as query terms, and the features of the trend sequence are used as key and value terms. Feature fusion is performed through an attention mechanism, and the feature is then processed by residual connection and layer normalization to obtain the bottom-level enhanced features. The underlying enhanced features are input into a deep learning prediction model to obtain prediction results for multiple future steps.
[0005] Preferably, the process of obtaining local trend information for adaptive span segmentation includes: With any observation point in the original input sequence as the center, construct an initial neighborhood window containing the observation point and one adjacent point before and after it; During each expansion, the least squares method is used to perform linear fitting on all observation points in the current neighborhood window, and the cumulative squared error of each observation point in the current window relative to the fitted line is calculated. If the cumulative squared error is less than or equal to the preset error threshold, and the current window has not yet reached the preset maximum time span, the window expands bidirectionally with the target point as the center. Each time an observation is included forward, an observation is included backward, and so on. If the cumulative squared error is greater than the error threshold, or the current window has reached the maximum time span, then the expansion stops, and the window that most recently met the error threshold constraint is taken as the effective fitting window.
[0006] Preferably, the error threshold is set according to the data fluctuation characteristics of different industrial variables, and different variables adopt their respective corresponding error thresholds.
[0007] Preferably, the process of obtaining the trend sequence corresponding to the original input sequence includes: Based on the fitting slope of the effective fitting window, the arctangent function is used to map the slope into a trend direction feature that characterizes the trend direction and intensity. Based on the left and right boundary indices of the effective fitting window, the total number of observation points contained within the window is calculated and used as the trend duration feature. After traversing all observation points, a slope feature sequence and a duration feature sequence corresponding to each point of the original input sequence are formed, and the slope feature sequence and the duration feature sequence are standardized respectively.
[0008] Preferably, the process of feature fusion through an attention mechanism includes: The slope feature sequence and duration feature sequence in the trend sequence are projected into a high-dimensional space, and the two sets of projected features are stacked along the feature dimension to form a trend candidate representation. The numerical features of the original input sequence are projected into a high-dimensional space to form a numerical candidate representation; Query terms are generated based on the numerical candidate representation, and key and value terms are generated based on the trend candidate representation. A multi-head attention mechanism is used to calculate the query item, key item, and value item to obtain the fused features.
[0009] Preferably, the query item is generated only from the numerical candidate representation, the key item and the value item are generated only from the trend candidate representation, and the attention weight is used to characterize the matching relationship between the current numerical state and the corresponding trend state.
[0010] Preferably, the computation process using a multi-head attention mechanism includes: Learnable query, key, and value projection weights are independently configured for each attention head, and the query, key, and value items are projected to the subspace of each attention head respectively. In each attention head, the dot product of the query vector and the key vector is calculated. The dot product result is scaled by dimension and then processed by a normalized exponential function to obtain the attention weight. The value vector is then weighted and summed using the attention weight to obtain the output of the attention head. The outputs of all attention heads are concatenated along the feature dimension and transformed using a learnable output mapping matrix to obtain the fused features.
[0011] Preferably, the process of obtaining the underlying enhanced features includes: The fused features are added element-wise to the numerical candidate representations to complete the residual connection; The result after residual connection is subjected to layer normalization to obtain the bottom layer enhanced features.
[0012] Preferably, the deep learning prediction model is a neural network model trained using the backpropagation algorithm. The underlying enhanced features are input into the neural network model, and the neural network model outputs the future multi-step prediction results.
[0013] Preferably, the neural network model includes a model based on a transformer structure, a model based on a graph neural network structure, a model based on a convolutional neural network structure, a model based on a recurrent neural network structure, and a model based on a multilayer perceptron structure.
[0014] Compared with the prior art, the present invention has the following advantages and technical effects: First, the present invention uses an error-constrained adaptive local linear fitting method to adaptively determine the optimal fitting window for each observation point, thereby obtaining a stable long-term trend estimate in the steady change section, while keeping the window tight in the volatile section to retain local detail information, avoiding the problem of trend oversmoothing or information loss caused by fixed window size, and effectively improving the accuracy and adaptability of local trend extraction.
[0015] Second, this invention quantifies local trends into trend direction and intensity features and trend duration features, so that each sampling point has both numerical state and trend state characteristics, providing richer evolutionary pattern information for predictive modeling.
[0016] Third, this invention uses an attention mechanism to fuse numerical features as query terms and trend features as keys and values, enabling the current numerical state to adaptively aggregate the corresponding trend component information. This achieves collaborative perception of trends and values at the underlying input feature level, making up for the shortcomings of existing methods that rely solely on numerical information while ignoring the direction of evolution. It also enhances the prediction model's ability to identify and respond to non-stationary fluctuations, trend reversals, and local mutations.
[0017] Fourth, the trend extraction and feature fusion processes of this invention are applied to the time series of a single variable itself, without constructing cross-variable interaction weights or adjacency relationships. It can be flexibly embedded as an independent underlying enhancement module into various mainstream deep learning prediction models, and has good versatility and engineering applicability.
[0018] Fifth, this invention sets different error thresholds for the data characteristics of different industrial variables, so that the trend segmentation scale of each variable can be independently adjusted according to its own fluctuation level, which further improves the adaptability and prediction performance of the method in complex industrial scenarios. Attached Figure Description
[0019] The accompanying drawings, which form part of this application, are used to provide a further understanding of this application. The illustrative embodiments and descriptions of this application are used to explain this application and do not constitute an undue limitation of this application. In the drawings: Figure 1 This is a schematic diagram of the method flow according to an embodiment of the present invention; Figure 2 This is an example diagram of the local trend evolution of a time series according to an embodiment of the present invention; Figure 3 This is a schematic diagram of the trend-numerical feature fusion module based on the attention mechanism in an embodiment of the present invention; Figure 4 This is a comparison chart of the prediction results of the original prediction model and the prediction model after incorporating the local trend features of this embodiment in the unit load prediction task. Detailed Implementation
[0020] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.
[0021] It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.
[0022] Example 1 This embodiment provides an industrial time series forecasting method that integrates local trend features, including: Time series observation data of industrial processes are acquired, and after preprocessing, the original input sequence is constructed. Based on the original input sequence, an initial neighborhood window is constructed with each observation point as the center. Under error constraints, the initial neighborhood window is expanded bidirectionally and linearly fitted to obtain local trend information of adaptive span segmentation. Based on the local trend information of adaptive span segmentation, the trend direction feature and trend duration feature corresponding to each observation point are determined, and a point-by-point sliding window strategy is used to traverse all time points to obtain the trend sequence corresponding to the original input sequence. The numerical features of the original input sequence are used as query terms, and the features of the trend sequence are used as key and value terms. Feature fusion is performed through an attention mechanism, and the low-level enhanced features are obtained through residual connection and layer normalization. By inputting the underlying enhanced features into a deep learning prediction model, prediction results for multiple future steps can be obtained.
[0023] The method in this embodiment extracts the corresponding slope and duration by performing adaptive local linear fitting with error constraints on the original sequence, thereby realizing the quantitative representation of local trend information; it assigns a corresponding trend state to the numerical features of each sampling point through an attention mechanism to enhance the underlying features of the driving model; and it inputs the fused features into a deep learning prediction model to obtain future prediction results.
[0024] This embodiment effectively captures the evolution patterns of industrial processes through the collaborative perception of trends and numerical features, thereby improving prediction performance. It is also compatible with a variety of mainstream deep learning frameworks, demonstrating good versatility and practical engineering value.
[0025] Furthermore, the time series observation data of industrial processes obtained in this embodiment includes univariate time series data or multivariate time series data; when the observation data is multivariate time series data, the local trend quantification and trend-numerical fusion process in this embodiment can be applied to the time series of each variable itself.
[0026] Furthermore, the process of obtaining local trend information for adaptive span segmentation includes: Construct an initial neighborhood window centered on any observation point in the original input sequence, containing the observation point and one adjacent point before and after it. During each expansion, the least squares method is used to perform linear fitting on all observation points in the current neighborhood window, and the cumulative squared error of each observation point in the current window relative to the fitted line is calculated. If the cumulative squared error is less than or equal to the preset error threshold, and the current window has not yet reached the preset maximum time span, expand bidirectionally with the target point as the center. Each time, one observation is included forward, and then one observation is included backward in the next time. If the cumulative squared error exceeds the error threshold, or the current window has reached its maximum time span, then the expansion stops, and the window that most recently met the error threshold constraint is taken as the effective fitting window.
[0027] Furthermore, in this embodiment, an initial neighborhood window is constructed with each observation point of the original sequence as the center, the data within the window is subjected to least squares linear fitting, and the local neighborhood window is expanded bidirectionally under error constraints to obtain local trend information of adaptive span segmentation. The error constraints include a cumulative fitting error threshold and a maximum time span constraint. When the neighborhood window meets the cumulative fitting error threshold and has not reached the maximum time span, the window continues to expand; otherwise, the expansion stops, and the candidate window that most recently met the constraints is taken as the effective fitting window.
[0028] Specifically, under error constraints, the local neighborhood window is expanded bidirectionally, including: Using any observation point in the original input sequence Construct an initial neighborhood window centered on [the location of the window]. ; During each expansion, the least squares method is used to perform a linear fit on the data within the current window, and the cumulative fitting error is calculated: (1) in, and The first The fitted slope and intercept of the second expansion, and This represents the start and end indices of the current window. This is a relative time offset; If satisfied If the window does not reach the preset maximum time span, it continues to expand; otherwise, it stops expanding and the candidate window that most recently met the above constraints is taken as the effective fitting window.
[0029] Furthermore, the error threshold The error thresholds are set separately according to the data fluctuation characteristics of different industrial variables, and different variables use their own corresponding error thresholds to avoid the over-segmentation of some variable trends or the obscuring of key trend information due to a uniform threshold.
[0030] Furthermore, the process of obtaining the trend sequence corresponding to the original input sequence includes: Based on the fitting slope of the effective fitting window, the arctangent function is used to map the slope into a trend direction feature that characterizes the trend direction and intensity. The total number of observation points contained within the window is calculated based on the left and right boundary indices of the effective fitting window, and is used as a feature of trend duration. After traversing all observation points, a slope feature sequence and a duration feature sequence corresponding to each point of the original input sequence are formed, and the slope feature sequence and the duration feature sequence are standardized respectively.
[0031] Furthermore, this embodiment defines the slope and duration as corresponding trend quantification elements based on local trend information of adaptive span segmentation, and uses a point-by-point sliding window strategy to traverse all time points to obtain the trend sequence corresponding to the original sequence; wherein, the slope is used to characterize the direction and intensity of the local trend, and the duration is used to characterize the time range of the local trend state, so that each sampling point has both numerical state and local trend state.
[0032] Specifically, slope and duration are defined as corresponding trend quantification elements, including: Based on the fitting slope corresponding to the effective window and window start and end index , Define the trend direction and strength characteristics and trend duration characteristics : (2) in, It is the arctangent function; Traversing all involved observation points forms the original input sequence. Slope sequence corresponding to each point and duration sequence And standardize it.
[0033] Furthermore, the process of feature fusion through attention mechanisms includes: The slope feature sequence and duration feature sequence in the trend sequence are projected into a high-dimensional space, and the two sets of projected features are stacked along the feature dimension to form a trend candidate representation. The numerical features of the original input sequence are projected into a high-dimensional space to form a numerical candidate representation; Generate query terms based on numerical candidate representations, and generate key and value terms based on trend candidate representations; A multi-head attention mechanism is used to calculate the query terms, key terms, and value terms to obtain the fused features.
[0034] Furthermore, query items are generated only from numerical candidate representations, key items and value items are generated only from trend candidate representations, and attention weights are used to characterize the matching relationship between the current numerical state and the corresponding trend state.
[0035] Furthermore, the process of computation using a multi-head attention mechanism includes: Each attention head is independently configured with learnable query, key, and value projection weights, and the query, key, and value items are projected to the subspace of each attention head respectively. In each attention head, the dot product of the query vector and the key vector is calculated. The dot product result is scaled by dimension and then processed by a normalized exponential function to obtain the attention weight. The value vector is then weighted and summed using the attention weight to obtain the output of the attention head. The outputs of all attention heads are concatenated along the feature dimension, and the fused features are obtained by transforming the output mapping matrix through a learnable matrix.
[0036] Furthermore, the process of obtaining the underlying enhanced features includes: The fused features are added element-wise to the numerical candidate representations to complete the residual connection; The results after residual connection are subjected to layer normalization to obtain the bottom layer enhanced features.
[0037] Furthermore, in this embodiment, the numerical features of the original input sequence are projected as queries, and the features of the trend component elements are projected as keys and values. These are then fused through a multi-head attention mechanism and obtained through residual connections and layer normalization to drive the underlying enhancement features of the prediction model. The trend component elements include slope and duration. The query terms are generated from numerical sequences, the keys and values are generated from the corresponding slope sequences and duration sequences, and the attention weights are only used to characterize the matching relationship between numerical features and trend quantification elements, without involving multivariate interactions.
[0038] Specifically, the fusion process of multi-head attention mechanisms includes: slope sequence and duration sequence Each feature is projected onto a high-dimensional latent space and stacked along the feature dimensions to form a trend candidate representation: (3) numerical sequence Perform spatial projection to form candidate representations: (4) Then, based on the above, construct the query, key, and value: (5) in, For spatial projection matrix, This is the weight matrix related to the attention mechanism; Furthermore, a multi-head attention path is employed to capture information interactions in parallel across different subspaces, for the first... The calculation method for each attention point is as follows: (6) Finally, the outputs of multiple attention heads are concatenated and mapped using a learnable output mapping matrix. Obtain fusion features : (7) Furthermore, the fused features and the numerical feature projection results are residually connected, and the bottom-level enhanced features are obtained through layer normalization: (8) in, Representative level normalization, This is the final underlying enhancement feature.
[0039] It should be noted that the fusion method of numerical features and trend features involved in this embodiment is only used to establish the feature association between the numerical state and its corresponding trend state in the same observed variable; wherein, the query item is generated by the numerical sequence, the key and value are generated by the corresponding slope sequence and duration sequence, and the attention weight is only used to characterize the matching relationship between the numerical features and the trend quantification elements. Therefore, the fusion method does not involve multivariate interaction.
[0040] Furthermore, the deep learning prediction model is a neural network model trained using the backpropagation algorithm. The low-level enhanced features are input into the neural network model, and the neural network model outputs the prediction results for multiple future steps.
[0041] Furthermore, neural network models include models based on transformer structures, models based on graph neural network structures, models based on convolutional neural network structures, models based on recurrent neural network structures, and models based on multilayer perceptron structures.
[0042] Furthermore, this embodiment inputs enhanced trend and numerical features into a deep learning prediction model to obtain multi-step prediction results. The neural network prediction model includes one or more of the following: Transformer-type models, graph neural network-type models, convolutional neural network-type models, recurrent neural network-type models, or multilayer perceptron-type models; the neural network prediction model updates parameters through a prediction loss function and a backpropagation algorithm.
[0043] Specifically, the deep learning prediction model is a neural network prediction model trained using the backpropagation algorithm. Using a training method adapted to the fusion module, the underlying enhancement features corresponding to each sample are input into the prediction model to obtain the future prediction result. , is represented as: (9) This embodiment constructs local trend information for each observation point through adaptive local linear fitting with error constraints, which can simultaneously characterize the local change direction and duration of industrial time series, providing a novel driving element for predictive modeling.
[0044] The prediction method provided in this embodiment enables the current numerical features to adaptively aggregate the corresponding trend components, enhancing the ability of the prediction model to express the underlying input features and making up for the shortcomings of existing methods that rely solely on numerical information for modeling and are unable to fully capture the evolution patterns of industrial processes.
[0045] The trend-numerical feature fusion part of this embodiment can be embedded into mainstream neural network prediction models as an independent underlying feature enhancement module. It does not involve constructing adjacency relationships between variables or cross-variable fusion weights, and has good versatility and engineering applicability.
[0046] This embodiment inputs the fused underlying enhanced features into the existing prediction model, which helps to improve the accuracy and robustness of its time series prediction.
[0047] As an optional implementation, such as Figure 1 As shown in the figure, this embodiment proposes an industrial time series forecasting method that integrates local trend features, specifically including the following steps: Step S1: Acquire time-series observation data of the industrial process, and construct the original input sequence after preprocessing. The time-series observation data can come from industrial field sensors, process control systems, data acquisition and monitoring systems, or historical operation databases.
[0048] Preprocessing includes various techniques such as missing value handling, outlier handling, and normalization. For the first... The processed historical observation sequence of a given industrial variable can be represented as follows: ; in, Indicates the length of the time series. Indicates the first Individual industrial variables at time... The observed values. In this embodiment, the local trend quantification and trend-numerical fusion processes are applied to the time series of each variable itself, without constructing additional interaction relationships between different variables. For ease of description, variable superscripts are omitted below without causing confusion. .
[0049] Step S2: Construct an initial neighborhood window centered on each observation point in the original input sequence, perform least-squares linear fitting on the data within the window, and expand the local neighborhood window bidirectionally under error constraints to obtain local trend information of adaptive span segmentation.
[0050] Specifically, for the central observation point The initial neighborhood window can be represented as And perform least-squares linear fitting on the data within the current window, and calculate the cumulative fitting error: ; in, and The first The fitted slope and intercept of the second expansion, and This represents the start and end indices of the current window. This is a relative time offset.
[0051] If the following conditions are met: ; Then, the local neighborhood window is expanded, incorporating one observation point forward and / or backward each time to update the candidate window; otherwise, the expansion stops, and the candidate window that most recently met the constraints is taken as the effective fitting window. The expansion process should not exceed the preset maximum time span. This is the error threshold corresponding to the current industrial variable. The error threshold can be set differently for the data characteristics of different industrial variables to avoid the over-segmentation of some variable trends or the obscuring of key trend information due to a uniform threshold.
[0052] Through the above processing, each observation point corresponds to a neighborhood window with an adaptive span. For time segments with relatively stable changes, the effective fitting window can be appropriately expanded to obtain a more stable trend estimate; for time segments with abrupt changes or strong fluctuations, the effective fitting window will stop expanding under error constraints to preserve local change information.
[0053] Step S3: Based on the effective fitting window obtained in step S2, the slope and duration are defined as the corresponding trend quantization elements, and a point-by-point sliding window strategy is used to traverse all time points to obtain the trend sequence corresponding to the original input sequence.
[0054] like Figure 2 As shown, equivalent numerical information may correspond to different local trend states, such as an upward trend, a downward trend, or a stable trend. Therefore, this embodiment uses both the trend slope and the trend duration to characterize the local trend state of the observation point, so that each observation point not only has the original numerical state, but also its corresponding trend evolution state.
[0055] Specifically, based on the fitting slope corresponding to the effective fitting window, trend direction and intensity features are defined: ; in, The slope of the fitting curve for the effective window corresponding to the current observation point. This is the arctangent function. By mapping the slope using the arctangent function, we can suppress the impact of abnormal peaks or extreme disturbances on the trend representation while preserving trend direction information.
[0056] Based on the left and right boundaries of the effective fitting window, the trend duration feature is defined: ; in, and These are the left and right boundary indices of the effective fitting window, respectively. The trend duration feature is used to represent the duration of the current local trend state over time.
[0057] After traversing all observation points, the trend slope sequence is obtained. and trend duration series The numerical feature sequence corresponding to the original numerical sequence is denoted as In practice, the trend slope sequence and trend duration sequence can be standardized to make them have a similar numerical scale to the numerical feature sequence in the subsequent fusion process.
[0058] Step S4: The numerical features and trend features are fused through a multi-head attention mechanism, and the resulting low-level enhanced features are obtained through residual connection and layer normalization to drive the prediction model.
[0059] like Figure 3 As shown, the trend-numerical feature fusion module uses numerical features as query terms and trend slope features and trend duration features as keys and values, enabling the current numerical state to adaptively aggregate the corresponding trend state, thereby injecting local trend information into the underlying input features.
[0060] Specifically, the slope sequence and duration sequence are projected into a high-dimensional latent space and stacked to form a trend candidate representation: ; in, This is the spatial projection matrix corresponding to the slope sequence. This is the spatial projection matrix corresponding to the duration sequence.
[0061] The original numerical feature sequence Projection as a numerical candidate representation: ; Then, based on the above settings, construct the query, key, and value: ; in, This is the spatial projection matrix corresponding to the numerical feature sequence. , , This is the learnable weight matrix in the attention mechanism.
[0062] This part generally employs a multi-head attention path, for the first... Each attention point is calculated as follows: ; in, The key vector dimension is used. The outputs of multiple attention heads are concatenated, and the fused features are obtained through the output mapping matrix. ; Furthermore, the fused features and the numerical feature projection results are residually connected, and the bottom-level enhanced features are obtained through layer normalization: ; in, Presentation layer normalization operation, This represents the final enhanced low-level features.
[0063] It should be noted that the trend-numerical fusion method in step S4 is only used to establish the feature association between the numerical state and its corresponding trend state of the same observed variable, and does not construct interaction weights, adjacency relationships, or cross-variable attention between different industrial variables. The dependencies between different variables can be modeled by the subsequent neural network prediction model according to its own structure.
[0064] Step S5: Input the low-level enhanced features obtained in step S4 into the deep learning prediction model to obtain the prediction results for future multiple steps. The deep learning prediction model is a neural network prediction model trained using the backpropagation algorithm.
[0065] The prediction process is represented as follows: ; in, This represents a neural network prediction model. This indicates the predicted fitting result. Neural network prediction models can include one or more of the following: Transformer-type models, graph neural network-type models, convolutional neural network-type models, recurrent neural network-type models, or multilayer perceptron-type models.
[0066] This embodiment uses the load prediction task of a supercritical thermal power unit as an application example. The operation of this thermal power unit is characterized by high-dimensional operating parameters, strong dynamic coupling, and random scheduling disturbances. The unit load is affected not only by historical load changes but also by variables such as feedwater flow rate, condensate flow rate, main steam pressure, and steam temperature. The relevant dataset comes from the historical operating records of a supercritical thermal power unit, containing 15,773 samples with a sampling interval of 1 minute. The main process variables include: unit electrical load UL50 (MW); condensate flow rate F501 (t / h); boiler feedwater flow rate F502 (t / h); turbine inlet pressure P501 (MPa); main steam temperature before the high-pressure regulating valve T501 (°C); and final reheat steam outlet temperature T502 (°C). The unit electrical load UL50 is used as the prediction target.
[0067] In the experimental setup, the samples were divided into training, validation, and test sets in a 6:2:2 ratio. Mean Absolute Error (MAE) and Root Mean Square Error (RMSE) were used as evaluation metrics. MAE measures the average level of the absolute value of the prediction error, while RMSE measures the square root of the average squared prediction error. Smaller values for both indicate better prediction performance.
[0068] In this application example, the method for fusing local trend features of this embodiment is combined with eight mainstream forecasting models, including MLP, LSTM, Transformer, Informer, PatchTST, Crossformer, iTransformer, and CATS. Simultaneously, the original forecasting models that do not incorporate the local trend features of this embodiment are used as comparison objects, and unit load forecasting experiments are conducted for each model. Figure 4 As shown in Table 1, the prediction results and evaluation indicators demonstrate that, compared with the original prediction model, the prediction model after introducing the local trend features of this embodiment exhibits better prediction performance at each prediction step size, thus verifying the effectiveness of the method in this embodiment.
[0069] Table 1 Furthermore, to further verify the superiority of the trend feature utilization method in this embodiment, a comparison was made between the currently more advanced trend decomposition models and the prediction model proposed in this embodiment. As shown in the evaluation metrics in Table 2, the trend feature fusion method of this embodiment achieves lower prediction errors during prediction modeling, indicating that the method of this embodiment has a superior effect in utilizing trend features.
[0070] Table 2 In summary, the industrial time series forecasting method that integrates local trend features provided in this embodiment does not rely on a specific neural network model structure and can be combined with various deep learning forecasting models as a bottom-level feature enhancement method. At the same time, this method can provide local trend states for each observation point, enabling the forecasting model to further perceive the evolution pattern of industrial processes based on numerical information, thereby improving the accuracy and robustness of industrial time series forecasting.
[0071] The above are merely preferred embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
[0072] On the other hand, this embodiment also provides an electronic device, including a memory, a processor, and a computing program stored in the memory and executable on the processor, wherein the processor implements the method when executing the computing program.
[0073] On the other hand, this embodiment also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method.
[0074] The above are merely preferred embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. An industrial time series forecasting method that integrates local trend features, characterized in that, include: Time series observation data of industrial processes are acquired, and after preprocessing, the original input sequence is constructed. Based on the original input sequence, an initial neighborhood window is constructed with each observation point as the center. Under error constraints, the initial neighborhood window is expanded bidirectionally and linearly fitted to obtain local trend information of adaptive span segmentation. Based on the local trend information of the adaptive span segmentation, the trend direction feature and trend duration feature corresponding to each observation point are determined, and a point-by-point sliding window strategy is used to traverse all time points to obtain the trend sequence corresponding to the original input sequence. The numerical features of the original input sequence are used as query terms, and the features of the trend sequence are used as key and value terms. Feature fusion is performed through an attention mechanism, and the feature is then processed by residual connection and layer normalization to obtain the bottom-level enhanced features. The underlying enhanced features are input into a deep learning prediction model to obtain prediction results for multiple future steps.
2. The method according to claim 1, characterized in that, The process of obtaining local trend information for adaptive span segmentation includes: With any observation point in the original input sequence as the center, construct an initial neighborhood window containing the observation point and one adjacent point before and after it; During each expansion, the least squares method is used to perform linear fitting on all observation points in the current neighborhood window, and the cumulative squared error of each observation point in the current window relative to the fitted line is calculated. If the cumulative squared error is less than or equal to the preset error threshold, and the current window has not yet reached the preset maximum time span, the window expands bidirectionally with the target point as the center. Each time an observation is included forward, an observation is included backward, and so on. If the cumulative squared error is greater than the error threshold, or the current window has reached the maximum time span, then the expansion stops, and the window that most recently met the error threshold constraint is taken as the effective fitting window.
3. The method according to claim 2, characterized in that, The error thresholds are set according to the data fluctuation characteristics of different industrial variables, and different variables use their respective corresponding error thresholds.
4. The method according to claim 1, characterized in that, The process of obtaining the trend sequence corresponding to the original input sequence includes: Based on the fitting slope of the effective fitting window, the arctangent function is used to map the slope into a trend direction feature that characterizes the trend direction and intensity. Based on the left and right boundary indices of the effective fitting window, the total number of observation points contained within the window is calculated and used as the trend duration feature. After traversing all observation points, a slope feature sequence and a duration feature sequence corresponding to each point of the original input sequence are formed, and the slope feature sequence and the duration feature sequence are standardized respectively.
5. The method according to claim 1, characterized in that, The process of feature fusion through attention mechanisms includes: The slope feature sequence and duration feature sequence in the trend sequence are projected into a high-dimensional space, and the two sets of projected features are stacked along the feature dimension to form a trend candidate representation. The numerical features of the original input sequence are projected into a high-dimensional space to form a numerical candidate representation; Query terms are generated based on the numerical candidate representation, and key and value terms are generated based on the trend candidate representation. A multi-head attention mechanism is used to calculate the query item, key item, and value item to obtain the fused features.
6. The method according to claim 5, characterized in that, The query item is generated only from the numerical candidate representation, the key item and the value item are generated only from the trend candidate representation, and the attention weight is used to characterize the matching relationship between the current numerical state and the corresponding trend state.
7. The method according to claim 5, characterized in that, The process of computation using a multi-head attention mechanism includes: Learnable query, key, and value projection weights are independently configured for each attention head, and the query, key, and value items are projected to the subspace of each attention head respectively. In each attention head, the dot product of the query vector and the key vector is calculated. The dot product result is scaled by dimension and then processed by a normalized exponential function to obtain the attention weight. The value vector is then weighted and summed using the attention weight to obtain the output of the attention head. The outputs of all attention heads are concatenated along the feature dimension and transformed using a learnable output mapping matrix to obtain the fused features.
8. The method according to claim 1, characterized in that, The process of obtaining low-level enhanced features includes: The fused features are added element-wise to the numerical candidate representations to complete the residual connection; The result after residual connection is subjected to layer normalization to obtain the bottom layer enhanced features.
9. The method according to claim 1, characterized in that, The deep learning prediction model is a neural network model trained using the backpropagation algorithm. The underlying enhanced features are input into the neural network model, and the neural network model outputs the future multi-step prediction results.
10. The method according to claim 9, characterized in that, The neural network models include models based on transformer structures, models based on graph neural network structures, models based on convolutional neural network structures, models based on recurrent neural network structures, and models based on multilayer perceptron structures.
