An underwater sonar target tracking method based on semantic verification

By employing enhanced RT-DETR, BoT-SORT, and SiamRPN++ multi-stage tracking mechanisms, along with BLIP-2 semantic verification, the problems of detection interruption and drift in underwater target tracking are solved, achieving high-precision and robust target tracking.

CN123182004APending Publication Date: 2026-11-27NANKAI UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611503926.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-24
Publication Date
2026-11-27

AI Technical Summary

Technical Problem

Existing underwater target tracking methods suffer from severe problems such as detection interruption, trajectory breakage, and single-target tracker drift in complex underwater acoustic environments. They also lack semantic verification mechanisms, resulting in poor robustness of the tracking system.

Method used

An enhanced RT-DETR target detection model is used for frame-by-frame detection, combined with the BoT-SORT multi-target tracker and the SiamRPN++ twin tracker for cross-frame temporal correlation, and zero-sample semantic verification is performed using the BLIP-2 vision-language model. A four-stage pipeline of detection-correlation-recovery-verification is constructed.

Benefits of technology

It significantly improves target tracking performance in complex underwater sonar environments, enhances detection accuracy, ensures tracking continuity, and improves robustness by eliminating drift prediction boxes through semantic verification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123182004A_ABST
    Figure CN123182004A_ABST
Patent Text Reader

Abstract

The application relates to the field of underwater target tracking, in particular to an underwater sonar target tracking method based on semantic verification, which comprises frame-by-frame detection based on an enhanced RT-DETR target detection model, extraction of high-confidence bounding boxes meeting preset reliability requirements, cross-frame association of the high-confidence bounding boxes of each frame by using a BoT-SORT multi-target tracker, generation and maintenance of continuous tracking trajectories, if the continuous tracking trajectory is interrupted, a high-confidence template of a corresponding target is cropped from a high-confidence bounding box detected in the last frame before the interruption of the trajectory, a SiamRPN++ twin tracker is used to locally search in a current frame to generate a candidate bounding box, BLIP-2 is used for zero-shot semantic verification of the candidate target, a fusion confidence is determined according to a semantic similarity score and a tracking confidence, and if the fusion confidence is greater than or equal to a preset dynamic acceptance threshold, the candidate bounding box is associated to the interrupted tracking trajectory to restore the continuous tracking trajectory.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of underwater target tracking, and more specifically, to an underwater sonar target tracking method based on semantic verification. Background Technology

[0002] Currently, in the field of underwater target tracking, mainstream visual tracking methods are mainly divided into multi-target tracking (MOT) methods based on the "detection-tracking" paradigm and single-target tracking (SOT) methods based on Siamese networks. Multi-target tracking methods based on the "detection-tracking" paradigm (such as BoT-SORT, ByteTrack, StrongSORT, etc.) rely on deep learning detectors to detect targets frame by frame and perform cross-frame association through Kalman filtering and appearance features. This method has achieved good results in the field of optical vision. Meanwhile, to cope with the situation of temporary detector failure, single-target tracking methods based on Siamese networks (such as SiamRPN++, etc.) have been introduced. These methods utilize the target template from the previous reliable frame to perform cross-correlation matching in the local search region to bridge detection interruptions and maintain trajectory continuity.

[0003] However, the aforementioned existing technologies have significant drawbacks when applied to underwater sonar target tracking in complex underwater acoustic environments. First, global multi-target trackers heavily rely on the performance of upstream detectors. In complex underwater acoustic environments, reverberation noise and weak textures often lead to false negatives in deep learning detectors, resulting in trajectory breakage, premature trajectory termination, and identity switching (IDSW), causing serious detection interruption problems. Second, most existing visual trackers are designed for optical images and perform poorly on low frame rates and noisy sonar sequences. Due to the highly homogeneous texture of sonar images, Siamese network-based trackers are prone to "drifting" to background noise during trajectory recovery. Even if the target is severely occluded or has left the frame, it will still maintain an artificially high correlation score, generating continuous tracking errors and false alarms, i.e., the anchor frame drift problem.

[0004] In addition, existing tracking methods generally lack explicit semantic verification mechanisms. Trackers cannot autonomously determine whether the target has been completely occluded or left the frame. As a result, after detection interruption or anchor frame drift, error accumulation and false detections continue to accumulate, which seriously reduces the robustness of the tracking system.

[0005] In summary, existing technologies cannot effectively address the issues of trajectory breakage caused by detection interruptions and false alarms caused by single-target tracker drift in underwater sonar scenarios. There is an urgent need for a multi-stage tracking mechanism that can integrate detection, correlation, recovery, and semantic verification to improve the accuracy and continuity of underwater sonar target tracking. Summary of the Invention

[0006] In view of this, this application provides an underwater sonar target tracking method based on semantic verification to solve the above-mentioned technical problems.

