Dynamic cross-domain general ship detection method based on edge wavelet guidance

By employing edge wavelet-guided attention, adaptive dynamic dilated convolution, and geometric structure attention enhancement modules, a cross-domain general ship detection model is constructed, which solves the applicability and complexity issues of cross-modal detection and achieves efficient and accurate ship target detection.

CN122049680APending Publication Date: 2026-05-15NORTHWESTERN POLYTECHNICAL UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-02-06
Publication Date
2026-05-15

AI Technical Summary

Technical Problem

Existing cross-modal ship detection methods have limitations in applicability to multi-source cross-domain detection, and existing multimodal fusion methods are costly and have high model complexity, making it difficult to promote them on a large scale in practical applications.

Method used

An edge wavelet guided attention module (EWGA) is used to generate a cross-modal consistent structural representation through a spatial-frequency dual decoupling mechanism. An adaptive dynamic dilated convolution module (ADDC) aligns the multi-scale feature distribution, and a geometric structure attention enhancement module (GSAA) enhances the anti-interference capability, thus constructing a cross-domain general ship detection model.

Benefits of technology

It improves the accuracy and robustness of cross-modal ship detection, reduces the complexity of the detection system and the computational resource requirements, and adapts to real-time detection in different environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122049680A_ABST
    Figure CN122049680A_ABST
Patent Text Reader

Abstract

The invention discloses a dynamic cross-domain general ship detection method based on edge wavelet guidance, which is suitable for optical and SAR remote sensing images. By constructing a unified detection framework, complexity and low efficiency caused by two independent detection models in a traditional method are avoided. Firstly, an edge wavelet guidance attention module adopts a spatial frequency double-decoupling mechanism; wavelet transformation high-frequency gating is utilized on the edge guiding feature, structural representation with the consistent cross-modal height is generated, and the modal gap problem is fundamentally solved. Secondly, the self-adaptive dynamic expansion convolution module solves the problem of scale distribution difference; a dynamic tanh activation function is introduced as a learnable dynamic calibrator and is responsible for adaptively aligning multi-scale feature distribution of different modals. And finally, an ensemble structure attention enhancement module explicitly applies geometric priori constraint to a self-attention mechanism, so that the anti-interference capability is enhanced, and the network attention is guided to only pay attention to the target form irrelevant to the mode. According to the method, complexity and low efficiency caused by two independent detection models in a traditional method can be avoided, and the application effect of a detection system in a complex dynamic environment can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of deep learning technology, specifically relating to a general method for detecting ship targets in remote sensing images. Background Technology

[0002] With the continuous development of remote sensing technology, ship target detection plays an increasingly important role in fields such as marine monitoring, maritime traffic safety, and border patrol. Traditional ship detection methods often rely on data from a single sensor, such as using only optical or synthetic aperture radar (SAR) images. However, data acquired by different sensors exhibit significant modal differences, leading to numerous challenges for single-modal detection methods in cross-modal and cross-domain applications. Therefore, how to achieve cross-modal ship detection has become an important research topic in remote sensing image analysis.

[0003] Existing cross-modal target detection methods mostly focus on transfer learning from one modality to another. For example, unsupervised or semi-supervised learning is used to transfer knowledge from optical images to SAR images for single-source-domain ship detection. While these methods have achieved some success in specific application scenarios, their applicability is limited and cannot fully address the problem of multi-source, cross-domain ship detection. Furthermore, existing multimodal fusion methods typically rely on paired optical and SAR images and employ complex fusion strategies to combine features from both modalities. However, acquiring paired images is costly, and these methods have high model complexity, making large-scale deployment in practical applications difficult.

[0004] To address the aforementioned issues, recent research has begun to explore more general cross-modal ship detection methods. For example, by constructing a universal detection framework, cross-modal detection between optical and SAR images can be achieved. This approach not only avoids the complexity and inefficiency of traditional methods involving two independent detection models but also improves the performance of the detection system in complex and dynamic environments. Through a unified detection framework, the complexity of system design and deployment can be significantly reduced, enhancing real-time detection capabilities in variable environments. Summary of the Invention

[0005] To overcome the shortcomings of existing technologies, this invention provides a dynamic cross-domain general ship detection method based on edge wavelet guidance. First, the Edge Wavelet-Guided Attention (EWGA) module employs a spatial-frequency dual decoupling mechanism. By utilizing high-frequency gating of Discrete Wavelet Transform (DWT) on edge-guided features to generate a highly consistent structural representation across modalities, it fundamentally solves the modal gap problem. Second, the Adaptive Dynamic Dilated Convolution (ADDC) module addresses the scale distribution difference problem by introducing a Flexible Tanh Activation (FTA) function as a learnable dynamic calibrator, responsible for adaptively aligning the multi-scale feature distributions of different modalities. Finally, the Geo-Structural Attention Augmentation (GSAA) module enhances the model's robustness by explicitly applying geometric prior constraints to the self-attention mechanism, guiding the network attention to focus only on target morphologies independent of modality. This invention avoids the complexity and inefficiency caused by two independent detection models in traditional methods, and improves the application effect of the detection system in complex dynamic environments.

