SAR image increment small sample target detection system and method based on prototype comparison

By generating and calibrating class prototype representations, the problems of high storage cost, high privacy risk and overfitting in SAR target detection with small sample size are solved, and a target detection system that maintains the performance of the basic class and improves the detection capability of new classes is realized in incremental learning.

CN120807885AActive Publication Date: 2025-10-17ANHUI UNIV +1
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202510909709.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-02
Publication Date
2025-10-17
Estimated Expiration
2045-07-02

AI Technical Summary

Technical Problem

Existing SAR small-sample target detection methods require re-accessing old category data when incrementally learning new categories, resulting in high storage costs and significant privacy risks. Furthermore, the scarcity of new category data can easily lead to overfitting and catastrophic forgetting. Traditional methods cannot effectively utilize basic class knowledge to optimize the representation of new categories, resulting in classification confusion and performance degradation.

Method used

The class prototype representation generation module generates the mean features of the basic class RoI as the class prototype. The loss function is designed through the hybrid class prototype comparison encoding module to force the aggregation of similar classes and the separation of dissimilar classes. The distribution difference between the newly added class samples and the class prototype is calibrated by the Gaussian kernel function to optimize the feature space and obtain the InFSAR model.

Benefits of technology

Without accessing old data, it effectively retains the basic category detection capabilities, enhances the discriminative power of new category representations, achieves efficient, flexible and secure incremental learning of target detection, improves the robustness and scalability of the model, reduces storage costs and lowers the risk of overfitting.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120807885A_ABST
    Figure CN120807885A_ABST
Patent Text Reader

Abstract

The invention discloses an SAR image increment small sample target detection system and method based on prototype comparison. The system comprises a prototype representation generation module, a mixed prototype comparison coding module, a prototype calibration module and a target detection module. The class prototype representation generation module is used for extracting a basic class RoI feature mean value of a historical SAR image based on a pre-training model as a class prototype; the mixed class prototype comparison coding module is used for combining a newly added class sample and a class prototype design loss function, forcing similar aggregation and heterogeneous separation, and optimizing a feature space; the class prototype calibration module is used for measuring and minimizing the distribution difference between the newly added class sample and the class prototype through a Gaussian kernel function, and constraining the characterization offset of an increment stage to obtain an InFSAR model; and the target detection module is used for acquiring an SAR image and carrying out small sample target detection based on the InFSAR model.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The application belongs to the technical field of computer vision and remote sensing image processing, and particularly relates to a SAR image incremental small sample target detection system and method based on prototype comparison. BACKGROUND

[0002] The existing SAR small sample target detection method needs to re-access old class data to ensure the performance of the base class when incrementally learning new classes, resulting in high storage cost and privacy risk. In addition, the scarcity of new class data can easily cause overfitting, and the inaccessibility of base class data leads to catastrophic forgetting. At present, there is a lack of a solution that can maintain the performance of the base class while efficiently adapting to new classes during the incremental learning process. For example, although the traditional method such as TFA (Two-stage Fine-tuning Approach) can alleviate forgetting by freezing part of the parameters, it cannot effectively utilize the base class knowledge to optimize the representation of the new class, resulting in classification confusion and performance degradation. SUMMARY

[0003] The application aims to solve the problems of the prior art and provides the following solution:

[0004] A SAR image incremental small sample target detection system based on prototype comparison, comprising a class prototype representation generation module, a mixed class prototype contrast coding module, a class prototype calibration module and a target detection module.

[0005] The class prototype representation generation module is used to extract the mean value of the base class RoI features of the historical SAR image based on a pre-trained model as a class prototype.

[0006] The mixed class prototype contrast coding module is used to design a loss function by combining the new class samples and the class prototype, forcing the same class to aggregate and the different classes to separate, and optimizing the feature space.

[0007] The class prototype calibration module is used to measure and minimize the distribution difference between the new class samples and the class prototype by a Gaussian kernel function, constrain the representation shift in the incremental stage, and obtain an InFSAR model.

[0008] The target detection module is used to obtain a SAR image and perform small sample target detection based on the InFSAR model.

[0009] Preferably, the workflow of the class prototype representation generation module comprises:

[0010] A Faster R-CNN target detection framework is adopted, and a feature extraction model is constructed by combining a ResNet-101 backbone network with a feature pyramid network.

