Abnormality detection method for multivariate time series data

By segmenting wind farm multi-variable time series data and adversarial autoencoding models combined with Gaussian kernel density estimation methods, the problem of failure to fully utilize time information and feature correlation in the existing technology is solved, and higher anomaly detection accuracy is achieved. performance and robustness.

CN118779731APending Publication Date: 2024-10-15ZHEJIANG UNIV +1
View PDF 0 Cites 3 Cited by

Patent Information

Application Number
CN202410685481.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-30
Publication Date
2024-10-15

AI Technical Summary

Technical Problem

Existing anomaly detection methods for multi-variable time series data in wind farms fail to fully consider the correlation between time information and features, resulting in low detection accuracy and low positioning granularity.

Method used

The time series data segmentation module is used to segment the data into equal-length time segments, and the correlation information between time segments and variables is mined through the cross-correlation coding unit, and the adversarial autoencoding module is used to train the generator and discriminator, combined with Gaussian kernel density estimation. The method calculates the outlier determination boundary and implements anomaly detection.

Benefits of technology

It improves the accuracy and interpretability of anomaly detection, has higher robustness and generalization performance in high-noise and complex data, and can more accurately locate and measure abnormal points.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118779731A_ABST
    Figure CN118779731A_ABST
Patent Text Reader

Abstract

The invention belongs to the field of fan fault detection, and discloses an anomaly detection method for multivariate time series data, which comprises the following steps that: step 1, a time series data segmentation module segments the whole time series data into time slices with equal length; 2, mining mutual correlation information between the time slice and the variable by a mutual correlation coding unit; step 3, the adversarial self-coding module trains a generator and a discriminator for anomaly detection; and step 4, an anomaly judgment module calculates a fragment generator error and a fragment discriminator error according to the obtained generator and discriminator to serve as a basis for anomaly judgment, and calculates an abnormal value judgment boundary of the two types of fragment errors, so as to judge whether an abnormal condition exists in each time period or not. According to the method, time dependence and correlation in multivariate time sequence data can be mined. According to the method, the segmentation technology and the cross-correlation coding unit are combined, and the accuracy and interpretability of an anomaly detection algorithm can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of fan fault detection, and in particular to an anomaly detection method for multivariate time series data. Background Art

[0002] There are many wind turbines in wind farms. When unattended, various abnormal situations are prone to occur, resulting in equipment shutdown or failure, causing significant economic losses. The anomaly detection system can provide early warnings, allowing staff to take timely intervention measures, which helps maintain the safe and efficient operation of wind turbines. Wind turbine operation data is multivariate time series data. Currently, there are several anomaly detection methods for multivariate time series data: the first is the traditional method, represented by the isolation forest, which constructs an isolation tree through classification conditions. Sample points with shorter path lengths are considered to be abnormal points. This type of method does not consider the time information in the data, and the accuracy of anomaly detection in time series data is low; the second is the method based on the autoencoder, which reconstructs the input data through the autoencoder. If the sample reconstruction error is large, the sample is considered to be an abnormal sample; the third is the deep autoencoder Gaussian mixture model, which is an extension of the second method. Both methods do not consider time information and cannot fully measure the correlation between features. Therefore, an anomaly detection method that can fully mine the time information of time series data, the dependency between features, and the correlation between time series segments is needed to improve the accuracy of the anomaly detection method and the positioning granularity and accuracy. Summary of the invention

[0003] The purpose of the present invention is to provide an anomaly detection method for multivariate time series data to solve the problems raised in the above background technology.

[0004] To achieve the above object, the present invention provides the following technical solutions:

[0005] A method for detecting anomalies in multivariate time series data comprises the following steps:

[0006] Step 1: The time series data segmentation module segments the entire time series data into time segments of equal length, so that when determining abnormal events, a certain time period can be located;

[0007] Step 2, the cross-correlation coding unit mines the correlation information between time segments and variables;

[0008] Step 3: Train the generator and discriminator against the autoencoder module for anomaly detection;