[0006] The technical solution adopted by this invention to solve its technical problem includes the following steps: Step 1: Dataset preparation; This invention uses a self-built multimodal dataset MRSSD, as well as two single-modal benchmark datasets DIOR and SSDD. The MRSSD dataset effectively evaluates cross-modal ship detection performance by integrating optical images from the LEVIR dataset and a portion of SAR images from the HRSID dataset at a 1:1 ratio. The DIOR dataset is used to evaluate the model's generalization ability on large-scale optical images, while the SSDD dataset is suitable for evaluating the robustness of SAR detection. Step 2: Construct a dynamic cross-domain general ship detection model based on edge wavelet guidance; The proposed model architecture consists of three main processing stages: modality-invariant feature extraction, multi-scale feature adaptation, and geometric structure enhancement. It involves three core modules: an edge wavelet-guided attention module, an adaptive dynamic dilated convolution module, and a geometric structure attention enhancement module. The construction process is as follows: Step 2-1: Construct the edge wavelet-guided attention module; The proposed EWGA module aims to address the modal differences between optical and SAR images. Through a space-frequency dual decoupling mechanism, features are decomposed into structural and textural components, which are further extracted using the wavelet domain, effectively isolating modality-independent structural information. First, the input feature map is processed by a Gaussian smoothing branch. Gaussian smoothing reduces low-frequency noise in the image, obtaining a smooth feature representation, and the smoothing degree is controlled by the overall standard deviation of the input image. Next, the Sobel operator is used for edge detection, extracting edge information from the image. This branch enhances edge features in the image, helping to preserve details and highlight structural information. Next, the original input, smoothed features, and edge features are fused. The fused features are then processed by batch normalization and ReLU activation function to obtain a preliminary feature representation. In the frequency-aware gating mechanism, wavelet transform is applied to the high-frequency components, and a frequency-aware mask is designed. This mask is used to filter noise and enhance structural features, thereby preserving structural information that significantly affects both modes. The low-frequency components are upsampled to the same size as the high-frequency features and concatenated with the high-frequency features to form fused features. The attention map generated by the upsampling is used to recalibrate the fused features, further improving the discriminative ability of the features. Finally, the... Convolution refines the image and outputs the final feature map. Step 2-2: Construct an adaptive dynamic dilated convolution module; Scale differences within and between modalities in optical and SAR images pose challenges to unified detection. To address this issue, this invention proposes an ADDC module that optimizes feature alignment and multi-scale target perception capabilities through a dual-adaptation mechanism. First, the input feature map is converted into a query through convolution. ),key( ) and value ( The ADDC module first calculates channel-level attention weights by combining Softmax and Sigmoid functions. Softmax enhances channels with strong discriminative power, while Sigmoid provides independent calibration for each channel, suppressing noise and preserving useful signals. Next, the attention weights are applied to the value feature map to obtain the enhanced feature representation, and stable features are activated through residuals. Then, the features are processed through three parallel convolutional layers, each using a different dynamic dilation rate to dynamically adjust the receptive field of the convolutional kernel. An FTA function is introduced as a learnable dynamic calibrator responsible for adaptively aligning multi-scale feature distributions of different modalities. Finally, the outputs of the three branches are fused and normalized by layers to output the final feature map. The ADDC module effectively adapts to different target scales, enhancing the detection performance of optical and SAR images. Steps 2-3: Construct the geometric structure attention enhancement module; The proposed GSAA module aims to enhance the self-attention mechanism by directly incorporating a set of self-learned geometric and structural priors into attention computation, significantly improving cross-modal feature alignment capabilities. Unlike traditional methods that rely on fixed external guidance, GSAA can automatically extract and fuse three prior information types: depth relevance, spatial proximity, and structural continuity, explicitly guiding attention to pixels with consistent structure and geometry. First, the input feature map is processed by a Geometric-Structural Encoder (GSE) to generate a depth-aware attention bias from the depth map. Then, the GSE uses three masks—a depth decomposition mask, a positional decay mask, and a structural contrast mask—to penalize pixel pairs with large depth differences, encourage spatially close pixel pairs, and emphasize structurally consistent regions, respectively. These masks are fused into a composite decay mask, which adjusts the influence of depth and position through learnable weights. Finally, the final attention bias mask further guides attention by combining depth consistency and spatial locality. To improve cross-modal perception capabilities, GSAA also embeds spatial proximity information directly into the query through rotational positional encoding. ) and key ( In the projection of ), finally, the Full Gated Attention (FGA) module combines these priors with the self-attention mechanism, through the enhancement value ( The feature and adaptive adjustment of attention weights further improve the ability to perceive cross-modal targets and exhibit higher robustness in noisy environments. Step 3: Train the network model; Set the training parameters: batch size, learning rate, weight decay, maximum number of iterations, and optimizer parameters; train using the dataset prepared in step 1; after training, the final dynamic cross-domain general ship detection model based on edge wavelet guidance is obtained; Step 4: Test the network model; The images in the dataset to be tested are input into the final dynamic cross-domain general ship detection model guided by edge wavelets, and the detection results are output. Preferably, the MRSSD dataset integrates optical images from the LEVIR dataset and SAR images from the HRSID dataset at a 1:1 ratio, totaling 2,988 images. It covers different ship sizes, imaging resolutions, and environmental conditions, effectively evaluating cross-modal ship detection performance. The dataset is divided into training, validation, and test sets in an 8:1:1 ratio.