[0007] The technical solution provided in this application is as follows: A semantically validated underwater sonar target tracking method includes: Acquire a sequence of sonar images captured by an underwater forward-looking sonar, and perform frame-by-frame detection on the sonar image sequence based on a pre-built enhanced RT-DETR target detection model; When a high-confidence bounding box that meets the preset confidence requirement is extracted within a frame, the BoT-SORT multi-target tracker is used to perform cross-frame temporal correlation on the high-confidence bounding boxes of each frame to generate and maintain a continuous tracking trajectory. If the continuous tracking trajectory is interrupted because no high-confidence bounding box is detected in the current frame, the high-confidence template of the corresponding target is cropped from the high-confidence bounding box detected in the last frame before the trajectory was interrupted, and the SiamRPN++ twin tracker is used to perform a local search in the current frame to generate candidate bounding boxes. The BLIP-2 vision-language model is used to perform zero-shot semantic verification on the candidate targets in the candidate bounding boxes. The semantic similarity scores of the candidate targets and the SiamRPN++ tracking confidence are fused, and the fused confidence is determined. When the fusion confidence is greater than or equal to a preset dynamic acceptance threshold, the candidate bounding box is associated with the interrupted tracking trajectory to restore the continuous tracking trajectory.

[0008] In one possible implementation, before performing frame-by-frame detection of the sonar image sequence based on the enhanced RT-DETR, the method further includes: The current sonar image frame is resized, padded, and normalized to obtain the image input tensor; The image input tensor is input into the backbone network of the enhanced RT-DETR for stepwise downsampling and feature extraction to obtain the intermediate feature map of the current frame, and the intermediate feature map is used as the input feature tensor for subsequent frame-by-frame detection.

[0009] In one possible implementation, the pre-built enhanced RT-DETR target detection model includes a hierarchical context fusion network HCF-Net and a cross-stage local CSP module; Frame-by-frame detection of the sonar image sequence based on the enhanced RT-DETR includes: The input feature tensor is subjected to multi-branch feature extraction using a hierarchical context fusion network HCF-Net to obtain local branch features, global branch features, and serial convolutional branch features. The local branch features, global branch features, and serial convolutional branch features are fused to obtain preliminary fused features; One-dimensional channel attention and two-dimensional spatial attention are applied sequentially to the preliminary fused features to obtain the enhanced feature output; The enhanced feature output is sampled and spliced ​​with the multi-scale features of the backbone network, and the fused features of the corresponding scale are input into the cross-stage local CSP module. The CSP module outputs multi-scale detection features, and the RT-DETR detection head outputs class confidence and bounding box coordinates to filter out high-confidence bounding boxes.

[0010] One possible implementation involves using a BoT-SORT multi-object tracker to perform cross-frame temporal association of high-confidence bounding boxes in each frame, including: The motion state of the tracked target is estimated by Kalman filtering; wherein, the motion state includes the target position, bounding box scale and change trend maintained by the Kalman filter inside BoT-SORT; Identity matching is performed by combining visual appearance features, and high-confidence bounding boxes predicted frame by frame are associated across frames; the visual appearance features are the ReID feature vectors obtained by encoding the image regions corresponding to the target bounding boxes through appearance feature extraction networks; by comparing the ReID feature vectors of the current detection boxes with historical trajectory features, the appearance matching cost of the target identity is obtained.

[0011] One possible implementation involves associating high-confidence bounding boxes predicted frame-by-frame across frames, including: Using Kalman filtering, the position and scale of each existing trajectory in the current frame are predicted based on the historical state of the existing trajectories, thus obtaining the trajectory prediction box; Calculate the spatial matching cost between the high-confidence bounding box of the current frame and the trajectory prediction box, and calculate the appearance matching cost between the high-confidence bounding box of the current frame and the existing trajectory; wherein, the spatial matching cost is used to characterize the positional and scale differences between the current detection box and the trajectory prediction box; the appearance matching cost is used to characterize the ReID feature differences between the current detection box and the existing trajectory, and is determined by the distance between the ReID feature vector of the current detection box and the historical ReID feature vector of the existing trajectory; The fusion association cost is obtained based on the spatial matching cost and the appearance matching cost; wherein, the fusion association cost is used to characterize the comprehensive matching cost between the current detection box and the existing trajectory; Based on the fusion association cost, the matching between the high-confidence bounding box of the current frame and the existing trajectory is completed.

[0012] One possible implementation involves associating frame-by-frame predicted high-confidence bounding boxes across frames. This also includes: successfully matched high-confidence bounding boxes inheriting the trajectory identifier of the corresponding existing trajectory and using it to update the Kalman state and appearance features of the corresponding existing trajectory; unmatched high-confidence bounding boxes being used to establish new trajectories; and unmatched existing trajectories entering a temporarily lost state and triggering the subsequent SiamRPN++ local recovery process.

