Hyperspectral image active domain adaptive classification method based on prototype alignment

By adopting the prototypical alignment-based active domain adaptation method in hyperspectral image classification, the problems of high-dimensional characteristics and class imbalance are solved, and the efficient classification performance and cost-effective improvement on the target domain are achieved.

CN119494989AActive Publication Date: 2025-02-21NANJING UNIV OF SCI & TECH
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202510041036.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-10
Publication Date
2025-02-21
Estimated Expiration
2045-01-10

AI Technical Summary

Technical Problem

The existing active domain adaptation methods are difficult to effectively deal with the high-dimensional characteristics and spectral variability of hyperspectral images, and ignore the phenomenon of class imbalance, resulting in the model having class bias in the target domain and degradation of classification performance.

Method used

Adopt the hyperspectral image active domain adaptation classification method based on prototype alignment, and obtain the target domain prototype through pseudo-label allocation, combine cross entropy loss and prototype alignment loss for training, identify specific samples of the target domain and label them, and use the category frequency to perform class balance self-balancing. Training to enhance the differentiation of the model and adaptability to the target domain.

Benefits of technology

It effectively improves the classification performance on the target domain, alleviates the problem of category imbalance, improves the cost-effectiveness of the model, and significantly improves the classification performance in unbalanced scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119494989A_ABST
    Figure CN119494989A_ABST
Patent Text Reader

Abstract

The invention discloses a hyperspectral image active domain adaptive classification method based on prototype alignment. The classification method comprises three stages. In the first stage, pseudo labels are distributed to confidence target domain samples, feature representation of a target domain prototype is obtained, and distribution between domains is preliminarily aligned under interaction guidance of a source domain and the target domain prototype; in the second stage, selecting a potential most valuable target domain sample under domain offset and labeling the target domain sample by an expert; in the third stage, target domain samples with balanced category distribution are sampled for self-training. According to the method, the classification performance on the target domain can be effectively improved by utilizing limited marking budget, the cost benefit is remarkable, and meanwhile, the problem of class imbalance generally existing in the hyperspectral image is relieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of hyperspectral image classification, and in particular relates to an active domain adaptation classification method for hyperspectral images based on prototype alignment. Background Art

[0002] In recent years, with the rapid development of machine learning and deep learning methods, hyperspectral image classification technology has made significant progress. However, these methods usually assume that the training data (source domain) and the test data (target domain) share the same distribution. In practical applications, due to factors such as differences in imaging equipment, sensor parameters, and acquisition environment, there is often a domain shift problem between the source domain and the target domain. This distribution difference will significantly reduce the performance of the classification model in the target domain, especially when there is a lack of labeled data in the target domain, the generalization ability of the model is usually difficult to guarantee.

[0003] In order to solve the domain shift problem, domain adaptation technology has gradually been introduced into the field of hyperspectral image classification. Domain adaptation reduces the distribution difference between the source domain and the target domain, so that the model trained from the source domain can be well generalized to the target domain scenario. In particular, active domain adaptation combines the advantages of domain adaptation and active learning. By actively selecting a small amount of information-rich unlabeled data in the target domain for manual labeling, it significantly reduces the labeling cost while improving the model performance. This method is particularly suitable for practical application scenarios in hyperspectral image classification where target domain data is difficult to label but still requires high-precision classification.

[0004] Existing active domain adaptation methods usually perform feature extraction and domain alignment based on the low-dimensional characteristics of natural images, but have difficulty dealing with the high-dimensional characteristics and spectral variability of hyperspectral images. In the active sample selection stage, existing methods often only focus on the uncertainty or representativeness of samples, while ignoring the guiding role of the semantic structure of the target domain, resulting in the selection of suboptimal samples that fail to effectively capture the specific features of the target domain. In addition, most existing active domain adaptation methods ignore the class imbalance phenomenon in hyperspectral images. This neglect makes it difficult for the model to effectively learn the distinguishing features of the minority classes, which may lead to class bias in the target domain, resulting in a significant decrease in classification performance in imbalanced scenarios. Summary of the invention