[0011] acquire the historical SAR images of the ship, and train the feature extraction model using the historical SAR images to obtain the pre-training model;

[0012] extract the basic class RoI features of the historical SAR images using the pre-training model, and calculate the mean representation of the basic class RoI features to obtain the class prototype:

[0013]

[0014] wherein p c represents the class prototype, x c represents the entire sample set of the historical SAR images, x i represents the input feature vector, y i represents the class label, f θ represents the feature extractor of the pre-training model.

[0015] Preferably, the working process of the hybrid class prototype contrast encoding module comprises:

[0016] input the K-shot sample of the new class sample, and obtain the RoI feature vector φ i through the frozen feature extractor.

[0017] calculate the cosine similarity between the feature vector φ i and the class prototype set P={p1,…,p c};

[0018]

[0019] wherein sim represents the cosine similarity, φ j represents the vector embedded by the hybrid class prototype contrast encoding module.

[0020] based on the cosine similarity, design a loss function combining the new class sample and the class prototype

[0021]

[0022]

[0023] wherein M represents the number of data sets of M labeled sample examples, represents the IoU score matched with its true value box, ε represents the threshold of the intersection over union IoU, M yi represents the number of same class samples in the current batch, represents the indicator function, y j represents the jth RoI feature, C represents the total number of classes, c represents the class number, p kdenotes a class prototype of class k, and denotes a temperature coefficient;

[0024] based on the loss function Forcing the same class samples to aggregate in the feature space while separating the new class from the base class prototype, the feature space is optimized.

[0025] Preferably, the workflow of the class prototype calibration module includes:

[0026] Given the distribution of class prototypes E={d j |j=1,…,C} and the distribution of new class samples F={f i |i=1,…,Q}, where d j and f i respectively represent the probability distribution of class prototypes and new class samples;

[0027] The maximum mean difference is calculated by the Gaussian kernel function to quantify the distance between the two class distributions:

[0028]

[0029] Where k(x,y) represents the Gaussian kernel function, sigma represents the hyperparameter, MMD represents the maximum mean difference, m represents the number of samples in set F, and n represents the number of samples in set E;

[0030] By adding MMD as a regularization term to the total loss function, the approximation of the new class prototype distribution to the class prototype distribution is realized, thereby constraining the representation drift in the incremental learning process, and the InFSAR model is obtained.

[0031] The application also provides a SAR image incremental small sample target detection method based on prototype comparison, which is applied to the system described in any one of the above and includes the following steps:

[0032] S1. Extracting the base class RoI feature mean of the historical SAR image as a class prototype based on the pre-trained model;

[0033] S2. Designing a loss function combining the new class samples and the class prototype to force the same class to aggregate and the different classes to separate, and optimizing the feature space;

[0034] S3. Measuring and minimizing the distribution difference between the new class samples and the class prototype by the Gaussian kernel function to constrain the representation drift in the incremental stage, and obtaining the InFSAR model;

[0035] S4. Obtaining a SAR image and performing small sample target detection based on the InFSAR model.

[0036] Preferably, the S1 includes:

[0037] The Faster R-CNN target detection framework is adopted, a feature extraction model is constructed by combining a ResNet-101 backbone network and a feature pyramid network;

[0038] The historical SAR image of the ship is acquired, and the feature extraction model is trained by using the historical SAR image, so as to obtain the pre-training model;

[0039] The base class RoI feature of the historical SAR image is extracted by using the pre-training model, and the mean representation of the base class RoI feature is calculated, so as to obtain the class prototype;

[0040]

[0041] Wherein, p c represents the class prototype, x c represents the sample set of the historical SAR image, x i represents the input feature vector, y i represents the class label, f θ represents the feature extractor of the pre-training model.

[0042] Preferably, the S2 comprises:

[0043] The K-shot sample of the new class sample is input, and the RoI feature vector φ i is obtained by the frozen feature extractor.

[0044] The cosine similarity between the feature vector φ i and the class prototype set P={p1,…,p c} is calculated:

[0045]

[0046] Wherein, sim represents the cosine similarity, φ j represents the vector embedded by the hybrid class prototype contrast coding module;

[0047] Based on the cosine similarity, the loss function

