Continuous learning method and device based on innate knowledge

By introducing the loss function of generator and regularization constraints into the deep neural network, the problem of catastrophic forgetting is solved, the continuous learning ability and efficiency of the model are improved, and efficient task learning is achieved.

CN113792874BActive Publication Date: 2024-09-06TSINGHUA UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111050660.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-09-08
Publication Date
2024-09-06
Estimated Expiration
2041-09-08

AI Technical Summary

Technical Problem

Existing deep neural networks are prone to catastrophic forgetting problems during the continuous learning process, causing old task knowledge to be overwritten, making it difficult to achieve continuous learning like humans.

Method used

By introducing a generator to initialize the parameters of the neural network, and in the subsequent training process, the task 0 data generated by the generator is used for regularization constraints, combined with a specific loss function design, to limit the update of model parameters and ensure the preservation of old task parameter information. .

Benefits of technology

It effectively reduces the catastrophic forgetting problem of neural networks in continuous learning, improves the model's generalization ability and task learning efficiency, and achieves efficient learning of continuous tasks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113792874B
    Figure CN113792874B
Patent Text Reader

Abstract

The present invention proposes a continuous learning method and device based on innate knowledge, the method comprising: obtaining first training data and preprocessing the first training data; inputting the preprocessed first training data into a pre-trained generator, and outputting second training data; training the initialization parameters of the neural network model according to the second training data and the classification neural network; updating the initialization parameters of the neural network model according to the first training data and a pre-constructed loss function to obtain the updated neural network model. The present invention introduces a generator before the learning task to initialize the parameters of the neural network in advance. In the subsequent training process, the task 0 generated by the comprehensive generator and the current learning task are regularized and constrained, so that the model can converge quickly, effectively reducing the catastrophic forgetting problem faced by the neural network in continuous learning, and improving the task learning ability of the model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of computer multimedia and relates to image classification technology. Background Art

[0002] Many breakthroughs have been made in the current field of artificial intelligence. In tasks such as face recognition, speech recognition, and object detection, deep learning models can achieve a fairly high learning accuracy rate through a large amount of input-output training under supervised learning, which is more efficient than humans and achieves the purpose of application. In the target recognition task ImageNet with 1,000 categories and more than 1 million training samples, the trained deep learning network can achieve a top-1 accuracy rate of more than 80%, and the recognition speed is also much higher than that of humans. In the field of chess games, Deep Blue defeated Kasparov, and AlphaGo defeated Lee Sedol, Ke Jie, etc.

[0003] Although artificial intelligence has made so many breakthroughs, there are still great differences between existing artificial intelligence, especially deep neural networks, and the corresponding patterns of humans or human brains. Humans have the ability to apply the knowledge of one task to another task, and will not forget the previous task when learning the next task. This ability is called continuous learning ability. However, for existing artificial intelligence, especially deep neural networks, there is a natural problem of catastrophic forgetting due to their own design. Catastrophic forgetting refers to the phenomenon that when AI learns the current task B in a sequence of tasks that are unlabeled, may switch randomly, and the same task may not reappear for a long time, the knowledge of the previous task A will suddenly be lost. In simple terms, it is called catastrophic forgetting when a deep neural network model forgets the previously learned content when learning new skills. When learning a new task B, the deep neural network model needs to update the parameters in the network, but at the same time, the knowledge extracted from the previous task A is also stored in the parameters of the network. Therefore, when the neural network learns a new task, the knowledge of the old task will be overwritten. Therefore, how to enable artificial neural networks to achieve continuous learning like humans and overcome the problem of catastrophic forgetting is very important in both academic and application fields.

