Aviation trajectory prediction method based on multi-flight training and transposition input, medium, device and program product
Through the Transformer model of multi-flight training and transposed input, the problems of insufficient learning features and difficulty in capturing long-term sequence prediction correlation caused by a single flight input method are solved, and higher prediction accuracy and generalization ability are achieved.
Patent Information
- Application Number
- CN202411441790.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-16
- Publication Date
- 2025-02-18
AI Technical Summary
In the existing aviation trajectory prediction methods, the input method of a single flight leads to insufficient learning characteristics and it is difficult to effectively capture the correlation between data in long-term sequence prediction.
Using multi-flight training and transposed input Transformer model, the data preprocessing of the flight data set and the trajectory prediction using the transposed input Transformer model to better capture the dependencies between data and variables. Relevance.
It improves the accuracy of flight trajectory prediction and the generalization ability of the model, and can identify the mutual influence between different variables in multivariable situations, providing more reliable and accurate prediction results.
Smart Images

Figure CN119479384A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of aviation trajectory prediction, and in particular to an aviation trajectory prediction method, medium, device and program product based on multi-flight training and transposed input. Background Art
[0002] With the development of globalization and economy, the demand for air transportation continues to grow, which puts higher requirements on the efficiency and safety of flight operations. The rapid development of the aviation industry has led to a continuous increase in airport surface traffic, an increase in the number of surface taxiways and runways, and complex connections between taxiways. However, limited airspace resources and the increasing number of flights have led to increasingly serious airspace congestion, affecting the normal operation of flights and passengers' travel experience. In the case of large-scale flight delays or changes in taxiway traffic status, it is difficult to ensure the efficiency of surface operations.
[0003] At present, the methods for flight trajectory prediction mainly include traditional prediction methods based on aircraft aerodynamics and aircraft performance models, prediction methods based on machine learning, and prediction methods based on deep learning.
[0004] Predictions based on aircraft dynamics and aircraft performance can effectively utilize the characteristics of aircraft in different flight phases. However, simple modeling methods and fixed parameter settings are only applicable to ideal flight modes. The actual flight process of an aircraft is complex and the parameters change dynamically, so it is difficult to predict the flight trajectory of the aircraft in advance.
[0005] With the development of artificial intelligence, machine learning has shown excellent performance in flight trajectory prediction, such as K-nearest neighbor algorithm, support vector machine, decision tree and random forest, which use data mining technology to find historical flight data and find factors that affect flight trajectory. Machine learning has high requirements for data quality and feature engineering when making predictions, and usually relies on manually selected features. This process requires the knowledge and experience of domain experts, so it is relatively cumbersome and time-consuming and limits its generalization ability on unseen data.
[0006] With the rise of Convolutional Neural Network (CNN), its unique network structure and powerful feature extraction capabilities have brought new development to time series prediction tasks. However, the locality of CNN has largely limited the development of time series prediction. Long Short-Term Memory (LSTM) has been used to deal with time series problems for a long time because of its special structure that can capture the long-term dependencies of data. However, LSTM still faces huge challenges when dealing with longer sequences. Recently, the emergence of Transformer has brought new development to time series prediction. Transformer can capture the long-term dependencies of sequences with its self-attention mechanism, but the practice of embedding multiple variables in the same channel at the same time leads to the elimination of the correlation of multiple variables in the prediction process. In addition, for flight prediction, current models often only use the trajectory data of a single flight for training and prediction. The data of a single flight is limited, so the knowledge features learned during model training are limited. Summary of the invention
[0007] The present invention aims to provide an aviation trajectory prediction method, medium, device and program product based on multi-flight training and transposed input to solve the problem of insufficient learning features caused by the previous single flight input method and the correlation capture problem faced by long-term series prediction.
[0008] The present invention provides an aviation trajectory prediction method based on multi-flight training and transposed input, comprising:
[0009] Collect flight data sets and perform data preprocessing;
[0010] Build a Transformer model based on transposed input and train the model using preprocessed data;
[0011] Use the trained Transformer model for trajectory prediction;
[0012] Visualize the trajectory prediction results.
[0013] Furthermore, the data preprocessing includes:
[0014] The collected flight data sets are grouped using the flight number as an index, and after the grouping process, each flight data is screened, wherein the screening process is the detection of the data length;
[0015] Perform equidistant sampling, completion operations and data selection on the filtered flight data;
[0016] The processed flight data set is divided into training set, validation set and test set in a certain proportion; the training set is used to train the model, the validation set is used to select and adjust the model parameters, and the test set is used to evaluate the model.
[0017] Furthermore, the Transformer model based on transposed input includes an Embedding layer, an attention layer, a first residual connection and normalization layer, a feedforward neural network layer, a second residual connection and normalization layer and a projection operation layer connected in sequence.
[0018] Furthermore, the data is transposed before being input into the Embedding layer of the Transformer model based on transposed input, and the entire sequence of each feature vector is taken as a token.
[0019] Furthermore, the Embedding layer is implemented using a multi-layer perceptron MLP.
[0020] Furthermore, in the feedforward neural network layer, a linear transformation is first performed, then a nonlinear transformation is performed, and finally a linear transformation is performed again.
[0021] Furthermore, the projection operation layer uses a multi-layer perceptron MLP to perform projection operations.
[0022] The present invention also provides a computer terminal storage medium storing computer terminal executable instructions, wherein the computer terminal executable instructions are used to execute the above-mentioned aviation trajectory prediction method based on multi-flight training and transposed input.
[0023] The present invention also provides a computing device, comprising:
[0024] At least one processor; and a memory in communication with the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the above-mentioned aviation trajectory prediction method based on multi-flight training and transposed input.
[0025] The present invention also provides a computer program product, which implements the above-mentioned aviation trajectory prediction method based on multi-flight training and transposed input when the computer program is executed by a processor.
[0026] In summary, due to the adoption of the above technical solution, the beneficial effects of the present invention are:
[0027] The present invention adopts a training method with multiple flight inputs and a Transformer method based on transposed inputs. By preprocessing the flight data set and using only valid flight data, the amount of data is greatly reduced, which provides convenience for subsequent training. The Transformer model with transposed inputs can better capture the dependencies between data when performing trajectory prediction, and the attention layer in the model can also capture the correlation between variables. It can not only solve the complex dependency problems in time series data, but also identify the mutual influence between different variables in multivariate situations, thereby improving the accuracy of prediction and the generalization ability of the model. This method is particularly suitable for tasks with high-dimensional features and long-sequence dependencies, such as aviation trajectories. It can capture detailed features while comprehensively considering global information to provide more reliable and accurate prediction results. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] Figure 1 The flowchart of the aviation trajectory prediction method based on multi-flight training and transposed input in an embodiment of the present invention.
[0029] Figure 2 Schematic diagram of an improved Tranformer model in an embodiment of the present invention. DETAILED DESCRIPTION
[0030] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Generally, the components of the embodiments of the present invention described and shown in the drawings here can be arranged and designed in various different configurations.
[0031] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the invention claimed for protection, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0032] Example
[0033] like Figure 1 As shown, this embodiment proposes an aviation trajectory prediction method based on multi-flight training and transposed input, comprising the following steps:
[0034] Step S1, collect flight data set and perform data preprocessing:
[0035] Step S1.1, grouping and screening: The collected flight data set contains tens of thousands of flight data. In order to predict a certain flight, it is first necessary to perform grouping processing on the collected flight data set. The embodiment of the present invention uses the flight number as an index to perform grouping processing on the collected flight data set, and saves the grouped data to a csv file. Through grouping processing, in the subsequent process, it is possible to perform screening processing using only the flight number and implement training with the input of multiple flights, and finally predict the specified flight. The screening process refers to the detection of the data length for each flight data, and only flight data that meets the conditions can be used as model input for model training.
[0036] Training with multiple flight inputs significantly improves the prediction accuracy of the model. By continuously training with a large amount of different flight data, the model can better capture and adapt to the differences between flights, learn more features and patterns, and improve the generalization ability of unknown data. At the same time, since the training and prediction of each flight are independent, this independence ensures that the model will not interfere with each other when processing each flight data, thereby improving the prediction accuracy.
[0037] Step S1.2, data preprocessing: The collected flight data contains multiple characteristic factors such as flight number, time, longitude, latitude, speed, altitude, take-off and landing airports, and unequal sampling, missing values, and outliers may occur during the data collection process. Therefore, the following data preprocessing is performed on the filtered flight data:
[0038] (1) Equidistant sampling: Equidistant sampling is performed on the filtered flight data to adapt to the input of the model;
[0039] (2) Completion operation: fill the flight data with missing values using the average value to prevent the impact of empty data prediction;
[0040] (3) Data selection: Select data information related to the flight trajectory, including longitude, latitude, altitude, and speed, which are expressed as [[h 11 ,h 12 ,…,h 1t ],[h 21 ,h 22 ,…,h 2t ],[h 31 ,h 32 ,…,h 3t ],[h 41 ,h 42 ,…,h 4t ]], where t=1,2,…n.
[0041] Step S1.3, data set division: the flight data set processed by steps S101 and S102 is divided into a training set, a validation set and a test set in a certain proportion (for example, 70%, 20% and 10%). The training set is used to train the model, the validation set is used to select and adjust the parameters of the model, and the test set is used to evaluate the model. Instead of taking different variables at the same time as input, the embodiment of the present invention takes the entire sequence of a single variable as the input of the model, captures the dependency of a single variable at different time moments, and can capture the changes in latitude in a larger window.
[0042] Step S2, build a Transformer model based on transposed input and train the model using the preprocessed data:
[0043] The specific structure of the Transformer model based on transposed input is as follows Figure 2 As shown in the figure, the specific functions of each layer are as follows:
[0044] Step S2.1, Embedding layer:
[0045] Before embedding, the input data is transposed and the entire sequence of each feature vector is used as a token to better capture the dependency and change trend of the features in the entire time series and retain the independence between features. For example, for a flight data, the original input matrix is Among them, T is the time step, N is the number of features, and after transposition, it is The embedding operation in the embodiment of the present invention is implemented by a multilayer perceptron (MLP), which maps each feature of the transposed flight data into a high-dimensional space to facilitate subsequent processing.
[0046] X=X.transpose,X∈R N×T (1)
[0047]
[0048] H={h1,h2,...h N} (3)
[0049] in, Indicates that it contains N tokens of dimension D, X :,n Represents the size of the playback window.
[0050] Step S2.2, Multivariate Attention:
[0051] When facing multiple feature vector inputs, since the entire sequence of a single feature vector is taken as a token, the attention layer of the embodiment of the present invention is mainly used to capture the correlation between feature vectors. The feature vector of each token is respectively compared with the parameter matrix W Q , W K and W V Multiply to get the query vector Q i , key vector K i Sum value vector V i , and calculate the similarity between each feature vector and other feature vectors respectively, obtain the similarity factor, perform softmax operation to weaken the influence of irrelevant features, and finally perform weighted summation with the value vector to obtain the attention matrix A.
[0052] Q i =h i W Q , K i =h i W K , V i =h i W V , K j =h j W K (4)
[0053]
[0054] Among them, d k is the embedding dimension of the attention head, that is, the feature dimension of the query vector and the key vector, using the scaling factor Each token is normalized on its dimension.
[0055] Step S2.3, the first residual connection and normalization layer Layer-Norm1:
[0056] A residual connection is performed based on the attention matrix A obtained in step S2.2 to prevent the gradient vanishing phenomenon in the model during the training process, which makes the loss function difficult to fit in the end. The specific implementation is as follows:
[0057] A′=A+H(7)
[0058] Where H is the original data block, and A′={h′1,h′2,...,h′ n}, n=1,2,...N.
[0059] The essence of normalization is to standardize the data to prevent the gradient explosion phenomenon in the model during the training process, which will also make the loss function difficult to fit in the end. The formula involved is as follows:
[0060]
[0061] Step S2.4, feed-forward neural network layer:
[0062] The existence of the FeedForward Neural Network (FFN) layer performs a more complex nonlinear transformation on the output of the attention mechanism. The FeedForward Neural Network layer is a two-layer network, which first performs a linear transformation, then a nonlinear transformation using the ReLU activation function, and finally a linear transformation. The purpose of these two layers of networks is to map the input Z to a higher-dimensional space and then filter it through the nonlinear function ReLU, and then transform it back to the original dimension after filtering. This process can be expressed as:
[0063] FFN(A′)=max(0,w1A′+b1)w2+b2 (9)
[0064] Among them, w1 and b1 are the weight matrix and bias vector of the first linear transformation, and w2 and b2 are the weight matrix and bias vector of the second linear transformation.
[0065] After the attention mechanism, residual calculation and normalization, the flight time series trajectory information is processed through the feedforward neural network layer to capture more complex nonlinear relationships and patterns between features, and finally obtain trajectory information containing internal and external features. This provides a more accurate expression for the model to predict future trajectories.
[0066] Step S2.5, the second residual connection and normalization layer Layer-Norm2:
[0067] Residual connections and normalization are used again after the feedforward neural network layer. Residual connections are used to alleviate the gradient vanishing problem and ensure that the gradient can be transmitted more smoothly during the back propagation process, thereby accelerating the training of the model and retaining the characteristics of the original input information. This is especially important for deep networks. Normalization standardizes the residual connection results to make the input distribution of each layer more stable, thereby improving the stability and convergence speed of model training.
[0068] LayerNorm(A′)={A′+FFN(A′)}(10)
[0069] Step S2.6, projection operation layer Projection:
[0070] After being processed by the encoder stacked with attention layer, residual connection, normalization layer and feedforward neural network layer, the result is input into the multi-layer perceptron MLP for projection operation. The multi-layer perceptron includes input layer, hidden layer and output layer. Through linear and nonlinear combination, the different dimensions of the feature vector are fully crossed, so that the model can capture more nonlinear features and combined features, and remap the processed high-dimensional features to the target dimension. The multi-layer perceptron MLP is used to implement the projection operation to extract key features from high-dimensional features and remove redundant information to achieve more accurate prediction.
[0071]
[0072] in, represents the output of the embedding vector at layer L with a look-back window size of n. The prediction result of the flight trajectory includes information such as longitude, latitude, speed and altitude within several time steps in the future.
[0073] Step S3: Use the trained Transformer model to predict trajectories:
[0074] In order to demonstrate the technical effect of this model, this embodiment uses mean square error MSE, root mean square error REME and mean absolute error MAE to evaluate the prediction results. The formula is as follows:
[0075]
[0076] Among them, y i represents the predicted value, Represents the true value.
[0077] This example is trained on 452 flight data, and evaluated and predicted on the flight with ID CBJ5270-1619861400-schedule-0516:0. The MSE, REME and MAE are 0.01254, 0.07392 and 0.11199 respectively.
[0078] Step S4, visualize the trajectory prediction results:
[0079] The trajectory prediction results are saved using npy files, and the trajectory prediction results and the real trajectory data are loaded for visualization on the map. This embodiment uses the Folium library in python for visualization. First, the real trajectory data and the predicted trajectory data npy files are loaded. In this test, the flight trajectory of the flight with ID CBJ5270-1619861400-schedule-0516:0 is selected for visualization, and the feature longitude and latitude required for visualization are selected as input. The real and predicted trajectories are marked with different colors.
[0080] In addition, in some embodiments, a computer terminal storage medium is provided, storing computer terminal executable instructions, wherein the computer terminal executable instructions are used to execute the aviation trajectory prediction method based on multi-flight training and transposed input as described in the previous embodiments. Examples of computer storage media include magnetic storage media (e.g., floppy disks, hard disks, etc.), optical recording media (e.g., CD-ROMs, DVDs, etc.), or memories, such as memory cards, ROMs, or RAMs, etc. Computer storage media can also be distributed on network-connected computer systems, such as application stores.
[0081] In addition, in some embodiments, a computing device is proposed, comprising: at least one processor; and a memory connected to the at least one processor in communication; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the aviation trajectory prediction method based on multi-flight training and transposed input as described in the above embodiments. Examples of computing devices include PCs, tablet computers, smart phones, or PDAs.
[0082] In addition, in some embodiments, a computer program product is provided, and when the computer program is executed by a processor, the computer program implements the above-mentioned aviation trajectory prediction method based on multi-flight training and transposed input.
[0083] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. An aviation trajectory prediction method based on multi-flight training and transposed input, characterized in that: include: Collect flight data sets and perform data preprocessing; Build a Transformer model based on transposed input and train the model using preprocessed data; Use the trained Transformer model for trajectory prediction; Visualize the trajectory prediction results.
2. The aviation trajectory prediction method based on multi-flight training and transposed input according to claim 1, characterized in that: The data preprocessing includes: The collected flight data sets are grouped using the flight number as an index, and after the grouping process, each flight data is screened, wherein the screening process is the detection of the data length; Perform equidistant sampling, completion operations and data selection on the filtered flight data; The processed flight data set is divided into training set, validation set and test set in a certain proportion; the training set is used to train the model, the validation set is used to select and adjust the model parameters, and the test set is used to evaluate the model.
3. The aviation trajectory prediction method based on multi-flight training and transposed input according to claim 1, characterized in that: The Transformer model based on transposed input includes an Embedding layer, an attention layer, a first residual connection and a normalization layer, a feedforward neural network layer, a second residual connection and a normalization layer, and a projection operation layer connected in sequence.
4. The aviation trajectory prediction method based on multi-flight training and transposed input according to claim 3, characterized in that: Before the data is input into the Embedding layer of the Transformer model based on transposed input, a transposition operation is performed, and the entire sequence of each feature vector is used as a token.
5. The aviation trajectory prediction method based on multi-flight training and transposed input according to claim 4, characterized in that: The Embedding layer is implemented using a multi-layer perceptron MLP.
6. The aviation trajectory prediction method based on multi-flight training and transposed input according to claim 3, characterized in that: In the feedforward neural network layer, a linear transformation is first performed, then a nonlinear transformation is performed, and finally a linear transformation is performed again.
7. The aviation trajectory prediction method based on multi-flight training and transposed input according to claim 3, characterized in that: The projection operation layer uses a multi-layer perceptron MLP to perform projection operations.
8. A computer terminal storage medium storing computer terminal executable instructions, characterized in that: The computer terminal executable instructions are used to execute the aviation trajectory prediction method based on multi-flight training and transposed input as described in any one of claims 1-7.
9. A computing device, characterized in that: include: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the aviation trajectory prediction method based on multi-flight training and transposed input as described in any one of claims 1-7.
10. A computer program product, characterized in that When the computer program is executed by a processor, the aviation trajectory prediction method based on multi-flight training and transposed input according to any one of claims 1 to 7 is implemented.
Citation Information
Cited By
Urban traffic flow prediction method, system and product under complex road network condition
CN119939167A
Flight trajectory prediction method and system based on airspace information perception
CN122050207A