[0005] The present invention aims to provide an active domain adaptation classification method for hyperspectral images based on prototype alignment, which can effectively improve the classification performance on the target domain under a limited annotation budget, improve cost-effectiveness, and alleviate the class imbalance problem that is prevalent in hyperspectral images.

[0006] In order to achieve the purpose of the present invention, the present invention provides a hyperspectral image active domain adaptation classification method based on prototype alignment, comprising the following steps:

[0007] Step 1: Assign pseudo labels to target domain samples to obtain target domain prototypes;

[0008] Step 2: Obtain the first-stage loss function through the cross entropy loss of the source domain, the feature-level prototype alignment loss, and the task-level prototype alignment loss;

[0009] Step 3: Identify target domain specific samples;

[0010] Step 4: Select and label samples from the target domain specific samples to obtain a labeled target domain sample set;

[0011] Step 5: Obtain a second-stage loss function by using the cross entropy loss of the labeled target domain sample set, the feature-level prototype alignment loss of the labeled target domain sample set, and the first-stage loss function;

[0012] Step 6: Obtain the category frequency of the target domain through the labeled target domain sample set and the unlabeled target domain sample set;

[0013] Step 7: Obtain a target domain sample set for class-balanced self-training through the category frequency of the target domain;

[0014] Step 8: Obtain a third-stage loss function by using the cross entropy loss of the target domain sample set for class-balanced self-training and the second-stage loss function.

[0015] Compared with the prior art, the significant progress of the present invention lies in: (1) By using a feature extractor with a spectral attention mechanism, the present invention enables the model to focus on spectral information with high discrimination and suppress the influence of band variability and redundant bands, thereby effectively solving the high-dimensional characteristics and spectral variability problems of hyperspectral images; (2) The present invention constructs a target domain prototype based on pseudo-labeled target domain samples, guides active sample selection through the target domain prototype, and makes full use of the semantic information of the target domain, so that the model can capture the structural characteristics of the semantic distribution of the target domain; (3) The present invention further enhances the model's discrimination of the target domain and alleviates the category imbalance problem in the target domain by sampling pseudo-labeled target domain samples with balanced category distribution for self-training.

[0016] In order to more clearly illustrate the functional characteristics and structural parameters of the present invention, further description is given below in conjunction with the accompanying drawings and specific implementation methods. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:

[0018] Figure 1It is a schematic diagram of the framework of the present invention;

[0019] Figure 2 is a schematic diagram of the Pavia cross-domain dataset based on the present invention, wherein: Figure 2 (a) is a false color image of the University of Pavia. Figure 2 (b) is the true value label of the University of Pavia, Figure 2 (c) is a false color image of the center of Pavia. Figure 2 (d) is the true value label of the center of Pavia;

[0020] Figure 3 This is a schematic diagram of the Houston cross-domain dataset based on the present invention, wherein: Figure 3 (a) is a false color image of Houston in 2013. Figure 3 (b) is the Houston 2013 true value label, Figure 3 (c) is a false color image of Houston in 2018. Figure 3 (d) is the Houston 2018 ground truth label;

[0021] Figure 4 This is a schematic diagram of the Shanghai-Hangzhou cross-domain dataset based on the present invention, wherein: Figure 4 (a) is a false color image of Shanghai. Figure 4 (b) is the Shanghai true value label, Figure 4 (c) is a false color image of Hangzhou. Figure 4 (d) is the Hangzhou ground truth label;

[0022] Figure 5 Schematic diagram of the classification effect of the deep learning network model of the present invention on the target domain data set, wherein: Figure 5 (a) is the classification effect of the deep learning network model of the present invention on the Pavia center, Figure 5 (b) is the classification effect of the deep learning network model of the present invention on Houston 2018, Figure 5 (c) is the classification effect of the deep learning network model of the present invention on Hangzhou. DETAILED DESCRIPTION

[0023] 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.

[0024] The invention discloses a hyperspectral image active domain adaptation classification method based on prototype alignment, combined with Figure 1 , including three stages:

[0025] Phase 1:

[0026] 1. A hyperspectral image active domain adaptation classification method based on prototype alignment, characterized by comprising the following steps:

[0027] Step 1: Assign pseudo labels to target domain samples to obtain target domain prototypes;

[0028] 1.1. Obtain source domain prototype through source domain samples:

[0029] ;

[0030] in, Indicates category The source domain prototype, Indicates that it belongs to the category The number of source domain samples, Indicates all belonging to the category The source domain samples L2 normalized feature vector of samples;

[0031] 1.2. Use the classifier to predict the target domain sample and obtain the first pseudo label;

[0032] 1.3. Obtain the remaining pseudo labels based on the source domain prototype closest to the target domain sample and K source domain samples;

[0033] 1.4. Filter the target domain samples whose first pseudo-label is the same as the remaining pseudo-labels to obtain high-confidence target domain samples; obtain the target domain prototype through the high-confidence target domain samples:

[0034] ;

[0035] in, Indicates category The target domain prototype, Indicates that it belongs to the category The number of target domain samples, Indicates all belonging to the category In the target domain sample The L2-normalized feature vector of samples.

[0036] Step 2: Obtain the first-stage loss function through the cross entropy loss of the source domain, the feature-level prototype alignment loss, and the task-level prototype alignment loss;

[0037] 2.1. According to the distance between each sample and the source domain prototype and the target domain prototype of its category, the feature-level prototype alignment loss is obtained :

[0038] ;

[0039] in, represents the number of source domain samples, Indicates The L2-normalized feature vector of source domain samples, Indicates The labels of source domain samples, represents the number of high confidence target domain samples, Indicates The L2 normalized feature vector of the high confidence target domain samples, Indicates Pseudo labels of the high-confidence target domain samples;

[0040] 2.2. Target Domain Samples The distance between the target domain prototype and each category is input into the softmax function to obtain the distance between the target domain prototype and the target domain sample. Predicted class probability distribution , the class probability distribution No. Elements It is expressed as:

[0041] ;

[0042] in, Represents the Euclidean distance; the source domain prototype is obtained by a method similar to the above formula to the target domain sample Predicted class probability distribution ;

[0043] 2.3. Measure the source domain prototype against the target domain sample by KL-divergence Predicted class probability distribution and the target domain prototype to the target domain sample Predicted class probability distribution The difference between them gives the task-level prototype alignment loss :

[0044] ;

[0045] in, represents the source domain, represents the target domain, represents the pairwise KL-divergence;

[0046] 2.4. The first-stage loss function is obtained by using the cross entropy loss of the source domain, the feature-level prototype alignment loss, and the task-level prototype alignment loss. :

[0047] ;

[0048] in, represents the cross entropy loss of the source domain.

[0049] Phase 2:

[0050] Step 3: Identify target domain specific samples;

[0051] 3.1. According to the target domain prototype, the target domain sample Predicted class probability distribution Get the predicted label based on the prototype ;

[0052] 3.2. The target domain samples Get the predicted label based on the classifier through the classifier prediction ;

[0053] 3.3. Target domain specific samples are obtained by selecting target domain samples whose predicted labels based on the classifier and the predicted labels based on the prototype are inconsistent.

[0054] Step 4: Select and label samples from the target domain specific samples to obtain a labeled target domain sample set;

[0055] 4.1. Combining the classifier-based predicted label and the prototype-based predicted label of the target domain specific sample to obtain a label pair of the target domain specific sample;

[0056] 4.2. The uncertainty of each sample under the label pair of the target domain specific sample is quantified by the difference between the highest prediction probability and the second highest prediction probability of the classifier:

[0057] ;

[0058] in, Represents the classifier for the sample The highest predicted probability, Represents the classifier for the sample The second highest predicted probability of The smaller the sample The higher the uncertainty, the higher the uncertainty; the highest uncertainty in each label pair Samples are selected to obtain a subset of uncertain samples for each label pair;

[0059] 4.3. Calculate the maximum square mean difference between the samples in the uncertain sample subset of each label pair and the samples themselves, and obtain the representativeness measure of the samples in the uncertain sample subset of each label pair:

[0060] ;

[0061] in, represents the maximum mean square difference, Represents a tag pair The uncertain sample subset, represents the radial basis function kernel, represents a feature extractor;

[0062] 4.4. Calculate the maximum square mean difference between the samples in the uncertain sample subset of each label pair and the previously selected samples belonging to the same label pair to obtain the diversity measure of the samples in the uncertain sample subset of each label pair; subtract the diversity measure of the samples in the uncertain sample subset of each label pair from the representative measure of the samples in the uncertain sample subset of each label pair to obtain the comprehensive measure of the samples in the uncertain sample subset of each label pair:

[0063] ;

[0064] in, Represents a comprehensive measure, Indicates that it was previously selected and belongs to the tag pair The set of all samples of ; the sample with the smallest comprehensive metric in the uncertain sample subset of each label pair is handed over to experts for labeling to obtain a labeled target domain sample set.

[0065] Step 5: The second stage loss function is obtained by using the cross entropy loss of the labeled target domain sample set, the feature-level prototype alignment loss of the labeled target domain sample set and the first stage loss function: :

[0066] ;

[0067] in, represents the cross entropy loss of the labeled target domain sample set, represents the feature-level prototype alignment loss of the labeled target domain sample set.

[0068] Phase 3:

[0069] Step 6: Obtain the category frequency of the target domain through the labeled target domain sample set and the unlabeled target domain sample set;

[0070] 6.1. Determine the number of samples in each category in the labeled target domain sample set:

[0071] ;

[0072] in, Indicates that the labeled target domain sample set belongs to the category The number of samples, represents the labeled target domain sample set, represents the indicator function;

[0073] 6.2. The predicted probability of the classifier for the unlabeled target domain sample set is calculated by weighted calculation to obtain the number of samples in each category in the unlabeled target domain sample set:

[0074] ;

[0075] in, Indicates that the unlabeled target domain sample set belongs to the category The number of samples, represents the unlabeled target domain sample set, represents the classifier, express Dimensional vector The output after softmax is Elements:

[0076] ;

[0077] 6.3. The labeled target domain sample set belongs to the category The number of samples and the number of samples in the unlabeled target domain sample set belonging to the category Add the number of samples of the target domain and divide it by the total number of samples in the target domain to get the category frequency of the target domain:

[0078] ;

[0079] in, Represents the category in the target domain The frequency, Represents the number of samples in the labeled target domain sample set.

[0080] Step 7: Obtain a target domain sample set for class-balanced self-training through the category frequency of the target domain;

[0081] 7.1. The sampling ratio from the samples of the lowest frequency category is Samples of

[0082] 7.2. Calculate the sampling ratio of samples of the more frequent categories:

[0083] ;

[0084] in, Indicates category The sampling ratio, represents the frequency of the category with the lowest category frequency, Indicates control category The sampling ratio parameters;

[0085] 7.3. Sample the samples with the highest classifier prediction probability from each category of samples to obtain the target domain sample set for class-balanced self-training.

[0086] Step 8: Obtain the third stage loss function by using the cross entropy loss of the target domain sample set for class-balanced self-training and the second stage loss function :

[0087] ;

[0088] in, represents the cross entropy loss on the set of target domain samples used for class-balanced self-training.

