Next Article in Journal
Characterization of Breast Microcalcifications Using Dual-Energy CBCT: Impact of Detector Configuration on Imaging Performance—A Simulation Study
Previous Article in Journal
Measurement of Mass Flow Rates of Petrochemical Particles Based on an Electrostatic Coupled Capacitance Sensor
Previous Article in Special Issue
Research on Displacement Tracking Device Inside Hybrid Materials Based on Electromagnetic Induction Principle
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Aeromagnetic Compensation for UAVs Using Transformer Neural Networks

1
College of Information Engineering, Gan Dong University, Fuzhou 344000, China
2
College of Intelligent Robotics and Advanced Manufacturing, Fudan University, Shanghai 200433, China
3
College of GeoExploration Science and Technology, Jilin University, Changchun 130026, China
*
Author to whom correspondence should be addressed.
Sensors 2025, 25(22), 6852; https://doi.org/10.3390/s25226852 (registering DOI)
Submission received: 2 August 2025 / Revised: 17 October 2025 / Accepted: 6 November 2025 / Published: 9 November 2025

Abstract

In geophysics, aeromagnetic surveying based on unmanned aerial vehicles (UAV) is a widely employed exploration technique, that can analyze underground structures by conducting data acquisition, processing, and inversion. This method is highly efficient and covers large areas, making it widely applicable in mineral exploration, oil and gas surveys, geological mapping, and engineering and environmental studies. However, during flight, interference from the aircraft’s engine, electronic systems, and metal structures introduces noise into the magnetic data. To ensure accuracy, mathematical models and calibration techniques are employed to eliminate these aircraft-induced magnetic interferences. This enhances measurement precision, ensuring the data faithfully reflect the magnetic characteristics of subsurface geological features. This study focuses on aeromagnetic data processing methods, conducting numerical simulations of magnetic interference for aeromagnetic surveys of UAVs with the Tolles–Lawson (T-L) model. Recognizing the temporal dependencies in aeromagnetic data, we propose a Transformer neural network algorithm for aeromagnetic compensation. The method is applied to both simulated and measured flight data, and its performance is compared with the classical Multilayer Perceptron neural networks (MLP). The results demonstrate that the Transformer neural networks achieve better fitting capability and higher compensation accuracy.

1. Introduction

