Infrared small target false label generation method and system, storage medium and equipment
By extracting the target centroid and rough label in the infrared image, using Gaussian blur kernel processing and centroid offset calibration network, combined with the pseudo-label image fine generation network, the problem of pseudo-label generation efficiency and accuracy in infrared weak and small target detection is solved. Efficient and accurate pseudo-label image generation is achieved, improving the performance of infrared image analysis tasks.
Patent Information
- Application Number
- CN202410789942.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-19
- Publication Date
- 2024-10-01
- Estimated Expiration
- 2044-06-19
AI Technical Summary
In the task of infrared weak and small target detection, the traditional manual pixel-by-pixel annotation method is inefficient and difficult to guarantee accuracy, resulting in a large consumption of manpower, financial resources and time. How to automatically generate high-precision and efficient pseudo-label images has become an urgent problem to be solved.
A method for generating pseudo-labels for small infrared targets is proposed. By collecting infrared images and artificial label images, the target centroid and rough labels are extracted, using Gaussian fuzzy kernel processing and centroid offset calibration network, combined with the pseudo-label image fine generation network. Gradually refine the pseudo-label image generation process to improve the accuracy and refinement of pseudo-labels.
The accuracy and precision of pseudo-label images are improved, thereby improving the performance of infrared image analysis tasks, reducing the complexity of annotation and the need for manual annotation, and achieving high-efficiency pseudo-label generation.
Smart Images