[0048] Wherein, M represents the number of data sets of M labeled sample examples, represents the IoU score matched with the true value box, ε represents the threshold of the intersection over union IoU, M yi represents the number of same-class samples in the current batch, represents the indicator function, y j represents the jth RoI feature, C represents the total number of classes, c represents the class number, p krepresents a class prototype of a class k, and tau represents a temperature coefficient;

[0049] based on the loss function Forcing the same class samples to aggregate in the feature space while separating the new class from the base class prototypes, the feature space is optimized.

[0050] Preferably, the S3 comprises:

[0051] Given the distribution of class prototypes E={d j |j=1,…,C} and the distribution of new class samples F={f i |i=1,…,Q}, where d j and f i represent the probability distribution of class prototypes and new class samples respectively;

[0052] The maximum mean difference is calculated by a Gaussian kernel function to quantify the distance between the two class distributions:

[0053]

[0054] Where k(x,y) represents the Gaussian kernel function, sigma represents the hyperparameter, MMD represents the maximum mean difference, m represents the number of samples in set F, and n represents the number of samples in set E.

[0055] By adding MMD as a regularization term to the total loss function, the approximation of the new class prototype distribution to the class prototype distribution is realized, thereby constraining the representation shift in the incremental learning process, and the InFSAR model is obtained.

[0056] Compared with the prior art, the present application has the following advantages:

[0057] The present application solves the problems of high storage cost, high risk of privacy leakage, overfitting caused by scarcity of new class data, and degradation of base class performance (catastrophic forgetting) caused by re-accessing base class data during incremental learning of new classes in the prior art. By designing a class prototype representation generation module (CPRG), a mixed class prototype contrast encoding module (MCPCE), and a prototype calibration strategy, the present application can effectively retain the detection ability of the base classes without accessing old data, while enhancing the representation distinguishability of the new classes, thereby achieving efficient, flexible and secure incremental learning of target detection in complex SAR scenarios, meeting the demand for dynamically adding new classes, and improving the robustness and expansibility of the overall model. BRIEF DESCRIPTION OF DRAWINGS

[0058] In order to make the technical solutions of the present application clearer, the following briefly introduces the drawings needed in the embodiments. Obviously, the drawings described in the following are only some of the embodiments of the present application, and other drawings can be obtained by those skilled in the art without any creative effort on the basis of these drawings.

[0059] Figure 1 The system structure schematic diagram of the embodiment of the present application;

[0060] Figure 2 The system framework schematic diagram of the embodiment of the present application;

[0061] Figure 3 The class prototype representation generation module structure schematic diagram of the embodiment of the present application;

[0062] Figure 4 The hybrid class prototype contrast encoding module structure schematic diagram of the embodiment of the present application. DETAILED DESCRIPTION

[0063] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without any creative effort fall within the scope of protection of the present application.

[0064] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and easy to understand, the present application will be further described in detail below with reference to the drawings and specific embodiments.

[0065] Embodiment one

[0066] In this embodiment, as shown in Figure 1 , Figure 2 , a SAR image incremental small sample target detection system based on prototype contrast includes a class prototype representation generation module, a hybrid class prototype contrast encoding module, a class prototype calibration module and a target detection module.

[0067] The class prototype representation generation module is used to extract the basic class RoI feature mean of the historical SAR image as the class prototype based on the pre-trained model.

[0068] The workflow of the class prototype representation generation module includes: using a Faster R-CNN target detection framework, a backbone network is ResNet-101 combined with a feature pyramid network to construct a feature extraction model; obtaining historical SAR images of a ship, and training the feature extraction model using the historical SAR images to obtain a pre-trained model; extracting basic class RoI features of the historical SAR images using the pre-trained model, and calculating the mean representation of the basic class RoI features to obtain a class prototype.

[0069] In the present embodiment, the class prototype representation generation module (CPRG) function is to learn a robust prototype representation containing high-dimensional semantic information of each basic class, and an example diagram of the module is as shown in Figure 3 The module can effectively improve the generalization ability of the model when processing new class data and reduce the risk of catastrophic forgetting by capturing and representing the core features of the basic class.