Aeromagnetic surveying is a method that uses magnetometers in aircraft for rapid, large-scale detection in geophysics. Aeromagnetic measurement can obtain physical quantities that reflect changes in the Earth’s magnetic field. Through data processing, local magnetic anomalies caused by mineral deposits, oil and gas reservoirs, or geological structures can be identified. Aeromagnetic surveys offer advantages such as high data acquisition efficiency and high resolution, making them widely applicable in mineral resource exploration, oil and gas investigations, fundamental geological mapping, and military target detection [1,2].
However, during aeromagnetic surveying, the presence of ferromagnetic materials in the airborne platform, along with various influencing factors during flight, affects data acquisition, subsequently impacts post-acquisition processing and geological interpretation. Therefore, compensation of the measured magnetic data is required [3,4]. The earliest aeromagnetic compensation methods primarily relied on hardware-based approaches. Tolles and Lawson established the classic aeromagnetic interference model (T-L model). There are three components in the interference field: permanent field, induced field, and eddy currents field. They also established a model called the compensation matrix for compensation coefficients solving [5]. This laid the foundation for aeromagnetic compensation. With early methods often involving the installation of counteracting magnets or coils on the aircraft to physically cancel out the permanent interference of the airframe and eddy currents interference generated during flight. With advancements in computer and electronic technologies, aeromagnetic compensation gradually shifted toward software-based methods. The aeromagnetic interference field can establish the T-L linear equation regarding attitude variation based on the T-L model, and then obtain the compensation coefficient through optimization solution. However, solving the T-L equation suffers from multicollinearity issues. To address this problem, a small-signal method proposed by Bickel can obtain more stable solutions by weakening linear dependencies between variables [6]. The most classical approach is least squares, known as the T-L compensation matrix method. However, the traditional solution methods have certain multicollinearity in the solution of the T-L equation, and the calculation of the compensation coefficient has a large calculation error. In order to improve the stability of the solution, Leach and Wu et al., respectively, adopted the ridge regression method and principal component analysis (PCA) to solve the aeromagnetic compensation coefficient [7,8].
The performance of drones employed in aeromagnetic surveys undoubtedly constitutes a critical factor affecting measurement data quality. The evolution of drone technology traces back to early 20th-century military target drone experiments. In 1916, American inventor Charles Kettering developed the “Kettering Bug,” an automatically controlled aerial bomb regarded as the prototype of modern drones [9]. During the 1930s, Britain created the “Queen Bee” target drone for anti-aircraft artillery training [10]. The Cold War witnessed rapid advancements in drone technology, with applications expanding into reconnaissance missions and tactical systems [11,12]. Since the 1990s, progress in GPS and composite materials technology drove the miniaturization and precision enhancement of drones [13]. The 21st century saw explosive growth in civilian drones, with French Parrot and Chinese DJI dominating the consumer market, while AI technology further catalyzed the development of autonomous flight systems [14,15,16]. With the development of artificial intelligence, drones are widely used in agriculture, remote sensing, communications, and other fields [17,18,19]. In the field of geophysics, a comprehensive overview of the applications of drone technology has been provided by Dimitris Perikleous et al. in geophysical exploration [20].
Since the 21st century, various intelligent algorithms have been applied to aeromagnetic compensation to further improve accuracy and adaptability in complex environments. Among these, neural network methods have been the most representative. In 1993, Williams pioneered a new aeromagnetic compensation by using neural networks, employing multi-layer backpropagation (BP) neural networks to model aircraft attitude variables, achieving compensation effects comparable to the traditional T-L model [21]. Ma et al. introduced unscented Kalman filtering into the solution of the T-L equation, effectively improving the compensation effect [22]. By 2022, Yu et al. introduced BP neural networks with residual connections to address gradient vanishing issues [23], while Jiao et al. achieved real-time compensation using backpropagation neural networks under limited computational power [24]. Additionally, Zhou et al. developed radial basis function neural networks (RBF-NN) to enhance generalization capability, thereby improving the precision of aeromagnetic compensation [25]. Although these methods improve the accuracy of aeromagnetic compensation to some extent, they do not take into account the time correlation of aeromagnetic data.
With the continuous development of deep neural networks, Transformer has been widely applied in fields such as time series prediction and natural language processing [26,27]. Since magnetic fields represent physical quantities that vary continuously over time, and optically pumped magnetometers typically measure magnetic fields at fixed sampling rates, their output signals inherently possess temporal characteristics [28,29]. To further enhance the accuracy of aeromagnetic compensation, this study employs Transformer neural networks for aeromagnetic compensation. The model effectively captures temporal dependencies, improves data fitting performance, and ultimately enhances compensation accuracy, as validated by both simulated and measured data.

2. Aeromagnetic Compensation Model and Methodology

2.1. Tolles and Lawson Model

