An unmanned aerial vehicle ocean small vessel target detection method based on a fusion framework
By using a global-local fusion framework and a feature fusion enhancement module, the problem of low detection efficiency of small targets in UAV aerial images is solved, enabling efficient identification of small ocean vessels and improving detection accuracy and speed.
Patent Information
- Application Number
- CN202411033671.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-30
- Publication Date
- 2025-11-18
- Estimated Expiration
- 2044-07-30
AI Technical Summary
Small target detection in drone aerial images is inefficient. Existing methods require multiple inferences and have unstable hyperparameter settings, making it difficult to effectively identify small ocean vessels.
We adopt a fusion framework-based approach, combining global and local detectors, and introducing foreground region assembly technology and feature fusion enhancement module to reduce the number of inferences and enhance the feature representation of small targets. We use loss functions such as SimOTA positive and negative sample matching, GIOU loss and Focal Loss to optimize the model.
It improves the recognition rate and detection efficiency of small ocean vessels, with stronger model recognition capabilities and wider adaptability, enabling it to efficiently handle small target detection tasks.
Smart Images

Figure CN118658086B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of deep learning algorithms and target detection technology, specifically to a method for detecting small marine vessels by unmanned aerial vehicles based on a fusion framework. Background Technology
[0002] The rapid development of deep learning has greatly accelerated the advancement of computer vision. Based on the object detection process, object detection methods can be divided into single-stage and two-stage object detection models. Compared to single-stage models, two-stage object detection models add a process of candidate region extraction and candidate bounding box generation. The second stage mainly refines the candidate bounding boxes generated in the first stage and classifies the objects. Single-stage object detection algorithms eliminate the time-consuming and complex process of candidate region extraction, resulting in faster inference speeds compared to multi-stage object detectors. However, this often comes at the cost of relatively lower accuracy.
[0003] Compared to general scenarios, target detection from a drone's perspective reveals a high proportion of small targets. The drone's flight altitude creates a significant distance from the target, while the flexible gimbal provides a wide and varied field of view. These factors combine to result in a high proportion of small targets in drone aerial images, with the overall target size being relatively small. Based on the definition criteria of the MS COCO dataset, targets smaller than 32×32 pixels are classified as small targets, and those larger than 96×96 pixels are classified as large targets. It can be observed that small targets constitute the vast majority of the drone-based dataset, while the proportion of large targets is negligible compared to general scenarios, accounting for only 5.53% in VisDrone and a mere 1.39% in the UAVDT dataset. This is particularly evident in marine target detection, where small vessels make up an even larger proportion.
[0004] Currently, most solutions to the above problems require multiple inferences during local region detection, resulting in significant time overhead. Furthermore, many methods necessitate the introduction of additional network structures for generating local region blocks. On the other hand, they largely rely on the setting of a series of hyperparameters, and the selection of these parameters significantly impacts the extraction results, making the overall detection performance prone to instability. Summary of the Invention
[0005] To address the issue of multiple inferences required for local target detection, this invention introduces a foreground region assembly technique. This technique stitches together extracted local target region blocks into a single image, allowing the local target detector to perform only one inference, significantly reducing time consumption. Simultaneously, to enhance the feature representation of small targets, an extended detection layer is introduced into the target detection model, within which a Feature Fusion Enhancement (FFA) module is designed to obtain higher-resolution feature maps with richer key information, achieving better small target detection.
[0006] To achieve the above objectives, the present invention provides the following technical solution:
[0007] A method for detecting small marine vessels by unmanned aerial vehicles (UAVs) based on a fusion framework, the method comprising the following steps:
[0008] S1) Process the global dataset of images of small marine vessels captured by UAVs to obtain the required raw UAV images. and their corresponding category labels The global dataset is divided into training, validation, and test sets according to a set ratio, which are used for subsequent model training, validation, and evaluation, respectively. The training set is denoted as... B is the number of images in the training set;
[0009] S2) Perform online data augmentation on the images in the training set, so that each image in the training set generates... The training set contains 10 different augmented images, and the number of images after augmentation is 1. , recorded as ;
[0010] S3) Construct a UAV target detection model for small marine vessels based on a "global-local" fusion framework;
[0011] S4) Transfer the training set The image is input into the global detector. SimOTA positive and negative sample matching is used during the training of the global detector. The regression loss of the global detector adopts GIOU loss, and the classification loss is calculated using the FocalLoss loss function. The global detector is updated through the backpropagation algorithm, and the optimal global detector is selected using the validation set in step S1).
[0012] S5) The output of the global detector is processed by NMS to generate a set of global prediction results, and a series of corresponding detection boxes are separated. At the same time, considering the deviation of the prediction results of the global detector and to avoid severe overlap of the final foreground regions, the foreground region blocks are extracted based on the prediction of the global detector.
[0013] S6) A series of foreground region blocks are obtained through the foreground region extraction method in S5). In order to save inference time, the foreground region blocks are assembled into an image using a foreground region assembly module. The image is then input into the local detector to detect the local foreground region blocks.
[0014] S7) Combine the validation set and test set from step S1) with the data-augmented training set from step S2) using the foreground region assembly module in step S6) to generate the training set, validation set, and test set required by the local detector, and name them the local training set. Local validation set and local test set; utilizing local training set Train the local detector; select the optimal local detector using the local validation set;
[0015] S8) The optimal global detector and local detector selected in steps S4) and S7) are tested on the global test set and local test set respectively. The global prediction result R1 and local prediction result R2 are processed by NMS to obtain the target detection result of small ocean vessels in the "global-local" fusion framework.
[0016] As a further technical solution of the present invention, in step S2), the input image is cropped to 640*640 pixels and then randomly horizontally flipped. Then, an image enhancement strategy is used to enhance the image, ultimately obtaining the expanded training set, denoted as... .
[0017] As a further technical solution of the present invention, the image enhancement strategy in step S2) includes one or more combinations of the following operations: normalizing the image, performing random color distortion and Gaussian blur in sequence, automatic enhancement, random enhancement, randomly selecting an image enhancement operation each time, then randomly determining its enhancement magnitude and enhancing the image, and randomly erasing a rectangular area from the image without changing the original label of the image.
[0018] As a further technical solution of the present invention, the target detection model consists of a global detector. Local detectors Foreground region extraction Assembly with foreground area composition:
[0019] The object detection model consists of a global detector. The YOLOX-M model, pre-trained on the COCO dataset, is used as the foundation for global object inspection of marine vessel images. Specifically, a global detector... It consists of a backbone feature network (CSPDarknet) for feature extraction, an extended layer for small object detection (FFA), a feature fusion module (PAFPN), and a decoupled detection head. Its core function lies in the small object extraction of the extended layer. Part of Generate large-resolution feature maps of shallow layers of the backbone network. As a foundation As a key source of supplementary information, the designed Feature Fusion Enhancement (FFA) module is used.
[0020] As a further technical solution of the present invention, SimOTA in step S4) is a matching strategy method that minimizes the cost of assigning Anchor Points to GTBoxes. The cost includes IoU loss and classification loss, and the formula for the cost is:
[0021] ;
[0022] In the formula, The cost of loss for each sample and each ground truth (GT) The classification loss cost between each sample and each ground truth (GT). The regression loss cost between each sample and each ground truth (GT).
[0023] As a further technical solution of the present invention, in step S4), GIOU loss is an index used to measure the similarity or dissimilarity between two geometric shapes. It is usually used to calculate the distance or difference between two geometric shapes. The advantage of GIOU over IOU is that it more accurately captures the position and size differences between target boxes, and at the same time, it has better performance in cases with low overlap. The GIOU formula is as follows:
[0024] ;
[0025] In the formula, Let the intersection-union ratio of the two rectangles be denoted as . Let U be the minimum bounding rectangle of the two rectangles, and U be the rubber region of the two rectangles; according to The formula shows that when two rectangles A and B completely overlap, IoU = 1 and =0, GIoU=1; when the two boxes do not overlap, IoU=0; when A and B are infinitely far apart, GIoU=-1, so -1<=GIoU<=1, therefore set .
[0026] As a further technical solution of the present invention, in step S4), the classification cross-entropy loss is a commonly used loss function, which uses the cross-entropy between the probability distribution of the model output and the actual label as the loss to train the classification model. It is usually used in multi-class classification tasks.
[0027] Cross-entropy loss in the case of two-class (binary) classification:
[0028] ;
[0029] Cross-entropy loss in the multi-class case:
[0030] ;
[0031] in, and These represent the probability distributions of the true labels and the model output, respectively. and Let represent the probabilities of the true label and the i-th class output by the model, respectively.
[0032] Focal Loss is a loss function used to address class imbalance, and it is particularly effective when dealing with extremely imbalanced datasets. Its advantage lies in its ability to focus training on difficult samples. By reducing the weights of easily classified samples, the model pays more attention to those difficult-to-classify samples, thus improving the model's performance in imbalanced situations. The introduction of this loss function helps improve the model's ability to identify minority classes, resulting in superior performance when handling imbalanced data. Let the model output probability be... The real label is Given C categories, the formula for calculating Focal Loss is as follows:
[0033] ;
[0034] in, It is the value of the i-th category of the real label. It is the probability of the i-th class predicted by the model. It is an adjustable parameter, usually a positive number, used to adjust the balance between easily classified and difficult samples. Increasing it... This allows the model to focus more on samples that are difficult to classify, where C is the number of classes; Focal Loss mainly achieves this by introducing... This reduces the weight of easily classified samples, making the model focus more on samples that are difficult to classify.
[0035] As a further technical solution of the present invention, in step S5), the method for extracting the foreground region block is as follows:
[0036] First, the detection boxes that have never been clustered. Select the detection box A with the smallest area, and then iterate through the other detection boxes B in turn. Find a region block C that can simultaneously cover both detection boxes A and B; if the sum of the areas of detection boxes A and B is greater than the area of region block C, then merge detection boxes A and B, replacing detection box A with region block C, and simultaneously... Remove detection box B from the list, and after all iterations are complete, add detection box A to the final foreground region block result. Repeat the above steps until all initial detection boxes are processed. Clustering is completed; this method can extract high-quality foreground region blocks more efficiently.
[0037] As a further technical solution of the present invention, in step S6), the assembly method includes: scale adjustment and assembling region blocks using a rectangular block assembly method;
[0038] The scale adjustment includes the following steps:
[0039] First, calculate each foreground region block. Average size of the included targets :
[0040] ;
[0041] Based on the scale classification criteria of the MS COCO dataset, the main scale categories of the targets contained in the foreground region blocks are determined, and then different scales are applied. The size can be adjusted as follows:
[0042] .
[0043] Compared with the prior art, the beneficial effects of the present invention are:
[0044] 1. High Recognition Rate: This invention targets marine vessel target detection. Since vessels in drone images are small targets, this invention's detection extension layer adds an extra feature layer compared to other feature extraction methods. This feature layer is larger and closer to the underlying information, making it easier to capture small target information. SimOTA positive and negative sample matching is used to help the model learn sufficiently good feature information. The addition of the small target extension layer effectively suppresses background noise.
[0045] 2. High scalability: The present invention is based on YOLOX-M and relies on the YOLO target detection ecosystem. Its principle is highly universal. According to actual needs, by selecting appropriate training data, it can be applied to different types of small target detection tasks.
[0046] 3. Reasonable data structure: This invention designs a discriminative label smoothing term and a discriminative supervised contrastive loss to learn a more compact and reasonable data structure; thereby, a model for UAV and marine vessel target detection based on a "global-local" fusion framework with stronger saliency feature capture capability is trained. Attached Figure Description
[0047] Figure 1 This is a flowchart of a method for detecting small marine vessels using an unmanned aerial vehicle (UAV) based on a fusion framework, as described in an embodiment of the present invention.
[0048] Figure 2 This is a demonstration diagram of the random enhancement module in an embodiment of the present invention.
[0049] Figure 3This is a schematic diagram of UAV target detection for small ocean vessels based on a fusion framework in an embodiment of the present invention. Detailed Implementation
[0050] To make the technical problems to be solved, the technical solutions, and the beneficial effects of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present invention and are not intended to limit the present invention.
[0051] This embodiment uses the detection of small targets on ocean vessels as a scenario to provide a detailed description of the small target enhancement detection model based on the "global-local" fusion framework provided by the present invention.
[0052] Please see Figure 1 As an embodiment of the present invention, a method for detecting small marine vessels by unmanned aerial vehicles based on a fusion framework is provided, the method comprising the following steps:
[0053] S1) Process the global dataset of images of small marine vessels captured by UAVs to obtain the required raw UAV images. and their corresponding category labels The global dataset is divided into training, validation, and test sets according to a set ratio, which are used for subsequent model training, validation, and evaluation, respectively. The training set is denoted as... B is the number of images in the training set;
[0054] The captured images contain ship targets. The category label refers to the annotation label of the ship targets. In this embodiment, the training set, validation set and test set are divided in a ratio of 8:1:1.
[0055] S2) Perform online data augmentation on the images in the training set, so that each image in the training set generates M different augmented images, and the number of images in the training set after augmentation is... , recorded as ;
[0056] In this embodiment, step S2) involves cropping the input image to 640*640 pixels, randomly flipping it horizontally, and then using an image enhancement strategy to enhance the image, ultimately obtaining the expanded training set, denoted as... In this embodiment, M is 4, such as Figure 2 As shown.
[0057] The image enhancement strategy includes one or more combinations of the following operations: normalizing the image, performing random color distortion and Gaussian blur in sequence, automatic enhancement, random enhancement, randomly selecting an image enhancement operation each time, then randomly determining its enhancement magnitude and enhancing the image, and randomly erasing a rectangular area from the image without changing the image's original label.
[0058] S3) Construct a UAV / small marine vessel target detection model based on a "global-local" fusion framework. The model structure is as follows: Figure 3 As shown.
[0059] In this embodiment, the target detection model consists of a global detector. Local detectors Foreground region extraction Assembly with foreground area composition:
[0060] The object detection model consists of a global detector. The YOLOX-M model, pre-trained on the COCO dataset, is used as the foundation for global object inspection of marine vessel images. Specifically, a global detector... It consists of a backbone feature network for extracting CSPDarknet, an FFA small target detection extension layer, a feature fusion module PAPPN, and a decoupled detection head.
[0061] S4) Transfer the training set The image is input into the global detector. SimOTA positive and negative sample matching is used during the training of the global detector. The regression loss of the global detector adopts GIOU loss, and the classification loss is calculated using the FocalLoss loss function. The global detector is updated through the backpropagation algorithm, and the optimal global detector is selected using the validation set in step S1).
[0062] In this embodiment, the ocean vessel image is processed to obtain a feature map. Size is .in, The feature fusion network PAFPN extracts relatively deep three-layer features from the backbone network CSPDarknet, and obtains them through two fusion paths, one from top to bottom and one from bottom to top, with the number of channels being 8c, 4c, and 2c, respectively. Then, the shallower, higher-resolution feature maps of the backbone network are used. As a foundation As a key source of supplementary information, the designed Feature Fusion Enhancement (FFA) module is used to obtain the feature map. , It has the same large size, but contains richer semantic and local detail information. Because... Feature maps are shallow features extracted by the backbone network, and their features are relatively coarse. Therefore, they are processed through a CSP module for feature refinement and channel expansion to generate... Its number of channels is . The generation process can be mathematically expressed as:
[0063] ;
[0064] in, This is represented as a 2x upsampling, using the nearest neighbor difference. From the upper two floors , After fusion, it is obtained, and Having the same size, achieving the same as through upsampling operation Ensure consistent size. (Regarding the feature maps) The data is fed into a hierarchical decoupling head to obtain regression and classification predictions. Valid anchor points and positive samples are determined through positive-negative sample matching, and then classification and regression losses are calculated.
[0065] SimOTA in step S4) is a matching strategy that minimizes the cost of assigning Anchor Points to GTBoxes. This cost includes IoU loss and classification loss, and the formula for the cost is:
[0066] ;
[0067] In the formula, The cost of loss for each sample and each ground truth (GT) The classification loss cost between each sample and each ground truth (GT). The regression loss cost between each sample and each ground truth (GT).
[0068] Classification cross-entropy loss is a commonly used loss function that uses the cross-entropy between the probability distribution of the model output and the actual labels as the loss to train classification models. It is typically used in multi-class classification tasks.
[0069] Cross-entropy loss in the case of two-class (binary) classification:
[0070] ;
[0071] Cross-entropy loss in the multi-class case:
[0072] ;
[0073] in, and These represent the probability distributions of the true labels and the model output, respectively. and Let represent the probabilities of the true label and the i-th class output by the model, respectively.
[0074] In this embodiment, Focal Loss is used for classification loss, a loss function designed to address class imbalance. It is particularly effective when dealing with extremely imbalanced datasets. Let the probability output by the model be... The real label is Given C categories, the formula for calculating Focal Loss is as follows:
[0075] ;
[0076] in: It is the value of the i-th category of the real label. It is the probability of the i-th category predicted by the model. This is an adjustable parameter, usually a positive number, used to balance the number of easily classified samples and difficult samples. Increasing this value... This allows the model to focus more on samples that are difficult to classify, where C is the number of classes. Focal Loss primarily achieves this by introducing... This reduces the weight of easily classified samples, making the model focus more on samples that are difficult to classify.
[0077] The regression loss uses GIOU loss, a metric used to measure the similarity or dissimilarity between two geometries, typically used to calculate the distance or difference between them. GIOU's advantage over IOU lies in its more accurate capture of positional and size differences between bounding boxes, while also offering better performance for cases with low overlap.
[0078] The formula is as follows:
[0079] ;
[0080] In the formula, Let the intersection-union ratio of the two rectangles be denoted as . Let U be the minimum bounding rectangle of the two rectangles, and U be the rubber region of the two rectangles. According to... The formula shows that when two rectangles A and B completely overlap, IoU = 1 and =0, GIoU=1. When the two boxes do not overlap, IoU=0; when A and B are infinitely far apart, GIoU = -1, so -1 <= GIoU <= 1. Therefore, set... .
[0081] The loss is calculated using a loss function, and then the optimizer and direction propagation are updated, continuously optimizing the model during training. The optimal global marine vessel detection model is selected using the validation set from step S1).
[0082] S5) The output of the global detector is processed by NMS to generate a set of global prediction results, and a series of corresponding detection boxes are separated. At the same time, considering the deviation of the prediction results of the global detector and to avoid severe overlap of the final foreground regions, the foreground region blocks are extracted based on the prediction of the global detector.
[0083] In this embodiment, the method for extracting foreground region blocks is as follows: first, the detection boxes that have not yet undergone clustering... Select the detection box A with the smallest area, and then iterate through the other detection boxes B in turn. Find a region block C that can simultaneously cover both detection boxes A and B; if the sum of the areas of detection boxes A and B is greater than the area of region block C, then merge detection boxes A and B, replacing detection box A with region block C, and simultaneously... Remove detection box B from the list, and after all iterations are complete, add detection box A to the final foreground region block result. Repeat the above steps until all initial detection boxes are processed. Clustering is completed; this method can extract high-quality foreground region blocks more efficiently.
[0084] S6) A series of foreground region blocks are obtained through the foreground region extraction method in S5). In order to save inference time, the foreground region blocks are assembled into an image using a foreground region assembly module. The image is then input into the local detector to detect the local foreground region blocks.
[0085] In this embodiment, the assembly process mainly includes two steps: scale adjustment, where region blocks containing targets of different sizes are relatively scaled according to certain rules to balance the scale of each region block, so that small and medium-sized target region blocks that are difficult to detect have a relatively larger pixel ratio. Using the rectangular block assembly method for region block assembly can efficiently and reasonably arrange image blocks, reduce the generation of empty areas, and ensure that the effective proportion of foreground region blocks in the assembled image is large enough.
[0086] The scale adjustment includes the following steps:
[0087] First, calculate each foreground region block. Average size of the included targets :
[0088] ;
[0089] Based on the scale classification criteria of the MS COCO dataset, the main scale categories of the targets contained in the foreground region blocks are determined, and then different scales are applied. The size can be adjusted as follows:
[0090] .
[0091] S7) Combine the validation set and test set from step S1) with the data-augmented training set from step S2) using the foreground region assembly module in step S6) to generate the training set, validation set, and test set required by the local detector, and name them the local training set. Local validation set and local test set; utilizing local training set Train the local detector; select the optimal local detector using the local validation set;
[0092] S8) The optimal global detector and local detector selected in steps S4) and S7) are tested on the global test set and local test set respectively. The global prediction result R1 and local prediction result R2 are processed by NMS to obtain the target detection result of small ocean vessels in the "global-local" fusion framework.
[0093] This invention reconstructs two core modules—regional foreground extraction and region foreground assembly—based on the "global-local" fundamental model. This invention overcomes the need for multiple inferences when detecting local regions by introducing foreground region assembly technology, which stitches together the extracted local target region blocks into a single image. This allows the local target detector to perform only one inference, greatly reducing time consumption and enabling the model to have higher recognition accuracy and faster inference speed.
[0094] This invention introduces an extended detection layer on top of the "global-local" basic model to enhance the detection of small marine targets, such as vessels. The main purpose of the extended detection layer is to generate a high-resolution feature map full of key semantic and detailed information through a designed feature fusion enhancement module (FFA) without changing the image input resolution. This enhances the feature representation of small targets at this layer, and the receptive field of this layer is relatively smaller, which is beneficial for the recognition of small targets.
[0095] The contents not described in detail in this specification are existing technologies known to those skilled in the art.
[0096] It should be understood that those skilled in the art can make improvements or modifications based on the principles of this invention and the above description, or apply the method provided by this invention to similar aerial image recognition tasks, and all such improvements and modifications should fall within the protection scope of the appended claims.
Claims
1. A method for detecting small marine vessels using unmanned aerial vehicles (UAVs) based on a fusion framework, characterized in that, The method includes the following steps: S1) Process the global dataset of images of small marine vessels captured by UAVs to obtain the required raw UAV images. and their corresponding category labels The global dataset is divided into training, validation, and test sets according to a set ratio, which are used for subsequent model training, validation, and evaluation, respectively. The training set is denoted as... , The number of images in the training set; S2) Perform online data augmentation on the images in the training set, so that each image in the training set generates... The training set contains 10 different augmented images, and the number of images after augmentation is 1. , recorded as ; S3) Construct a UAV target detection model for small marine vessels based on a "global-local" fusion framework; S4) Transfer the training set The image is input into the global detector, and SimOTA positive and negative sample matching is used during the training of the global detector. The regression loss of the global detector adopts GIOU loss, and the classification loss is calculated using the Focal Loss function. The global detector is updated through the backpropagation algorithm, and the optimal global detector is selected using the validation set in step S1). S5) The output of the global detector is processed by NMS to generate a set of global prediction results, and a series of corresponding detection boxes are separated. Foreground region blocks are extracted based on the prediction of the global detector. S6) A series of foreground region blocks are obtained through the foreground region extraction method in step S5). The foreground region blocks are assembled into an image using the foreground region assembly module. The image is then input into the local detector to detect the local foreground region blocks. S7) Combine the validation set and test set from step S1) with the data-augmented training set from step S2) using the foreground region assembly module in step S6) to generate the training set, validation set, and test set required by the local detector, and name them the local training set. Local validation set and local test set; utilizing local training set Train the local detector; select the optimal local detector using the local validation set; S8) The optimal global detector and local detector selected in steps S4) and S7) are tested on the global test set and local test set respectively. The global prediction result R1 and local prediction result R2 are processed by NMS to obtain the target detection result of small ocean vessels in the "global-local" fusion framework. The target detection model consists of a global detector. Local detectors Foreground region extraction Assembly with foreground area composition: The object detection model consists of a global detector. The YOLOX-M model, pre-trained on the COCO dataset, is used as the foundation for the global detector. It consists of a backbone feature network for extracting CSPDarknet, an FFA small target detection extension layer, a feature fusion module PAPPN, and a decoupled detection head.
2. The method for detecting small marine vessels by unmanned aerial vehicles based on a fusion framework according to claim 1, characterized in that, Step S2) The input image is cropped to 640*640 pixels and then randomly horizontally flipped. Image enhancement strategies are then applied to enhance the image, resulting in an expanded training set, denoted as [example set]. .
3. The method for detecting small marine vessels by unmanned aerial vehicles based on a fusion framework according to claim 2, characterized in that, The image enhancement strategy in step S2) includes one or more combinations of the following operations: normalizing the image, performing random color distortion and Gaussian blur in sequence, automatic enhancement, random enhancement, randomly selecting an image enhancement operation each time, then randomly determining its enhancement magnitude and enhancing the image, and randomly erasing a rectangular area from the image without changing the original label of the image.
4. The method for detecting small marine vessels by unmanned aerial vehicles based on a fusion framework according to claim 1, characterized in that, SimOTA in step S4) is a matching strategy that minimizes the cost of assigning Anchor Points to GTBoxes. This cost includes IoU loss and classification loss, and the formula for cost is: ; In the formula, The cost of loss for each sample and each ground truth (GT) The classification loss cost between each sample and each ground truth (GT). The regression loss cost between each sample and each ground truth (GT).
5. The method for detecting small marine vessels by unmanned aerial vehicles based on a fusion framework according to claim 1, characterized in that, In step S4), GIOU loss is a metric used to measure the similarity or dissimilarity between two geometric shapes. It is used to calculate the distance or difference between the two geometric shapes. The GIOU formula is as follows: ; In the formula, Let the intersection-union ratio of the two rectangles be denoted as . Let U be the minimum bounding rectangle of the two rectangles, and U be the rubber region of the two rectangles; according to The formula shows that when two rectangles A and B completely overlap, IoU = 1 and =0, GIoU=1; when the two boxes do not overlap, IoU=0; when A and B are infinitely far apart, GIoU=-1, so -1<=GIoU<=1, therefore set .
6. The method for detecting small marine vessels by unmanned aerial vehicles based on a fusion framework according to claim 1, characterized in that, In step S4), the classification cross-entropy loss is a commonly used loss function. It uses the cross-entropy between the probability distribution of the model output and the actual label as the loss to train the classification model. It is usually used in multi-class classification tasks. Cross-entropy loss in the biclass case: ; Cross-entropy loss in the multi-class case: ; in, and These represent the probability distributions of the true labels and the model output, respectively. and Let represent the probabilities of the true label and the i-th class output by the model, respectively. Focal Loss is a loss function used to solve the class imbalance problem. Let the probability output by the model be... The real label is Given C categories, the formula for calculating Focal Loss is as follows: ; in, It is the value of the i-th category of the real label. It is the probability of the i-th class predicted by the model. It is an adjustable parameter, and C is the number of categories.
7. The method for detecting small marine vessels by unmanned aerial vehicles based on a fusion framework according to claim 1, characterized in that, In step S5), the method for extracting the foreground region block is as follows: First, the detection boxes that have never been clustered. Select the detection box A with the smallest area, and then iterate through the other detection boxes B in turn. Find the region block C that can simultaneously cover both detection box A and detection box B; If the sum of the areas of detection boxes A and B is greater than the area of region C, then detection boxes A and B are merged, and detection box A is replaced by region C. Remove detection box B from the list, and after all iterations are complete, add detection box A to the final foreground region block result. Repeat the process until all initial detection boxes are detected. Complete clustering.
8. A method for detecting small marine vessels using an unmanned aerial vehicle (UAV) based on a fusion framework according to claim 1, characterized in that, In step S6), the assembly method includes: scale adjustment and assembling region blocks using a rectangular block assembly method; The scale adjustment includes the following steps: First, calculate each foreground region block. Average size of the included targets : ; in, This represents the size-related parameters corresponding to the j-th target within the i-th foreground region block; This indicates the numerical value of the dimension to be retrieved, and is guaranteed to be non-negative. Based on the scale classification criteria of the MS COCO dataset, the main scale categories of the targets contained in the foreground region blocks are determined, and then different scales are applied. The size can be adjusted as follows: 。
Citation Information
Patent Citations
Occluded pedestrian re-identification and retrieval method based on multi-feature collaboration and semantic perception
CN114842512A
Image salient object segmentation method and apparatus based on reciprocal attention between foreground and background
US20200372660A1