[0013] One possible implementation uses the SiamRPN++ twin tracker to perform a local search in the current frame to generate candidate bounding boxes, including: When detection is interrupted, the high-confidence template of the corresponding target is cropped from the high-confidence bounding box detected in the last frame before the trajectory was interrupted, and the local search area is initialized in the current frame; Using a convolutional neural network with shared parameters, the template features of the high-confidence template and the search region features of the local search region in the current frame are extracted respectively. After adjusting the template features and the search region features to a preset number of channels through 1×1 convolution, depth cross-correlation is performed channel by channel to generate a similarity feature map; The similarity feature maps are input into the classification branch and the bounding box regression branch respectively to obtain the confidence of the predicted candidate targets, as well as the bounding box position and scale offset of each layer. The multi-level prediction results are weighted and fused, and the result with the highest score is determined as the candidate bounding box to maintain the continuity of the tracking trajectory.

[0014] One possible implementation involves using the BLIP-2 vision-language model to perform zero-shot semantic verification of candidate targets within the candidate bounding box, including: Guided by preset text prompts, visual and textual features of candidate regions are extracted and projected into a shared latent space. The semantic similarity score is obtained by calculating the cosine similarity between visual features and text features. S sem It is used to evaluate the consistency between candidate regions and valid target semantic concepts.

[0015] One possible implementation involves fusing the semantic similarity score of the candidate targets with the SiamRPN++ tracking confidence, and determining the fused confidence, including: Maintain a sliding window of historical motion confidence scores, calculate the mean and standard deviation of SiamRPN++ tracking confidence within the window, and use the standard scores to quantify the burst tracking bias of the current frame. When the sudden tracking deviation exceeds a preset deviation threshold, the fusion weight of the SiamRPN++ tracking confidence is reduced to a preset minimum value. When the sudden tracking deviation is less than or equal to the preset deviation threshold, the fusion weight of the SiamRPN++ tracking confidence is adaptively and linearly adjusted according to the current SiamRPN++ tracking confidence. The fused confidence score is calculated by a convex combination of the fused weights and semantic weights of the SiamRPN++ tracking confidence score.

[0016] Compared with the prior art, the technical solution provided in this application has the following beneficial effects: This application significantly improves target tracking performance in complex underwater sonar environments by constructing a four-stage pipeline of "detection-association-recovery-verification". First, the enhanced RT-DETR effectively solves the problem of difficult feature extraction of small targets under low signal-to-noise ratio by introducing a hierarchical context fusion network and a CSP module, thereby improving detection accuracy. Second, the dual-path association recovery mechanism uses SiamRPN++ to fill the trajectory gaps caused by detection interruptions, ensuring the continuity of tracking. Finally, the innovative introduction of the BLIP-2 zero-shot semantic verification module eliminates drift prediction boxes caused by sonar texture homogenization through visual-semantic consistency evaluation, significantly improving the robustness of tracking in complex underwater acoustic environments. Attached Figure Description

[0017] Figure 1 This is a flowchart of an underwater sonar target tracking method based on semantic verification, provided in Embodiment 1 of this application.

[0018] Figure 2 This is a model architecture diagram of the underwater sonar target tracking method based on semantic verification provided in Embodiment 1 of this application.

[0019] Figure 3 This is an improved ablation radar image provided in Embodiment 2 of this application.

[0020] Figure 4 This is a schematic diagram of the tracking effect provided in Embodiment 2 of this application.

[0021] Figure 5 This is a comparison chart of the tracker performance provided in Embodiment 2 of this application.

[0022] Figure 6 This is a comparison chart of dynamic thresholds provided in Embodiment 2 of this application.

[0023] Figure 7 This is a comparison diagram of the target detection models provided in Embodiment 2 of this application. Detailed Implementation

[0024] The technical solutions in the embodiments of this application will be clearly and completely described below with reference to the embodiments of this application. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the scope of protection of this application.

[0025] Example 1 See Figure 1 This is a flowchart of an underwater sonar target tracking method based on semantic verification provided in Embodiment 1 of this application. Figure 1 As shown, the specific implementation steps of the above method include: Step 101: Acquire the sonar image sequence collected by the underwater forward-looking sonar, and perform frame-by-frame detection on the sonar image sequence based on the pre-built enhanced RT-DETR target detection model.

[0026] like Figure 2 As shown in the embodiments of this application, the RT-DETR detector is structurally enhanced by introducing a hierarchical context fusion network (HCF-Net) and a cross-stage local (CSP) module to improve the feature extraction capability of small targets under low signal-to-noise ratio and weak texture conditions.

[0027] In some embodiments, after acquiring the sonar image sequence from the underwater forward-looking sonar, the current sonar image frame is read, resized, padded, and normalized to obtain a 640×640 detection network input tensor. This input tensor is then fed into the backbone network of the enhanced RT-DETR, sequentially passing through HGStem and various feature extraction layers for downsampling and feature encoding, resulting in an intermediate feature map of the current frame. This intermediate feature map serves as the input feature tensor of HCF-Net. F , F The dimension can be represented as B × C × H × W Before entering the multi-branch structure, the channel dimensions are adjusted by pointwise convolution, and then fed into the local branch, global branch and serial convolution branch respectively.