When establishing the T-L model, it is necessary to clarify the corresponding relationship between the aircraft coordinate system and the geographic coordinate system. As shown in Figure 1, the position of the coordinate origin is defined as the center of the aeromagnetic measurement system. The geographic coordinate system is shown in the x-y-z black color coordinate system in Figure 1, while the aircraft coordinate system is shown in the xb-yb-zb yellow color coordinate system in Figure 1. The attitude changes in the drones during flight can be divided into three basic motions: pitches, rolls, and yaws, specifically, pitch angle θ , roll angle λ , and yaw angle ψ .
Based on the mechanisms of magnetic interference generation, the aeromagnetic interference was classified into three categories. The permanent field originates from hard magnetic materials (such as permanent magnets) and direct current closed circuits on the aircraft. Its intensity and direction do not change with flight attitude, remaining constant for a given aircraft. The induced field is caused by paramagnetic or soft materials magnetized by the earth’s magnetic field. The eddy current field is a transient interference caused by the aircraft’s metal structure cutting geomagnetic flux lines during motion. Its strength and direction depend on the geomagnetic gradient, maneuvering actions, and flight acceleration [5].
These three types of interference in the aircraft coordinate system would be expressed as follows:
H P = c 1 u 1 + c 2 u 2 + c 3 u 3
H i = T t ( c 4 u 1 2 + c 5 u 1 u 2 + c 6 u 1 u 3 + c 7 u 2 2 + c 8 u 2 u 3 + c 9 u 3 2 )
H e c = T t ( c 10 u 1 u 1 + c 11 u 2 u 1 + c 12 u 3 u 1 + c 13 u 1 u 3 + c 14 u 2 u 3 + c 15 u 3 u 3 + c 16 u 1 u 2 + c 17 u 2 u 2 + c 18 u 3 u 2 )
u 1 = T b x T t ,   u 2 = T b y T t ,   u 3 = T b z T t
T t = T b x 2 + T b y 2 + T b z 2
where T is the intensity of the geomagnetic field, c1, c2, ……, c18 are the compensation coefficients to be determined, u1, u2, and u3 denote the direction cosines, u 1 , u 2 , u 3 represent derivatives of these cosines with respect to time t, the total geomagnetic field is Tt, and Tbx, Tby, and Tbz are the triaxial components of the fluxgate sensor. Due to the lower measurement accuracy of triaxial fluxgate magnetometers compared to optically pumped magnetometers, as well as installation misalignments introducing additional errors, the triaxial fluxgate data may exhibit deviations, thereby affecting compensation performance. Therefore, this paper indirectly calculates the three-component geomagnetic field data based on the normal geomagnetic field and attitude angle information:
T b x T b y T b z = D T g x T g y T g z
D = cos θ cos ψ sin θ cos ψ sin ψ cos θ sin λ sin ψ sin θ cos λ sin θ sin λ sin ψ + cos θ cos λ sin λ cos ψ cos θ cos λ sin ψ + sin θ sin λ sin θ cos λ sin ψ cos θ sin λ cos λ cos ψ
T g x = T t cos φ cos μ
T g y = T t cos φ sin μ
T g z = T t cos φ sin φ ,
where μ is the magnetization bias angle, and φ is the magnetization tilt angle.
According to the above formulas, the total interference magnetic field Ht is expressed as follows:
H t = H p + H i + H e c = T t ( c 1 u 1 / T t + c 2 u 2 / T t + c 3 u 3 / T t + c 4 u 1 2 + c 5 u 1 u 2 + c 6 u 1 u 3 + c 7 u 2 2 + c 8 u 2 u 3 + c 9 u 3 2 + c 10 u 1 u 1 + c 11 u 2 u 1 + c 12 u 3 u 1 + c 13 u 1 u 3 + c 14 u 2 u 3 + c 15 u 3 u 3 + c 16 u 1 u 2 + c 17 u 2 u 2 + c 18 u 3 u ) ,
Moreover, since:
u 1 2 + u 2 2 + u 3 2 = 1 u 1 u 1 + u 2 u 2 + u 3 u 3 = 0 ,
we obtain:
H t = b 1 b 2 b 3 b 4 b 5 b 6 b 7 b 8 b 9 b 10 b 11 b 12 b 13 b 14 b 15 b 16 T u 1 / T t u 2 / T t u 3 / T t u 1 2 u 1 u 2 u 1 u 3 u 2 u 3 u 2 2 u 1 u 1 u 2 u 1 u 3 u 1 u 1 u 3 u 2 u 3 u 3 u 3 u 1 u 2 u 3 u 2 ,
where b1, b2, …, b16 are 16 compensation coefficients.
From the T-L method described above, it is apparent that H t is correlated with three components of the magnetic flux gate data, including their cosine and derivative values. Therefore, based on the T-L model, these parameters are selected as the input features of the neural networks. This paper does not require solving for T-L coefficients, but instead uses the neural network to find appropriate weights that transform input data into a correction that minimizes the noise (standard deviation) of the observed total field. We note that due to the lower measurement accuracy of triaxial fluxgate magnetometers compared to optically pumped magnetometers, the input three-component geomagnetic field data is calculated from the normal geomagnetic field and attitude angle information.

2.2. MLP Neural Networks

2.2.1. Multilayer Perceptron

The Multilayer Perceptron (MLP) is a traditional deep learning method based on the feedforward neural network architecture (as shown in Figure 2), consisting of three parts: the input layer, the hidden layer, and the output layer. The training of an MLP primarily relies on the backpropagation algorithm. Computing the gradient of the loss function of the network’s parameters and using gradient descent optimization, the weights are iteratively updated to minimize prediction errors.

2.2.2. Forward Propagation

