A small target detection method based on guided focus feature pyramid network
By guiding the focus of the feature pyramid network and combining top-down and bottom-up bidirectional fusion methods, the problems of inaccurate feature focusing and insufficient discrimination ability of the feature pyramid structure in small target detection are solved, and more efficient small target detection is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHIJIAZHUANG TIEDAO UNIV
- Filing Date
- 2026-02-01
- Publication Date
- 2026-07-21
AI Technical Summary
The existing feature pyramid structure is not precise enough in focusing key features in small target detection, has insufficient feature discrimination ability, and fails to fully explore inter-layer features, resulting in insufficient detection accuracy.
The design is based on a guided-focus feature pyramid network and adopts a bidirectional fusion approach, combining a top-down feature pyramid network and a bottom-up guided-focus network. It enhances feature discrimination and focusing capabilities through a lightweight hierarchical attention module and a full-channel correlation fusion module.
It improves the accuracy and efficiency of small target detection, enhances the model's ability to identify and locate small targets, and reduces computational complexity.
Smart Images

Figure CN121921496B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to a small target detection method based on a guided focusing feature pyramid network, belonging to the field of computer vision technology. Background Technology
[0002] With the development of artificial intelligence technology, machine vision-based surface defect detection technology is replacing manual inspection, driving the innovation of manufacturing production models and the intelligent upgrading of industries. In terms of production models, it overcomes the limitations of manual inspection in terms of speed, accuracy, and stability, enabling precise and real-time detection of product defects on high-speed production lines. This facilitates a shift from reliance on manual sampling to fully automated and intelligent inspection, significantly improving production efficiency and product quality consistency. Currently, as enterprises continuously increase their requirements for inspection accuracy and timeliness, the problem of small-target defects has become one of the major challenges facing surface defect detection in industrial products. Some defects are only a few pixels long, containing little information and having weak feature representation capabilities, resulting in low detection accuracy. For products with complex surface textures, "similar textures" may be mixed with the detailed features of small targets, further increasing the difficulty of detection. Researchers have conducted extensive work to address these problems in small-target detection, with multi-scale feature fusion being one of the important research directions.
[0003] As an inherent feature extraction mechanism, CNNs naturally learn hierarchical image representations from coarse to fine. In computer vision tasks, it is crucial for CNNs to collect different information from feature maps of different sizes and understand meaningful context. Early in the development of deep learning, researchers recognized the importance of features at different scales for model performance. This led to the development of multi-scale feature fusion techniques, which allow models to capture and integrate information at different resolutions and scales, enabling them to more comprehensively understand image content and significantly improve the performance of tasks such as object detection and image segmentation.
[0004] The core idea of multi-scale feature fusion lies in the fact that images or features at different scales contain different information. While feature maps from deep networks have a large receptive field and strong semantic information representation capabilities, they have low resolution and weak geometric information representation capabilities; conversely, feature maps from low-level networks have high resolution and rich geometric details, but weaker semantic information representation capabilities. By fusing features from multiple scales, the advantages of different layers can be fully utilized to improve the overall performance of the model. Multi-scale feature fusion technology has been largely adopted by current mainstream object detection models, becoming an important method for improving multi-scale object detection performance. The most representative example is the Feature Pyramid (FPN) and its variants. The earliest FPNs used a top-down unidirectional path to integrate semantic information into shallow feature maps, effectively enhancing the model's ability in multi-scale object detection. This innovative work showed great potential in object detection; therefore, some research focused on optimizing the FPN structure, such as adding a bottom-up path to the FPN, introducing a weighted feature fusion mechanism, and designing cross-layer connections. These studies effectively enhanced the feature representation capabilities of FPNs, resulting in significant performance improvements for object detection tasks within a certain scale range. However, due to the inherent contradiction between insufficient semantics in shallow features and loss of detail in deep features, and the lack of an active filtering mechanism in traditional feature pyramids, their ability to distinguish effective features is insufficient, which seriously affects the model's ability to identify and locate small targets. Attention mechanisms offer a solution to this problem, allowing the model to focus on more important parts when processing information, reducing unnecessary information interference, and thus improving model accuracy. Recently, research has explored combining attention mechanisms with feature pyramids to improve small target detection performance. Related work includes incorporating channel attention, spatial attention, and self-attention mechanisms into feature pyramid networks, which provides important references for this invention. However, designing an effective fusion mechanism to give the model more precise focusing ability, stronger feature discrimination ability, and balancing detection accuracy and model complexity remain significant challenges. Summary of the Invention
[0005] The purpose of this invention is to provide a small target detection method based on a guided focusing feature pyramid network, which solves the problems of insufficient focusing accuracy of key features, insufficient feature discrimination ability, and failure to fully explore inter-layer features in existing feature pyramid structures, thereby improving the performance of small target detection.
[0006] This invention provides a small target detection method based on a guided focusing feature pyramid network, comprising the following steps: S1, Obtain the small object detection dataset and divide the dataset into training set, validation set and test set; S2, the training set image data is input into the backbone network, and features are extracted through different layers of the backbone network to obtain four feature maps of different scales: P2, P3, P4, and P5. S3, four feature maps of different scales are fed into a guided focusing feature pyramid network for feature fusion to obtain a feature sequence. The guided focusing feature pyramid network adopts a bidirectional fusion method, including: Feature Pyramid Network: The feature pyramid network adopts a top-down connection method, which transmits high-level semantic features to low-level layers through upsampling; Guided Focusing Network: The guided focusing network adopts a bottom-up connection approach and designs a lightweight hierarchical attention module to replace simple convolutional downsampling. While downsampling layer by layer, the attention map of the next layer is generated from the feature map of the previous layer. Then, star operation and residual connection are used to apply the attention weights to the feature map, thereby improving the ability to distinguish between the target and the background and achieving accurate focusing of key features. Specifically, the lightweight hierarchical attention module consists of a local spatial attention module and a full-channel correlation fusion module. The local spatial attention module extracts basic features and local contextual information through different receptive fields to obtain an initial spatial attention map. The full-channel correlation fusion module fuses cross-channel spatial information based on the initial spatial attention map, establishes the correlation between features of different receptive fields, and adjusts the number of channels to adapt to star-shaped operations. S4. Input the fused feature sequence into the detection head, perform iterative training, and save the model parameters with the best results. S5 inputs the test set images into the detection model to identify and locate targets in the images.
[0007] Furthermore, the implementation process of the local spatial attention module is as follows: First, the input feature map is split into three parts by channel to reduce the amount of computation; Then, deep dilated convolutions with dilation rates of 1, 2, and 3, and the ReLU activation function are used to expand the receptive field and extract local contextual information. Finally, these three parts are spliced together along the channel dimension.
[0008] Furthermore, the implementation process of the full-channel correlation fusion module is as follows: First, the spatial dimension is compressed, condensing the spatial information of each channel into a vector containing two elements, resulting in the global descriptor of the channel. Global average pooling and max pooling are used here: , , in, The feature matrix representing the c-th channel of the input features. H , W They are height and width, respectively. This represents the output value of the c-th channel after global average pooling. This represents the output value of the c-th channel after max pooling, from which the global description vector of the c-th channel can be obtained. The global descriptor for all channels can be represented as ; Next, the query vector Q and the key vector K are generated through two linear transformations: , In the formula, , It is a learnable linear transformation matrix; Next, attention weights between channels are calculated to dynamically measure the strength of the association. Specifically, the association score between channels is calculated based on the similarity between Q and K, and then normalized to obtain the weight matrix A. , By weighting and summing the input features using the attention weight matrix, we obtain the full-channel fused output features: , In the formula, This represents the output characteristic of the c-th channel; Finally, the number of channels is adjusted by 1×1 convolution to obtain the attention guidance map.
[0009] Furthermore, the four different scale feature maps P2, P3, P4, and P5 are downsampled by 4, 8, 16, and 32 times respectively from the original image.
[0010] Furthermore, the guided focus feature pyramid network is a plug-and-play structure that can be used in conjunction with backbone networks such as ResNet, Darknet53, and CSPDarknet.
[0011] Furthermore, the detection head adopts the decoupled design of YOLOv5: regression and classification use two completely independent branches that do not interfere with each other.
[0012] Furthermore, the iterative training uses a combined loss function, which is a weighted average of confidence loss, regression loss, and classification loss.
[0013] Compared with existing technologies, the present invention has the following advantages: 1. This invention proposes a guided-focusing feature pyramid network to improve the performance of small target detection. Based on FPN, this network is designed as a bottom-up guided-focusing network: it establishes the correlation between the target and local context information, as well as shallow details and deep semantic features through hierarchical attention modules, star operations and residual connections, so that the feature pyramid network can focus on key features, improve the ability to distinguish between the target and the background, and thus improve the small target detection capability of the model.
[0014] 2. This invention designs a lightweight hierarchical attention module, which establishes the association between the target and local contextual information through a local spatial attention module and a full-channel correlation fusion module, thereby enhancing the feature discrimination capability.
[0015] 3. This invention designs a full-channel correlation fusion module, which constructs a correlation matrix between channels through a global descriptor and a self-attention mechanism, dynamically captures the correlation between channels, and realizes the fusion of full-channel spatial features. Attached Figure Description
[0016] The above and other objects, features and advantages of the present invention will become more apparent from the following description of examples of the invention with reference to the accompanying drawings, in which: Figure 1 This is a flowchart illustrating the implementation of the small target detection method based on a guided focusing feature pyramid network provided in the first embodiment of the present invention. Figure 2 This is an overall structural diagram of the guided focusing feature pyramid network provided in the first embodiment of the present invention; Figure 3 This is a structural diagram of the lightweight hierarchical attention module provided in the first embodiment of the present invention. Detailed Implementation
[0017] To make the objectives, advantages, and technical methods of this invention clearer, the technical solutions in the embodiments of this invention will be described in detail below with reference to the accompanying drawings. The specific examples described herein are for illustrative purposes only and are not intended to limit the scope of this invention.
[0018] like Figure 1 The diagram shows a flowchart of a small target detection method based on a guided focusing feature pyramid network according to an embodiment of the present invention, including steps S1-S5: S1. Obtain the small object detection dataset and divide the dataset into training set, validation set and test set.
[0019] In this embodiment of the invention, the model was trained and tested on the self-built dataset TinyIndus and the public dataset NEU-DET, respectively. These two datasets will be described in detail below.
[0020] (1) TinyIndus dataset: This dataset primarily includes four products: pharmaceutical glass bottles, pharmaceutical glass tubes, glass spheres, and disposable medical gloves. It labels nine defect categories: neck crack (xjf), bottle body crack (xsf), bottle body stain (xsd), bottle bottom crack (xdf), tube body crack (gsf), tube mouth crack (gkf), tube body black spot (gsp), glass sphere black spot (qp), and medical glove damage (stf). The dataset is divided into three parts: 80% as the training set, 10% as the validation set, and 10% as the test set.
[0021] (2) NEU-DET dataset: Developed and released by Northeastern University, this dataset enjoys widespread recognition and application value in the field of steel surface defect detection. Designed specifically to address the challenge of automatic defect identification in industrial steel production, it provides a standardized and comprehensive resource for training, validating, and comparing the performance of computer vision and object detection models. The dataset contains 1800 high-quality grayscale images, all collected from cold-rolled steel sheets in actual production, with a uniform resolution of 200×200 pixels. The images cover six common and typical surface defects in steel products: crazing, inclusion, patches, pitted surface, rolled-in scale, and scrapes. Each defect category contains 300 images, ensuring a balanced data distribution and effectively preventing bias in model training. Currently, NEU-DET has become a core evaluation benchmark for various advanced object detection algorithms.
[0022] S2, the training set image data is input into the backbone network, and features are extracted through different layers of the backbone network to obtain four feature maps of different scales: P2, P3, P4, and P5.
[0023] The guided focusing feature pyramid network provided by this invention is a plug-and-play structure that can be used in conjunction with common backbone networks such as ResNet, Darknet53, and CSPDarknet. In this embodiment, Darknet53 and CSPDarknet are selected for training and testing. The four different scale feature maps P2, P3, P4, and P5 extracted from the backbone network represent downsampling of the original image by 4, 8, 16, and 32 times, respectively.
[0024] S3 feeds four feature maps of different scales into the guided focusing feature pyramid network for feature fusion to obtain a feature sequence.
[0025] like Figure 2The diagram shown illustrates the overall structure of the Guided Focusing Feature Pyramid Network (GF-FPN) of this invention. This network consists of two parts: a feature pyramid network and a guided focusing network, employing a bidirectional path fusion structure similar to PANet. The feature pyramid network employs a top-down connection approach, passing deep semantic features to shallower layers to generate preliminary feature fusion. Here, channel-dimensional concatenation is used to preserve original features, preventing information loss or weak information being "covered" by strong information.
[0026] The guided focusing network adopts a bottom-up connection approach and designs a lightweight hierarchical attention module to replace simple convolutional downsampling. The lightweight hierarchical attention module acts on the feature fusion layers (F2, F3, F4) generated by the feature pyramid network. While downsampling layer by layer, the attention map of the next layer is generated from the feature map of the previous layer. Then, star operations and residual connections are used to apply the attention weights to the feature map, thereby improving the ability to distinguish between the target and the background and achieving accurate focusing of key features.
[0027] The residual connection is implemented as follows: The long path first passes through a sigmoid activation function to obtain an attention guidance map. Then, a star-shaped operation directly applies the attention weights to the next layer's feature map, further enhancing the discriminative power between features and completing layer-by-layer feature aggregation. The short path "passes" the output features of the lightweight hierarchical attention module to the output of the main path, adding them element-wise with the output of the long path to obtain the output features of the next layer. Through residual connections, cross-layer feature fusion is achieved, enhancing feature reuse and preventing the loss of important features. It also alleviates the problem of gradient products being too small (vanishing) or too large (exploding) due to star-shaped operations. The final output feature sequences O3, O4, and O5 are obtained through the guidance aggregation network. These features can be input into the detection head for target recognition and localization.
[0028] The star schema operation is essentially performing element-wise multiplication on two matrices, for two matrices of the same dimension ( H × W Given matrices A and B, the element-wise multiplication result C can be expressed as: , In the formula, [i,j] represents the position of an element in the matrix, and the value of i ranges from 0 to... W -1, the value of j ranges from 0 to... H -1. Star operations can map the input to a higher-dimensional nonlinear feature space, thereby improving the nonlinearity and representational ability of the network.
[0029] like Figure 3The diagram shows the structure of a lightweight hierarchical attention module provided by this invention. This module consists of two parts: a local spatial attention module and a full-channel correlation fusion module. The local spatial attention module extracts basic features and extensive local contextual information through different receptive fields. Specifically, it is implemented as follows: First, the input feature map is split into three parts by channel, primarily to reduce computational cost. Then, deep dilated convolution (DW-D-Conv) with different dilation rates (r=1,2,3) and the ReLU activation function are used to expand the receptive field and extract extensive local contextual information. Finally, these three parts are concatenated along the channel dimension. The local spatial attention module performs a 2x downsampling and extracts the initial spatial attention map. Based on the initial spatial attention map, cross-channel spatial information is fused to establish the correlation between features in different receptive fields, while simultaneously adjusting the number of channels to accommodate subsequent star-shaped operations. This module calculates the correlation between all channels using global pooling and self-attention mechanisms, and then performs feature fusion. Assuming the input feature is X, the goal is to generate a correlation matrix A across all channels through channel self-attention. The steps are as follows: First, the spatial dimension is compressed, condensing the spatial information of each channel into a vector containing two elements, resulting in the global descriptor of the channel. Global average pooling and max pooling are used here: , , in, The feature matrix representing the c-th channel of the input features. H , W They are height and width, respectively. This represents the output value of the c-th channel after global average pooling. This represents the output value of the c-th channel after max pooling, from which the global description vector of the c-th channel can be obtained. The global descriptor for all channels can be represented as ; Next, the query vector Q and the key vector K are generated through two linear transformations: , In the formula, , It is a learnable linear transformation matrix; Next, attention weights between channels are calculated to dynamically measure the strength of the association. Specifically, the association score between channels is calculated based on the similarity between Q and K, and then normalized to obtain the weight matrix A. , By weighting and summing the input features using the attention weight matrix, we obtain the full-channel fused output features: , In the formula, This represents the output characteristic of the c-th channel; Finally, the number of channels is adjusted by 1×1 convolution to obtain the attention guidance map.
[0030] The specific structure and parameter calculations of the local spatial attention module and the full-channel correlation fusion module are as follows: 1. Local Spatial Attention Module The input to the local spatial attention module is , H and W These represent height and width, respectively. This represents the number of input channels, which is then evenly divided into 3 branches by Split (each branch has 10 channels). Each branch contains DW-D-Conv and ReLU, and they are finally merged using Concat. DW-D-Conv consists of two parts: depthwise dilated convolution and pointwise convolution. Deeply dilated convolution (2D, kernel=3×3, dilation rates r are 1, 2, and 3 respectively): Number of parameters per branch: ; Total number of parameters across 3 branches: ; Pointwise convolution (2D, kernel=1×1): Number of parameters per branch: ; Total number of parameters across 3 branches: .
[0031] 2. Full-channel correlation fusion module The input to the full-channel correlation fusion module is the output of the local spatial attention module. It includes a global pooling layer (GlobalPool), a Q / K fully connected layer, Softmax, and a 1×1 Conv. GlobalPool and Softmax have no parameters.
[0032] Q / K fully connected layer: after GlobalPool Feature mapping to dimension .
[0033] Number of parameters in a single fully connected layer: ; The total number of parameters Q and K is: ; 1×1 Conv: Input channel Output channel The number of parameters is: .
[0034] 3. Total number of parameters The total number of parameters is calculated by summing the parameters of each part: .
[0035] S4. Input the fused feature sequence into the detection head, perform iterative training, and save the model parameters with the best results.
[0036] In this embodiment, the detection head uses the YOLOv5 detection head. The input to the detection head is the feature sequence output by the Guided Focusing Feature Pyramid Network. The output has three scale branches adapted for small / medium / large target detection, respectively. Each scale of the detection head contains two parallel branches: regression and classification. These two branches are completely independent, sharing only the input feature map to avoid interference between tasks. The regression branch consists of two feature enhancement layers and an output layer. The feature enhancement layer consists of a 3×3 convolution, a batch normalization layer, and a SiLU activation function. The output layer consists of a 1×1 convolution. The classification branch has the same structure as the regression branch. The regression branch predicts the bounding box offset, and the classification branch predicts the target confidence plus the class.
[0037] The training uses a combined loss function, which is a weighted average of confidence loss, regression loss, and classification loss. The expression is as follows: , In the formula, Represents the total loss. Represents confidence loss. Represents regression loss, Represents classification loss, These represent different weight values.
[0038] The experimental environment was Windows 10, with an NVIDIA GeForce RTX 3060 GPU. Key hyperparameter settings were as follows: batch size of 8, SGD optimizer used, learning rate of 0.001, and 100 epochs.
[0039] S5 inputs the test set images into the detection model to identify and locate targets in the images.
[0040] To test the performance of the Guided Focusing Feature Pyramid Network (GF-FPN) proposed in this invention, this embodiment selected two backbone networks, Darknet53 and CSPDarknet. The experiments were compared and analyzed with the original Feature Pyramid Network (FPN) and the improved PANet feature fusion module in YOLOv8. Three different feature pyramid modules and two backbone networks were combined, using the same detection head and the same number of training epochs, to obtain the mAP50, mAP50-95, and AP50 values for each defect category for different models. The experimental results are recorded in Tables 1 and 2.
[0041] Table 1 Comparison results on the TinyIndus dataset
[0042] Table 1 shows that on the TinyIndus dataset, the two models using the GF-FPN module achieved the best and second-best detection results, respectively. With the Darknet53 backbone network, the GF-FPN model improved the mAP50 value by 4.7% and 7.4% compared to the PANet and FPN models, respectively, and the mAP50-95 value by 3.4% and 5.5%, respectively. With the CSPDarknet backbone network, the mAP50 value improved by 8.1% and 9.7%, respectively, and the mAP50-95 value by 2.6% and 5.3%, respectively. Table 3 shows the AP values for each defect category. Overall, GF-FPN improves the detection accuracy for different defect categories to a certain extent. However, the dataset itself and the backbone network also have a significant impact on defect detection. Pipe cracks, due to their small scale and susceptibility to interference from pipe texture, are the most difficult defect category to detect, resulting in generally low detection accuracy. However, using GF-FPN also shows a significant improvement.
[0043] As shown in Table 2, on the NEU-DET dataset, the model using GF-FPN improved the mAP50 value by 1.3% and 2.2% compared to the models using PANet and FPN, respectively, and improved the mAP50-95 value by 1.3% and 4.1%, respectively. With CSPDarknet as the backbone network, the mAP50 value improved by 2.8% and 5.7%, respectively, and the mAP50-95 value improved by 1.6% and 7.4%, respectively.
[0044] To further evaluate the model's computational complexity, inference time, and other performance metrics, this example uses the number of parameters, gigaflops per second (GFLOPs), and frames per second (FPS). The experimental results are shown in Table 3. The data in the table shows that the proposed GF-FPN model has 41.7M parameters; at an input resolution of 640×640, the architecture achieves an inference speed of 64.2 FPS and a floating-point computation of 166.9 GFLOPs. Compared to PANet, BiFPN, and AFPN, this model has fewer parameters and the lowest floating-point computation, achieving a balance between detection performance and computational efficiency. The reduction in the number of parameters is mainly attributed to the lightweight hierarchical attention module.
[0045] Overall, the experimental results demonstrate that the GF-FPN designed in this invention has better detection performance than FPN and PANet.
[0046] Table 2 Comparison results on the NEU-DET dataset
[0047] Table 3 Model Performance Comparison
[0048] The specific embodiments of the present invention have been described above. It should be understood that the present invention is not limited to the specific embodiments described above, and those skilled in the art can make various modifications or variations within the scope of the claims, which do not affect the essence of the present invention.
Claims
1. A small target detection method based on guided focusing feature pyramid network, characterized in that, Includes the following steps: S1, Obtain the small object detection dataset and divide the dataset into training set, validation set and test set; S2, input the training set image data into the backbone network, and extract features through different layers of the backbone network to obtain four feature maps of different scales: P2, P3, P4, and P5. S3, four feature maps of different scales are fed into a guided focusing feature pyramid network for feature fusion to obtain a feature sequence. The guided focusing feature pyramid network adopts a bidirectional fusion method, including: Feature Pyramid Network: The feature pyramid network adopts a top-down connection method, which transmits high-level semantic features to low-level layers through upsampling; Guided Focusing Network: The guided focusing network adopts a bottom-up connection approach and designs a lightweight hierarchical attention module to replace simple convolutional downsampling. While downsampling layer by layer, the attention map of the next layer is generated from the feature map of the previous layer. Then, star operation and residual connection are used to apply the attention weights to the feature map, thereby improving the ability to distinguish between the target and the background and achieving accurate focusing of key features. Specifically, the lightweight hierarchical attention module consists of a local spatial attention module and a full-channel correlation fusion module. The local spatial attention module extracts basic features and local contextual information through different receptive fields to obtain an initial spatial attention map. The full-channel correlation fusion module fuses cross-channel spatial information based on the initial spatial attention map, establishes the correlation between features of different receptive fields, and adjusts the number of channels to adapt to star-shaped operations. S4. Input the fused feature sequence into the detection head, perform iterative training, and save the model parameters with the best results. S5 inputs the test set images into the detection model to identify and locate targets in the images.
2. The small target detection method based on guided focusing feature pyramid network as described in claim 1, characterized in that, The implementation process of the local spatial attention module is as follows: First, the input feature map is split into three parts by channel to reduce the amount of computation; Then, deep dilated convolutions with dilation rates of 1, 2, and 3, and the ReLU activation function are used to expand the receptive field and extract local contextual information. Finally, these three parts are spliced together along the channel dimension.
3. The small target detection method based on guided focusing feature pyramid network as described in claim 1, characterized in that, The full-channel correlation fusion module is implemented as follows: First, the spatial dimension is compressed, condensing the spatial information of each channel into a vector containing two elements, resulting in the global descriptor of the channel. Global average pooling and max pooling are used here: , , in, The feature matrix representing the c-th channel of the input features. H , W They are height and width, respectively. This represents the output value of the c-th channel after global average pooling. This represents the output value of the c-th channel after max pooling, where max() represents taking the maximum value. From this, we can obtain the global description vector of the c-th channel. The global descriptor for all channels can be represented as ; Next, the query vector Q and the key vector K are generated through two linear transformations: , In the formula, , It is a learnable linear transformation matrix; Next, attention weights between channels are calculated to dynamically measure the strength of the association. Specifically, the association score between channels is calculated based on the similarity between Q and K, and then normalized to obtain the weight matrix A. , In the formula, softmax() represents the normalization function; By weighting and summing the input features using the attention weight matrix, we obtain the full-channel fused output features: , In the formula, This represents the output characteristic of the c-th channel; Finally, the number of channels is adjusted by 1×1 convolution to obtain the attention guidance map.
4. The small target detection method based on guided focusing feature pyramid network as described in claim 1, characterized in that, The four different scale feature maps P2, P3, P4, and P5 are downsampled by 4, 8, 16, and 32 times respectively from the original image.
5. The small target detection method based on guided focusing feature pyramid network as described in claim 1, characterized in that, The aforementioned guided focusing feature pyramid network is a plug-and-play structure that can be used in conjunction with backbone networks Darknet53 and CSPDarknet.
6. The small target detection method based on guided focusing feature pyramid network as described in claim 1, characterized in that, The detection head uses a decoupled design of YOLOv5: regression and classification use two completely independent branches that do not interfere with each other.
7. The small target detection method based on guided focusing feature pyramid network as described in claim 1, characterized in that, The iterative training described uses a combined loss function, which consists of a weighted average of confidence loss, regression loss, and classification loss.