[0009] In step 4, the anomaly judgment module calculates the segment generator error and the segment discriminator error based on the generator and discriminator obtained in step 3 as the basis for anomaly judgment, and calculates the anomaly value judgment boundary of the two types of segment errors to determine whether there are anomalies in each time period.

[0010] Furthermore, in the time series data segmentation module, assuming that the size of the original input time series X is (T, V), T is the total time length, V is the variable dimension, and the i-th segment is represented as L is the length of each time period, and s is the interval between each adjacent time period.

[0011] Furthermore, the step 2 comprises:

[0012] The time series data processed by the time series data segmentation module is represented as X s , the size is (Seg,L,V), where Seg is the number of time segments. The cross-correlation coding unit first fuses the multivariate information in dimension V. The specific implementation is to s Perform average pooling in the Seg dimension to get X seg , X seg The size of is (L, V), and then by Calculate the attention weight matrix α of each variable f ,Softmax is an activation function, W f The size of is (L,L), which is the learnable attention coefficient, and the final fusion result X f For X s and α f The weighted sum of

[0013] In the piecewise cross-correlation evaluation, each variable is considered as an independent input and the final result is calculated. First, the attention matrix of each variable is calculated. The calculation formula is The subscript v indicates the vth variable, W seg is the learnable attention coefficient, and the final cross-correlation evaluation result is expressed as By X f and The weighted sum of passes through a fully connected layer and then is activated using the ReLU activation function.

[0014] Furthermore, the step 3 comprises:

[0015] The adversarial autoencoder module includes two training processes: reconstruction training and adversarial training. The goal of reconstruction training is to obtain the first autoencoder, also known as the generator AE. g , the adversarial training goal is to obtain the second autoencoder, also known as the discriminator AE d;

[0016] During the reconstruction training process, the training objectives of the first autoencoder and the second autoencoder are to accurately transform the original input data X s After processing, the original input data is reconstructed. The input data is compressed by the encoder network and then reconstructed by the decoder network to minimize the error between the original input and the reconstructed output of each autoencoder.

[0017] During adversarial training, the training goal of the first autoencoder is to generate reconstructed data AE that the second autoencoder can mistakenly identify as the original input data. g (X s ), and the training goal of the second autoencoder is to correctly distinguish the original input data AE processed by the first autoencoder g (X s ) and the original input data X without any processing s ;

[0018] Finally, the loss function of the first autoencoder and the second autoencoder is obtained by the weighted sum of the loss functions of the two training processes, reconstruction training and adversarial training. The weight is determined by the current training round n and the damping factor λ that controls the different proportions between the reconstruction and adversarial training losses.

[0019] Furthermore, the loss function in the reconstruction training is expressed as:

[0020] and

[0021] in, Represents the generator AE during reconstruction training g The loss function is Represents the discriminator AE in reconstruction training d The loss function of AE g (·) indicates the generator AE g The processed result, AE d (·) indicates the discriminator AE d The result after processing.

[0022] Furthermore, the loss function in the adversarial training is expressed as:

[0023] and

[0024] in, Represents the generator AE in adversarial training g The loss function is Represents the discriminator AE in adversarial training d The loss function of AEg (·) indicates the generator AE g The processed result, AE d (·) indicates the discriminator AE d The result after processing.

[0025] Furthermore, the loss function of the first autoencoder is expressed as:

[0026]

[0027] Where e represents a natural constant;

[0028] The loss function of the second autoencoder is expressed as:

[0029]

[0030] Furthermore, the step 4 comprises:

[0031] Step 3: Get the trained generator AE g and the discriminator AE d , for each time segment, use the generator AE obtained in step 3 g and the discriminator AE d After calculation, two types of fragment errors are obtained: fragment generator error and the fragment discriminator error and Represents the time series data of the seg segment, AEg(X s ) seg The time series data representing the segment seg is generated by the generator AE g The processed result, AE d (·) indicates the discriminator AE d The processed result is obtained using the Gaussian kernel density estimation method and The joint distribution of and The values ​​are and Time, point The kernel density at can be expressed as in f(·) represents the function for calculating kernel density, N is the number of segments after the time series data is segmented, h is the bandwidth parameter that controls the width of the kernel function, exp(·) represents exponential operation, Represents the i-th segment value, Represents the i-th segment value, Express and Traverse the range to [1, N] and calculate e d and e g The upper and lower thresholds are:

[0032]

[0033]

[0034]

[0035]

[0036] Among them, α represents the significance index, express The upper threshold of express The lower threshold of express The upper threshold of express The lower threshold of

[0037] When the error pair for a given time segment If the value exceeds any of the four upper and lower limits, the data points in this time segment are considered outliers.

[0038] Compared with the prior art, the present invention has the following beneficial effects:

[0039] 1) This paper proposes a segmentation-based adversarial denoising autoencoder model, which combines the advantages of autoencoders and adversarial training, and can mine the temporal dependencies and correlations in multivariate time series data. It combines segmentation technology and cross-correlation coding units to improve the accuracy and interpretability of anomaly detection algorithms;

[0040] 2) The present invention fully measures the correlation between different features in the data, so that the model can have a higher anomaly detection accuracy in complex data sets with high noise levels and correlated features, strong robustness to noisy data, and better generalization performance;

[0041] 3) The present invention proposes a kernel density estimation method to estimate the joint distribution of reconstruction errors, so that abnormal points can be judged according to upper and lower thresholds and the degree of abnormality can be measured. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] Figure 1 It is a flow chart of the present invention.

[0043] Figure 2 It is a schematic diagram of the structure of the time series data segmentation module in the present invention.

[0044] Figure 3 It is a schematic diagram of the structure of the mutual correlation coding unit in the present invention.

[0045] Figure 4 It is a schematic diagram of the structure of the anti-autoencoding module in the present invention. DETAILED DESCRIPTION

[0046] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0047] See also Figure 1-Figure 4 , an anomaly detection method for multivariate time series data, comprising the following steps:

[0048] Step 1: The time series data segmentation module segments the entire time series data into time segments of equal length, so that a certain time period can be located when determining an abnormal event.

[0049] like Figure 2 As shown, in the time series data segmentation module, assume that the size of the original input time series X is (T, V), T is the total time length, V is the variable dimension, and the i-th segment is represented as L is the length of each time period, and s is the interval between each adjacent time period.

[0050] Step 2, such as Figure 3 As shown in Figure 2, the cross-correlation coding unit mines the correlation information between time segments and variables, including:

[0051] The time series data processed by the time series data segmentation module is represented as X s , the size is (Seg,L,V), where Seg is the number of time segments. The cross-correlation coding unit first fuses the multivariate information in dimension V. The specific implementation is to s Perform average pooling in the Seg dimension to obtain X seg , X seg The size of is (L, V), and then by Calculate the attention weight matrix α of each variable f ,Softmax is an activation function, W The size of f is (L, L), which is the learnable attention coefficient, and the final fusion result X f For X s and α fThe weighted sum of

[0052] In the piecewise cross-correlation evaluation, each variable is considered as an independent input and the final result is calculated. First, the attention matrix of each variable is calculated. The calculation formula is The subscript v indicates the vth variable, W seg is the learnable attention coefficient, and the final cross-correlation evaluation result is expressed as By X f and The weighted sum of passes through a fully connected layer and then is activated using the ReLU activation function.

[0053] Step 3, such as Figure 4 As shown in the figure, the adversarial self-encoder module trains the generator and discriminator for anomaly detection, including:

[0054] The adversarial autoencoder module includes two training processes: reconstruction training and adversarial training. The goal of reconstruction training is to obtain the first autoencoder, also known as the generator AE. g , the adversarial training goal is to obtain the second autoencoder, also known as the discriminator AE d ;

[0055] During the reconstruction training process, the training objectives of the first autoencoder and the second autoencoder are to accurately transform the original input data X s After processing, the original input data is reconstructed. The input data is compressed by the encoder network and then reconstructed by the decoder network to minimize the error between the original input and the reconstructed output of each autoencoder.

[0056] During adversarial training, the training goal of the first autoencoder is to generate reconstructed data AE that the second autoencoder can mistakenly identify as the original input data. g (X s ), and the training goal of the second autoencoder is to correctly distinguish the original input data AE processed by the first autoencoder g (X s ) and the original input data X without any processing s ;