[0070] In the basic training stage, a Faster R-CNN target detection framework is used, and a backbone network is ResNet-101 combined with a feature pyramid network (FPN) for extracting multi-scale SAR image features. The feature dimension of the region of interest (RoI) output by the network is 1024. The training data is a basic class dataset C base (e.g. 6 classes of ships in SRSDD-v1.0), and the model training is completed by optimizing the target detection loss function , wherein, is the classification loss, is the bounding box regression loss, is the region proposal network loss. The training parameters are set as: initial learning rate 0.002, batch size 2, stochastic gradient descent (SGD) optimizer, momentum 0.9, weight decay coefficient 0.00001, training rounds 40k (SRSDD-v1.0) or 80k (SARDet-100K), and the learning rate is reduced to 0.0005 in the middle of training to stabilize convergence. After the model pre-training is completed, the RoI features of all samples of each basic class c∈C base are extracted, and the class prototype p c is calculated as the mean representation of the feature space of the class. Specifically, given a basic class sample set D M ={(x m , y m )}, where is the input feature vector, y i is the class label, and the class prototype calculation formula is:

[0071]

[0072] wherein, p c represents the class prototype, and xc x represents the set of all samples of historical SAR images i y represents the input feature vector i f represents the class label θ φ represents the feature extractor of the pre-trained model. The generated class prototype p c w represents the Softmax classification layer weight corresponding to it i The prototype library is stored together in the form of a key-value pair set {(p1, w1),..., (p C , w C )} so as to be called in the subsequent incremental learning stage.

[0073] The mixed class prototype contrast coding module is used to design a loss function combining new class samples and class prototypes, forcing same-class aggregation and different-class separation, and optimizing the feature space.

[0074] In this embodiment, the mixed class prototype contrast coding module (MCPCE) optimizes the new class feature space through contrast learning, so that same-class samples are closely aggregated and different-class samples (including new classes and base classes) are significantly separated, thereby reducing classification confusion. The introduction of base class prototypes for contrast enhances the distinctiveness of new class representation and avoids overfitting caused by data scarcity. An example diagram is shown in Figure 4 .

[0075] The workflow of the mixed class prototype contrast coding module includes: inputting K-shot samples (K=3, 5, 10, 30) of the new class sample C novel , obtaining the RoI feature vector φ i through the frozen feature extractor; to improve feature quality, only RoI features with an intersection over union (IoU) ≥ ε (ε=0.7) with the true bounding box are retained, low-quality proposal boxes are filtered, and the reliability of feature coding is ensured. Calculate the cosine similarity between the feature vector φ i and the class prototype set P={p1,…,p c}.

[0076]

[0077] wherein sim represents the cosine similarity, φ j represents the vector embedded by the mixed class prototype contrast coding module; based on the cosine similarity, a loss function is designed combining the new class samples and the class prototypes

[0078]

[0079] wherein M represents the number of data sets of M labeled sample examples, IoU represents the IoU score matched with its true value box, and ε represents the threshold of the intersection over union (IoU). M yidenotes the number of same type samples in the current batch, denotes the indicator function, y j denotes the jth RoI feature, C denotes the total number of classes, c denotes the class number, p k denotes the class prototype of class k, τ denotes the temperature coefficient; based on the loss function Forcing same type samples to aggregate in the feature space, while separating new classes from the base class prototype, optimizing the feature space.

[0080] The class prototype calibration module is used to measure and minimize the distribution difference between the new class samples and the class prototype by the Gaussian kernel function, constrain the representation shift in the incremental stage, and obtain the InFSAR model.

[0081] In this embodiment, the distribution alignment strategy is used to effectively reduce the invasion of new class prototypes on the feature space of the base class, maintain the detection performance of the base class, and alleviate the catastrophic forgetting. The MMD loss ensures the consistency of new and old class prototypes in the latent space, and avoids the deviation of the model from the initial optimization direction due to incremental updating.

[0082] The workflow of the class prototype calibration module includes: given the distribution E = {d j |j = 1, …, C} of the class prototype and the distribution F = {f i |i = 1, …, Q} of the new class samples, where d j and f i respectively represent the probability distribution of the class prototype and the new class samples; the maximum mean difference is calculated by the Gaussian kernel function to quantify the distance between the two distributions:

[0083]

[0084]

[0085] where k(x, y) represents the Gaussian kernel function, σ represents the hyperparameter, MMD represents the maximum mean difference, m represents the number of samples in set F, and n represents the number of samples in set E; by adding MMD as a regularization term to the total loss function, the approximation of the new class prototype distribution to the class prototype distribution is realized, thereby constraining the representation shift in the incremental learning process, and the calibration loss is defined as:

[0086] L MMD = MMD 2 (E, F);

