Unmanned aerial vehicle unsupervised anomaly detection data model
By constructing the PA-LSTM-AE model, using parallel LSTM structure and attention mechanism, and combining Spearman correlation coefficient method to screen key features, the problem of difficulty in parameter screening in the abnormal detection of unmanned aerial aircraft flight data is solved, and efficient and accurate abnormal detection is achieved.
Patent Information
- Application Number
- CN202510335324.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-20
- Publication Date
- 2025-06-20
AI Technical Summary
In the detection of unmanned aerial flight data anomalies, how to effectively screen key parameters to avoid the reduction of model performance due to redundant information, resulting in a decrease in detection efficiency and accuracy.
The PA-LSTM-AE model is constructed, and the parallel LSTM structure and attention mechanism are used to perform correlation analysis and automatically filter key features through Spearman correlation coefficient method to reduce redundant information and enhance the model's sensitivity to abnormal patterns.
It significantly improves the performance of drone abnormal detection, improves the ability to extract complex dynamic features, optimizes the accuracy and efficiency of abnormal detection, and enhances the reliability and generalization capabilities of detection.
Smart Images

Figure CN120180337A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of unmanned aerial vehicle (UAV) anomaly detection, and particularly to an unsupervised UAV anomaly detection data model. Background Art
[0002] In the field of UAVs, anomaly detection can detect anomalies in flight data in advance, so as to perform preventive maintenance or mission replanning, improving the safety and reliability of UAVs. UAV flight data anomaly detection technologies are mainly divided into three categories: knowledge-based methods, model-based methods, and data-driven methods: 1. Knowledge-based methods rely on expert experience and prior knowledge to identify anomalies by defining normal behavior patterns in UAV flight data. This method is simple to implement but highly dependent on expert knowledge and difficult to adapt to new or unknown types of anomalies; 2. Model-based methods describe the normal flight behavior of UAVs by establishing mathematical models, and any data deviating from this model is considered abnormal. This method has high precision, but requires accurate physical models, and the model construction is complex and difficult; 3. Data-driven methods directly learn the normal behavior patterns of UAVs from data and identify data points deviating from these patterns. This method reduces the dependence on expert knowledge and does not require the construction of accurate physical models, and is currently a research hotspot.
[0003] The method proposed in Patent 201810639367.6 demonstrates the effectiveness of a combined model based on LSTM, CNN, and autoencoder (AE) in UAV flight data anomaly detection. However, these methods face a common challenge in practical applications: when UAV flight data contains a large number of parameters, how to effectively screen key parameters to avoid the degradation of model performance due to redundant information. Specifically, although the existing technologies can handle high-dimensional data, the inclusion of too many irrelevant or weakly relevant parameters not only increases the computational complexity but also may dilute the sensitivity of the model to true anomaly patterns, resulting in a decline in detection efficiency and accuracy. Summary of the Invention
[0004] The present invention provides an unsupervised UAV anomaly detection data model to solve the problems of difficult screening of key parameters in UAV flight data anomaly detection, easy influence of model performance by redundant information, and the need to improve anomaly detection accuracy and efficiency.
[0005] An unsupervised UAV anomaly detection data model of the present invention constructs a PA-LSTM-AE model based on the LSTM structure. The input of the previous time period will enter the parallel LSTM units simultaneously. After passing through the forget gate, the input gate and the output gate will be respectively passed to the next parallel LSTM unit, and the outputs of each parallel unit will be fused together. Specifically, it includes the following levels:
[0006] 1 input layer: As the entrance of the model, it passes the feature data to the subsequent layers;
[0007] 1 parallel LSTM layer: Among them, the upper layer is two LSTMs in series, and the lower layer has only one LSTM, which is used to process the input data and extract time series features;
[0008] 1 parallel dropout layer: Randomly drops the outputs of the upper and lower layer LSTMs respectively to prevent overfitting;
[0009] 1 multiplication layer: Multiplies and fuses the outputs of the two dropout layers to enhance feature interaction;
[0010] 1 attention layer: Calculates the attention weights for each time step to enhance the attention to important time steps;
[0011] 1 repeat vector layer: Repeats the output of the attention layer twice to generate time series data;
[0012] 1 LSTM layer; Processes the data of the attention layer;
[0013] 1 output layer: Used to output the loss function MSE.
[0014] Beneficial effects: Through the PA-LSTM-AE model with a unique parallel LSTM structure and attention mechanism, this solution significantly improves the performance in UAV anomaly detection: Its parallel LSTM layer effectively captures the short-term and long-term dependencies of flight data, combines with the multiplication layer to enhance feature interaction, and significantly improves the ability to extract complex dynamic features; The attention mechanism dynamically focuses on key time steps, optimizing the accuracy and efficiency of anomaly detection; The dynamic threshold setting adapts to the requirements of multiple scenarios, balances false alarms and missed alarms, and enhances the detection reliability; The parallel dropout layer prevents overfitting, ensuring the generalization and stability of the model. Through innovative design and algorithm optimization, this model provides an efficient and accurate technical guarantee for the safe flight of UAVs.
[0015] Furthermore, the calculation formula of the loss function MSE is as follows:
[0016]
[0017] In the formula, where y i is the i-th data point of the original feature data sequence without anomalies, is the i-th data point of the model estimate value, and n is the length of the selected feature data sequence. This solution provides a clear optimization goal for model training by quantifying the difference between the model estimate value and the original anomaly-free data points. The calculation formula of MSE directly reflects the accuracy of the model prediction, which helps to adjust the model parameters in a timely manner during the training process and improve the model performance.
[0018] Further, the PA-LSTM-AE model is trained, and the steps are as follows:
[0019] (1) Collect the initial data set; collect the feature data of the drone flight in multiple dimensions;
[0020] (2) Correlation analysis: Use the Spearman correlation coefficient method to perform correlation analysis on the feature data, and select the feature data with the absolute value of the Spearman correlation coefficient greater than 0.4 for output;
[0021] (3) Preprocess the data set: Perform normalization and data reconstruction on the selected feature data;
[0022] (4) Model training: Use the selected feature data to train the PA-LSTM-AE model. Each dimension of the feature data trains a corresponding model. The model outputs the loss function as the reconstruction error, and the anomaly threshold T of the feature data of this dimension is obtained after calculation.
[0023] The effects of this model training scheme are as follows: (1) Efficient feature screening: Through correlation analysis using the Spearman correlation coefficient method, it can automatically screen out the feature data highly related to the drone flight state (the absolute value of the correlation coefficient is greater than 0.4), effectively reducing redundant information, lowering the model complexity, and getting rid of the excessive dependence on expert experience, thus enhancing the universality and self-adaptability of the method; (2) Precise anomaly detection: Adopt the data-driven PA-LSTM-AE model, capture the complex dynamic patterns in the time series through the parallel LSTM structure, and combine the attention mechanism to enhance the attention to key time steps, significantly improving the accuracy and sensitivity of anomaly detection. This method can real-time identify the subtle anomalies in the drone flight data, providing a timely basis for preventive maintenance and mission adjustment; (3) Strong robustness and generalization ability: The random dropout layer is introduced during the model training process, effectively preventing overfitting and enhancing the model's generalization ability to unknown anomaly types. At the same time, through the dynamic anomaly threshold T set by quantiles, it can adapt to different flight environments and mission requirements, ensuring the robustness of anomaly detection. (4) Low computational cost and high efficiency: Data normalization and reconstruction not only meet the input requirements of the LSTM model but also reduce the computational amount through the sliding window technique, improving the processing efficiency. In addition, the division of the model training and test sets ensures the reliable evaluation of the model performance, further verifying the feasibility of the method in practical applications. In summary, through the constructed PA-LSTM-AE model, the real-time identification and robust detection of subtle anomalies in drone flight data are achieved, enhancing the universality, self-adaptability, and practical application feasibility of the method.
[0024] Further, in the model training step, a quantile p≤1 is set, and the product of this quantile and the reconstruction error is used as the anomaly threshold T. This solution enables the anomaly detection threshold to be dynamically adjusted according to different flight environments and mission requirements. This flexible threshold setting mechanism effectively balances the false alarm rate and the miss rate, improving the reliability and practicality of anomaly detection. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] Figure 1 It is a schematic diagram of a sliding window;
[0026] Figure 2 It is a diagram of the PLSTM model;
[0027] Figure 3 It is a diagram of the PA-LSTM-AE model of the present invention;
[0028] Figure 4 It is a diagram of the normal and injected deviation data of Flight 69 of Thor;
[0029] Figure 5 It is a diagram of the anomaly detection results of the PA-LSTM-AE, LSTM-AE, PLSTM-AE, and ALSTM-AE models after injecting bias = 10;
[0030] Figure 6 It is a diagram of the visualized anomaly detection results of the PA-LSTM-AE, LSTM-AE, PLSTM-AE, and ALSTM-AE models (δ = 10);
[0031] Figure 7 It is a diagram of the anomaly detection results of the PA-LSTM-AE, LSTM-AE, PLSTM-AE, and ALSTM-AE models after injecting bias = 5;
[0032] Figure 8 It is a schematic flow diagram of an unsupervised anomaly detection method for unmanned aerial vehicles. DETAILED DESCRIPTION OF THE INVENTION
[0033] EXAMPLE
[0034] In this example, an unsupervised anomaly detection data model for unmanned aerial vehicles, namely the constructed PA-LSTM-AE, has an output of the loss function MSE.
[0035] Introduction to PLSTM: LSTM is a variant of the Recurrent Neural Network (RNN) proposed by Hochreiter and Schmidhuber in 1997. It aims to solve the problem of vanishing or exploding gradients encountered by traditional RNNs when dealing with long sequence data. The structure of LSTM usually consists of a forget gate, an input gate, an output gate, and a memory cell. The forget gate decides which information should be retained in the cell state and which information should be forgotten based on the current input and the output of the previous time step. At the same time, the input gate determines whether to add new information to the cell state. The cell state is updated according to the decisions of the forget gate and the input gate. Finally, the output gate determines the output value, and it also saves the current data to the next hidden layer cell, and the storage cell determines and sends the data to the next layer. As Figure 2 shown, on the basis of the original LSTM structure, the PLSTM model structure proposes a parallel LSTM structure. The input of the previous time period will enter the parallel LSTM units simultaneously. After passing through the forget gate, the input gate and the output gate will be respectively passed to the next parallel LSTM unit, and the outputs of each parallel unit will be fused together.
[0036] The PA-LSTM-AE model constructed in this embodiment is a neural network that combines the LSTM network with AE. It combines the feature extraction ability of the autoencoder with the time data processing ability of LSTM to retain the time data information in the extracted features. And the introduced parallel mechanism can improve the accuracy of model anomaly detection. In the PA-LSTM-AE model, on the basis of the LSTM structure, the input of the previous time period will enter the parallel LSTM units simultaneously. After passing through the forget gate, the input gate and the output gate will be respectively passed to the next parallel LSTM unit, and the outputs of each parallel unit will be fused together.
[0037] Figure 3 The dotted line in
[0038]
[0039] According to Table 1 and Figure 3 shown, the structure of the PA-LSTM-AE model is as follows:
[0040] 1 input layer (i.e., Input layer): As the entrance of the model, it passes the feature data to the subsequent layers;
[0041] 1 parallel LSTM layer (i.e., PLSTM Layer), where the upper layer is two LSTMs in series and the lower layer has only one LSTM; processes the input data and extracts time series features;
[0042] 1 parallel dropout layer (i.e., dropout layer): randomly drops the outputs of the upper and lower LSTMs respectively to prevent
[0043] overfitting;
[0044] 1 multiplication layer (i.e., Multiply layer): multiplies and fuses the outputs of the upper and lower dropouts to enhance feature
[0045] interaction;
[0046] 1 attention layer (i.e., Attention Mech layer): calculates the attention weights for each time step to enhance the attention to important
[0047] time steps;
[0048] 1 repeat vector layer (i.e., Repeat vector layer): converts the output of the attention layer into data suitable for the LSTM layer;
[0050] 1 LSTM layer; processes the data of the attention layer;
[0051] 1 output layer (i.e., Output layer layer): outputs the mean squared error (MSE) of the loss function.
[0052] The data model for unsupervised anomaly detection of drones in this embodiment is applied to unsupervised anomaly detection of drones. As Figure 8 shown, the detection method includes the following steps:
[0053] (1) Data collection
[0054] This embodiment uses the publicly available dataset of the Thor 69 UAV (i.e., unmanned aerial vehicle) collected by the University of Minnesota, which consists of 75 feature data sequences recorded during the 69th normal flight of the Thor UAV. The sampling frequency is 50 Hz, with a total of 42,711 data sampling points.
[0055] (2) Correlation analysis
[0056] The Spearman correlation coefficient method is used to perform correlation analysis on the collected feature data, and the feature data sequences with the absolute value of the Spearman correlation coefficient greater than 0.4 are selected for output. The calculation formula is as shown in Equation (1):
[0057]
[0058] In the formula, ρ is the Spearman correlation coefficient, di Denote the rank difference of the corresponding observed values of two variables, and \(n\) is the number of features in the data set. is the sum of squares of all pairwise rank differences.
[0059] (3) Data preprocessing
[0060] Perform normalization and data reconstruction on each selected feature data sequence. Among them, the normalization uses the formula as shown in (2), and the initial data is represented by \(x\) o denote, and the normalized data is represented by \(x\) new denote, and \(x\) o The maximum and minimum values of are represented by \(x\) omax and \(x\) omin respectively:
[0061]
[0062] Reconstruct the normalized data. Specifically, use a sliding window of length \(E\) to capture local data in the time series data. The sliding mechanism with \(E = 2\) is as Figure 1 shown, Figure 1 where \(n\) is the length of the selected feature data sequence. Define the reconstruction equation as shown in Equation (3) below. The reconstructed data is the input matrix \(X(T)\) that meets the requirements of LSTM training:
[0063]
[0064] In Equation (3), \(x\) n is the original data in the feature data time series, and \(n\) is the length of the selected feature data sequence.
[0065] (4) Data set division
[0066] Randomly divide the preprocessed feature data group into training set and test set. The training set consists of \([0:12.750]\), accounting for 85% of the data set, and the test set consists of \([12.750:15.000]\), accounting for 15% of the data set.
[0067] Since it is difficult to obtain abnormal data, this embodiment uses the abnormal injection method to generate abnormal data. Drift anomalies occur when the UAV cannot maintain the expected trajectory, position, or attitude due to factors such as sensor errors, environmental interference, or power problems, resulting in the UAV flight data deviating from the expected \(v\) value. Drift anomalies involve the gradual deviation of UAV flight data from the predetermined trajectory or position, usually caused by dynamic factors. The formula for injecting offset anomalies is as shown in Equation (4).
[0068] \(x_{bias}=x_t+\delta\) (4)
[0069] where \(x\) tis the original flight data, δ is a constant, and t is time. Anomaly data is injected into the test set before model training, or anomalies are injected into the test set after model training is completed, to detect the anomaly detection ability of the model.
[0070] (5) Model training
[0071] The PA-LSTM-AE model is trained using the training set. The loss function used by the model is MSE, as shown in Equation (5):
[0072]
[0073] where y i is the i-th data point without anomalies in the original feature data sequence, is the i-th data point of the model estimate, and n is the length of the selected feature data sequence. In this embodiment, the loss function MSE is used as the reconstruction error.
[0074] Since too many LSTM parameters will cause overfitting in model training and affect the training of forward propagation, it is necessary to discard some LSTM units during training to prevent overfitting. In this embodiment, the PA-LSTM-AE model introduces a dropout layer with dropout = 0.1. The activation function of the PA-LSTM-AE model is the ReLU function, and the Adam optimizer is used to update the network weights.
[0075] After training is completed, a quantile p ≤ 1 is set, and the product of this quantile and the reconstruction error is used as the anomaly threshold T for subsequent anomaly detection.
[0076] After the model training is completed, the data in the test set is used to test the model. The reconstruction error of the test set can be obtained from Equation (5). When the reconstruction error of the test set is less than the anomaly threshold T, it proves that the data at this time is normal data; when the reconstruction error of the test set is greater than the anomaly threshold T, it means that the data at this time is anomaly data, and the relevant representation is as shown in Equation (6):
[0077]
[0078] (6) Model verification
[0079] In this embodiment, navalt is selected as the detection parameter to verify the performance of the PA-LSTM-AE model. For the embodiment, two pairs of biases of 5 and 10 are respectively used to inject into the model for verification.
[0080] Figure 4 Shows the flight data set injected with bias anomalies, and the data division. The injection anomaly range is [14200:15000], and the injected bias anomaly δ value is 5.
[0081] In the anomaly detection task, the key to diagnosing the quality of a model lies in the model's ability to detect anomalies. In this embodiment, the accuracy (ACC), true positive rate (TPR), and false positive rate (FPR) are used as the performance evaluation criteria for the experimental model. The calculation formulas are shown in Equations (7), (8), and (9) as follows:
[0082]
[0083]
[0084] In Equations (7), (8), and (9), TP represents the number of correctly identified normal samples, TN represents the number of correctly identified abnormal samples, FP represents the number of normal samples misidentified as abnormal, and FN represents the number of abnormal samples misidentified as normal. The higher the ACC and TPR values, and the lower the FPR value, the better the training effect of the model.
[0085] When the model is applied, for a certain type of UAV, the applicable features are first selected using historical data according to the above process, and then the model is trained using these selected feature data. The trained parameters and the model can be imported into the on-board system of the UAV of this type to be tested for anomaly detection directly.
[0086] A. Ablation Experiment
[0087] To verify the effectiveness of the solution in this embodiment, it is compared with LSTM-AE, PLSTM-AE, and ALSTM-AE, and the model is trained, and then tested using the real UAV dataset of Thor 69. And the measured Threshold is used to divide the abnormal data and normal data, and the results are as Figure 5 shown.
[0088] Figure 5Among them, when δ takes 10, it is a comparison of the anomaly detection capabilities between PA-LSTM-AE and the model after removing the relevant strategy. It can be seen that when the strategy is not added, the ACC of LSTM-AE is only 77.42%, the TPR is only 70.29%, and the FPR is 18.63%. This indicates that LSTM-AE cannot accurately judge abnormal data, that is, LSTM-AE cannot accurately judge abnormal data and will also misidentify some normal data as abnormal data. After adding the Attention mechanism to ALSTM-AE, that is, LSTM-AE, its ACC is 94.13%, the TPR is 83.90%, and the FPR is 0.21%. It can be seen from this that after adding the Attention mechanism, the correctness of the abnormal data recognition model has been improved, and it can more accurately distinguish correct data and wrong data. The number of misrecognized normal data has also decreased, and its accuracy can reach a very high standard. In order to make the model reach a relatively high TPR value as much as possible, this paper proposes an improved PLSTM-AE model. The parallel mechanism of this model does not mean that two LSTMs are independently iteratively trained, but that two parallel LSTMs are trained at the same sample point and the same time point. And the results of each training need to be combined with the multiplication layer at the same time. The output and the backpropagation process are completed at a certain time point simultaneously, which means that although the LSTMs in the encoder are in a parallel structure, the previous states of the LSTMs in each recursion are consistent. Therefore, the structure proposed in this paper avoids the problem that parallel LSTMs cannot be combined due to recursive training at the same time, and greatly improves the feature extraction ability of the model. After experiments, the ACC value of PLSTM-AE is 95.33%, the TPR value is 99.63%, and the FPR value is 7.04%. These data indicate that the accuracy of this model in detecting abnormal data has been greatly improved, but the probability of misidentifying some abnormal data has increased.
[0089] Compared with LSTM-AE with the attention mechanism, the normal data misidentified as abnormal data has also increased. In addition, the PLSTM-AE model is prone to overfitting during the training process. Combining the above information, this paper combines the improved PLSTM-AE model with the attention mechanism to form the PA-LSTM-AE model. After training with real data, the ACC value is 98.31%, the TPR value is 99.63%, and the FPR value is 2.42%. The results show that the proposed model can distinguish almost all abnormal data, greatly reducing the abnormal discrimination of normal data, and also proving the abnormal detection ability of the proposed model.
[0090] Figure 6Shows the anomaly detection visualization of each model after ablation experiments (delta = 10). In the anomaly detection module, that is, the top figure of each model, where blue represents normal data and red represents abnormal data. Corresponding to the visual comparison of the initial data and the reconstructed data, where the red solid line represents the reconstructed data after the model experiment, and the blue solid line represents the initial data. The wireframe indicates the situation of error detection and is magnified in the figure. Since abnormal data will generate large errors during the decoding and reconstruction process, it can be detected through anomaly detection. It can be seen from the figure that compared with other models, PA-LSTM-AE amplifies the reconstruction difference between normal data and abnormal data by optimizing the feature extraction and fusion strategy, thus setting the detection threshold more accurately for anomaly detection.
[0091] Table 2 gives the change amounts of TPR, FPR, and ACC of PA-LSTM-AE, PLSTM-AE, and ALSTM-AE relative to LSTM-AE. The more TPR and ACC increase, and the more FPR decreases, the better the model improvement. It can be seen from the data in Table 3 that compared with LSTM-AE, the ACC of ALSTM-AE has increased by 16.71%, the FPR has decreased by 18.42%, and the TPR has increased by 13.61%. Thus, it can be seen that the addition of the attention mechanism has indeed greatly improved the anomaly detection rate, and the false detection rate of the model has also been greatly reduced. Compared with LSTM-AE, the ACC of PLSTM-AE has increased by 17.91%, the FPR has decreased by 11.59%, and the TPR has increased by 29.34%. The accuracy effect of PLSTM-AE is better, and the false detection rate has also been greatly reduced. In contrast, PA-LSTM-AE increases the ACC by 20.89%, reduces the FPR by 16.21%, and increases the TPR by 29.34%. Combining the advantages of the above two makes the proposed PA-LSTM-AE not only greatly improve the anomaly detection effect, but also further reduce the false detection rate. This indicates that PA-LSTM-AE can more effectively mine the dependencies between spatio-temporal related features, thus detecting more anomalies.
[0092] Table 2 Comparison of the anomaly detection capabilities of PA-LSTM-AE and the model after removing related strategies (δ = 10)
[0093]
[0094] Such as Figure 7As shown in the figure, when the δ value is 5, the ACC of LSTM-AE is only 66.04%, the FPR is 24.36%, and the TPR is 48.69%. While the ACC value of ALSTM-AE is 80.80%, the FPR value is 10.56%, and the TPR value is 65.17%. This can also prove that the introduced attention mechanism improves the performance of its model for anomaly detection to a certain extent. The ACC of PLSTM-AE is 93.02%, the FPR is 8.83%, and the TPR is 96.37%. Although its TPR is the best, it can be seen from this that the data predicted by PLSTM-AE deviates greatly from the real data and is prone to overfitting during the training process. Therefore, the actual effect is not ideal. The accuracy of PA-LSTM-AE proposed in this paper is 93.24%, the FPE is 6.34%, and the TPR is 92.51%. Although the TPR value is not as high as that of the initial PLSTM-AE, it avoids the problem of the predicted data deviating from the real data and also greatly reduces the overfitting of the model. This indicates that the proposed PLSTM-AE has a large deviation from the actual data.
[0095] B. Benchmark Experiment
[0096] To further verify the effectiveness of the proposed model, we compared KPCA, KNN, SVM, CAE with PA-LSTM-AE. The principle of anomaly detection in KPCA is a non-linear data processing method. By mapping the data into a high-dimensional feature space, principal component analysis is performed in the high-dimensional feature space to extract the main features, and then the T2 and Q statistics are used for anomaly detection. KNN is a time-dependent anomaly detection method. It realizes anomaly detection by calculating the distance between the predicted data point and the nearest K sample points and distinguishing the anomaly samples according to the threshold. The similarity between SVM and KPCA is that it also maps the data into a high-dimensional feature space through the kernel function and maximally separates the distance between all data points and the origin through the decision function, so that the points far from most data points are regarded as anomalies. CAE is a variant of AE and is an unsupervised anomaly detection method. It uses a convolutional neural network to extract the features of the input data and then uses the reconstruction error to judge whether the new data is abnormal.
[0097] Table 3 Comparison of Anomaly Detection Capabilities between PA-LSTM-AE and Benchmark Methods
[0098]
[0099] Table 3 shows the results of the above anomaly detection methods. When the bias is 5, the TPR of SVM is the highest, at 99.88%, but the FPR value is not good, at 27.67%. Most of the normal data detected by this method are outliers, which is usually not allowed in practical applications. The ACC value of KPCA is 85.24%, the TPR value is 67.29%, and the FPR value is 4.83%. This is not a good result. The reason may be that the principal elements with smaller eigenvalues may capture the main fault information, while the principal elements with larger eigenvalues may not capture the main fault information, resulting in the TPR value and ACC value of KNN being 19.66% and 78% respectively. The reason for this phenomenon may be that KNN has a lower tolerance for training data and is more sensitive to noise data and outliers. The ACC, TPR, and FPR of CAE are 86.49%, 66.79%, and 2.62% respectively. The reason for this phenomenon may be the high volatility of the data, resulting in large fluctuations in CAE during training. CAE may not converge or be unstable during training, resulting in low TPR and ACC values.
[0100] Table 4 Comparison of the result change rates based on the PA-LSTM-AE benchmark method
[0101]
[0102] Table 4 presents the performance differences between the PA-LSTM-AE model and CAE, KNN, KPCA, and SVM. When the bias is 5, compared with CAE, KNN, KPCA, and SVM, the ACC of PA-LSTM-AE is increased by 6.75%, 15.24%, 8.00%, and 11.11% respectively. The TPR of PA-LSTM-AE is 7.37% lower than that of SVM, but 25.72%, 72.85%, and 25.22% higher than that of CAE, KNN, and KPCA respectively. The FPR value of PA-LSTM-AE is 6.34%, which is 3.72% and 1.51% higher than that of CAE and KPCA respectively, but 12.6% and 21.33% lower than that of KNN and SVM respectively. The above results indicate that PA-LSTM-AE has a good anomaly detection effect.
[0103] When the deviation is 10, the TPR of SVM is the highest, at 99.88%. The TPR of PA-LSTM-AE also increases with the increase of the error, at 99.63%. The TPR values of KNN and CAE are 23.93% and 70.03% respectively, both showing a slight increase. However, in the FPR comparison, the FPR value of PA-LSTM-AE is the smallest, at 2.42%, which is 0.58%, 15.49%, 9.80% and 0.25% lower than that of CAE, KNN, KPCA and SVM respectively. This reduction is due to the attention mechanism greatly improving the ability of PA-LSTM-AE to capture abnormal data under high bias, resulting in a reduction in FPR. Compared with CAE, KNN, KPCA and SVM, the ACC values of PA-LSTM-AE are increased by 10.93%, 19.31%, 10.84% and 12.27% respectively.
[0104] Conclusion: A new LSTM-AE framework for UAV anomaly detection, namely the PA-LSTM-AE model. First, the Spearman correlation coefficient is used to achieve the correlation selection of flight features, effectively reducing the dependence on expert knowledge. Then, the maximum-minimum normalization is used to normalize the data range to between -1 and 1, and the data is reconstructed to meet the requirements of LSTM. Secondly, the attention mechanism is introduced to improve the feature extraction ability of PLSTM in the decoder. Finally, the data is divided into a training set and a test set, imported into the model for training, and the anomaly detection ability of the model is verified through a real dataset.
Claims
1. A drone unsupervised anomaly detection data model, characterized by: The PA-LSTM-AE model is constructed based on the LSTM structure. The input of the previous time period will enter the parallel LSTM unit at the same time. After passing through the forget gate, the input gate and the output gate will be respectively passed to the next parallel LSTM unit. The output of each parallel unit will be fused together, including the following layers: 1 input layer: as the entry of the model, passing feature data to subsequent layers; 1 parallel LSTM layer: the upper layer consists of two LSTMs connected in series, and the lower layer has only one LSTM, which is used to process input data and extract time series features; 1 parallel dropout layer: randomly drop the outputs of the upper and lower LSTM layers to prevent overfitting; 1 multiplication layer: multiply and fuse the outputs of the two discard layers to enhance feature interaction; 1 attention layer: calculates the attention weight of each time step to enhance the attention to important time steps; 1 Repeat Vector Layer: Repeat the output of the attention layer twice to generate time series data; 1 LSTM layer; processes the data of the attention layer; 1 output layer: used to output the loss function MSE.
2. The unsupervised anomaly detection data model for drones according to claim 1 is characterized in that: The calculation formula of the loss function MSE is as follows: In the formula, y i is the i-th data point without abnormality in the original feature data sequence, is the i-th data point of the model estimate, and n is the length of the selected feature data sequence.
3. The unsupervised anomaly detection data model for drones according to claim 2 is characterized in that: The PA-LSTM-AE model is trained in the following steps: (1) Collect the initial data set; collect characteristic data of drone flight in multiple dimensions; (2) Correlation analysis: The Spearman correlation coefficient method was used to perform correlation analysis on the feature data, and the feature data with an absolute value of the Spearman correlation coefficient greater than 0.4 were selected for output; (3) Preprocessing the data set: normalizing and reconstructing the selected feature data; (4) Model training: The PA-LSTM-AE model is trained using the selected feature data. A corresponding model is trained for each dimension of feature data. The model outputs the loss function as the reconstruction error, and the anomaly threshold T of the feature data of that dimension is obtained after calculation.
4. The unsupervised anomaly detection data model for drones according to claim 3 is characterized by: In the model training step, a quantile p≤1 is set, and the quantile multiplied by the reconstruction error is used as the abnormal threshold T.
Citation Information
Patent Citations
An LSTM-based method for detecting anomalies in UAV flight data
CN108960303B