[0057] Finally, the loss function of the first autoencoder and the second autoencoder is obtained by the weighted sum of the loss functions of the two training processes, reconstruction training and adversarial training. The weight is determined by the current training round n and the damping factor λ that controls the different proportions between the reconstruction and adversarial training losses.

[0058] The loss function in reconstruction training is expressed as:

[0059] and

[0060] In the formula, Represents the generator AE during reconstruction training g The loss function is Represents the discriminator AE in reconstruction training d The loss function of AE g (·) indicates the generator AE g The processed result, AE d (·) indicates the discriminator AE d The result after processing.

[0061] The loss function in adversarial training is expressed as:

[0062] and

[0063] In the formula, Represents the generator AE in adversarial training g The loss function is Represents the discriminator AE in adversarial training d The loss function of AE g (·) indicates the generator AE g The processed result, AE d (·) indicates the discriminator AE d The result after processing.

[0064] The loss function of the first autoencoder is expressed as:

[0065]

[0066] Where e represents a natural constant;

[0067] The loss function of the second autoencoder is expressed as:

[0068]

[0069] Step 4: The abnormality determination module calculates the segment generator error and the segment discriminator error based on the generator and discriminator obtained in step 3 as the basis for abnormality determination, and calculates the abnormal value determination boundary of the two types of segment errors, so as to determine whether there is an abnormal situation in each time period, specifically including:

[0070] Step 3: Get the trained generator AE g and the discriminator AE d , for each time segment, use the generator AE obtained in step 3 g and the discriminator AE d After calculation, two types of fragment errors are obtained: fragment generator error and the fragment discriminator error and Indicates the time series data of the seg segment, AE g (X s ) seg The time series data representing the segment seg is generated by the generator AE g The processed result, AE d (·) indicates the discriminator AE d The processed result is obtained using the Gaussian kernel density estimation method and The joint distribution of and The values ​​are and Time, point The kernel density at can be expressed as in f(·) represents the function for calculating kernel density, N is the number of segments after the time series data is segmented, h is the bandwidth parameter that controls the width of the kernel function, exp(·) represents exponential operation, Represents the i-th segment value, Represents the i-th segment value, Express and Traverse the range to [1, N] and calculate e d and e g The upper and lower thresholds:

[0071]

[0072]

[0073]

[0074]

[0075] Among them, α represents the significance index, express The upper threshold of express The lower threshold of express The upper threshold of express The lower threshold of

[0076] When the error pair for a given time segment If the value exceeds any of the four upper and lower limits, the data points in this time segment are considered outliers.

[0077] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. An anomaly detection method for multivariate time series data, It is characterized in that The steps include: Step 1: The time series data segmentation module segments the entire time series data into time segments of equal length, so that when determining abnormal events, a certain time period can be located; Step 2, the cross-correlation coding unit mines the correlation information between time segments and variables; Step 3: Train the generator and discriminator against the autoencoder module for anomaly detection; In step 4, the anomaly judgment module calculates the segment generator error and the segment discriminator error based on the generator and discriminator obtained in step 3 as the basis for anomaly judgment, and calculates the anomaly value judgment boundary of the two types of segment errors to determine whether there are anomalies in each time period.

2. The method for detecting anomalies in multivariate time series data according to claim 1, It is characterized in that In the time series data segmentation module, assume that the size of the original input time series X is (T, V), T is the total time length, V is the variable dimension, and the i-th segment is represented as L is the length of each time period, and s is the interval between each adjacent time period.