Forward propagation is used to compute the output of neural networks. In MLP, the input to the first hidden layer comes from the input layer. The computation for this layer is as follows:
z 1 = w 1 x + b 1
a 1 = f z 1
where z 1 is the linear transformation result, w 1 is the first layer’s weight matrix, b 1 is the bias, and a 1 is the output of the activation function.
The calculation for the l -th layer (where l ranges from 2 to L − 1, and L is the total number of layers) is as follows:
z l = w l a l 1 + b l
a l = f z l
where z l is the linear transformation result, w l is the l-th layer’s weight matrix.
The calculation expression of the output layer is as follows:
z L = w L a L 1 + b L
y ^ = g z L
where z L is the output result, w L is the output layer’s weight matrix.
In this paper, the Mean Squared error (MSE) is adopted to define the loss function as follows:
L o s s = 1 N i = 1 N y i y ^ i 2

2.2.3. Backpropagation

The goal of backpropagation is to compute gradients to update the neural network’s weights, minimizing the loss function. First, the output layer error is calculated by taking the derivative of the L o s s with respect to z L as follows:
δ L = L o s s z L = y ^ y
a 1 = f z 1
Subsequently, the error propagates from the output layer to the hidden layers. The hidden layer error is calculated as follows:
δ l = w l + 1 T δ l + 1 f z l
a l = f z l
Compute the gradients:
L o s s w l = δ l a l 1 T
L o s s b l = δ l
Update the parameters (e.g., Adam, SGD):
w l = w l α L o s s w l
b l = b l α L o s s b l
Before training, all weights and biases need to be randomly initialized. During the training process, multiple iterations are required until the network converges, ultimately obtaining the optimal model.

2.3. Transformer Neural Networks

Transformer is a deep learning model based on a self-attention mechanism, and its main structure consists of an encoder and a decoder. Residual connections and layer normalization stabilize training. Transformers excel at capturing long-range dependencies and have become the foundation for state-of-the-art NLP models like BERT and GPT. Its model architecture is shown in Figure 3.

2.3.1. Forward Propagation

The core of the self-attention mechanism lies in computing attention weights for the input sequence and aggregating information based on these weights. First, calculate the Query ( Q ), Key ( K ), and Value ( V ) matrices. The input X R n × d is multiplied by learnable weight matrices W Q , W K , and W V respectively.
Q = X W Q , K = X W K , V = X W V
where Q represents the current position requiring attention computation, K serves to calculate similarity with other positions, and V contains the actual information used for weighted aggregation.
Computing the dot product between Q and K , and scaling by d k to prevent the problem of gradient vanishing or explosion, and then used to calculate the attention weights.
A = S o f t m a x Q K T d k
where A represents the attention weights from each position to all other positions.
Then computing weighted sum:
S = A V
A linear transformation is applied using a learnable weight matrix W O R d k × d .
O = S W O
Moreover, a residual connection structure is incorporated, which enables direct gradient flow during backpropagation, effectively mitigating the vanishing gradient problem. Layer normalization (LayerNorm) is then applied to each sample to stabilize the training process.
X a t t n = L a y e r N o r m X + O
Next, the output is processed through an FFN layer. Typically, the FFN consists of a two-layer fully connected network, which enhances the model’s nonlinear expressive capability. Finally, another residual connection is applied to obtain the final output.
H = R e L U X a t t n W 1 + b 1
F = H W 2 + b 2
X o u t = L a y e r N o r m X a t t n + F
where ReLU serves as the activation function; W 1 and W 2 are the weight matrices of the FFN layer, while b 1 and b 2 represent the bias terms.

2.3.2. Backpropagation