[0089] The following table compares the deep neural network classification model obtained by the active domain adaptation classification method for hyperspectral images based on prototype alignment and class balance training in the present invention with the prior art active adversarial domain adaptation (AADA), selection by unique margin (SDM), label distribution matching by density-aware active sampling (LAMDA), local context-aware active domain adaptation (LADA), domain adaptation based on contrastive learning of category matching (CLCM), category prototype guided alignment network (CPGAN), masked self-distillation domain adaptation (MSDA), and domain adaptation from easy to difficult with human expert intervention (IEH-DA) in the following ways: In order to compare the classification effects of the active domain adaptation method and the hyperspectral image classification method, this embodiment selects three pairs of cross-domain data sets: University of Pavia and Pavia Center (Pavia), Houston 2013 and Houston 2018 (Houston), Shanghai and Hangzhou (Shanghai-Hangzhou), and uses the above methods to classify the target domain of the selected cross-domain data sets and obtain the classification accuracy. At the same time, the deep neural network classification model obtained by the hyperspectral image active domain adaptation classification method (PCADA for short) based on prototype alignment and class balance training described in this application is also used to further compare the classification accuracy of the target domain data sets involved in this embodiment. To ensure the fairness of the comparison, all methods use 180 labeled samples of each category randomly selected in the source domain and all unlabeled target domain samples for training. For the Pavia cross-domain data set, 30 samples are selected from the target domain for annotation, while for the Houston and Shanghai-Hangzhou cross-domain data sets, the number of labeled target domain samples is 40. The experiment is repeated ten times to eliminate the influence of random sampling. The experimental results use overall classification accuracy (OA), average classification accuracy (AA) and Kappa coefficient as measurement indicators. The higher the values ​​of the three indicators, the better the classification performance. The results are shown in the figure below. On the Pavia cross-domain dataset, PCADA's OA is 95.06 0.57(%), which is 10.39% - 1.56% higher than other methods. On the Houston cross-domain dataset, PCADA’s OA is 85.24 2.01(%), which is 25.63% - 2.61% higher than other methods. On the Shanghai-Hangzhou cross-domain dataset, PCADA also achieved the best classification performance compared with other comparison methods. In addition, AA and Kappa of the present invention are also significantly improved.

[0090] Through Figure 2 The first validation data set used to verify the effectiveness of the algorithm proposed in the present invention is shown. The data set provides training samples and test samples for the algorithm proposed in the present invention, wherein: Figure 2(a) is a false color image of the University of Pavia, which provides training data for the algorithm proposed in this invention; Figure 2 (b) is the true value label of the University of Pavia, which provides supervision information for the algorithm proposed in this invention; Figure 2 (c) is a false color image of the center of Pavia, which provides training data and test data for the algorithm proposed in the present invention; Figure 2 (d) is the true value label of the Pavia center, which is used to evaluate the performance of the algorithm proposed in this invention.

[0091] Further, such as Figure 3 The second validation data set used to verify the effectiveness of the algorithm proposed in the present invention is shown. The data set provides training samples and test samples for the algorithm proposed in the present invention. Figure 3 (a) is a false color image of Houston 2013, which provides training data for the algorithm proposed in the present invention; Figure 3 (b) is the Houston 2013 true value label, which provides supervision information for the algorithm proposed in this invention; Figure 3 (c) is a false color image of Houston 2018, which provides training data and test data for the algorithm proposed in the present invention; Figure 3 (d) is the Houston 2018 true value label, which is used to evaluate the performance of the algorithm proposed in this invention.

[0092] Furthermore, Figure 4 The third validation data set used to verify the effectiveness of the algorithm proposed in the present invention is shown. The data set provides training samples and test samples for the algorithm proposed in the present invention. Figure 4 (a) is a false color image of Shanghai, which provides training data for the algorithm proposed in the present invention; Figure 4 (b) is the Shanghai true value label, which provides supervision information for the algorithm proposed in this invention; Figure 4 (c) is a false color image of Hangzhou, which provides training data and test data for the algorithm proposed in the present invention; Figure 4 (d) is the Hangzhou true value label, which is used to evaluate the performance of the algorithm proposed in this invention.

[0093] like Figure 5 The classification results of the algorithm proposed in this invention are shown, where: Figure 5 (a) is the classification effect of the algorithm proposed in this invention on the Pavia center, Figure 5 (b) is the classification effect of the algorithm proposed in this invention on Houston 2018. Figure 5 (c) is the classification effect of the algorithm proposed in this invention on Hangzhou.

[0094] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device.