[0028] Specifically, to capture the multi-scale features of small targets, a hierarchical context fusion network (HCF-Net) is introduced into the aforementioned enhanced RT-DETR target detection model. A multi-branch feature extraction strategy is employed, and the input feature tensor is divided according to different patch sizes (e.g., 2 local branches and 4 global branches). F It is divided into three branches: local, global, and sequential convolution. After adjusting the dimensions through initial pointwise convolution, the following are obtained: The initial characteristics obtained through fusion are represented as follows:

[0029] In the formula, Indicates local branching characteristics. Represents global branch features. This represents the features of the serial convolution branch.

[0030] Then an adaptive attention mechanism is applied: Passing through a one-dimensional channel attention map in sequence and 2D spatial attention map Combining activation and batch normalization, element-wise multiplication yields the final enhanced feature output. , is represented as:

[0031] This attention-driven fusion enhances the discriminative features of small sonar targets and suppresses background reverberant noise.

[0032] A Cross-Stage Local (CSP) module is introduced into the detection architecture. By partitioning the input feature maps of CSP and merging them through a cross-stage hierarchical structure, computational redundancy is reduced and gradient propagation is improved. This improved structure enhances feature learning for sonar targets, achieving mAP@0.5 = 0.923 in experiments.

[0033] Specifically, the CSP input feature map mentioned above is a multi-scale fused feature map. Specifically, this application enhances the features obtained from HCF-Net. First, the features are encoded using AIFI and other methods. Then, they are upsampled or downsampled and concatenated with other scale features such as P3 and P4 output from the backbone network to obtain the input feature map of the CSP module. Subsequently, the CSP module further fuses these features to form P3, P4, and P5 detection features.

[0034] In one feasible approach, for the feature map input to the CSP module, a cross-stage preservation branch and a local feature extraction branch are established: the preservation branch undergoes a 1×1 convolution, and the local feature extraction branch sequentially undergoes a 1×1 convolution, RepConv, and convolution-batch normalization-activation operation. The outputs of the two branches are then concatenated along the channel direction, and channel fusion is completed through a 1×1 convolution to form P3, P4, and P5 multi-scale detection features. Finally, the multi-scale features are input into the RT-DETR detection head, which outputs the target class confidence and bounding box coordinates. Bounding boxes with a confidence level of not less than 0.65 are selected as the aforementioned high-confidence bounding boxes.

[0035] Step 102: When a high-confidence bounding box that meets the preset confidence requirement is extracted within a frame, the BoT-SORT multi-target tracker is used to perform cross-frame temporal correlation on the high-confidence bounding boxes of each frame to generate and maintain a continuous tracking trajectory.

[0036] This application extracts high-confidence bounding boxes based on an enhanced RT-DETR object detection model and directly submits them to BoT-SORT for global temporal correlation. Specifically, this application uses the target category confidence score output by the enhanced RT-DETR as the selection criterion. For the... i For each test result, let its highest category confidence level be 1.

[0037] In the formula, Indicates the first i Target category confidence of each detection result i Indicates the sequence number of the target query or detection result. Represents any target category in the preset target category set. This indicates the output of the enhanced RT-DETR decoder. i One target query, Indicates the first i The target query belongs to the category c The predicted probability, This indicates that the maximum value is taken across all preset target categories. when When the confidence level is ≥0.65, the detection result is retained, and its corresponding bounding box is identified as a high-confidence bounding box, which is then input into BoT-SORT for cross-frame association. The IoU parameter used in the detection phase is 0.6, which has a different purpose than the target confidence threshold of 0.65.

[0038] When the sequence is uninterrupted, BoT-SORT acts as the master tracker, estimating motion state through Kalman filtering and performing identity matching by combining visual appearance features. It associates the bounding boxes predicted frame by frame by frame by enhanced RT-DETR to maintain target identity consistency and ensure a high multi-target tracking evaluation index IDF1.

[0039] The aforementioned motion states refer to the target position, bounding box scale, and their changing trends maintained by the Kalman filter within the BoT-SORT. The Kalman filter predicts the target's position and scale in the current frame based on the trajectory state from the previous moment, and then updates the predicted state using the detected bounding boxes matched in the current frame, thus forming a continuous motion trajectory. The specific state variables and parameters are determined by the BoT-SORT implementation used.

[0040] The aforementioned visual appearance features are ReID feature vectors obtained by encoding the image regions corresponding to high-confidence bounding boxes through an appearance feature extraction network, used to describe the appearance identity information of the target. This application employs the OSNet-x0.25 appearance feature extraction model. Specifically, the target region is cropped from the current sonar frame based on the detected bounding box, and after size adjustment and normalization, it is input into OSNet-x0.25 to obtain a fixed-dimensional appearance feature vector. The distance between the current detected box features and the historical trajectory appearance features is then calculated as one of the criteria for target identity matching.

