Method and device for abnormality detection and parameter filling of time series data
The adversarial generative interpolation network effectively addresses the challenges of joint anomaly detection and missing value filling in time series data by using spatial and temporal constraints, improving accuracy and robustness in MR key parameter processing.
Patent Information
- Application Number
- CN202110128210.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-01-29
- Publication Date
- 2024-12-03
- Estimated Expiration
- 2041-01-29
AI Technical Summary
Existing methods for anomaly detection and missing value filling in time series data, such as MR key parameters, fail to jointly process outliers and missing values, cannot adapt to inconsistent spatiotemporal distributions, and are ineffective for non-stationary, incomplete data.
A method and device using an adversarial generative interpolation network with a generator and discriminator, trained on preprocessed time series data with marked abnormal and missing parameters, and regional labels, to jointly detect anomalies and fill missing values, considering spatial and temporal constraints.
Accurately determines specific abnormal positions and fills missing values in multivariate time series data, improving model training difficulty, accuracy, and robustness, enhancing MR positioning accuracy and prediction.
Smart Images

Figure CN114826988B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure generally relates to the field of artificial intelligence, and more specifically to a method and device for anomaly detection and parameter filling of time series data. Background Art
[0002] In the prior art, parameters such as TA (Time Advanced) and RSRP (Reference Signal Receiving Power) of MR (Measurement Report) data are very critical in applications such as network positioning. Since MR data is easily affected by factors such as equipment and environment during the reporting process, there are often many abnormal values and missing values, which seriously affect the effect of applications that rely on MR data. Therefore, it is necessary to achieve accurate and robust abnormal detection and missing filling of MR key parameters.
[0003] Because users report MR continuously at a fixed time, when processing abnormal values and missing values in MR data, we can consider using the spatiotemporal continuity relationship of user-reported data to construct time series data and perform further processing.
[0004] At present, in the anomaly detection and missing filling methods for time series data, due to the time series memory ability of LSTM (Long Short Term Memory) and the adversarial learning mechanism of GAN (Generative Adversarial Networks), the combination of the two methods has a natural advantage. In the prior art, this type of method is often performed independently when performing anomaly detection and missing filling: for missing filling, the missing values of the time series are first filled with preset values, and then the time series filled with preset values and the corresponding missing mask sequence are input into the generator to predict the missing values; for anomaly detection, random noise is first input into the generator to generate abnormal samples, and the discriminator is trained to distinguish between real samples and generated samples as much as possible. Then, when detecting anomalies, the time series features extracted by the hidden layer of the discriminator are first input into the generator for reconstruction to obtain the reconstruction error, and the discrimination error output by the discriminator is combined to obtain the final abnormal score of the entire time series.
[0005] There are some problems when using existing timing anomaly detection and missing filling methods to process MR key parameter timing:
[0006] 1) When there are missing values and outliers in the data, ignoring the outliers and filling the missing values will introduce noise, while truncating the time series from the missing parts and performing outlier detection separately will lose the time series structure information. The current method does not combine the two for joint processing;
[0007] 2) Different MR parameters are affected by many uncertain factors, the spatial and temporal distribution of data is inconsistent, and potential anomalies appear completely randomly. Current methods cannot be adjusted by region, and cannot accurately determine the specific location of temporal anomalies;
[0008] 3) The MR time series continuously reported by users are of uncertain length, non-stationary, and mostly incomplete, and the current method cannot process them adaptively.
[0009] At present, the existing network MR data is rich. According to the session ID, base station ID, cell ID, timestamp, etc. reported by MR, the MR time series continuously reported by different users can be effectively identified, and then converted into processing of indefinite-length multivariate time series data of each user, laying the foundation for joint MR key parameter anomaly detection and missing filling based on the data's spatiotemporal distribution and time series structure information. Summary of the invention
[0010] A brief overview of the disclosure is given below in order to provide a basic understanding of some aspects of the disclosure. However, it should be understood that this overview is not an exhaustive overview of the disclosure. It is not intended to identify the key or important parts of the disclosure, nor is it intended to limit the scope of the disclosure. Its purpose is simply to give some concepts of the disclosure in a simplified form as a prelude to a more detailed description given later.
[0011] According to a first aspect of the present disclosure, there is provided a method for training a model for anomaly detection and missing filling of time series data, comprising: obtaining time series data of a user, wherein the time series data includes abnormal parameters and missing parameters; preprocessing the time series data to obtain preprocessed time series data, a first marking matrix, a second marking matrix, and region labels, wherein the first marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the time series data, the second marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the preprocessed time series data, and the region labels are configured to mark the region where the user is located; and training the model based on the preprocessed time series data, the first marking matrix, the second marking matrix, and the region labels.
[0012] According to a second aspect of the present disclosure, a method for anomaly detection and missing filling of time series data is provided, comprising: training a model using the method described in the first aspect; generating a probability that a parameter in the time series data to be detected is an abnormal parameter using the trained model; judging whether the parameter in the time series data to be detected is an abnormal parameter based on the probability and the probability threshold; and filling the parameters judged to be abnormal and the missing parameters in the time series data to be detected with normal values generated using the trained model.
[0013] According to a third aspect of the present disclosure, there is provided a device for training a model for anomaly detection and missing filling of time series data, comprising: a construction module, configured to obtain time series data of a user, wherein the time series data includes abnormal parameters and missing parameters; a preprocessing module, configured to preprocess the time series data to obtain preprocessed time series data, a first marking matrix, a second marking matrix and region labels, wherein the first marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the time series data, the second marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the preprocessed time series data, and the region labels are configured to mark the region where the user is located; a training module, configured to train the model based on the preprocessed time series data, the first marking matrix, the second marking matrix and the region labels.
[0014] According to a fourth aspect of the present disclosure, a device for anomaly detection and missing filling of time series data is provided, comprising: a construction module, a preprocessing module and a training module according to the third aspect; and a detection and filling module, wherein the detection and filling module is configured to: generate a probability that a parameter in the time series data to be detected is an abnormal parameter using a trained model; determine whether the parameter in the time series data to be detected is an abnormal parameter based on a probability and a probability threshold; and fill the determined abnormal parameters and missing parameters in the time series data to be detected with normal values generated using the trained model.
[0015] According to a fifth aspect of the present disclosure, there is provided a non-transitory computer-readable storage medium having a program stored thereon, wherein when the program is executed by a computer, the computer is caused to execute the method according to the first aspect.
[0016] According to a sixth aspect of the present disclosure, there is provided a non-transitory computer-readable storage medium having a program stored thereon, wherein when the program is executed by a computer, the computer is caused to execute the method according to the second aspect.
[0017] According to a seventh aspect of the present disclosure, there is provided a device for training a model for anomaly detection and gap filling for time series data, comprising a memory and a processor, wherein the memory is communicatively coupled to the processor, and a program is stored in the memory, and when the program is executed by the processor, the processor executes the method described in the first aspect.
[0018] According to an eighth aspect of the present disclosure, there is provided an apparatus for anomaly detection and missing filling of time series data, comprising a memory and a processor, wherein the memory is communicatively coupled to the processor, wherein a program is stored in the memory, and when the program is executed by the processor, the processor executes the method described in the second aspect.
[0019] According to a ninth aspect of the present disclosure, a computer program product is provided, comprising a computer program, which implements the method described in the first aspect when executed by a processor.
[0020] According to a tenth aspect of the present disclosure, a computer program product is provided, comprising a computer program, which implements the method according to the second aspect when executed by a processor.
[0021] The method and device proposed in the present invention can realize the joint anomaly detection and missing filling of multivariate time series data, accurately determine the specific abnormal position of the time series data, adapt to variable-length input, introduce spatial condition constraints to improve the problem of inconsistent spatiotemporal distribution of time series, and there is no need to obtain normal and complete time series samples for training, which effectively improves the model training difficulty, accuracy, robustness and granularity of MR key parameters such as time series anomaly detection and missing filling, thereby realizing data quality optimization and providing strong support for application scenarios including the simultaneous improvement of MR positioning accuracy and prediction ratio.
[0022] Other features and advantages of the present disclosure will become more apparent from the following detailed description of exemplary embodiments of the present disclosure with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] The accompanying drawings, which constitute a part of the specification, illustrate embodiments of the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0024] The present disclosure may be more clearly understood from the following detailed description with reference to the accompanying drawings, in which:
[0025] Figure 1 A schematic diagram of a system for anomaly detection and missing filling of time series data according to an embodiment of the present disclosure is shown;
[0026] Figure 2 A flowchart of a method for training a model for anomaly detection and missing fill in time series data according to an embodiment of the present disclosure is shown;
[0027] Figure 3 A schematic diagram showing a method for anomaly detection and missing filling of time series data according to an embodiment of the present disclosure is shown;
[0028] Figure 4 A schematic diagram of training a model for abnormality detection and missing filling of MR key parameters according to an embodiment of the present disclosure is shown;
[0029] Figure 5 A schematic diagram of the generator and discriminator network structure according to an embodiment of the present disclosure is shown;
[0030] Figure 6An exemplary configuration of a computing device that can implement an embodiment according to the present disclosure is shown. DETAILED DESCRIPTION
[0031] The following detailed description is made with reference to the accompanying drawings, and the following detailed description is provided to assist in a comprehensive understanding of the various exemplary embodiments of the present disclosure. The following description includes various details to assist in understanding, but these details are considered to be examples only and not to limit the present disclosure, which is defined by the appended claims and their equivalents. The words and phrases used in the following description are only used to enable a clear and consistent understanding of the present disclosure. In addition, for the sake of clarity and brevity, descriptions of well-known structures, functions, and configurations may be omitted. Those of ordinary skill in the art will recognize that various changes and modifications may be made to the examples described herein without departing from the spirit and scope of the present disclosure.
[0032] Figure 1 A schematic diagram of a system 100 for anomaly detection and gap filling of time series data according to an embodiment of the present disclosure is shown.
[0033] like Figure 1 As shown, the system 100 may include a construction module 101 , a preprocessing module 102 , and a training module 103 .
[0034] Figure 2 A flowchart of a method for training a model for anomaly detection and gap filling for time series data according to an embodiment of the present disclosure is shown.
[0035] Specifically, if Figure 2 As shown, at S201, the user's time series data can be obtained; at S202, the time series data can be preprocessed to obtain preprocessed time series data, a first labeling matrix, a second labeling matrix and region labels; at S203, the model can be trained based on the preprocessed time series data, the first labeling matrix, the second labeling matrix and the region labels.
[0036] The construction module 101 may be configured to obtain time series data of a user, wherein the time series data includes abnormal parameters and missing parameters.
[0037] For MR data, the indefinite length time series of each user's MR key parameters and the missing position marker matrix can be obtained according to the session ID, base station ID, and timestamp. Specifically, obtaining the user's time series data may include the following steps:
[0038] 1) The collected MR data are grouped according to the primary cell base station ID and the cell ID, and the number of occurrences of each group of neighboring cell FCN (Frequency Channel Number, wireless channel signal) number + PCI (Physical Cell Identifier, physical cell identifier) number is counted, and the first N neighboring cell FCN + PCI numbers with the highest number of occurrences are taken in descending order, where N is set according to the actual situation, for example, N = 15 can be taken, and it should be understood that the value of N is not limited thereto;
[0039] 2) Rearrange the N neighboring cell RSRPs of each original MR data according to the corresponding primary cell base station ID, cell ID, and the index of the top N neighboring cell FCN+PCI numbers according to the number of occurrences, and obtain [base station ID, cell ID, MME (Mobile Management Entity) code, user S1AP (S1-Application Protocol) identifier, MMEPOOL number, primary cell TA, primary cell RSRP, RSRP corresponding to the top 1 to top N neighboring cell FCN+PCIs in terms of number of occurrences, abnormal data flag];
[0040] 3) Grouping the MR data with rearranged fields according to MME code, user S1AP identifier, MMEPOOL number, and base station ID;
[0041] 4) For each group of MR data, sort by timestamp; in the embodiment according to the present disclosure, the continuous MR data with a time difference of less than or equal to 1 minute or a time difference of more than 1 minute but within 5 minutes of the first time stamp can be identified as the MR time sequence continuously reported by the same user;
[0042] 5) Extract the key parameter timing of [primary cell TA, primary cell RSRP, neighboring cell RSRP] from the MR timing of each user, and construct a missing mark matrix 302 indicating whether the corresponding position is missing, and fill the missing position with 0 and the value position with 1.
[0043] The preprocessing module 102 may be configured to preprocess the time series data to obtain preprocessed time series data 301, a first label matrix 302, a second label matrix 304, and a region label 303 (eg, Figure 3 As shown). The first marking matrix 302 may be configured to mark the positions of abnormal parameters and missing parameters in the time series data, the second marking matrix 304 may be configured to mark the positions of abnormal parameters and missing parameters in the preprocessed time series data, and the area label 303 may be configured to mark the area where the user is located.
[0044] Preprocessing the time series data may include: grouping the time series data according to the area where the user is located; estimating the missing parameters in the time series data within the group using a discriminant interpolation method, and filling the estimated parameters into the positions of the corresponding missing parameters; and identifying abnormal parameters in the preprocessed time series data.
[0045] Specifically, the preprocessing may include the following steps:
[0046] 1) Rearrange the MR data with fields and group them by base station ID + cell ID. For each group of MR data [MME code, user S1AP identifier, MMEPOOL number, primary cell TA, primary cell RSRP, RSRP corresponding to the top 1 to top N neighboring cells FCN + PCI, abnormal data flag], use the MICE interpolation method based on LightGBM to estimate the missing values. At the same time, for each group of TA and several RSRPs, use the 3σ method to identify the abnormal values in each column.
[0047] 2) Fill the missing TA and RSRP values estimated by regional grouping into the missing positions of TA and RSRP of the corresponding timestamp of the corresponding user; in the embodiment according to the present disclosure, the maximum and minimum values of each column feature can be recorded, and the maximum and minimum normalization of each column feature can be performed to obtain the preprocessed time series data 301;
[0048] 3) Based on the TA and several RSRP outlier positions identified by regional grouping, for each user's MR key parameter timing, an abnormal marking matrix is constructed to indicate whether the corresponding position is abnormal, with 0 filled in the abnormal position and 1 in other positions;
[0049] 4) According to the MR key parameter time series of each user, the corresponding first labeling matrix 302 and second labeling matrix 304 are constructed; the first labeling matrix 302 has a value of 0 or 1, wherein the missing and abnormal value positions are filled with 0, and the normal position is filled with 1; the second labeling matrix 304 identifies the abnormal value positions of the time series after preprocessing and the missing values and normal value positions of some values, and its value is 0, 0.5 or 1, the abnormal position is marked as 0, the missing position is marked as 0 or 0.5, and the normal position is marked as 1 or 0.5, wherein the position marked with 0.5 is randomly selected according to a certain probability;
[0050] 5) Constructing model input samples, each sample includes a normalized MR key parameter time series 301 filled with estimated missing values, a first label matrix 302 and a second label matrix 304, and a region label 303, wherein the region label 303 can be a base station ID+cell ID.
[0051] The training module 103 may be configured to train the model based on the preprocessed time series data 301 , the first label matrix 302 , the second label matrix 304 , and the region labels 303 .
[0052] In an embodiment according to the present disclosure, the model may be an adversarial generative interpolation network. Figure 3 , the model may include a generator 305 and a discriminator 307.
[0053] The generator 305 may be configured to input the preprocessed time series data 301 , the first labeling matrix 302 , and the region labels 303 and output a first numerical matrix 306 including normal values for filling abnormal parameters and missing parameters.
[0054] The discriminator 307 can be configured to input the time series data, the second label matrix 304 and the region label 303 and output a probability matrix 308, which includes the probability that the parameters in the time series data are abnormal parameters. When training, the input time series data can be a matrix filled with normal values output by the generator.
[0055] Figure 4 A schematic diagram of training a model for abnormality detection and missing fill of MR key parameters according to an embodiment of the present disclosure is shown.
[0056] like Figure 4 As shown, for MR time series data Y, when training the model, the preprocessed time series data can be The first label matrix M and the region label C are input to the generator G; the padding matrix is generated using the output of the generator Will fill the matrix The region labels C and the second label matrix H are input into the discriminator D; and the probability matrix P is generated using the discriminator D.
[0057] Figure 5 A schematic diagram of the generator and discriminator network structure according to an embodiment of the present disclosure is shown in more detail.
[0058] refer to Figure 4 and Figure 5 Specifically, model construction and training may include the following steps:
[0059] 1) Construct the adversarial generative interpolation network generator as a multi-input multi-output model, such as Figure 5 As shown, the dotted arrows represent the data flow that distinguishes the generator from the discriminator:
[0060] a. First, the MR key parameter time series with the same size of (number of samples, time step, key parameter dimension) filled with estimated missing values and the corresponding first label matrix are input into the Concatenate layer and concatenated into a tensor of size (number of samples, time step, feature dimension * 2);
[0061] b. Then input it to the BiLSTM and Attention layers in turn to extract the temporal hidden layer feature tensor with the same time step and size of (number of samples, time step, BiLSTM hidden layer dimension * 2);
[0062] c. At the same time, the corresponding region label is input into the RepeatVector layer, and t copies are made in advance according to t time steps of the corresponding time series to obtain a region label input tensor of size (number of samples, time steps, label dimension);
[0063] d. Input the temporal hidden layer feature tensor and the region label input tensor together into the Concatenate layer, and concatenate them again into a tensor of size (number of samples, time step, BiLSTM hidden layer dimension*2+label dimension) representing the conditional temporal hidden layer features;
[0064] e. Finally, the hidden layer feature tensor representing the conditional time series is input into the TimeDistributed (Dense) layer to generate the fully connected results for each time step feature, and the output data tensor of size (number of samples, time step, key parameter dimension) corresponds one-to-one to the input variable-length multivariate time series;
[0065] f. In addition, the time series hidden layer feature tensor extracted in the middle of the model without considering the conditional constraints is directly connected to the Dense layer, and the output is a tensor that corresponds one-to-one with the input multivariate time series of indefinite length;
[0066] 2) Construct the adversarial generative interpolation network discriminator as a multi-input multi-output model, such as Figure 5 As shown, the triangular arrows represent the data flow that distinguishes the discriminator from the generator:
[0067] a. First, the MR key parameter time series to be detected with the same size of (number of samples, time step, key parameter dimension) and the corresponding second label matrix are input into the Concatenate layer and concatenated into a tensor with the size of (number of samples, time step, feature dimension * 2);
[0068] b. Then input it into the BiLSTM and Attention layers in turn to extract the temporal hidden layer feature tensor with the same time step and the size of (number of samples, time step, BiLSTM hidden layer dimension * 2);
[0069] c. At the same time, the corresponding region label is input into the RepeatVector layer, and t copies are made in advance according to t time steps of the corresponding time series to obtain a region label input tensor of size (number of samples, time steps, label dimension);
[0070] d. Input the temporal hidden layer feature tensor and the region label input tensor together into the Concatenate layer, and concatenate them again into a tensor of size (number of samples, time step, BiLSTM hidden layer dimension*2+label dimension) representing the conditional temporal hidden layer features;
[0071] e. Finally, the hidden layer feature tensor representing the conditional time series is input into the TimeDistributed (Dense) layer with Sigmoid as the activation function to generate the fully connected results for each time step feature, and the output size is (number of samples, time step, key parameter dimension) probability tensor, which corresponds one-to-one to the input variable-length multivariate time series;
[0072] 3) Based on sample data, the generator and discriminator models are trained adversarially, where:
[0073] a. Generator G inputs the time series of missing value filling estimates according to the above construction The first labeling matrix M∈{0,1} t×d , and the regional label C, respectively output the following auxiliary results Aux_output without considering the conditions, and the main results Main_output (i.e., the first numerical matrix) considering the conditions:
[0074]
[0075]
[0076] Among them, t is the time step, d is the parameter dimension;
[0077] b. Replace the abnormal values (e.g., missing values, outliers) in the input time series with the values of the corresponding positions of the main results generated by the generator to obtain:
[0078]
[0079] c. The discriminator D inputs the time sequence of replacing abnormal values with values generated by the generator according to the above structure. The corresponding second label matrix H∈{0,0.5,1} t×d , and the region label C, output the normal probability matrix P of the values at each position under the considered conditions, where:
[0080]
[0081] 4) The generator and the discriminator update their parameters alternately every certain number of iterations:
[0082] a. The discriminator calculates the following discriminator classification cross entropy loss based on the output probability matrix P and the first label matrix M, and calculates the gradient update parameters:
[0083] L D = -[MlogP + (1-M)log(1-P)];
[0084] b. The generator calculates the following weighted loss of the generator based on the normal probability of the discriminator distinguishing abnormal values and the generation regression loss of the normal components in the auxiliary results Aux_output and the main results Main_output:
[0085]
[0086]
[0087] Among them, α and β are the weights of the probability loss of generating abnormal values and the regression loss of the main results to restore the normal component;
[0088] 5) Among them, for indefinite length time series input, in the model training phase, a small batch random cumulative gradient descent training model is used:
[0089] a. Input a single sample each time to the generator or discriminator to calculate the loss;
[0090] b. In the alternating training discriminator stage, b samples including the generator filling abnormal value time series, the second labeling matrix, and the region label are input cumulatively, the average cross entropy loss of the discriminator for the b samples is calculated, and the gradient update parameter is calculated, where b is the set Batch Size, and b can be, for example, 10, but it should be understood that the value of b is not limited thereto;
[0091] c. In the alternating training generator stage, the cumulative input includes the time series with missing value filling estimates, the first labeling matrix, and the samples of the region labels, and the average weighted loss of the generator for these b samples is calculated, and the gradient update parameters are calculated.
[0092] In an embodiment according to the present disclosure, the system 100 may further include a detection and filling module 104 .
[0093] The detection and filling module 104 can use the trained model to generate the probability that the parameters in the time series data to be detected are abnormal parameters; determine whether the parameters in the time series data to be detected are abnormal parameters based on the probability and probability threshold; and fill the parameters judged as abnormal and missing parameters in the time series data to be detected with normal values generated by the trained model.
[0094] See also Figure 3 At 309, the discriminator in the trained model can be used to predict the probability; at 310, the normal value can be screened out according to the probability; at 311, the generator in the trained model can be used to generate a first numerical matrix; at 312, the abnormal parameters and missing parameters can be filled with normal values based on the first numerical matrix.
[0095] Specifically, anomaly detection and missing fill may include the following steps:
[0096] 1) In the phase of anomaly detection and missing filling of the test data, the original data is first converted and preprocessed according to steps 1 and 2, the missing values are filled with the estimated values of the regional grouping MICE, and the noise components outside the regional grouping 3σ are marked as outliers; at the same time, the maximum and minimum values used for normalizing each parameter are recorded, and the preprocessed time series data, the first labeling matrix, the second labeling matrix, and the regional labels are constructed;
[0097] 2) First, perform anomaly detection on the preprocessed time series data, fill missing values with estimated values, and mark regional grouping noise as known outliers, to find all abnormal values:
[0098] a. Input the features required by the discriminator and output the normal probability matrix corresponding to the values at each position of the input data;
[0099] b. According to the set normal probability threshold θ, the values less than θ are screened out, that is, abnormal values, and a first marking matrix is constructed, in which the positions corresponding to the abnormal values found are filled with 0, and the remaining positions are filled with 1. The value of θ can be, for example, 0.5, but it should be understood that the value of θ is not limited to this;
[0100] 3) According to the anomaly detection results, fill in the abnormal components of the preprocessed time series data and replace them with normal values:
[0101] a. Input the required features to the generator, where the first label matrix is obtained using the anomaly detection in the previous step, and output a numerical matrix of the same size as the input data;
[0102] b. Replace the original values marked as abnormal components in the preprocessed time series data with the values of the corresponding positions in the first numerical matrix generated by the generator;
[0103] 4) According to the maximum and minimum values used by each parameter recorded, the results are denormalized and the final corrected data is output.
[0104] Figure 6 An exemplary configuration of a computing device 600 capable of implementing embodiments according to the present disclosure is shown.
[0105] The computing device 600 is an example of a hardware device to which the above aspects of the present disclosure can be applied. The computing device 600 can be any machine configured to perform processing and / or calculations. The computing device 600 can be, but is not limited to, a workstation, a server, a desktop computer, a laptop computer, a tablet computer, a personal data assistant (PDA), a smart phone, a vehicle-mounted computer, or a combination thereof.
[0106] like Figure 6 As shown, the computing device 600 may include one or more components that can be connected or communicated with the bus 602 via one or more interfaces. The bus 602 may include, but is not limited to, an Industry Standard Architecture (ISA) bus, a Micro Channel Architecture (MCA) bus, an Enhanced ISA (EISA) bus, a Video Electronics Standards Association (VESA) local bus, and a Peripheral Component Interconnect (PCI) bus. The computing device 600 may include, for example, one or more processors 604. The one or more processors 604 may be any type of processor and may include, but is not limited to, one or more general-purpose processors or special-purpose processors (such as special-purpose processing chips). The processor may be configured to implement, for example, Figure 2 , Figure 3 as well as Figure 4 The method shown.
[0107] The computing device 600 may also include or be connected to a non-transitory storage device 614, which may be any non-transitory storage device that can implement data storage, and may include, but is not limited to, a disk drive, an optical storage device, a solid-state memory, a floppy disk, a flexible disk, a hard disk, a magnetic tape, or any other magnetic medium, a compressed disk or any other optical medium, a cache memory, and / or any other storage chip or module, and / or any other medium from which a computer can read data, instructions, and / or code. The computing device 600 may also include a random access memory (RAM) 610 and a read-only memory (ROM) 612. The ROM 612 may store programs, utilities, or processes to be executed in a non-volatile manner. The RAM 610 may provide volatile data storage and store instructions related to the operation of the computing device 600.
[0108] In summary, according to the first aspect of the present disclosure, a method for training a model for anomaly detection and missing filling of time series data is provided, including: obtaining time series data of a user, wherein the time series data includes abnormal parameters and missing parameters; preprocessing the time series data to obtain preprocessed time series data, a first marking matrix, a second marking matrix, and region labels, wherein the first marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the time series data, the second marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the preprocessed time series data, and the region labels are configured to mark the region where the user is located; and training the model based on the preprocessed time series data, the first marking matrix, the second marking matrix, and the region labels.
[0109] In an embodiment according to the present disclosure, the model is an adversarial generative interpolation network, including a generator and a discriminator, the generator is configured to input preprocessed time series data, a first labeling matrix and region labels and output a first numerical matrix, the first numerical matrix includes normal values for filling abnormal parameters and missing parameters, the discriminator is configured to input time series data, a second labeling matrix and region labels and output a probability matrix, the probability matrix includes the probability that the parameters in the time series data are abnormal parameters.
[0110] In an embodiment according to the present disclosure, training the adversarial generative interpolation network includes inputting time series data padded with a first numerical matrix output by the generator into the discriminator.
[0111] In an embodiment according to the present disclosure, the probability matrix output by the discriminator takes into account the regional constraints, the first numerical matrix output by the generator takes into account the regional constraints, and the generator is also configured to output a second numerical matrix that does not take into account the regional constraints for training the generator.
[0112] In an embodiment of the present disclosure, preprocessing the time series data includes: grouping the time series data according to the area where the user is located; estimating the missing parameters in the time series data within the group, and filling the estimated parameters into the positions of the corresponding missing parameters; and identifying abnormal parameters in the preprocessed time series data.
[0113] In an embodiment according to the present disclosure, in the first marking matrix, the positions corresponding to abnormal parameters and missing parameters are marked as first values, and the positions corresponding to normal parameters are marked as second values; and in the second marking matrix, the positions corresponding to abnormal parameters are marked as third values, the positions corresponding to missing parameters are randomly marked as third values or fourth values, and the positions corresponding to normal parameters are randomly marked as fourth values or fifth values.
[0114] According to a second aspect of the present disclosure, a method for anomaly detection and missing filling of time series data is provided, comprising: training a model using the method described in the first aspect; generating a probability that a parameter in the time series data to be detected is an abnormal parameter using the trained model; judging whether the parameter in the time series data to be detected is an abnormal parameter based on the probability and the probability threshold; and filling the parameters judged to be abnormal and the missing parameters in the time series data to be detected with normal values generated using the trained model.
[0115] According to a third aspect of the present disclosure, there is provided a device for training a model for anomaly detection and missing filling of time series data, comprising: a construction module, configured to obtain time series data of a user, wherein the time series data includes abnormal parameters and missing parameters; a preprocessing module, configured to preprocess the time series data to obtain preprocessed time series data, a first marking matrix, a second marking matrix and region labels, wherein the first marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the time series data, the second marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the preprocessed time series data, and the region labels are configured to mark the region where the user is located; a training module, configured to train the model based on the preprocessed time series data, the first marking matrix, the second marking matrix and the region labels.
[0116] In an embodiment according to the present disclosure, the model is an adversarial generative interpolation network, including a generator and a discriminator, the generator is configured to input preprocessed time series data, a first labeling matrix and region labels and output a first numerical matrix, the first numerical matrix includes normal values for filling in abnormal parameters and missing parameters, the discriminator is configured to input time series data, a second labeling matrix and region labels and output a probability matrix, the probability matrix includes the probability that the parameters in the time series data are abnormal parameters.
[0117] In an embodiment according to the present disclosure, training the adversarial generative interpolation network includes inputting time series data padded with a first numerical matrix output by the generator into the discriminator.
[0118] In an embodiment according to the present disclosure, the probability matrix output by the discriminator takes into account the regional constraints, the first numerical matrix output by the generator takes into account the regional constraints, and the generator is also configured to output a second numerical matrix that does not take into account the regional constraints for training the generator.
[0119] In an embodiment of the present disclosure, preprocessing the time series data includes: grouping the time series data according to the area where the user is located; estimating the missing parameters in the time series data within the group, and filling the estimated parameters into the positions of the corresponding missing parameters; and identifying abnormal parameters in the preprocessed time series data.
[0120] In an embodiment according to the present disclosure, in the first marking matrix, the positions corresponding to abnormal parameters and missing parameters are marked as first values, and the positions corresponding to normal parameters are marked as second values; and in the second marking matrix, the positions corresponding to abnormal parameters are marked as third values, the positions corresponding to missing parameters are randomly marked as third values or fourth values, and the positions corresponding to normal parameters are randomly marked as fourth values or fifth values.
[0121] According to a fourth aspect of the present disclosure, a device for anomaly detection and missing filling of time series data is provided, comprising: a construction module, a preprocessing module and a training module according to the third aspect; and a detection and filling module, wherein the detection and filling module is configured to: generate a probability that a parameter in the time series data to be detected is an abnormal parameter using a trained model; determine whether the parameter in the time series data to be detected is an abnormal parameter based on a probability and a probability threshold; and fill the determined abnormal parameters and missing parameters in the time series data to be detected with normal values generated using the trained model.
[0122] According to a fifth aspect of the present disclosure, a non-transitory computer-readable storage medium is provided, on which a program is stored, characterized in that when the program is executed by a computer, the computer is caused to execute the method according to the first aspect.
[0123] According to a sixth aspect of the present disclosure, a non-transitory computer-readable storage medium is provided, on which a program is stored, characterized in that when the program is executed by a computer, the computer is caused to execute the method according to the second aspect.
[0124] According to a seventh aspect of the present disclosure, there is provided a device for training a model for anomaly detection and parameter filling of time series data, comprising a memory and a processor, wherein the memory is communicatively coupled to the processor, and a program is stored in the memory, and when the program is executed by the processor, the processor executes the method described in the first aspect.
[0125] According to an eighth aspect of the present disclosure, there is provided an apparatus for anomaly detection and parameter filling of time series data, comprising a memory and a processor, wherein the memory is communicatively coupled to the processor, wherein a program is stored in the memory, and when the program is executed by the processor, the processor executes the method described in the second aspect.
[0126] According to a ninth aspect of the present disclosure, a computer program product is provided, comprising a computer program, which implements the method described in the first aspect when executed by a processor.
[0127] According to a tenth aspect of the present disclosure, a computer program product is provided, comprising a computer program, which implements the method according to the second aspect when executed by a processor.
[0128] In the embodiment of the present disclosure, based on the session ID, base station ID, cell ID, and timestamp reported by the MR, the MR time series reported continuously by different users are identified according to certain rules, and the problem is converted into processing the indefinite-length multivariate time series data of each user;
[0129] In the embodiment of the present disclosure, the data are grouped according to regional attributes (base station ID, cell ID), the discriminant interpolation method (MICE) is used within the group to estimate missing values, the statistical method (3σ) is used to identify noise components, the missing values and abnormal positions of the time series are initialized in advance according to the spatial relationship, and the original time series data distribution is corrected;
[0130] In the embodiment of the present disclosure, the original incomplete data and time series structure information are directly used to train the generator and the discriminator based on GAIN, without the need for normal and complete time series sample training, wherein the first label matrix input by the generator reveals the missing / abnormal non-normal position in the input time series, and guides it to learn the normal component distribution to infer the complete data, wherein the second label matrix input by the discriminator reveals the abnormal position and the partially missing and normal position, and trains it to distinguish the normal component from the filled missing and abnormal components as much as possible according to the known information, so as to train the two parts against each other, and realize the joint operation of accurately determining the specific abnormal position of the time series data and replacing the missing values and abnormal values with normal values;
[0131] In the embodiment of the present disclosure, in view of the problem of inconsistent spatiotemporal distribution of the time series itself, spatial condition constraints (base station ID + cell ID) are introduced when training GAIN, and the generator and the discriminator are constructed as a multi-input multi-output model, with auxiliary input area labels, so that the generator calculates the regression loss of conditional generated samples and unconditional generated samples respectively, and the discriminator calculates the cross entropy loss of the normal probability of each component under the condition, so as to control the approximation direction of the model;
[0132] In the embodiments of the present disclosure, a generator and a discriminator model supporting spatial condition constraints are constructed based on the BiLSTM+Attention network, and a small batch random cumulative gradient descent training model is adopted, so that the model can adaptively process (MR user-level) indefinite-length multivariate time series.
[0133] The present disclosure will effectively improve the model training difficulty, accuracy, robustness and granularity of multivariate time series anomaly detection and missing filling such as MR key parameters, and adapt to time series with indefinite length and inconsistent spatiotemporal distribution to support data quality optimization.
[0134] The subject matter of the present disclosure is provided as an example of devices, systems, methods and programs for performing the features described in the present disclosure. However, in addition to the above-mentioned features, other features or variations may also be expected. It is expected that the implementation of the components and functions of the present disclosure may be completed with any emerging technology that may replace any of the above-mentioned implementation technologies.
[0135] In addition, the above description provides examples without limiting the scope, applicability or configuration set forth in the claims. Without departing from the spirit and scope of the present disclosure, the functions and arrangements of the elements discussed may be changed. Various embodiments may appropriately omit, replace or add various processes or components. For example, features described with respect to certain embodiments may be combined in other embodiments.
[0136] In addition, in the description of the present disclosure, the terms “first”, “second”, “third”, etc. are used for descriptive purposes only and cannot be understood as indicating or implying relative importance and order.
[0137] Similarly, while operations are depicted in a particular order in the drawings, this should not be understood as requiring that such operations be performed in the particular order shown or in sequential order, or that all illustrated operations be performed to achieve desired results. In certain circumstances, multitasking and parallel processing can be advantageous.
Claims
1. A method for training a model for anomaly detection and missing fill in time series data, comprising: Acquire time series data of the user's measurement report data, wherein the time series data includes abnormal parameters and missing parameters; Preprocessing the time series data to obtain preprocessed time series data, a first marking matrix, a second marking matrix and a region label, wherein the first marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the time series data, the second marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the preprocessed time series data, and the region label is configured to mark the region where the user is located; in the first marking matrix, the positions corresponding to the abnormal parameters and the missing parameters are marked as the first value, and the positions corresponding to the normal parameters are marked as the second value; and in the second marking matrix, the positions corresponding to the abnormal parameters are marked as the third value, the positions corresponding to the missing parameters are randomly marked as the third value or the fourth value, and the positions corresponding to the normal parameters are randomly marked as the fourth value or the fifth value; and Training the model based on the preprocessed time series data, the first label matrix, the second label matrix, and the region labels; The model is an adversarial generative interpolation network, including a generator and a discriminator. The generator is configured to input preprocessed time series data, a first labeling matrix and region labels and output a first numerical matrix, wherein the first numerical matrix includes normal values for filling abnormal parameters and missing parameters. The discriminator is configured to input time series data, a second labeling matrix and region labels and output a probability matrix, wherein the probability matrix includes the probability that the parameters in the time series data are abnormal parameters.
2. The method according to claim 1, wherein: Training the adversarial generative interpolation network includes inputting time series data padded with a first numerical matrix output by the generator into the discriminator.
3. The method according to claim 1, wherein: The probability matrix output by the discriminator takes into account the regional constraints, the first numerical matrix output by the generator takes into account the regional constraints, and the generator is also configured to output a second numerical matrix that does not take into account the regional constraints for training the generator.
4. The method according to claim 1, wherein: Preprocessing the time series data includes: Group the time series data by the region where the user is located; Estimate the missing parameters in the time series data within the group, and fill the estimated parameters into the positions of the corresponding missing parameters; and Parameters of anomalies in the preprocessed time series data are identified.
5. A method for anomaly detection and missing fill in time series data, comprising: Training the model using the method according to any one of claims 1 to 4; The trained model is used to generate the probability that the parameters in the time series data to be detected are abnormal parameters; Determine whether the parameter in the time series data to be detected is an abnormal parameter based on the probability and the probability threshold; as well as The parameters judged to be abnormal and the missing parameters in the time series data to be detected are filled with normal values generated using the trained model.
6. A device for training a model for anomaly detection and missing fill in time series data, comprising: A construction module is configured to obtain time series data of the user's measurement report data, wherein the time series data includes abnormal parameters and missing parameters; A preprocessing module is configured to preprocess the time series data to obtain preprocessed time series data, a first marking matrix, a second marking matrix and a region label, wherein the first marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the time series data, the second marking matrix is configured to mark the positions of abnormal parameters and missing parameters in the preprocessed time series data, and the region label is configured to mark the region where the user is located; in the first marking matrix, the positions corresponding to the abnormal parameters and the missing parameters are marked as the first value, and the positions corresponding to the normal parameters are marked as the second value; and in the second marking matrix, the positions corresponding to the abnormal parameters are marked as the third value, the positions corresponding to the missing parameters are randomly marked as the third value or the fourth value, and the positions corresponding to the normal parameters are randomly marked as the fourth value or the fifth value; A training module, configured to train the model based on the preprocessed time series data, the first label matrix, the second label matrix and the region labels; The model is an adversarial generative interpolation network, including a generator and a discriminator. The generator is configured to input preprocessed time series data, a first labeling matrix and region labels and output a first numerical matrix, wherein the first numerical matrix includes normal values for filling abnormal parameters and missing parameters. The discriminator is configured to input time series data, a second labeling matrix and region labels and output a probability matrix, wherein the probability matrix includes the probability that the parameters in the time series data are abnormal parameters.
7. The device according to claim 6, wherein: Training the adversarial generative interpolation network includes inputting time series data padded with a first numerical matrix output by the generator into the discriminator.
8. The device according to claim 6, wherein: The probability matrix output by the discriminator takes into account the regional constraints, the first numerical matrix output by the generator takes into account the regional constraints, and the generator is also configured to output a second numerical matrix that does not take into account the regional constraints for training the generator.
9. The device according to claim 6, wherein: Preprocessing the time series data includes: Group the time series data by the region where the user is located; Estimate the missing parameters in the time series data within the group, and fill the estimated parameters into the positions of the corresponding missing parameters; and Parameters of anomalies in the preprocessed time series data are identified.
10. A device for anomaly detection and missing filling of time series data, comprising: The device according to any one of claims 6 to 9; as well as A detection and filling module, wherein the detection and filling module is configured to: The trained model is used to generate the probability that the parameters in the time series data to be detected are abnormal parameters; Determine whether the parameter in the time series data to be detected is an abnormal parameter based on the probability and the probability threshold; as well as The parameters judged to be abnormal and the missing parameters in the time series data to be detected are filled with normal values generated using the trained model.
11. A non-transitory computer-readable storage medium having a program stored thereon, characterized in that: When the program is executed by a computer, the computer is caused to execute the method according to any one of claims 1 to 4.
12. A non-transitory computer-readable storage medium having a program stored thereon, characterized in that: When the program is executed by a computer, the computer is caused to execute the method according to claim 5 .
13. A model device for training anomaly detection and parameter filling for time series data, comprising a memory and a processor, wherein the memory is communicatively coupled to the processor, and a program is stored in the memory, and when the program is executed by the processor, the processor executes the method according to any one of claims 1-4.
14. A device for anomaly detection and parameter filling of time series data, comprising a memory and a processor, wherein the memory is communicatively coupled to the processor, and a program is stored in the memory, and when the program is executed by the processor, the processor executes the method according to claim 5.
15. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the method according to any one of claims 1 to 4 is implemented.
16. A computer program product, comprising a computer program, which implements the method of claim 5 when executed by a processor.