[0087] Total loss function design: integrate the target detection task loss, contrastive loss and distribution calibration loss to form a multi-task joint optimization objective: L = L TFA + αL MCFCF + β LMMDwhere, a = 0.5 and b = 0.5 are hyperparameters for balancing the weights of detection accuracy, contrastive learning and distribution alignment.

[0088] Incremental fine-tuning process: (1) Input preparation: load the base class prototype library generated by the training model and the K-shot sample data of the new class. (2) Parameter freezing: fix the parameters of the feature extractor (ResNet-101+FPN), only optimize the weights of the classifier and the regressor, reduce the computational overhead and prevent the loss of base class knowledge. (3) Forward propagation: calculate the RoI feature, detection loss L TFA , contrastive loss L MCFCF and MMD loss L MMD ; (4) Back propagation: retrain the parameters according to the total loss L until the model converges (usually 10-20 rounds of tuning), and obtain the InFSAR model.

[0089] The target detection module is used to obtain the SAR image and perform small sample target detection based on the InFSAR model.

[0090] Embodiment two

[0091] In this embodiment, a SAR image incremental small sample target detection method based on prototype contrast includes the following steps:

[0092] S1. Extract the mean value of the base class RoI feature of the historical SAR image based on the pre-trained model as the class prototype.

[0093] S1 includes: using the Faster R-CNN target detection framework, the backbone network is ResNet-101 combined with the feature pyramid network to construct the feature extraction model; obtaining the historical SAR image of the ship, and training the feature extraction model using the historical SAR image to obtain the pre-trained model; using the pre-trained model to extract the base class RoI feature of the historical SAR image, and calculating the mean value representation of the base class RoI feature to obtain the class prototype:

[0094]

[0095] where, p c represents the class prototype, x c represents the entire sample set of the historical SAR image, x i represents the input feature vector, y i represents the class label, and f θ represents the feature extractor of the pre-trained model.

[0096] S2. Design a loss function combining new class samples and class prototypes to force same-class aggregation, different-class separation, and optimize the feature space.

[0097] S2 includes: inputting K-shot samples of new-added class samples, obtaining RoI feature vector φ through the frozen feature extractor i ; calculating the cosine similarity between the feature vector φ i and the class prototype set P={p1,…,p c}

[0098]

[0099] wherein sim represents the cosine similarity, φ j represents the vector embedded by the hybrid class prototype contrast coding module; based on the cosine similarity, a loss function is designed combining the new class samples and the class prototypes

[0100]

[0101] wherein M represents the number of data sets of M marked sample examples, represents the IoU score matched with its true value box, ε represents the threshold of the intersection over union IoU, M yi represents the number of same class samples in the current batch, represents the indicator function, y j represents the jth RoI feature, C represents the total number of categories, c represents the category number, p k represents the class prototype of the category k, τ represents the temperature coefficient; based on the loss function the same class samples are forced to aggregate in the feature space, while the new class and the base class prototypes are separated, and the feature space is optimized.

[0102] S3. Through the Gaussian kernel function measurement and minimization of the distribution difference between the new class samples and the class prototypes, the representation deviation of the incremental stage is constrained, and the InFSAR model is obtained.

[0103] S3 includes: given the distribution E={d j |j=1,…,C} of the class prototype and the distribution F={f i |i=1,…,Q} of the new class sample, wherein d j and f i represent the probability distribution of the class prototype and the new class sample respectively; the maximum mean difference is calculated through the Gaussian kernel function, and the distance between the two distributions is quantified:

[0104]

[0105] Where k(x,y) represents the Gaussian kernel function, σ represents the hyperparameter, MMD represents the maximum mean difference, m represents the number of samples in set F, and n represents the number of samples in set E. By adding MMD as a regularization term to the total loss function, the new class prototype distribution is approximated to the class prototype distribution, thereby constraining the representation shift in the incremental learning process and obtaining the InFSAR model.

[0106] S4. Acquire SAR images and perform small-sample target detection based on the InFSAR model.

[0107] Example 3

