Deep synthesis identification method and system, electronic equipment and storage medium
By generating diverse forged sample data to train the deep synthesis identification model, the problem of insufficient model generalization ability in the existing technology is solved, and efficient identification of deep forged images and single-model identification of watermark forgeries are achieved, thereby improving recognition accuracy.
Patent Information
- Application Number
- CN202510812632.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-17
- Publication Date
- 2025-09-26
AI Technical Summary
Existing deep fake image/video training methods ignore traces of tampering in other parts of the image and rely on static datasets, resulting in insufficient model generalization capabilities and inability to effectively identify unknown forged samples.
By obtaining real sample data, extracting samples using a preset ratio for tampering and watermark forgery processing, generating diverse forged sample data, and training a deep synthetic identification model, a single-model integrated identification of tampering forgery and watermark forgery is achieved.
It significantly improves the recognition accuracy of deep fake image data, enhances the model's generalization ability for unknown data, and realizes engineering application and deployment.
Smart Images

Figure CN120708039A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence technology, and specifically provides a deep synthesis identification method, system, electronic device and storage medium. Background Art
[0002] With the rapid development of computer technology and artificial intelligence, deepfake synthesis techniques (such as face-swapped videos and synthetic images) have emerged in an endless stream. These techniques have been abused for identity impersonation and attacks on facial recognition systems, posing serious threats to personal privacy and property security. This has made efficient deepfake detection a pressing need. However, current training methods based on deepfake images / videos face two core challenges. First, mainstream training methods typically focus on analyzing the facial region within the image. This not only ignores potential tampering traces in other parts of the image (such as background anomalies or overall coordination), but also introduces additional face detection overhead. More importantly, many deepfake techniques (such as specific local region manipulation algorithms) extend the tampering range beyond the face region and often involve the addition of watermarks to the corners of the image. Therefore, relying solely on face recognition is not only inefficient but also misses critical global forgery cues. Second, existing training methods primarily rely on fixed datasets generated offline, either open source or using known forgery software. The forgery features (tampering patterns, watermark styles, and locations) in these datasets are fixed upon synthesis and lack diversity. In real-world scenarios, however, the constant emergence of new forgery methods and software produces unknown forged data with vastly different characteristics (e.g., watermarks of varying locations, sizes, and types). The static and limited nature of training data can easily lead to models overfitting to known patterns, severely limiting their generalization capabilities when faced with unknown or changing forged samples.
[0003] Accordingly, this field needs a new deep synthesis identification solution to solve the above problems. Summary of the Invention
[0004] In order to overcome the above-mentioned defects, the present application is proposed to provide a solution or at least partially solve the technical problem that the deep synthesis identification model in the prior art has insufficient generalization ability, thereby resulting in low recognition accuracy.
[0005] In a first aspect, the present application provides a deep synthesis identification method, which includes: obtaining image data to be detected; inputting the image data to be detected into a pre-trained deep synthesis identification model, and the deep synthesis identification model outputs a deep synthesis identification result corresponding to the image data to be detected, wherein the deep synthesis identification result includes a tampering forgery result and a watermark forgery result, and the deep synthesis identification model is trained based on real sample data and online synthesized forged sample data.
[0006] In a technical solution of the above-mentioned deep synthesis identification method, the training process of the deep synthesis identification model is as follows: obtain real sample data; based on a preset ratio, extract real sample data from all real sample data as samples to be forged; perform forgery processing on the samples to be forged to obtain forged sample data, and the forgery processing includes tampering forgery processing and / or watermark forgery processing; based on the real sample data and the forged sample data, train the deep synthesis identification model.
[0007] In a technical solution of the above-mentioned deep synthesis identification method, the tampering and forging processing is performed on the sample to be forged to obtain forged sample data, including: obtaining size information of the sample to be forged; based on the size information of the sample to be forged, cropping the sample to be forged to determine multiple local area images; performing tampering and forging processing on the multiple local area images respectively, and the tampering and forging processing includes at least Gaussian blur, motion blur, sharpening, image compression, saturation adjustment, and brightness adjustment; mapping the local area image that has been tampered with and forged to the corresponding position of the sample to be forged to obtain forged sample data.
[0008] In a technical solution of the above-mentioned deep synthesis identification method, the sample to be forged is cropped based on the size information of the sample to be forged to determine multiple local area images, including: based on the size information of the sample to be forged, using a preset random algorithm to determine the size information of multiple candidate areas and the position information of the preset coordinate points of each candidate area on the sample to be forged; based on the size information of multiple candidate areas and the position information of the preset coordinate points of each candidate area, the sample to be forged is cropped to obtain multiple local area images.
[0009] In a technical solution of the above-mentioned deep synthesis identification method, the watermark forgery processing is performed on the sample to be forged to obtain forged sample data, including: obtaining the size information of the sample to be forged; determining the watermark adding position within a preset area of the sample to be forged based on the size information of the sample to be forged; determining the watermark information based on a random generation rule, the watermark information including the watermark content, watermark font and watermark font size; generating a corresponding watermark based on the watermark information; and adding the watermark at the corresponding position of the sample to be forged based on the watermark adding position to obtain forged sample data.
[0010] In one technical solution of the above-mentioned deep synthesis identification method, before extracting real sample data from all real sample data as the sample to be forged, the method also includes: obtaining image size information of the real sample data, the image size information including image width and image height; if the image width of the real sample data is greater than the image height, rotating the real sample data in a preset direction to ensure that the size ratio of the real sample data meets preset conditions.
[0011] In a technical solution of the above-mentioned deep synthesis identification method, the deep synthesis identification model is trained based on the real sample data and the forged sample data, including: resizing the real sample data and the forged sample data respectively; and training the deep synthesis identification model using the real sample data and the forged sample data after resizing.
[0012] In a second aspect, the present application provides a deep synthesis identification system, which includes: an acquisition module for acquiring image data to be detected; an identification module for inputting the image data to be detected into a pre-trained deep synthesis identification model, and the deep synthesis identification model outputs a deep synthesis identification result corresponding to the image data to be detected, wherein the deep synthesis identification result includes a tampering forgery result and a watermark forgery result, and the deep synthesis identification model is trained based on real sample data and online synthesized forged sample data.
[0013] In a third aspect, an electronic device is provided, which includes a processor and a memory, wherein the memory is suitable for storing multiple program codes, and the program codes are suitable for being loaded and run by the processor to execute the deep synthesis identification method described in any one of the technical solutions of the above-mentioned deep synthesis identification method.
[0014] In a fourth aspect, a computer-readable storage medium is provided, which stores a plurality of program codes, wherein the program codes are suitable for being loaded and run by a processor to execute the deep synthesis identification method described in any one of the technical solutions of the above-mentioned deep synthesis identification method.
[0015] The above one or more technical solutions of this application have at least one or more of the following beneficial effects:
[0016] The deep synthesis identification method of the present application includes: obtaining image data to be detected; inputting the image data to be detected into a pre-trained deep synthesis identification model, the deep synthesis identification model outputting a deep synthesis identification result corresponding to the image data to be detected, wherein the deep synthesis identification result includes a tampering forgery result and a watermark forgery result, and the deep synthesis identification model is trained based on real sample data and online synthesized forged sample data. The present application uses real sample data and online synthesized diversified forged sample data to pre-train the deep synthesis identification model to enhance the model's generalization ability for unknown data, thereby significantly improving the recognition accuracy of deep forged image data. By realizing a single-model integrated identification of tampering forgery and watermark forgery, it is conducive to engineering application and deployment. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] The disclosure of this application will be more easily understood with reference to the accompanying drawings. Those skilled in the art will readily appreciate that these drawings are for illustrative purposes only and are not intended to limit the scope of protection of this application. Furthermore, similar numbers in the figures represent similar components, where:
[0018] Figure 1 This is a flow chart of the main steps of a deep synthesis identification method according to one embodiment of the present application;
[0019] Figure 2 This is a flowchart of the main steps of training a deep synthesis identification model according to one embodiment of the present application;
[0020] Figure 3 is a schematic diagram of watermark forgery processing according to an embodiment of the present application;
[0021] Figure 4 is a schematic diagram of the main structural block diagram of a deep synthesis identification system according to an embodiment of the present application;
[0022] Figure 5 It is a schematic diagram of the main structure block diagram of an electronic device according to an embodiment of the present application.
[0023] List of reference numerals:
[0024] 11: memory; 12: processor; 41: acquisition module; 42: identification module. DETAILED DESCRIPTION
[0025] Some embodiments of the present application are described below with reference to the accompanying drawings. Those skilled in the art should understand that these embodiments are only used to explain the technical principles of the present application and are not intended to limit the scope of protection of the present application.
[0026] In the description of this application, "module" and "processor" may include hardware, software, or a combination of both. A module may include hardware circuitry, various suitable sensors, communication ports, and memory. It may also include software components, such as program code, or a combination of software and hardware. A processor may be a central processing unit, a microprocessor, an image processor, a digital signal processor, or any other suitable processor. A processor has data and / or signal processing capabilities. A processor may be implemented in software, hardware, or a combination of both. Non-transitory computer-readable storage media include any suitable medium capable of storing program code, such as magnetic disks, hard disks, optical disks, flash memory, read-only memory, random access memory, etc. The term "A and / or B" refers to all possible combinations of A and B, such as only A, only B, or both A and B. The terms "at least one of A or B" or "at least one of A and B" have similar meanings to "A and / or B" and may include only A, only B, or both A and B. The singular forms "a" and "the" may also include the plural forms.
[0027] Current training methods for deepfake images and videos face two core challenges. First, mainstream training methods typically focus on analyzing the facial region within an image. This not only ignores potential manipulation artifacts (such as background anomalies or overall coherence) in other image regions but also introduces additional face detection overhead. More importantly, many deepfake techniques (such as specific local region manipulation algorithms) extend the manipulation beyond the face region and are often accompanied by the addition of watermarks to image corners. Therefore, relying solely on face recognition is not only inefficient but also misses critical global forgery cues. Second, existing training relies primarily on fixed datasets generated by open-source or known forgery software. The forgery features (tampering patterns, watermark styles, and locations) in these datasets are fixed upon synthesis and lack diversity. In real-world scenarios, the constant emergence of new forgery techniques and software generates unknown forged data with vastly different features (e.g., watermarks of varying locations, sizes, and types). The static and limited nature of training data can easily lead to model overfitting to known patterns, severely limiting generalization capabilities to unknown or changing forged samples.
[0028] To this end, the deep synthesis identification method of the present application includes: obtaining image data to be detected; inputting the image data to be detected into a pre-trained deep synthesis identification model, the deep synthesis identification model outputting a deep synthesis identification result corresponding to the image data to be detected, wherein the deep synthesis identification result includes a tampering forgery result and a watermark forgery result, and the deep synthesis identification model is trained based on real sample data and online synthesized forged sample data. The present application uses real sample data and online synthesized diversified forged sample data to pre-train the deep synthesis identification model to enhance the model's generalization ability for unknown data, thereby significantly improving the recognition accuracy of deep forged image data, and by realizing a single-model integrated identification of tampering forgery and watermark forgery, it is conducive to engineering application and deployment.
[0029] See attached Figure 1 , Figure 1 This is a flow chart of the main steps of the deep synthesis identification method according to an embodiment of the present application. Figure 1 As shown, the deep synthesis identification method in the embodiment of the present application mainly includes the following steps S101-S102.
[0030] Step S101: Acquire image data to be detected;
[0031] In this embodiment, the image data to be detected may be image data to be detected, or video frame image data captured from a video to be detected.
[0032] Step S102: Input the image data to be detected into a pre-trained deep synthesis identification model, and the deep synthesis identification model outputs the deep synthesis identification result corresponding to the image data to be detected, wherein the deep synthesis identification result includes the tampering forgery result and the watermark forgery result, and the deep synthesis identification model is trained based on real sample data and online synthesized forged sample data.
[0033] In this embodiment, there is no need to perform face detection on the image to be detected. The image data to be detected is directly used as the input of the deep synthesis identification model, and the deep synthesis identification model is used to determine the tampering and forgery results and watermark forgery results of the image data to be detected.
[0034] Based on the above steps S101 and S102, the present application uses real sample data and diversified forged sample data synthesized online to pre-train the deep synthesis identification model to enhance the model's generalization ability for unknown data, thereby significantly improving the recognition accuracy of deep forged image data. In actual application, the image data to be detected is directly used as the input of the deep synthesis identification model, so that the model can obtain more tampering traces besides the face to determine whether the image has been deeply synthesized, and by realizing a single model integrated identification of tampering forgery and watermark forgery, it is conducive to engineering application and deployment.
[0035] Before implementing the deep synthesis identification method of this application, it is necessary to pre-train the deep synthesis identification model. Figure 2 As shown, Figure 2 This is a flowchart of the main steps of training a deep synthesis identification model according to an embodiment of the present application.
[0036] In one embodiment, the training process of the deep synthesis identification model is as follows: obtain real sample data; based on a preset ratio, extract real sample data from all real sample data as samples to be forged; perform forgery processing on the samples to be forged to obtain forged sample data, and the forgery processing includes tampering forgery processing and / or watermark forgery processing; based on the real sample data and the forged sample data, train the deep synthesis identification model.
[0037] Specifically, the real sample data refers to the original data set composed of multiple real-person images; some samples in the real sample data are extracted at a preset ratio p as samples to be forged. In order to ensure that the subsequent model training has relatively balanced positive and negative samples, the preset ratio p can be set to 0.5.
[0038] For forged samples, online real-time forgery processing is implemented. The forgery processing includes tampering forgery processing and watermark forgery processing. Tampering forgery processing refers to injecting randomized tampering traces into local areas of the image, and watermark forgery processing refers to adding watermarks with randomized parameters and content in the edge area of the image. Then, based on the original real sample data and the dynamically synthesized forged sample data, the deep synthesis identification model is trained, and the trained model is deployed in actual application scenarios to realize the simultaneous tampering forgery recognition and watermark forgery recognition of the input image to be detected.
[0039] In one embodiment, before extracting real sample data from all real sample data as the sample to be forged, the method further includes: obtaining image size information of the real sample data, where the image size information includes image width and image height; if the image width of the real sample data is greater than the image height, rotating the real sample data in a preset direction to ensure that the size ratio of the real sample data meets preset conditions.
[0040] Specifically, the size information of the real sample data is obtained, including the image width w and the image height h, and it is determined whether the image width w is greater than the image height h. If it is greater, the real sample data is rotated. The rotation can be 90° around the image center point of the real sample data, so that the size information of the rotated real image data satisfies the requirement that the image height h is greater than the image width w.
[0041] In one embodiment, the tampering and forging processing is performed on the sample to be forged to obtain forged sample data, including: obtaining size information of the sample to be forged; based on the size information of the sample to be forged, cropping the sample to be forged to determine multiple local area images; performing tampering and forging processing on the multiple local area images respectively, the tampering and forging processing at least including Gaussian blur, motion blur, sharpening, image compression, saturation adjustment, and brightness adjustment; mapping the local area images that have been tampered and forged to corresponding positions of the sample to be forged to obtain forged sample data.
[0042] In one embodiment, the method of cropping the sample to be forged based on the size information of the sample to be forged to determine multiple local area images includes: based on the size information of the sample to be forged, using a preset random algorithm to determine the size information of multiple candidate areas and the position information of the preset coordinate points of each candidate area on the sample to be forged; based on the size information of the multiple candidate areas and the position information of the preset coordinate points of each candidate area, cropping the sample to be forged to obtain multiple local area images.
[0043] Specifically, the image height and width of the sample to be forged are obtained as size information. Based on the image height h and image width w of the sample to be forged, a preset random algorithm is used to randomly determine the size information of multiple candidate regions and the position information of the preset coordinate points of each candidate region in the sample to be forged. The calculation formula of the preset random algorithm is as follows: center x =random(w*0.25,w*0.75) center y =random(h*0.25,h*0.75) w1=random(w*0.6,w*0.8) h1=random(w*0.6,w*0.8)
[0044] Among them, random(a,b) means randomly generating a number from the range of [a,b], w is the image width of the sample to be forged, h is the image height of the sample to be forged, center xPreset the x coordinate of the coordinate point for the candidate area, center y The y coordinate of the preset coordinate point of the candidate area, w1 is the width of the candidate area, and h1 is the height of the candidate area.
[0045] Through the preset random algorithm, multiple candidate regions of different positions and sizes can be generated. Based on the size information (width w1, height h1) of the multiple candidate regions and the position information (center x ,center y ), the forged sample is cropped to obtain multiple local area images of different positions and sizes, which greatly expands the coverage of the tampered area.
[0046] Each local area image is then tampered with and forged to simulate the tampering traces exhibited by forged data in real scenes. The tampering and forgery processing includes at least Gaussian blur, motion blur, sharpening, image compression (JPEG compression), saturation adjustment, and brightness adjustment. During processing, a local area image can be subjected to a single processing method or a combination of multiple processing methods. For example, it can be blurred first, then slightly sharpened, then the brightness and saturation are adjusted, and finally a little JPEG compression is applied. The processing intensity and parameters applied can be determined as needed, as long as subtle traces that are not easily perceived by the naked eye but can be detected by the algorithm are produced. Different local area images can be subjected to different processing methods and intensities to increase the diversity of forged sample data.
[0047] Finally, the local area image that has been tampered with and forged is repositioned (mapped) back to the sample to be forged according to its original position, that is, forged sample data is obtained in which the local area has a certain slight difference from the corresponding area of the original real sample data.
[0048] In one embodiment, the watermark forging processing is performed on the sample to be forged to obtain forged sample data, including: obtaining size information of the sample to be forged; determining a watermark adding position within a preset area of the sample to be forged based on the size information of the sample to be forged; determining watermark information based on a random generation rule, the watermark information including watermark content, watermark font, and watermark font size; generating a corresponding watermark based on the watermark information; and adding the watermark at a corresponding position of the sample to be forged based on the watermark adding position to obtain forged sample data.
[0049] Specifically, the size information of the sample to be forged is obtained, which includes the image height h and image width w. Based on the image height h and image width w of the sample to be forged, the watermark adding position is determined in the preset area of the sample to be forged. The preset area refers to the four edge areas (top, bottom, left, and right) of the sample to be forged. Taking the top area and the bottom area as an example, Figure 3 As shown, for the top area, the following formula is used to calculate the upper left corner coordinates (x, y) of the watermark adding position:
[0050] Where x is the x-axis coordinate of the watermark adding position, y is the y-axis coordinate of the watermark adding position, w is the image width of the sample to be forged, and h is the image height of the sample to be forged.
[0051] For the bottom area, use the following formula to calculate the upper left corner coordinates (x, y) of the watermark adding position:
[0052] Based on a random generation rule, 6 to 10 characters are randomly selected from the 26 English letters (A-Z) to generate the watermark content. Based on a preset font library (e.g., including commonly used fonts such as FONT_HERSHEY_SIMPLEX, FONT_HERSHEY_DUPLEX, FONT_HERSHEY_COMPLE, FONT_HERSHEY_SCRIPT_SIMPLEX, and FONT_ITALIC), a font is randomly selected from the preset font library as the watermark font. Based on a preset font size range, a value within the range is randomly selected as the watermark font size. The preset font size range can be [0.8, 1.2].
[0053] Finally, based on the calculated coordinates (x, y) of the upper left corner of the watermark, the generated random watermark content, randomly selected watermark font, and random watermark font size are used to render the watermark text onto the sample to be forged at the specified (x, y) position of the sample to be forged, and the forged sample data containing the simulated watermark is obtained.
[0054] In one embodiment, the training of the deep synthesis identification model based on the real sample data and the forged sample data includes: performing size scaling processing on the real sample data and the forged sample data, respectively; and training the deep synthesis identification model using the real sample data and the forged sample data after size scaling processing.
[0055] Specifically, before training the deep synthesis identification model, the real sample data and the forged sample data are resized separately. Specifically, the size can be uniformly resized to 128*128 (pixels), and the resized real sample data and forged sample data are used to train the deep synthesis identification model.
[0056] In summary, compared with the traditional model that directly uses open source offline forged data for training, the method proposed in this application trains a deep synthesis identification model based on real sample data and online real-time synthesized deep forged sample data. This online real-time synthesis method can dynamically generate forged sample data with more diverse forgery trace features and different forms of watermarks, greatly expanding the range of forgery types covered by the training data. This not only provides the model with a more difficult and more general training target, effectively avoiding model overfitting, but also significantly improves the generalization ability of the model, thereby ultimately improving the accuracy of deep synthetic data identification.
[0057] It should be pointed out that although the various steps in the above embodiments are described in a specific order, those skilled in the art will understand that in order to achieve the effect of the present application, different steps do not have to be performed in such an order. They can be performed simultaneously (in parallel) or in other orders. These changes are within the scope of protection of the present application.
[0058] Furthermore, the present application also provides a deep synthesis identification system.
[0059] See attached Figure 4 , Figure 4 This is a main structural block diagram of a deep synthesis identification system according to an embodiment of the present application. Figure 4 As shown, the deep synthesis identification system in the embodiment of the present application mainly includes an acquisition module 41 and an identification module 42. In some embodiments, one or more of the acquisition module 41 and the identification module 42 can be combined into one module. In some embodiments, the acquisition module 41 can be configured to acquire image data to be detected. The identification module 42 can be configured to input the image data to be detected into a pre-trained deep synthesis identification model, and the deep synthesis identification model outputs a deep synthesis identification result corresponding to the image data to be detected, wherein the deep synthesis identification result includes a tampering forgery result and a watermark forgery result, and the deep synthesis identification model is trained based on real sample data and online synthesized forged sample data. In one embodiment, the description of the specific implementation function can be found in steps S101-102.
[0060] The above-mentioned deep synthesis identification system is used to perform Figure 1The deep synthesis identification method embodiment shown in the figure has similar technical principles, technical problems solved and technical effects produced. Technical personnel in this technical field can clearly understand that for the convenience and conciseness of description, the specific working process and related instructions of the deep synthesis identification system can refer to the contents described in the embodiment of the deep synthesis identification method, and will not be repeated here.
[0061] It will be understood by those skilled in the art that all or part of the processes in the method for implementing the above embodiment of the present application can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by a processor, it can implement the steps of each of the above method embodiments. The computer program includes computer program code, which can be in source code form, object code form, executable file or some intermediate form. The computer-readable storage medium can include: any entity or device, medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory, random access memory, electric carrier signal, telecommunication signal and software distribution medium that can carry the computer program code. It should be noted that the content contained in the computer-readable storage medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable storage media do not include electric carrier signals and telecommunication signals.
[0062] Furthermore, the present application also provides an electronic device.
[0063] In an electronic device embodiment according to the present application, the electronic device includes a processor and a memory, the memory can be configured to store a program for executing the depth synthesis identification method of the above method embodiment, and the processor can be configured to execute the program in the memory, which includes but is not limited to a program for executing the depth synthesis identification method of the above method embodiment. For ease of explanation, only the parts related to the embodiment of the present application are shown. For specific technical details not disclosed, please refer to the method part of the embodiment of the present application. The electronic device can be an electronic device formed by various electronic devices. See the attached Figure 5 , Figure 5 exemplarily shows that the memory 11 and the processor 12 are communicatively connected via a bus.
[0064] Furthermore, the present application also provides a computer-readable storage medium. In a computer-readable storage medium embodiment according to the present application, the computer-readable storage medium can be configured to store a program for executing the depth synthesis identification method of the above-mentioned method embodiment, and the program can be loaded and run by the processor to implement the above-mentioned depth synthesis identification method. For ease of explanation, only the parts related to the embodiment of the present application are shown. For specific technical details not disclosed, please refer to the method part of the embodiment of the present application. The computer-readable storage medium can be a storage device formed by various electronic devices. Optionally, the computer-readable storage medium in the embodiment of the present application is a non-temporary computer-readable storage medium.
[0065] Furthermore, it should be understood that since the configuration of each module is merely for the purpose of illustrating the functional units of the apparatus of the present application, the physical devices corresponding to these modules may be the processor itself, or a portion of the software in the processor, a portion of the hardware, or a combination of software and hardware. Therefore, the number of modules in the figure is merely illustrative.
[0066] Those skilled in the art will appreciate that the various modules in the device can be adaptively split or merged. Such splitting or merging of specific modules will not cause the technical solution to deviate from the principles of this application. Therefore, the technical solutions after splitting or merging will fall within the scope of protection of this application.
[0067] Thus far, the technical solutions of the present application have been described in conjunction with the preferred embodiments shown in the accompanying drawings. However, it is readily understood by those skilled in the art that the scope of protection of the present application is obviously not limited to these specific embodiments. Without departing from the principles of the present application, those skilled in the art may make equivalent changes or substitutions to the relevant technical features, and the technical solutions after such changes or substitutions will fall within the scope of protection of the present application.
Claims
1. A deep synthesis identification method, characterized in that: The method comprises: Obtaining image data to be detected; The image data to be detected is input into a pre-trained deep synthesis identification model, and the deep synthesis identification model outputs a deep synthesis identification result corresponding to the image data to be detected, wherein the deep synthesis identification result includes a tampering forgery result and a watermark forgery result, and the deep synthesis identification model is trained based on real sample data and online synthesized forged sample data.
2. The deep synthesis identification method according to claim 1, characterized in that: The training process of the deep synthesis identification model is as follows: Obtain real sample data; Based on a preset ratio, real sample data is extracted from all real sample data as samples to be forged; Performing a forgery process on the sample to be forged to obtain forged sample data, wherein the forgery process includes a tampering forgery process and / or a watermark forgery process; The deep synthesis identification model is trained based on the real sample data and the forged sample data.
3. The deep synthesis identification method according to claim 2, characterized in that: The tampering and forging process is performed on the sample to be forged to obtain forged sample data, including: Obtaining size information of the sample to be forged; Based on the size information of the sample to be forged, the sample to be forged is cropped to determine a plurality of local area images; Performing tampering and forging processing on the multiple local area images respectively, wherein the tampering and forging processing at least includes Gaussian blur, motion blur, sharpening, image compression, saturation adjustment, and brightness adjustment; The tampered and forged local area image is mapped to the corresponding position of the sample to be forged to obtain forged sample data.
4. The deep synthesis identification method according to claim 3, characterized in that: The step of cropping the sample to be forged based on the size information of the sample to be forged to determine a plurality of local area images includes: Based on the size information of the sample to be forged, a preset random algorithm is used to determine the size information of multiple candidate areas and the position information of the preset coordinate points of each candidate area on the sample to be forged; Based on the size information of the multiple candidate areas and the position information of the preset coordinate points of each candidate area, the sample to be forged is cropped to obtain multiple local area images.
5. The deep synthesis identification method according to claim 2, characterized in that: The step of performing watermark forging processing on the sample to be forged to obtain forged sample data includes: Obtaining size information of the sample to be forged; Based on the size information of the sample to be forged, determining a watermark adding position within a preset area of the sample to be forged; Determining watermark information based on a random generation rule, wherein the watermark information includes watermark content, watermark font, and watermark font size; Based on the watermark information, generating a corresponding watermark; Based on the watermark adding position, the watermark is added at the corresponding position of the sample to be forged to obtain forged sample data.
6. The deep synthesis identification method according to claim 2, characterized in that: Before extracting real sample data from all real sample data as samples to be forged, the method further includes: Acquire image size information of the real sample data, where the image size information includes image width and image height; If the image width of the real sample data is greater than the image height, the real sample data is rotated in a preset direction to ensure that the size ratio of the real sample data meets the preset conditions.
7. The deep synthesis identification method according to claim 2, characterized in that: The training of the deep synthesis identification model based on the real sample data and the forged sample data includes: Performing size scaling processing on the real sample data and the forged sample data respectively; The deep synthesis identification model is trained using the real sample data and the forged sample data after size scaling processing.
8. A deep synthesis identification system, characterized in that: The system comprises: An acquisition module, used for acquiring image data to be detected; An identification module is used to input the image data to be detected into a pre-trained deep synthesis identification model, and the deep synthesis identification model outputs a deep synthesis identification result corresponding to the image data to be detected, wherein the deep synthesis identification result includes a tampering forgery result and a watermark forgery result, and the deep synthesis identification model is trained based on real sample data and online synthesized forged sample data.
9. An electronic device comprising a processor and a memory, wherein the memory is adapted to store a plurality of program codes, wherein: The program code is suitable for being loaded and run by the processor to execute the deep synthesis identification method according to any one of claims 1 to 7.
10. A computer-readable storage medium storing a plurality of program codes, characterized in that: The program code is suitable for being loaded and run by a processor to execute the deep synthesis identification method according to any one of claims 1 to 7.