Aerial small target detection method applied to unmanned aerial vehicle
By improving the multi-module collaborative design in the RFA-DETR model, the accuracy and real-time performance issues in small target detection in UAV aerial photography were resolved, achieving efficient and lightweight aerial small target detection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HUAIYIN INSTITUTE OF TECHNOLOGY
- Filing Date
- 2026-01-16
- Publication Date
- 2026-05-12
AI Technical Summary
Traditional UAV aerial photography methods for small target detection suffer from low accuracy and high computational load in scenarios with insufficient feature information of small targets, complex background interference, and dense small target scenes, making it difficult to achieve real-time detection.
An improved RFA-DETR model is adopted, and dynamic feature extraction, frequency domain contrast-driven feature enhancement, and hierarchical context integration are performed through the DDCSM module, HWD-TPA module, BDFEAN network module, and HLACI module to build an end-to-end lightweight detection framework.
It significantly improves the accuracy and speed of small target detection, reduces the computational load, achieves efficient real-time detection, and greatly reduces the false detection rate and missed detection rate, making it suitable for UAV platform applications.
Smart Images

Figure CN122023769A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of small target detection technology, and specifically to a method for detecting small aerial targets applied to unmanned aerial vehicles (UAVs). Background Technology
[0002] Traditional methods for small target detection in aerial drones mainly rely on hand-designed feature extraction techniques, such as Scale Invariant Feature Transform (SIFT) and Speed-Up Robust Feature Transform (SURF). However, with the rapid development of machine learning and deep learning technologies, the field of small target detection in aerial drones has seen a major breakthrough.
[0003] Currently, deep learning-based object detection algorithms are mainly divided into two categories: two-stage detectors and single-stage detectors. Two-stage detectors, such as the R-CNN series, first generate candidate regions, and then classify and regress bounding boxes for these regions. These methods typically have high detection accuracy and low false negative rates, but are slow and computationally expensive, making them unsuitable for real-time detection applications. Single-stage detectors, such as the YOLO series and SSD, directly predict the target location and category, offering advantages such as high speed and low computational load, but relatively lower accuracy.
[0004] With the application of the Transformer architecture in the field of vision, Transformer-based detectors such as the DETR series provide end-to-end solutions that do not require non-maximum suppression (NMS). Despite the significant progress made in target detection technology, small target detection in aerial drones still faces many challenges. For example: (1) Insufficient and easily lost feature information of small targets; with the increase of network depth and multiple convolution operations, small targets often lose a large amount of key feature information, making it difficult to detect and recognize them in high-level feature maps. (2) Complex background interference and dense small target scenes: Aerial images usually contain a lot of background information, such as buildings, trees and roads. This complex and diverse background information may interfere with the correct detection of small targets. In addition, targets in aerial images are often densely distributed, with serious occlusion and overlap, which increases the difficulty of detection. Summary of the Invention
[0005] To address the technical challenge of small target detection in UAV aerial photography scenarios, this technical solution provides a method for small aerial target detection applied to UAVs. It creates an improved RFA-DETR model, which effectively solves the limitations of traditional detectors through the DDCSM module, HWD-TPA module, BDFEAN network module, and HLACI module in the model.
[0006] This invention is achieved through the following technical solution:
[0007] A method for detecting small aerial targets applied to unmanned aerial vehicles (UAVs) includes the following steps:
[0008] Step 1: Create the RFA-DETR improved model, which includes the DDCSM module, HWD-TPA module, BDFEAN network module, and HLACI module;
[0009] Step 2: Preprocess the images taken by the drone and transmit the processed images to the RFA-DETR improved model;
[0010] Step 3: Perform dynamic feature extraction using the DDCSM module;
[0011] Step 4: Feature Encoding and Preliminary Fusion;
[0012] Step 5: Perform frequency domain contrast-driven feature enhancement using the HWD-TPA module;
[0013] Step Six: Perform spatial-frequency dual-domain feature fusion and enhancement using the BDFEAN network module;
[0014] Step 7: Use the HLACI module for hierarchical context integration;
[0015] Step 8: Target detection and output the final detection results.
[0016] Furthermore, the creation of the RFA-DETR improved model described in step one is an optimization of the RT-DETR model, and the optimization method is as follows:
[0017] In the feature extraction stage, the DDCSM module is used to replace the ResNet backbone network in the RT-DETR model. Through dynamic receptive field and multi-path feature interaction mechanism, the network's ability to perceive small targets is enhanced. The DDCSM module adopts the CSP idea combined with the dynamic receptive field strategy to adaptively adjust the spatial range of feature extraction, thereby reducing the number of parameters and computational complexity while maintaining the model's expressive power.
[0018] In the feature fusion and enhancement stage, three complementary modules are introduced: HWD-TPA, BDFEAN, and HLACI. The HWD-TPA module uses Haar wavelet transform to achieve frequency domain decomposition of features and designs a dual-path attention mechanism driven by high-frequency foreground information and low-frequency background information, respectively, to achieve adaptive enhancement of the boundaries and internal details of small targets. The BDFEAN module constructs a multi-path, multi-domain feature enhancement framework, simultaneously enhancing features in the spatial and frequency domains to improve the feature representation ability of small targets. The HLACI module combines a local-global dual attention mechanism and an adaptive feature guidance strategy to enhance the model's ability to detect small targets.
[0019] The optimized RFA-DETR improved model includes four core components: (1) a dynamic backbone network based on DDCSM, (2) a contrast-driven feature aggregation module based on HWD-TPA, (3) a space-frequency dual-domain attention network based on BDFEAN, and (4) a hierarchical attention fusion module based on HLACI.
[0020] Furthermore, the dynamic feature extraction using the DDCSM module described in step three is specifically performed as follows: channel mapping is performed through 1×1 convolution to map the input features to a higher-dimensional representation space, and the features are divided into two branches for processing. The first branch directly transmits the original feature information, and the second branch performs dynamic feature extraction through a concatenated DIMBlock.
[0021] The DIMBlock module combines Transformer and CNN, employing a two-branch architecture including a feature mixing branch and a feature transformation branch, both supplemented by residual connections; given input features The workflow of the DIMBlock module is as follows:
[0022] ;
[0023]
[0024] in, and is a learnable hierarchical scaling parameter, initialized to a small value to ensure the stability of residual learning in the early stages of training; DropPath is a stochastic depth regularization technique that enhances the model's generalization ability by randomly discarding some paths during training; BN represents batch normalization; DIM is used to capture multi-scale features, first dividing the features equally along the channel dimension, and then processing each group of features through DynamicInceptionDWConv2d with different configurations; ConvolutionalGLU introduces a gating mechanism, enabling the network to adaptively select and enhance informative feature channels while suppressing irrelevant noisy features.
[0025] Furthermore, the DIMBlock module includes three core components: DIM multi-scale extraction, DIDWConv dynamic receptive field convolution, and ConvolutionalGLU gating mechanism.
[0026] The DIDWConv module integrates three different types of depthwise separable convolutions, including standard square convolutions such as 3×3, and two rectangular convolutions: 1×11 and 11×1, to capture feature patterns of different orientations and scales.
[0027] Given input features First, dynamic kernel weights are generated using global average pooling and 1×1 convolution, resulting in a tensor W of shape 3C×1×1; then, W is reshaped into three tensors. Finally, the Softmax function is applied to the three tensors to obtain three attention weight coefficients α1, α2, and α3; the workflow is as follows:
[0028] ;
[0029] ;
[0030]
[0031] Then apply three types of depthwise convolution and weighted fuse them:
[0032] ;
[0033] in, Indicates the size of the square convolution kernel. This indicates the size of the bar convolution kernel, and GAP indicates global average pooling.
[0034] Furthermore, step three outputs multi-scale features S3, S4, and S5, which correspond to different spatial resolutions and semantic levels. Step four applies the AIFI module to the highest-level feature S5 for attention-based scale feature interaction, and fuses the features of three different scales, S3, S4, and S5, through the CCFF module to output encoded multi-scale features P3, P4, and P5.
[0035] Furthermore, the HWD-TPA module described in step five constructs a cascaded dual-path attention mechanism: the high-frequency path first focuses on the target boundary and texture details, enhancing the local features of small targets; while the low-frequency path focuses on the global context, using structural information to further refine and improve the target representation.
[0036] The HWD-TPA module guides feature aggregation using frequency domain information from wavelet decomposition; given input features First, the input features are preliminarily processed using two cascaded 3×3 convolutional blocks. Then, the Haar wavelet transform is applied to decompose the features. The HaarWaveletConv module implements a differentiable version of the two-dimensional Haar wavelet transform for frequency domain decomposition of the features.
[0037]
[0038] in, Indicates low-frequency background components. Indicates high-frequency foreground components;
[0039] The features are rearranged into a spatial-channel order and a value projection is generated. Then, a sliding window expansion operation is applied to the value features to generate a local receptive field, represented as follows:
[0040] ;
[0041] ;
[0042]
[0043] in, For the number of attention heads, For the size of the core, This represents the number of spatial positions after unfolding. This represents the sliding window expansion operation, followed by a two-stage attention mechanism; firstly, the high-frequency foreground attention stage captures detailed features:
[0044]
[0045] in, This indicates a channel rearrangement operation. Indicates average pooling. For the Softmax function, For linear projection transformation, The scaling factor is used; feature aggregation is achieved in the following ways:
[0046]
[0047] in, and These represent projection and folding operations, respectively. Weighting attention; similarly, enhancing context awareness during low-frequency background attention phases:
[0048] ;
[0049] ;
[0050] ;
[0051] in, Indicates feature expansion operation, Linear transformation of background features and Rearrange operations for different channels.
[0052] Furthermore, the BDFEAN network module described in step six includes two fusion paths: a top-down path in the FPN part of the network and a bottom-up path in the PAN part of the network.
[0053] The top-down path first aligns the channels of each level of features through 1×1 convolution, and then uses the MultiScalePCA module to fuse features from adjacent layers. This module calculates channel attention weights through adaptive 1D convolution and weights and fuses the upsampled low-resolution features. The fused features are then enhanced in two domains using the FSA module. FSA includes an AGF adaptive global frequency filtering branch and an SA spatial attention branch, which enhance the features in the frequency domain and spatial domain, respectively.
[0054] In the bottom-up path of the PAN part of the network, the MultiScalePCA_Down module is used to realize feature downsampling fusion, which retains important low-level feature information. The FSA module is also used to further enhance the discriminative ability of features, thus constructing a complete bidirectional feature extraction network.
[0055] Furthermore, the MultiScalePCA module introduces an adaptive channel attention mechanism, enabling the network to dynamically learn the importance of features at different scales. Subsequently, one-dimensional convolution is used to establish long-distance dependencies between channels, achieving adaptive upsampling feature fusion based on channel attention. This module receives two feature maps of different scales as input and achieves efficient feature fusion through channel-level attention mechanism and transposed convolution.
[0056] The MultiScalePCA_Down module is specifically designed to implement feature fusion for bottom-up paths. This module takes two feature maps of different scales as input and achieves efficient feature downsampling fusion through channel attention and downsampling convolution.
[0057] The FSA module consists of two parallel branches: Adaptive Global Frequency Filter (AGF) and Spatial Attention (SA), enabling the network to utilize complementary information from both the frequency and spatial domains. The AGF branch enhances the frequency characteristics of small targets from a global spectral perspective, while the SA branch emphasizes salient regions from a local spatial perspective, thereby enhancing feature representation in both the spatial and frequency domains and improving the salience of small targets.
[0058] Furthermore, the AGF branch achieves selective enhancement of the feature spectrum through frequency domain transformation and adaptive filtering; first, the features are transformed to the frequency domain, then low-pass and high-pass frequency masks are constructed, followed by the extraction of low-frequency and high-frequency components, and a learnable complex weighted filter is applied to the low-frequency part. Finally, the inverse transformation is used to return to the spatial domain;
[0059] The SA branch generates a spatial attention map using channel statistics, emphasizing spatial contextual relationships.
[0060] Furthermore, the HLACI module described in step seven receives two feature maps from different levels. After feature projection, the HLACI module performs feature enhancement through parallel multi-path processing. The basic feature fusion path combines the two features through a simple and effective additive fusion operation, and then uses grouped convolution to extract the mixed features.
[0061] ;
[0062] in, For parameters of Grouped convolution operation, with 4 groups;
[0063] The local-global attention enhancement path applies local attention (receptive field of 2) and global attention (receptive field of 4) to each projected feature:
[0064] ;
[0065] ;
[0066] in, and These represent the local and global attention functions, respectively. For the corresponding parameter set; attention mechanism Specifically implemented in the LocalGlobalAttention class;
[0067] For input features First, feature region segmentation is performed, dividing the input features into... The size is The local region is then analyzed; then, regional statistical features are extracted, and the statistics for each region are calculated; subsequently, nonlinear feature transformation is performed, and the feature representation is enhanced through a multilayer perceptron, while attention weights are generated and used to weight and enhance the features.
[0068] ;
[0069] ;
[0070] ;
[0071] in, and For a multilayer perceptron, LayerNorm is the layer normalization operation;
[0072] Next, we will use learnable cue vectors Calculate feature correlation to achieve adaptive feature selection; where express The normalization result, This indicates element-wise multiplication;
[0073] ;
[0074] Feature size is recovered through a learnable transformation matrix and upsampling operations. It is a learnable transformation matrix; For shape reconstruction operations, For bilinear interpolation upsampling, for convolution;
[0075] ;
[0076] ;
[0077] Finally, the HLACI module concatenates all enhanced features and fuses them through a series of efficient convolutional operations; HLACI introduces a dual-path attention mechanism, simultaneously capturing local fine features (receptive field of 2) and global contextual information (receptive field of 4); through formal analysis, this mechanism is expressed as:
[0078]
[0079] in, This indicates a feature fusion operation. and These represent the local and global attention functions, respectively.
[0080] Beneficial effects
[0081] The present invention proposes an aerial small target detection method for unmanned aerial vehicles (UAVs), which, compared with existing technologies, has the following advantages:
[0082] (1) The improved RFA-DETR model of this technical solution includes the DDCSM module, HWD-TPA module, BDFEAN network module, and HLACI module. These four modules constitute a feature processing pipeline from coarse to fine and from superficial to in-depth: DDCSM coarse extraction, HWD-TPA fine separation, BDFEAN strong enhancement, and HLACI optimal integration. This progressive design avoids the performance bottleneck of traditional single modules. Each stage focuses on solving a core sub-problem, and the overall performance shows a multiplier effect rather than simple superposition, ensuring that features are continuously optimized during processing. At the same time, the complementarity of four information dimensions is utilized: spatial domain (receptive field adjustment), frequency domain (wavelet decomposition and AGF filtering), channel domain (channel attention), and spatiotemporal domain (local-global attention). This multi-dimensional collaboration enables the model to capture small target features from different angles, significantly reducing the false negative rate. Experiments show that the small target detection accuracy of the complete model reaches 12.8%, which is 1.7 percentage points higher than the baseline of 11.1%, and the accuracy is improved by 15.3%.
[0083] (2) This technical solution successfully achieves a dual improvement in efficiency and accuracy through a lightweight strategy; DDCSM adopts a CSP architecture and dynamic convolution to reduce redundant computation, HWD-TPA uses dual-path attention to share computational resources, BDFEAN uses grouped convolution and one-dimensional convolution to reduce the number of parameters, and HLACI uses adaptive filtering to reduce invalid computation. In the end, the number of parameters is reduced by 31.2% from 19.9M to 13.7M, the computation amount is reduced by 12.3% from 57G to 50G, while AP50 is improved by 2.4%.
[0084] (3) This technical solution benefits from the Transformer architecture and four-module feature optimization to achieve true end-to-end detection. No NMS post-processing is required, and the inference speed is not affected; it directly outputs high-quality detection results, avoiding the complexity of NMS threshold parameter tuning; it is particularly suitable for UAV application scenarios with high real-time requirements. This design not only simplifies the deployment process, but also improves system stability and reliability.
[0085] (4) The DDCSM module in this technical solution enhances the perception capability of small targets by utilizing a dynamic receptive field strategy; the HWD-TPA module strengthens the target feature representation by using frequency domain contrast information; the BDFEAN architecture performs feature enhancement in both the spatial and frequency domains; and the HLACI module optimizes multi-scale target detection through a hierarchical attention mechanism. This provides an efficient and practical solution for real-time small target detection on UAV platforms, which is of great significance for promoting the practical application of related technologies. Visualization results verify that RFA-DETR can effectively detect small targets in complex backgrounds, reducing false detections and missed detections. Attached Figure Description
[0086] Figure 1This is a schematic diagram of the overall process of the present invention.
[0087] Figure 2 This is a structural diagram of the improved RFA-DETR model in this invention.
[0088] Figure 3 This is a structural diagram of the DDCSM module in this invention.
[0089] Figure 4 This is a structural diagram of the DIDWConv module in this invention.
[0090] Figure 5 This is a structural diagram of the HWD-TPA module in this invention.
[0091] Figure 6 This is a structural diagram of the MultiScalePCA module in this invention.
[0092] Figure 7 This is a structural diagram of the FSA module in this invention.
[0093] Figure 8 This is a structural diagram of the HLACI module in this invention.
[0094] Figure 9 This is a structural diagram of the LocalGlobalAttention module in this invention.
[0095] Figure 10 This is a thermodynamic comparison diagram of the baseline RT-DETR and the improved RFA-DETR model in the experiment of this invention.
[0096] Figure 11 This is a comparison chart of the detection results of the baseline RT-DETR and the improved RFA-DETR model in the experiment of this invention. Detailed Implementation
[0097] The technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments. The described embodiments are merely some embodiments of the present invention, and not all embodiments. Various modifications and improvements made to the technical solutions of the present invention by those skilled in the art without departing from the design concept of the present invention should fall within the protection scope of the present invention.
[0098] Example 1:
[0099] like Figure 1 As shown, a method for detecting small aerial targets applied to unmanned aerial vehicles includes the following steps:
[0100] Step 1: Create the improved RFA-DETR model, which includes the DDCSM module, HWD-TPA module, BDFEAN network module, and HLACI module. The improved RFA-DETR model is based on the RT-DETR-R18 model and is optimized as follows: Figure 2 As shown. The optimization method is as follows:
[0101] In the feature extraction stage, the DDCSM module is used to replace the ResNet backbone network in the RT-DETR model. Through dynamic receptive field and multi-path feature interaction mechanism, the network's ability to perceive small targets is enhanced. The DDCSM module adopts the CSP idea combined with the dynamic receptive field strategy to adaptively adjust the spatial range of feature extraction, thereby reducing the number of parameters and computational complexity while maintaining the model's expressive power.
[0102] In the feature fusion and enhancement stage, three complementary modules are introduced: HWD-TPA, BDFEAN, and HLACI. The HWD-TPA module uses Haar wavelet transform to achieve frequency domain decomposition of features and designs a dual-path attention mechanism driven by high-frequency foreground information and low-frequency background information, respectively, to adaptively enhance the boundaries and internal details of small targets. The BDFEAN module constructs a multi-path, multi-domain feature enhancement framework, simultaneously enhancing features in the spatial and frequency domains to improve the feature representation ability of small targets. The HLACI module combines a local-global dual attention mechanism and an adaptive feature guidance strategy to enhance the model's ability to detect small targets.
[0103] The improved RFA-DETR model is an enhanced real-time target detection framework specifically designed for small target detection tasks on UAV platforms. After analyzing the limitations of the traditional RT-DETR algorithm in small target detection scenarios, it systematically improves the core aspects of feature extraction, feature fusion, and feature enhancement to construct an efficient end-to-end detection model.
[0104] The RFA-DETR model is a comprehensive optimization based on the RT-DETR architecture, mainly consisting of the following four core components: (1) a dynamic backbone network based on DDCSM, (2) a contrast-driven feature aggregation module based on HWD-TPA, (3) a space-frequency dual-domain attention network based on BDFEAN, and (4) a hierarchical attention fusion module based on HLACI. These modules work together to address the key challenges in small target detection in UAVs.
[0105] Step 2: Acquire aerial images taken by the drone and normalize the images to adjust them to the standard input size of 640×640 pixels; then transmit the processed images to the RFA-DETR improved model.
[0106] Step 3: Perform dynamic feature extraction using the DDCSM module; the DDCSM module is a dynamic dual-channel semantic mapping module, and its structure diagram is shown below. Figure 3 As shown, DDCSM has three key advantages: it adopts a dynamic receptive field strategy to adaptively adjust the spatial range of feature extraction; it introduces a multi-path feature interaction mechanism to enhance the fusion of information at different scales; and it optimizes computational efficiency, reducing the number of parameters and computational complexity while maintaining the model's expressive power.
[0107] The core idea of the DDCSM module is to segment and process the input features before fusing them to obtain a richer feature representation. Its specific operation is as follows:
[0108] Channel mapping is performed using 1×1 convolutions to map the input features to a higher-dimensional representation space. The features are then split into two branches for processing. The first branch directly passes the original feature information, while the second branch performs dynamic feature extraction through cascaded DIMBlocks. The structure of the DIMBlocks is as follows: Figure 3 As shown in (b), this segmented processing strategy enables the network to simultaneously retain the original feature information and extract higher-level semantic features, thereby constructing a hierarchical feature representation.
[0109] The DIMBlock module combines the advantages of Transformer and CNN, employing a dual-branch architecture that includes a feature mixing branch and a feature transformation branch, both supplemented by residual connections. Given input features... The workflow of the DIMBlock module is as follows:
[0110] ;
[0111]
[0112] in, and is a learnable hierarchical scaling parameter, initialized to a small value to ensure the stability of residual learning in the early stages of training; DropPath is a stochastic depth regularization technique that enhances the model's generalization ability by randomly discarding some paths during training; BN represents batch normalization; DIM is used to capture multi-scale features, first dividing the features equally along the channel dimension, and then processing each group of features through DynamicInceptionDWConv2d with different configurations; ConvolutionalGLU introduces a gating mechanism, enabling the network to adaptively select and enhance informative feature channels while suppressing irrelevant noisy features.
[0113] The DIMBlock module comprises three core components: DIM multi-scale extraction, DIDWConv dynamic receptive field convolution, and a Convolutional GLU gating mechanism. The DIDWConv module structure is as follows: Figure 4 As shown.
[0114] The DIDWConv module integrates three different types of depthwise separable convolutions, including standard square convolutions such as 3×3, and two rectangular convolutions: 1×11 and 11×1, to capture feature patterns in different directions and scales.
[0115] Given input features First, dynamic kernel weights are generated through global average pooling and 1×1 convolution, resulting in a tensor W of shape 3C×1×1. Then, W is reshaped into three tensors W1, W2, and W3. Finally, the Softmax function is applied to the three tensors to obtain three attention weight coefficients α1, α2, and α3. The workflow is as follows:
[0116] ;
[0117] ;
[0118]
[0119] Then apply three types of depthwise convolution and weighted fuse them:
[0120] ;
[0121] in, Indicates the size of the square convolution kernel. The bar represents the size of the convolutional kernel, and GAP represents global average pooling. The innovation of the DIDWConv module lies in introducing an attention mechanism to dynamically adjust the weights of different convolutional kernels, enabling the network to adaptively select the most suitable combination of receptive fields based on the input features.
[0122] This step outputs multi-scale features S3, S4, and S5, which correspond to different spatial resolutions and semantic levels, respectively.
[0123] Step 4: Feature Encoding and Preliminary Fusion; Apply the AIFI module to the highest-level feature S5 for in-attention scale feature interaction, and fuse the features of three different scales (S3, S4, and S5) through the CCFF module to output the encoded multi-scale features P3, P4, and P5. This step enhances the information flow between feature maps, laying the foundation for subsequent fine-tuning.
[0124] Step 5: Use the HWD-TPA module to perform frequency domain contrast-driven feature enhancement.
[0125] HWD-TPA first decouples features into low-frequency components (approximation coefficients) and high-frequency components (detail coefficients) using Haar wavelet transform, corresponding to the smooth structure and detail variations of the image, respectively. This decomposition is based on the observation that small targets typically exhibit significant differences from the background in the high-frequency components. Subsequently, HWD-TPA designs a cascaded dual-path attention mechanism: the high-frequency path first focuses on target boundaries and texture details, enhancing the local features of small targets; the low-frequency path focuses on the global context, using structural information to further refine and improve the target representation. The structure diagram of HWD-TPA is shown below. Figure 5 As shown.
[0126] The HWD-TPA module guides feature aggregation using frequency domain information from wavelet decomposition; given input features First, the input features are preliminarily processed using two cascaded 3×3 convolutional blocks. Then, the Haar wavelet transform is applied to decompose the features. The HaarWaveletConv module implements a differentiable version of the two-dimensional Haar wavelet transform for frequency domain decomposition of the features.
[0127]
[0128] in, Indicates low-frequency background components. This represents the high-frequency foreground component.
[0129] The features are rearranged into a spatial-channel order and a value projection is generated. Then, a sliding window expansion operation is applied to the value features to generate a local receptive field, represented as follows:
[0130] ;
[0131] ;
[0132]
[0133] in, For the number of attention heads, For the size of the core, This represents the number of spatial positions after unfolding. This represents the sliding window expansion operation, followed by a two-stage attention mechanism. First, the high-frequency foreground attention stage captures detailed features:
[0134]
[0135] in, This indicates a channel rearrangement operation. Indicates average pooling. For the Softmax function, For linear projection transformation, This is the scaling factor. Feature aggregation is achieved in the following way:
[0136]
[0137] in, and These represent projection and folding operations, respectively. Weighting attention. Similarly, enhancing context awareness during the low-frequency background attention phase:
[0138] ;
[0139] ;
[0140] ;
[0141] in, Indicates feature expansion operation, Linear transformation of background features and Rearrange operations for different channels.
[0142] The two-stage design enables the HWD-TPA module to adaptively focus on important features in different frequency domains while maintaining computational efficiency. It provides an effective solution for small target detection on UAV platforms. By introducing differentiable Haar wavelet transform into the target detection network, frequency domain decoupling of features is achieved, providing a new perspective for effectively distinguishing small targets from the background. A dual-path attention mechanism guided by frequency domain information is designed, utilizing high-frequency features from the foreground and low-frequency features from the background to enhance target representation, achieving contrast-driven adaptive feature enhancement.
[0143] Step 6: Use the BDFEAN network module to perform spatial-frequency dual-domain feature fusion and enhancement.
[0144] The BDFEAN network module is a bidirectional frequency-enhanced attention network that enhances features simultaneously in the spatial and frequency domains, significantly improving the feature representation capability of small targets. This architecture comprises three core components: (1) a MultiScalePCA module, which implements adaptive upsampling feature fusion based on channel attention; (2) a MultiScalePCA_Down module, which performs efficient downsampling feature integration; and (3) an FSA module, which enhances feature representation simultaneously in the spatial and frequency domains. This multi-domain collaborative feature processing strategy significantly improves the model's ability to perceive small targets while suppressing interference introduced by complex backgrounds.
[0145] The BDFEAN architecture retains the original RTDETR backbone network and detection head, while reconstructing the neck fusion network. The overall BDFEAN architecture consists of four key feature processing stages, each incorporating adaptive channel attention and a space-frequency dual-domain enhancement mechanism. The BDFEAN network module contains two fusion paths: a top-down path in the FPN portion of the network and a bottom-up path in the PAN portion.
[0146] The top-down path first aligns the channels of features at each level using 1×1 convolution, then uses the MultiScalePCA module to fuse features from adjacent layers. This module calculates channel attention weights through adaptive 1D convolution and weights and fuses the upsampled low-resolution features. The fused features are then enhanced using the FSA module in both the frequency and spatial domains. FSA includes an AGF adaptive global frequency filtering branch and an SA spatial attention branch, which enhance the features in the frequency and spatial domains, respectively.
[0147] In the bottom-up path of the PAN part of the network, the MultiScalePCA_Down module is used to realize feature downsampling fusion, which retains important low-level feature information. The FSA module is also used to further enhance the discriminative ability of features, thus constructing a complete bidirectional feature extraction network.
[0148] The MultiScalePCA module introduces an adaptive channel attention mechanism, enabling the network to dynamically learn the importance of features at different scales. Subsequently, one-dimensional convolution is used to establish long-distance dependencies between channels, achieving adaptive upsampling feature fusion based on channel attention. This module receives two feature maps of different scales as input and achieves efficient feature fusion through channel-level attention and transposed convolution. The structure diagram is shown below. Figure 6 As shown.
[0149] Given input features and (in First, global average pooling is applied to both input features to extract channel statistical features:
[0150] ;
[0151] ;
[0152] Then, the size of the one-dimensional convolution kernel is adaptively calculated based on the number of channels, as shown in the following formula. Where, This means taking the nearest odd number from the top. and These are hyperparameters (default values are 1 and 2, respectively). This dynamic kernel size strategy allows the network to adaptively adjust the receptive field based on the number of channels, establishing more effective long-range dependencies along the channel dimension.
[0153] ;
[0154] Next, one-dimensional convolution is applied for channel feature processing. Then, the two features are concatenated along the channel dimension and integrated using another one-dimensional convolution.
[0155] ;
[0156] ;
[0157] ;
[0158] in, This represents a one-dimensional convolution operation, with kernel sizes of [sizes not specified]. and , Represents the Sigmoid activation function. Using kernel size One-dimensional convolution ( Total number of channels (Related).
[0159] Subsequently, the integrated weight vector is split back to the original channel dimension and applied to its respective input features:
[0160] ;
[0161] ;
[0162] ;
[0163] Finally, the low-resolution features are upsampled using transposed convolution and then fused with the high-resolution features:
[0164] ;
[0165] in, This represents a parameterized transpose convolution, using a 3×3 kernel, a stride of 2, and appropriate padding to achieve a 2x increase in feature map size.
[0166] The MultiScalePCA module introduces an adaptive channel attention mechanism, enabling the network to dynamically learn the importance of features at different scales. Subsequently, one-dimensional convolution is used to establish long-distance dependencies between channels.
[0167] The MultiScalePCA_Down module is similar in design philosophy to the MultiScalePCA module, but it is specifically designed for bottom-up feature fusion. This module takes two feature maps of different scales as input and achieves efficient feature downsampling fusion through channel attention and downsampling convolution. Given input features... and (in The processing flow of this module is similar to that of MultiScalePCA, with the main difference being in the final feature fusion stage:
[0168] ;
[0169] in, This represents a 3×3 convolution operation with a stride of 2, which reduces the feature map size from... downsampling to .
[0170] The FSA module aims to enhance feature representations simultaneously in both the frequency and spatial domains, particularly improving the saliency of small targets. This module consists of two parallel branches: an adaptive global frequency filter (AGF) and spatial attention (SA). The structure diagram of the FSA module is shown below. Figure 7 As shown.
[0171] The FSA module enables the network to utilize complementary information from both the frequency and spatial domains: the AGF branch enhances the frequency characteristics of small targets from a global spectral perspective, while the SA branch emphasizes salient regions from a local spatial perspective, thereby enhancing feature representation in both the spatial and frequency domains and improving the salience of small targets.
[0172] Given input features The FSA processing flow is expressed as follows:
[0173] ;
[0174] The AGF branch achieves selective enhancement of the feature spectrum through frequency domain transformation and adaptive filtering. First, the features are transformed to the frequency domain; then, low-pass and high-pass frequency masks are constructed.
[0175] ;
[0176] ;
[0177] ;
[0178] in, This represents a two-dimensional Fast Fourier Transform. This indicates a spectrum center shift operation. This is the frequency cutoff radius parameter, which controls the boundary between low and high frequencies.
[0179] Next, the low-frequency and high-frequency components are extracted separately, and a learnable complex weighted filter is applied to the low-frequency component. :
[0180] ;
[0181] ;
[0182] ;
[0183] ;
[0184] Finally, the spatial domain is returned through an inverse transformation:
[0185] ;
[0186] The innovation of the AGF module lies in the introduction of a learnable frequency domain filter that can adaptively enhance the frequency components related to small targets while suppressing background noise.
[0187] The SA branch generates a spatial attention map using channel statistics, emphasizing spatial contextual relationships.
[0188] ;
[0189] ;
[0190] ;
[0191] ;
[0192] in, This represents a 7×7 convolution operation. This represents the Sigmoid activation function.
[0193] The dual-branch design of the FSA module enables the network to utilize complementary information from both the frequency and spatial domains: the AGF branch enhances the frequency characteristics of small targets from a global spectral perspective, while the SA branch emphasizes salient regions from a local spatial perspective. This multi-domain collaborative enhancement strategy significantly improves the model's ability to identify small targets, especially in complex backgrounds and low-contrast environments.
[0194] Step 7: Use the HLACI module for hierarchical context integration.
[0195] The HLACI module significantly enhances the model's ability to detect small targets by combining a local-global dual attention mechanism and an adaptive feature guidance strategy. The HLACI module not only extracts and fuses key features from multiple scales but also effectively suppresses background interference through the attention mechanism, achieving accurate localization and recognition of small targets. The design of the HLACI module is based on theoretical assumptions: small target detection requires simultaneous attention to local detail features and global contextual information; feature maps at different scales contain complementary target representations; and adaptive feature guidance effectively improves the quality of information flow. Therefore, we designed a multi-path feature fusion architecture integrating local-global dual attention. The structure of the HLACI module is as follows: Figure 8 As shown.
[0196] The HLACI module receives feature maps from two different levels. After feature projection, the HLACI module enhances features through parallel multi-path processing. The basic feature fusion path combines the two features through a simple and effective additive fusion operation, and then uses grouped convolution to extract the mixed features.
[0197] ;
[0198] in, For parameters of Grouped convolution operation, with 4 groups;
[0199] The local-global attention enhancement path applies local attention (receptive field of 2) and global attention (receptive field of 4) to each projected feature:
[0200] ;
[0201] ;
[0202] in, and These represent the local and global attention functions, respectively. For the corresponding parameter set; attention mechanism The specific implementation is in the LocalGlobalAttention class; the LocalGlobalAttention structure is as follows: Figure 9 As shown.
[0203] For input features First, feature region segmentation is performed, dividing the input features into... The size is The local region is then analyzed; then, regional statistical features are extracted, and the statistics for each region are calculated; subsequently, nonlinear feature transformation is performed, and the feature representation is enhanced through a multilayer perceptron, while attention weights are generated and used to weight and enhance the features.
[0204] ;
[0205] ;
[0206] ;
[0207] in, and For a multilayer perceptron, LayerNorm is the layer normalization operation.
[0208] Next, we will use learnable cue vectors Calculate feature correlation to achieve adaptive feature selection; where express The normalization result, This indicates element-wise multiplication.
[0209] ;
[0210] Feature size is recovered through a learnable transformation matrix and upsampling operations. It is a learnable transformation matrix; For shape reconstruction operations, For bilinear interpolation upsampling, for convolution;
[0211] ;
[0212] ;
[0213] Finally, the HLACI module concatenates all enhanced features and fuses them through a series of efficient convolutional operations; HLACI introduces a dual-path attention mechanism, simultaneously capturing local fine features (receptive field of 2) and global contextual information (receptive field of 4); through formal analysis, this mechanism is expressed as:
[0214]
[0215] in, This indicates a feature fusion operation. and These represent the local and global attention functions, respectively.
[0216] The HLACI module performs channel projection on the fused features and then executes three processing paths in parallel. The first path is the basic fusion path, which directly adds the two feature paths and extracts the mixed features through a 3×3 grouped convolution. The second and third paths apply a local-global dual attention mechanism to the two projected features, respectively, where the receptive field of local attention is 2 and the receptive field of global attention is 4. In the local-global attention mechanism, the features are divided into small regions, the statistical features of each region are calculated, the features are enhanced by a multilayer perceptron and attention weights are generated, and a learnable cue vector P is used for feature selection. The output features of the three paths are concatenated and then fused through convolution to output the final features.
[0217] Step 8: Object Detection and Output of Final Detection Results. First, a high-quality image feature selection mechanism based on IoU (Inter-Origin Union) is used to select initial object queries from the encoder output. Then, the Transformer decoder iteratively optimizes the object queries through multiple decoder layers, generating accurate object location and category predictions. The final output includes bounding box coordinates and category confidence scores. The entire process requires no NMS post-processing and directly outputs the final detection results.
[0218] To verify the feasibility and superiority of this invention, the inventors conducted experiments; the specific experimental process and data are as follows:
[0219] Experimental environment
[0220] To ensure the stability and efficiency of model training and testing, all experiments were conducted on an NVIDIA 4090 GPU using Python 3.8 and the PyTorch 1.13.1 deep learning framework. For fair comparison, no pre-trained weights were used in the models, the batch size was set to 4, the training epochs were set to 200, the initial learning rate was 0.0001, and all other training hyperparameters used their default values.
[0221] Dataset Introduction
[0222] This experiment conducted small object detection experiments on the VisDrone2019, UAVDT, and DOTA datasets.
[0223] VisDrone2019 is a small target dataset specifically designed for drone aerial photography, containing 8629 drone aerial images. Of these, 6471 images are used for training, 548 for validation, and 1610 for testing.
[0224] UAVDT is a large-scale and challenging dataset designed specifically for target detection and tracking from the perspective of unmanned aerial vehicles (UAVs). It aims to advance three key tasks in UAV applications: target detection (DET), single target tracking (SOT), and multi-target tracking (MOT).
[0225] The DOTA dataset is a large-scale dataset specifically designed for target detection in remote sensing images. Its images are densely packed with targets, and the size of target instances varies considerably. VisDrone2019 was used as the primary experimental dataset in this paper for ablation and comparison experiments. The DOTA dataset is a large-scale dataset for target detection in remote sensing images. Due to the inconsistent image sizes within the dataset, directly feeding it into the network is difficult for training. Therefore, the DOTA dataset was segmented into 1024×1024 pixel sub-images with adjacent images spaced 200 pixels apart. After processing using Python, a total of 21,046 images were obtained. The training set contains 15,749 images, and the test set contains 5,297 images.
[0226] To verify the effectiveness of the FSA module in the BDFEAN architecture, ablation experiments were conducted, and the results are shown in Table 1. The experimental data show that adding the FSA module to the basic BDFEAN architecture improves detection performance to a certain extent. Specifically, the overall detection accuracy (AP) improved by 0.9%, and the small target detection accuracy (AP_s) improved by 0.6%. These results verify that the FSA module can effectively enhance feature representation capabilities.
[0227] Table 1. Comparison of various indicators in BDFEAN ablation experiments with and without FSA ablation on test dataset.
[0228]
[0229] The FSA module's improved detection performance is primarily attributed to its unique spatial-frequency dual-domain collaborative enhancement mechanism. By adaptively enhancing target features in the frequency domain through the AGF branch, the model can better distinguish the frequency characteristics of small targets from the background, especially for tiny targets in low-contrast regions. Simultaneously, the SA branch generates an attention map in the spatial domain, further highlighting the spatial contextual information of the target region. This multi-domain collaborative feature enhancement strategy enables the network to capture discriminative features of small targets from different angles, effectively suppressing interference from complex backgrounds, thereby improving the model's detection stability and accuracy in real-world aerial photography scenarios.
[0230] Table 1 clearly demonstrates the outstanding performance of the proposed RFA-DETR model across key metrics. In terms of detection accuracy, RFA-DETR achieves an AP50 of 38.2%, a 2.4% improvement over the baseline model RT-DETR-R18. Notably, in small target detection performance (APs), RFA-DETR reaches 12.8%, significantly outperforming most comparative models. Furthermore, RFA-DETR also performs well in detecting medium and large targets, demonstrating its balanced performance across different target scales. Regarding model efficiency, RFA-DETR achieves even more significant advantages: the number of parameters is only 13.7M, a 31.2% reduction compared to the baseline model; the computational cost is reduced to 50G, a 12.3% reduction compared to the baseline model. While the DINO model achieves a maximum AP50 accuracy of 44.5%, its large number of parameters makes it difficult to deploy in real-time on UAV platforms with limited computing resources. Considering all indicators, RFA-DETR maintains high detection accuracy while significantly reducing computational costs, achieving the best balance between accuracy and efficiency, and providing an efficient and practical solution for real-time detection of small targets by aerial drones.
[0231] To verify the generalization ability of the proposed RFA-DETR algorithm in different scenarios, we conducted generalization experiments on different datasets, as shown in Table 2. Three representative aerial image datasets were selected for evaluation: Visdrone2019, UAVDT, and DOTA. These datasets represent aerial images at different altitudes, densities, and in different scenarios, comprehensively validating the model's general performance. In the experiments, we compared and analyzed the basic RT-DETR-R18 model with the proposed RFA-DETR model.
[0232] Table 2 Generalization experiments on different datasets
[0233]
[0234] Experimental results demonstrate that the RFA-DETR model proposed in this invention outperforms the basic RT-DETR-R18 model on all test datasets. Specifically, on the Visdrone2019 dataset, RFA-DETR achieves AP and AP50 of 22.0% and 38.2%, respectively, representing improvements of 1.5% and 2.4% compared to the basic model; on the UAVDT dataset, RFA-DETR achieves AP and AP50 of 42.7% and 66.3%, respectively, representing improvements of 1.1% and 0.9% compared to the basic model; and on the DOTA dataset, RFA-DETR achieves AP and AP50 of 17.3% and 30.8%, respectively, representing improvements of 0.9% and 0.8% compared to the basic model. These results fully demonstrate that the RFA attention mechanism proposed in this invention can effectively improve the model's ability to detect small targets in aerial photography scenes and maintain good generalization performance in different scenarios.
[0235] To verify the RFA-DETR model's ability to perceive small targets in complex backgrounds, we used Grad-CAM technology to perform a heatmap visualization comparison between the baseline RT-DETR and the improved RFA-DETR model. The experiment selected three typical scenarios: high-density crowds, traffic in complex building environments, and urban road intersections, visually demonstrating the distribution intensity of the model's focus areas.
[0236] like Figure 10 As shown, compared to RT-DETR, the RFA-DETR of this invention exhibits more accurate target localization and a more focused attention distribution. In crowd scenes, RFA-DETR more accurately highlights areas where crowds gather; in complex architectural environments, it provides a clearer response to vehicle target boundaries; and in urban road scenes, even under varying lighting conditions...
[0237] It can stably generate accurate thermal responses even under varying conditions. These results demonstrate that RFA-DETR has stronger feature representation capabilities in small target detection tasks for aerial drones, especially with significant advantages under complex backgrounds and low-light conditions.
[0238] To verify the target detection performance of the RFA-DETR model in real-world aerial photography scenarios, comparative detection experiments were conducted under various complex environments using the VisDrone2019 dataset. For example... Figure 11 As shown, three typical scenarios were selected: large vehicles and buildings in industrial areas, mixed scenes of pedestrians and vehicles in public areas, and crowds and stalls in entertainment venues. The detection results of the original image (a), baseline RT-DETR (b), and RFA-DETR (c) were compared.
[0239] Experimental results show that RFA-DETR exhibits significant advantages in all scenarios. In industrial scenarios, RFA-DETR not only accurately detects large vehicles but also identifies more details such as pedestrians at a distance, with a well-fitting detection box.
[0240] The detection accuracy and confidence levels are higher; in public area scenes, more densely distributed pedestrians are successfully detected, and the system is more robust to occluded targets, with pedestrian detection confidence increasing from 0.41-0.78 to 0.45-0.85; in entertainment venue scenes, not only are more small targets detected, but bicycles and pedestrians can also be correctly distinguished. These results demonstrate that RFA-DETR has higher detection accuracy and stronger small target perception capabilities in aerial photography scenarios, especially in complex environments with dense targets, partial occlusion, and diverse categories.
[0241] The above embodiments are only for illustrating the technical concept and features of the present invention, and are intended to enable those skilled in the art to understand the content of the present invention and implement it accordingly. They should not be construed as limiting the scope of protection of the present invention. All equivalent changes or modifications made in accordance with the spirit and essence of the present invention should be covered by the present invention.
Claims
1. A method for detecting small aerial targets applied to unmanned aerial vehicles (UAVs), characterized in that: Including the following steps: Step 1: Create the RFA-DETR improved model, which includes the DDCSM module, HWD-TPA module, BDFEAN network module, and HLACI module; Step 2: Preprocess the images taken by the drone and transmit the processed images to the RFA-DETR improved model; Step 3: Perform dynamic feature extraction using the DDCSM module; Step 4: Feature Encoding and Preliminary Fusion; Step 5: Perform frequency domain contrast-driven feature enhancement using the HWD-TPA module; Step Six: Perform spatial-frequency dual-domain feature fusion and enhancement using the BDFEAN network module; Step 7: Use the HLACI module for hierarchical context integration; Step 8: Target detection and output the final detection results.
2. The method for detecting small aerial targets applied to unmanned aerial vehicles according to claim 1, characterized in that: Step one describes creating an improved RFA-DETR model, which optimizes the RT-DETR model. The optimization method is as follows: In the feature extraction stage, the DDCSM module is used to replace the ResNet backbone network in the RT-DETR model. Through dynamic receptive field and multi-path feature interaction mechanism, the network's ability to perceive small targets is enhanced. The DDCSM module adopts the CSP idea combined with the dynamic receptive field strategy to adaptively adjust the spatial range of feature extraction, thereby reducing the number of parameters and computational complexity while maintaining the model's expressive power. In the feature fusion and enhancement stage, three complementary modules are introduced: HWD-TPA, BDFEAN, and HLACI. The HWD-TPA module uses Haar wavelet transform to achieve frequency domain decomposition of features and designs a dual-path attention mechanism driven by high-frequency foreground information and low-frequency background information, respectively, to adaptively enhance the boundaries and internal details of small targets. The BDFEAN module constructs a multi-path, multi-domain feature enhancement framework, simultaneously enhancing features in the spatial and frequency domains to improve the feature representation ability of small targets. The HLACI module combines a local-global dual attention mechanism and an adaptive feature guidance strategy to enhance the model's ability to detect small targets. The optimized RFA-DETR improved model includes four core components: (1) a dynamic backbone network based on DDCSM, (2) a contrast-driven feature aggregation module based on HWD-TPA, (3) a space-frequency dual-domain attention network based on BDFEAN, and (4) a hierarchical attention fusion module based on HLACI.
3. A method for detecting small aerial targets applied to unmanned aerial vehicles according to claim 1 or 2, characterized in that: The specific operation method of using the DDCSM module for dynamic feature extraction in step 3 is as follows: channel mapping is performed through 1×1 convolution to map the input features to a higher-dimensional representation space, and the features are divided into two branches for processing. The first branch directly transmits the original feature information, and the second branch performs dynamic feature extraction through cascaded DIMBlock. The DIMBlock module combines Transformer and CNN, employing a two-branch architecture including a feature mixing branch and a feature transformation branch, both supplemented by residual connections; given input features The workflow of the DIMBlock module is as follows: ; ; in, and is a learnable hierarchical scaling parameter, initialized to a small value to ensure the stability of residual learning in the early stages of training; DropPath is a stochastic depth regularization technique that enhances the model's generalization ability by randomly discarding some paths during training; BN represents batch normalization; DIM is used to capture multi-scale features, first dividing the features equally along the channel dimension, and then processing each group of features through DynamicInceptionDWConv2d with different configurations; ConvolutionalGLU introduces a gating mechanism, enabling the network to adaptively select and enhance informative feature channels while suppressing irrelevant noisy features.
4. The method for detecting small aerial targets applied to unmanned aerial vehicles according to claim 3, characterized in that: The DIMBlock module comprises three core components: DIM multi-scale extraction, DIDWConv dynamic receptive field convolution, and ConvolutionalGLU gating mechanism. The DIDWConv module integrates three different types of depthwise separable convolutions, including standard square convolutions such as 3×3, and two rectangular convolutions: 1×11 and 11×1, to capture feature patterns of different orientations and scales. Given input features First, dynamic kernel weights are generated using global average pooling and 1×1 convolution, resulting in a tensor W of shape 3C×1×1; then, W is reshaped into three tensors. Finally, the Softmax function is applied to the three tensors to obtain the three attention weight coefficients. ; Its workflow is represented as follows: ; ; ; Then apply three types of depthwise convolution and weighted fuse them: ; in, Indicates the size of the square convolution kernel. This indicates the size of the bar convolution kernel, and GAP indicates global average pooling.
5. The method for detecting small aerial targets applied to unmanned aerial vehicles according to claim 1, characterized in that: Step three outputs multi-scale features S3, S4, and S5, which correspond to different spatial resolutions and semantic levels. Step four applies the AIFI module to the highest-level feature S5 for attentional scale feature interaction, and fuses the three different scale features S3, S4, and S5 through the CCFF module to output encoded multi-scale features P3, P4, and P5.
6. The method for detecting small aerial targets applied to unmanned aerial vehicles according to claim 1, characterized in that: Step 5 describes the HWD-TPA module that constructs a cascaded dual-path attention mechanism: the high-frequency path first focuses on the target boundary and texture details, enhancing the local features of small targets; Low-frequency paths focus on the global context, using structural information to further refine and improve the target representation; The HWD-TPA module guides feature aggregation using frequency domain information from wavelet decomposition; given input features First, the input features are preliminarily processed using two cascaded 3×3 convolutional blocks. Then, the Haar wavelet transform is applied to decompose the features. The HaarWaveletConv module implements a differentiable version of the two-dimensional Haar wavelet transform for frequency domain decomposition of the features. ; in, Indicates low-frequency background components. Indicates high-frequency foreground components; The features are rearranged into a spatial-channel order and a value projection is generated. Then, a sliding window expansion operation is applied to the value features to generate a local receptive field, represented as follows: ; ; ; in, For the number of attention heads, For the size of the core, This represents the number of spatial positions after unfolding. This represents the sliding window expansion operation, followed by a two-stage attention mechanism; firstly, the high-frequency foreground attention stage captures detailed features: ; in, This indicates a channel rearrangement operation. Indicates average pooling. For the Softmax function, For linear projection transformation, The scaling factor is used; feature aggregation is achieved in the following ways: ; in, and These represent projection and folding operations, respectively. Weighting attention; similarly, enhancing context awareness during low-frequency background attention phases: ; ; ; in, Indicates feature expansion operation, A linear transformation of background features. and Rearrange operations for different channels.
7. The method for detecting small aerial targets applied to unmanned aerial vehicles according to claim 1, characterized in that: The BDFEAN network module described in step six includes two fusion paths: a top-down path in the FPN part of the network and a bottom-up path in the PAN part of the network. The top-down path first aligns the channels of each level of features through 1×1 convolution, and then uses the MultiScalePCA module to fuse the features of adjacent layers. This module calculates channel attention weights through adaptive 1D convolution and weighted fuses the upsampled low-resolution features. The fused features are enhanced in two domains using the FSA module. The FSA includes the AGF adaptive global frequency filtering branch and the SA spatial attention branch, which enhance the features in the frequency domain and the spatial domain, respectively. In the bottom-up path of the PAN part of the network, the MultiScalePCA_Down module is used to realize feature downsampling fusion, which retains important low-level feature information. The FSA module is also used to further enhance the discriminative ability of features, thus constructing a complete bidirectional feature extraction network.
8. The method for detecting small aerial targets applied to unmanned aerial vehicles according to claim 7, characterized in that: The MultiScalePCA module introduces an adaptive channel attention mechanism, enabling the network to dynamically learn the importance of features at different scales. Subsequently, one-dimensional convolution is used to establish long-distance dependencies between channels, achieving adaptive upsampling feature fusion based on channel attention. This module takes two feature maps of different scales as input and achieves efficient feature fusion through channel-level attention mechanism and transposed convolution. The MultiScalePCA_Down module is specifically designed to implement feature fusion for bottom-up paths. This module takes two feature maps of different scales as input and achieves efficient feature downsampling fusion through channel attention and downsampling convolution. The FSA module consists of two parallel branches: Adaptive Global Frequency Filter (AGF) and Spatial Attention (SA), enabling the network to utilize complementary information from both the frequency and spatial domains. The AGF branch enhances the frequency characteristics of small targets from a global spectral perspective, while the SA branch emphasizes salient regions from a local spatial perspective, thereby enhancing feature representation in both the spatial and frequency domains and improving the salience of small targets.
9. A method for detecting small aerial targets applied to unmanned aerial vehicles according to claim 8, characterized in that: The AGF branch achieves selective enhancement of the feature spectrum through frequency domain transformation and adaptive filtering. First, the features are transformed to the frequency domain, then low-pass and high-pass frequency masks are constructed. Next, low-frequency and high-frequency components are extracted respectively, and a learnable complex weighted filter is applied to the low-frequency portion. Finally, the inverse transformation is used to return to the spatial domain; The SA branch generates a spatial attention map using channel statistics, emphasizing spatial contextual relationships.
10. The method for detecting small aerial targets applied to unmanned aerial vehicles according to claim 1, characterized in that: The HLACI module described in step seven receives two feature maps from different levels. After feature projection, the HLACI module performs feature enhancement through parallel multi-path processing. The basic feature fusion path combines the two features through a simple and effective additive fusion operation, and then uses grouped convolution to extract the mixed features. ; in, For parameters of Grouped convolution operation, with 4 groups; The local-global attention enhancement path applies local attention (receptive field of 2) and global attention (receptive field of 4) to each projected feature: ; ; in, and These represent the local and global attention functions, respectively. For the corresponding parameter set; attention mechanism Specifically implemented in the LocalGlobalAttention class; For input features First, feature region segmentation is performed, dividing the input features into... The size is The local region is then analyzed; then, regional statistical features are extracted, and the statistics for each region are calculated; subsequently, nonlinear feature transformation is performed, and the feature representation is enhanced through a multilayer perceptron, while attention weights are generated and used to weight and enhance the features. ; ; ; in, and For a multilayer perceptron, LayerNorm is the layer normalization operation; Next, we will use learnable cue vectors Calculate feature correlation to achieve adaptive feature selection; where express The normalization result, This indicates element-wise multiplication; ; Feature size is recovered through a learnable transformation matrix and upsampling operations. It is a learnable transformation matrix; For shape reconstruction operations, For bilinear interpolation upsampling, for convolution; ; ; Finally, the HLACI module concatenates all enhanced features and fuses them through a series of efficient convolutional operations; HLACI introduces a dual-path attention mechanism, simultaneously capturing local fine features (receptive field of 2) and global contextual information (receptive field of 4); through formal analysis, this mechanism is expressed as: ; in, This indicates a feature fusion operation. and These represent the local and global attention functions, respectively.