[0108] The proposed incremental small-shot target detection method for SAR images based on prototype contrast (InFSAR) significantly improves the overall performance of the model in incremental learning through the synergy of prototype-like representation generation, hybrid contrastive learning, and distribution calibration strategies. In terms of basic class detection performance retention, the model achieves a basic class average precision (bAP) of 77.44% in the 30-shot incremental task on the SRSDD-v1.0 dataset, a 13.14% improvement over the traditional baseline method TFA. The basic class bAP retention rate exceeds 95% on the SARDet-100K dataset, effectively alleviating the catastrophic forgetting problem caused by the introduction of new class data. For scenarios where new class data is scarce (3-shot to 30-shot), the new class average precision (nAP) improves by 7.24%-14.05% and 6.14%-14.05% on the SRSDD-v1.0 and SARDet-100K datasets, respectively, significantly outperforming competing methods such as Meta-RCNN and FPD, and reducing the overfitting rate by over 30%. In addition, the system supports multi-stage incremental tasks (such as 3+2+1 category division), with overall detection accuracy (All) fluctuating less than 1%. In the 30-shot task of SARDet-100K, All indicators reach 69.91%, and in complex SAR scenarios (such as large-scale images and dense targets), the false detection rate is reduced by 18.7% and the missed detection rate is reduced by 12.3%. By replacing the original data storage with a prototype library, storage costs are reduced by more than 90%, and the incremental fine-tuning training time is shortened by 40% (only 10-20 iterations are required), meeting the efficient adaptation requirements for dynamically added categories in practical applications. Furthermore, after the model was migrated to the MSTAR dataset that was not involved in training, the new class detection accuracy (nAP) still remained at 62.3%, verifying the generalization ability and universality of the method.

[0109] The embodiments described above are merely descriptions of preferred embodiments of the present invention and are not intended to limit the scope of the present invention. Without departing from the spirit of the present invention, various modifications and improvements made to the technical solutions of the present invention by persons skilled in the art should fall within the scope of protection defined by the claims of the present invention.

Claims

1. A SAR image incremental small sample target detection system based on prototype comparison, characterized by: include: Class prototype representation generation module, hybrid class prototype contrast encoding module, class prototype calibration module and target detection module; The class prototype representation generation module is used to extract the basic class RoI feature mean of the historical SAR image as the class prototype based on the pre-trained model; The hybrid class prototype comparison encoding module is used to combine the newly added class samples and the class prototype to design a loss function, forcing the same class to aggregate and the different classes to separate, thereby optimizing the feature space; The class prototype calibration module is used to measure and minimize the distribution difference between the newly added class samples and the class prototype through a Gaussian kernel function, constrain the representation offset in the incremental stage, and obtain an InFSAR model; The target detection module is used to acquire SAR images and perform small sample target detection based on the InFSAR model.

2. The SAR image incremental small sample target detection system based on prototype comparison according to claim 1, characterized in that: The workflow of the class prototype representation generation module includes: The Faster R-CNN target detection framework is used, with the backbone network being ResNet-101 combined with the feature pyramid network to build a feature extraction model; Acquiring the historical SAR images of the ship, and using the historical SAR images to train the feature extraction model to obtain the pre-trained model; The pre-trained model is used to extract the basic class RoI features of the historical SAR image, and the mean representation of the basic class RoI features is calculated to obtain the class prototype: Among them, p c Represents the class prototype, x c represents the set of all samples of historical SAR images, x i represents the input feature vector, y i represents the category label, f θ Represents the feature extractor of the pretrained model.

3. The SAR image incremental small sample target detection system based on prototype comparison according to claim 2, characterized in that: The workflow of the hybrid prototype comparison coding module includes: Input the K-shot sample of the newly added class sample and obtain the RoI feature vector φ through the frozen feature extractor i ; Calculate the eigenvector φ i and the class prototype set P = {p1,…,p c } cosine similarity between: Among them, sim represents cosine similarity, φ j A vector representing the embedding of the hybrid class prototype contrast encoding module; Based on the cosine similarity, a loss function is designed in combination with the newly added class samples and the class prototype. Among them, M represents the number of labeled sample examples in the dataset, It is expressed as the IoU score matching its true value box, ε represents the threshold of the intersection over union (IoU), and M yi Indicates the number of similar samples in the current batch, represents the indicator function, y j Represents the jth RoI feature, C represents the total number of categories, c represents the number of categories, p k represents the class prototype of category k, τ represents the temperature coefficient; Based on the loss function It forces samples of the same type to aggregate in the feature space, while separating new classes from base class prototypes to optimize the feature space.