Firstly, Self-Attention Layer gradient calculation. The mathematical formulation of LayerNorm is expressed as follows:
X a t t n = γ X + O μ σ + β
where μ is the mean of X + O , σ is the standard deviation, and γ and β are the learnable scaling and shifting parameters, respectively.
Let the loss function be denoted as L , and the gradient of L with respect to X a t t n be denoted as L X a t t n . Then we obtain the following:
L X + O = L X a t t n γ 1 σ X + O μ 2 n σ 3
For the gradients of the residual connection and output projection, since X a t t n = L a y e r N o r m X + O , it follows that:
L O = L X + O
L X = L X + O
Moreover, since O = S W O , we obtain:
L W O = S T L O
L S = L O W O T
For gradient of attention weights, since S = A V , it follows that:
L A = L S V T
L Q K T / d k = L A d i a g A A A T
For gradient of, since A = S o f t m a x Q K T d k , we obtain:
L Q = 1 d k L Q K T / d k K
L K = 1 d k L Q K T / d k T Q
L V = A T L S
Thus, the gradients of W Q , W K , and W V are as follows:
L W Q = X T L Q , L W K = X T L K , L W V = X T L V
Secondly, compute the gradients for the FFN layer. The gradients for weight matrix W 2 and bias term b 2 are given by the following:
L W 2 = H T L F
L b 2 = L F
Since H = R e L U X a t t n W 1 + b 1 , we obtain:
L H = L F W 2 T
L X a t t n W 1 + b 1 = L H R e L U X a t t n W 1 + b 1
The gradients of the weight W 1 and biase b 1 are calculated as follows:
L W 1 = X a t t n T L X a t t n W 1 + b 1
L b 1 = L X a t t n W 1 + b 1
Thus, the gradients of X a t t n is as follows:
L X a t t n = L F + L X a t t n W 1 + b 1 W 1 T
Thirdly, computing gradients for LayerNorm Parameters. The gradients of γ and β are expressed as follows:
L γ = i = 1 n L X a t t n i X ^ i
L β = i = 1 n L X a t t n i
where X ^ i is the normalized result of the i-th sample.
Finally, gradient descent is applied to update the parameters. For example, the updated parameters θ is computed as follows:
θ = θ η L θ
where η is learning rate, θ ( W Q , W K , W V , W O , W 1 , b 1 , W 2 , b 2 ,   γ , β ) .

3. Simulation and Compensation

3.1. Experiment of Simulation

In actual aeromagnetic surveys, aeromagnetic compensation requires standardized flight maneuvers. This standardized flight method, known as the FOM (Figure of Merit Flight), designed by Leliak [30]. The FOM flight needs the aircraft to fly along predetermined directions. In each direction, it performs three sets of maneuvers: pitch, roll, and yaw. Each maneuver lasts approximately 5~10 s, with 5 s of level flight inserted between sets. With the development of drones, an alternative approach has emerged: drones can perform in-place motion to achieve the same effect as FOM flight during actual measurements.
This study simulates the attitude variations in a drone and configures 16 compensation coefficients, parameters such as attitude angles, the magnetization bias angle, the magnetization tilt angle et al. Meanwhile, appropriate noise was added during data simulation. Two datasets were generated and labeled as Data A and Data B. The three-axis fluxgate magnetometer components ( T b x , T b y , T b z ) and the total magnetic interference ( H t ) for these datasets are illustrated in Figure 4 and Figure 5.

3.2. Compensation Results

This paper selects standard deviation (STD) and improvement ratio (IR) to evaluate the effect of aeromagnetic compensation, and then compares and analyzes the effectiveness of the methods.
S T D = 1 n i = 1 n ( μ μ ¯ )
where n is the sample number, μ represents the sample value, and μ ¯ is the mean of μ .
The improvement ratio is calculated by STDs as follows:
I R = S T D u S T D c
where S T D u and S T D c are the uncompensated magnetic data and compensated data, respectively.
In this study, the simulated datasets Data A and Data B were alternately used as the training set and test set. Considering that the compensation accuracy of traditional linear methods (such as least squares method, LS) is not as good as that of neural network methods [23], this paper adopts MLP to compare with Transformer. The aforementioned two neural networks were employed for compensation, with the results depicted in Figure 6 and Figure 7. The figures demonstrate the following: First, neural network-based compensation achieves significant improvement. Second, the Transformer model outperforms MLP in compensation effectiveness. Meanwhile, a quantitative comparison is provided in Table 1, showing that: For Transformer, the standard deviation of compensated data is smaller than MLP, and the improvement rate is higher. These results confirm the better performance of the Transformer networks for compensation tasks on simulated data.

4. Field-Measured Data Compensation

4.1. Flight of Compensation

To meet the hypothetical conditions of the T-L model, this study conducted FOM flights using a DJI M300RTK quadcopter UAV equipped with an airborne magnetic survey system (as shown in Figure 8) in a designated area of Suqian City, Jiangsu Province, China. Here we employ a miniature rubidium optically pumped magnetometer, with its main performance parameters shown in Table 2.
Two FOM flights were conducted in this study, which selected sites with features such as flat terrain, minimal geomagnetic variations, and an absence of interference sources (e.g., high-voltage power lines) and acquired two datasets labeled as Data C and Data D, shown in Figure 9 and Figure 10.

