A GAN fingerprint enhancement method for forged face tracing
The compressed face image and GAN fingerprint are enhanced through the dual-domain GAN fingerprint parallel enhancement framework, which solves the problem of low traceability of fake face images after JPEG compression in the existing technology, significantly improves the traceability accuracy, and enhances traceability. The credibility of the results.
Patent Information
- Application Number
- CN202210558754.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-20
- Publication Date
- 2024-10-25
- Estimated Expiration
- 2042-05-20
AI Technical Summary
When existing technology traces the origin of JPEG-compressed fake face images, the accuracy is low and cannot be effectively improved, especially in judicial investigations where there is a lack of sufficient traceability information to support case investigations.
The dual-domain GAN fingerprint parallel enhancement framework is used to enhance the compressed face image and GAN fingerprint through the multi-network enhancement module and decision-making module in the image domain and fingerprint domain. The enhanced features are used for traceability identification to improve the traceability accuracy.
Without retraining the traceability model, the traceability accuracy of compressed face images is significantly improved, and feature details lost in the compression process can be effectively reconstructed, thereby enhancing the credibility of the traceability results.
Smart Images

Figure CN114973363B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of digital image technology, and in particular relates to a GAN fingerprint enhancement method for tracing the origin of forged faces. Background Art
[0002] With the continuous development of generative adversarial networks (GAN), the authenticity of computer-forged facial images is getting higher and higher. It has become increasingly challenging to judge the authenticity of facial images with human eyes alone. Previous methods could only judge the authenticity of images, but could not know the forgery process. In judicial investigations, simply judging the authenticity of images is not enough to support the investigation of cases. If traceability information such as the type of GAN forgery model can be obtained, the credibility of the case investigation results will be further improved. Therefore, tracing the source of GAN forged facial images has become an urgent problem to be solved.
[0003] In 2019, Marra et al. [Reference 1] found that the fake faces generated by different GAN models have unique identifiable features, namely GAN fingerprints, and proposed a set of manual extraction processes for GAN fingerprints, and verified the rationality of using GAN fingerprints for image tracing. In the same year, Yu et al. [Reference 2] proposed an implicit tracing model and a fingerprint visualization tracing model, using a deep convolutional network to extract GAN fingerprint features, improving the tracing accuracy of GAN fake face images. In 2021, Asnani et al. [Reference 3] proposed a fingerprint prediction network for tracing GAN fake face images, and used a combination of level loss, spectrum loss, repetition loss and energy loss to constrain the network. Existing methods generally consider uncompressed lossless format images, but in actual scenarios, considering factors such as storage volume and transmission speed, most images will be compressed by JPEG, which leads to a sharp decrease in the tracing accuracy of existing methods.
[0004] [Document 1] Marra, F., Gragnaniello, D., Verdoliva, L., and Poggi, G.: 'Do gansleave artificial fingerprints? ',in Editor(Ed.)^(Eds.):'Book Do gans leave artificial fingerprints? '(IEEE, 2019, edn.), pp.506-511.
[0005] [Document 2] Yu, N., Davis, LS, and Fritz, M.: 'Attributing fake images to gans: Learning and analyzing gan fingerprints', in Editor (Ed.)^ (Eds.): 'Book Attributing fake images to gans: Learning and analyzing gan fingerprints' (2019, edn.), pp.7556-7566.
[0006] [Document 3] Asnani, V., Yin, X., Hassner, T., and Liu, arXiv:2106.07873, 2021, edn.).
[0007] [Document 4] Haris, M., Shakhnarovich, G., and Ukita, N.: 'Deep back-projectinetworks for single image super-resolution', in Editor(Ed.)^(Eds.): 'Book Deep back-projectinetworks for single image super-resolution' (IEEE, 2020, edn.), pp.4323-4337. Summary of the invention
[0008] In view of the shortcomings of the prior art, the present invention provides a GAN fingerprint enhancement method for forged face tracing, which effectively improves the tracing accuracy of compressed face images without retraining the tracing model by performing enhancement preprocessing operations on the GAN fingerprint before tracing identification.
[0009] In order to achieve the above object, the technical solution provided by the present invention is a GAN fingerprint enhancement method for tracing the source of fake faces, comprising the following steps:
[0010] Step 1, prepare image datasets for training and testing;
[0011] Step 2, construct a dual-domain GAN fingerprint parallel enhancement framework based on multi-type forged face decision-level fusion, including an image domain multi-network enhancement module, a fingerprint domain multi-network enhancement module, a GAN fingerprint calculation module, a GAN fingerprint recognition module and a score decision module; the image domain multi-network enhancement module is composed of multiple image domain enhancement networks, the fingerprint domain multi-network enhancement module is composed of multiple fingerprint domain enhancement networks, the GAN fingerprint recognition module is composed of a fingerprint comparison module and a splicing operation cascade, and the score decision module includes an image domain score decision module, a fingerprint domain score decision module and an overall score decision module; specifically, the following steps are included:
[0012] Step 2.1, inputting the compressed face image obtained in step 1 into the image domain multi-network enhancement module, inputting one compressed face image each time, and obtaining multiple enhanced face images;
[0013] Step 2.2, inputting the multiple enhanced face images obtained in step 2.1 into the GAN fingerprint calculation module to obtain multiple GAN fingerprints;
[0014] Step 2.3, input the multiple GAN fingerprints obtained in step 2.2 into the GAN fingerprint recognition module to obtain the image domain fingerprint comparison score matrix;
[0015] Step 2.4, inputting the compressed face image obtained in step 1 into the GAN fingerprint calculation module to obtain the GAN fingerprint;
[0016] Step 2.5, input the GAN fingerprint obtained in step 2.4 into the fingerprint domain multi-network enhancement module, input one GAN fingerprint each time, and obtain multiple enhanced GAN fingerprints;
[0017] Step 2.6, input the multiple enhanced GAN fingerprints obtained in step 2.5 into the GAN fingerprint recognition module to obtain the fingerprint domain fingerprint comparison score matrix;
[0018] Step 2.7, input the two fingerprint comparison score matrices obtained in step 2.3 and step 2.6 into the image domain score decision module and the fingerprint domain score decision module respectively to obtain two fusion comparison scores, and then input the two fusion comparison scores into the overall score decision module to obtain the final tracing result;
[0019] Step 3, using the training set to train the dual-domain GAN fingerprint parallel enhancement framework based on multi-type forged face decision-level fusion, including training the image domain multi-network enhancement module, the fingerprint domain multi-network enhancement module, the image domain score decision module, the fingerprint domain score decision module and the overall score decision module, and using the test set to evaluate the enhancement effect, to obtain the trained enhancement framework;
[0020] Step 4: Use the trained enhancement framework to input the compressed face image after compression, enhance the GAN fingerprint in the compressed face image, and output the final tracing result.
[0021] Moreover, the training data set in step 1 is divided into four parts, including uncompressed lossless face images, compressed face images after compression, GAN fingerprints generated by uncompressed lossless face images, and labels of GAN model types corresponding to the images. The test data set includes two parts: compressed face images after compression and labels of GAN model types corresponding to the images.
[0022] Moreover, the image domain multi-network enhancement module in step 2.1 is composed of n image domain enhancement networks, and an input compressed face image will be enhanced by n image domain enhancement networks respectively to obtain n enhanced face images.
[0023] Moreover, the step 2.3 is to input n GAN fingerprints into the fingerprint comparison module in the GAN fingerprint recognition module, the fingerprint comparison module outputs n groups of fingerprint comparison scores, and then the n groups of scores are spliced to obtain a fingerprint comparison score matrix.
[0024] Moreover, the fingerprint domain multi-network enhancement module in step 2.5 is composed of n fingerprint domain enhancement networks, and an input GAN fingerprint will be enhanced by n fingerprint domain enhancement networks respectively to obtain n enhanced GAN fingerprints.
[0025] Moreover, the image domain score decision module in step 2.7 is composed of a fully connected layer, the fingerprint domain score decision module is composed of four fully connected layers, three ReLU activation layers and one Softmax activation layer, and the overall score decision module is composed of two fully connected layers, one ReLU activation layer and one Softmax activation layer. First, the input image domain fusion comparison score and fingerprint domain fusion comparison score are connected to form a fusion comparison score matrix. Secondly, the obtained fusion comparison score matrix is sequentially passed through the fully connected layer, ReLU activation layer, fully connected layer and Softmax activation layer to output the overall fusion comparison score. Finally, the maximum value of the overall fusion comparison score is taken as the corresponding label, and the output is the final tracing result.
[0026] Moreover, when training the image domain multi-enhancement network module in step 3, an image domain enhancement network for each type of GAN forged face is trained respectively. If there are n types of GAN forged faces, n image domain enhancement networks are finally trained. During the training process, loss constraints are imposed on the enhanced face image and the uncompressed lossless format face I, the enhanced output GAN fingerprint and the uncompressed output GAN fingerprint F, and the final traceability result and the target GAN model label L, and the calculation method is as follows:
[0027]
[0028] Where L1(·) represents the L1 loss function, ||·||1 represents the L1 norm, P represents an image pair, which contains two image matrices X and Y. X represents the predicted image matrix, and Y represents the target image matrix. Both have the same size N, x i and i Represent the pixel values at position i in the predicted image matrix X and the target image matrix Y respectively.
[0029] F r =C(E_img(I)) (5)
[0030] In the formula, F r It represents the GAN fingerprint output by the enhanced image after passing through the GAN fingerprint calculation module, I represents the input image, E_img(·) represents the image domain enhancement operation, and C(·) represents the image fingerprint operation output by the GAN fingerprint calculation module.
[0031] L plxel =||F r -F||1 (6)
[0032]
[0033] Where, L plxel represents the pixel-level loss function, ||·||1 represents the L1 norm, and F r represents the GAN fingerprint output by the enhanced image after passing through the GAN fingerprint calculation module, F represents the GAN fingerprint output when it is not compressed, and L corr represents the cross entropy loss function, corr(F r , L) indicates F r The fingerprint comparison score obtained by comparing with the target model, G represents the set of all models, n represents a model in the set G, corr(F r , L) indicates F r The fingerprint comparison score obtained by comparing with n models.
[0034] L orlglnal =||E_img(I)-I||1 (8)
[0035] Loss = λ1L plxel +λ2L corr +λ3L orluglnal (9)
[0036] Where, L orlglnal represents the original enhancement loss function, ||·||1 represents the L1 norm, I represents the input image, E_img(·) represents the image domain enhancement operation, Loss represents the optimized objective equation, L plxel represents the pixel-level loss function, L corr represents the cross entropy loss function, and λ1, λ2, and λ3 are weight parameters.
[0037] Moreover, when training the image domain multi-enhancement network module in step 3, a fingerprint domain enhancement network for each type of GAN forged face is trained respectively. If there are n types of GAN forged faces, n fingerprint domain enhancement networks are finally trained. During the training process, loss constraints are imposed on the enhanced GAN fingerprint, the GAN fingerprint F output when not compressed, the final traceability result, and the target GAN model label L, and the calculation method is as follows:
[0038] F e =E_frp(C(I)) (10)
[0039] In the formula, F e represents the enhanced GAN fingerprint, E_frp(·) represents the fingerprint domain enhancement operation, C(·) represents the output image fingerprint operation of the GAN fingerprint calculation module, and I represents the input image.
[0040] L plxel =||F e -F||1 (11)
[0041]
[0042] Where, L plxel represents the pixel-level loss function, ||·||1 represents the L1 norm, and F e represents the enhanced GAN fingerprint, F represents the GAN fingerprint output without compression, L corr represents the cross entropy loss function, corr(F e , L) indicates F e The fingerprint comparison score obtained by comparing with the target model, G represents the set of all models, corr(F e , n) represents F e The fingerprint comparison score obtained by comparing with n models.
[0043] Loss = β1L plxel +β2Lcorr (13)
[0044] In the formula, Loss represents the target equation for optimization, L plxel represents the pixel-level loss function, L corr represents the cross entropy loss function, β1 and β2 are weight parameters.
[0045] Moreover, in the process of training the image domain score decision module, step 3 imposes loss constraints on the final traceability type and the target GAN model label L, and the calculation method is as follows:
[0046] logits_img = LD_img(S) (14)
[0047] Where logits_img represents the image domain fusion contrast score, S represents the input image domain fingerprint contrast score matrix, and LD_img(·) represents the image domain score decision module processing operation.
[0048]
[0049] In the formula, Loss represents the optimized target equation, logits_img L Represents the fingerprint comparison score of the target model, G represents the set of all models, n represents a model in the set G, logits_img n Represents the fingerprint comparison score of n models.
[0050] Moreover, in the process of training the fingerprint domain score decision module, step 3 imposes loss constraints on the final traceability type and the target GAN model label L, and the calculation method is as follows:
[0051] logits_frp=LD_frp(S) (16)
[0052] Where logits_frp represents the fingerprint domain fusion comparison score, S represents the input fingerprint domain fingerprint comparison score matrix, and LD_frp(·) represents the fingerprint domain score decision module processing operation.
[0053]
[0054] In the formula, Loss represents the optimized objective equation, logits_frp L Represents the fingerprint comparison score of the target model, G represents the set of all models, n represents a model in the set G, logits_frp n Represents the fingerprint comparison score of n models.
[0055] Moreover, in the process of training the overall score decision module, step 3 imposes loss constraints on the final traceability type and the target GAN model label L, and the calculation method is as follows:
[0056] logits=LD(logits_img, logits_frp) (18)
[0057] Where logits represents the overall fusion comparison score, logits_img represents the image domain fusion comparison score, logits_frp represents the fingerprint domain fusion comparison score, and LD(·) represents the overall score decision module processing operation.
[0058]
[0059] In the formula, Loss represents the optimized objective equation, logits L represents the fingerprint comparison score of the target model, G represents the set of all models, n represents a model in the set G, logits n Represents the fingerprint comparison score of n models.
[0060] Compared with the prior art, the present invention has the following advantages:
[0061] 1) The present invention enhances the original forged face (image domain) and the GAN fingerprint (fingerprint domain) extracted from the forged face through a dual-domain GAN fingerprint parallel enhancement framework, reconstructs the feature details lost in the compression process, and utilizes the complementarity of the enhanced image domain and fingerprint domain tracing features to further improve the tracing accuracy.
[0062] 2) For various types of forged faces, different types of GAN fingerprint enhancement networks are trained respectively. Finally, the score decision module is used to fuse the output results of multiple enhancement networks, so that various types of forged faces can obtain a higher traceability accuracy. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] Figure 1 is a flow chart of an embodiment of the present invention.
[0064] Figure 2 is a flow chart of the image domain multi-network enhancement module and the fingerprint domain multi-network enhancement module of an embodiment of the present invention: wherein, Figure 2 (a) represents the flowchart of the image domain multi-network enhancement module. Figure 2 (b) shows the flow chart of the fingerprint domain multi-network enhancement module.
[0065] Figure 3 It is a flow chart of the GAN fingerprint recognition module of an embodiment of the present invention.
[0066] Figure 4is a flow chart of the score decision module of an embodiment of the present invention: wherein, Figure 4 (a) represents the flow chart of the image domain score decision module. Figure 4 (b) represents the flow chart of the fingerprint domain score decision module. Figure 4 (c) shows the flow chart of the overall score decision module. DETAILED DESCRIPTION
[0067] The present invention provides a GAN fingerprint enhancement method for tracing the source of forged faces. The technical solution of the present invention is further described below in conjunction with the accompanying drawings and embodiments.
[0068] like Figure 1 As shown, the process of the embodiment of the present invention includes the following steps:
[0069] Step 1: Prepare image datasets for training and testing.
[0070] The training dataset is divided into four parts, including uncompressed lossless face images, compressed face images after compression, GAN fingerprints generated by uncompressed lossless face images, and labels of the GAN model types corresponding to the images. The test dataset includes two parts: compressed face images after compression and labels of the GAN model types corresponding to the images.
[0071] In this embodiment, the uncompressed lossless face image is denoted as I, and the compressed face image after compression is denoted as I cp , the GAN fingerprint generated by the uncompressed lossless format face image is denoted as F, and the label of the image corresponding to the GAN model type is denoted as L. Among them, the uncompressed lossless format face image I is compressed by a specific compression quality factor to obtain the compressed face image I cp , the calculation formula is as follows:
[0072] I cp =Compress(I,q) (1)
[0073] Where Compress(·) represents the compression operation and q represents the compression quality factor.
[0074] Step 2: Construct a dual-domain GAN fingerprint parallel enhancement framework based on decision-level fusion of multiple types of forged faces.
[0075] The dual-domain GAN fingerprint parallel enhancement framework based on multi-type forged face decision-level fusion includes an image domain multi-network enhancement module, a fingerprint domain multi-network enhancement module, a GAN fingerprint calculation module, a GAN fingerprint recognition module and a score decision module. The image domain multi-network enhancement module is composed of multiple image domain enhancement networks. The fingerprint domain multi-network enhancement module is composed of multiple fingerprint domain enhancement networks. The GAN fingerprint recognition module is composed of a fingerprint comparison module and a splicing operation cascade. The score decision module includes an image domain score decision module, a fingerprint domain score decision module and an overall score decision module.
[0076] First, the compressed face image I cp The cascaded image domain multi-network enhancement module, GAN fingerprint calculation module and GAN fingerprint recognition module are input to obtain the image domain fingerprint comparison score matrix; secondly, the compressed face image I cp The cascaded GAN fingerprint calculation module, fingerprint domain multi-network enhancement module and GAN fingerprint recognition module are input to obtain the fingerprint domain fingerprint comparison score matrix; finally, the two fingerprint comparison score matrices are input into the score decision module to output the final tracing result. The specific calculation steps are as follows:
[0077] Step 2.1, input the compressed face image obtained in step 1 into the image domain multi-network enhancement module, input one compressed face image each time, and obtain multiple enhanced face images.
[0078] like Figure 2 As shown in (a), the image domain multi-network enhancement module is composed of n image domain enhancement networks. An input compressed face image will be enhanced by n image domain enhancement networks respectively to obtain n enhanced face images. In this embodiment, each image domain enhancement network is constructed based on DBPN [Reference 4].
[0079] Step 2.2: Input the multiple enhanced face images obtained in step 2.1 into the GAN fingerprint calculation module to obtain multiple GAN fingerprints.
[0080] In this embodiment, the GAN fingerprint calculation module adopts the GAN fingerprint calculation module provided in the fingerprint visualization tracing model [Reference 2].
[0081] Step 2.3, input the multiple GAN fingerprints obtained in step 2.2 into the GAN fingerprint recognition module to obtain the image domain fingerprint comparison score matrix.
[0082] like Figure 3As shown, n GAN fingerprints are input into the fingerprint comparison module in the GAN fingerprint recognition module, and the fingerprint comparison module outputs n sets of fingerprint comparison scores, and then the n sets of scores are spliced to obtain a fingerprint comparison score matrix. In this embodiment, the fingerprint comparison module adopts the fingerprint comparison module provided in the fingerprint visualization traceability model [Document 2], and the specific calculation method is as follows:
[0083] S=Concatenate((l1,l2,...,l n ), axis) (2)
[0084] In the formula, S represents the fingerprint comparison score matrix, Concatenate(·) represents the concatenation operation, and l i It represents the fingerprint comparison score output by the fingerprint comparison module after the i-th GAN fingerprint passes through the fingerprint comparison module. axis represents the concatenated dimension. The default value of axis is 0, which means that the fingerprint comparison scores are concatenated into a one-dimensional matrix.
[0085] Step 2.4, input the compressed face image obtained in step 1 into the GAN fingerprint calculation module to obtain the GAN fingerprint.
[0086] Step 2.5, input the GAN fingerprint obtained in step 2.4 into the fingerprint domain multi-network enhancement module, input one GAN fingerprint each time, and obtain multiple enhanced GAN fingerprints.
[0087] like Figure 2 As shown in (b), the fingerprint domain multi-network enhancement module is composed of n fingerprint domain enhancement networks. An input GAN fingerprint will be enhanced by n fingerprint domain enhancement networks respectively to obtain n enhanced GAN fingerprints. In this embodiment, each fingerprint domain enhancement network is constructed based on DBPN [Reference 4].
[0088] Step 2.6, input the multiple enhanced GAN fingerprints obtained in step 2.5 into the GAN fingerprint recognition module to obtain the fingerprint domain fingerprint comparison score matrix.
[0089] In step 2.7, the two fingerprint comparison score matrices obtained in step 2.3 and step 2.6 are input into the image domain score decision module and the fingerprint domain score decision module respectively to obtain two fused comparison scores, and then the two fused comparison scores are input into the overall score decision module to obtain the final tracing result.
[0090] The image domain score decision module consists of one fully connected layer, the fingerprint domain score decision module consists of four fully connected layers, three ReLU activation layers and one Softmax activation layer, and the overall score decision module consists of two fully connected layers, one ReLU activation layer and one Softmax activation layer. The specific connection methods are as follows: Figure 4 shown.
[0091] First, the input image domain fusion contrast score and fingerprint domain fusion contrast score are connected to form a fusion contrast score matrix; secondly, the obtained fusion contrast score matrix is sequentially passed through the fully connected layer, ReLU activation layer, fully connected layer and Softmax activation layer to output the overall fusion contrast score; finally, the maximum value of the overall fusion contrast score is taken as the corresponding label, and the output is the final tracing result, which is calculated as follows:
[0092] L=Label(Max(logit)) (3)
[0093] Where L represents the output label, logit represents the overall fusion comparison score, Max(·) represents the maximum value operation, and Label(·) represents the corresponding label operation.
[0094] Step 3, use the training set to train the dual-domain GAN fingerprint parallel enhancement framework based on multi-type forged face decision-level fusion, including training the image domain multi-network enhancement module, the fingerprint domain multi-network enhancement module, the image domain score decision module, the fingerprint domain score decision module and the overall score decision module, and use the test set to evaluate the enhancement effect to obtain the trained enhancement framework.
[0095] Step 3.1, train the image domain multi-enhancement network module.
[0096] For each type of GAN forged face, train an image domain enhancement network for each type. If there are n types of GAN forged faces, n image domain enhancement networks will be trained in the end. During the training process, the enhanced face image and the uncompressed lossless format face I, the enhanced output GAN fingerprint F and the uncompressed output GAN fingerprint, as well as the final traceability result and the target GAN model label L are subjected to loss constraints. The calculation method is as follows:
[0097]
[0098] Where L1(·) represents the L1 loss function, ||·||1 represents the L1 norm, P represents an image pair, which contains two image matrices X and Y. X represents the predicted image matrix, and Y represents the target image matrix. Both have the same size N, x i and i Respectively represent the pixel values of the predicted image matrix X and the target image matrix Y at position i;
[0099] F r =C(E_img(I)) (5)
[0100] In the formula, F rrepresents the GAN fingerprint output by the enhanced image after passing through the GAN fingerprint calculation module, I represents the input image, E_img(·) represents the image domain enhancement operation, and C(·) represents the image fingerprint operation output by the GAN fingerprint calculation module;
[0101] L plxel =||F r -F||1 (6)
[0102]
[0103] Where, L plxel represents the pixel-level loss function, ||·||1 represents the L1 norm, and F r represents the GAN fingerprint output by the enhanced image after passing through the GAN fingerprint calculation module, F represents the GAN fingerprint output when it is not compressed, and L corr represents the cross entropy loss function, corr(F r , L) indicates F r The fingerprint comparison score obtained by comparing with the target model, G represents the set of all models, n represents a model in the set G, corr(F r , L) indicates F r The fingerprint comparison score obtained by comparing with n models;
[0104] L orlglnal =||E_img(I)-I||1 (8)
[0105] Loss = λ1L plxel +λ2L corr +λ3L orlglnal (9)
[0106] Where, L orlglnal represents the original enhancement loss function, ||·||1 represents the L1 norm, I represents the input image, E_img(·) represents the image domain enhancement operation, Loss represents the optimized objective equation, L plxel represents the pixel-level loss function, L corr represents the cross entropy loss function, and λ1, λ2, and λ3 are weight parameters.
[0107] Step 3.2: train the fingerprint domain multi-enhancement network module.
[0108] For each type of GAN forged face, a fingerprint domain enhancement network for each type is trained. If there are n types of GAN forged faces, n fingerprint domain enhancement networks are trained in the end. During the training process, the loss constraints are imposed on the enhanced GAN fingerprint, the uncompressed output GAN fingerprint F, the final traceability result, and the target GAN model label L. The calculation method is as follows:
[0109] F e =E_frp(C(I)) (10)
[0110] In the formula, F e represents the enhanced GAN fingerprint, E_frp(·) represents the fingerprint domain enhancement operation, C(·) represents the GAN fingerprint calculation module output image fingerprint operation, and I represents the input image;
[0111] L plxel =||F e -F||1 (11)
[0112]
[0113] Where, L plxel represents the pixel-level loss function, ||·||1 represents the L1 norm, and F e represents the enhanced GAN fingerprint, F represents the GAN fingerprint output without compression, L corr represents the cross entropy loss function, corr(F e , L) indicates F e The fingerprint comparison score obtained by comparing with the target model, G represents the set of all models, corr(F e , n) represents F e The fingerprint comparison score obtained by comparing with n models;
[0114] Loss = β1L plxel +β2L corr (13)
[0115] In the formula, Loss represents the target equation for optimization, L plxel represents the pixel-level loss function, L corr represents the cross entropy loss function, β1 and β2 are weight parameters.
[0116] Step 3.3, train the image domain score decision module.
[0117] During the training process, the loss constraint is imposed on the final traceability type and the target GAN model label L, and the calculation method is as follows:
[0118] logits_img = LD_img(S) (14)
[0119] Where logits_img represents the image domain fusion comparison score, S represents the input image domain fingerprint comparison score matrix, and LD_img(·) represents the image domain score decision module processing operation;
[0120]
[0121] In the formula, Loss represents the optimized target equation, logits_img L Represents the fingerprint comparison score of the target model, G represents the set of all models, n represents a model in the set G, logits_img n Represents the fingerprint comparison score of n models.
[0122] Step 3.4, train the fingerprint domain score decision module.
[0123] During the training process, the loss constraint is imposed on the final traceability type and the target GAN model label L, and the calculation method is as follows:
[0124] logits_frp=LD_frp(S) (16)
[0125] Where logits_frp represents the fingerprint domain fusion comparison score, S represents the input fingerprint domain fingerprint comparison score matrix, and LD_frp(·) represents the fingerprint domain score decision module processing operation;
[0126]
[0127] In the formula, Loss represents the optimized objective equation, logits_frp L Represents the fingerprint comparison score of the target model, G represents the set of all models, n represents a model in the set G, logits_frp n Represents the fingerprint comparison score of n models.
[0128] Step 3.5, train the overall score decision module.
[0129] During the training process, the loss constraint is imposed on the final traceability type and the target GAN model label L, and the calculation method is as follows:
[0130] logits=LD(logits_img, logits_frp) (18)
[0131] Where logits represents the overall fusion comparison score, logits_img represents the image domain fusion comparison score, logits_frp represents the fingerprint domain fusion comparison score, and LD(·) represents the overall score decision module processing operation;
[0132]
[0133] In the formula, Loss represents the optimized objective equation, logits L represents the fingerprint comparison score of the target model, G represents the set of all models, n represents a model in the set G, logits n Represents the fingerprint comparison score of n models.
[0134] Step 4: Use the trained enhancement framework to input the compressed face image after compression, enhance the GAN fingerprint in the compressed face image, and output the final tracing result.
[0135] The specific embodiments described herein are merely examples of the spirit of the present invention. Those skilled in the art may make various modifications or additions to the specific embodiments described or replace them in similar ways, but they will not deviate from the spirit of the present invention or exceed the scope defined by the appended claims.
Claims
1. A GAN fingerprint enhancement method for forged face tracing, characterized in that: The following steps are involved: Step 1, prepare image datasets for training and testing; Step 2, construct a dual-domain GAN fingerprint parallel enhancement framework based on multi-type forged face decision-level fusion, including image domain multi-network enhancement module, fingerprint domain multi-network enhancement module, GAN fingerprint calculation module, GAN fingerprint recognition module and score decision module; The image domain multi-network enhancement module is composed of multiple image domain enhancement networks, the fingerprint domain multi-network enhancement module is composed of multiple fingerprint domain enhancement networks, the GAN fingerprint recognition module is composed of a fingerprint comparison module and a splicing operation cascade, and the score decision module includes an image domain score decision module, a fingerprint domain score decision module and an overall score decision module; the operation of the framework includes the following steps: Step 2.1, inputting the compressed face image obtained in step 1 into the image domain multi-network enhancement module, inputting one compressed face image each time, and obtaining multiple enhanced face images; The image domain multi-network enhancement module is composed of n image domain enhancement networks. A compressed face image input will be enhanced by n image domain enhancement networks respectively to obtain n enhanced face images. Step 2.2, inputting the multiple enhanced face images obtained in step 2.1 into the GAN fingerprint calculation module to obtain multiple GAN fingerprints; Step 2.3, input the multiple GAN fingerprints obtained in step 2.2 into the GAN fingerprint recognition module to obtain the image domain fingerprint comparison score matrix; Input n GAN fingerprints into the fingerprint comparison module in the GAN fingerprint recognition module. The fingerprint comparison module outputs n sets of fingerprint comparison scores. Then, the n sets of scores are concatenated to obtain a fingerprint comparison score matrix. Step 2.4, inputting the compressed face image obtained in step 1 into the GAN fingerprint calculation module to obtain the GAN fingerprint; Step 2.5, input the GAN fingerprint obtained in step 2.4 into the fingerprint domain multi-network enhancement module, input one GAN fingerprint each time, and obtain multiple enhanced GAN fingerprints; The fingerprint domain multi-network enhancement module is composed of n fingerprint domain enhancement networks. An input GAN fingerprint will be enhanced by n fingerprint domain enhancement networks respectively to obtain n enhanced GAN fingerprints. Step 2.6, input the multiple enhanced GAN fingerprints obtained in step 2.5 into the GAN fingerprint recognition module to obtain the fingerprint domain fingerprint comparison score matrix; Step 2.7, input the two fingerprint comparison score matrices obtained in step 2.3 and step 2.6 into the image domain score decision module and the fingerprint domain score decision module respectively to obtain two fusion comparison scores, and then input the two fusion comparison scores into the overall score decision module to obtain the final tracing result; Step 3, using the training set to train the dual-domain GAN fingerprint parallel enhancement framework based on multi-type forged face decision-level fusion, including training the image domain multi-network enhancement module, the fingerprint domain multi-network enhancement module, the image domain score decision module, the fingerprint domain score decision module and the overall score decision module, and using the test set to evaluate the enhancement effect, to obtain the trained enhancement framework; Step 4: Use the trained enhancement framework to input the compressed face image after compression, enhance the GAN fingerprint in the compressed face image, and output the final tracing result.
2. A GAN fingerprint enhancement method for forged face tracing as claimed in claim 1, characterized in that: In step 1, the training data set is divided into four parts, including uncompressed lossless face images, compressed face images after compression, GAN fingerprints generated by uncompressed lossless face images, and labels of GAN model types corresponding to the images. The test data set includes two parts: compressed face images after compression and labels of GAN model types corresponding to the images. The uncompressed lossless face images are denoted as I, and the compressed face images after compression are denoted as I cp , the GAN fingerprint generated by the uncompressed lossless format face image is denoted as F, and the label of the image corresponding to the GAN model type is denoted as L; wherein, the uncompressed lossless format face image I is compressed by a specific compression quality factor to obtain the compressed face image I cp , the calculation formula is as follows: I cp =Compress(I,q) (1) Where Compress(·) represents the compression operation and q represents the compression quality factor.
3. A GAN fingerprint enhancement method for forged face tracing as claimed in claim 1, characterized in that: In step 2.7, the image domain score decision module consists of a fully connected layer, the fingerprint domain score decision module consists of four fully connected layers, three ReLU activation layers and one Softmax activation layer, and the overall score decision module consists of two fully connected layers, one ReLU activation layer and one Softmax activation layer. First, the input image domain fusion comparison score and the fingerprint domain fusion comparison score are connected to form a fusion comparison score matrix. Secondly, the obtained fusion comparison score matrix is passed through the fully connected layer, ReLU activation layer, fully connected layer and Softmax activation layer in turn to output the overall fusion comparison score. Finally, the maximum value of the overall fusion comparison score is taken as the corresponding label, and the output is the final tracing result. The calculation method is as follows: L=Label(Max(logit)) (3) Where L represents the output label, logit represents the overall fusion comparison score, Max(·) represents the maximum value operation, and Label(·) represents the corresponding label operation.
4. A GAN fingerprint enhancement method for forged face tracing as claimed in claim 1, characterized in that: Step 3: When training the image domain multi-enhancement network module, for each type of GAN forged face, an image domain enhancement network for each type is trained. If there are n types of GAN forged faces, n image domain enhancement networks are trained in the end. During the training process, loss constraints are imposed on the enhanced face image and the uncompressed lossless face image I, the enhanced GAN fingerprint and the uncompressed GAN fingerprint F, as well as the final traceability result and the target GAN model label L. The calculation method is as follows: Where L1(·) represents the L1 loss function, ‖·‖1 represents the L1 norm, P represents an image pair, which contains two image matrices X and Y. X represents the predicted image matrix, and Y represents the target image matrix. Both have the same size N, x i With y i Respectively represent the pixel values of the predicted image matrix X and the target image matrix Y at position i; F r =C(E_img(I)) (5) In the formula, F r represents the GAN fingerprint output by the enhanced image after passing through the GAN fingerprint calculation module, I represents the input image, E_img(·) represents the image domain enhancement operation, and C(·) represents the image fingerprint operation output by the GAN fingerprint calculation module; L pixel =‖F r -F‖1 (6) Where, L pixel represents the pixel-level loss function, ‖·‖1 represents the L1 norm, and F r represents the GAN fingerprint output by the enhanced image after passing through the GAN fingerprint calculation module, F represents the GAN fingerprint output when it is not compressed, and L corr represents the cross entropy loss function, corr(F r ,L) indicates F r The fingerprint comparison score obtained by comparing with the target model, G represents the set of all models, n represents a model in the set G, corr(F r ,n) represents F r The fingerprint comparison score obtained by comparing with n models; L original =‖E_img(I)-I‖1 (8) Loss=λ1L pixel +λ2L corr +λ3L original (9) Where, L original represents the original enhancement loss function, ‖·‖1 represents the L1 norm, I represents the input image, E_img(·) represents the image domain enhancement operation, Loss represents the optimized objective equation, L pixel represents the pixel-level loss function, L corr represents the cross entropy loss function, and λ1, λ2, and λ3 are weight parameters.
5. The GAN fingerprint enhancement method for forged face tracing as claimed in claim 1, characterized in that: Step 3: When training the fingerprint domain multi-network enhancement module, for each type of GAN forged face, a fingerprint domain enhancement network for each type is trained. If there are n types of GAN forged faces, n fingerprint domain enhancement networks are finally trained. During the training process, the loss constraints are applied to the enhanced GAN fingerprint, the uncompressed output GAN fingerprint F, the final traceability result, and the target GAN model label L. The calculation method is as follows: F e =E_frp(C(I)) (10) In the formula, F e represents the enhanced GAN fingerprint, E_frp(·) represents the fingerprint domain enhancement operation, C(·) represents the GAN fingerprint calculation module output image fingerprint operation, and I represents the input image; L pixel =‖F e -F‖1 (11) Where, L pixel represents the pixel-level loss function, ‖·‖1 represents the L1 norm, and F e represents the enhanced GAN fingerprint, F represents the GAN fingerprint output without compression, L corr represents the cross entropy loss function, corr(F e ,L) indicates F e The fingerprint comparison score obtained by comparing with the target model, G represents the set of all models, corr(F e ,n) represents F e The fingerprint comparison score obtained by comparing with n models; Loss=β1L pixel +β2L corr (13) In the formula, Loss represents the target equation for optimization, L pixel represents the pixel-level loss function, L corr represents the cross entropy loss function, β1 and β2 are weight parameters.
6. A GAN fingerprint enhancement method for forged face tracing as claimed in claim 1, characterized in that: Step 3: During the training of the image domain score decision module, the loss constraint is imposed on the final traceability type and the target GAN model label L. The calculation method is as follows: logits_img = LD_img(S) (14) Where logits_img represents the image domain fusion comparison score, S represents the input image domain fingerprint comparison score matrix, and LD_img(·) represents the image domain score decision module processing operation; In the formula, Loss represents the optimized target equation, logits_img L Represents the fingerprint comparison score of the target model, G represents the set of all models, n represents a model in the set G, logits_img n Represents the fingerprint comparison score of n models.
7. The GAN fingerprint enhancement method for forged face tracing according to claim 1, characterized in that: Step 3: During the training of the fingerprint domain score decision module, the loss constraint is imposed on the final traceability type and the target GAN model label L. The calculation method is as follows: logits_frp=LD_frp(S) (16) Where logits_frp represents the fingerprint domain fusion comparison score, S represents the input fingerprint domain fingerprint comparison score matrix, and LD_frp(·) represents the fingerprint domain score decision module processing operation; In the formula, Loss represents the optimized objective equation, logits_frp L Represents the fingerprint comparison score of the target model, G represents the set of all models, n represents a model in the set G, logits_frp n Represents the fingerprint comparison score of n models.
8. The GAN fingerprint enhancement method for forged face tracing as claimed in claim 1, characterized in that: Step 3: During the training of the overall score decision module, the loss constraint is imposed on the final traceability type and the target GAN model label L. The calculation method is as follows: logits=LD(logits_img,logits_frp) (18) Where logits represents the overall fusion comparison score, logits_img represents the image domain fusion comparison score, logits_frp represents the fingerprint domain fusion comparison score, and LD(·) represents the overall score decision module processing operation; In the formula, Loss represents the optimized objective equation, logits L represents the fingerprint comparison score of the target model, G represents the set of all models, n represents a model in the set G, logits n Represents the fingerprint comparison score of n models.