4. The SAR image incremental small sample target detection system based on prototype comparison according to claim 1, characterized in that: The workflow of the prototype-like calibration module includes: Given the distribution of class prototypes E = {d j |j=1,…,C} and the distribution of new class samples F={f i |i=1,…,Q}, where d j and f i Represent the probability distribution of class prototype and newly added class samples respectively; The maximum mean difference is calculated by the Gaussian kernel function to quantify the distance between the two distributions: Where k(x,y) represents the Gaussian kernel function, σ represents the hyperparameter, MMD represents the maximum mean difference, m represents the number of samples in set F, and n represents the number of samples in set E; By adding MMD as a regular term to the total loss function, the new class prototype distribution is approximated to the class prototype distribution, thereby constraining the representation shift in the incremental learning process and obtaining the InFSAR model.

5. A method for incremental small sample target detection in SAR images based on prototype comparison, the method being applied to the system according to any one of claims 1 to 4, characterized in that: The following steps are involved: S1. Extract the mean of basic class RoI features of historical SAR images as class prototypes based on the pre-trained model; S2. Design a loss function based on the newly added class samples and the class prototype, forcing the aggregation of similar classes and the separation of heterogeneous classes to optimize the feature space; S3. Measure and minimize the distribution difference between the newly added class samples and the class prototype using a Gaussian kernel function, constrain the representation offset in the incremental phase, and obtain an InFSAR model; S4. Acquire a SAR image and perform small sample target detection based on the InFSAR model.

6. The incremental small sample target detection method for SAR images based on prototype comparison according to claim 5, characterized in that: Said S1 comprises: The Faster R-CNN target detection framework is used, with the backbone network being ResNet-101 combined with the feature pyramid network to build a feature extraction model; Acquiring the historical SAR images of the ship, and using the historical SAR images to train the feature extraction model to obtain the pre-trained model; The pre-trained model is used to extract the basic class RoI features of the historical SAR image, and the mean representation of the basic class RoI features is calculated to obtain the class prototype: Among them, p c Represents the class prototype, x c represents the set of all samples of historical SAR images, x i represents the input feature vector, y i represents the category label, f θ Represents the feature extractor of the pretrained model.

7. The incremental small sample target detection method for SAR images based on prototype comparison according to claim 6, characterized in that: The S2 includes: Input the K-shot sample of the newly added class sample and obtain the RoI feature vector φ through the frozen feature extractor i ; Calculate the eigenvector φ i and the class prototype set P = {p1,…,p c } cosine similarity between: Among them, sim represents cosine similarity, φ j A vector representing the embedding of the hybrid class prototype contrast encoding module; Based on the cosine similarity, a loss function is designed in combination with the newly added class samples and the class prototype. Among them, M represents the number of labeled sample examples in the dataset, It is expressed as the IoU score matching its true value box, ε represents the threshold of the intersection over union (IoU), and M yi Indicates the number of similar samples in the current batch, represents the indicator function, y j Represents the jth RoI feature, C represents the total number of categories, c represents the number of categories, p k represents the class prototype of category k, τ represents the temperature coefficient; Based on the loss function It forces samples of the same type to aggregate in the feature space, while separating new classes from base class prototypes to optimize the feature space.

8. The SAR image incremental small sample target detection method based on prototype comparison according to claim 5, characterized in that: The S3 includes: Given the distribution of class prototypes E = {d j |j=1,…,C} and the distribution of new class samples F={f i |i=1,…,Q}, where d j and f i Represent the probability distribution of class prototype and newly added class samples respectively; The maximum mean difference is calculated by the Gaussian kernel function to quantify the distance between the two distributions: Where k(x,y) represents the Gaussian kernel function, σ represents the hyperparameter, MMD represents the maximum mean difference, m represents the number of samples in set F, and n represents the number of samples in set E; By adding MMD as a regular term to the total loss function, the new class prototype distribution is approximated to the class prototype distribution, thereby constraining the representation shift in the incremental learning process and obtaining the InFSAR model.

Citation Information

Patent Citations

  • Small sample increment SAR image target identification method based on cosine prototype learning

    CN116863301A

  • SAR image small sample target detection system and method based on context perception and Gaussian flow representation

    CN119006798A

  • Image classification method for small sample class incremental learning based on prototype features

    CN120088576A

  • Artificial intelligence (AI) assisted analysis of electron microscope data

    WO2022076915A1