4.2. Compensation Results

Similarly, the measured datasets Data C and Data D were alternately used as the training set and test set. The aforementioned two neural networks were employed for compensation, with the results depicted in Figure 11 and Figure 12. Meanwhile, a quantitative comparison is provided in Table 3. These results also confirm the better performance of the Transformer neural networks for compensation tasks on measured data.

5. Conclusions

In conventional aeromagnetic compensation tasks, linear regression algorithms have traditionally dominated. While the standard MLP neural network exhibits stronger fitting capabilities than linear regression and offers some improvement in compensation accuracy, it remains a global approximation neural network with limited generalization ability. Issues such as gradient vanishing further constrain its precision gains for aeromagnetic compensation. To enhance compensation accuracy, this study builds upon the T-L model and proposes a Transformer neural network-based aeromagnetic compensation method. The approach captures temporal dependencies in the data, further refining compensation precision. The feasibility of this method was validated through experiments on simulated and measured flight data. The development of high-precision aeromagnetic compensation methods also provides important support for the application of unmanned aerial vehicle aeromagnetic measurement technology in fields such as metal mine detection and military target detection in the later stage.

Author Contributions

Conceptualization, W.D.; methodology, writing, W.D. and C.Y.; supervision, S.Z. All authors have read and agreed to the published version of the manuscript.

Funding

This work was supported by Science Foundation of Jiang-Xi Educational Committee (GJJ2403801), Ph.D. Programs Foundation of Ministry of GanDong College (No. 122000801).

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

The original contributions presented in this study are included in the article. Further inquiries can be directed to the corresponding author.

Acknowledgments