[0007] Preferably, during training, the initial learning rate is set to 0.01, the momentum coefficient is 0.937, and the weight decay is fixed at 0.0005. All models are trained using the SGD optimizer with a batch size of 16 and a cosine learning rate scheduling strategy.

[0008] The beneficial effects of this invention are as follows: 1. This invention proposes an edge wavelet-guided attention module. Through a spatial-frequency dual decoupling mechanism, it utilizes wavelet transform-gated high-frequency edge-guided features to generate highly consistent structural representations across modalities, fundamentally solving the problem of inter-modal differences. This module can improve the similarity of feature extraction from different modalities through effective feature guidance. 2. This invention proposes an adaptive dynamic dilated convolution module specifically designed to address the problem of distributional differences. This module introduces an FTA function as a learnable dynamic calibrator, which can adaptively align multi-scale feature distributions, compensate for scale differences within and between different modes, and enhance the model's ability to handle ship targets of different sizes; 3. This invention proposes a geometric structure attention enhancement module, which enhances the ability to suppress background interference by using geometric prior constraints on the self-attention mechanism. This helps the network focus its attention on modality-independent features related to ship morphology, effectively improving the network's robustness in complex backgrounds and reducing false detections and false negatives. 4. The edge wavelet-guided attention module, adaptive dynamic dilated convolution module, and geometric structure attention enhancement module proposed in this invention are all modular designs with low coupling, possessing good compatibility and portability. They can be flexibly integrated into different types of target detection networks such as YOLO series, RT-DETR, and Faster R-CNN. Their application scope is not limited to the edge wavelet-guided dynamic cross-domain general ship detection model architecture proposed in this patent.

[0009] This invention achieves cross-domain universal detection through the synergistic effect of three core modules: the Edge Wavelet Guided Attention (EWGA) module utilizes a spatial-frequency dual decoupling mechanism to generate a highly consistent structural representation across modalities; the Adaptive Dynamic Dilated Convolution (ADDC) module aligns multi-scale feature distributions of different modalities through a learnable dynamic calibrator; and the Geometric Structure Attention Enhancement (GSAA) module enhances anti-interference capability by explicitly applying geometric prior constraints to the self-attention mechanism. Together, these three modules solve three major technical challenges: modal differences, scale distribution differences, and background noise interference. Attached Figure Description

[0010] Figure 1 This is a flowchart of the method of the present invention; Figure 2 This is a structural diagram of the method of the present invention; Figure 3This is a schematic diagram of the S2GCA module in the adaptive dynamic dilation convolution module of the method of the present invention; Figure 4 This is a comparison chart of the detection results of the method of this invention and other methods on the MRSSD dataset, wherein... Figure 4 (a) is the true value. Figure 4 (b) to Figure 4 (f) The detection results on MRSSD test images using YOLOv8-n, YOLO11-n, RT-DETR, OptiSAR-Net and the method of the present invention, respectively; Figure 5 This is a comparison chart of the detection results of the method of this invention and other methods on the DIOR dataset, wherein... Figure 5 (a) is the true value. Figure 5 (b) to Figure 5 (f) The detection results on the DIOR test image are obtained by using YOLOv8-n, YOLO11-n, RT-DETR, OptiSAR-Net and the method of the present invention, respectively; Figure 6 This is a comparison chart of the detection results of the method of this invention and other methods on the SSDD dataset, wherein... Figure 6 (a) is the true value. Figure 6 (b) to Figure 6 (f) shows the detection results on SSDD test images using YOLOv8-n, YOLO11-n, RT-DETR, OptiSAR-Net, and the method of the present invention, respectively. Detailed Implementation

[0011] The present invention will be further described below with reference to the embodiments and accompanying drawings.

