A few-shot class-incremental image classification method based on meta-learning
By pre-training the feature extractor in the base stage and introducing feature compaction constraints, embedding the adapter module for meta-learning training, and combining pseudo-few-shot task and knowledge distillation loss, the problem of model generalization difficulty in incremental image classification of few-shot classes is solved, and the accuracy and structural consistency of the model in new category recognition are improved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- NANJING UNIV
- Filing Date
- 2026-04-28
- Publication Date
- 2026-06-19
AI Technical Summary
Existing methods, in incremental image classification scenarios with few samples, have a limited number of new category samples, making it difficult for the model to form a category representation with good generalization, thus affecting the accurate recognition ability of new category images.
The feature extractor is pre-trained in the base stage and a feature compaction constraint is introduced. The adapter module is then embedded for meta-learning training. The adapter module parameters are optimized by combining pseudo-few-shot task and knowledge distillation loss. The feature extractor is frozen in the incremental stage, and only the adapter and classifier are updated. Finally, the adapter parameters are fused into the feature extractor.
It improves the model's classification performance in continuous learning scenarios, reduces the forgetting of old category knowledge, and maintains the consistency of model structure and adaptability to new categories.
Smart Images

Figure CN122244557A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to a few-shot incremental image classification method based on meta-learning, belonging to the fields of computer vision and continuous learning in computer technology. It is particularly suitable for image classification scenarios where the training categories are continuously expanded and the number of training samples for new categories is limited. Background Technology
[0002] Image classification is a classic task in computer vision, with wide applications in intelligent security, industrial inspection, medical assisted diagnosis, and robot perception. With the development of deep learning technology, image classification models have achieved high recognition accuracy under fixed datasets and offline training conditions. However, traditional image classification methods typically assume that all training data is available before training begins and that the category set remains unchanged, making it difficult to adapt to the open environment of real-world applications where categories continuously increase and data arrives gradually.
[0003] To address the problem of models forgetting knowledge of old categories during the sequential learning of new categories, researchers have proposed class incremental continuous learning methods. Existing methods can be broadly categorized into regularization-based methods, replay-based methods, and structure-based methods. Regularization-based methods mitigate forgetting by limiting changes in model parameters; replay-based methods aid training by preserving some historical samples; and structure-based methods reduce interference between new and old knowledge by adding additional modules.
[0004] However, existing methods still have significant shortcomings in incremental image classification scenarios with few samples. Due to the limited number of new category samples, the model struggles to form a class representation with good generalization, thus affecting its ability to accurately identify new category images. Summary of the Invention
[0005] Purpose of the invention: To address the problems and shortcomings of existing technologies, this invention provides a few-sample incremental image classification method based on meta-learning, which solves the problem that class representation is difficult to generalize under conditions where there are very few new class samples.
[0006] To address the problem of extremely few new class samples in incremental image classification, making it difficult for the model to form a class representation with good generalization, this method first pre-trains the feature extractor using a base class training set, obtaining a more suitable basic feature representation for subsequent incremental learning through feature compaction constraints. Then, an adapter module is embedded into the feature extractor, and a pseudo-few-shot task is constructed using the base class training set to perform meta-learning training on the adapter module, thereby obtaining initial parameters suitable for subsequent few-shot incremental stages. In subsequent incremental stages, the feature extractor is frozen, and the adapter is trained using a combination of classification loss and knowledge distillation loss. After each incremental stage, the adapter module parameters are reparameterized and fused into the corresponding layer of the feature extractor.
[0007] Technical solution: A few-shot incremental image classification method based on meta-learning, mainly including the following steps: Step 1: Obtain image samples corresponding to the image classification task as the base class training set. and the current incremental phase with a small number of training samples An image classification model is constructed, which includes a feature extractor. Adapter module and classifier ; Step 2, using the base class training set For the feature extractor Pre-training is performed, and feature compaction constraints and a sharpness-aware minimization-based optimization strategy are introduced to obtain image base feature representations suitable for subsequent incremental learning; Step 3, in the feature extractor Insert an adapter module and utilize the base class training set. Construct a pseudo-few-shot task for the adapter module. Perform meta-learning training to obtain the initial parameters of the adapter. ; Step 4, when the current incremental stage training set is received At that time, expand the classifier The output dimension, and utilize the adapter initial parameters. Initialize the current stage adapter module ; Step 5: Freeze the feature extractor in the current incremental phase. Only update the adapter module. and classifier Incremental learning is performed on a small number of new category image samples; Step 6: Introduce knowledge distillation constraints during incremental learning to mitigate the forgetting of old category knowledge; Step 7: After the current incremental training phase is completed, the parameters of the adapter module are reparameterized and fused into the feature extractor. In the corresponding layer, the trained image classification model is obtained. Step 8: Obtain the image to be classified, input the image to be classified into the trained image classification model, and output the image classification result.
[0008] Furthermore, in step 2, the image samples in the current training batch are processed by the feature extractor to obtain corresponding image sample features, and the category mean features are calculated based on the image sample features of the same category. A feature set is constructed using the image sample features and category mean features in the current training batch. And construct a feature compaction loss function based on the feature set. The feature compaction loss function is used to constrain the distribution of features of the same category to be more concentrated, reduce the excessive dispersion of the feature space in the base stage, thereby making the learned feature representation more compact and reserving more sufficient representation space for subsequent expansion of the representation of new categories.
[0009] in, and For feature set The feature vector in The similarity between feature vectors For temperature coefficient, This refers to the sofmax function.
[0010] Furthermore, in step 2, after calculating the cross-entropy classification loss function and the feature compactness loss function, the two are weighted and combined to obtain the base-stage total loss function. in, Let cross-entropy be the classification loss function. The feature compact loss weight coefficient is used.
[0011] Furthermore, in step 2, the optimization strategy based on sharpness-perceived minimization is as follows: first, based on the current feature extractor parameters... and base phase total loss function The gradient is used to calculate the perturbation. in, The disturbance radius is... This represents the gradient of the total loss function in the base stage; then, in the feature extractor parameters... Add perturbation Then, the base stage total loss function is recalculated, and the feature extractor parameters are updated based on the recalculated base stage total loss function.
[0012] Furthermore, in step 3, from the base class training set Two image samples from different categories are selected, and pseudo-few-shot task samples are generated through linear interpolation. Using the generated pseudo-few-shot task samples Multiple pseudo-few-shot tasks are constructed, and then the adapter parameters are updated for each pseudo-few-shot task. Finally, based on the adapter parameter update results of each pseudo-few-shot task, the initial adapter parameters are meta-updated. The meta-update method is as follows: in, and For image samples from different categories, For the generated pseudo-few sample task samples , These are the interpolation coefficients. For the first The adapter parameters are updated after a pseudo-few-samples task. To update the learning rate for the meta-level, This is for the number of pseudo-small sample tasks.
[0013] Furthermore, in step 4, when the current incremental phase training set is received... First, the output dimension of the classifier is expanded to accommodate the new category. For each new category, the corresponding classification weights are initialized using the feature mean of the samples of that category in the current incremental training set, denoted as, Indicates image samples Input Feature Extractor This yields the feature representation of the sample.
[0014] Furthermore, in steps 5 and 6, under the condition of freezing the feature extractor parameters, the incremental stage total loss function is constructed using the cross-entropy classification loss function and the knowledge distillation loss function to update the adapter module and classifier parameters. The incremental stage total loss function is expressed as follows: in, For category The corresponding classification weights For category The number of training samples, It is an indicator function.
[0015] Further, in step 6, the knowledge distillation constraint is implemented through a knowledge distillation loss function, specifically limiting the difference in output distribution between the current stage model and the previous stage model on the old categories, so that the current stage model maintains consistency with the previous stage model in the output of the old categories while learning new category knowledge. The knowledge distillation loss function is defined as follows: in, This represents the number of samples in the current batch. For the old category quantity, For the previous stage model, the first stage... One sample in the old category The output probability on For the current stage model, the first One sample in the old category The output probability.
[0016] Furthermore, in step 6, the total loss function for the incremental stage is defined as follows: in, Let cross-entropy be the classification loss function. For the knowledge distillation loss function, This is the weighting coefficient for knowledge distillation loss.
[0017] Furthermore, in step 7, the parameters of the adapter module are fused into the feature extractor. The process for the corresponding layer is as follows: in, These are the parameters of the corresponding layer in the previous stage feature extractor. These are the adapter parameters for the current stage. For adapter fusion weights, This is a parameter mapping function used for dimension alignment.
[0018] A computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the few-shot incremental image classification method based on meta-learning as described above.
[0019] Compared with existing technologies, the beneficial effects of this invention are as follows: This invention obtains a more suitable basic feature representation for subsequent incremental learning by introducing a feature compaction loss function in the base stage. By constructing a pseudo-few-shot task using the base class training set and performing meta-learning training on the adapter module, it provides initial parameters for adapting to new categories in subsequent incremental stages. By updating only the adapter module and classifier in the current incremental stage and introducing knowledge distillation constraints, it effectively alleviates the forgetting of old category knowledge. By fusing the adapter parameters into the corresponding layer of the feature extractor after training, it improves the classification performance of the image classification model in continuous learning scenarios while maintaining the consistency of the model structure during the testing stage. Attached Figure Description
[0020] Figure 1 This is a flowchart of the method steps in an embodiment of the present invention; Figure 2 This is a flowchart of the base phase training process in an embodiment of the present invention; Figure 3 This is a flowchart of the incremental training process in an embodiment of the present invention. Detailed Implementation
[0021] The present invention will be further illustrated below with reference to specific embodiments. It should be understood that these embodiments are for illustrative purposes only and are not intended to limit the scope of the invention. After reading the present invention, any modifications of the present invention in various equivalent forms by those skilled in the art will fall within the scope defined by the appended claims.
[0022] like Figure 1 As shown, a few-shot incremental image classification method based on meta-learning includes the following steps: Step 1: Obtain the base class training set corresponding to the image classification task. And the current incremental phase with a small number of training samples An image classification model is constructed, which includes a feature extractor. Adapter module and classifier The input image is first processed by the feature extractor. At one or more feature transformation layers of the feature extractor, the adapter module transforms the intermediate features output by the corresponding layer in parallel to obtain adaptive features, which are then combined with the original intermediate features. The combined features are then input into subsequent layers of the feature extractor, and finally, the classifier outputs the image category prediction result.
[0023] Step 2, using the base class training set For the feature extractor Pre-training is performed, and feature compaction constraints and a sharpness-aware minimization-based optimization strategy are introduced to obtain basic feature representations suitable for subsequent incremental learning; Step 3, in the feature extractor Insert adapter module and using the base class training set Construct a pseudo-few-shot task for the adapter module. Perform meta-learning training to obtain the initial parameters of the adapter. ; Step 4, when the current incremental phase of the few-sample training set is received At that time, expand the classifier The output dimension is adjusted to accommodate the new category, and the adapter initial parameters are utilized. Initialize the adapter module for the current stage; Step 5: Freeze the feature extractor in the current incremental phase. Only update the adapter module. and classifier This is to complete incremental learning of image samples of new categories; Step 6: Introduce knowledge distillation constraints during incremental learning to mitigate the forgetting of old category knowledge; Step 7: After the current incremental training phase is completed, fuse the parameters of the adapter module into the feature extractor. In the corresponding layer, the knowledge of the current stage is accumulated into the parameters of the backbone network, and the model structure is kept consistent during the testing stage. Step 8: Obtain the image to be classified, input the image to be classified into the trained image classification model, and output the corresponding image classification result.
[0024] In this embodiment, the feature extractor Used to extract feature representations from input images, which can specifically employ ResNet, Vision Transformer, or other deep neural network architectures suitable for image classification tasks. Classifier The adapter module is used to locally adjust the existing feature representations during the incremental phase, outputting the class prediction results. By pre-training the feature extractor and introducing feature compaction constraints during the base phase, the model can obtain a more suitable basic representation for subsequent incremental learning and retain a more sufficient representation space for learning new classes. By freezing the feature extractor during the incremental phase and updating only the adapter module and classifier parameters, the model's adaptability to new class samples can be improved while preserving existing knowledge as much as possible.
[0025] Reference Figure 2 As shown, step 2 specifically includes the following steps: Step 2.1, Set the batch size for the base phase training. Learning rate Maximum number of training epochs, feature compactness loss weight coefficient and the perturbation radius in sharpness perception minimization ; Step 2.2, base class training set By batch size Divided into multiple training batches; Step 2.3: Extract image samples from the current training batch sequentially and use the feature extractor. The corresponding feature representations are obtained and used as sample features; Step 2.4: Calculate the image category mean features for each category based on the sample features in the current training batch, and combine the sample features and the category mean features to form a feature set. ; Step 2.5, based on feature set Computational feature compact loss ; Step 2.6: Calculate the classification loss based on the labels of the current training batch samples. ; Step 2.7, Construct the base stage total loss function ; Step 2.8: Based on the total loss function of the base stage, update the feature extractor parameters using a sharpness-aware minimization optimization strategy; Step 2.9: Determine whether all training batches in the current round have been processed; if not, extract the next training batch and return to step 2.3; if yes, proceed to step 2.10. Step 2.10: Determine if the current training epoch has reached the preset value; if not, adjust the learning rate and return to step 2.2; if yes, output the trained feature extractor. .
[0026] Specifically, in the current training batch, the feature extractor is used. Extract image sample features and calculate the category mean features for each category within the current batch. To avoid excessive dispersion of the feature space, combine the sample features and category mean features into a feature set. And based on the feature set, a feature compaction loss function is constructed. in, and For feature set The feature vector in Indicates the similarity between feature vectors. This is the temperature coefficient.
[0027] In this embodiment, the total loss function of the base stage can be expressed as, in, For classification loss function, represents the weighting coefficients for the feature compact loss.
[0028] Furthermore, to improve the flatness and generalization ability of the feature representations learned in the base stage, this embodiment employs a sharpness-aware minimization optimization strategy during base stage training. First, based on the current parameters... and base phase total loss function The gradient is used to calculate the perturbation. in, Let be the perturbation radius. Then, in the perturbation parameters... The loss is recalculated, and the feature extractor parameters are updated accordingly.
[0029] Through the above process, the feature representations learned in the base stage can be made more compact, thereby alleviating the problem of excessive dispersion of the base class feature space and reserving more sufficient representation expansion space for the subsequent introduction of new categories with fewer samples.
[0030] After completing step 2, proceed to step 3. Step 3 specifically includes the following steps: Step 3.1, from the base class training set Two image samples from different categories are selected, and task samples are generated through linear interpolation. Step 3.2: Construct multiple pseudo-few-shot tasks using the task samples; Step 3.3, in the feature extractor An adapter module is inserted into one or more feature transformation layers, and the parameters of the adapter module are initialized. Step 3.4: Update the adapter parameters for each pseudo-few-shot task; Step 3.5: Based on the updated adapter parameters from each pseudo-few-samples task, perform a meta-update on the adapter initial parameters to obtain the adapter initial parameters. .
[0031] Specifically, the task sample can be represented as in, and For image samples from different categories, These are the interpolation coefficients.
[0032] In this embodiment, the adapter module can be disposed in the feature extractor. In the intermediate feature transformation layer, the corresponding layer output features are received and adapted features are generated. These adapted features are then combined with the original features to achieve local adjustment of the feature representation without significantly changing the backbone parameters. By utilizing multiple pseudo-few-shot tasks constructed from the base class training set, the subsequent few-shot incremental learning scenario can be simulated in the base stage, allowing the adapter module to learn initialization parameters suitable for rapid adaptation to new categories in advance.
[0033] Let the first The adapter parameters updated after the pseudo-few-samples task are: The meta-update method for the adapter's initial parameters can be expressed as follows: in, To update the learning rate for the meta-level, This refers to the number of pseudo-few sample tasks.
[0034] Through the above meta-learning training process, the adapter module can obtain initial parameters with strong generalization ability, thus enabling it to adapt more quickly when faced with fewer samples of new categories in the subsequent incremental stage.
[0035] Reference Figure 3As shown, after obtaining the adapter's initial parameters Then, proceed with steps 4 through 8.
[0036] When receiving a small training set of samples in the current incremental phase At that time, firstly, the classifier The output dimension is expanded to accommodate new categories; the classification weights of the existing categories remain unchanged, and only the new categories have corresponding output units added. Then, the current incremental training set is used... The classification weights corresponding to the new categories are initialized using the feature mean of each new category sample, and are expressed as follows: in, For category The corresponding classification weights For category The number of training samples, This is an indicator function that indicates whether a data label belongs to a certain category.
[0037] After completing the classifier expansion, utilize the adapter initial parameters. Initialize the adapter module for the current stage. Freeze the feature extractor during the current incremental stage. The parameters are updated only for the adapter module and the classifier. The parameters are adjusted to maintain the basic representation capabilities learned in the base stage as much as possible, and to improve the adaptability to new categories of image samples in the current stage.
[0038] Furthermore, to mitigate the forgetting of old category knowledge, a knowledge distillation constraint is introduced during the current incremental training phase. Specifically, the model trained in the previous phase is used as the teacher model, and the model in the current phase is used as the student model. The output distribution of the input samples in the current phase on the old categories is constrained, ensuring that the student model maintains consistency with the teacher model's output on the old categories while learning new category knowledge. The knowledge distillation loss function is defined as follows: in, This represents the number of samples in the current batch. For the old category quantity, For the previous stage model, the first stage... One sample in the old category The output probability on For the current stage model, the first One sample in the old category The output probability.
[0039] In this embodiment, the total loss function in the incremental stage can be expressed as: in, For classification loss function, For the knowledge distillation loss function, This is the weighting coefficient for knowledge distillation loss.
[0040] By freezing the feature extractor during the incremental phase and updating only the adapter module and classifier, the overall parameter perturbation can be reduced. Furthermore, constraining the old class output distribution through knowledge distillation can mitigate the damage to old class knowledge caused by current-phase training, thereby alleviating the catastrophic forgetting problem.
[0041] After the current incremental training phase is completed, the parameters of the adapter module will be fused into the feature extractor. In the corresponding layer, knowledge from the current stage is accumulated into the parameters of the backbone network, while maintaining the consistency of the model structure during the testing phase. The parameter reparameterization and fusion process can be represented as follows: in, These are the parameters of the corresponding layer in the previous stage feature extractor. These are the adapter parameters for the current stage. For adapter fusion weights, This is a parameter mapping function used for dimension alignment.
[0042] After parameter reparameterization and fusion are completed, the image to be classified is obtained. This image is then input into the trained image classification model to output the image classification result. Since the adapter parameters are already fused to the corresponding layer of the feature extractor, no additional independent adapter branch needs to be attached during the testing phase. This allows for effective support of continuous learning image classification tasks while maintaining a consistent model structure during testing.
[0043] Obviously, those skilled in the art should understand that the steps of the few-shot incremental image classification method based on meta-learning in the above embodiments of the present invention can be implemented using general-purpose computing devices. They can be centralized on a single computing device or distributed across a network of multiple computing devices. Optionally, they can be implemented using device-executable program code, thereby storing them in a storage device for execution by a computing device. Furthermore, in some cases, the steps shown or described can be performed in a different order than presented herein, or they can be fabricated as separate integrated circuit modules, or multiple modules or steps can be fabricated as a single integrated circuit module. Thus, the embodiments of the present invention are not limited to any particular hardware and software combination.
Claims
1. A few-shot incremental image classification method based on meta-learning, characterized in that, Includes the following steps: Step 1: Obtain the base class training set and the few-sample training set for the current incremental stage corresponding to the image classification task, and construct an image classification model, which includes a feature extractor, an adapter module and a classifier; Step 2: Pre-train the feature extractor using the base class training set, and introduce feature compaction constraints and a sharpness-aware minimization optimization strategy to obtain image base feature representations suitable for subsequent incremental learning; Step 3: Insert an adapter module into the feature extractor, construct a pseudo-few-shot task using the base class training set, perform meta-learning training on the adapter module, and obtain the initial parameters of the adapter. Step 4: When the current incremental stage training set is received, expand the output dimension of the classifier and initialize the current stage adapter module using the adapter initial parameters; Step 5: Freeze the feature extractor in the current incremental phase, update only the adapter module and classifier, and perform incremental learning on a small number of new category image samples; Step 6: Introduce knowledge distillation constraints during incremental learning to mitigate the forgetting of old category knowledge; Step 7: After the current incremental training phase is completed, the parameters of the adapter module are reparameterized and fused into the corresponding layer of the feature extractor; thus obtaining the trained image classification model. Step 8: Obtain the image to be classified, input the image to be classified into the trained image classification model, and output the image classification result.
2. The few-shot incremental image classification method based on meta-learning according to claim 1, characterized in that, In step 2, the feature extractor is pre-trained using the base class training set, and feature compaction constraints and a sharpness-aware minimization optimization strategy are introduced to obtain image basic feature representations suitable for subsequent incremental learning. Includes the following steps: Step 201: Set the batch size, learning rate, upper limit of training epochs, feature compact loss weight coefficients, and perturbation radius in sharpness-aware minimization for the base phase training. Step 202: Divide the base class training set into multiple training batches according to the batch size; Step 203: Extract image samples from the current training batch sequentially, and obtain the feature representations corresponding to the image samples through the feature extractor, which are used as sample features; Step 204: Calculate the class mean features of each image category based on the sample features in the current training batch, and combine the sample features and the class mean features to form a feature set; Step 205: Calculate the feature compactness loss based on the feature set. ; Step 206: Calculate the classification loss based on the labels of the current training batch samples. ; Step 207, Construct the base stage total loss function ; , The feature compactness loss weight coefficients; Step 208: Based on the total loss function of the base stage, update the feature extractor parameters using a sharpness-aware minimization optimization strategy; Step 209: Determine whether all training batches in the current round have been processed; if not, extract the next training batch and return to step 203; if yes, proceed to step 210. Step 210: Determine whether the current training rounds have reached the preset value; if not, adjust the learning rate and return to step 202; if yes, output the trained feature extractor.
3. The few-shot incremental image classification method based on meta-learning according to claim 2, characterized in that, Construct a feature compaction loss function based on the aforementioned feature set. in, and For feature set The feature vector in Indicates the similarity between feature vectors. This is the temperature coefficient.
4. The few-shot incremental image classification method based on meta-learning according to claim 1, characterized in that, Step 3 involves inserting an adapter module into the feature extractor, constructing a pseudo-few-shot task using the base class training set, and performing meta-learning training on the adapter module to obtain the initial parameters of the adapter. Specifically, this includes the following steps: Step 301: Select two image samples from different categories from the base class training set, and generate task samples through linear interpolation; Step 302: Construct multiple pseudo-few-sample tasks using the task samples; Step 303: Insert an adapter module into one or more feature transformation layers of the feature extractor and initialize the adapter module parameters; Step 304: Update the adapter parameters for each pseudo-few-samples task; Step 305: Based on the updated adapter parameters of each pseudo-few-samples task, perform meta-update on the adapter initial parameters to obtain the adapter initial parameters.
5. The few-shot incremental image classification method based on meta-learning according to claim 4, characterized in that, The task sample is represented as in, and For image samples from different categories, These are the interpolation coefficients.
6. The few-shot incremental image classification method based on meta-learning according to claim 4, characterized in that, The adapter module is located in the intermediate feature transformation layer of the feature extractor. It is used to receive the output features and generate adapted features, which are then combined with the original features. Let the first The adapter parameters after the pseudo-few-samples task are: The meta-update of the adapter's initial parameters is represented as follows: in, To update the learning rate for the meta-level, To determine the number of pseudo-few sample tasks, These are the initial parameters for the adapter.
7. The few-shot incremental image classification method based on meta-learning according to claim 1, characterized in that, In step 4, when a small sample training set for the current incremental stage is received, the output dimension of the classifier is first expanded to accommodate the new categories; the classification weights corresponding to the original categories remain unchanged, and only the corresponding output units are added for the new categories; subsequently, the classification weights corresponding to the new categories are initialized using the feature mean of each new category sample in the current incremental stage training set, expressed as: in, For category The corresponding classification weights For category The number of training samples, An indicator function to indicate whether a data label belongs to a certain category, It is a feature extractor.
8. The few-shot incremental image classification method based on meta-learning according to claim 1, characterized in that, In step 6, a knowledge distillation constraint is introduced during the current incremental training phase. Specifically, the model completed in the previous training phase is used as the teacher model, and the model in the current training phase is used as the student model. The output distribution of the input samples in the current phase on the old categories is constrained, ensuring that the student model maintains consistency with the teacher model in the output of the old categories while learning new category knowledge. The knowledge distillation loss function is defined as follows: in, This represents the number of samples in the current batch. For the old category quantity, For the previous stage model, the first stage One sample in the old category The output probability on For the current stage model, the first One sample in the old category The output probability.
9. The few-shot incremental image classification method based on meta-learning according to claim 8, characterized in that, The total loss function in the incremental phase is expressed as follows: in, For classification loss function, For the knowledge distillation loss function, The weighting coefficient for knowledge distillation loss; After the current incremental training phase is completed, the parameters of the adapter module are fused into the corresponding layer of the feature extractor to accumulate knowledge from the current phase into the backbone network parameters and maintain the consistency of the model structure during the testing phase; the parameter reparameterization fusion process is expressed as follows: in, These are the parameters of the corresponding layer in the previous stage feature extractor. These are the adapter parameters for the current stage. For adapter fusion weights, This is a parameter mapping function used for dimension alignment.
10. A computer device, characterized in that: The computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the few-shot incremental image classification method based on meta-learning as described in any one of claims 1-9.