[0041] The enhanced frame-by-frame prediction of high-confidence bounding boxes is associated across frames. Specifically, this involves: using Kalman filtering to predict the position and scale of each trajectory in the current frame based on the historical state of existing trajectories, thus obtaining trajectory prediction boxes. The spatial matching cost between the current detection box and the trajectory prediction box is calculated, as well as the appearance matching cost between the high-confidence bounding box in the current frame and existing trajectories. The spatial matching cost characterizes the positional and scale differences between the current detection box and the trajectory prediction box, and can be represented by their intersection-over-union (IoU) distance. The appearance matching cost characterizes the ReID feature differences between the current detection box and existing trajectories, and is determined by the distance between the ReID feature vector of the current detection box and the historical ReID feature vector of the existing trajectory, and can be represented by cosine distance. During matching, obviously mismatched detection box-trajectory combinations are first excluded using preset spatial and appearance thresholds. Then, the gated spatial matching results and appearance matching results are combined into an association cost matrix, and the detection boxes and trajectories are assigned based on this matrix. The smaller the association cost, the better the match between the detection box and the trajectory.

[0042] Furthermore, based on the aforementioned spatial matching cost and appearance matching cost, a fusion association cost is obtained. Specifically, this fusion association cost is the comprehensive matching cost used by BoT-SORT when matching the current detection box with existing trajectories. Based on this fusion association cost, the matching between the high-confidence bounding box of the current frame and existing trajectories is completed.

[0043] In this embodiment, successfully matched detection boxes inherit the corresponding trajectory identifier and are used to update the Kalman state and trajectory appearance features; unmatched detection boxes are used to establish new trajectories, and unmatched existing trajectories enter a temporarily lost state and trigger the subsequent SiamRPN++ local recovery process.

[0044] Step 103: If the above continuous tracking trajectory is interrupted because no high-confidence bounding box is detected in the current frame, the high-confidence template of the corresponding target is cropped from the high-confidence bounding box detected in the last frame before the trajectory was interrupted. The SiamRPN++ twin tracker is used to perform a local search in the current frame to generate candidate bounding boxes.

[0045] When the detector misses a detection, the traditional MOT will abruptly terminate the trajectory. However, this application designs a backoff mechanism. When acoustic shadows or target deformation cause detection failure, SiamRPN++ is activated to perform local anchor frame recovery based on the target template of the previous reliable frame.

[0046] Specifically, when detection is interrupted, SiamRPN++ uses a high-confidence template extracted from the previous successful tracking frame to initialize a local search region in the current frame, calculates the cross-correlation between the template features and the search region features, and outputs a dense set of candidate bounding boxes. Through the dual-path correlation-recovery mechanism combining BoT-SORT and SiamRPN++, trajectory continuity is maintained when detection is intermittently lost.

[0047] Specifically, the high-confidence template mentioned above is a target region image cropped from the last successfully detected and associated reliable frame before the trajectory interruption, according to the high-confidence bounding box of the target. Specifically, let the last reliable frame be... I t-1 The corresponding bounding box is B t-1 Then from I t-1 medium crop B t-1 The defined target region, after preprocessing such as context expansion and resizing, forms a template image for SiamRPN++. z The search area is determined centered on the nearest location of the target in the current frame. x Candidate target localization is achieved by utilizing template features and search region features.

[0048] The generation of candidate bounding boxes specifically includes: using a convolutional neural network with shared parameters to extract template features from the high-confidence template and search region features from the local search region of the current frame. The template features and search region features are then adjusted to a preset number of channels via 1×1 convolutions, and deep cross-correlation is performed channel-by-channel to generate similarity feature maps. These similarity feature maps are then input into the classification branch and the bounding box regression branch to obtain the confidence scores of the predicted candidate targets at each layer, as well as the bounding box positions and scale offsets. The multi-layer prediction results are then weighted and fused, and the result with the highest score is determined as the candidate bounding box to maintain the continuity of the tracking trajectory.

[0049] In some embodiments, this application uses the configuration siamrpn_r50_l234_dwxcorr, which uses ResNet-50 with shared parameters to extract the second, third, and fourth layer features of the template image and the search region, and uses deep cross-correlation to complete the template-search region matching. Optionally, the above-mentioned preset number of channels can be 256, or it can be set according to the actual situation. This application does not make specific limitations.

[0050] Step 104: Use the BLIP-2 vision-language model to perform zero-shot semantic verification on the candidate targets in the above candidate bounding boxes, fuse the semantic similarity scores of the above candidate targets and the SiamRPN++ tracking confidence, and determine the fusion confidence.

[0051] Since the aforementioned appearance-based local search is prone to drift in sonar images, this application further introduces a zero-shot semantic verification module based on BLIP-2 to perform visual-semantic consistency evaluation on candidate bounding boxes, in order to determine whether the recovered trajectory should be retained or terminated when drift occurs, and to remove the drifted prediction box.

[0052] Specifically, when detection fails, the candidate regions proposed by SiamRPN++ are... Evaluation was performed using BLIP-2. Guided by a predefined text cue P, the model extracted visual features. Text features Projected into the shared latent space, semantic similarity scores are calculated using cosine similarity. , is represented as:

[0053] In the formula, The score ∈ [0,1] indicates that the candidate region is more consistent with the semantic concept of the effective target. A score close to 0 indicates that the tracker has drifted into the background noise.