[0012] like Figure 1 As shown, a dynamic cross-domain general ship detection method based on edge wavelet guidance includes the following steps: Step 1: Dataset preparation; This invention utilizes a self-built multimodal dataset, MRSSD, and two single-modal benchmark datasets. The MRSSD dataset, comprising 2,988 images (a 1:1 ratio of optical images from the LEVIR dataset and SAR images from the HRSSD dataset), covers various ship sizes, imaging resolutions, and environmental conditions, effectively evaluating cross-modal ship detection performance. The dataset is divided into training, validation, and test sets in an 8:1:1 ratio. The DIOR dataset, extracted from the DIOR dataset and retaining only ship-related categories, yields 2,702 optical images. This subset is used to evaluate the model's generalization ability on large-scale optical images, and is divided in a 6:2:2 ratio. SSDD, a widely used SAR ship detection dataset, contains 1,160 images collected under different imaging conditions, sea states, and background interference, suitable for evaluating the robustness of SAR detection. This dataset is also divided in a 6:2:2 ratio.

[0013] Step 2: Construct a dynamic cross-domain general ship detection model based on edge wavelet guidance; The proposed model architecture consists of three main processing stages: modality-invariant feature extraction, multi-scale feature adaptation, and geometric structure enhancement. It involves three core modules: Edge Wavelet Guided Attention (EWGA), Adaptive Dynamic Dilated Convolution (ADDC), and Geometric Structure Attention Enhancement (GSAA). The specific construction process is as follows: Step 2-1: Construct the edge wavelet-guided attention module; The EWGA module proposed in this invention aims to address the modal discrepancy problem between optical and SAR images. Due to the physical differences in imaging between optical and SAR images, features are entangled by modality-specific noise and texture, resulting in poor direct feature alignment or fusion. Edges are among the most consistent and modality-independent cues; however, the extracted edges themselves are also affected by modal noise. To decouple the inherent structural information from these noise interferences, this invention proposes the EWGA module.

[0014] First, features are decomposed into structural and textural features in the spatial domain. Then, the discriminative power of the wavelet domain is used to further extract these features, effectively extracting mode-independent edge structural information. The EWGA module consists of two complementary branches: a Gaussian Smoothing Branch (GSB), which simulates the global appearance and suppresses low-frequency interference; and an Edge Detection Branch (EDB), which highlights key structural cues. The two branches are first fused, and then the fused features are projected into the wavelet domain, where a frequency-aware gating mechanism performs crucial decoupling processing.

[0015] Input feature map First, it undergoes GSB processing: (1) In the formula, For the input feature map, The output features are Gaussian smoothed.

[0016] The GSB module uses multiple fixed 2D Gaussian kernels of different sizes and standard deviations for processing. Each Gaussian kernel is defined as follows: (2) In the formula, , Represents two-dimensional spatial coordinates. It is the standard deviation of the Gaussian kernel. It is a defined Gaussian kernel used to smooth images.

[0017] To preserve high-frequency boundary information, this invention employs the Sobel operator: (3) In the formula, and These are the horizontal and vertical responses of the Sobel operator, respectively. To ensure numerical stability, this branch enhances edges and fine structures that are easily blurred by the smoothing process.

[0018] raw input Smoothed features and edge features Element-wise summation is performed, and then processed using batch normalization (BN) and the ReLU activation function: (4) Next, Decomposed into low-frequency and high-frequency components using a single-stage discrete wavelet transform (DWT): (5) In the formula, Indicates low-frequency characteristics. Includes high-frequency details in the horizontal, vertical, and diagonal directions.

[0019] Since the high-frequency subbands in the wavelet domain primarily capture structural details and noise, this invention designs a discriminative filter to suppress noise components while enhancing structural responses that are discriminative in both modes. This process can be expressed as: (6) In the formula, It is a high-frequency feature map. It is a generated frequency-aware mask. express Convolutional layer For batch normalization, It is the Sigmoid activation function.

[0020] (7) In the formula, Frequency-aware masking The output after weighting the high-frequency features.

[0021] Low frequency components Upsampled to Same size: (8) The two components are concatenated to generate a channel-level attention map: (9) In the formula, It is a channel-level attention map. It refers to the batch size. It is the number of channels. and These are the height and width of the feature map.

[0022] (10) In the formula, It is the generated attention map. yes Convolutional layer.

[0023] Finally, the attention map is upsampled and applied to the recalibration. and use Convolution refines the results: (11) (12) (13) In the formula, This is the attention map after upsampling. These are features that have undergone attention calibration. These are the characteristics of the final output.

[0024] Step 2-2: Construct an adaptive dynamic dilated convolution module; Significant scale variations and inherent feature distribution differences exist between optical and SAR images, posing a challenge to unified detection models. While numerous scale-based convolutional designs have been developed to address this issue, their static nature limits the model's adaptability to cross-modal features. To resolve this, this invention proposes an ADDC module employing a dual-adaptation mechanism: firstly, adjusting the receptive field through dynamic dilation rate configuration; and secondly, calibrating the feature distribution through a dynamic tanh activation function. This design enables real-time alignment of feature representations across modalities and scales, enhancing the model's cross-modal adaptability and multi-scale perception capabilities.