3. The method for detecting anomalies in multivariate time series data according to claim 1, It is characterized in that The step 2 comprises: The time series data processed by the time series data segmentation module is represented as X s , the size is (Seg,L,V), where Seg is the number of time segments. The cross-correlation coding unit first fuses the multivariate information in dimension V. The specific implementation is to s Perform average pooling in the Seg dimension to obtain X seg , X seg The size of is (L, V), and then by Calculate the attention weight matrix α of each variable f ,Softmax is an activation function, W f The size of is (L,L), which is the learnable attention coefficient, and the final fusion result X f For X s and α f The weighted sum of In the piecewise cross-correlation evaluation, each variable is considered as an independent input and the final result is calculated. First, the attention matrix of each variable is calculated. The calculation formula is The subscript v indicates the vth variable, W seg is the learnable attention coefficient, and the final cross-correlation evaluation result is expressed as By X f and The weighted sum of passes through a fully connected layer and then is activated using the ReLU activation function.

4. The method for detecting anomalies in multivariate time series data according to claim 1, It is characterized in that The step 3 comprises: The adversarial autoencoder module includes two training processes: reconstruction training and adversarial training. The goal of reconstruction training is to obtain the first autoencoder, also known as the generator AE. g , the adversarial training goal is to obtain the second autoencoder, also known as the discriminator AE d ; During the reconstruction training process, the training objectives of the first autoencoder and the second autoencoder are to accurately transform the original input data X s After processing, the original input data is reconstructed. The input data is compressed by the encoder network and then reconstructed by the decoder network to minimize the error between the original input and the reconstructed output of each autoencoder. During adversarial training, the training goal of the first autoencoder is to generate reconstructed data AE that the second autoencoder can mistakenly identify as the original input data. g (X s ), and the training goal of the second autoencoder is to correctly distinguish the original input data AE processed by the first autoencoder g (X s ) and the original input data X without any processing s ; Finally, the loss function of the first autoencoder and the second autoencoder is obtained by the weighted sum of the loss functions of the two training processes, reconstruction training and adversarial training. The weight is determined by the current training round n and the damping factor λ that controls the different proportions between the reconstruction and adversarial training losses.

5. The method for detecting anomalies in multivariate time series data according to claim 4, It is characterized in that The loss function in the reconstruction training is expressed as: and in, Represents the generator AE during reconstruction training g The loss function is Represents the discriminator AE in reconstruction training d The loss function of AE g (·) indicates the generator AE g The processed result, AE d (·) indicates the discriminator AE d The result after processing.

6. The method for detecting anomalies in multivariate time series data according to claim 4, It is characterized in that The loss function in the adversarial training is expressed as: and in, Represents the generator AE in adversarial training g The loss function is Represents the discriminator AE in adversarial training d The loss function of AE g (·) indicates the generator AE g The processed result, AE d (·) indicates the discriminator AE d The result after processing.

7. The method for detecting anomalies in multivariate time series data according to claim 4, It is characterized in that The loss function of the first autoencoder is expressed as: Where e represents a natural constant; The loss function of the second autoencoder is expressed as:

8. The method for detecting anomalies in multivariate time series data according to claim 1, It is characterized in that The step 4 comprises: Step 3: Get the trained generator AE g and the discriminator AE d , for each time segment, use the generator AE obtained in step 3 g and the discriminator AE d After calculation, two types of fragment errors are obtained: fragment generator error and the fragment discriminator error and Represents the time series data of the seg segment, AE g (X s ) seg The time series data representing the segment seg is generated by the generator AE g The processed result, AE d (·) indicates the discriminator AE d The processed result is obtained using the Gaussian kernel density estimation method and The joint distribution of and The values ​​are and Time, point The kernel density at can be expressed as in f(·) represents the function for calculating kernel density, N is the number of segments after the time series data is segmented, h is the bandwidth parameter that controls the width of the kernel function, exp(·) represents exponential operation, Represents the i-th segment value, Represents the i-th segment value, Express and Traverse the range to [1, N] and calculate e d and e g The upper and lower thresholds are: Among them, α represents the significance index, express The upper threshold of express The lower threshold of express The upper threshold of express The lower threshold of When the error pair for a given time segment If the value exceeds any of the four upper and lower limits, the data points in this time segment are considered outliers.

Citation Information

Cited By

  • One-dimensional time sequence signal anomaly detection method and system

    CN119884919A

  • IDC machine room operation and maintenance visual monitoring method and system

    CN120578563A

  • IDC machine room operation and maintenance visual monitoring method and system

    CN120578563B