[0004] In order to reduce the problem of catastrophic forgetting, there are currently three common solutions. The first type of method is the data replay method based on making sample sets. This type of method is based on data. This solution is to store samples of past tasks and add sample replays to new tasks. Make a sample set and mix the sample set into the training when learning other tasks later. Since the previous data is not available for the current task, a simple solution is to store some previous samples in memory and replay them when learning each new task. In addition to directly storing real samples, some studies have proposed to achieve pseudo memory by training generative models. For example, people can train generative adversarial networks for previous tasks and use them to generate fake samples when learning new tasks. In this way, the generative model can provide infinitely diverse samples from previous tasks, which is conducive to model training. In summary, this idea mixes data into subsequent tasks, which can achieve a certain effect of fighting forgetting. However, how to select data and how much data to select to make sample sets is a problem faced by this method.

[0005] The second type of method is to design a regularization method for the loss function. This type of method starts from the update method of the neural network. This solution mainly adds a regularization term to the loss function to limit the direction of model update. Through mathematical derivation and combined with theories such as knowledge distillation, the loss function is modified to limit the direction of gradient update of the model. Catastrophic forgetting occurs because the model parameters are updated without limit. Although the model parameters adapt to the current task, they lose information about the previous task. In order to solve this problem, many studies have designed regularization terms to preserve previous knowledge. Regularization-based methods focus on the parameter update process to keep it consistent with the previously learned parameters to avoid forgetting. Compared with replay-based methods, regularization-based methods have an advantage that they usually do not require external memory to store previous data. From this perspective, they are more robust. However, parameter update in regularization methods is inflexible because it is limited to specific update positions. In addition, when there are many tasks, it is also challenging to manually set regularization weights to find the best balance between learning new tasks and memorizing old tasks.

[0006] The third type of method is the dynamic network structure method for specific tasks. This type of method starts from the neural network structure. This solution design different network structures and masks for different tasks. Modify the neural network, combine ideas such as generative adversarial networks, or add some restrictive rules or special network structure layers. Since the parameterization of deep networks is too serious, it can be assumed that not all parameters are used for one task. Based on this assumption, different sub-components in the network can be used to handle different tasks, and these sub-components can be adjusted dynamically. The method based on dynamic network structure can be regarded as training multiple sub-networks for different tasks, so that each task has little impact on another task. However, it is a rather difficult operation to adjust the architecture and migrate to different tasks.

[0007] Although existing continuous learning research has made breakthrough progress, it is still a long way from truly solving the problem of catastrophic forgetting. When the number of model learning is large and the storage space is limited, it is difficult for existing solutions to achieve very effective results. Summary of the invention

[0008] The present invention aims to solve one of the technical problems in the related art at least to a certain extent.

[0009] To this end, the first purpose of the present invention is to propose a continuous learning method based on innate knowledge to solve the problem of forgetting past tasks and slow convergence of new task models in continuous learning problems.

[0010] The second object of the present invention is to provide a device for continuous learning based on innate knowledge.

[0011] To achieve the above-mentioned purpose, the first aspect of the embodiment of the present invention proposes a method of continuous learning based on innate knowledge, including: obtaining first training data and preprocessing the first training data; inputting the preprocessed first training data into a pre-trained generator and outputting second training data; training the initialization parameters of the neural network model according to the second training data and the classification neural network; updating the initialization parameters of the neural network model according to the first training data and a pre-constructed loss function to obtain the updated neural network model.

[0012] The method of continuous learning based on innate knowledge proposed in the embodiment of the present invention introduces a generator before the learning task to initialize the parameters of the neural network in advance, effectively improving the generalization ability of the model. In the subsequent training process, the task 0 generated by the comprehensive generator and the current learning task are regularized so that the model can converge quickly and effectively reduce the catastrophic forgetting problem faced by the neural network in continuous learning, improve the task learning ability of the model, and achieve efficient learning of continuous tasks.

[0013] In addition, the method for continuous learning based on innate knowledge according to the above embodiment of the present invention may also have the following additional technical features:

[0014] Furthermore, in one embodiment of the present invention, obtaining first training data and preprocessing the first training data includes:

[0015] Perform general processing on the input data and transform it into a general row vector. The specific representation is as follows:

[0016]

[0017] Where i represents the task number, j represents the jth data under the current task i, and n represents the number of data in the current data The nth vector component under .

[0018] Furthermore, in one embodiment of the present invention, the initialization module includes:

[0019] Build a generator based on the task and data;

[0020] data The corresponding latent variable z obeys a certain distribution, and the generator is used to learn the mapping X = G(z) to achieve the conversion between the latent variable distribution z and the real data distribution P(X).

[0021]

[0022] The generator is trained and the final generator mapping is: X = G(z). A bias term B is added so that the final generator data is somewhat different from the first training data result, but both are associated with the latent variable distribution z. The final generator mapping is:

[0023] X′=G(z)+B(z);

[0024] According to the generator trained in Task 1, simulate and generate the corresponding second training data;

[0025] Assume that the task data set is A0, then the data set of task 0 is:

[0026]

[0027] in Represents the data in the simulation generation task 0 The amount of data in task 0 is t. The amount of t is related to the amount of data j in the remaining tasks. Generally, the more appropriate relationship is: t=2j.

[0028] Furthermore, in one embodiment of the present invention, the loss function limits the update of the neural network by adding regularization terms of the new task and past task model parameters and the regularization terms of the current task model parameters of task 0, so that the neural network can preserve the original task parameter information, and the parameters will not change too much with the initial parameter space, thereby achieving stronger generalization and learning capabilities. The specific loss function is designed as follows:

[0029]

[0030] Among them, θ represents With label The difference between p (θ) represents the cross entropy function obtained under the current task t, Represents learning current data After that, the model parameters are changed from H t-1 Updated t After the change of parameters, Represents the current neural network H t In the forward propagation task t data Data initialized with task 0 of the total difference.

[0031] Furthermore, in one embodiment of the present invention, after obtaining the updated neural network model, the method further includes:

[0032] Repeat all the steps of claim 1 until the classification accuracy of the neural network meets the requirements;

[0033] When there are i tasks in total, it is necessary to repeat the process for different tasks and update the model parameters. After all i training operations, the final model is obtained.

[0034] To achieve the above-mentioned purpose, another embodiment of the present invention proposes a device for continuous learning based on innate knowledge, including: a preprocessing module, used to obtain first training data and preprocess the first training data; an initialization module, used to input the preprocessed first training data into a pre-trained generator, and output second training data; a training module, used to train the initialization parameters of the neural network model according to the second training data and the classification neural network; an updating module, used to update the initialization parameters of the neural network model according to the first training data and a pre-constructed loss function to obtain the updated neural network model.

[0035] The continuous learning device based on innate knowledge proposed in the embodiment of the present invention introduces a generator before the learning task to initialize the parameters of the neural network in advance, effectively improving the generalization ability of the model. In the subsequent training process, the task 0 generated by the comprehensive generator and the current learning task are regularized, so that the model can converge quickly and effectively reduce the catastrophic forgetting problem faced by the neural network in continuous learning, improve the task learning ability of the model, and realize efficient learning of continuous tasks.

[0036] In addition, the continuous learning device based on innate knowledge according to the above embodiment of the present invention may also have the following additional technical features:

[0037] Furthermore, in one embodiment of the present invention, the preprocessing module is further used for:

[0038] Perform general processing on the input data and transform it into a general row vector. The specific representation is as follows:

[0039]

[0040] Where i represents the task number, j represents the jth data under the current task i, and n represents the number of data in the current data The nth vector component under .

[0041] Furthermore, in one embodiment of the present invention, the initialization module is further used to:

[0042] Build a generator based on the task and data;

[0043] data The corresponding latent variable z obeys a certain distribution, and the generator is used to learn the mapping X = G(z) to achieve the conversion between the latent variable distribution z and the real data distribution P(X).

[0044]

[0045] The generator is trained and the final generator mapping is: X = G(z). A bias term B is added so that the final generator data is somewhat different from the first training data result, but both are associated with the latent variable distribution z. The final generator mapping is:

[0046] X′=G(z)+B(z);

[0047] According to the generator trained in Task 1, simulate and generate the corresponding second training data;

[0048] Assume that the task data set is A0, then the data set of task 0 is:

[0049]

[0050] in Represents the data in the simulation generation task 0 The amount of data in task 0 is t. The amount of t is related to the amount of data j in the remaining tasks. Generally, the more appropriate relationship is: t=2j.

[0051] Furthermore, in one embodiment of the present invention, the initialization parameters of the neural network model are updated according to the first training data and the pre-constructed loss function to obtain the updated neural network model, wherein the loss function limits the update of the neural network by adding regularization terms of the new task and past task model parameters and the regularization terms of the task 0 in the current task model parameters, so that the neural network preserves the original task parameter information, and the parameters will not change too much with the initial parameter space, thereby achieving stronger generalization and learning capabilities. The specific loss function is designed as follows:

[0052]

[0053] Among them, θ represents With label The difference between p (θ) represents the cross entropy function obtained under the current task t, Represents learning current data After that, the model parameters are changed from H t-1 Updated t After the change of parameters, Represents the current neural network H t In the forward propagation task t data Data initialized with task 0 of the total difference.

[0054] Furthermore, in one embodiment of the present invention, after obtaining the updated neural network model, an iteration module is also included:

[0055] Repeat the updating of the neural network model until the classification accuracy of the neural network meets the requirements;

[0056] When there are i tasks in total, it is necessary to repeat the process for different tasks and update the model parameters. After all i training operations, the final model is obtained.

[0057] Additional aspects and advantages of the present invention will be given in part in the following description and in part will be obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] The above and / or additional aspects and advantages of the present invention will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:

[0059] Figure 1 A flowchart of a continuous learning method based on innate knowledge provided in an embodiment of the present invention.

[0060] Figure 2 A schematic diagram of a flow chart of a continuous learning device based on innate knowledge provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0061] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present invention, and should not be construed as limiting the present invention.

[0062] The following describes the method and device for continuous learning based on innate knowledge according to an embodiment of the present invention with reference to the accompanying drawings.

[0063] Figure 1 A flowchart of a continuous learning method based on innate knowledge provided in an embodiment of the present invention.

[0064] like Figure 1 As shown, the method for coloring nodes in a neural network includes the following steps:

[0065] S1, obtaining first training data, and preprocessing the first training data.

[0066] It can be understood that in order to better describe data information and universally handle a variety of tasks, the input data is first universally processed and transformed into a universal row vector form.

[0067] Furthermore, in one embodiment of the present invention, obtaining first training data and preprocessing the first training data include:

[0068] Perform general processing on the input data and transform it into a general row vector. The specific representation is as follows:

[0069]

[0070] Where i represents the task number, j represents the jth data under the current task i, and n represents the number of data in the current data The nth vector component under .

[0071] S2, input the preprocessed first training data into the pre-trained generator, and output the second training data.

[0072] The generator can be constructed according to the task and data. The corresponding latent variable z obeys a certain distribution, and the generator is used to learn the mapping X = G(z) to achieve the conversion between the latent variable distribution z and the real data distribution P(X).

[0073]

[0074] The generator is trained and the final generator mapping is: X = G(z). A bias term B is added so that the final generator data is somewhat different from the first training data result, but both are associated with the latent variable distribution z. The final generator mapping is:

[0075] X′=G(z)+B(z);

[0076] Further, according to the generator trained by Task 1, corresponding second training data is generated by simulation;

[0077] Assume that the task data set is A0, then the data set of task 0 is:

[0078]

[0079] in Represents the data in the simulation generation task 0 The amount of data in task 0 is t. The amount of t is related to the amount of data j in the remaining tasks. Generally, the more appropriate relationship is: t=2j.

[0080] S3, training initialization parameters of the neural network model according to the second training data and the classification neural network.