[0025] First, input the feature map. , For batch size, For the number of channels, and The height and width of the feature map, respectively, are converted into a query. ),key( ) and value ( The input features are mapped to three different representations through convolutional layers and activation functions for subsequent attention mechanism processing. (14) In the formula, It is the input feature map. and Depend on Convolutional layers, ReLU activation function and Convolutional layers are used to capture rich contextual dependencies. In contrast, Only by The convolutional layers are designed to preserve the integrity of local features and avoid excessive nonlinear transformations that could lead to the loss of local information.

[0026] Secondly and After flattening, the high-dimensional tensor is transformed into a two-dimensional tensor, and their similarity score is calculated using matrix multiplication. This calculation helps the model focus on key channel information by quantifying the correlation between different channels: (15) (16) In the formula, and The expanded query is ( ) and key ( feature, For the calculated similarity score, Indicates matrix transpose. It is a normalization factor used to prevent scores from becoming too high.

[0027] Next, to obtain selective and robust channel-level attention weights, this invention employs a complementary mechanism combining the Softmax and Sigmoid functions. The Softmax function highlights the most discriminative channel through channel competition, while the Sigmoid-based gating mechanism provides independent, constrained calibration for each channel, effectively suppressing noise and preserving weak but useful signals. Through this combination, the model can better adapt to background interference and cross-modal differences, improving its discriminative ability.

[0028] (17) (18) In the formula, This represents the sum of the similarity scores for each channel across the spatial dimension. For channel-level attention scores, This is the gating factor.

[0029] Final attention weights The product of these two is: (19) In the formula, This represents the final channel-level attention weights.

[0030] Then, the attention weights are applied to the value features. Generate enhanced feature representations : (20) In the formula, This is the enhanced feature map.

[0031] Next, residual activation is used to process the data, yielding the output of the S2GCA module. Residual activation helps maintain the continuity of the information flow and prevents gradient vanishing. (twenty one) In the formula, For the enhanced feature map, For bias terms, This is the final output of the S2GCA module.

[0032] Finally, Through three parallel Convolutional layers, each using a different dynamic dilation rate ( The dilation rate is dynamically adjusted during training, allowing the network to adaptively adjust the sampling range of the convolutional kernels based on the spatial distribution and size of the target. (twenty two) In the formula, These are the output features after convolution processing with different dilation rates.

[0033] The FTA function dynamically adjusts its transformation parameters based on real-time input statistics. Each branch outputs... After flattening, a channel-level nonlinear transformation is performed via FTA: (twenty three) (twenty four) (25) (26) (27) In the formula, For input features, This is the output after FTA activation. The input characteristics of the representative function. and These represent the real-time mean and standard deviation of the input features in the batch and spatial dimensions, respectively. and These are dynamically generated scaling factors and bias terms used to control the slope and offset of the activation function. and For channel-level learnable parameter vectors, and It is a learnable scalar scaling factor.

[0034] Finally, by fusing the activation outputs of the three branches and performing layer normalization to stabilize training, the feature tensor is readjusted back to its original spatial dimensions: (28) (29) (30) In the formula, Indicates the characteristics after fusion. The features are normalized. This is the final output of the ADDC module.

[0035] Steps 2-3: Construct the geometric structure attention enhancement module; The GSAA module proposed in this invention significantly enhances the self-attention mechanism by directly integrating a set of self-learned geometric and structural priors into the self-attention computation. Unlike traditional methods that rely on fixed or single external guidance, GSAA proposes three priors: depth relevance, spatial proximity, and structural continuity, and combines these three to explicitly guide cross-modal attention to focus on structurally and geometrically consistent pixels. This is of significant value when processing heterogeneous remote sensing images with large feature differences, significant scale variations, and strong background noise interference. By utilizing these self-learned multidimensional priors, GSAA not only stabilizes cross-modal feature alignment but also introduces a structural gating mechanism to preserve details and enhance noise resistance, thus distinguishing itself from traditional attention blocks.

[0036] First, given the input feature tensor In the formula, For batch size, For the number of channels, For height, The width is used as the averaging factor across the channel dimensions to obtain a preliminary depth map. : (31) Depth priors provide the foundation for attention biases in depth perception, helping models better capture pixel relationships within scene geometry. In this task, it helps group coplanar or similarly sized objects, even if they appear different in different modalities.

[0037] Secondly, the GSAA module consists of two parts: the geometry-structure encoder (GSE) and the full gating attention (FGA) module.

[0038] GSE transforms spatial and depth information into learnable attention biases using three masks: Depth decomposition mask This mask penalizes pixel pairs with large depth differences, focusing attention on regions with consistent depth. (32) In the formula, This is the preset attenuation coefficient.

[0039] Position attenuation mask This mask uses Manhattan distance to penalize spatial distance, encouraging locality. (33) In the formula, and For the first and Row and column indices of pixels, This is the spatial decay factor.

[0040] Structure contrast mask This mask binarizes depth differences using a depth map and uses a threshold. Emphasizing structural continuity and suppressing noise: (34) In the formula, The threshold for depth difference.

[0041] These masks are achieved through learnable weights. The two layers are fused to form a composite attenuation mask. (35) In the formula, This is a composite attenuation mask.

[0042] The final attention bias mask is: (36) In the formula, This is an attention bias mask. Attention bias masks can be used to explicitly guide attention to pixels that are spatially close, have consistent depth, and are structurally similar.

[0043] In remote sensing target detection, this method, through cross-modal feature alignment, helps reduce feature differences between optical and SAR images and enhances robustness to noise, especially in target boundary regions. GSE also generates a sin-cos matrix for rotational position encoding, directly embedding relative spatial information into the target. and In the projection: (37) (38) (39) In the formula, For rotation angle, and These are the row and column indices, respectively. and These are the query and key matrices after applying rotational position encoding, respectively. This indicates swapping the odd and even dimensions and performing a sign flip. and This is the location encoding value for the corresponding dimension.

[0044] The Fully Gated Attention (FGA) module incorporates these priors into the self-attention mechanism: (40) In the formula, It is the arranged feature map. This is the weight matrix obtained during training.

[0045] Value characteristics Enhanced through depthwise convolution (DWConv): (41) In the formula, These are the enhanced features resulting from depthwise convolution.

[0046] Next, the attention weight matrix is ​​calculated, and an attention bias mask is introduced. To incorporate structural information: (42) In the formula, This is the normalized attention weight matrix. For the dimension of the key, For attention bias mask. Subsequently, the value features were processed using the attention matrix. Perform weighted aggregation and with By fusing, intermediate features are obtained. : (43) Finally, through linear projection Mapping back to the original embedding dimension yields the module's final output: (44) In the formula, For the final output, This is the output weight matrix.

[0047] By explicitly modeling depth correlation, spatial proximity, and structural continuity, GSAA can effectively align features between optical and SAR images and reduce the impact of noise in SAR images. This method accurately enhances global inference while preserving local geometric features, demonstrating high effectiveness for target detection in complex, noisy, and multimodal environments.

[0048] Step 3: Train the network model; The present invention sets training parameters. During training, the initial learning rate is set to 0.01, the momentum coefficient is 0.937, the weight decay is fixed at 0.0005, SGD with a batch size of 16 is used for training, and a cosine learning rate scheduling strategy is adopted.

[0049] Step 4: Test the network model; The images in the test dataset are input into the final dynamic cross-domain general ship detection model guided by edge wavelets, and the detection results are output. Specific Implementation 1. Experimental conditions The experimental environment configuration for this invention is as follows: all experiments were conducted on the Ubuntu 20.04 LTS operating system, the virtualization platform used was KVM, equipped with a 12-core Intel Xeon Platinum 8352V CPU, combined with NVIDIA 4090 GPU acceleration, CUDA 12.6 was used for computation, and the PyTorch 2.4.1+CU121 deep learning framework was used.

[0051] 2. Experiment Content We selected classic YOLO models and representative state-of-the-art (SOTA) detection methods proposed in recent years to conduct cross-domain detection performance comparison experiments on the cross-modal dataset MRSSD. Furthermore, we also conducted comparative experiments on two single-modal datasets: the optical ship detection dataset DIOR and the SAR ship detection dataset SSDD. By evaluating the method on cross-domain and single-modal datasets, we demonstrated its strong adaptability and effectiveness in handling multiple data sources, further emphasizing its potential for practical applications in remote sensing and ship detection tasks. The following is a detailed description of the experimental results and visual detection results.

[0052] 3. Evaluation Indicators In this invention, model size is characterized by floating-point operations (FLOPs) and the number of parameters. Detection accuracy is evaluated as follows: the average accuracy (AP50) is calculated with an Intersection over Union (IoU) threshold of 0.5; additionally, the mean average accuracy (mAP) is calculated and averaged using IoU thresholds ranging from 0.5 to 0.95 at 0.05 steps, which can also be expressed as AP50:95.

[0053] 4. Simulation Testing As shown in Table 1, this invention achieved optimal detection performance in all evaluation scenarios of the MRSSD dataset. Specifically, on the overall dataset, the method of this invention achieved 93.8% AP50 and 72.8% AP50:95, which are 1.8 percentage points and 2.3 percentage points higher than the second-best performing existing method, YOLOv11-n, respectively. On the optical subset, this invention further achieved 94.2% AP50 and 73.8% AP50:95; on the more challenging SAR subset, it still achieved 93.3% AP50 and 71.8% AP50:95, fully demonstrating its adaptability and robustness to multimodal remote sensing images.

[0054] It is particularly noteworthy that, despite its significantly superior detection accuracy compared to existing technologies, the model architecture employed in this invention maintains a lightweight design, containing only 3.6M parameters and 19.1G FLOPs. This effectively reduces the computational resource requirements while ensuring high accuracy, achieving a good balance between detection accuracy and computational efficiency.

[0055] In summary, this invention not only significantly improves the detection accuracy in target detection tasks using optical and SAR images, but also possesses good generalization ability and practical deployment, demonstrating outstanding substantive features and significant progress.

[0056] Table 1 Comparison results on the MRSSD dataset like Figure 4 As shown, the border in the leftmost image represents the ground truth annotation, and the right side sequentially displays the detection results of different methods (including YOLOv5, YOLOv8, YOLOv11, DETR, and OptiSAR-Net). Circles indicate various detection errors, including missed detections, false alarms, and duplicate detections. This visualization fully demonstrates the superior detection accuracy and robustness of this invention in both optical and synthetic aperture radar (SAR) imaging modes, as well as in complex scenes.

[0057] In the optical remote sensing scenarios shown in the first four rows, existing methods generally suffer from significant detection deficiencies: in near-shore areas and high-density target regions, methods such as YOLOv5, YOLOv8, YOLOv11, and DETR frequently misidentify non-ship targets such as oil tanks, port facilities, or islands as ships, generating a large number of false alarms; simultaneously, there are also significant missed detections of visible targets located at the image edges. Although OptiSAR-Net performs second best in overall performance, it still fails to effectively overcome the above problems. In contrast, the method of this invention can achieve accurate and complete detection. For example, in the scenario shown in the third row, this invention can reliably identify partially occluded small vessels with high positioning accuracy, and both the missed detection and false alarm rates are significantly lower than other methods.

[0058] In the SAR imaging scenarios shown in the last four lines, this invention also demonstrates excellent anti-interference capabilities. As shown in the first two lines, existing methods are subject to radar echo interference caused by strong scattering objects such as port boundaries and dock facilities, resulting in a large number of false alarms and missed detections; while the method of this invention effectively suppresses interference from such non-ship targets, maintaining a low false alarm rate and missed detection rate. The last two lines further demonstrate that in near-shore dense small target scenarios, even in the face of extremely crowded layouts, cluttered backgrounds, or adverse conditions such as nearby strong scattering sources, the method of this invention can still accurately locate ship targets while maintaining a high detection rate and a low false alarm rate.

[0059] In summary, the method of this invention achieves consistently high detection rates and low false alarm rates in both optical and SAR dual-modal remote sensing images, with particularly outstanding performance under conditions of small-scale targets, low-contrast objects, and complex backgrounds. Its strong robustness and anti-interference capabilities in SAR imaging mode represent a significant technological advancement and practical value compared to existing technologies, solving the long-standing problems of false detections, missed detections, and environmental sensitivity in multimodal remote sensing target detection.

[0060] As shown in Table 2, the performance comparison results on the DIOR dataset demonstrate that the method of this invention achieves a significant improvement in detection accuracy. The method of this invention achieves 96.7% on the AP50 metric, surpassing all comparable models, including the YOLO series, OptiSAR-Net (96.4%), and RT-DETR (96.4%). Under the more stringent AP50:95 evaluation metric, the method of this invention achieves 62.3% performance, exceeding all other methods and exhibiting more stable multi-threshold detection capabilities. In terms of model efficiency, the method of this invention demonstrates excellent practicality. Its parameters are 3.6M, significantly lower than complex models such as Faster R-CNN (41.3M) and RT-DETR (32.0M). Although the computational cost of this invention is 19.1 GFLOPs, slightly higher than some lightweight YOLO variants, this cost results in a significant improvement in detection accuracy, thus achieving a better balance between accuracy and computational efficiency. Specifically, experimental results on the DIOR dataset demonstrate that the method of this invention outperforms existing technologies in all key accuracy metrics, achieving optimal overall detection performance while maintaining reasonable computational complexity. These results fully validate the outstanding technical effectiveness, good engineering deployability, and significant practical value of this invention in remote sensing image ship target detection tasks.

[0061] Table 2 Comparison results on the DIOR dataset Figure 5The results of comparative experiments on the DIOR dataset are presented. As shown in the figure, even under the setting of training on a single optical ship data source and testing under the same data distribution, the method of this invention still demonstrates superior detection performance compared to existing technologies, especially showing greater robustness in complex scenes with background noise interference. Specifically, as shown in the first row, other methods (including YOLOv5, YOLOv8, RT-DETR, etc.) are prone to misidentifying land vehicles as ship targets, resulting in significant false alarms; while the method of this invention effectively suppresses the misidentification of such non-ship targets. In the near-shore ship detection scenarios shown in the second and third rows, other methods are prone to incorrectly detecting static structures such as containers and buildings on shore as ships, while the method of this invention can accurately distinguish ships from nearby shore objects, significantly reducing the false alarm rate. Furthermore, as shown in the fourth row of the figure, in the scenario of strong wake (spray) generated by the stern of a ship traveling at high speed, background dynamic noise can easily cause existing methods to miss detections; in contrast, although the prediction boundary of the method of this invention is slightly larger than the true label, it still successfully achieves complete detection of the target, avoiding missed detections. The above results collectively demonstrate that the method of the present invention has stronger discrimination ability and robustness under challenging conditions such as complex backgrounds, strong interference, and changes in target shape. It effectively solves the problems of false alarms and missed alarms caused by background confusion in the existing technology for remote sensing ship detection, and has outstanding substantive features and significant technological progress.

[0062] As shown in Table 3, the comprehensive performance comparison results on the SSDD dataset demonstrate that the method of this invention exhibits a significant advantage in detection accuracy. Specifically, on the AP50 metric, this invention achieves a high accuracy of 98.8%, second only to the current best DBW-YOLO model (99.2%), but still significantly outperforming other competing models, such as RT-DETR (95.8%). More importantly, under the more stringent AP50:95 evaluation criterion, the method of this invention ranks first with a performance of 76.7%, surpassing YOLOv8-n (76.1%) and OptiSAR-Net (76.2%), which fully demonstrates the excellent generalization ability and robustness of the method of this invention in single-source SAR ship detection.

[0063] Overall, data analysis shows that the method of this invention achieves excellent detection accuracy on the SSDD dataset, particularly reaching the optimal level on the AP50:95 metric, which comprehensively measures model performance. These results not only verify the effectiveness of the method of this invention in complex remote sensing ship detection tasks, but also highlight its advanced nature and practicality compared to existing technologies. By maintaining a high level of detection accuracy under different conditions, this invention solves the problems of false alarms and false negatives existing in traditional methods, demonstrating outstanding technological innovation and application prospects.

[0064] Table 3 Comparison results on the SSDD dataset Figure 6 The comparative experimental detection results on the SSDD dataset are presented. As shown in the figure, under various complex scenarios, the method of this invention achieves the most accurate target detection, detecting almost all ship targets, and its detection performance is significantly better than other existing methods. It is worth noting that the SSDD dataset contains SAR images with four polarization modes (HH, VV, VH, HV). Experimental results show that the method of this invention can not only effectively overcome the significant modal differences between optical and SAR images, but also has good adaptability, robustly handling subtle feature changes caused by different SAR polarization modes. This further verifies the generalization ability and robustness of this invention under multimodal remote sensing data, demonstrating its substantial technological advancement in cross-modal universal target detection.

[0065] While the invention has been disclosed above with reference to preferred embodiments, it is not intended to limit the scope of the invention. Those skilled in the art can make various modifications and refinements without departing from the spirit and scope of the invention. Therefore, the scope of protection of this invention is determined by the claims.

Claims

1. A dynamic cross-domain general ship detection method based on edge wavelet guidance, characterized in that, Includes the following steps: Step 1: Prepare a multimodal dataset, which includes optical images and synthetic aperture radar (SAR) images; Step 2: Construct a general ship detection model, which includes an edge wavelet guided attention (EWGA) module, an adaptive dynamic dilated convolution (ADDC) module, and a geometric structure attention enhancement (GSAA) module. The EWGA module is used to extract ship structural features independent of the imaging modality through a space-frequency dual decoupling mechanism; the ADDC module is used to dynamically adjust the convolutional receptive field according to the input features to align the multi-scale target distribution of optical and SAR images; and the GSAA module is used to fuse three geometric priors—depth consistency, spatial proximity, and structural continuity—to suppress background noise interference. Step 3: Train a general ship detection model using a multimodal dataset; Step 4: Input the image to be detected into the trained general ship detection model and output the ship detection results.

2. The method as described in claim 1, characterized in that, The EWGA module decomposes the input features into low-frequency and high-frequency components through discrete wavelet transform, and generates a guiding signal based on the edge detection results. It then performs gating enhancement on the high-frequency components to highlight the contour structure features of the ship.

3. The method as described in claim 1, characterized in that, The ADDC module employs a learnable dynamic inflation rate and combines it with an adaptive activation function based on feature statistics to calibrate the cross-modal feature response intensity in real time.

4. The method as described in claim 1, characterized in that, The GSAA module generates a depth decomposition mask from the depth map, a position attenuation mask by calculating the Manhattan distance between pixels, and a structural continuity mask by comparing structural similarity. These three are then fused into a composite attention bias to suppress background noise and enhance attention to geometrically consistent regions.

5. The method as described in claim 1, characterized in that, The general ship detection model can achieve AP on the optical image dataset DIOR, the SAR image dataset SSDD, and the self-built multimodal dataset MRSSD. 50 Detection accuracy of no less than 90%.