A sar directed target detection method based on multi-scale context perception
By employing a multi-scale context-aware SAR directional target detection method, the problems of large target scale differences, strong background clutter interference, and complex orientation in SAR images are solved, achieving high-precision directional target detection and orientation estimation, and improving the robustness and adaptability of detection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-20
- Publication Date
- 2026-03-31
AI Technical Summary
SAR images suffer from large differences in target scale, strong background clutter interference, arbitrary and variable target orientation, and complex scattering characteristics, leading to problems such as low detection accuracy, high false alarm rate, and inaccurate orientation estimation.
A multi-scale context-aware SAR directional target detection method is adopted, including a multi-scale dynamic feature enhancement network guided by scattering characteristics, a task-adaptive regional context-aware module, a decoupled progressively refined directional detection head, and a multi-task joint training strategy including semantic consistency loss. Through multi-level feature extraction and fusion, the target category, directional bounding box, and orientation angle are predicted collaboratively.
It significantly improves the accuracy and robustness of directional target detection in SAR images, especially in real-world reconnaissance scenarios with scarce samples and complex backgrounds, demonstrating better generalization ability and adaptability.
Smart Images

Figure CN121582554B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of remote sensing image processing and computer vision technology, specifically relating to a SAR directional target detection method based on multi-scale context awareness. Background Technology
[0002] Synthetic Aperture Radar (SAR), as an active microwave imaging sensor, possesses all-weather, all-day operational capabilities, playing an irreplaceable role in fields such as Earth observation, military reconnaissance, and disaster assessment. Directed target detection in SAR images—which involves not only locating the position of a target of interest in an image but also accurately describing its orientation using a oriented bounding box—is a core and challenging task in SAR image interpretation. Accurate directed detection results are crucial for subsequent high-level applications such as target recognition and situational awareness.
[0003] However, the inherent characteristics of SAR images and the complexity of targets pose serious challenges to directional target detection: (1) huge differences in target scale; (2) severe background clutter interference; (3) arbitrary and variable target orientation; (4) complex target scattering characteristics. Summary of the Invention
[0004] The purpose of this invention is to address the shortcomings of existing technologies by providing a SAR directional target detection method based on multi-scale context awareness. This method aims to solve problems such as low detection accuracy, high false alarm rate, and inaccurate direction estimation caused by large differences in target scale, strong background clutter interference, arbitrary and variable target orientation, and complex scattering characteristics in SAR images.
[0005] To achieve the above objectives, this invention provides a SAR directional target detection method based on multi-scale context awareness, comprising the following steps:
[0006] S1. Acquire SAR images and perform preprocessing and prior coding of scattering features;
[0007] S2. Construct a multi-scale dynamic feature enhancement network guided by scattering characteristics to extract and enhance the multi-level feature representation of SAR images;
[0008] S3. Introduce a task-adaptive region context awareness module, which integrates local features, spatial context and semantic context information to generate enhanced features with stronger discriminative power.
[0009] S4. Construct a decoupled progressively refined directed detection head to collaboratively predict target category, directed bounding box, and orientation angle;
[0010] S5. Employ a multi-task joint training strategy that includes semantic consistency loss to train the network end-to-end.
[0011] S6. During the inference phase, the input SAR image is forward-propagated, and the target category, refined directed bounding box, and orientation angle are output.
[0012] Furthermore, the acquisition of SAR images and the preprocessing and prior coding of scattering features in S1 specifically include the following:
[0013] S1.1 SAR Image Acquisition and Radiometric Calibration: Raw SAR image data is acquired through a synthetic aperture radar system. Radiometric calibration is then performed, converting the raw digital quantization values into a backscattering coefficient image. To eliminate the influence of the sensor system response, this calibration process is performed pixel-by-pixel, and its core calculation formula is:
[0014]
[0015] in, For position The original digitized value of each pixel. This is a calibration constant, which depends on the radar system parameters;
[0016] S1.2 Speckle Noise Suppression: An adaptive filtering algorithm is used to denoise the radiometrically calibrated backscattering coefficient image to suppress speckle noise and improve the image signal-to-noise ratio. Taking Lee filtering as an example, the filtered image... It can be represented as:
[0017]
[0018] in, The image shows the backscattering coefficients obtained after calibration as described in S1.1. It is a local mean. The adaptive weighting coefficients are determined by the local variance and the mean.
[0019] S1.3 Image Standardization: The pixel values of the denoised SAR image are standardized to map them to a numerical range suitable for neural network processing. The Z-Score standardization method is used to obtain the standardized image. :
[0020]
[0021] in, and These are the pixel mean and standard deviation of the entire image, respectively.
[0022] S1.4, Prior coding of scattering features: The specific implementation includes the following three sub-steps:
[0023] S1.4.1 Strong Scattering Point Extraction: Strong scattering points in SAR images are adaptively extracted using constant false alarm rate (CFAR) detection technology. Its mathematical expression is as follows:
[0024]
[0025] in, The detection threshold is dynamically calculated based on the statistical characteristics of the background region surrounding the pixel. These statistical characteristics include the mean and standard deviation of the region. This threshold can effectively adapt to changes in background clutter intensity in different regions.
[0026] S1.4.2, Local Scattering Moment Calculation: Within a sliding window across multiple scales, the local statistical moment features of the image are calculated to construct a multi-channel scattering feature descriptor. Specifically, this includes:
[0027] First moment: mean, reflecting the average scattering intensity of a local area;
[0028] Second moment: variance, reflecting the degree of fluctuation in scattering intensity;
[0029] Third moment: skewness, reflecting the asymmetry of the scattering distribution;
[0030] Fourth-order moment: Kurtosis, which reflects the sharpness of the scattering distribution.
[0031] These statistical moments together constitute a feature map describing the scattering texture characteristics of a local region. .
[0032] S1.4.3 Prior Image Fusion: The strong scattering point map and the scattering moment feature map are concatenated through channels to form a prior image of scattering features. :
[0033]
[0034] in, This indicates that a tensor stitching operation is performed along the channel dimension. This prior image will be input into the subsequent feature extraction network along with the original SAR image as guiding information for scattering characteristics.
[0035] Furthermore, in S2, a multi-scale dynamic feature enhancement network guided by scattering characteristics is constructed to extract and enhance the multi-level feature representation of SAR images, specifically including the following:
[0036] S2.1, Multi-scale Feature Pyramid Construction: Constructing the preprocessed SAR image output from S1. Prior map of scattering features Channel splicing is performed to form a network input. ; Utilizing the backbone network Feature extraction is performed to obtain multi-level feature maps. Subsequently, a feature pyramid network is used to fuse deep semantic information with shallow detail information to generate multi-scale feature maps. The calculation process is as follows:
[0037]
[0038]
[0039]
[0040]
[0041] in, This represents a 1×1 convolution, used to adjust the number of channels. This indicates a 2x upsampling operation.
[0042] S2.2 Spatial Attention Modulation Guided by Scattering Characteristics: To enhance the network's ability to focus on the target scattering region, spatial attention modulation is implemented at each pyramid level. A scattering-guided spatial attention module is then introduced; this module first processes the scattering feature prior map. Downsampling to the same level using bilinear interpolation For the same space dimensions, Then and Common input generates a spatial attention weight map. :
[0043]
[0044] in, This represents a 3×3 convolution. for Activation function; utilizing The original features are modulated to obtain the enhanced features. :
[0045]
[0046] in, This indicates element-wise multiplication. Modulated features. It can more effectively highlight the potential areas of the target.
[0047] S2.3 Dynamic Receptive Field Enhancement: To capture the contextual information of SAR targets at different scales, modulated features are enhanced. Parallel multi-branch dilated convolution processing is performed; the branches include:
[0048] Branch 1 (Local Details): 1×1 standard convolution, preserving original feature information;
[0049] Branch 2 (Medium Context): 3×3 dilated convolution, dilation rate Expand the sensory field;
[0050] Branch 3 (Large Context): 3×3 dilated convolution, dilation rate Capture wide-area context;
[0051] Branch 4 (Global Context): Global average pooling followed by a 1×1 convolution and... The function upsamples back to the original size, providing image-level semantic guidance.
[0052] The outputs of each branch are concatenated along the channel dimension to obtain a feature representation that incorporates multi-scale contextual information:
[0053]
[0054] in, Let represent the processing function of the i-th branch for the input features. This is for channel splicing operations.
[0055] S2.4, Cross-scale adaptive fusion: This involves integrating the enhanced features obtained from each level in S2.3. By unifying the channels to the same number using 1×1 convolution, we obtain... Through an inter-scale attention module, the fusion weights of features at different scales at each spatial location are learned; for each level Calculate its spatial weight map :
[0056]
[0057] All and Upsampling to maximum scale (and) Consistent), then proceeding along the scale dimension. Normalization yields a normalized weighted graph. Ultimately, cross-scale adaptive fusion features Calculated by the following formula:
[0058]
[0059] in, This indicates element-wise multiplication.
[0060] Furthermore, S3 introduces a task-adaptive region context-aware module that fuses local features, spatial context, and semantic context information to generate more discriminative enhanced features, specifically including the following:
[0061] S3.1, Region Candidate Generation and Local Feature Alignment: The fused feature map output from S2 is... The input is fed into a region proposal network, which generates a series of candidate regions that may contain the target by setting anchor points of different scales and aspect ratios on the feature map and combining them with a preset confidence threshold. Each candidate region is parameterized by the center coordinates, width, and height of a rectangle.
[0062] To extract fixed-dimensional feature representations from these candidate regions of different sizes, a method is employed. This operation, based on the coordinates of each candidate box, interpolates the feature map using bilinear interpolation. The feature map of a fixed size (e.g., 7×7) is accurately extracted from the image, and denoted as... .
[0063] S3.2 Spatial Context Aware Submodule: To model the relative spatial relationship between the target and its surrounding environment, a spatial context aware submodule is constructed; this submodule is based on... As input, perform the following operations:
[0064] S3.2.1 Feature Transformation: Transforming the input feature map The data is transformed into query feature maps through two independent 1×1 convolutional layers. Bond feature map Both are used to calculate the correlation between different spatial locations in the feature map.
[0065] S3.2.2 Spatial Attention Calculation: Subsequently, and Flatten it into a two-dimensional matrix and calculate the spatial attention matrix. :
[0066]
[0067] in, for The number of channels is used as a scaling factor to stabilize training. The function is normalized row by row;
[0068] S3.2.3, Context Feature Reconstruction: Simultaneously, Features are obtained through a third 1×1 convolutional layer. and with Multiplying yields the spatial context-enhanced features. :
[0069]
[0070] S3.3, Semantic Context Aware Submodule: To incorporate broader image-level semantic context information, a semantic context aware submodule is constructed; the input of this submodule is the entire fused feature map. :
[0071] S3.3.1, Global Context Extraction: [This section appears to be incomplete and requires further context.] Perform global average pooling to obtain an image-level global context vector. ;
[0072] S3.3.2 Semantic Modulation Vector Generation: This global context vector... A semantic modulation vector is generated through a transform network consisting of fully connected layers and ReLU activation functions. ;
[0073] S3.3.3, Semantic Information Injection: [This section appears to be incomplete and requires further context.] With each feature Perform channel-by-channel multiplication to achieve adaptive injection of semantic context information:
[0074]
[0075] S3.4 Task-Adaptive Feature Fusion: Integrating Local Features Spatial context features and semantic context features By concatenating the features, a rich joint feature representation is obtained. :
[0076]
[0077] To adaptively optimize this joint feature, it is fed into a lightweight task-adaptive weight learning network. This network consists of a small multilayer perceptron, and its output is a three-dimensional weight tensor. The tensor and Same dimensions, and feature recalibration performed through element-wise multiplication:
[0078]
[0079] in, This refers to the enhanced features that are more discriminative after being processed by the region context awareness module, which will serve as the input for the subsequent directed detection head.
[0080] Furthermore, in S4, a decoupled progressively refined directed detection head is constructed to collaboratively predict the target category, directed bounding box, and orientation angle, specifically including the following:
[0081] S4.1 Decoupled Detection Head Construction: Design a decoupled detection head with three independent branches, used for object classification, directed bounding box regression, and orientation angle prediction, respectively. The three branches share the enhanced features output by S3. Each part serves as input, but each has its own independent network parameters, thereby achieving task decoupling and avoiding conflicts between different tasks (classification and localization);
[0082] S4.1.1 Classification Branch: This branch consists of two fully connected layers. The first fully connected layer is followed by a ReLU activation function, and the second fully connected layer outputs the unnormalized classification score. Finally, through... The function obtains the probability distribution of the candidate region belonging to each category and outputs the classification confidence score. ,in Total number of categories;
[0083] S4.1.2, Directed Bounding Box Regression Branch: Consists of two fully connected layers, outputting the geometric parameters of the directed bounding box. This is used to refine the position and size of the candidate boxes;
[0084] S4.1.3, Orientation Angle Prediction Branch: This branch uses a hybrid representation method to accurately predict the target's orientation; firstly, the continuous angle prediction problem is transformed into a problem combining classification and regression: The angle range is evenly divided into There are several angled warehouses, among which... This is a preset positive integer, typically set based on a trade-off between the required accuracy of angle estimation and computational complexity; the network also outputs the confidence score for each angle bin. and the angular residual vector within each compartment , of which element Corresponding to the The residuals within each angle bin; finally, combining the angle bin index with the highest confidence level. And its residuals, calculate the final angle prediction value. :
[0085]
[0086] in, for Functions used to convert residuals Mapping to the [0, 1) interval enables refined regression within the silo. for ;
[0087] S4.2 Progressive Refinement Mechanism: To address the issue of inaccurate target localization and angle estimation in complex scenarios, a progressive refinement mechanism is introduced; this mechanism repeatedly executes the decoupled detection head described in S4.1. Next (referred to as) (Several refining stages), each stage uses the directed bounding box and orientation angle predicted in the previous stage as input proposals for the current stage, and performs iterative optimization;
[0088] S4.2.1 Feature Re-extraction: To preserve more spatial details to support accurate localization, shallow feature maps with higher spatial resolution are selected. Perform feature re-extraction. For the first... The refining stage no longer directly uses the features of the S3 module, but instead uses features based on the first... The directed bounding box predicted in stages, using Operation from the main feature map Re-extracting features from the middle:
[0089]
[0090] in, Indicates the first The directed bounding box parameters predicted in the stage, where 7 indicates that the output feature map size is 7×7 pixels. It is a region feature alignment operation used to accurately extract a fixed-size feature map from the feature map that corresponds to the input bounding box.
[0091] S4.2.2 Angle-aware feature enhancement: In order to explicitly incorporate directional information into the feature representation, the angle-aware feature enhancement is performed on the first... The direction angle predicted in the stage Perform sine-cosine encoding:
[0092]
[0093] The encoded vector By replicating and expanding along spatial dimensions, a space with a size of The feature map, at each spatial location The channel vectors on are all Then, this angular feature map is compared with the re-extracted features. Perform channel splicing:
[0094]
[0095] in, This indicates the spatial dimension expansion operation described above.
[0096] S4.2.3 Refined Prediction: Incorporating Angle-Aware Features Enter to the number The decoupled detection head at each stage predicts the refined classification confidence level. Bounding box offset and direction angle .
[0097]
[0098]
[0099]
[0100] in, , and They represent the first Learnable parameterized functions used in the staged detection head for classification, bounding box regression, and orientation angle prediction.
[0101] S4.3, Collaborative Prediction and Output: After... After several stages of progressive refinement, the prediction result of the last stage is selected as the final output; finally, for each valid detection proposal, the model collaboratively outputs its target category. Refined directed bounding boxes and the final direction angle This completes a comprehensive description of the directed objective.
[0102] Furthermore, S5 employs a multi-task joint training strategy that includes semantic consistency loss to train the network end-to-end, specifically including the following:
[0103] S5.1 Construction of Multi-Task Loss Function: The overall loss function of the network. It consists of four core components: classification loss Directed box regression loss Angle-based loss prediction And the semantic consistency loss introduced in this invention Together they constitute, and their mathematical expression is:
[0104]
[0105] in, , , , This is a hyperparameter used to balance the weights of each loss term.
[0106] S5.2 Loss Calculation for Each Task: Specific loss functions were designed for different learning tasks.
[0107] S5.2.1 Classification Loss To address the severe imbalance between foreground and background class samples in SAR image target detection, a focusing loss function is employed. This loss function reduces the weight of easily classified samples through a dynamic scaling factor, allowing the model training to focus more on difficult-to-classify samples. Its definition is as follows:
[0108]
[0109] in, It is the probability of the target class predicted by the model. It is a balancing factor. It is a modulation factor used to reduce the weight of easily distinguishable samples, so that the model focuses on difficult samples.
[0110] S5.2.2, Directed Box Regression Loss :use The loss is used to optimize the precise location and size of the directed bounding box; for the truth box parameters... and predicted value The loss is calculated as follows:
[0111]
[0112] S5.2.3 Angle Prediction Loss This loss is classified as an angle warehouse loss. and angle residual regression loss It consists of two parts:
[0113] Cross-entropy loss is used to correctly classify the angle bin to which the target belongs.
[0114] use The loss is calculated only on the angle bins that are the same as the true angle, and is used for the angle residuals within the fine regression bins.
[0115] The total loss for angle prediction is:
[0116]
[0117] in, It is the weighting coefficient of the residual loss.
[0118] S5.3 Semantic Consistency Loss Calculation: To enhance the robustness and discriminativeness of the model's feature representation, a semantic consistency loss is introduced. This loss is augmented to generate two different views for each training sample. and The two views are input into the network respectively, and the enhanced features are output from the S3 module. Above, for those belonging to the same goal Cosine similarity is calculated for features to narrow the distance between feature representations of the same target in different views. The calculation formula is as follows:
[0119]
[0120] in, Representing vectors and Cosine similarity between them It is a temperature hyperparameter used to adjust the sensitivity of the loss function to difficult negative samples. It is an indicator function if and only if The time value is 1.
[0121] S5.4, Incremental Refining Stage Loss Aggregation: For those containing The detection head in the refining stage, the total loss It is the weighted sum of losses from all refining stages:
[0122]
[0123] in, It is the first The total loss for each refining stage is calculated based on S5.1 to S5.3. It is the first The loss weight for each stage is set to That is, it increases as the refining stage progresses. This is to maximize the contribution of the final stage prediction to the loss.
[0124] S5.5 End-to-end training: Minimize the overall loss using stochastic gradient descent or the AdamW optimizer. Simultaneously, backpropagation and updates are performed on all trainable parameters in the network, thereby achieving end-to-end joint training of the entire model.
[0125] Furthermore, in the inference phase of S6, the input SAR image is forward-propagated, and the target category, refined directed bounding box, and orientation angle are output, specifically including the following:
[0126] S6.1 Model Loading and Input Image Preprocessing: During the deployment and inference phase, the optimal model parameters obtained through S5 training are first loaded; subsequently, the input SAR image to be detected is preprocessed. Perform the same preprocessing operations as S1, including radiometric calibration, speckle noise suppression, and image normalization, to obtain a normalized image. And generate a priori scattering feature map according to the method described in S1.4. Finally, and Channel splicing is performed to form a network input. ;
[0127] S6.2 Forward Propagation and Feature Extraction: Input the preprocessed network... Input into the network, passing through in sequence:
[0128] The scattering characteristic-guided multi-scale dynamic feature enhancement network described in S2 obtains fused features. ;
[0129] The task-adaptive region context awareness module described in S3 generates more discriminative region features;
[0130] The decoupled progressively refined directed detection head described in S4, after T stages of refinement, finally outputs the prediction results of all candidate regions in stage T, including: classification confidence. Refined bounding box offset and direction angle .
[0131] S6.3 Post-processing and result generation:
[0132] S6.3.1 Bounding Box Decoding and Angle Mapping: Using the bounding box offset obtained in S6.2 Based on the initial region proposal, the final directed bounding box is decoded to determine its position and size in the actual image coordinate system. At the same time, the predicted direction angle The internal representation of the model is mapped back to the actual radian or angle value.
[0133] S6.3.2 Confidence Filtering and Non-Maximum Suppression: First, based on the confidence level of the classification branch output... Filter out all data below the preset threshold. The low-confidence candidate boxes are identified; subsequently, for the remaining candidate boxes of the same category, a non-maximum suppression method oriented towards directed bounding boxes is applied. The calculation process of this method is as follows:
[0134] For a specific category, calculate the directed pairs between all candidate boxes. ;
[0135] Based on the calculated directed Matrix, remove those candidate boxes with higher confidence scores. Exceeding the preset threshold Redundant boxes;
[0136] S6.4 Final Detection Result Output: After post-processing in S6.3, the system outputs a final list of detection results; for each detected target retained in the list... Output its:
[0137] Target Category Take the category label with the highest classification confidence score;
[0138] Refined directed bounding box : using quadruplets It can be represented by the coordinates of its center point, width, and height, or by the coordinates of the vertices of the polygon;
[0139] Direction angle : Indicates the direction of the principal axis of the target, in radians or degrees;
[0140] Detection confidence This refers to the maximum classification probability value of the category to which the target belongs.
[0141] Finally, the system outputs all detected directed targets and their attributes in the form of structured data, completing the entire SAR image directed target detection process.
[0142] Beneficial Effects: This invention organically combines physical detection mechanisms with deep learning models through a multi-scale dynamic feature enhancement network guided by scattering characteristics, a task-adaptive region context awareness module, a decoupled progressively refined directed detection head, and a multi-task training strategy incorporating semantic consistency loss. This effectively solves the detection challenges in SAR images caused by large target scale differences, strong background clutter interference, and complex orientation changes. Compared with traditional methods, this invention significantly improves the accuracy and robustness of directed target detection, especially in real-world reconnaissance scenarios with scarce samples and complex backgrounds, demonstrating superior generalization ability and adaptability. Attached Figure Description
[0143] Figure 1 This is a schematic diagram of the overall process of the present invention;
[0144] Figure 2 This is a schematic diagram of the preprocessing and prior coding of scattering features in this invention;
[0145] Figure 3 This is a schematic diagram of the multi-scale dynamic feature enhancement network structure guided by scattering characteristics in this invention;
[0146] Figure 4 This is a schematic diagram of the task-adaptive region context-aware module structure in this invention;
[0147] Figure 5 This is a schematic diagram of the working process of the decoupled progressive refining directional detection head in this invention;
[0148] Figure 6 This is a flowchart of the loss calculation and parameter update process for the multi-task joint training strategy in this invention;
[0149] Figure 7 This is a schematic diagram of the post-processing and result generation process in the reasoning stage of this invention. Detailed Implementation
[0150] The invention will now be further described with reference to the accompanying drawings.
[0151] Example
[0152] like Figure 1 As shown, a SAR directional target detection method based on multi-scale context awareness includes the following steps:
[0153] S1. Acquire SAR images and perform preprocessing and prior coding of scattering features;
[0154] S2. Construct a multi-scale dynamic feature enhancement network guided by scattering characteristics to extract and enhance the multi-level feature representation of SAR images;
[0155] S3. Introduce a task-adaptive region context awareness module, which integrates local features, spatial context and semantic context information to generate enhanced features with stronger discriminative power.
[0156] S4. Construct a decoupled progressively refined directed detection head to collaboratively predict target category, directed bounding box, and orientation angle;
[0157] S5. Employ a multi-task joint training strategy that includes semantic consistency loss to train the network end-to-end.
[0158] S6. During the inference phase, the input SAR image is forward-propagated, and the target category, refined directed bounding box, and orientation angle are output.
[0159] Furthermore, such as Figure 2 As shown, the specific steps in S1 for acquiring SAR images and performing preprocessing and prior coding of scattering features are as follows:
[0160] S1.1 SAR Image Acquisition and Radiometric Calibration: Raw SAR image data is acquired through a synthetic aperture radar system. Radiometric calibration is then performed, converting the raw digital quantization values into a backscattering coefficient image. To eliminate the influence of the sensor system response, this calibration process is performed pixel-by-pixel, and its core calculation formula is:
[0161]
[0162] in, For position The original digitized value of each pixel. This is a calibration constant, which depends on the radar system parameters;
[0163] S1.2 Speckle Noise Suppression: An adaptive filtering algorithm is used to denoise the radiometrically calibrated backscattering coefficient image to suppress speckle noise and improve the image signal-to-noise ratio. Taking Lee filtering as an example, the filtered image... It can be represented as:
[0164]
[0165] in, The image shows the backscattering coefficients obtained after calibration as described in S1.1. It is a local mean. The adaptive weighting coefficients are determined by the local variance and the mean.
[0166] S1.3 Image Standardization: Perform Z-Score standardization on the denoised SAR image. Calculate the pixel mean of the entire image. and standard deviation Then, standardization is performed:
[0167]
[0168] in, and These are the pixel mean and standard deviation of the entire image, respectively.
[0169] S1.4, Prior coding of scattering features:
[0170] S1.4.1, Strong Scattering Point Extraction: Strong scattering points are extracted using the CFAR detection algorithm, resulting in a strong scattering point map. The calculation formula is:
[0171]
[0172] S1.4.2 Calculation of Local Scattering Moments: Calculate four local scattering moment characteristics within a 9×9 sliding window:
[0173]
[0174]
[0175]
[0176]
[0177] The above four statistics together constitute the local scattering moment characteristic map of the four channels. .
[0178] S1.4.3 Prior Image Fusion: The strong scattering point map and the scattering moment feature map are concatenated through channels to form a prior image of scattering features. :
[0179]
[0180] This prior image will be input into the subsequent feature extraction network along with the original SAR image, serving as guiding information for scattering characteristics.
[0181] Furthermore, such as Figure 3 As shown, in step S2, a multi-scale dynamic feature enhancement network guided by scattering characteristics is constructed to extract and enhance the multi-level feature representation of SAR images. The specific steps are as follows:
[0182] S2.1, Multi-scale Feature Pyramid Construction: Constructing the preprocessed SAR image output from S1. Prior map of scattering features Channel splicing is performed to form a network input. The input is processed through a ResNet-50-based backbone network to extract features, resulting in feature maps at four levels. The computational process for generating multi-scale feature maps using a feature pyramid network is as follows:
[0183]
[0184]
[0185]
[0186]
[0187] in, This represents a 1×1 convolution, used to adjust the number of channels. This indicates a 2x upsampling operation.
[0188] S2.2 Spatial Attention Modulation Guided by Scattering Characteristics: To enhance the network's ability to focus on the target scattering region, spatial attention modulation is implemented at each pyramid level. A scattering-guided spatial attention module is then introduced; this module first processes the scattering feature prior map. Downsampling to the same level using bilinear interpolation For the same space dimensions, Then and Common input generates a spatial attention weight map. :
[0189]
[0190] in, for Activation function; utilizing The original features are modulated to obtain the enhanced features. :
[0191]
[0192] S2.3 Dynamic Receptive Field Enhancement: To capture the contextual information of SAR targets at different scales, modulated features are enhanced. Parallel multi-branch dilated convolution processing is performed; the branches include:
[0193] Branch 1 (Local Details): 1×1 standard convolution, preserving original feature information;
[0194] Branch 2 (Medium Context): 3×3 dilated convolution, dilation rate Expand the sensory field;
[0195] Branch 3 (Large Context): 3×3 dilated convolution, dilation rate Capture wide-area context;
[0196] Branch 4 (Global Context): Global average pooling followed by a 1×1 convolution and... The function upsamples back to the original size, providing image-level semantic guidance.
[0197] The outputs of each branch are concatenated along the channel dimension to obtain a feature representation that incorporates multi-scale contextual information:
[0198]
[0199] in, Representing the The processing results of each branch.
[0200] S2.4, Cross-scale adaptive fusion: This involves integrating the enhanced features obtained from each level in S2.3. By unifying the channels to the same number using 1×1 convolution, we obtain... Through an inter-scale attention module, the fusion weights of features at different scales at each spatial location are learned; for each level Calculate its spatial weight map :
[0201]
[0202] All and Upsampling to maximum scale (and) Consistent), then proceeding along the scale dimension. Normalization yields a normalized weighted graph. Ultimately, cross-scale adaptive fusion features Calculated by the following formula:
[0203]
[0204] in, This indicates element-wise multiplication.
[0205] Furthermore, such as Figure 4 As shown, S3 introduces a task-adaptive region context awareness module, which fuses local features, spatial context, and semantic context information to generate more discriminative enhanced features. The specific steps are as follows:
[0206] S3.1, Region Candidate Generation and Local Feature Alignment: The fused feature map output from S2 is... The input is fed into a region proposal network, which generates 300 candidate regions by setting anchor points on the feature map at five scales (32, 64, 128, 256, 512) and three aspect ratios (0.5, 1.0, 2.0). Utilizing... Operation, based on the coordinates of each candidate box from Extract a feature map of fixed size:
[0207]
[0208] in This represents the coordinates of the candidate bounding box, and 7 indicates that the output feature map size is 7×7 pixels. .
[0209] S3.2 Spatial Context Awareness Submodule: This submodule is based on a multi-head self-attention mechanism, and its specific implementation is as follows:
[0210] S3.2.1 Feature Transformation: [The text abruptly ends here, likely due to an incomplete sentence or a formatting error.] The query matrix is obtained by flattening the matrix to 49×256 and performing three independent linear transformations. Bond matrix Sum matrix :
[0211]
[0212]
[0213]
[0214] S3.2.2 Spatial Attention Calculation: An 8-head attention mechanism is adopted to calculate spatial attention. , , The space is divided into eight 32-dimensional subspaces, and the attention weights are calculated in each subspace:
[0215]
[0216] S3.2.3 Feature Reconstruction: After concatenating the attention outputs of each head, a linear transformation is performed to obtain spatial context-enhanced features:
[0217]
[0218] S3.3, Semantic Context Aware Submodule:
[0219] S3.3.1, Global Context Extraction: [This section appears to be incomplete and requires further context.] Perform global average pooling:
[0220]
[0221] in The feature map space size, .
[0222] S3.3.2 Semantic Modulation Vector Generation: The global context vector is generated through a two-layer fully connected network.
[0223]
[0224] in, and These are the weight matrices for the first and second fully connected layers, respectively. and These are the bias vectors for the first and second fully connected layers, respectively. for Activation function for function.
[0225] S3.3.3, Semantic Information Injection: [This section appears to be incomplete and requires further context.] With each feature Perform channel-by-channel multiplication to achieve adaptive injection of semantic context information:
[0226]
[0227] S3.4 Task-Adaptive Feature Fusion: Integrating Local Features Spatial context features and semantic context features By concatenating the features, a rich joint feature representation is obtained. :
[0228]
[0229]
[0230] The final enhanced features are:
[0231]
[0232] in, This refers to the enhanced features that are more discriminative after being processed by the region context awareness module, which will serve as the input for the subsequent directed detection head.
[0233] Furthermore, such as Figure 5 As shown, in step S4, a decoupled progressively refined directed detection head is constructed to collaboratively predict the target category, directed bounding box, and orientation angle. The specific steps are as follows:
[0234] S4.1 Decoupled Detection Head Construction: Design a decoupled detection head with three independent branches, used for object classification, directed bounding box regression, and orientation angle prediction, respectively. The three branches share the enhanced features output by S3. As input, but each has its own independent network parameters, thereby achieving task decoupling and avoiding conflicts between classification tasks and localization tasks;
[0235] S4.1.1 Classification Branch: This branch consists of two fully connected layers. The first fully connected layer is followed by a ReLU activation function, and the second fully connected layer outputs the unnormalized classification score. Finally, through... The function obtains the probability distribution of the candidate region belonging to each category and outputs the classification confidence score. ,in Total number of categories;
[0236] S4.1.2, Directed Bounding Box Regression Branch: Consists of two fully connected layers, outputting the geometric parameters of the directed bounding box. This is used to refine the position and size of the candidate boxes;
[0237] S4.1.3, Orientation Angle Prediction Branch: This branch uses a hybrid representation method to accurately predict the target's orientation; firstly, the continuous angle prediction problem is transformed into a problem combining classification and regression: The angle range is evenly divided into There are several angled warehouses, among which... This is a preset positive integer, typically set based on a trade-off between the required accuracy of angle estimation and computational complexity; the network also outputs the confidence score for each angle bin. and the angular residual vector within each compartment , of which element Corresponding to the The residuals within each angle bin; finally, combining the angle bin index with the highest confidence level. And its residuals, calculate the final angle prediction value. :
[0238]
[0239] in, for Functions used to convert residuals Mapping to the [0, 1) interval enables refined regression within the silo. for ;
[0240] S4.2 Progressive Refinement Mechanism: To address the issue of inaccurate target localization and angle estimation in complex scenarios, a progressive refinement mechanism is introduced; this mechanism includes... Each stage is a refining phase, in which the decoupled detection head described in S4.1 is executed, and each stage uses the directed bounding box and orientation angle predicted by the previous stage as the input proposal for the current stage to perform iterative optimization.
[0241] S4.2.1 Feature Re-extraction: For the first... The refining stage no longer directly uses the features of the S3 module, but instead uses features based on the first... The directed bounding box predicted in stages, using Operation from the main feature map Re-extracting features from the middle:
[0242]
[0243] S4.2.2 Angle-aware feature enhancement: In order to explicitly incorporate directional information into the feature representation, the angle-aware feature enhancement is performed on the first... The direction angle predicted in the stage Perform sine-cosine encoding:
[0244]
[0245] The encoded vector Expanding in spatial dimensions to form a dimension of The feature map, at each spatial location The channel vectors on are all Then, this angular feature map is compared with the re-extracted features. Perform channel splicing:
[0246]
[0247] in, This indicates the spatial dimension expansion operation described above.
[0248] S4.2.3 Refined Prediction: Incorporating Angle-Aware Features Enter to the number The decoupled detection head at each stage predicts the refined classification confidence level. Bounding box offset and direction angle .
[0249]
[0250]
[0251]
[0252] S4.3, Collaborative Prediction and Output: After... After several stages of progressive refinement, the prediction result of the last stage is selected as the final output; finally, for each valid detection proposal, the model collaboratively outputs its target category. Refined directed bounding boxes and the final direction angle This completes a comprehensive description of the directed objective.
[0253] Furthermore, such as Figure 6 As shown, step S5 employs a multi-task joint training strategy that includes semantic consistency loss to train the network end-to-end. The specific steps are as follows:
[0254] S5.1 Construction of Multi-Task Loss Function: To achieve collaborative optimization of classification, localization, and orientation angle prediction, a comprehensive multi-task loss function was designed. The overall loss function of the network is... It consists of four core components: classification loss Directed box regression loss Angle-based loss prediction And the semantic consistency loss introduced in this invention Together they constitute, and their mathematical expression is:
[0255]
[0256] in, , , , This is a hyperparameter used to balance the weights of each loss term.
[0257] S5.2 Loss Calculation for Each Task: Specific loss functions were designed for different learning tasks.
[0258] S5.2.1 Classification Loss Its definition is as follows:
[0259]
[0260] in, It is the probability of the target class predicted by the model. It is a balancing factor. It is a modulation factor used to reduce the weight of easily distinguishable samples, so that the model focuses on difficult samples.
[0261] S5.2.2, Directed Box Regression Loss :use The loss is used to optimize the precise location and size of the directed bounding box; for the truth box parameters... and predicted value The loss is calculated as follows:
[0262]
[0263] S5.2.3 Angle Prediction Loss This loss is classified as an angle warehouse loss. and angle residual regression loss It consists of two parts:
[0264] Cross-entropy loss is used to correctly classify the angle bin to which the target belongs.
[0265] use The loss is calculated only on the angle bins that are the same as the true angle, and is used for the angle residuals within the fine regression bins.
[0266] The total loss for angle prediction is:
[0267]
[0268] in, It is the weighting coefficient of the residual loss.
[0269] S5.3 Semantic Consistency Loss Calculation: To enhance the robustness and discriminativeness of the model's feature representation, a semantic consistency loss is introduced. This loss generates two distinct views for each training sample through data augmentation (such as random rotation and brightness perturbation). and The two views are input into the network respectively, and the enhanced features are output from the S3 module. Above, for those belonging to the same goal Cosine similarity is calculated for features to narrow the distance between feature representations of the same target in different views. The calculation formula is as follows:
[0270]
[0271] in, Representing vectors and Cosine similarity between them It is a temperature hyperparameter used to adjust the sensitivity of the loss function to difficult negative samples. It is an indicator function if and only if The time value is 1.
[0272] S5.4, Incremental Refining Stage Loss Aggregation: For those containing The detection head in the refining stage, the total loss It is the weighted sum of losses from all refining stages:
[0273]
[0274] in, It is the first The total loss for each refining stage is calculated based on S5.1 to S5.3. It is the first The loss weight for each stage is set to That is, it increases as the refining stage progresses. This is to maximize the contribution of the final stage prediction to the loss.
[0275] S5.5 End-to-end training: Minimize the overall loss using a stochastic gradient descent optimizer or an AdamW optimizer. Simultaneously, backpropagation and updates are performed on all trainable parameters in the network, thereby achieving end-to-end joint training of the entire model.
[0276] Furthermore, such as Figure 7 As shown, in step S6, during the inference phase, the input SAR image undergoes forward propagation, and the target category, refined directed bounding box, and orientation angle are output. The specific steps are as follows:
[0277] S6.1 Model Loading and Input Image Preprocessing: During the deployment and inference phase, the optimal model parameters obtained from S5 training are first loaded; subsequently, the input SAR image to be detected is preprocessed. Perform the same preprocessing operations as S1, including radiometric calibration, speckle noise suppression, and image normalization, to obtain a normalized image. ; Generate a priori scattering feature map according to the method described in S1.4. Finally, and Channel splicing is performed to form a network input. .
[0278] S6.2 Forward Propagation and Feature Extraction: Input the preprocessed network... Input into the network, passing through in sequence:
[0279] The scattering characteristic-guided multi-scale dynamic feature enhancement network described in S2 obtains fused features. ;
[0280] The task-adaptive region context awareness module described in S3 generates more discriminative region features;
[0281] The decoupled progressively refined directed detection head described in S4, after T stages of refinement, finally outputs the prediction results of all candidate regions in stage T, including: classification confidence. Refined bounding box offset and direction angle .
[0282] S6.3 Post-processing and result generation:
[0283] S6.3.1 Bounding Box Decoding and Angle Mapping: Using the bounding box offset obtained in S6.2 Based on the initial region proposal, the final directed bounding box is decoded to determine its position and size in the actual image coordinate system. At the same time, the predicted direction angle The internal representation of the model is mapped back to the actual radian or angle value.
[0284] S6.3.2 Result Filtering: First, based on the confidence level output by the classification branch... Filter out all data below the preset threshold. The low-confidence candidate boxes are identified; subsequently, for the remaining candidate boxes of the same category, a non-maximum suppression method oriented towards directed bounding boxes is applied. The calculation process of this method is as follows:
[0285] For a specific category, calculate the directed pairs between all candidate boxes. ;
[0286] Based on the calculated directed Matrix, remove those candidate boxes with higher confidence scores. Exceeding the preset threshold Redundant boxes;
[0287] S6.4 Final Detection Result Output: After post-processing in S6.3, the system outputs a final list of detection results; for each detected target retained in the list... Output its:
[0288] Target Category Take the category label with the highest classification confidence score;
[0289] Refined directed bounding box : using quadruplets It can be represented by the coordinates of its center point, width, and height, or by the coordinates of the vertices of the polygon;
[0290] Direction angle : Indicates the direction of the principal axis of the target, in radians or degrees;
[0291] Detection confidence This refers to the maximum classification probability value of the category to which the target belongs.
[0292] Finally, the system outputs all detected directed targets and their attributes in the form of structured data, completing the entire SAR image directed target detection process.
[0293] The above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention. The scope of protection of the present invention should be determined by the scope of protection of the appended claims.
Claims
1. A method for SAR directed target detection based on multi-scale context awareness, characterized in that, The method comprises the following steps: S1, acquiring a SAR image and pre-processing and prior coding of scattering characteristics; S2, constructing a multi-scale dynamic feature enhancement network guided by scattering characteristics, extracting and enhancing multi-level feature representations of the SAR image; S3, introducing a task-adaptive regional context perception module, fusing local features, spatial context and semantic context information, and generating more discriminative enhanced features; S4, constructing a decoupled progressive refinement oriented detection head, and predicting target categories, oriented bounding boxes and direction angles; S5, using a multi-task joint training strategy including semantic consistency loss to perform end-to-end training on the network; S6, in the inference stage, performing forward propagation on the input SAR image, and outputting target categories, refined oriented bounding boxes and direction angles; The S4 comprises the following steps: S4.1, Decoupled detection head construction: design a decoupled detection head containing three independent branches, respectively for target classification, oriented bounding box regression and direction angle prediction, and the three branches share the enhanced features output by S3 As input, but each has independent network parameters, thereby realizing task decoupling and avoiding conflicts between classification tasks and positioning tasks; S4.1.1, Classification branch: consists of two fully connected layers, for each input candidate region, this branch computes a vector of raw scores through its fully connected layers, and then processes the vector of raw scores through a softmax function to output a vector of confidence scores of dimension K, to represent the confidence of the region for all K preset classes. S4.1.2, the oriented bounding box regression branch: composed of two fully connected layers, output the geometric parameters of the oriented bounding box for refining the position and size of the candidate box; S4.1.3, Direction angle prediction branch: This branch adopts a hybrid representation method to accurately predict the orientation of the target; first, the continuous angle prediction problem is transformed into a combined classification and regression problem: the angle range of is uniformly divided into angle bins, where is a preset positive integer, usually set according to the trade-off between the accuracy requirement of angle estimation and the calculation complexity; the network simultaneously outputs the confidence of each angle bin and the angle residual vector within each bin, where the element corresponds to the residual within the angle bin; finally, combined with the index of the angle bin with the highest confidence and its residual, the final angle prediction value is calculated: wherein, is a function for mapping the residual to the interval [0, 1) to achieve fine regression within the bin, is ; S4.2, Progressive refining mechanism: To solve the problem of inaccurate target positioning and angle estimation in complex scenes, a progressive refining mechanism is introduced; the mechanism includes a refining stage, each stage executes the decoupled detection head described in S4.1, and each stage takes the directed bounding box and direction angle predicted by the previous stage as the input proposal of the current stage, and iteratively optimizes; S4.2.1, Feature Re-extraction: To preserve more spatial details and improve the localization accuracy, shallow feature maps with higher spatial resolution are selected Feature re-extraction is performed when the sequence number of the refinement stage is less than a pre-defined threshold The aligned features are re-extracted from the backbone feature maps using a re-extraction operation according to the predicted directional bounding box of the first stage and are denoted as S4.2.2, Angle-aware feature enhancement: the first predicted direction angle is encoded to generate an angle prior vector; the vector is passed through a small fully connected network and concatenated with the re-extracted features or feature modulation in channel dimension, so that the network can explicitly utilize the direction information in the refinement process to generate angle-aware features ; S4.2.3, Refinement Prediction: angle-aware features are input to a decoupled head of the same architecture as the first stage but with shared parameters, predicting the refined classification confidence , bounding box offsets , and orientation angles to the second stage . S4.3, Collaborative Prediction and Output: After... After several stages of progressive refinement, the prediction result of the last stage is selected as the final output; finally, for each valid detection proposal, the model collaboratively outputs its target category. Refined directed bounding box And the final direction angle ,in: In the above formula, denotes the operation of finding the index corresponding to the maximum value in the vector; the above outputs together complete the full description of the directed target.
2. The method of claim 1, wherein, The S1 comprises the following steps: S1.1, SAR image acquisition and radiometric calibration: The raw SAR image data is acquired by a synthetic aperture radar system, and first radiometric calibration is performed to convert the raw digital quantization values into backscattering coefficient images to eliminate the influence of the sensor system response, the calibration process is performed on a pixel basis, and the core calculation formula is: wherein, is the position of the pixel, is a scaling constant, depending on radar system parameters; S1.2, Coherent speckle noise suppression: The backscattering coefficient image after radiometric calibration is denoised by using an adaptive filtering algorithm to suppress coherent speckle noise and improve the image signal-to-noise ratio. Taking Lee filtering as an example, the filtered image may be represented as: wherein, is the backscattering coefficient image after calibration by S1.1, is the local mean, is the adaptive weight coefficient determined by the local variance and mean; S1.3, image standardization: the pixel value of the denoised SAR image is standardized to map it to a numerical range suitable for neural network processing, and the Z-Score standardization method is used to obtain the standardized image : wherein and are the pixel mean and standard deviation of the whole image, respectively; S1.4, scattering feature prior encoding: to enhance the network's ability to perceive the scattering characteristics of SAR targets, a scattering feature prior map is constructed , combining the target strong scattering point distribution and the local scattering matrix feature, the specific steps are as follows: S1.4.1, strong scattering point extraction: extract the strong scattering point position map using constant false alarm rate detection or local maximum detection method : wherein is an adaptive threshold value; S1.4.2, local scattering matrix calculation: Local scatter matrix feature of an image is calculated within a sliding window, including mean, variance, skewness and kurtosis, to form a multi-channel scatter feature map ; S1.4.3, prior map fusion: The strong scattering point image and the scattering matrix feature image are spliced in channel to form a scattering feature prior image : wherein, represents a tensor concatenation operation along the channel dimension, and the prior map will be input into the subsequent feature extraction network together with the original SAR image as the guiding information of scattering characteristics.
3. The method of claim 1, wherein, The S2 comprises the following steps: S2.1, Multi-scale Feature Pyramid Construction: Constructing the preprocessed SAR image output from S1. Prior map of scattering features Channel splicing is performed to form a network input. ; Utilizing the backbone network Feature extraction is performed to obtain multi-level feature maps. Subsequently, a feature pyramid network is used to fuse deep semantic information with shallow detail information to generate multi-scale feature maps. The calculation process is as follows: wherein, denotes a 1 x 1 convolution to adjust the number of channels, denotes a 2x up-sampling operation; S2.2 Spatial Attention Modulation Guided by Scattering Characteristics: To enhance the network's ability to focus on the target scattering region, spatial attention modulation is implemented at each pyramid level. A scattering-guided spatial attention module is then introduced; this module first processes the scattering feature prior map. Downsampling to the same level using bilinear interpolation For the same space dimensions, Then and Common input generates a spatial attention weight map. : wherein, denotes a 3x3 convolution, is activation function; utilizes modulates the original features to obtain enhanced features : wherein denotes element-wise multiplication; S2.3, dynamic receptive field enhancement: to capture the contextual information of SAR targets at different scales, the modulated features Parallel multi-branch hole convolution processing is carried out; the branches include: Branch 1: 1x1 standard convolution; Branch 2: 3x3 atrous convolution, atrous rate ; Branch 3: 3x3 atrous convolution, atrous rate ; Branch 4: 1x1 convolution after global average pooling and function, and then upsampled back to the original size by bilinear interpolation. concatenate the branch outputs along the channel dimension to obtain a multi-receptive field fusion feature : wherein, represents a processing function of the i-th branch on the input feature, is a channel concatenation operation; S2.4, cross-scale adaptive fusion: the enhanced features of each level obtained in S2.3 are fused unified to the preset channel number by 1x1 convolution , obtaining ; through an inter-scale attention module, learn the fusion weight of different scale features at each spatial position; for each level , calculate its spatial weight map : All and Upsampling to the maximum scale via bilinear interpolation, the maximum scale being compared with the feature map Consistency, followed by scaling dimension Normalization yields a normalized weighted graph. Ultimately, cross-scale adaptive fusion features Calculated by the following formula: 。 4. The method of claim 1, wherein, The S3 comprises the following steps: S3.1, Region Proposal Generation and Local Feature Alignment: The fused feature maps output from S2 are input into a region proposal network to generate a set of candidate regions that potentially contain the object, each of which is represented by a rectangular bounding box parameterization. where is a pre-defined channel number. This feature map encodes the local visual features within the candidate region. S3.2, spatial context awareness sub-module: to model the relative spatial relationship between the target and its surrounding environment, a spatial context awareness sub-module is constructed; this sub-module takes as input As input, the following operations are performed: S3.2.
1. First, two parallel convolutional layers are used to transform the input image into feature maps and for computing spatial attention; S3.2.
2. Subsequently, the following is calculated and flattened into a two-dimensional matrix and the spatial attention matrix is calculated : wherein, is the number of channels, used as a scaling factor to stabilize training, the function is normalized by row; S3.2.3、Meanwhile, the following is calculated The feature is obtained by another convolution layer , and multiplied by to obtain the feature enhanced by spatial context : S3.3, semantic context-aware sub-module: to introduce more extensive image-level semantic context information, a semantic context-aware sub-module is constructed; the input of the sub-module is the entire fusion feature map : S3.3.1、First, the global average pooling is performed on the feature map to obtain an image-level global context vector ; S3.3.2, subsequently, the global context vector by a transformation network consisting of fully connected layers and ReLU activations ; S3.3.
3. Finally, the with each characteristics per-channel multiplication is performed to achieve adaptive injection of semantic context information: S3.4, Task-adaptive Feature Fusion: Local features , spatial context features and semantic context features are concatenated to obtain a rich joint feature representation : To adaptively optimize this joint feature, it is input to a lightweight task-adaptive weight learning network, which is composed of a small multilayer perceptron whose output is a three-dimensional weight tensor that has the same dimensions as the feature and recalibrates the feature by element-wise multiplication: wherein, That is, after the region context perception module processing, the more discriminative enhanced features, it will be as a subsequent input direction detection head.
5. The method of claim 1, wherein, The S5 comprises the following steps: S5.1, Multi-task loss function construction: the overall loss function of the network consists of a classification loss , a directed box regression loss , an angle prediction loss , and a semantic consistency loss , and the mathematical expression thereof is: wherein, , , , are hyperparameters for balancing the weights of the respective loss terms; S5.2, task loss calculation: S5.2.1, Classification loss Focal loss is used to handle the imbalance problem between foreground and background classes, which is defined as follows: wherein, is the model predicted target class probability, is the balancing factor, is the modulation factor, used to reduce the weight of easy samples, making the model focus on hard samples; S5.2.2, Directed Box Regression Loss :use The loss is used to optimize the precise location and size of the directed bounding box; for the truth box parameters... and predicted value The loss is calculated as follows: S5.2.3, Angle prediction loss This loss consists of two parts: angle bin classification loss and angle residual regression loss Cross-entropy loss is used for correctly classifying the angle bin the target belongs to; Adopting Losses are only computed on the same angular bin as the true angle, for fine regression bins. The total angle prediction loss is: wherein, is an internal weight coefficient for balancing the angle-bin classification loss and the residual regression loss. S5.3 Semantic Consistency Loss Calculation: To enhance the robustness and discriminativeness of the model's feature representation, a semantic consistency loss is introduced. This loss is augmented to generate two different views for each training sample. and The two views are input into the network respectively, and the enhanced features are output from the S3 module. Above, for those belonging to the same goal Feature calculation uses cosine similarity to narrow the distance between feature representations of the same target in different views. A target in view Below The feature vector is In view Below The feature vector is The calculation formula is as follows: wherein, denotes the cosine similarity between vectors and is a temperature hyperparameter that regulates the sensitivity of the loss function to difficult negative samples, is an indicator function that takes the value 1 if and only if 1. S5.4, Loss aggregation for progressive refinement stages: For a detection head that includes S5.4.1, Loss for each refinement stage: For each refinement stage, the total loss is a weighted sum of all refinement stage losses: in, It is the first The total loss for each refining stage is calculated based on S5.1 to S5.
3. It is the first The loss weight for each stage is set to That is, it increases as the refining stage progresses. To maximize the contribution of the final stage prediction to the loss; S5.5, end-to-end training: using a stochastic gradient descent optimizer or an AdamW optimizer to minimize the total loss At the same time, all the trainable parameters in the network are backpropagated and updated, including the parameters of the feature extraction network, the context awareness module and the detection head of each stage, so as to realize end-to-end joint training of the whole model.
6. The method of claim 1, wherein, The S6 comprises the following steps: S6.1 Model Loading and Input Image Preprocessing: During the deployment and inference phase, the optimal model parameters obtained through training in S5 are first loaded; subsequently, the input SAR image to be detected is preprocessed. Perform the same preprocessing operations as S1, including radiometric calibration, speckle noise suppression, and image normalization, to obtain a normalized image. Next, following the prior coding method for scattering features described in S1.4, unsupervised constant false alarm rate detection and local scattering moment calculation are used to... Generate scattering feature prior map Finally, and Channel splicing is performed to form a network input. ; S6.2 Forward Propagation and Feature Extraction: Input the preprocessed network... Input into the network, passing through in sequence: The scattering characteristic guided multi-scale dynamic feature enhancement network of S2 obtains fusion features ; The task-adaptive regional context perception module of S3 generates more discriminative regional features; The decoupled progressive refining described in S4 has a direction detection head, and after T stages of refining, finally outputs the prediction results of all candidate regions in the Tth stage, including: classification confidence , refined bounding box offset , and direction angle ; S6.3, post-processing and result generation: S6.3.
1. Border box decoding and angle mapping: using the border box offsets obtained in S6.2 and the initial region proposal, the final oriented border box position and size in the actual image coordinate system is decoded ; simultaneously, the predicted direction angle is mapped back from the model internal representation to the actual radian or angular degree value; S6.3.2 Confidence Filtering and Non-Maximum Suppression: First, based on the confidence level of the classification branch output... Filter out all values below the preset threshold. The low-confidence candidate boxes are identified; subsequently, for the remaining candidate boxes of the same category, a non-maximum suppression method oriented towards directed bounding boxes is applied. The calculation process of this method is as follows: For a certain class, compute the directed edge between all pairs of candidate boxes ; According to the calculated directed matrix, remove those redundant boxes whose confidence scores are lower than a pre-set threshold of the higher confidence candidate boxes. This step aims to eliminate repeated detection of the same target and ensure that each target in the final result corresponds to only one optimal detection box; S6.4, Final detection result output: after the post-processing of S6.3, the system outputs the final detection result list; for each detection target remaining in the list , outputs its: Target category : take the class label with the highest classification confidence Refined oriented bounding box : in a quadruple representing the center point coordinates, width and height, or in polygon vertex coordinates; direction angle : indicates the direction of the target principal axis, in radians or degrees; detection confidence : i.e., the maximum classification probability value of the category to which the target belongs Finally, the system outputs all detected oriented targets and their attributes in the form of structured data, completing the entire SAR image oriented target detection process.
Citation Information
Patent Citations
SAR (Synthetic Aperture Radar) small-scale target detection system and method based on deep learning
CN120495626A
Small sample target detection method based on target feature enhancement and semantic fusion perception
CN120747465A