[0081] Further, in one embodiment of the present invention, the initialization parameters of the neural network model are trained according to the second training data and the classification neural network, including:

[0082] The model is trained using the Task 0 data generated by the simulation. The stochastic gradient descent method is used here to update the model parameters. The network part can be built using different network structures according to actual needs, such as ResNet, DenseNet, etc. When the model produces an accuracy rate of more than 90% for the Task 0 data generated by the simulation, the model parameters are initialized and the resulting neural network is H 0 At this point, the model has a certain degree of generalization ability and can better train subsequent tasks.

[0083] S4, updating the initialization parameters of the neural network model according to the first training data and the pre-constructed loss function to obtain an updated neural network model.

[0084] Among them, the loss function limits the update of the neural network by adding the regularization terms of the new task and past task model parameters and the regularization terms of the task 0 in the current task model parameters, so that the neural network can preserve the original task parameter information, and the parameters will not change too much from the initial parameter space, thus achieving strong generalization and learning capabilities. The specific loss function is designed as follows:

[0085]

[0086] Among them, θ represents With label The difference between p (θ) represents the cross entropy function obtained under the current task t, Represents learning current data After that, the model parameters are changed from H t-1 Updated t After the change of parameters, Represents the current neural network H t In the forward propagation task t data Data initialized with task 0 of the total difference.

[0087] This loss function comprehensively considers the parameter changes in the neural network, that is, the changes in the accuracy of task 0, and the regular relationship between the current task and the past tasks. This loss function can well limit the parameter changes of the new task data and learn new tasks while protecting the relevant accuracy of historical tasks.

[0088] Furthermore, in one embodiment of the present invention, after obtaining the updated neural network model, the method further includes:

[0089] Repeat all the steps of claim 1 until the classification accuracy of the neural network meets the requirements.

[0090] When there are i tasks in total, it is necessary to repeat the process for different tasks and update the model parameters. After all i training operations, the final model is obtained.

[0091] The continuous learning method based on innate knowledge proposed in the present invention can be applied to the fields of face recognition, target detection, etc. Taking face recognition as an example, an initial face database is obtained, the initial database is learned according to the continuous learning method based on innate knowledge, ResNet or other neural network models are trained, and a model that can classify the initial face database is obtained. When new face data is added, the neural network can increase the number of classified faces through the method of the present invention, and achieve the purpose of real-time maintenance without storing the initial face database. In the target detection scenario, new detection targets can be learned and added in sequence according to the continuous learning method of innate knowledge, realizing the continuous learning process of the neural network, and solving the problem that the neural network needs to be retrained in the detection scenario of target increment.

[0092] According to the method of continuous learning based on innate knowledge proposed in an embodiment of the present invention, a generator is introduced before the learning task to initialize the parameters of the neural network in advance, effectively improving the generalization ability of the model. In the subsequent training process, the task 0 generated by the comprehensive generator and the current learning task are regularized, so that the model can converge quickly and effectively reduce the catastrophic forgetting problem faced by the neural network in continuous learning, improve the task learning ability of the model, and achieve efficient learning of continuous tasks.

[0093] Figure 2 A schematic diagram of the structure of a continuous learning device based on innate knowledge provided in an embodiment of the present invention.

[0094] like Figure 2 As shown, the continuous learning device based on innate knowledge includes: a preprocessing module 10, an initialization module 20, a training module 30, and an updating module 40.

[0095] Among them, the preprocessing module y is used to take the first training data and preprocess the first training data; the initialization module is used to input the preprocessed first training data into the pre-trained generator and output the second training data; the training module is used to train the initialization parameters of the neural network model according to the second training data and the classification neural network; the updating module is used to update the initialization parameters of the neural network model according to the first training data and the pre-constructed loss function to obtain the updated neural network model.

[0096] In addition, the continuous learning device based on innate knowledge according to the above embodiment of the present invention may also have the following additional technical features:

[0097] Furthermore, in one embodiment of the present invention, the preprocessing module is also used for:

[0098] Perform general processing on the input data and transform it into a general row vector. The specific representation is as follows:

[0099]

[0100] Where i represents the task number, j represents the jth data under the current task i, and n represents the number of data in the current data The nth vector component under .

[0101] Furthermore, in one embodiment of the present invention, the initialization module is further used to:

[0102] Build a generator based on the task and data;

[0103] Assumptions The corresponding latent variable z obeys a certain distribution, and the generator is used to learn the mapping X = G(z) to achieve the conversion between the latent variable distribution z and the real data distribution P(X).

[0104]

[0105] The generator is trained and the final generator mapping is: X = G(z). A bias term B is added so that the final generator data is somewhat different from the first training data result, but both are associated with the latent variable distribution z. The final generator mapping is:

[0106] X′=G(z)+B(z);

[0107] According to the generator trained in Task 1, simulate and generate the corresponding second training data;

[0108] Assume that the task data set is A0, then the data set of task 0 is:

[0109]

[0110] in Represents the data in the simulation generation task 0 The amount of data in task 0 is t. The amount of t is related to the amount of data j in the remaining tasks. Generally, the more appropriate relationship is: t=2j.

[0111] Furthermore, in one embodiment of the present invention, the initialization parameters of the neural network model are updated according to the first training data and the pre-constructed loss function to obtain an updated neural network model, wherein the loss function limits the update of the neural network by adding regularization terms of the new task and past task model parameters and the regularization terms of the task 0 in the current task model parameters, so that the neural network preserves the original task parameter information, and the parameters will not change too much with the initial parameter space, thereby achieving stronger generalization and learning capabilities. The specific loss function is designed as follows:

[0112]

[0113] Among them, θ represents With label The difference between p (θ) represents the cross entropy function obtained under the current task t, Represents learning current data After that, the model parameters are changed from H t-1 Updated t After the change of parameters, Represents the current neural network H t In the forward propagation task t data Data initialized with task 0 of the total difference.

[0114] Furthermore, in one embodiment of the present invention, after obtaining the updated neural network model, an iteration module is also included:

[0115] Repeatedly update the neural network model until the neural network classification accuracy meets the requirements;

[0116] When there are i tasks in total, it is necessary to repeat the process for different tasks and update the model parameters. After all i training operations, the final model is obtained.

[0117] The continuous learning device based on innate knowledge proposed in the embodiment of the present invention introduces a generator before the learning task to initialize the parameters of the neural network in advance, effectively improving the generalization ability of the model. In the subsequent training process, the task 0 generated by the comprehensive generator and the current learning task are regularized, so that the model can converge quickly and effectively reduce the catastrophic forgetting problem faced by the neural network in continuous learning, improve the task learning ability of the model, and realize efficient learning of continuous tasks.

[0118] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.

[0119] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of the present invention, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.

[0120] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and modify the above embodiments within the scope of the present invention.

Claims