[0095] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. A hyperspectral image active domain adaptation classification method based on prototype alignment, characterized in that: The following steps are involved: Step 1: Assign pseudo labels to target domain samples to obtain target domain prototypes; Step 2: Obtain the first-stage loss function through the cross entropy loss of the source domain, the feature-level prototype alignment loss, and the task-level prototype alignment loss; Step 3: Identify target domain specific samples; Step 4: Select and label samples from the target domain specific samples to obtain a labeled target domain sample set; Step 5: Obtain a second-stage loss function by using the cross entropy loss of the labeled target domain sample set, the feature-level prototype alignment loss of the labeled target domain sample set, and the first-stage loss function; Step 6: Obtain the category frequency of the target domain through the labeled target domain sample set and the unlabeled target domain sample set; Step 7: Obtain a target domain sample set for class-balanced self-training through the category frequency of the target domain; Step 8: Obtain a third-stage loss function by using the cross entropy loss of the target domain sample set for class-balanced self-training and the second-stage loss function.

2. The active domain adaptation classification method for hyperspectral images based on prototype alignment according to claim 1 is characterized in that: The step 1 specifically The following steps are involved: 1.

1. Obtain source domain prototype through source domain samples: ; in, Indicates category The source domain prototype, Indicates that it belongs to the category The number of source domain samples, Indicates all belonging to the category The source domain samples L2 normalized feature vector of samples; 1.

2. Use the classifier to predict the target domain sample and obtain the first pseudo label; 1.

3. Obtain the remaining pseudo labels based on the source domain prototype closest to the target domain sample and K source domain samples; 1.

4. Filter the target domain samples whose first pseudo-label is the same as the remaining pseudo-labels to obtain high-confidence target domain samples; obtain the target domain prototype through the high-confidence target domain samples: ; in, Indicates category The target domain prototype, Indicates that it belongs to the category The number of target domain samples, Indicates all belonging to the category In the target domain sample The L2-normalized feature vector of samples.

3. The active domain adaptation classification method for hyperspectral images based on prototype alignment according to claim 2 is characterized in that: The step 2 specifically The following steps are involved: 2.

1. According to the distance between each sample and the source domain prototype and the target domain prototype of its category, the feature-level prototype alignment loss is obtained : ; in, represents the number of source domain samples, Indicates The L2-normalized feature vector of source domain samples, Indicates The labels of source domain samples, represents the number of high confidence target domain samples, Indicates The L2 normalized feature vector of the high confidence target domain samples, Indicates Pseudo labels of the high-confidence target domain samples; 2.

2. Target Domain Samples The distance between the target domain prototype and each category is input into the softmax function to obtain the distance between the target domain prototype and the target domain sample. Predicted class probability distribution , the class probability distribution No. Elements It is expressed as: ; in, Represents the Euclidean distance; the source domain prototype is obtained by a method similar to the above formula to the target domain sample Predicted class probability distribution ; 2.

3. Measure the source domain prototype against the target domain sample by KL-divergence Predicted class probability distribution and the target domain prototype to the target domain sample Predicted class probability distribution The difference between them gives the task-level prototype alignment loss : ; in, represents the source domain, represents the target domain, represents the pairwise KL-divergence; 2.

4. The first-stage loss function is obtained by using the cross entropy loss of the source domain, the feature-level prototype alignment loss, and the task-level prototype alignment loss. : ; in, represents the cross entropy loss of the source domain.

4. The active domain adaptation classification method for hyperspectral images based on prototype alignment according to claim 3 is characterized in that: The step 3 is specifically The following steps are involved: 3.

1. According to the target domain prototype, the target domain sample Predicted class probability distribution Get the predicted label based on the prototype ; 3.

2. The target domain samples Get the predicted label based on the classifier through the classifier prediction ; 3.

3. Target domain specific samples are obtained by selecting target domain samples whose predicted labels based on the classifier and the predicted labels based on the prototype are inconsistent.

5. The active domain adaptation classification method for hyperspectral images based on prototype alignment according to claim 4 is characterized in that: The step 4 specifically comprises the following steps: 4.

1. Combining the classifier-based predicted label and the prototype-based predicted label of the target domain specific sample to obtain a label pair of the target domain specific sample; 4.