The authors would like to thank the editors and reviewers for providing their valuable comments and suggestions.

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Yang, J.; Chen, J.; Yang, Z. EnergyEfficient UAV Communication with Trajectory Optimization. In Proceedings of the 2021 2nd International Conference on Big Data & Artificial Intelligence & Software Engineering (ICBASE), Zhuhai, China, 24–26 September 2021; pp. 508–514. [Google Scholar]
  2. Zheng, Y.; Li, S.; Xing, K.; Zhang, X. Unmanned Aerial Vehicles for Magnetic Surveys: A Review on Platform Selection and Interference Suppression. Drones 2021, 5, 93. [Google Scholar] [CrossRef]
  3. Yang, S.L.; Li, F.L.; Huang, J.J.; Wang, J.; Huang, M.N.; Wang, X.; Zhou, Q. History and Prospects of Aeromagnetic Compensation Technologies Used in China and Abroad. Geophys. Geochem. Explor. 2017, 41, 694–699. [Google Scholar]
  4. Xiong, S.Q. Innovation and application of airborne geophysical exploration technology. J. Geomech. 2020, 26, 791–818. [Google Scholar]
  5. Tolles, W.E.; Lawson, J.D. Magnetic Compensation of MAD Equipped Aircraft; Airborne Instruments Lab. Inc.: Mineola, NY, USA, 1950; pp. 201–211. [Google Scholar]
  6. Bickel, S. Small Signal Compensation of Magnetic Fields Resulting from Aircraft Maneuvers. IEEE Trans. Aerosp. Electron. Syst. 1979, AES-15, 518–525. [Google Scholar] [CrossRef]
  7. Leach, B.W. Aeromagnetic compensation as a linear regression problem. In Information Linkage Between Applied Mathematics and Industry II; Academic Press: London, UK, 1980; pp. 139–161. [Google Scholar]
  8. Wu, P.; Zhang, Q.; Chen, L.; Zhu, W.; Guangyou, F. Aeromagnetic Compensation Algorithm Based on Principal Component Analysis. J. Sens. 2018, 2018, 5798287. [Google Scholar] [CrossRef]
  9. Newcome, L.R. Unmanned Aviation: A Brief History of Unmanned Aerial Vehicles; American Institute of Aeronautics and Astronautics: Reston, VA, USA, 2004. [Google Scholar]
  10. Everett, H.R. Unmanned Systems of World Wars I and II; MIT Press: Cambridge, MA, USA, 2015. [Google Scholar]
  11. Wagner, W. Lightning Bugs and Other Reconnaissance Drones. Armed Forces J. Int. 1982, 120, 45–52. [Google Scholar]
  12. Gertler, J.U.S. Unmanned Aerial Systems; R42136; Congressional Research Service Report for Congress: Washington, DC, USA, 2012.
  13. Nonami, K.; Kendoul, F.; Suzuki, S.; Wang, W.; Nakazawa, D. Autonomous Flying Robots: Unmanned Aerial Vehicles and Micro Aerial Vehicles, 1st ed.; Springer: Tokyo, Japan, 2010. [Google Scholar] [CrossRef]
  14. Floreano, D.; Wood, R.J. Science, Technology and the Future of Small Autonomous Drones. Nature 2015, 521, 460–466. [Google Scholar] [CrossRef]
  15. Clothier, R.A.; Greer, D.A.; Greer, D.G.; Mehta, A.M. Risk Perception and the Public Acceptance of Drones. Risk Anal. 2015, 35, 1167–1183. [Google Scholar] [CrossRef]
  16. Sánchez-Soriano, J.; Rojo-Gala, M.Á.; Pérez-Pérez, G.; Bemposta Rosende, S.; Gordo-Herrera, N. Optimized Autonomous Drone Navigation Using Double Deep Q-Learning for Enhanced Real-Time 3D Image Capture. Drones 2024, 8, 725. [Google Scholar] [CrossRef]
  17. Guo, A.; Huang, W.; Dong, Y.; Ye, H.; Ma, H.; Liu, B.; Wu, W.; Ren, Y.; Ruan, C.; Geng, Y. Wheat Yellow Rust Detection Using UAV-Based Hyperspectral Technology. Remote Sens. 2021, 13, 123. [Google Scholar] [CrossRef]
  18. Zuo, L.; Gao, S.; Li, Y.; Li, L.; Li, M.; Lu, X. A Fast and Robust Algorithm with Reinforcement Learning for Large UAV Cluster Mission Planning. Remote Sens. 2022, 14, 1304. [Google Scholar] [CrossRef]
  19. Subbarayalu, V.; Vensuslaus, M.A. An Intrusion Detection System for Drone Swarming Utilizing Timed Probabilistic Automata. Drones 2023, 7, 248. [Google Scholar] [CrossRef]
  20. Perikleous, D.; Margariti, K.; Velanas, P.; Blazquez, C.S.; Gonzalez-Aguilera, D. Aerial Drones for Geophysical Prospection in Mining: A Review. Drones 2025, 9, 383. [Google Scholar] [CrossRef]
  21. Williams, P.M. Aeromagnetic Compensation Using Neural Networks. Neural Comput. Appl. 1993, 1, 207–214. [Google Scholar] [CrossRef]
  22. Ma, M.; Zhou, Z.; Cheng, D. A Dual Estimate Method for Aeromagnetic Compensation. Meas. Sci. Technol. 2017, 28, 115904. [Google Scholar] [CrossRef]
  23. Yu, P.; Bi, F.; Jiao, J.; Zhao, X.; Zhou, S.; Su, Z. An Aeromagnetic Compensation Algorithm Based on a Residual Neural Network. Appl. Sci. 2022, 12, 10759. [Google Scholar] [CrossRef]
  24. Jiao, J.; Yu, P.; Zhao, X.; Bi, F. Real-Time Aeromagnetic Compensation With Compressed and Accelerated Neural Networks. IEEE Geosci. Remote Sens. Lett. 2022, 19, 8025905. [Google Scholar] [CrossRef]
  25. Zhou, S.; Yang, C.; Su, Z.; Yu, P.; Jiao, J. An Aeromagnetic Compensation Algorithm Based on Radial Basis Function Artificial Neural Network. Appl. Sci. 2023, 13, 136. [Google Scholar] [CrossRef]
  26. Vaswani, A.; Shazeer, N.; Parmar, N.; Uszkoreit, J.; Jones, L.; Gomez, A.N.; Kaiser, L.; Polosukhin, I. Attention is all you need. In Proceedings of the 31st International Conference on Neural Information Processing Systems, Long Beach, CA, USA, 2–6 December 2024; Curran Associates Inc.: Red Hook, NY, USA, 2017; pp. 6000–6010. [Google Scholar]
  27. Wu, H.; Xu, J.; Wang, J.; Long, M. Autoformer: Decomposition transformers with auto-correlation for long-term series forecasting. In Proceedings of the 35th International Conference on Neural Information Processing Systems, Los Angeles, CA, USA, 6–14 December 2021; p. 1717. [Google Scholar]
  28. Lv, Y.; Duan, Y.; Kang, W.; Li, Z.; Wang, F.Y. Traffic Flow Prediction With Big Data: A Deep Learning Approach. IEEE Trans. Intell. Transp. Syst. 2015, 16, 865–873. [Google Scholar] [CrossRef]
  29. Qin, Y.; Song, D.; Cheng, H.; Cheng, W.; Jiang, G.; Cottrell, G.W. A dual-stage attention-based recurrent neural network for time series prediction. In Proceedings of the 26th International Joint Conference on Artificial Intelligence, Melbourne, Australia, 19–25 August 2017; pp. 2627–2633. [Google Scholar]
  30. Leliak, P. Identification and evaluation of magnetic-field sources of magnetic airborne detector equipped aircraft. IRE Trans. Aerosp. Navig. Electr. 1961, 3, 95–105. [Google Scholar] [CrossRef]