1. A continuous learning method based on innate knowledge, characterized in that: The method is used to realize continuous learning of a neural network, and the neural network is applied to face recognition. The method comprises the following steps: Acquire first training data, and preprocess the first training data; Input the preprocessed first training data into a pre-trained generator, and output second training data; According to the second training data and the classification neural network, training the initialization parameters of the neural network model; According to the first training data and the pre-constructed loss function, updating the initialization parameters of the neural network model to obtain the updated neural network model; The preprocessing of the first training data includes: Perform general processing on the input data and transform it into a general row vector form. The specific representation is as follows: Where i represents the task number, j represents the jth data under the current task i, and n represents the number of data in the current data The nth vector component under ; Inputting the preprocessed first training data into a pre-trained generator, and outputting second training data, comprising: Build a generator based on the task and data; data The corresponding latent variable z obeys a certain distribution, and the generator is used to learn the mapping X = G(z) to realize the transformation between the latent variable distribution z and the real data distribution P(X). The generator is trained and the final generator mapping is: X = G(z). A bias term B is added so that the final generator data is somewhat different from the first training data result, but both are associated with the latent variable distribution z. The final generator mapping is: X ′ =G(z)+B(z); According to the generator trained in Task 1, simulate and generate the corresponding second training data; Assume that the task data set is A0, then the data set of task 0 is: in Represents the data in the simulation generation task 0 The number of data in task 0 is t. The number of t is related to the number of data in the remaining tasks j. Generally, the more appropriate relationship is: t = 2j; The loss function limits the update of the neural network by adding the regularization term of the new task and the past task model parameters and the regularization term of the task 0 in the current task model parameters, so that the neural network can preserve the original task parameter information, and the parameters will not change too much with the initial parameter space, thus achieving strong generalization and learning capabilities. The specific loss function is designed as follows: Among them, θ represents With label The difference between p (θ) represents the cross entropy function obtained under the current task t, Represents learning current data After that, the model parameters are changed from H t-1 Updated t After the change of parameters, Represents the current neural network H t In the forward propagation task t data Data initialized with task 0 of the total difference.

2. The continuous learning method based on innate knowledge according to claim 1, characterized in that: After obtaining the updated neural network model, the method further includes: Repeat all the steps of claim 1 until the classification accuracy of the neural network meets the requirements; When there are i tasks in total, it is necessary to repeat the process for different tasks and update the model parameters. After all i training operations, the final model is obtained.

3. A device for continuous learning based on innate knowledge, characterized in that: The device is used to realize continuous learning of a neural network, and the neural network is applied to face recognition. The device includes: A preprocessing module, which obtains first training data and preprocesses the first training data; an initialization module, inputting the preprocessed first training data into a pre-trained generator, and outputting second training data; A training module, which trains initialization parameters of a neural network model according to the second training data and the classification neural network; An updating module, which updates the initialization parameters of the neural network model according to the first training data and the pre-constructed loss function to obtain an updated neural network model; Wherein, the preprocessing module is also used for: Perform general processing on the input data and transform it into a general row vector form. The specific representation is as follows: Where i represents the task number, j represents the jth data under the current task i, and n represents the number of data in the current data The nth vector component under ; The preprocessing module is also used for: Build a generator based on the task and data; data The corresponding latent variable z obeys a certain distribution, and the generator is used to learn the mapping X = G(z) to realize the transformation between the latent variable distribution z and the real data distribution P(X). The generator is trained and the final generator mapping is: X = G(z). A bias term B is added so that the final generator data is somewhat different from the first training data result, but both are associated with the latent variable distribution z. The final generator mapping is: X ′ =G(z)+B(z); According to the generator trained in Task 1, simulate and generate the corresponding second training data; Assume that the task data set is A0, then the data set of task 0 is: in Represents the data in the simulation generation task 0 The number of data in task 0 is t. The number of t is related to the number of data in the remaining tasks j. Generally, the more appropriate relationship is: t = 2j; The loss function limits the update of the neural network by adding the regularization term of the new task and the past task model parameters and the regularization term of the task 0 in the current task model parameters, so that the neural network can preserve the original task parameter information, and the parameters will not change too much with the initial parameter space, thus achieving strong generalization and learning capabilities. The specific loss function is designed as follows: Among them, θ represents With label The difference between p (θ) represents the cross entropy function obtained under the current task t, Represents learning current data After that, the model parameters are changed from H t-1 Updated t After the change of parameters, Represents the current neural network H t In the forward propagation task t data Data initialized with task 0 of the total difference.

4. The continuous learning device based on innate knowledge according to claim 3, characterized in that: After obtaining the updated neural network model, an iteration module is also included: Repeatedly update the neural network model until the neural network classification accuracy meets the requirements; When there are i tasks in total, it is necessary to repeat the process for different tasks and update the model parameters. After all i training operations, the final model is obtained.