Figure CN118736290A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of infrared image processing technology, and in particular to a method, system, storage medium and device for generating a pseudo label of an infrared small target. Background Art
[0002] In the task of infrared dim small target detection, accurate annotation information is crucial to improving the performance of deep learning models. Due to the characteristics of dim small targets in infrared images, such as low signal-to-clutter ratio, small pixel ratio and blurred edges, the traditional manual pixel-by-pixel annotation method is not only inefficient, but also difficult to ensure the annotation accuracy, and also causes a lot of manpower, financial resources and time consumption; therefore, how to automatically generate high-precision and high-efficiency infrared dim small target pseudo-label images has become a problem to be solved urgently in this field.
[0003] To address the above problems, the single-point mark-induced label image generation technology provides an effective solution. This technology only requires the user to click once inside each target area in the infrared image, and then the pseudo-label image generation algorithm automatically completes the labeling of the target shape. This labeling strategy significantly reduces the complexity of labeling and improves the labeling efficiency.
[0004] At present, there are still many challenges in the single-point marker induced label image generation technology in the infrared dim target detection task; therefore, developing a pseudo-label image generation method that is both efficient and accurate is of great significance to improving the performance of infrared dim target detection. Summary of the invention
[0005] Based on this, it is necessary to propose a method for generating pseudo labels for small infrared targets to address the above problems.
[0006] A method for generating a pseudo label for an infrared small target, the method comprising the following steps:
[0007] Collect infrared images I i and the infrared image I i The corresponding artificial label image L G ;
[0008] From the artificial label image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ;
[0009] According to the infrared image I iand the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence; Preset the centroid offset calibration network f BC weights and use the centroid shift to calibrate the network f BC Determine the central area prediction results
[0010] Get the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid
[0011] According to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence;
[0012] The pseudo-label image is finely generated into a network G SCTrans Determine the infrared image I i The corresponding final pseudo-label image F.
[0013] In the above scheme, the artificial label image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG , including:
[0014] Use the connected component algorithm CoC(·) to obtain the target centroid label image L C Get the connected domain graph M C , and from the connected domain graph M C Sample the coarse label image L B ;
[0015] For the connected domain graph M C For each target in the image, extract its centroid coordinates to obtain the centroid label image L C ;
[0016] According to the Gauss kernel function Gauss d=3 (·) respectively for the centroid label image L C and the coarse label image L B Each marked position in the fuzzy processing: L CG =Gauss d=3(L C )、L BG =Gauss d=3 (L B ), and obtain the fuzzy centroid label image L CG and the fuzzy coarse label image L BG .
[0017] In the above scheme, the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence, including:
[0018] Use the maximum pooling Maxpool2(·) to blur the rough label image L BG Perform downsampling to obtain a multi-scale fuzzy label image and
[0019]
[0020]
[0021] The infrared image I i and the fuzzy coarse label image L BG With the calibration network f BC The zeroth level and first level encoding features are concatenated along the channel dimension to form the multi-scale fuzzy label image and Respectively with the calibration network f BC The second, third and fourth level encoding features are concatenated along the channel dimension;
[0022] Use binary cross entropy BCE(·) to determine the central prediction result With the fuzzy centroid label image L CG The first loss function
[0023] The initial learning rate is preset to 0.005, and the centroid offset calibration network f BC Train until the first loss function The value is within the convergence range.
[0024] In the above scheme, the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence, including:
[0025] Determine the center area of the fuzzy prediction results
[0026] The infrared image I i and fuzzy centroid As input, we train G using the BCE(·) loss function. SCTrans :
[0027] The initial learning rate is preset to 0.001, and the pseudo-label image is finely generated into the network G SCTrans Train until the second loss function The value is within the convergence range.
[0028] In the above scheme, the network G is finely generated according to the pseudo-label image SCTrans Determine the infrared image I i The corresponding final pseudo-label image F specifically includes:
[0029] Preset centroid offset calibration network f BC and pseudo-label image fine generation network G SCTrans The weight of the infrared image I i and any coarse label image L B Generate pseudo-label images and obtain candidate label images F d ;
[0030] Take the candidate label image F d As a mask, the coarse label image L B The final pseudo-label image F of the infrared small target is obtained by using the eight-neighborhood clustering algorithm.
[0031] In the above scheme, the candidate label image F d As a mask, the coarse label image L B As the cluster center, the final pseudo-label image F of the infrared small target is obtained by using the eight-neighborhood clustering algorithm, which includes:
[0032] F=Cluster mode=8 (F d ,L B )
[0033] Among them, Cluster mode=8 (·) represents the eight-neighborhood clustering function induced by the coarse point label image, and F is the final pseudo label image obtained.
[0034] In the above scheme, the network G is finely generated according to the pseudo-label image SCTrans Determine the infrared image I i The corresponding final pseudo-label image F, after which the method further includes:
[0035] The accuracy of the pseudo-label image F is verified by using the intersection-comparison ratio. For the i-th generated label image F i , and the corresponding manually labeled images Get the corresponding intersection over union (IoU):
[0036]
[0037] Among them, A and A u Represent the tested object F i With the true value The intersection and union between pixels, TP[i] represents F i c and The intersection of the predicted positive pixel numbers, T[i] and P[i] represent F i and The number of positive pixels predicted by each;
[0038] When the intersection over union (IoU) of the pseudo-label image F is lower than a fixed threshold, it is determined as an unqualified label image and re-labeled.
[0039] The present application also proposes a system for generating pseudo labels for infrared small targets, the system comprising: a label image acquisition unit, a model training unit, a centroid acquisition unit and a pseudo label image generation unit;
[0040] The label image acquisition unit is used to collect infrared images I i and the infrared image I i The corresponding artificial label image L G ; From the artificial label image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ;
[0041] The model training unit is used to train the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence; according to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence;
[0042] The centroid acquisition unit is used to preset the centroid offset calibration network f BCThe weights of the centroid shift calibration network f BC Determine the central area prediction results Get the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid
[0043] The pseudo-label image generating unit is used to finely generate the network G according to the pseudo-label image SCTrans Acquire the infrared image I i The corresponding final pseudo-label image F.
[0044] The present application also proposes a readable storage medium storing a computer program. When the computer program is executed by a processor, the processor executes the following steps:
[0045] Collect infrared images I i and the infrared image I i The corresponding artificial label image L G ;
[0046] From the artificial label image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ;
[0047] According to the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence; Preset the centroid offset calibration network f BC weights and use the centroid shift to calibrate the network f BC Determine the central area prediction results
[0048] Get the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid
[0049] According to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence;
[0050] The pseudo-label image is finely generated into a network G SCTrans Determine the infrared image I i The corresponding final pseudo-label image F.
[0051] The present application also proposes a computer device, comprising a memory and a processor, wherein the memory stores a computer program, and the processor executes the following steps of the computer program:
[0052] Collect infrared images I i and the infrared image I i The corresponding artificial label image L G ;
[0053] From the artificial label image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ;
[0054] According to the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence; Preset the centroid offset calibration network f BC weights and use the centroid shift to calibrate the network f BC Determine the central area prediction results
[0055] Get the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid
[0056] According to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence;
[0057] The pseudo-label image is finely generated into a network G SCTrans Determine the infrared image I i The corresponding final pseudo-label image F.
[0058] The embodiment of the present invention has the following beneficial effects: collecting an infrared image and an artificial label image corresponding to the infrared image; extracting a target centroid label image and a coarse label image from the artificial label image, and processing the target centroid label image and the coarse label image with a Gaussian blur kernel to obtain a fuzzy centroid label image and a fuzzy coarse label image; training a centroid offset calibration network according to the infrared image and the fuzzy coarse label until convergence; presetting the weights of the centroid offset calibration network, and using the centroid offset calibration network to determine the central area prediction result; obtaining the centroid of the central prediction result, and processing the centroid with a Gaussian blur kernel to obtain a fuzzy centroid; training a pseudo-label image fine generation network according to the infrared image and the fuzzy centroid until convergence; and determining the final pseudo-label image corresponding to the infrared image according to the pseudo-label image fine generation network. The present invention gradually refines the generation process of the pseudo-label image by introducing the centroid offset calibration network and the pseudo-label image fine generation network, and is expected to improve the accuracy and fineness of the pseudo-label image, thereby improving the performance of subsequent infrared image analysis tasks. BRIEF DESCRIPTION OF THE DRAWINGS
[0059] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0060] in:
[0061] Figure 1 A schematic diagram of a process for generating a pseudo-label for an infrared small target in one embodiment;
[0062] Figure 2 for Figure 1 Infrared image I i (Infrared weak target original input image I i );
[0063] Figure 3 is the infrared image I i The corresponding coarse label image L B Schematic diagram of
[0064] Figure 4 is the coarse label image L B The corresponding fuzzy rough label image L BG Schematic diagram of
[0065] Figure 5 Calibrate the network for centroid shift f BC The output center prediction result
[0066] Figure 6 Fine-tune the network G for pseudo-label images SCTrans Output the resulting saliency map;
[0067] Figure 7 is the final generated pseudo label image F. DETAILED DESCRIPTION
[0068] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments; based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0069] In the following description, a large number of specific details are given in order to provide a more thorough understanding of the present invention; however, it is obvious to those skilled in the art that the present invention can be implemented without one or more of these details; in other examples, in order to avoid confusion with the present invention, some technical features known in the art are not described, and it should be understood that the present invention can be implemented in different forms and should not be interpreted as limited to the embodiments presented here; on the contrary, providing these embodiments will make the disclosure thorough and complete and fully convey the scope of the present invention to those skilled in the art.
[0070] The purpose of the terms used herein is only to describe specific embodiments and is not intended to be limiting of the present invention. When used herein, the singular forms "a", "an" and "said / the" are also intended to include the plural forms, unless the context clearly indicates otherwise, and it should also be understood that the terms "consisting of" and / or "comprising", when used in this specification, determine the presence of the features, integers, steps, operations, elements and / or parts, but do not exclude the presence or addition of one or more other features, integers, steps, operations, elements, parts and / or groups. When used herein, the term "and / or" includes any and all combinations of the relevant listed items.
[0071] In the prior art, there are two main methods for single-point label-induced label image generation technology: the first method uses single-point annotation as a weak supervision signal, combines it with the target detection network for joint training, and designs a label image evolution strategy to gradually generate pseudo-label images. However, this joint training framework limits the learning ability and evolution space of the pseudo-label image generation branch, resulting in low quality of the generated pseudo-label images; the second method treats pseudo-label image generation as an independent task, and directly generates pseudo-label images by designing clustering, optimization and other algorithms by utilizing the gradient and energy distribution differences between the target and the background in the image. Although this method does not rely on the target detection network, it is highly dependent on complex parameter adjustments and empirical observations, which makes the algorithm less robust. In addition, when the annotation point is not central, this type of method often finds it difficult to ensure the accuracy of pseudo-label image generation, limiting its effectiveness in practical applications.
[0072] In summary, the existing single-point marked infrared small target pseudo-label generation method has the problems of poor learning ability, low robustness and difficulty in ensuring the label generation accuracy under rough marking. The present application provides an infrared small target pseudo-label generation method, which regards the pseudo-label generation as an independent learnable task, that is, making full use of the labeled infrared small target data set to construct a deep neural network framework that can generate high-precision pseudo-labels even in rough marking. After the method is trained, it can be directly integrated into the training process of the rough single-point marked small target detection algorithm, which is of great significance for improving the infrared small target detection performance.
[0073] To facilitate understanding, the relevant terms involved in this application are first introduced below.
[0074] (1) Connected component map is an important concept in image processing. It mainly refers to the area formed by a set of adjacent pixels with the same attributes or features in an image. These pixels usually have the same pixel value (such as black or white) and are connected to each other through adjacent relationships in the up-down, left-right or diagonal directions in the image. The connected component map can be regarded as a representation of different objects or regions in the image. Each connected component can represent an independent object or region.
[0075] (2) Coarse label images refer to relatively fuzzy or inaccurate label images, which are used to represent some approximate attributes or categories of samples. They are usually labeled by experts or domain knowledge personnel in order to more quickly and efficiently label large-scale data sets.
[0076] (3) Multi-scale fuzzy label image. Related to multi-scale detection, a multi-scale fuzzy label image may refer to a label image in which an image or object is blurred or annotated at different scales. This label image may take into account the characteristic performance of the object at different scales, including the balance between details and overall structure.
[0077] In order to thoroughly understand the present invention, a detailed structure will be presented in the following description to illustrate the technical solution proposed by the present invention; optional embodiments of the present invention are described in detail as follows, but in addition to these detailed descriptions, the present invention may also have other implementation methods.
[0078] like Figure 1 As shown, in one embodiment, a method for generating a pseudo-label for an infrared small target is provided, and the method for generating a pseudo-label for an infrared small target includes steps S101 to S106, which are described in detail as follows:
[0079] S101, collecting infrared images I i and infrared image I i The corresponding artificial label image L G ;
[0080] Collecting infrared images and their corresponding artificially labeled images is the basis for ensuring the quality of pseudo-label images. The quality and quantity of data directly affect the effect of subsequent model training. The accuracy and completeness of artificially labeled images are crucial for subsequent steps. i That is, infrared weak target image (such as Figure 2 As shown in the figure, there are currently a large number of public infrared small target datasets: NUAA-SIRST, NUDT-SIRST, and IRSTD-1K. To ensure the performance of the pseudo-label generation network of this method, the number of paired data is set to at least 500.
[0081] S102, from the artificial label image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ;
[0082] Using Gaussian blur kernel to process these label images can obtain smoother label images that are more consistent with the actual infrared image characteristics. Gaussian blur processing can also reduce the noise and edge effects of the label images, which helps to improve the generalization ability of the subsequent network.
[0083] In some embodiments, from the artificial label image LG Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG , including:
[0084] (1) Use the connected component algorithm CoC(·) to obtain the target centroid label image L C Get the connected domain graph M C , and from the connected domain graph M C Sample the coarse label image L B (like Figure 3 shown);
[0085] Specifically, M. c =CoC(L C ), connected domain graph M C Ability to number and distinguish different targets in the mask label image.
[0086] From M C Sample the coarse label image L B : For an object with horizontal size w and vertical size h, the coarse label image L B The sampling probability of follows a two-dimensional Gaussian distribution L with the target centroid as the center and the minimum value of w and h is the half-width B ~N(L C ,min{h,w}), to prevent the coarse label image L B The marking position exceeds the actual edge of the target, and the sampling result is intersected with the original label LG to set the unreasonable result to zero:
[0087]
[0088] Represents the centroid label L C The target coordinates in are taken as the center, and the pixel sampling is performed with min{h,w} as the half width. For L beyond the edge B , repeat the above steps until the sampling is successful.
[0089] (2) For the connected domain graph M C For each target in the image, extract its centroid coordinates to obtain the centroid label image L C ;
[0090] Specifically, L C =Central(M C), Central(·) represents the extraction of centroid coordinates, and assigns the pixel value of the coordinate position to 1. So far, the target centroid label image L C Extraction complete.
[0091] (3) According to Gauss kernel function d=3 (·) respectively for the centroid label image L C and the coarse label image L B Each marked position in the fuzzy processing: L CG =Gauss d=3 (L C )、L BG =Gauss d=3 (L B ), and obtain the fuzzy centroid label image L CG and the fuzzy coarse label image L BG .
[0092] S103, according to the infrared image I i and the fuzzy coarse label image L BG (like Figure 4 As shown) train the centroid offset calibration network f BC Until convergence; preset centroid offset calibration network f BC The weights of the network are calibrated using the centroid shift BC Determine the central area prediction results (like Figure 5 shown);
[0093] The centroid position of the target in the infrared image is calibrated to improve the accuracy of the pseudo-label image. By presetting the network weights and using the trained centroid offset calibration network, the central area can be predicted and the centroid of the area can be obtained. Since the centroid of the target in the infrared image may deviate from the actual position due to factors such as noise and blur, the introduction of this network helps to improve the accuracy of the centroid prediction. Presetting the network weights and determining the prediction results of the central area can provide a relatively accurate centroid position prediction, which provides a basis for the subsequent fine generation of pseudo-label images.
[0094] In some embodiments, according to the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence, including:
[0095] (1) Use the maximum pooling Maxpool2(·) to blur the coarse label image L BG Perform downsampling to obtain a multi-scale fuzzy label image and
[0096]
[0097] Considering that scaling will alleviate the distance error caused by annotation offset, the standard three-downsampling U-Net is selected as the benchmark network structure. Specifically, we first use the maximum pooling Maxpool2(·) with a step size of 2 to BG Continuously perform multiple downsampling to obtain multi-scale fuzzy labels and
[0098] (2) The infrared image I i and the fuzzy coarse label image L BG With the calibration network f BC The zeroth level, the first level encoding features are spliced along the channel dimension, and the multi-scale fuzzy label image and Respectively with the calibration network f BC The second, third and fourth level encoding features are concatenated along the channel dimension;
[0099] The purpose of this step is to progressively embed the fuzzy information of the target position into f BC The high-level semantic features of .
[0100] (3) Use binary cross entropy BCE(·) to determine the central prediction result With the fuzzy centroid label image L CG The first loss function
[0101] (4) The initial learning rate is set to 0.005, and the centroid offset calibration network f is used. BC Train until the first loss function The value is within the convergence range.
[0102] Specifically, the image input batch is set to 16, the optimizer uses Adam, the initial learning rate is set to 0.005, and the cosine annealing strategy is used to gradually decay the learning rate to 1×10-6. The overall iteration round of the network is 500. After the numerical convergence of the loss function is stable, the training can be stopped in advance to obtain the centroid offset calibration network f BC The weight file is recorded as FBC.pth, where the above training parameters are empirical values and can be further adjusted according to the actual data scale.
[0103] S104. Obtaining the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid
[0104] The centroid of the center prediction result is Gaussian blurred to obtain the blurred centroid. This step helps to further reduce the error of the centroid position and enhance the robustness of the pseudo-label image. The process can be expressed as:
[0105] in, is the centroid offset calibration network f BC Predicted central region results.
[0106] S105, according to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence;
[0107] This step is the key to generating the final pseudo-label image. The network uses infrared images and fuzzy centroids as input and is trained until convergence. Since the input already contains relatively accurate centroid position information, the network can focus on learning the detailed features of the target, thereby generating more refined pseudo-label images. Through this step-by-step refinement method, the final pseudo-label image will be closer to the real label image, which will help improve the accuracy of subsequent infrared image analysis tasks.
[0108] In some embodiments, according to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence, including:
[0109] Determine the center area of the fuzzy prediction results
[0110] The infrared image I i and fuzzy centroid As input, we train it using the BCE(·) loss function.
[0111] The initial learning rate is preset to 0.001, and the pseudo-label image is finely generated by the network G SCTrans Train until the second loss function The value is within the convergence range.
[0112] Preferably, the infrared small target detection network SCTransNet based on the Transformer architecture of the present application is used as the pseudo label generation network, denoted as G SCTrans , the detection network here is not fixed, as long as the weak target detection network with excellent performance can be considered for use, The exact centroid of the target is already provided, so there is no need to Perform separate downsampling and directly splice along the channel dimension and I i As input, we train G using the BCE(·) loss function. SCTrans .
[0113] Specifically, G. SCTrans The training parameters are as follows: the input batch is set to 8, and the Adam optimizer is used to optimize the loss function The initial learning rate of the training is set to 0.001, and cosine annealing is used to gradually decay to 1×10-6. The number of iterations is 1000. The training is completed after the loss converges and stabilizes, and G is obtained. SCTrans Weight file GSCTrans.pth, where the above training parameters are empirical values and can be further adjusted according to the actual data scale.
[0114] S106, finely generate network G based on pseudo-label image SCTrans Determine the infrared image I i The corresponding final pseudo-label image F.
[0115] In some embodiments, the network G is finely generated based on the pseudo-label image SCTrans Determine the infrared image I i The corresponding final pseudo-label image F specifically includes:
[0116] (1) Preset centroid offset calibration network f BC and pseudo-label image fine generation network G SCTrans The weight of the infrared image I i and any coarse label image L B Generate pseudo-label images and obtain candidate label images F d ;
[0117] Due to the uncertainty of the deep neural network, the candidate label F d There will be a certain amount of missed detection and false alarm in the image, so it is necessary to B For the candidate label image F d Make further corrections.
[0118] (2) Take the candidate label image F d (like Figure 6 As shown) is a mask, with a coarse label image L B As the cluster center, the eight-neighborhood clustering algorithm is used to obtain the final pseudo-label image F of the infrared small target (such as Figure 7 shown).
[0119] In some embodiments, the candidate label image F d As a mask, with a coarse label image L BAs the cluster center, the final pseudo-label image F of the infrared small target is obtained by using the eight-neighborhood clustering algorithm, which includes:
[0120] F=Cluster mode=8 (F d ,L B )
[0121] Among them, Gluster mode=8 (·) represents the eight-neighborhood clustering function induced by the coarse point label image, and F is the final pseudo label image obtained.
[0122] In some embodiments, the network G is finely generated based on the pseudo-label image SCTrans Determine the infrared image I i The corresponding final pseudo-label image F, after which the method further includes:
[0123] The accuracy of the pseudo-label image F is verified by using the intersection-comparison ratio. For the i-th generated label image F i , and the corresponding manually labeled images Get the corresponding intersection over union (IoU):
[0124]
[0125] Among them, A and A u Represent the tested object F i With the true value The intersection and union between pixels, TP[i] represents F i c and The intersection of the predicted positive pixel numbers, T[i] and P[i] represent F i and The number of positive pixels predicted by each;
[0126] When the intersection over union (IoU) of the pseudo-label image F is lower than a fixed threshold, it is determined as an unqualified label image and re-labeled.
[0127] Preferably, pseudo labels with an IoU lower than 60% can be regarded as unqualified labels and need to be manually recalibrated. In fact, the average IoU in the 1079 test sets can reach 85%. In this application, only less than 10 labels need to be relabeled, that is, the relabeling rate is less than 1%, which effectively illustrates the superiority of the present application.
[0128] In summary, the present invention is based on deep learning, and with the support of massive data, the model has stronger robustness. At the same time, the designed centroid offset calibration network can effectively convert coarse labels into centroid labels, solving the problem of coarse strategy labeling.
[0129] The present application also proposes a system for generating pseudo-labels for infrared small targets, the system comprising: a label image acquisition unit, a model training unit, a centroid acquisition unit and a pseudo-label image generation unit;
[0130] Label image acquisition unit, used to collect infrared image I i and infrared image I i The corresponding artificial label image L G ; From the manually labeled image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ;
[0131] The model training unit is used to train the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence; according to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence;
[0132] The centroid acquisition unit is used to preset the centroid offset calibration network f BC The weights of the network are calibrated using the centroid shift BC Determine the central area prediction results Get the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid
[0133] The pseudo-label image generation unit is used to finely generate the network G according to the pseudo-label image SCTrans Get infrared image I i The corresponding final pseudo-label image F.
[0134] The present application also proposes a readable storage medium storing a computer program. When the computer program is executed by a processor, the processor executes the following steps:
[0135] Collect infrared images I i and infrared image I i The corresponding artificial label image L G ;
[0136] From the manually labeled image L GExtract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ;
[0137] According to the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence; preset centroid offset calibration network f BC The weights of the network are calibrated using the centroid shift BC Determine the central area prediction results
[0138] Get the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid
[0139] According to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence;
[0140] Finely generate a network G based on pseudo-label images SCTrans Determine the infrared image I i The corresponding final pseudo-label image F.
[0141] The present application also proposes a computer device, including a memory and a processor, wherein the memory stores a computer program, and the computer program is executed by the processor to perform the following steps:
[0142] Collect infrared images I i and infrared image I i The corresponding artificial label image L G ;
[0143] From the manually labeled image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ;
[0144] According to the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence; preset centroid offset calibration network f BC The weights of the network are calibrated using the centroid shift BC Determine the central area prediction results
[0145] Get the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid
[0146] According to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence;
[0147] Finely generate a network G based on pseudo-label images SCTrans Determine the infrared image I i The corresponding final pseudo-label image F.
[0148] Those skilled in the art will understand that all or part of the processes in the above-mentioned embodiments can be completed by instructing the relevant hardware through a computer program, and the program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in the present application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0149] The technical features of the above embodiments can be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0150] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the patent of the present application. It should be pointed out that, for ordinary technicians in this field, several modifications and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. The above disclosure is only a preferred embodiment of the present invention, and of course it cannot be used to limit the scope of the rights of the present invention. Therefore, equivalent changes made according to the claims of the present invention are still within the scope covered by the present invention.
Claims
1. A method for generating a pseudo label for a small infrared target, characterized in that: The method comprises: Collect infrared images I i and the infrared image I i The corresponding artificial label image L G ; From the artificial label image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ; According to the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence; Preset the centroid offset calibration network f BC weights and use the centroid shift to calibrate the network f BC Determine the central area prediction results Get the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid According to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence; The pseudo-label image is finely generated into a network G SCTrans Determine the infrared image I i The corresponding final pseudo-label image F.
2. The infrared small target pseudo label generation method according to claim 1 is characterized in that: The artificial label image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG , specifically including: Use the connected component algorithm CoC(·) to obtain the target centroid label image L C Get the connected domain graph M C , and from the connected domain graph M C Sample the coarse label image L B ; For the connected domain graph M C For each target in the image, extract its centroid coordinates to obtain the centroid label image L C ; According to the Gauss kernel function Gauss d=3 (·) respectively for the centroid label image L C and the coarse label image L B Each marked position in the fuzzy processing: L CG =Gauss d=3 (L C )、L BG =Gauss d=3 (L B ), and obtain the fuzzy centroid label image L CG and the fuzzy coarse label image L BG .
3. The infrared small target pseudo label generation method according to claim 2 is characterized in that: The infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence, including: Use the maximum pooling Maxpool2(·) to blur the rough label image L BG Perform downsampling to obtain a multi-scale fuzzy label image and The infrared image I i and the fuzzy coarse label image L BG With the calibration network f BC The zeroth level and first level encoding features are concatenated along the channel dimension to form the multi-scale fuzzy label image and Respectively with the calibration network f BC The second, third and fourth level encoding features are concatenated along the channel dimension; Use binary cross entropy BCE(·) to determine the central prediction result With the fuzzy centroid label image L CG The first loss function The initial learning rate is preset to 0.005, and the centroid offset calibration network f BC Train until the first loss function The value is within the convergence range.
4. The infrared small target pseudo label generation method according to claim 3 is characterized in that: The infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images SCTrans Until convergence, including: Determine the center area of the fuzzy prediction results The infrared image I i and fuzzy centroid As input, we train G using the BCE(·) loss function. SCTrans : The initial learning rate is preset to 0.001, and the pseudo-label image is finely generated into the network G SCTrans Train until the second loss function The value is within the convergence range.
5. The infrared small target pseudo label generation method according to claim 4 is characterized in that: The network G is finely generated according to the pseudo-label image SCTrans Determine the infrared image I i The corresponding final pseudo-label image F specifically includes: Preset centroid offset calibration network f BC and pseudo-label image fine generation network G SCTrans The weight of the infrared image I i and any coarse label image L B Generate pseudo-label images and obtain candidate label images F d ; Take the candidate label image F d As a mask, the coarse label image L B The final pseudo-label image F of the infrared small target is obtained by using the eight-neighborhood clustering algorithm.
6. The method for generating a pseudo-label for an infrared small target according to claim 5, characterized in that: The candidate label image F d As a mask, the coarse label image L B As the cluster center, the final pseudo-label image F of the infrared small target is obtained by using the eight-neighborhood clustering algorithm, which includes: F=Cluster mode=8 (F d ,L B ) Among them, Cluster mode=8 (·) represents the eight-neighborhood clustering function induced by the coarse point label image, and F is the final pseudo label image obtained.
7. The infrared small target pseudo-label generation method according to claim 6 is characterized in that: The network G is finely generated according to the pseudo-label image SCTrans Determine the infrared image I i The corresponding final pseudo-label image F, after which the method further includes: The accuracy of the pseudo-label image F is verified by using the intersection-comparison ratio. For the i-th generated label image F i , and the corresponding manually labeled images Get the corresponding intersection over union (IoU): Among them, A and A u Represent the tested object F i With the true value The intersection and union between pixels, TP[i] represents F i c and The intersection of the predicted positive pixel numbers, T[i] and P[i] represent F i and The number of positive pixels predicted by each; When the intersection over union (IoU) of the pseudo-label image F is lower than a fixed threshold, it is determined as an unqualified label image and re-labeled.
8. Infrared small target pseudo label generation system, characterized by: The system comprises: a label image acquisition unit, a model training unit, a centroid acquisition unit and a pseudo label image generation unit; The label image acquisition unit is used to collect infrared images I i and the infrared image I i The corresponding artificial label image L G ; From the artificial label image L G Extract the target centroid label image L C and the coarse label image L B , and use Gaussian blur kernel to process the target centroid label image L C and the coarse label image L B , get the fuzzy centroid label image L CG and the fuzzy coarse label image L BG ; The model training unit is used to train the infrared image I i and the fuzzy coarse label image L BG Train the centroid shift calibration network f BC Until convergence; according to the infrared image I i and fuzzy centroid Train a fine-grained generative network G for pseudo-labeled images sCTrans Until convergence; The centroid acquisition unit is used to preset the centroid offset calibration network f BC The weights of the centroid shift calibration network f BC Determine the central area prediction results Get the center prediction result Centroid And use Gaussian blur kernel to process the centroid Get the fuzzy centroid The pseudo-label image generating unit is used to finely generate the network G according to the pseudo-label image SCTrans Acquire the infrared image I i The corresponding final pseudo-label image F.
9. A readable storage medium storing a computer program, wherein when the computer program is executed by a processor, the processor is caused to execute the steps of the method according to any one of claims 1 to 7.
10. A computer device comprising a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor executes the steps of the method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Unsupervised medical image segmentation method and system based on active contour model
CN113643302A
A cross-domain pedestrian retrieval method based on heterogeneous pseudo-label learning
CN114937289A
Semi-automatic intelligent calibration method for cells in digital image
CN116452867A
Method for training domain adaptive neural network
JP2022042487A