[0054] Maintain a sliding window for historical SiamRPN++ tracking confidence, and apply this to SiamRPN++ tracking confidence. S mot With semantic score Perform dynamic weighted fusion. Let... μ t-1 , σ t 1 represents the mean and standard deviation up to frame t-1. Calculate... Z The score, quantifying the burst tracking error in the current frame, is expressed as:

[0055] In the formula, Take 10 -6 Indicates the first t The SiamRPN++ tracking confidence score for each frame is calculated. Specifically, SiamRPN++ performs deep cross-correlation between template features and current search region features, and outputs the confidence score of each candidate location belonging to the target through a classification branch. The highest confidence score corresponding to the final candidate bounding box is normalized to [0,1] to obtain the confidence score of the frame. t Frame tracking confidence The program prioritizes reading from the output of SiamRPN++. best score The confidence score field. If the invoked implementation does not return a confidence score, the intersection-union ratio (IUU) of the candidate bounding box and the previous reliable bounding box is used as a backup score.

[0056] like > τ drop (Empirical estimate is 3.0), which is judged as "sudden failure". At this time, the fusion weight of the tracking confidence is forcibly adjusted. α t Press down to the minimum value α min (A value of 0.3 is acceptable), with a strong reliance on semantic verification. Otherwise, during normal tracking... α t Linear adaptive:

[0057]

[0058] In the formula, Indicates the default weight. This represents the linear adjustment coefficient. clip (·) indicates that the value is restricted to a given upper and lower limit range. In this embodiment of the application, the preset lower limit of the tracking confidence fusion weight is set to . α min The preset upper limit is α max . clip ( x , α min , α max ) indicates when x Less than α min Time to take α min ,when x Greater than α max Time to take α max In other cases, take x Based on this, the SiamRPN++ tracking confidence weights obtained through linear calculation are limited to a given upper and lower bound to prevent the fusion result from completely ignoring tracking or semantic information. Optionally, the aforementioned preset lower bound... α min 0.3 is acceptable, with a preset upper limit. α max A value of 0.9 is acceptable, with a default weight of 0.6, and a linear adjustment coefficient. A value of 0.8 can be taken, and the above fusion weights are... αt This can be further expressed as: = clip [0.6+0.8( -0.5), 0.3, 0.9] The final fusion confidence score is calculated using a convex combination and is expressed as follows:

[0059] In the formula, The fusion weights are used to track confidence levels.

[0060] Step 105: When the above fusion confidence is greater than or equal to the preset dynamic acceptance threshold, the above candidate bounding boxes are associated with the interrupted tracking trajectory to restore the continuous tracking trajectory.