2. The uncertainty of each sample under the label pair of the target domain specific sample is quantified by the difference between the highest prediction probability and the second highest prediction probability of the classifier: ; in, Represents the classifier for the sample The highest predicted probability, Represents the classifier for the sample The second highest predicted probability is The smaller the sample The higher the uncertainty, the higher the uncertainty; the highest uncertainty in each label pair Samples are selected to obtain a subset of uncertain samples for each label pair; 4.

3. Calculate the maximum square mean difference between the samples in the uncertain sample subset of each label pair and the samples themselves, and obtain the representativeness measure of the samples in the uncertain sample subset of each label pair: ; in, represents the maximum mean squared difference, Represents a tag pair The uncertain sample subset, represents the radial basis function kernel, represents a feature extractor; 4.

4. Calculate the maximum square mean difference between the samples in the uncertain sample subset of each label pair and the previously selected samples belonging to the same label pair to obtain the diversity measure of the samples in the uncertain sample subset of each label pair; subtract the diversity measure of the samples in the uncertain sample subset of each label pair from the representative measure of the samples in the uncertain sample subset of each label pair to obtain the comprehensive measure of the samples in the uncertain sample subset of each label pair: ; in, Represents a comprehensive measure, Indicates that it was previously selected and belongs to the tag pair The set of all samples of ; the sample with the smallest comprehensive metric in the uncertain sample subset of each label pair is handed over to experts for labeling to obtain a labeled target domain sample set.

6. The active domain adaptation classification method for hyperspectral images based on prototype alignment according to claim 5 is characterized in that: The second stage loss function of step 5 : ; in, represents the cross entropy loss of the labeled target domain sample set, represents the feature-level prototype alignment loss of the labeled target domain sample set.

7. The active domain adaptation classification method for hyperspectral images based on prototype alignment according to claim 6 is characterized in that: The step 6 specifically The following steps are involved: 6.

1. Determine the number of samples in each category in the labeled target domain sample set: ; in, Indicates that the labeled target domain sample set belongs to the category The number of samples, represents the labeled target domain sample set, represents the indicator function; 6.

2. The predicted probability of the classifier for the unlabeled target domain sample set is calculated by weighted calculation to obtain the number of samples in each category in the unlabeled target domain sample set: ; in, Indicates that the unlabeled target domain sample set belongs to the category The number of samples, represents the unlabeled target domain sample set, represents the classifier, express Dimensional vector The output after softmax is Elements: ; 6.

3. The labeled target domain sample set belongs to the category The number of samples and the number of samples in the unlabeled target domain sample set belonging to the category Add the number of samples of the target domain and divide it by the total number of samples in the target domain to get the category frequency of the target domain: ; in, Represents the category in the target domain The frequency, Represents the number of samples in the labeled target domain sample set.

8. The active domain adaptation classification method for hyperspectral images based on prototype alignment according to claim 7 is characterized in that: The step 7 specifically includes the following steps: 7.

1. The sampling ratio from the samples of the lowest frequency category is Samples of 7.

2. Calculate the sampling ratio of samples of the more frequent categories: ; in, Indicates category The sampling ratio, represents the frequency of the category with the lowest category frequency, Indicates control category The sampling ratio parameters; 7.

3. Sample the samples with the highest classifier prediction probability from each category of samples to obtain the target domain sample set for class-balanced self-training.

9. The active domain adaptation classification method for hyperspectral images based on prototype alignment according to claim 8, characterized in that: The third stage loss function of step 8 : ; in, represents the cross entropy loss on the set of target domain samples used for class-balanced self-training.

10. A computer program product comprising computer program instructions, characterized in that When the computer program instructions are executed on a computer, the computer is caused to perform the method according to any one of claims 1 to 9.

Citation Information

Patent Citations

  • Domain adaptation image classification method based on feature and label space dynamic alignment

    CN114282602A

  • Image classification method and system based on label noise domain self-adaption

    CN114842267A

  • Hyperspectral image cross-domain classification method based on multi-level feature alignment

    CN116188830A

  • Image classification method and system based on potential domain and category diversity

    CN119251605A

  • Method and device for domain adaptation training of neural network

    JP2024125219A