Data enhancement method, device, equipment and storage medium
By extracting features and fusing distinguishing features from the target dataset and training dataset, fused image data is generated, which solves the problem that data augmentation in existing technologies is difficult to cover individual differences, and improves the recognition accuracy of facial image recognition models.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- DALIAN ENTROPY TECH CO LTD
- Filing Date
- 2022-12-09
- Publication Date
- 2026-05-05
AI Technical Summary
In existing technologies for facial image recognition, random orientation data augmentation in the training dataset is insufficient to cover individual differences, leading to recognition errors by deep learning models.
By extracting features from the target dataset and the training dataset, performing discriminative feature fusion, generating fused image data, and updating the training dataset, the data augmentation direction is ensured to target individual discriminative data.
This improved the deep learning model's ability to identify individual discrepancies in the data, enhanced the coverage of the training dataset, and improved the model's recognition accuracy.
Smart Images

Figure CN115984642B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of data processing technology, and in particular relates to a data enhancement method, apparatus, device and storage medium. Background Technology
[0002] In facial image recognition using deep learning models, the diverse nature of collected facial image data means that the training dataset for deep learning models cannot encompass all types of facial image data. When applied to a deep learning model trained on this dataset, a small number of discriminative data points with unique characteristics will be encountered. The absence of these data in the training dataset can easily lead to recognition errors by the deep learning model. To address this issue, data augmentation of the training dataset is necessary. A common method is to perform random-direction data augmentation on the training dataset; however, this method struggles to cover any individual discriminative data points that may be present. Summary of the Invention
[0003] This application provides a data augmentation method, apparatus, device, and storage medium that can solve the problem in the prior art where the direction of training data augmentation is random and it is difficult to cover individual differential data that may occur.
[0004] A first aspect of this application provides a data augmentation method, including:
[0005] Feature extraction is performed on the image data in the target dataset and the training dataset respectively to obtain the feature vector of the target data and the feature vector of the training data.
[0006] The target data feature vector and the training data feature vector are subjected to distinguishable feature fusion to obtain a fused feature vector;
[0007] Based on the fusion feature vector, generate fused image data corresponding to the fusion feature vector;
[0008] The image data in the training dataset is updated to the fused image data.
[0009] A second aspect of this application provides a data enhancement apparatus, comprising:
[0010] The feature extraction module is used to extract features from the image data in the target dataset and the training dataset respectively, to obtain the feature vector of the target data and the feature vector of the training data.
[0011] The feature fusion module is used to perform distinguishable feature fusion on the target data feature vector and the training data feature vector to obtain a fused feature vector.
[0012] An image generation module is used to generate fused image data corresponding to the fused feature vector based on the fused feature vector;
[0013] The data update module is used to update the image data in the training dataset to the fused image data.
[0014] A third aspect of this application provides a terminal device including 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 data augmentation method described above.
[0015] A fourth aspect of this application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the data augmentation method described above.
[0016] The data augmentation method provided in the first aspect of this application fuses the target data feature vector extracted from the target dataset and the training data feature vector extracted from the training dataset to obtain a fused feature vector. Based on the fused feature vector, corresponding fused image data is generated, and the image data in the training dataset is updated to the fused image data. The data augmentation direction of the training dataset is not random. When individual differential data appear in the image data of the target dataset, the distinguishing features of these individual differential data can be fused into the image data of the training dataset, so that the image data in the augmented training dataset can also cover these individual differential data.
[0017] It is understood that the beneficial effects of the second, third and fourth aspects mentioned above can be found in the relevant descriptions in the first aspect above, and will not be repeated here. Attached Figure Description
[0018] To more clearly illustrate the technical solutions in the specific embodiments of this application or the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0019] Figure 1 This is a schematic diagram of a first flowchart of a data augmentation method provided in an embodiment of this application;
[0020] Figure 2 This is a second flowchart illustrating the data augmentation method provided in an embodiment of this application;
[0021] Figure 3 An overall framework diagram of the data augmentation method provided in the embodiments of this application;
[0022] Figure 4 A schematic diagram of the data enhancement device provided in the embodiments of this application;
[0023] Figure 5 This is a schematic diagram of the structure of a terminal device provided in an embodiment of this application. Detailed Implementation
[0024] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application may also be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of this application with unnecessary detail.
[0025] It should be understood that, when used in this application specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or a collection thereof.
[0026] It should also be understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0027] As used in this application specification and the appended claims, the term "if" may be interpreted, depending on the context, as "when," "once," "in response to determination," or "in response to detection." Similarly, the phrase "if determined" or "if detected [the described condition or event]" may be interpreted, depending on the context, as meaning "once determined," "in response to determination," "once detected [the described condition or event]," or "in response to detection [the described condition or event]."
[0028] Furthermore, in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0029] References to "one embodiment" or "some embodiments" in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized. "A plurality" means "two or more."
[0030] Example 1
[0031] Embodiment 1 of this application provides a data augmentation method that can be executed by the processor of a terminal device when running a corresponding computer program. It is used to perform discriminative feature fusion on the target data feature vector extracted from the target dataset and the training data feature vector extracted from the training dataset to obtain a fused feature vector. Based on the fused feature vector, corresponding fused image data is generated, and the image data in the training dataset is updated to the fused image data. This method can fuse the discriminative features of individual differential data appearing in the target dataset into the image data in the training dataset, so that the image data in the augmented training dataset can also cover these individual differential data.
[0032] like Figure 1 As shown, the data augmentation method provided in this embodiment includes the following steps S11 to S14:
[0033] S11. Extract features from the image data in the target dataset and the training dataset respectively to obtain the feature vector of the target data and the feature vector of the training data.
[0034] In application, the target dataset can be a facial image dataset obtained by collecting facial images of the target object in the target scene requiring facial recognition. The training dataset can be a pre-constructed facial image dataset used to train a deep learning model, which can then be used for facial recognition. Because the facial images of the target object in the target scene are unpredictable, the target dataset may contain individual differential data. These differential data possess distinguishing features not found in the image data of the training dataset, such as a tightly wrapped scarf or a thick beard. Although these differential data belong to the same category as the image data in the training dataset, they possess key, subtle distinguishing features. Feature extraction from the image data in the target dataset and training dataset can be performed separately using a generative adversarial network (GAN).
[0035] S12. Perform feature fusion on the target data feature vector and the training data feature vector to obtain a fused feature vector.
[0036] In the application, assume the target dataset is T = {t1, t2, ..., t}. n The training dataset is X = {x1, x2, ..., x}. n The two sets of data have the same number of data points and belong to the same category, focusing on learning the distinguishing features between data points within the same category. In practice, since the number of data points in T is often small, the data in T can be reused to correspond to the number of data points in X, with the categories being Y = {y1, y2, ..., y...}. c}, where c is the number of categories. Image data is organized with a fixed batch size. After feature extraction from the image data in both the target dataset and the training dataset, the feature vector of the target data is obtained as F. t The feature vector of the training data is F x The aforementioned feature fusion of the target data feature vector and the training data feature vector to obtain the fused feature vector can be achieved by using a generative adversarial network to fuse the target data feature vector F. t Training data feature vector F x Distinguishing features F between t -F x With the feature vector F of the training data x The fusion is performed to obtain the fused feature vector F'. x .
[0037] S13. Generate fused image data corresponding to the fused feature vector based on the fused feature vector.
[0038] In application, generating fused image data corresponding to the fused feature vector based on the fused feature vector can be achieved by using a generative adversarial network to generate the corresponding fused image data from the fused feature vector, i.e., obtaining the fused feature vector F' through step S12. x Then, the above-mentioned fused feature vector F' can be obtained through a generative adversarial network. x Generate the corresponding fused image data x'. The aforementioned fused image data x' is the image data after feature fusion, which includes the features of the original image data of the aforementioned training dataset, as well as the distinguishing features that the differential data of the aforementioned target dataset has but that the original image data of the aforementioned training dataset does not have.
[0039] S14. Update the image data in the training dataset with the fused image data.
[0040] In application, after generating the fused image data x' in step S13, the image data in the training dataset can be updated to the fused image data x'. This ensures that the image data in the training dataset contains both the features of its original image data and the distinguishing features possessed by the differential data in the target dataset but not present in the original image data of the training dataset, thus achieving data augmentation of the training dataset. After fine-tuning the deep learning model using the data-augmented training dataset, the deep learning model's ability to recognize the distinguishing features of the differential data in the target dataset can be improved.
[0041] The data augmentation method provided in this application embodiment fuses the target data feature vector extracted from the target dataset and the training data feature vector extracted from the training dataset to obtain a fused feature vector. Based on the fused feature vector, corresponding fused image data is generated, and the image data in the training dataset is updated to the fused image data. The data augmentation direction of the training dataset is not random. When individual differential data appear in the image data of the target dataset, the distinguishing features of these individual differential data can be fused into the image data of the training dataset, so that the image data in the augmented training dataset can also cover these individual differential data.
[0042] Example 2
[0043] This application provides a data augmentation method based on the implementation of embodiment one, which can be executed by the processor of a terminal device when running a corresponding computer program. It is used to perform discriminative feature fusion on the target data feature vector and the training data feature vector through an orthogonal basis subspace, and can achieve effective control over discriminative feature fusion, making data augmentation more reasonable and efficient.
[0044] In one embodiment, step S11 includes: extracting features from the image data in the target dataset and the training dataset respectively using a feature extraction network to obtain the target data feature vector and the training data feature vector.
[0045] In application, the above-mentioned feature extraction network extracts features from the image data in the target dataset and the training dataset respectively, obtaining the target data feature vector and the training data feature vector. Alternatively, the target dataset T and the training dataset X can be input into the feature extraction network of the generative adversarial network, respectively, to output the target data feature vector F. t and the feature vector F of the training data x .
[0046] In one embodiment, step S12 includes: performing discriminative feature fusion on the target data feature vector and the training data feature vector through an orthogonal basis subspace to obtain a fused feature vector.
[0047] In application, the above-mentioned feature fusion of the target data feature vector and the training data feature vector through orthogonal basis subspaces to obtain the fused feature vector can be expressed as:
[0048] F' x =F x +z(F t -F x )
[0049] Where z represents the linear orthogonal basis subspace of the generative adversarial network, used to precisely control the discriminative features F t -F x The degree of fusion. z can be expressed as z = oU + μ, where U = [u1,...,u q ]∈R dxq Describe an orthogonal basis for a linear orthogonal basis subspace, with random factors o ~ N. q (o,I) follows a normal distribution and is used to combine orthogonal bases to form a feature weighting, μ∈R d Let represent the weighted mean. Through training, o, U, and μ are learnable parameters; U is optimized under orthogonal basis constraints, and L... ort =|U T UI|, where L ort Let z represent the orthogonal loss, and I represent the identity matrix. Substitute the expression for z into F' x The expression can be used to obtain F' x =F x +(oU+μ)(F t -F x ).
[0050] In one embodiment, step S13 includes: generating fused image data corresponding to the fused feature vector through a generative network based on the fused feature vector.
[0051] In application, the above-mentioned method of generating fused image data corresponding to the fused feature vector through a generative network can be achieved by using the fused feature vector F'. x The input generative adversarial network G, and the output fused image data x', can be represented as: x' = G(F') x The fused image data x' is the image data that combines the features of the original image data in the training dataset with the distinguishing features of the difference data in the target dataset that are not present in the original image data in the training dataset.
[0052] In applications, the aforementioned orthogonal basis subspace can be learned based on generative adversarial networks (GANs) to control the degree and direction of fusing discriminative features from differentially expressed data in the target dataset into the training dataset. Through the learned orthogonal basis subspace, discriminative features from individual differentially expressed data in the target dataset can be fused into the training dataset, thereby augmenting the training dataset. Finally, the deep learning model is fine-tuned using the augmented training dataset, enabling it to recognize individual differentially expressed data.
[0053] like Figure 2 As shown, in one embodiment, step S14 includes: S21, calculating the loss corresponding to the fused image data based on the fused image data; S22, updating the image data in the training dataset to the fused image data when the loss corresponding to the fused image data is less than a preset threshold. Specifically, S21 includes: calculating the cross-entropy loss, adversarial loss, and discriminative loss corresponding to the fused image data based on the fused image data; calculating the sum of the cross-entropy loss, the adversarial loss, and the orthogonal loss of the orthogonal basis subspace to obtain the generator network loss. S22 includes: updating the image data in the training dataset to the fused image data when the generator network loss corresponding to the fused image data is less than a first preset threshold and the discriminative loss corresponding to the fused image data is less than a second preset threshold.
[0054] In application, the cross-entropy loss corresponding to the above-mentioned fused image data x' can be the cross-entropy loss between the fused image data x' and its corresponding category y∈Y, which can be expressed as: L c =E(x',y). In discriminative feature fusion, the fused image data x' generated based on the adversarial method must be sufficiently realistic to represent the features of the real image. Therefore, the adversarial loss can be expressed as: L a =-E x~X,z~Z [log(D(x'))]. By calculating the cross-entropy loss L mentioned above...c The aforementioned losses in combat L a The orthogonal loss L with the above orthogonal basis subspace ort The sum of these can be used to obtain the generator network loss, expressed as: L G =L ort +L c +L a Meanwhile, to ensure the distinguishability between the generated fused image data and the image data in the target dataset, the generated fused image data cannot be too realistic. Therefore, the discrimination loss can be expressed as: L D =-E t~T [log(D(t))]-E x~X,z~Z [log(1-D(x'))].
[0055] In applications, when generating network loss L G If the value is less than the first preset threshold, the identification loss L is determined. D When the value is less than the second preset threshold, it indicates that the orthogonal basis subspace learning is complete and the fused image data x' has fused the distinguishing features of the differential data in the target dataset. Then, the image data in the training dataset can be updated to the fused image data x' to achieve data augmentation of the training dataset. The first preset threshold and the second preset threshold can be a value preset based on experience.
[0056] Through the generative adversarial process described above, orthogonal basis subspaces can be used for learning. When encountering individual differential data, the discriminative features of these individual differential data can be fused into the training dataset, thereby achieving data augmentation by imbuing the training dataset with these discriminative features. Fine-tuning the deep learning model based on this augmented training dataset can improve its ability to recognize individual differential data.
[0057] Please see Figure 3 , Figure 3 The overall framework diagram of the data augmentation method provided in this embodiment is illustrated below with an example:
[0058] Suppose that the training dataset X has 20,000 images, with 4 categories: "wearing a hat", "wearing a mask", "wearing glasses", and "wearing a beard", with 5,000 images in each category. The target dataset T has 200 images, with 50 images in each category. The target dataset contains data that the deep learning model misidentified. To ensure a one-to-one correspondence between the training dataset images and the target dataset images for each category, the target dataset images can be reused to achieve a correspondence between the categories and the number of images in the training dataset.
[0059] Image data from the training dataset X and the target dataset T are input into the feature extraction network. Assuming a batch size of 16 and an input size of 112*112 pixels, the feature vector F extracted by the feature extraction network is the training data feature vector. x and target data feature vector F t The sizes of all elements are [16, 256, 28, 28]. Discriminating features are fused using orthogonal basis subspaces to obtain the fused feature vector F'. x Its size is [16,256,28,28].
[0060] The above fused feature vector F' x The generator network G outputs fused image data x' with a size of [16, 3, 112, 112]. When the generator network loss L... G If the value is less than the first preset threshold, the identification loss L is determined. D When the value is less than the second preset threshold, the image data in the training dataset can be updated to the fused image data x'. In z = oU + μ, the size of U is [10, 256], the size of μ is
[256] , and the size of o is [16, 10], where 10 represents the types of orthogonal bases to be learned, that is, the distinguishing features of the differential data in the target dataset are learned in 10 different directions.
[0061] The data augmentation method provided in this application, through learning orthogonal basis subspaces, can control the fusion of discriminative features of individual differential data in the target dataset into the training dataset, thereby achieving data augmentation of the training dataset. This allows for fine-tuning of the deep learning model, achieving the goal of updating the deep learning model based on individual differential data, and ultimately identifying these discriminative data. Unlike existing randomized data augmentation methods, this method effectively controls the learning of discriminative features through orthogonal basis subspaces, making the data augmentation more reasonable and efficient.
[0062] Example 3
[0063] like Figure 4 As shown, this embodiment also provides a data augmentation device, the data augmentation device 400 including:
[0064] The feature extraction module 401 is used to extract features from the image data in the target dataset and the training dataset respectively, to obtain the target data feature vector and the training data feature vector;
[0065] Feature fusion module 402 is used to perform distinguishable feature fusion on the target data feature vector and the training data feature vector to obtain a fused feature vector;
[0066] The image generation module 403 is used to generate fused image data corresponding to the fused feature vector based on the fused feature vector;
[0067] The data update module 404 is used to update the image data in the training dataset to the fused image data.
[0068] Optionally, the feature extraction module 401 is specifically used to extract features from the image data in the target dataset and the training dataset respectively through a feature extraction network to obtain the target data feature vector and the training data feature vector.
[0069] Optionally, the feature fusion module 402 is specifically used to perform distinguishable feature fusion on the target data feature vector and the training data feature vector through an orthogonal basis subspace to obtain a fused feature vector.
[0070] Optionally, the image generation module 403 is specifically used to generate fused image data corresponding to the fused feature vector through a generation network based on the fused feature vector.
[0071] Optionally, the data update module 404 includes:
[0072] The loss calculation unit is used to calculate the loss corresponding to the fused image data based on the fused image data;
[0073] The data update unit is used to update the image data in the training dataset to the fused image data when the loss corresponding to the fused image data is less than a preset threshold.
[0074] Optionally, the loss calculation unit includes:
[0075] The first computing unit is used to calculate the cross-entropy loss, adversarial loss, and discrimination loss corresponding to the fused image data, respectively, based on the fused image data.
[0076] The second computing unit is used to calculate the sum of the cross-entropy loss, the adversarial loss, and the orthogonal loss of the orthogonal basis subspace to obtain the generator network loss.
[0077] Optionally, the data update unit is specifically used to update the image data in the training dataset to the fused image data when the generation network loss corresponding to the fused image data is less than a first preset threshold and the discrimination loss corresponding to the fused image data is less than a second preset threshold.
[0078] It should be noted that the information interaction and execution process between the above-mentioned devices / units are based on the same concept as the method embodiments of this application. For details on their specific functions and technical effects, please refer to the method embodiments section, and they will not be repeated here.
[0079] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is merely an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. Furthermore, the specific names of the functional units and modules are only for easy differentiation and are not intended to limit the scope of protection of this application. The specific working process of the units and modules in the above system can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0080] This application also provides a terminal device 500, such as... Figure 5 As shown, it includes a memory 501, a processor 502, and a computer program 503 stored in the memory 501 and executable on the processor 502. When the processor 502 executes the computer program 503, it implements the steps of the data augmentation method provided in the first aspect.
[0081] In applications, terminal devices may include, but are not limited to, processors and memory. Figure 5 This is merely an example of a terminal device and does not constitute a limitation on the terminal device. It may include more or fewer components than illustrated, or a combination of certain components, or different components, such as input / output devices, network access devices, etc. Input / output devices may include cameras, audio capture / playback devices, displays, etc. Network access devices may include network modules for wireless network communication with external devices.
[0082] In applications, the processor can be a Central Processing Unit (CPU), but it can also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor.
[0083] In applications, the memory may be an internal storage unit of the terminal device in some embodiments, such as the hard drive or RAM of the terminal device. In other embodiments, the memory may be an external storage device of the terminal device, such as a plug-in hard drive, Smart Media Card (SMC), Secure Digital (SD) card, or Flash Card. The memory may also include both internal and external storage units of the terminal device. The memory is used to store the operating system, applications, boot loader, data, and other programs, such as the program code of computer programs. The memory can also be used to temporarily store data that has been output or will be output.
[0084] This application also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, can implement the steps in the above-described method embodiments.
[0085] This application implements all or part of the processes in the methods of the above embodiments, which can be accomplished by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable file, or some intermediate form. The computer-readable medium can include at least: any entity or device capable of carrying the computer program code to a terminal device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium, such as a USB flash drive, a portable hard drive, a magnetic disk, or an optical disk.
[0086] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0087] Those skilled in the art will recognize that the device and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0088] In the embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interface, or the device may be indirectly coupled or communicated, and may be electrical, mechanical, or other forms.
[0089] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. A data augmentation method, characterized in that, include: Feature extraction is performed on the image data in the target dataset and the training dataset respectively to obtain the feature vector of the target data and the feature vector of the training data. The target data feature vector and the training data feature vector are subjected to distinguishable feature fusion to obtain a fused feature vector; Based on the fusion feature vector, generate fused image data corresponding to the fusion feature vector; Update the image data in the training dataset with the fused image data; The step of fusing the distinguishing features of the target data feature vector and the training data feature vector to obtain the fused feature vector is expressed as follows: F' x =F x +z(F t -F x ) Where z represents the linear orthogonal basis subspace of the generative adversarial network, used to control the discriminative features F t -F x The degree of integration, F t Let F be the feature vector of the target data. x Let F' be the feature vector of the training data. x The fused feature vector is denoted as .
2. The data augmentation method as described in claim 1, characterized in that, The step of extracting features from image data in the target dataset and training dataset respectively to obtain feature vectors for the target data and training data includes: The feature extraction network extracts features from the image data in the target dataset and the training dataset respectively, resulting in feature vectors for the target data and training data.
3. The data augmentation method as described in claim 1, characterized in that, The step of generating fused image data corresponding to the fused feature vector based on the fused feature vector includes: Based on the fusion feature vector, a generative network is used to generate fused image data corresponding to the fusion feature vector.
4. The data augmentation method according to any one of claims 1 to 3, characterized in that, The step of updating the image data in the training dataset to the fused image data includes: Calculate the loss corresponding to the fused image data based on the fused image data; When the loss corresponding to the fused image data is less than a preset threshold, the image data in the training dataset is updated to the fused image data.
5. The data augmentation method as described in claim 4, characterized in that, The step of calculating the loss corresponding to the fused image data based on the fused image data includes: Based on the fused image data, calculate the cross-entropy loss, adversarial loss, and discrimination loss corresponding to the fused image data, respectively. The sum of the cross-entropy loss, the adversarial loss, and the orthogonal loss of the orthogonal basis subspace is calculated to obtain the generator network loss.
6. The data augmentation method as described in claim 4, characterized in that, When the loss corresponding to the fused image data is less than a preset threshold, updating the image data in the training dataset to the fused image data includes: When the loss of the generator network corresponding to the fused image data is less than a first preset threshold and the loss of the discrimination corresponding to the fused image data is less than a second preset threshold, the image data in the training dataset is updated to the fused image data.
7. A data augmentation device, characterized in that, include: The feature extraction module is used to extract features from the image data in the target dataset and the training dataset respectively, to obtain the feature vector of the target data and the feature vector of the training data. The feature fusion module is used to perform distinguishable feature fusion on the target data feature vector and the training data feature vector to obtain a fused feature vector. An image generation module is used to generate fused image data corresponding to the fused feature vector based on the fused feature vector; The data update module is used to update the image data in the training dataset to the fused image data; The step of fusing the distinguishing features of the target data feature vector and the training data feature vector to obtain the fused feature vector is expressed as follows: F' x =F x +z(F t -F x ) Where z represents the linear orthogonal basis subspace of the generative adversarial network, used to control the discriminative features F t -F x The degree of integration, F t Let F be the feature vector of the target data. x Let F' be the feature vector of the training data. x The fused feature vector is denoted as .
8. A terminal device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the data augmentation method as described in any one of claims 1 to 6.
9. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the data augmentation method as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Extracting method for blast furnace charge line
CN109490861A
Lung segment identification method and device
CN115240184A