Time-series-aware industrial data stream prediction method and system
By separating industrial data streams into numerical tracks and event tracks, and identifying and applying differentiated gating operations, the problem of insufficient industrial event boundary identification in existing methods is solved, achieving high-precision prediction and differentiated decision support.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-10
- Publication Date
- 2026-07-10
AI Technical Summary
Existing industrial data stream prediction methods cannot effectively identify and process the semantic boundaries of industrial events, resulting in a systematic deterioration in prediction accuracy at the moment of change in operating conditions. Furthermore, implicit industrial events cannot be automatically identified, and the prediction results lack industrial semantic state annotations, making it impossible for downstream decision-making systems to adopt differentiated confidence strategies.
The industrial data stream is separated into numerical tracks and event tracks. By identifying the event anchor point time and semantic category, differential gating operations are applied to correct the hidden state sequence, and event state labels are generated. The combined result of multi-step prediction values and labels is output.
It achieves precise boundary localization and semantic classification of industrial events, avoids cross-condition memory contamination, and enables downstream systems to make differentiated decisions based on event status labels, thereby improving prediction accuracy and robustness.
Smart Images

Figure CN122372446A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of industrial forecasting technology, and in particular to a time-aware industrial data stream forecasting method and system. Background Technology
[0002] With the rapid development of the Industrial Internet and intelligent manufacturing, modern industrial production systems continuously generate high-frequency, multi-dimensional data streams through devices such as sensors, controllers, and smart instruments. Real-time prediction of these data streams is a core technical means to achieve predictive maintenance of equipment, optimization of production cycle time, and control of process parameters. Existing time-series-aware industrial data stream prediction methods mainly rely on deep learning architectures such as Long Short-Term Memory Networks, gated recurrent units, and Transformers as their backbone. These methods construct a single continuous numerical sequence from the multi-dimensional readings collected by industrial sensors, predict future states by learning the temporal dependencies of values within a historical time window, and use a fixed-length sliding window as the model's perception boundary. This approach has achieved certain predictive results in scenarios with relatively stable production conditions.
[0003] However, the existing methods mentioned above have fundamental flaws in industrial data stream prediction: they treat industrial data streams as pure numerical sequences, ignoring the discrete event information that objectively exists in the industrial production process, including industrial events such as mold change, batch change, equipment cold start, over-limit alarms, and manual intervention. These events, in terms of physical semantics, can cause reset-like jumps or disturbance-like shifts in equipment operating conditions. The temporal memory mechanism of existing methods cannot perceive such operating condition boundaries, causing the model to continuously accumulate and transmit historical memories from different operating conditions when crossing event boundaries. This causes historical numerical data before mold change or cold start to interfere with the prediction after mold change, resulting in a systematic deterioration of prediction errors at the moment of operating condition change, with particularly low prediction accuracy during the reset and reconstruction phase.
[0004] Even with the introduction of industrial event information as an auxiliary input feature, existing methods still simply concatenate event information and numerical information at the feature level and input them into the model uniformly. Event information cannot directly control the temporal memory within the model, and the memory contamination problem is not fundamentally eliminated. Furthermore, when the event recording system in the industrial field has missing or delayed annotations, methods relying on external event input will completely fail. Operating condition deviations caused by implicit industrial events (such as minor process adjustments not recorded by operators) cannot be identified, further leading to insufficient robustness of the prediction model in actual industrial deployment. In addition, existing prediction methods only output numerical prediction results. Downstream manufacturing execution systems cannot determine the industrial semantic state of the current prediction results and cannot adopt differentiated confidence strategies accordingly. This results in the prediction results being used directly for production decisions without distinction during the reconstruction phase after operating condition switching, posing a decision safety risk. Summary of the Invention
[0005] This application provides a time-aware industrial data stream prediction method and system, which solves the problems in existing industrial data stream prediction methods, such as the inability of time-series memory to perceive the semantic boundaries of industrial events, cross-event memory contamination leading to a systematic deterioration of prediction accuracy at the moment of change of operating conditions, the inability to automatically identify implicit industrial events, and the lack of industrial semantic state labeling in prediction results, which prevents downstream decision-making systems from adopting differentiated confidence strategies.
[0006] In a first aspect, this application provides a time-aware industrial data flow prediction method, which includes:
[0007] Step S1: Separate the industrial data stream into a numerical track and an event track. The numerical track carries multi-dimensional time-series readings from sensors, and the event track carries industrial event coding sequences. The timestamps of the two tracks are aligned to form a dual-track input.
[0008] Step S2: Based on the transition relationship between adjacent time points in the event encoding sequence, identify the event anchor point time and the corresponding event semantic category. The event semantic category is divided into state reset category and state disturbance category, forming an event anchor point set.
[0009] Step S3: Input the multi-dimensional time-series readings of the sensors in the dual-track input into the numerical encoder to obtain the hidden state sequence; at the anchor point time in the event anchor point set, apply differentiated gating operation to the hidden state sequence according to the event semantic category: the hidden state at the corresponding time of the state reset category is forced to zero, and the hidden state at the corresponding time of the state disturbance category is multiplied by the attenuation coefficient calculated from the duration of the event to obtain the gating corrected hidden state sequence.
[0010] Step S4: Using the terminal state of the gated modified hidden state sequence as input, the multi-step prediction value is obtained by decoding through the prediction head network. Based on the category of the anchor point closest to the current time and its time interval in the event anchor point set, an event state label is generated. The multi-step prediction value and the event state label are then output together.
[0011] Secondly, this application provides a time-aware industrial data flow prediction system, the time-aware industrial data flow prediction system comprising:
[0012] The separation module is used to separate the industrial data stream into a numerical track and an event track. The numerical track carries multi-dimensional time-series readings from sensors, and the event track carries an industrial event encoding sequence. The timestamps of the two are aligned to form a dual-track input.
[0013] The identification module is used to identify the event anchor point time and the corresponding event semantic category based on the jump relationship between adjacent time encodings in the event encoding sequence. The event semantic category is divided into state reset category and state disturbance category, forming an event anchor point set.
[0014] The calculation module is used to input the multi-dimensional time-series readings of the sensors in the dual-track input into the numerical encoder to obtain the hidden state sequence; at the anchor time in the event anchor set, a differentiated gating operation is applied to the hidden state sequence according to the event semantic category: the hidden state at the corresponding time of the state reset category is forced to zero, and the hidden state at the corresponding time of the state disturbance category is multiplied by the attenuation coefficient calculated from the duration of the event to obtain the gating corrected hidden state sequence.
[0015] The generation module is used to take the terminal state of the gated modified hidden state sequence as input, decode it through the prediction head network to obtain multi-step prediction values, generate event state labels according to the category of the nearest anchor point to the current time and its time interval in the event anchor point set, and output the multi-step prediction values and the event state labels together.
[0016] Thirdly, a time-aware industrial data flow prediction device is provided, comprising: a memory and at least one processor, wherein the memory stores instructions; the at least one processor invokes the instructions in the memory to cause the time-aware industrial data flow prediction device to execute the aforementioned time-aware industrial data flow prediction method.
[0017] Fourthly, a computer-readable storage medium is provided, wherein instructions are stored therein, which, when executed on a computer, cause the computer to perform the aforementioned time-aware industrial data flow prediction method.
[0018] The technical solution provided in this application explicitly separates the industrial data stream into numerical tracks and event tracks at the input layer, constructing a dual-track input structure. This ensures that the industrial event coding sequence and the multi-dimensional time-series readings of sensors are strictly aligned at the timestamp level and independently carry their respective semantic information, fundamentally breaking the modeling assumption of existing methods that treat the industrial data stream as a single numerical sequence. Based on this, by scanning and identifying the transition relationships between adjacent moments in the industrial event coding sequence, the event anchor point moment and the event semantic category are combined to form an event anchor point set. This achieves precise boundary positioning and semantic classification of different types of industrial events, such as mold changing, cold start, over-limit alarms, and manual intervention. This provides subsequent gating operations with clear trigger moments and operational basis, avoiding the fundamental limitation of existing methods where event information is merely used as a general feature in prediction and cannot directly interfere with model memory.
[0019] Driven by the event anchor set, this application applies differentiated gating operations to the hidden state sequence of the numerical encoder. Based on the event semantic category, it distinguishes between two memory processing strategies: forced zeroing and decay retention. This allows the retention and erasure of temporal memory to be directly controlled by industrial physical semantics rather than entirely relying on internal model gradient learning. This completely cuts off cross-condition memory contamination when state reset events occur, and proportionally weakens and retains historical memory according to a function of event duration when state disturbance events occur, forming a gated modified hidden state sequence. Finally, the prediction head network decodes the terminal state of the gated modified hidden state sequence as input to obtain multi-step prediction values. Simultaneously, based on the category of the nearest anchor in the event anchor set and its time interval with the current moment, it generates three types of event state labels: steady-state continuation, reset reconstruction, or disturbance recovery. These labels are jointly encapsulated and output with the multi-step prediction values, enabling the downstream manufacturing execution system to adopt differentiated confidence handling strategies based on the event state labels. This overcomes the shortcomings of existing prediction methods, which have a single semantic output and cannot support condition-aware production decisions. Attached Figure Description
[0020] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0021] Figure 1 This is a schematic diagram of an embodiment of the time-aware industrial data stream prediction method in this application.
[0022] Figure 2 This is a schematic diagram illustrating the changes in the hidden state vector before and after the differentiated gating operation in an embodiment of this application, wherein... Figure 2 (a) is a schematic diagram of the state reset gating effect. Figure 2 (b) is a schematic diagram of the gating effect of state disturbance type;
[0023] Figure 3 This is a schematic diagram illustrating the relationship between the attenuation coefficient and the duration of the event in the embodiments of this application. Detailed Implementation
[0024] This application provides a time-aware industrial data flow prediction method and system. The terms "first," "second," "third," "fourth," etc. (if present) in the specification, claims, and accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in a sequence other than that illustrated or described herein. Furthermore, the terms "comprising" or "having" and any variations thereof are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises 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 such processes, methods, products, or apparatus.
[0025] For ease of understanding, the specific process of the embodiments of this application is described below. Please refer to [link / reference]. Figure 1 One embodiment of the time-aware industrial data stream prediction method in this application includes:
[0026] Step S1: Separate the industrial data stream into a numerical track and an event track. The numerical track carries multi-dimensional time-series readings from the sensors, and the event track carries the industrial event coding sequence. The timestamps of the two are aligned to form a dual-track input.
[0027] Specifically, the essential difference between numerical and event tracks lies in the different physical properties of the signals: the multidimensional time-series readings from sensors in the numerical track are continuously changing physical quantities, including temperature, pressure, current, and vibration acceleration, which are continuously collected at fixed sampling periods to form a multidimensional numerical matrix with equal time intervals; the industrial event coding sequence in the event track is a discrete semantic tag, carrying a non-zero code only at the moment the industrial event occurs, and filling the rest with zero values. The specific implementation of timestamp alignment between the two is as follows: using the sampling period of the numerical track as the reference clock, the occurrence time of each industrial event in the event track is mapped to the most recent sampling time, and those less than one sampling period are aligned to the current sampling point, so that the two tracks correspond moment by moment on the same time axis, forming a dual-track input.
[0028] Step S2: Based on the transition relationship between adjacent time points in the event encoding sequence, identify the event anchor point time and the corresponding event semantic category. The event semantic category is divided into state reset category and state disturbance category, forming an event anchor point set.
[0029] Specifically, the identification of event anchor moments is based on the transition relationship between adjacent time-series codes. That is, the moment when the industrial event coding sequence changes from zero to a non-zero value is determined as the event anchor moment. This transition marks the initial boundary of the industrial production state transitioning from normal operation to a certain type of event-driven state. The classification of event semantic categories is based on industrial physical semantics: mold-changing events and cold-start events both cause fundamental changes in the equipment's working object or initial operating condition. The former involves switching production types, and the latter involves the equipment re-establishing thermal equilibrium from a power-off state. Both render historical numerical data useless for the current operating condition, thus classifying them as state reset events. Brief over-limit alarms and manual intervention events only cause limited disturbances to the current operating condition. The equipment returns to its original operating condition after the event ends, and historical numerical data still has some reference value for the current operating condition, thus classifying them as state disturbance events.
[0030] Step S3: Input the multi-dimensional time-series readings of the sensors in the dual-track input into the numerical encoder to obtain the hidden state sequence; at the anchor point time in the event anchor point set, apply differentiated gating operation to the hidden state sequence according to the event semantic category: the hidden state corresponding to the state reset category is forced to zero, and the hidden state corresponding to the state disturbance category is multiplied by the attenuation coefficient calculated from the event duration to obtain the gating correction hidden state sequence.
[0031] Specifically, the core of differentiated gating operation lies in clearing the memory of the hidden state of the numerical encoder to different degrees according to the semantic category of the event. For state reset events, both the hidden state vector and the cell state vector at the corresponding moment are forcibly assigned to all zero vectors. This is because the physical operating conditions of the equipment after mode change or cold start are completely different from those described by historical data, and retaining historical memory would only introduce noise interference. For state disturbance events, the hidden state at the corresponding moment is multiplied by an attenuation coefficient instead of being cleared to zero. The attenuation coefficient is calculated based on the duration of the event: the attenuation coefficient is larger when the duration is 1 sampling period (approximately 0.74), and smaller when the duration is 3 sampling periods (approximately 0.41). That is, the longer the event lasts, the stronger the weakening of historical memory, but it is not completely cleared, and historical trend information that is still valid for the current operating conditions is retained.
[0032] Step S4: Using the terminal state of the gated modified hidden state sequence as input, the prediction head network decodes the multi-step prediction value and generates an event state label based on the category of the nearest anchor point to the current time and its time interval in the event anchor point set. The multi-step prediction value and the event state label are then output together.
[0033] Specifically, event status labels are generated by comparing the time interval between the current moment and the nearest event anchor point with a stabilization period threshold. The stabilization period threshold is twice the production cycle time, which is determined by the process parameters of the specific production line. When the time interval exceeds the stabilization period threshold, it is determined that the equipment has re-entered a stable operating state, and a steady-state continuation label is generated. When the time interval does not exceed the stabilization period threshold and the nearest anchor point is a state reset type, a reset reconstruction label is generated, indicating that the prediction result is in the reconstruction stage after a state switch. When the time interval does not exceed the stabilization period threshold and the nearest anchor point is a state disturbance type, a disturbance recovery label is generated, indicating that the equipment is in the recovery stage after a disturbance event. Multi-step predicted values and event status labels are encapsulated into structured data packets and jointly output. The downstream manufacturing execution system adopts different confidence handling strategies for the predicted values based on the event status label category.
[0034] In one specific embodiment, step S1 includes:
[0035] Each industrial event is extracted from the manufacturing execution system operation log, programmable logic controller alarm record, and process parameter change record. Each industrial event is assigned a unique integer code. The code for normal operation is 0, the codes for mold change event and cold start event are 1 and 2 respectively, the code for brief over-limit alarm event is 3, and the code for manual intervention event is 4. Industrial events coded as 1 and 2 are classified as state reset events, and industrial events coded as 3 and 4 are classified as state disturbance events, thus obtaining the event semantic category of each industrial event.
[0036] Based on the semantic category of the event, the timestamps of each industrial event are aligned with a fixed sampling period, and the time when no event occurs is filled with 0 codes to obtain the industrial event coding sequence.
[0037] The multidimensional readings of each sensor in the industrial field at time t are combined into a numerical vector. A historical window of length T is continuously collected with a fixed sampling period. Z-score standardization is performed on each dimension using the training set statistics to obtain a standardized numerical matrix.
[0038] By using a standardized numerical matrix as the numerical track and an industrial event coding sequence as the event track, and strictly aligning the timestamps according to a fixed sampling period, a dual-track input is obtained.
[0039] Specifically, the fixed sampling period is determined by the physical response characteristics of the equipment in the industrial field, and is specifically set to half of the equipment's fastest physical response time constant to satisfy the Nyquist sampling theorem and ensure that frequency aliasing does not occur in the multi-dimensional time-series readings of the sensors in the numerical trajectory. The principle for determining the historical window length T is to cover at least two complete production cycle times to ensure that the standardized numerical matrix contains the complete periodicity of the equipment under stable operating conditions. In Z-score standardization, the mean and standard deviation of each dimension are statistically derived from the training set. During the inference phase, the statistics of the training set are used instead of the statistics of the current window because the current window may be in a period of event disturbance, and its local statistics may deviate from the steady-state distribution. Using the statistics of the training set as a benchmark can ensure the consistency of the standardization scale.
[0040] The classification of industrial event coding systems is based on industrial physical semantics: mold change events are coded as 1, and cold start events are coded as 2. Both cause a fundamental change in the working object or initial thermal condition of the equipment, and their subsequent numerical data is not continuous with the historical data before the change, so they belong to the state reset category; brief over-limit alarms are coded as 3, and manual intervention events are coded as 4. The impact of both on the equipment condition can naturally decay and recover after the event ends, and the historical numerical data still has some reference value for the current condition, so they belong to the state disturbance category. No event occurs is filled with code 0, which, together with the above non-zero codes, constitutes a complete industrial event coding sequence covering the time axis, ensuring a one-to-one correspondence between the event track and the numerical track at each sampling moment, forming a dual-track input.
[0041] In one specific embodiment, step S2 includes:
[0042] The industrial event coding sequence is scanned time by time, and the time when the coding value at time t is non-zero and the coding value at time t-1 is zero is determined as the event anchor time, thus obtaining the event anchor time;
[0043] Based on the industrial event codes at each event anchor point, the event anchor points with codes belonging to the mold change and cold start categories are marked as state reset categories, and the event anchor points with codes belonging to the over-limit alarm and manual intervention categories are marked as state disturbance categories, thus obtaining the event semantic category corresponding to each event anchor point.
[0044] Each event anchor point moment is paired with its corresponding event semantic category to form a tuple, which is then used to obtain the event anchor point set.
[0045] Specifically, the determination of the event anchor point time adopts the transition edge detection logic. That is, only the starting time when the industrial event encoding sequence transitions from zero to a non-zero value is recorded as the event anchor point time. When the encoding of multiple consecutive times is non-zero, only the first non-zero time is determined as the event anchor point time, and subsequent consecutive non-zero times are not recorded repeatedly. This ensures that the same industrial event corresponds to only one event anchor point time in the event anchor point set. This determination method makes the event anchor point time accurately correspond to the starting boundary of the industrial state transition, avoiding the same event being repeatedly counted into the event anchor point set, which would lead to the gating operation being triggered multiple times.
[0046] Each event anchor point is paired with its corresponding event semantic category, where the first element is the time step index of the event anchor point, and the second element is the semantic category label value for that time, taken from either the state reset class or the state perturbation class. All pairs are sorted in ascending order of time step index and then summarized to obtain the event anchor point set. This event anchor point set is used as the traversal object in the differential gating operation of subsequent step S3. The gating operation sequentially performs zeroing or decay processing on the corresponding positions in the hidden state sequence according to the time step index. If the event anchor point set is empty, the gating operation is not performed, and the hidden state sequence remains unchanged from the original output of the numerical encoder.
[0047] In one specific embodiment, in step S3, the multi-dimensional timing readings of the sensors from the dual-track input are input into the numerical encoder to obtain the hidden state sequence, including:
[0048] The standardized numerical matrix from the dual-track input is fed into the dual-layer long short-term memory network step by step according to the time step. The first layer of the dual-layer long short-term memory network has 128 hidden units and the second layer has 64 hidden units. Dropout with a dropout rate of 0.2 is applied between the two layers to obtain the hidden state vector and cell state vector at each time step.
[0049] The hidden state vectors and cell state vectors are arranged according to time steps to obtain the hidden state sequence.
[0050] Specifically, the dimension of the standardized numerical matrix is the product of the historical window length T and the sensor dimension d, i.e., the matrix shape is T rows and d columns. When inputting into the two-layer long short-term memory network step by step, each time step inputs a row vector of dimension d. Initially, the hidden state vectors and cell state vectors of the first and second layers are initialized to all zeros. The first layer receives the d-dimensional input vector of the current time step and the 64-dimensional hidden state vector of the first layer at the previous time step, outputting a 128-dimensional hidden state vector which is then fed into the second layer. The second layer receives the 128-dimensional vector after Dropout processing and the 64-dimensional hidden state vector of the second layer at the previous time step, outputting a 64-dimensional hidden state vector and a 64-dimensional cell state vector. The number of hidden units in the first layer is set to 128 to establish sufficient intermediate representation capacity between the input dimension d and the output dimension 64 of the second layer. The number of hidden units in the second layer is set to 64 to compress the temporal features to a fixed dimension for use by the subsequent prediction head network. Dropout with a dropout rate of 0.2 is applied between the two layers. During the training phase, each element in the 128-dimensional vector output by the first layer is randomly set to zero with a probability of 0.2. Dropout is turned off during the inference phase. The dropout rate of 0.2 is determined based on the principle of balancing the risk of overfitting and the feature retention rate on industrial time series data.
[0051] The 64-dimensional hidden state vector and the 64-dimensional cell state vector at each time step are arranged sequentially from step 1 to step T. The hidden state vector sequence has a shape of T rows and 64 columns, and the cell state vector sequence also has a shape of T rows and 64 columns. The two are combined to form the hidden state sequence. Each row in the hidden state sequence corresponds strictly one-to-one with the time step of the corresponding row in the standardized numerical matrix, thereby ensuring that when the subsequent differentiated gating operation intervenes in the hidden state sequence at the event anchor time, the time step index is completely aligned with the timestamp in the industrial event coding sequence.
[0052] In one specific embodiment, step S3, at the anchor point time in the event anchor point set, applies a differential gating operation to the hidden state sequence based on the event semantic category, including:
[0053] Traverse the event anchor moments in the event anchor moment set, and force the hidden state vector and cell state vector corresponding to the event anchor moments with the event semantic category of state reset to be all zero vectors. The forced assignment operation is performed synchronously on the two layers of the two-layer long short-term memory network to obtain the zero-reset hidden state vectors of each reset anchor moment.
[0054] The hidden state vector and cell state vector corresponding to the anchor point time of the event semantic category of state disturbance are multiplied by the decay coefficient. The decay coefficient is calculated by the duration of the industrial event corresponding to the anchor point time. The longer the duration, the smaller the decay coefficient, thus obtaining the decayed hidden state vector of each disturbance anchor point time.
[0055] Specifically, the duration of an industrial event is measured as follows: starting from the event anchor point, the industrial event coding sequence is scanned backward, and the number of consecutive non-zero coding moments is counted until the coding value returns to zero. The number of consecutive non-zero coding moments is the duration of the industrial event, measured in sampling periods. The attenuation coefficient is calculated based on the duration using an exponential decay formula, with an attenuation rate parameter of 0.3. This parameter is determined on the training set using a grid search within the range of 0.1 to 0.5 with a step size of 0.05, based on minimizing the mean square error of the validation set. The attenuation coefficient is strictly limited to a range greater than zero and less than or equal to 1. When the duration is 1 sampling period, the attenuation coefficient is calculated using the exponential function at an attenuation rate of 0.3. When the duration is 3 sampling periods, the attenuation coefficient is calculated using the exponential function at a attenuation rate multiplied by the duration of 0.9. The longer the duration, the smaller the attenuation coefficient, but it is always greater than zero. This ensures that the hidden state vector and cell state vector at the corresponding moment of state disturbance events are still non-zero vectors after being multiplied by the attenuation coefficient, thus strictly distinguishing them from the forced zeroing operation of state reset events.
[0056] The forced assignment operation, performed synchronously across both layers of the two-layer long short-term memory network, means that at the anchor point of a state reset event, the 128-dimensional hidden state vector and the 128-dimensional cell state vector of the first layer are simultaneously assigned to all zero vectors, and the 64-dimensional hidden state vector and the 64-dimensional cell state vector of the second layer are also simultaneously assigned to all zero vectors. The assignment operations of both layers are completed within the same time step, without any sequential order. After the assignment is completed, the two-layer long short-term memory network recursively starts from the next time step after this anchor point with an initial state of all zeros, consistent with the all-zero initialization method at the network's initial moment in step S3. The decay operation at the corresponding moment of a state perturbation event is also performed synchronously across both layers. The 128-dimensional hidden state vector and the cell state vector of the first layer are multiplied by the same decay coefficient, and the 64-dimensional hidden state vector and the cell state vector of the second layer are multiplied by the same decay coefficient. The multiplication operation is element-wise multiplication, with each dimension scaled independently, resulting in the decayed hidden state vector at each perturbation anchor point.
[0057] Figure 2 This is a schematic diagram illustrating the changes in the hidden state vector before and after the differentiated gating operation in an embodiment of this application, wherein... Figure 2 (a) is a schematic diagram of the state reset gating effect. Figure 2 (b) is a schematic diagram of the gating effect of state disturbance type. Figure 2 (a) Show the gating operation effect corresponding to the state reset event. The vertical dashed line marks the time of the reset anchor point. The hidden state after gating is zeroed at this time and recursively recursively starts from the initial state of all zeros, which contrasts with the continuous offset of the hidden state before gating after the anchor point. Figure 2(b) Display the gating operation effect corresponding to state disturbance events. The vertical dashed line marks the time of the disturbance anchor point. The amplitude of the hidden state after gating shrinks after being multiplied by the attenuation coefficient at this time, while the hidden state before gating shows a large jump at this time. Figure 2 (a) and Figure 2 (b) The gray dashed lines represent the gated state before access control is enabled, and the black solid lines represent the gated state after access control is enabled.
[0058] Figure 3 This is a schematic diagram illustrating the relationship between the attenuation coefficient and the duration of the event in an embodiment of this application. The figure shows the curves of the attenuation coefficient α as a function of the duration of the event when the attenuation rate λ is 0.1, 0.3, and 0.5, respectively. λ=0.3 is the value selected in this application. When the duration of the event is 1 sampling period, the attenuation coefficient α is approximately 0.741, and when the duration of the event is 3 sampling periods, the attenuation coefficient α is approximately 0.407. The attenuation coefficient decreases monotonically with the increase of the duration and is always greater than zero, which is strictly distinguished from the forced zeroing operation of state reset events.
[0059] In one specific embodiment, step S3, obtaining the gated modified hidden state sequence, includes:
[0060] Keep the hidden state vectors at each time point of any event anchor point in the set of non-triggered event anchor points unchanged, and replace the zero-reset hidden state vectors at each reset anchor point time point and the decayed hidden state vectors at each disturbance anchor point time point with the corresponding positions in the hidden state sequence according to time steps.
[0061] The replaced hidden state vectors at each time step are rearranged according to the time step to obtain the gated modified hidden state sequence.
[0062] Specifically, the method for determining when no event anchor point has been triggered is as follows: the time step index of the current moment is compared one by one with the first element of all pairs in the event anchor point set. If the current time step index is not equal to the first element of any pair in the event anchor point set, then the moment is determined to be a non-anchor point moment, and its corresponding hidden state vector is directly retained as the original output value of the numerical encoder without any modification. The specific operation of time step replacement is as follows: using the time step index as the positioning key, the zero-reset hidden state vector corresponding to each reset anchor point moment in the event anchor point set and the decayed hidden state vector corresponding to each perturbation anchor point moment are written into the row position of the hidden state sequence that is the same as the time step index of the anchor point moment, respectively, overwriting the original numerical encoder output value at that position. The row position of the non-anchor moment remains unchanged.
[0063] After the replacement, the hidden state sequence contains three types of rows: the row containing the zeroed hidden state vector, the row containing the decaying hidden state vector, and the row containing the original hidden state vector. These three types of rows are arranged in ascending order from step 1 to step T according to the time step index, forming a gated modified hidden state sequence. The data structure of the gated modified hidden state sequence is completely consistent with the hidden state sequence before the replacement, with the same shape of T rows and 64 columns. The number and order of time steps remain unchanged. The replacement operation only modifies the numerical content of the row corresponding to the anchor time, without adding or removing any rows. This ensures that the gated modified hidden state sequence and the standardized numerical matrix maintain a strict row-by-row correspondence in time steps, making the position taken by the subsequent prediction head network when using the hidden state vector of the last time step as input clear and unique.
[0064] In one specific embodiment, step S4 includes:
[0065] The terminal hidden state vector of the gated modified hidden state sequence is input into the prediction head network. The prediction head network is composed of a first fully connected layer and a second fully connected layer connected sequentially. The first fully connected layer has 64 nodes and the activation function is ReLU. The number of nodes in the second fully connected layer is the product of the number of prediction steps and the number of sensor dimensions, thus obtaining the standardized multi-step prediction matrix.
[0066] Each dimension of the standardized multi-step prediction matrix is subjected to inverse Z-score standardization using training set statistics to obtain multi-step prediction values;
[0067] Traverse the set of event anchors, and record the difference between the current time and the event anchor time closest to the current time as the time interval. Compare the time interval with the stable period threshold: if the time interval is greater than the stable period threshold or the set of event anchors is empty, generate a steady-state continuation label; if the event semantic category of the closest event anchor time is state reset and the time interval is not greater than the stable period threshold, generate a reset reconstruction label; if the event semantic category of the closest event anchor time is state disturbance and the time interval is not greater than the stable period threshold, generate a disturbance recovery label; use one of the steady-state continuation label, reset reconstruction label, or disturbance recovery label as the event state label.
[0068] The multi-step predicted values and event status labels are encapsulated into a structured data packet to obtain the joint output result.
[0069] Specifically, the terminal hidden state vector of the gated correction hidden state sequence is the row vector with time step index T in the sequence, with a dimension of 64. This vector carries a compressed representation of all temporal information within the historical window after event gating correction, and serves as the sole input to the prediction head network. The prediction step number is 10, which is the product of the number of nodes in the second fully connected layer (10) and the sensor dimension (d). The output tensor has a shape of 10 rows and d columns. After inverse Z-score standardization, the restoration method for each dimension is as follows: the predicted value of each dimension in the standardized multi-step prediction matrix is multiplied by the standard deviation of that dimension on the training set, and then the mean of that dimension on the training set is added. The standard deviation and mean used are strictly consistent with the training set statistics used in Z-score standardization in step S1, thereby ensuring that the multi-step predicted values and the original physical readings of the sensor are on the same scale.
[0070] The stabilization period threshold is determined by the production cycle of a specific production line, and is set to twice the number of sampling points in the production cycle. The number of sampling points in the production cycle is obtained by dividing the production cycle duration by a fixed sampling period. The physical meaning of the stabilization period threshold is the maximum time span required for the equipment to re-enter a stable operating condition after a mold change or disturbance event. The time interval is the difference between the current time step index and the time step index of the nearest event anchor point, both expressed in units of sampling points, with the difference being an integer. The structured data packet consists of the following fields: a 10-row, d-column multi-step prediction matrix; an event status label with values of one of three: steady-state continuation, reset / reconstruction, or disturbance recovery; the time step index of the nearest event anchor point; and the complete set of event anchor points corresponding to the current time. These four fields together constitute the joint output result.
[0071] The above describes the time-aware industrial data stream prediction method in the embodiments of this application. The following describes the time-aware industrial data stream prediction system in the embodiments of this application. One embodiment of the time-aware industrial data stream prediction system in the embodiments of this application includes:
[0072] The separation module is used to separate the industrial data stream into a numerical track and an event track. The numerical track carries multi-dimensional time-series readings from sensors, and the event track carries an industrial event encoding sequence. The timestamps of the two are aligned to form a dual-track input.
[0073] The identification module is used to identify the event anchor point time and the corresponding event semantic category based on the jump relationship between adjacent time encodings in the event encoding sequence. The event semantic category is divided into state reset category and state disturbance category, forming an event anchor point set.
[0074] The calculation module is used to input the multi-dimensional time-series readings of the sensors in the dual-track input into the numerical encoder to obtain the hidden state sequence; at the anchor time in the event anchor set, a differentiated gating operation is applied to the hidden state sequence according to the event semantic category: the hidden state at the corresponding time of the state reset category is forced to zero, and the hidden state at the corresponding time of the state disturbance category is multiplied by the attenuation coefficient calculated from the duration of the event to obtain the gating corrected hidden state sequence.
[0075] The generation module is used to take the terminal state of the gated modified hidden state sequence as input, decode it through the prediction head network to obtain multi-step prediction values, generate event state labels according to the category of the nearest anchor point to the current time and its time interval in the event anchor point set, and output the multi-step prediction values and the event state labels together.
[0076] This invention also provides a time-aware industrial data flow prediction device, which can be a server. The device includes a processor, memory, display screen, input device, network interface, and database connected via a system bus. The processor, designed as a computer, provides computing and control capabilities. The memory includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The database stores the data corresponding to this embodiment. The network interface communicates with external terminals via a network connection. The computer program, when executed by the processor, implements the above-described method.
[0077] The present invention also provides a computer-readable storage medium, which can be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium, wherein the computer-readable storage medium stores instructions that, when the instructions are executed on a computer, cause the computer to perform the steps of the time-aware industrial data flow prediction method.
[0078] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0079] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, 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. This computer software product is stored in a storage medium and includes several instructions to cause a time-aware industrial data flow prediction device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0080] The above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A time-aware industrial data stream prediction method, characterized in that, The method includes: Step S1: Separate the industrial data stream into a numerical track and an event track. The numerical track carries multi-dimensional time-series readings from sensors, and the event track carries industrial event coding sequences. The timestamps of the two tracks are aligned to form a dual-track input. Step S2: Based on the transition relationship between adjacent time points in the event encoding sequence, identify the event anchor point time and the corresponding event semantic category. The event semantic category is divided into state reset category and state disturbance category, forming an event anchor point set. Step S3: Input the multi-dimensional time-series readings of the sensors in the dual-track input into the numerical encoder to obtain the hidden state sequence; at the anchor point time in the event anchor point set, apply differentiated gating operation to the hidden state sequence according to the event semantic category: the hidden state at the corresponding time of the state reset category is forced to zero, and the hidden state at the corresponding time of the state disturbance category is multiplied by the attenuation coefficient calculated from the duration of the event to obtain the gating corrected hidden state sequence. Step S4: Using the terminal state of the gated modified hidden state sequence as input, the multi-step prediction value is obtained by decoding through the prediction head network. Based on the category of the anchor point closest to the current time and its time interval in the event anchor point set, an event state label is generated. The multi-step prediction value and the event state label are then output together.
2. The industrial data stream prediction method based on time-awareness according to claim 1, characterized in that, Step S1 includes: Each industrial event is extracted from the manufacturing execution system operation log, programmable logic controller alarm record, and process parameter change record. Each industrial event is assigned a unique integer code. The code for normal operation is 0, the codes for mold change event and cold start event are 1 and 2 respectively, the code for brief over-limit alarm event is 3, and the code for manual intervention event is 4. Industrial events coded as 1 and 2 are classified as state reset events, and industrial events coded as 3 and 4 are classified as state disturbance events, thus obtaining the event semantic category of each industrial event. Based on the event semantic category, timestamps of each industrial event are aligned with a fixed sampling period, and 0 is filled in for moments when no event occurs, to obtain the industrial event coding sequence. The multidimensional readings of each sensor in the industrial field at time t are combined into a numerical vector. A historical window of length T is continuously collected with the fixed sampling period. Z-score standardization is performed on each dimension using the training set statistics to obtain a standardized numerical matrix. The standardized numerical matrix is used as the numerical track, and the industrial event coding sequence is used as the event track. The timestamps are strictly aligned according to the fixed sampling period to obtain the dual-track input.
3. The industrial data stream prediction method based on time-awareness according to claim 2, characterized in that, Step S2 includes: The industrial event coding sequence is scanned time by time, and the time when the coding value at time t is non-zero and the coding value at time t-1 is zero is determined as the event anchor time, thus obtaining the event anchor time; Based on the industrial event code at each event anchor point time, the event anchor points with codes belonging to the mold change category and cold start category are marked as state reset category, and the event anchor points with codes belonging to the over-limit alarm category and manual intervention category are marked as state disturbance category, thus obtaining the event semantic category corresponding to each event anchor point time. Each event anchor point moment is paired with its corresponding event semantic category to form a tuple, which is then used to obtain the event anchor point set.
4. The industrial data stream prediction method based on time-awareness according to claim 3, characterized in that, In step S3, the multidimensional time-series readings of the sensors in the dual-track input are input into the numerical encoder to obtain the hidden state sequence, including: The standardized numerical matrix in the dual-track input is input into the dual-layer long short-term memory network step by step according to the time step. The first layer of the dual-layer long short-term memory network has 128 hidden units and the second layer has 64 hidden units. Dropout with a dropout rate of 0.2 is applied between the two layers to obtain the hidden state vector and cell state vector at each time step. The hidden state vectors and the cell state vectors are arranged according to time steps to obtain the hidden state sequence.
5. The industrial data stream prediction method based on time-awareness according to claim 4, characterized in that, In step S3, at the anchor point time in the event anchor point set, a differential gating operation is applied to the hidden state sequence according to the event semantic category, including: Traverse each event anchor moment in the event anchor moment set, and force the hidden state vector and the cell state vector corresponding to the event anchor moment whose event semantic category is state reset to be all zero vectors. The forced assignment operation is performed synchronously on the two layers of the two-layer long short-term memory network to obtain the zero-reset hidden state vector of each reset anchor moment. The hidden state vector and the cell state vector corresponding to the event anchor point time with the event semantic category of state disturbance are multiplied by a decay coefficient. The decay coefficient is calculated from the duration of the industrial event corresponding to the anchor point time. The longer the duration, the smaller the decay coefficient, so as to obtain the decayed hidden state vector of each disturbance anchor point time.
6. The industrial data stream prediction method based on time-awareness according to claim 5, characterized in that, In step S3, the gated modified hidden state sequence is obtained, including: The hidden state vectors at each time point of any event anchor point in the set of event anchor points that have not been triggered remain unchanged, and the zero-reset hidden state vectors at each time point of the reset anchor point and the decayed hidden state vectors at each time point of the disturbance anchor point are replaced with the corresponding positions in the hidden state sequence according to time steps. The replaced hidden state vectors at each time step are rearranged according to the time step to obtain the gated modified hidden state sequence.
7. The industrial data stream prediction method based on time-awareness according to claim 1, characterized in that, Step S4 includes: The terminal hidden state vector of the gated modified hidden state sequence is input into the prediction head network, which is composed of a first fully connected layer and a second fully connected layer connected sequentially. The first fully connected layer has 64 nodes and the activation function is ReLU. The number of nodes in the second fully connected layer is the product of the number of prediction steps and the number of sensor dimensions, thus obtaining a standardized multi-step prediction matrix. The multi-step prediction matrix is standardized by inverse Z-score using training set statistics for each dimension to obtain the multi-step prediction value. Traverse the set of event anchor points, and record the difference between the event anchor point closest to the current time and the current time as the time interval. Compare the time interval with a stable period threshold: if the time interval is greater than the stable period threshold or the set of event anchor points is empty, generate a steady-state continuation label; if the event semantic category of the closest event anchor point is state reset and the time interval is not greater than the stable period threshold, generate a reset reconstruction label; if the event semantic category of the closest event anchor point is state disturbance and the time interval is not greater than the stable period threshold, generate a disturbance recovery label; use one of the steady-state continuation label, the reset reconstruction label, or the disturbance recovery label as the event state label. The multi-step predicted values and the event status labels are encapsulated into a structured data packet to obtain a joint output result.
8. A time-aware industrial data stream prediction system, characterized in that, For implementing the time-aware industrial data flow prediction method as described in any one of claims 1-7, the time-aware industrial data flow prediction system comprises: The separation module is used to separate the industrial data stream into a numerical track and an event track. The numerical track carries multi-dimensional time-series readings from sensors, and the event track carries an industrial event encoding sequence. The timestamps of the two are aligned to form a dual-track input. The identification module is used to identify the event anchor point time and the corresponding event semantic category based on the jump relationship between adjacent time encodings in the event encoding sequence. The event semantic category is divided into state reset category and state disturbance category, forming an event anchor point set. The calculation module is used to input the multi-dimensional time-series readings of the sensors in the dual-track input into the numerical encoder to obtain the hidden state sequence; at the anchor time in the event anchor set, a differentiated gating operation is applied to the hidden state sequence according to the event semantic category: the hidden state at the corresponding time of the state reset category is forced to zero, and the hidden state at the corresponding time of the state disturbance category is multiplied by the attenuation coefficient calculated from the duration of the event to obtain the gating corrected hidden state sequence. The generation module is used to take the terminal state of the gated modified hidden state sequence as input, decode it through the prediction head network to obtain multi-step prediction values, generate event state labels according to the category of the nearest anchor point to the current time and its time interval in the event anchor point set, and output the multi-step prediction values and the event state labels together.
9. A time-aware industrial data stream prediction device, characterized in that, The method includes a memory and a processor, the memory storing a computer program that can run on the processor, and the processor executing the computer program to implement the time-aware industrial data flow prediction method according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is run by the processor, it causes the processor to perform the time-aware industrial data flow prediction method as described in any one of claims 1 to 7.