Figure 1. The transformation relationship of coordinate systems.
Figure 1. The transformation relationship of coordinate systems.
Sensors 25 06852 g001
Figure 2. MLP neural networks model diagram.
Figure 2. MLP neural networks model diagram.
Sensors 25 06852 g002
Figure 3. Transformer model diagram.
Figure 3. Transformer model diagram.
Sensors 25 06852 g003
Figure 4. Data A.
Figure 4. Data A.
Sensors 25 06852 g004
Figure 5. Data B.
Figure 5. Data B.
Sensors 25 06852 g005
Figure 6. Data A compensation result.
Figure 6. Data A compensation result.
Sensors 25 06852 g006
Figure 7. Data B compensation result.
Figure 7. Data B compensation result.
Sensors 25 06852 g007
Figure 8. Unmanned aerial vehicles and equipment.
Figure 8. Unmanned aerial vehicles and equipment.
Sensors 25 06852 g008
Figure 9. Data C.
Figure 9. Data C.
Sensors 25 06852 g009
Figure 10. Data D.
Figure 10. Data D.
Sensors 25 06852 g010
Figure 11. Data C compensation result.
Figure 11. Data C compensation result.
Sensors 25 06852 g011
Figure 12. Data D compensation result.
Figure 12. Data D compensation result.
Sensors 25 06852 g012
Table 1. Compensation results of the simulation data.
Table 1. Compensation results of the simulation data.
Test SetTraining SetMethod S T D p S T D f IR
Data AData BMLP5.590.06982.45
Transformer0.06586.40
Data BData AMLP5.580.07475.38
Transformer0.06586.38
Table 2. Parameters of miniature rubidium optically pumped magnetometer.
Table 2. Parameters of miniature rubidium optically pumped magnetometer.
Measuring Range1000~100,000 nT
Gradient Capacity100 nT/cm
Ground Static Noise Level≤0.01 nT
Resolution0.0001 nT
Sensitivity0.02 nT/ Hz
Power Consumption≤3 W
Operating Remperature−30~+60 °C
Table 3. Simulation model parameters.
Table 3. Simulation model parameters.
Test SetTraining SetMethod S T D p S T D f IR
Data DData CMLP6.210.1731.13
Transformer0.1336.43
Data CData DMLP6.420.1640.94
Transformer0.1446.57
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Dai, W.; Yang, C.; Zhou, S. Aeromagnetic Compensation for UAVs Using Transformer Neural Networks. Sensors 2025, 25, 6852. https://doi.org/10.3390/s25226852

AMA Style

Dai W, Yang C, Zhou S. Aeromagnetic Compensation for UAVs Using Transformer Neural Networks. Sensors. 2025; 25(22):6852. https://doi.org/10.3390/s25226852

Chicago/Turabian Style

Dai, Weiming, Changcheng Yang, and Shuai Zhou. 2025. "Aeromagnetic Compensation for UAVs Using Transformer Neural Networks" Sensors 25, no. 22: 6852. https://doi.org/10.3390/s25226852

APA Style

Dai, W., Yang, C., & Zhou, S. (2025). Aeromagnetic Compensation for UAVs Using Transformer Neural Networks. Sensors, 25(22), 6852. https://doi.org/10.3390/s25226852

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Article metric data becomes available approximately 24 hours after publication online.
Back to TopTop