[0061] Specifically, this application employs distributed sensing dynamic gating instead of static thresholds. (Maintenance) A sliding window that dynamically accepts thresholds T dyn Take the lower bound of the 95% confidence interval for recent tracking quality, and express it as: = clip ( -2 (0.45, 0.90) In the formula, The mean of the fusion score within the window, The standard deviation of the fusion score within the window, and the confidence multiplier. =2.0, This is the lower bound of the absolute baseline.

[0062] Only when Only after the candidate target is verified is the tracking device validated. This mechanism allows the tracker to adapt naturally to slow environmental changes while immediately rejecting sudden statistical anomalies indicating anchor frame drift, such as... Figure 3 As shown in the image.

[0063] By combining visual tracking with zero-shot semantic verification, this application reduces tracker drift and significantly improves the robustness of tracking in complex underwater acoustic environments. Furthermore, zero-shot semantic verification does not require task-specific retraining and can be transferred to different detection backbones and correlation algorithms, demonstrating good engineering adaptability and application potential.

[0064] Example 2 To verify the effectiveness and robustness of the semantic verification-based underwater sonar target tracking method described in this application, Embodiment 2 of this application provides the following experimental verification scheme.

[0065] Platform: PyTorch, NVIDIA RTX 4090 GPU, Intel Core i9 CPU, 64GB RAM.

[0066] Enhanced RT-DETR: Training for 100 epochs, batch size=16, optimizer AdamW, initial learning rate and weight decay are both 1e-4.

[0067] Semantic verification: The blip2-opt-2.7b model from Hugging Face Transformers was adopted; the semantic drift rejection threshold τ was empirically fixed at 0.65.

[0068] Dataset: more than 3,000 still images; 13 consecutive video sequences totaling 3,151 frames, divided into a standard subset (6 sequences, 991 frames) and a challenge subset (7 sequences, 2,160 frames).

[0069] Detailed experimental data are shown in Tables 1 to 6, and the relevant model structure and experimental results are as follows: Figures 2 to 7 As shown.

[0070] Table 1: Ablation experiments using enhanced RT-DETR detectors

[0071] Table 2: Performance comparison with mainstream trackers (lower CLE is better, higher CLE is better for the others)

[0072] Table 3: Ablation Experiment of Tracking Module (Overall Dataset)

[0073] Table 4: Tracking performance in challenging sonar scenarios

[0074] Table 5: Comparison of Different Gating Threshold Strategies

[0075] Table 6: Performance of the complete system under different detection backbones (MOTA↑ / IDF1↑)

[0076] This application embodiment uses real forward-looking sonar video acquired by an Oculus M1200d multi-beam forward-looking sonar (dual-frequency 1.2MHz / 750kHz, 512 beams per frame, maximum 40Hz update rate, 2.5mm distance resolution) and employs a complete pipeline of "enhanced RT-DETR + BoT-SORT + SiamRPN +++ BLIP-2" to perform multi-target tracking on 13 consecutive sequences (3151 frames in total). As shown in the table above, the system achieves MOTA=0.8479, IDF1=0.8440, CLE=0.0187, and OP=0.6666 on the overall dataset, achieving an optimal balance between target recall and identity consistency.

[0077] On a challenging subset (7 sequences, 2160 frames) with strong speckle noise, frequent multipath occlusion, and long-term detection loss, the system achieved MOTA=0.7302 and IDF1=0.7167 after introducing semantic verification. This is a significant improvement compared to using only the BoT-SORT baseline (MOTA=0.5710) and only adding SiamRPN++ (MOTA=0.6492). It can terminate the drift trajectory when the target is occluded / disappears and re-associate when the target reappears.

[0078] In summary, compared with the prior art, the technical solution provided in this application has the following beneficial effects: (1) The four-stage “detection-association-recovery-verification” pipeline structure is clear, decoupled, and can be integrated with different association methods. In the experiment, the MOTA and IDF1 of all 7 baseline trackers (OC-SORT, DeepOCSORT, BoostTrack, StrongSORT, ByteTrack, ImprAssoc, BoT-SORT) were improved, and the versatility is strong.

[0079] (2) Enhanced RT-DETR: HCF-Net achieves multi-scale context fusion and CSP optimizes gradient propagation. The combination of the two improved mAP@0.5 from the baseline 0.889 to 0.923 in the ablation experiment.

[0080] (3) Dual-path association-recovery structure: BoT-SORT is responsible for the global trajectory, and SiamRPN++ is responsible for the local recovery during detection intervals. They complement each other and avoid the trajectory from being broken due to a single missed detection.

[0081] (4) BLIP-2 semantic verification, as an independent verification dimension orthogonal to visual appearance, combined with adaptive dynamic gating, can eliminate semantically inconsistent drift boxes with zero samples without retraining. It significantly reduces tracker drift, false alarms, and trajectory breaks, with an overall dataset MOTA of 0.8479 and IDF1 of 0.8440.

[0082] Although embodiments of this application have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and variations can be made to these embodiments without departing from the principles and spirit of this application, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A semantically verified underwater sonar target tracking method, characterized in that, include: Acquire a sequence of sonar images captured by an underwater forward-looking sonar, and perform frame-by-frame detection on the sonar image sequence based on a pre-built enhanced RT-DETR target detection model; When a high-confidence bounding box that meets the preset confidence requirement is extracted within a frame, the BoT-SORT multi-target tracker is used to perform cross-frame temporal correlation on the high-confidence bounding boxes of each frame to generate and maintain a continuous tracking trajectory. If the continuous tracking trajectory is interrupted because no high-confidence bounding box is detected in the current frame, the high-confidence template of the corresponding target is cropped from the high-confidence bounding box detected in the last frame before the trajectory was interrupted, and the SiamRPN++ twin tracker is used to perform a local search in the current frame to generate candidate bounding boxes. The BLIP-2 vision-language model is used to perform zero-shot semantic verification on the candidate targets in the candidate bounding boxes. The semantic similarity scores of the candidate targets and the SiamRPN++ tracking confidence are fused, and the fused confidence is determined. When the fusion confidence is greater than or equal to a preset dynamic acceptance threshold, the candidate bounding box is associated with the interrupted tracking trajectory to restore the continuous tracking trajectory.

2. The underwater sonar target tracking method based on semantic verification according to claim 1, characterized in that, Before performing frame-by-frame detection of the sonar image sequence based on the enhanced RT-DETR, the method further includes: The current sonar image frame is resized, padded, and normalized to obtain the image input tensor; The image input tensor is input into the backbone network of the enhanced RT-DETR for stepwise downsampling and feature extraction to obtain the intermediate feature map of the current frame, and the intermediate feature map is used as the input feature tensor for subsequent frame-by-frame detection.

3. The underwater sonar target tracking method based on semantic verification according to claim 2, characterized in that, The pre-built enhanced RT-DETR target detection model includes a hierarchical context fusion network HCF-Net and a cross-stage local CSP module; The input feature tensor is subjected to multi-branch feature extraction using a hierarchical context fusion network HCF-Net to obtain local branch features, global branch features, and serial convolutional branch features. The local branch features, global branch features, and serial convolutional branch features are fused to obtain preliminary fused features; One-dimensional channel attention and two-dimensional spatial attention are sequentially applied to the preliminary fused features to obtain enhanced feature output; The enhanced feature output is sampled and spliced ​​with the multi-scale features of the backbone network, and the fused features of the corresponding scale are input into the cross-stage local CSP module. The CSP module outputs multi-scale detection features, and the RT-DETR detection head outputs class confidence and bounding box coordinates to filter out high-confidence bounding boxes.

4. The underwater sonar target tracking method based on semantic verification according to claim 1, characterized in that, The BoT-SORT multi-object tracker is used to perform cross-frame temporal association of high-confidence bounding boxes in each frame, including: The motion state of the tracked target is estimated by Kalman filtering; wherein, the motion state includes the target position, bounding box scale and change trend maintained by the Kalman filter inside BoT-SORT; Identity matching is performed by combining visual appearance features, and high-confidence bounding boxes predicted frame by frame are associated across frames; the visual appearance features are the ReID feature vectors obtained by encoding the image regions corresponding to the target bounding boxes through appearance feature extraction networks; by comparing the ReID feature vectors of the current detection boxes with historical trajectory features, the appearance matching cost of the target identity is obtained.

5. The underwater sonar target tracking method based on semantic verification according to claim 4, characterized in that, Associating high-confidence bounding boxes predicted frame by frame across frames includes: Using Kalman filtering, the position and scale of each existing trajectory in the current frame are predicted based on the historical state of the existing trajectories, thus obtaining the trajectory prediction box; Calculate the spatial matching cost between the high-confidence bounding box of the current frame and the trajectory prediction box, and calculate the appearance matching cost between the high-confidence bounding box of the current frame and the existing trajectory; wherein, the spatial matching cost is used to characterize the positional and scale differences between the current detection box and the trajectory prediction box; the appearance matching cost is used to characterize the ReID feature differences between the current detection box and the existing trajectory, and is determined by the distance between the ReID feature vector of the current detection box and the historical ReID feature vector of the existing trajectory; The fusion association cost is obtained based on the spatial matching cost and the appearance matching cost; wherein, the fusion association cost is used to characterize the comprehensive matching cost between the current detection box and the existing trajectory; Based on the fusion association cost, the matching between the high-confidence bounding box of the current frame and the existing trajectory is completed.

6. The underwater sonar target tracking method based on semantic verification according to claim 1, characterized in that, Associating high-confidence bounding boxes predicted frame by frame across frames also includes: Successfully matched high-confidence bounding boxes inherit the trajectory identifier of the corresponding existing trajectory and are used to update the Kalman state and appearance features of the corresponding existing trajectory; unmatched high-confidence bounding boxes are used to establish new trajectories; unmatched existing trajectories enter a temporarily lost state and trigger the subsequent SiamRPN++ local recovery process.

7. The underwater sonar target tracking method based on semantic verification according to claim 1, characterized in that, The SiamRPN++ twin tracker is used to perform a local search in the current frame to generate candidate bounding boxes, including: When detection is interrupted, the high-confidence template of the corresponding target is cropped from the high-confidence bounding box detected in the last frame before the trajectory was interrupted, and the local search area is initialized in the current frame; Using a convolutional neural network with shared parameters, the template features of the high-confidence template and the search region features of the local search region in the current frame are extracted respectively. After adjusting the template features and the search region features to a preset number of channels through 1×1 convolution, depth cross-correlation is performed channel by channel to generate a similarity feature map; The similarity feature maps are input into the classification branch and the bounding box regression branch respectively to obtain the confidence of the predicted candidate targets, as well as the bounding box position and scale offset of each layer. The multi-level prediction results are weighted and fused, and the result with the highest score is determined as the candidate bounding box to maintain the continuity of the tracking trajectory.

8. The underwater sonar target tracking method based on semantic verification according to claim 1, characterized in that, Zero-shot semantic verification of candidate targets in the candidate bounding boxes is performed using the BLIP-2 vision-language model, including: Guided by preset text prompts, visual and textual features of candidate regions are extracted and projected into a shared latent space. The semantic similarity score is obtained by calculating the cosine similarity between visual features and text features. S sem It is used to evaluate the consistency between candidate regions and valid target semantic concepts.

9. The underwater sonar target tracking method based on semantic verification according to claim 1, characterized in that, The semantic similarity scores of the candidate targets and the SiamRPN++ tracking confidence scores are fused, and the fused confidence score is determined, including: Maintain a sliding window of historical motion confidence scores, calculate the mean and standard deviation of SiamRPN++ tracking confidence within the window, and use the standard scores to quantify the burst tracking bias of the current frame. When the sudden tracking deviation exceeds a preset deviation threshold, the fusion weight of the SiamRPN++ tracking confidence is reduced to a preset minimum value. When the sudden tracking deviation is less than or equal to the preset deviation threshold, the fusion weight of the SiamRPN++ tracking confidence is adaptively and linearly adjusted according to the current SiamRPN++ tracking confidence. The fused confidence score is calculated by a convex combination of the fused weights and semantic weights of the SiamRPN++ tracking confidence score.