A blind evidence-taking method for small target copy-paste tampered image
By combining residual super-resolution network and frequency domain information extraction network with cross-modal fusion and Transformer module, the problem of detecting small target copy-paste tampered images is solved, and high-precision tampered area localization is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- HEBEI UNIV OF TECH
- Filing Date
- 2022-10-14
- Publication Date
- 2026-06-02
AI Technical Summary
Existing technologies are insufficient to effectively detect small target copy-paste regions in tampered images, and traditional methods have high computational complexity, poor robustness, and are unable to capture frequency domain information.
A residual super-resolution network is used to extract high-resolution images. Combined with a frequency domain information extraction network based on discrete cosine transform, multi-scale features are fused through cross-modal fusion and the Transformer module. Position attention is used to calculate the inter-pixel dependencies and locate the tampered region.
It improves the accuracy of small target detection and overall detection accuracy, can accurately locate source and target areas, and enhances the ability to detect tampered areas.
Smart Images

Figure CN115619639B_ABST
Abstract
Description
Technical Field
[0001] The technical solution of this invention belongs to the field of deep learning image processing and pattern recognition technology, specifically a blind evidence collection method for small-target copy-paste tampered images. Background Technology
[0002] The purpose of image tampering forensics is to detect the parts of an image that have been artificially modified. Image tampering methods include splicing, copy-paste, and removal. Copy-paste is a typical digital image processing technique, which involves copying a region of the same image (the source region) and then pasting it into other regions of the same image (the tampered region), thereby enhancing or hiding parts of the image. Because the brightness and color information of the same image are very similar, it is difficult for an image to produce obvious visual differences after being subjected to copy-paste tampering.
[0003] Image tampering detection technology is an forensic technique that detects whether digital images have undergone forgery or other additional manipulations. It includes active forensics, which requires additional verification information, and passive forensics, which does not. Both types of techniques can detect image authenticity but are used in different fields. In real life, most images do not have pre-embedded digital signatures, digital watermarks, or other prior information, making them undetectable using active forensics techniques. Therefore, passive forensics, also known as blind forensics, is needed. Blind forensics refers to techniques that determine the authenticity and integrity of an image without embedding prior information within it. Image tampering blind forensics involves multiple research areas, including computer vision, image processing, and pattern recognition.
[0004] Current research methods for blind forensics based on copy-paste image tampering include traditional methods and deep learning-based methods. Traditional methods further include block-based and keypoint-based approaches. Block-based methods divide the host image into blocks, extract block features, perform feature similarity matching, and locate the tampered region based on the matching results. Principal Component Analysis (PCA) can extract features robust to noise and compression. Popescu et al. used this algorithm in "Exposing digital forgeries by detecting duplicated image regions" to detect duplicate regions by lexicographically sorting these features. However, block-based forensics algorithms have high computational complexity and poor robustness to geometric transformations. Keypoint-based methods use SIFT or SURF to search for high-entropy regions, find local extrema, extract neighborhood features, and perform feature matching to locate the forged region. Ardizzone's "Copy-move forgery detection by matching triangles of keypoints" introduces triangular features to extract points of interest from images. Based on these points, connected triangles are used to simulate targets in the image, followed by matching. However, this approach struggles with keypoint extraction in smooth regions. With the development of deep learning, especially convolutional neural networks, in recent years, deep learning methods have also been applied to blind forensics against image manipulation. Rao's "A deep learning approach to detection of splitting and copy-move forgeries in images" proposes using RGB color images as input to learn hierarchical feature representations, but the network structure is too simple, leading to poor detection accuracy. Wu's "BusterNet: Detecting Copy-Move Image Forgery with Source / Target Localization" proposes a method based on fusing boundary artifacts and region similarity calculations, presenting a BusterNet model to distinguish between source and forged targets. The drawback of this method is that it requires ensuring both branches correctly locate the forged region.
[0005] CN113450330A discloses an image copy-paste detection method based on segmentation and convolutional neural networks. This method first acquires the image to be detected and builds an image segmentation model; then, it trains and segments the image to obtain segmentation weight parameters and image boundary pixel direction information, acquiring a segmented image; furthermore, it combines the segmented image and its features to perform autocorrelation matching, obtaining image matching features; finally, it feeds the image matching features into a classification model to obtain a detected image of the tampered region. The drawback of this method is that although it uses attention to acquire high-frequency edge features of the tampered image, it only processes in the spatial domain and cannot capture tampering artifact features. Furthermore, it struggles to detect small targets within the tampered image.
[0006] CN103345758A discloses a blind detection method for JPEG image region duplication based on DCT statistical features. This method extracts DCT statistical features from the image content without relying on image watermarks or other information. The method first divides the image into multiple overlapping sub-blocks, then extracts the DCT statistical features of each sub-block, performs DCT transformation on each sub-block sequentially, and then identifies image sub-blocks with matching features as suspicious blocks through feature dimensionality reduction and feature sorting. Finally, it selects sub-blocks with displacement vector counts greater than a threshold value for identification, thus defining them as tampered regions. The disadvantages of this method are its high computational complexity and poor robustness to geometric transformations. Furthermore, the DCT transformation used in this method lacks adaptive learning capabilities, only showing good results for certain types of images, thus limiting its application scenarios. Summary of the Invention
[0007] To address the shortcomings of existing technologies, the technical problem this invention aims to solve is to provide a blind forensics method for small-target copy-paste tampered images. This method utilizes frequency domain information in the tampered image to capture clear tampering artifacts, thereby improving the network's ability to detect tampered areas. Furthermore, to address the difficulty in detecting tampered small targets, subpixel convolution is used to super-divide the original low-resolution input image into a high-resolution image, which to some extent expands the scale of small targets and enhances the network's ability to identify tampered small targets.
[0008] The technical solution adopted by the present invention to solve the aforementioned technical problem is as follows:
[0009] A blind forensic method for small-target copy-paste tampering images, characterized by two stages, specifically including the following:
[0010] In the first stage, the input image is preprocessed. The residual features of the preprocessed input image are extracted using a residual super-resolution network, and the residual features are super-resolutiond to obtain a super-resolution image.
[0011] The residual super-resolution network comprises a feature activation unit module, a residual feature extraction module, and a feature pixel rearrangement module. The feature activation unit module includes convolution operations and activation functions, which activate the preprocessed input image to obtain activation features. The residual feature extraction module extracts residual features from the activation features. This module consists of multiple stacked residual blocks; the output of one residual block serves as the input to the next, and the results are added point-by-point to obtain the output of the next residual block. Each residual block consists of multiple sequential convolutional structures and activation functions. The feature pixel rearrangement module rearranges the residual features pixel by pixel to obtain the super-resolution image. This module includes convolution operations and sub-pixel convolution operations.
[0012] In Phase Two, the tampered image is preprocessed and input into the trained residual super-resolution network to obtain residual features and the super-resolution image. Frequency domain features of the super-resolution image are extracted using a frequency domain information extraction network based on discrete cosine transform (DCT). This network includes DCT, adaptive filters, and inverse DCT. A cross-modal fusion network fuses frequency domain features and residual features through positional attention to obtain cross-domain features. Multi-scale features are extracted from the cross-domain features using a feature extraction network, which includes a feature pyramid and a Transformer module. Each feature extraction module in the feature pyramid is connected to a Transformer module, which obtains the dependencies between pixels in the features. A multi-scale fusion module fuses the multi-scale features. This module obtains prediction masks for the multi-scale features through convolution and upsampling operations. Each prediction mask is then convolved to the same dimension and added point-by-point to obtain the predicted segmentation map.
[0013] This completes the blind evidence collection of the small-target image copy-paste tampering.
[0014] Furthermore, the feature pixel rearrangement module includes two convolution operations and two subpixel convolution operations, expressed as:
[0015] O H =PixelShuffle2(f Conv2D_1 (PixelShuffle2(f Conv2D_2 (X F ))))
[0016] Among them, f Conv2D_2 (·) represents a convolution operation with a kernel size of 3×3 and padding of 2, f Conv2D_1(·) represents a convolution operation with a kernel size of 3×3 and padding of 1, while PixelShuffle2(·) represents a subpixel convolution operation with a sampling rate of 2.
[0017] Furthermore, the residual block includes a convolutional structure with a kernel size of 1×1, a PRelu activation function, a convolutional structure with a kernel size of 3×3, a PRelu activation function, a convolutional structure with a kernel size of 1×1, and a PRelu activation function.
[0018] Furthermore, the frequency domain information extraction network based on discrete cosine transform first transforms the super-resolution image from the spatial domain to the frequency domain to obtain the frequency domain response; then, it uses an adaptive filter to decompose the super-resolution image into three frequency domain bands: low frequency, mid frequency, and high frequency, and performs a Hadamard product between the frequency domain response and the adaptive filter; finally, it performs an inverse discrete cosine transform to transfer the frequency domain response to the spatial domain, thereby extracting the frequency domain features of the super-resolution image.
[0019] Furthermore, all features extracted from the feature pyramid are input into the corresponding Transformer module. The Transformer module performs dimensionality adjustment on the input features, and then converts the dimensionality-adjusted features into semantic information through convolution. The semantic information is multiplied with the input features of the Transformer module and then activated to obtain visual information. The encoder of the Transformer module includes a multi-head self-attention and a multilayer perceptron module. Each self-attention module includes multiple self-attention layers. The attention features of each self-attention layer are obtained by multiplying its respective weight matrix with the visual information obtained from the previous self-attention layer.
[0020] Compared with the prior art, the beneficial effects of the present invention are:
[0021] The key features of this invention are as follows:
[0022] (1) The residual super-resolution network in this invention removes the Batch Normalization (BN) layer, which is unsuitable for super-resolution tasks, ensuring that the output image maintains consistency with the input image in terms of color, contrast, and brightness. Only the resolution and some details are altered, avoiding the stretching of image contrast caused by adding BN layers, which would destroy the original contrast information of the image. In practice, because tampered images often contain small-resolution targets, these small targets cover a small number of pixels, making the features used for detection less effective and the feature representation weak. The large anchor size of the candidate region in general object detection networks leads to small targets being less noticed or ignored. In this application, the tampered image is input into the trained residual super-resolution network to obtain a high-resolution super-resolution image, increasing the information content of small targets, enhancing their features, and obtaining more details of the small targets.
[0023] (2) This invention guides the network to focus on tampered regions by capturing unusual frequency domain information in tampered images and integrating it into a cross-modal fusion network. The tampered image is transformed from the spatial domain to the frequency domain using discrete cosine transform (DCT), and the frequency domain information is divided into different frequency bands using an adaptive filter. Finally, to enable the network to process this frequency domain information, inverse DCT is used to transform it back to the spatial domain. Simultaneously, positional attention is used to calculate the dependencies between pixels in the tampered image, combining this with the frequency domain information to guide the network. This makes the convolutional neural network focus more on the tampered regions, improving the detection accuracy of the tampered regions.
[0024] (3) This invention employs a feature pyramid and a Transformer module to fuse shallow features containing detailed target texture information and deep features containing abstract semantic information. Shallow and deep features at different scales are obtained through the feature pyramid. These features are then input into the Transformer module to evaluate the similarity between local neighborhoods and global regions, constructing pixel dependencies at both local and global scales to obtain the similarity between pixels. Simultaneously, a multi-scale fusion module is used to fuse features at different scales, thereby more accurately locating the source and target regions.
[0025] The significant advancement of this invention is:
[0026] (1) Compared with CN113450330A, the method of the present invention has the advantage of being able to perform super-resolution processing on tampered images, increasing the amount of information about small targets, enhancing the features of small targets, and obtaining more details of small targets. Ultimately, it improves both the detection accuracy of small targets and the overall detection accuracy.
[0027] (2) Compared with CN103345758A, the method of the present invention has the advantage of extracting unusual frequency domain information of the tampered image through discrete cosine transform, and innovatively using position attention to integrate the frequency domain information into the neural network, which can fully enhance the network's attention to the tampered area, thereby locating a more accurate source and target area.
[0028] (3) The present invention proposes a two-stage parallel training method. In the first stage, a residual super-resolution network is trained to obtain an image that outputs an image that only changes the resolution while maintaining consistency with the input image in terms of color, contrast, and brightness. In the second stage, the residual super-resolution network is combined with a cross-modal network to capture the frequency domain information of the tampered image while fusing multi-scale features from shallow and deep layers. This improves the detection accuracy of tampered regions of small targets and accurately locates the source and target regions.
[0029] (4) The method of the present invention uses a positional attention mechanism to capture cross-domain features. By calculating the mutual influence between pixels through the attention mechanism, the importance of each pixel can be determined. This allows for full attention to the frequency domain features of the tampered image, thereby enhancing the performance of tampered image detection.
[0030] (5) The method of this invention proposes to fuse shallow features with target texture details and deep features with abstract semantic information with a feature pyramid and a Transformer module. By using self-attention in the Transformer module to replace the traditional calculation of pixel similarity, the dependencies between pixels can be effectively obtained. Furthermore, instead of the traditional method of dividing the input into blocks in the Transformer module, this method proposes to transform features into visual information and detect all possible visual information, regardless of the image content, thereby enabling the network to achieve considerable results on a smaller dataset.
[0031] (6) The present invention proposes a multi-scale feature fusion method, which combines shallow detailed information with deep information through cascaded upsampling to output a feature mask containing rich information, thereby completely locating the tampered source domain and target region. Attached Figure Description
[0032] Figure 1 This is a schematic diagram of the overall process of the present invention;
[0033] Figure 2 This is a schematic diagram of the residual super-resolution network;
[0034] Figure 3 This is a schematic diagram of the structure of a frequency domain information extraction network based on discrete cosine transform;
[0035] Figure 4 This is a schematic diagram of the cross-modal fusion network structure;
[0036] Figure 5 This is a schematic diagram of the feature extraction network structure;
[0037] Figure 6 This is a schematic diagram of the multi-scale fusion module. Detailed Implementation
[0038] The technical solution of the present invention will be described in detail below with reference to the accompanying drawings and specific embodiments, but this does not limit the scope of protection of this application.
[0039] This invention is a blind forensic method for small-target copy-paste tampering images (hereinafter referred to as the method, see [link]). Figures 1-6 This method comprises two stages, specifically including the following:
[0040] In the first stage, the input image is preprocessed, and the residual features of the preprocessed input image are extracted using a residual super-resolution network. The residual features are then super-resolutiond to obtain a super-resolution image.
[0041] Step 1.1: Preprocess the input image to obtain a preprocessed input image;
[0042] The input image is preprocessed to obtain a preprocessed input image. The input image is a low-resolution image with a resolution of 128×128 pixels. The preprocessing includes random cropping, random horizontal flipping, random scaling, and normalization operations. The expression for the preprocessing is shown in Equation (1):
[0043] W L =Normalize(TemporalRescale(RandomFlip(RandomCrop(I L (1)
[0044] In equation (1), I L W represents the input image. L This represents the input image for preprocessing. RandomCrop(·) represents the random cropping function, RandomFlip(·) represents the random horizontal flipping function, TemporalRescale(·) represents the random scaling function, and Normalize(·) represents the normalization function, which is used to convert the pixel values of the image to the range (0, 1).
[0045] Step 1.2: Establish a residual super-resolution network by inputting the preprocessed input image into the residual super-resolution network to obtain residual features and super-resolution image;
[0046] like Figure 2 As shown, the residual super-resolution network includes a feature activation unit module, a residual feature extraction module, and a feature pixel rearrangement module. First, the preprocessed input image is activated using the feature activation unit module, which includes convolution operations and activation functions. The preprocessed input image undergoes a 3×3 convolution operation, followed by activation using the PReLU activation function, resulting in activation features F∈R. 64×128×128 The first dimension of the activation feature is the channel dimension, and the second and third dimensions are the spatial size dimensions; the expression for activating the preprocessed input image is:
[0047] F = PRelu(Conv) 3×3 (W L (2)
[0048] In equation (2), Conv 3×3This represents a convolution operation with a kernel size of 3×3, and PRelu(·) represents a parameterized modified linear unit activation function.
[0049] Then, the residual feature X of the activation feature F is extracted using the residual feature extraction module. F ∈R 64×128×128 The residual feature extraction module comprises 16 residual blocks. The output of the previous residual block serves as the input to the next residual block, and is added point-by-point to the calculation result of the next residual block to obtain the output of the next residual block. Each residual block consists of multiple sequential convolutional structures and PReLU activation functions, specifically a Conv convolutional structure with a kernel size of 1×1. 1×1 PReLU activation function, Conv convolutional structure with a kernel size of 3×3 3×3 PReLU activation function, 1×1 convolutional kernel structure Conv 1×1 And the PRelu activation function; for the i-th residual block, its expression is shown in equation (3):
[0050] x i =RB i (x i-1 )+x i-1 (3)
[0051] In equation (3), RB i (·) represents the i-th residual block, x i-1 x i These represent the outputs of the (i-1)th and i-th residual blocks, respectively.
[0052] Residual feature X F The expression for is shown in equation (4):
[0053]
[0054] Finally, the residual features are super-resolutiond to a specified resolution using a feature pixel rearrangement module, resulting in a super-resolution image. This involves rearranging the channels of each pixel in the residual features along the channel dimension, with each pixel's channel corresponding to a sub-block in the feature map. This rearrangement transforms the residual features into a high-resolution image, i.e., the super-resolution image. The feature pixel rearrangement module includes two convolution operations and two sub-pixel convolution operations. After passing through this module, the residual features are super-resolutiond to the specified resolution, yielding a high-resolution super-resolution image. H The expression is shown in equation (5):
[0055] O H =PixelShuffle2(f Conv2D_1 (PixelShuffle2(f Conv2D_2 (X F(5)
[0056] Among them, f Conv2D_2 (·) represents a convolution operation with a kernel size of 3×3 and padding of 2, f Conv2D_1 (·) represents a convolution operation with a kernel size of 3×3 and padding of 1, and PixelShuffle2(·) represents a subpixel convolution operation with a sampling rate of 2.
[0057] Step 1.3: Train the residual super-resolution network to obtain the trained residual super-resolution network.
[0058] In the second stage, the tampered image is segmented at the pixel level to obtain a predicted segmentation map;
[0059] Step 2.1, modify image I L Preprocessing is performed to obtain the preprocessed tampered image W. F Since the input tampered images have inconsistent resolutions, the preprocessing mainly involves scaling the tampered images to a specified size and normalizing them.
[0060] Step 2.2, the preprocessed tampered image W F The input is fed into the trained residual super-resolution network to obtain residual features X with super-resolution properties. F and super-resolution image O H ;
[0061] Since tampered images contain information at multiple scales, when using copy-paste tampering methods, targets of different scales will be copied and pasted. Therefore, small-scale targets will inevitably be tampered with in the tampered image. Super-resolution of tampered images is to increase the resolution of the image so that the network can focus on small targets.
[0062] Step 2.3: Extract frequency domain features of the super-resolution image using a frequency domain information extraction network based on discrete cosine transform;
[0063] like Figure 3 As shown, the frequency domain information extraction network based on discrete cosine transform (DCT) includes DCT, an adaptive filter, and inverse DCT. First, the DCT transforms the super-resolution image from the spatial domain to the frequency domain, obtaining the frequency domain response. Then, the adaptive filter decomposes the super-resolution image into three frequency bands: low frequency, mid frequency, and high frequency, and the frequency domain response is multiplied by the adaptive filter using the Hadamard product. Finally, the inverse DCT transfers the frequency domain response back to the spatial domain, thereby extracting the frequency domain features F of the super-resolution image. fre The expression for the frequency domain characteristics is shown in equation (6):
[0064]
[0065] Where D(·) denotes the discrete cosine transform. This represents an adaptive filter. This represents the frequency domain band, where n = 1, 2, 3. Represents a binary filter. D represents the normalization operation, ⊙ represents the Hadamard product, and D -1 (·) denotes the inverse discrete cosine transform;
[0066] Since artifacts in tampered images are difficult to locate in the RGB domain after compression using the JPEG compression method, and these artifacts usually appear in an unusual frequency distribution compared to real images, this application extracts the frequency domain information of the super-resolution image, utilizes these unusual frequency distributions, and introduces them into a convolutional network to guide the network to focus on the tampered region, thereby further improving the detection capability of the tampered region.
[0067] Step 2.4: Use a cross-modal fusion network to fuse frequency domain features and residual features to obtain cross-domain features;
[0068] like Figure 4 As shown, the cross-modal fusion network fuses frequency domain features and residual features through a positional attention module. The residual features are spatial features, therefore, cross-modal fusion with the frequency domain features allows the frequency domain information to guide the cross-modal fusion network to focus on tampered regions. The positional attention module contains three parallel convolutional layers, each with a kernel size of 1 and zero padding. First, the residual features X... F With frequency domain feature F fre The inputs are fed into three convolutional layers respectively, and dimension adjustment is performed to obtain three features Q, K, and V, which are expressed as shown in formulas (7)-(9);
[0069] Q = Reshape(f) Conv1D_1 (F fre (7)
[0070] K = Reshape(f Conv1D_1 (X F (8)
[0071] V = Reshape(f) Conv1D_1 (X F (9)
[0072] Among them, f Conv1D_1 This indicates a convolution operation with a kernel size of 1 and padding of 1; Reshape indicates a dimension adjustment operation.
[0073] Next, feature Q is multiplied by the transpose of feature K, and then the positional attention feature E is obtained through an activation function. pa The expression is:
[0074]
[0075] In the formula, exp represents the logarithmic function with base e, T represents the transpose operation, j represents the pixel index in the feature map, and J represents the number of pixels.
[0076] Finally, the positional attention feature E pa Multiply by feature V, and then multiply the result by the residual feature X. F Adding them together yields the channel attention-enhanced cross-domain feature F. pa The expression is:
[0077]
[0078] Where γ represents a learnable parameter initialized to 0;
[0079] Step 2.5: Use a feature extraction network to extract multi-scale features for pixel-level representation;
[0080] like Figure 5 As shown, the feature extraction network includes a feature pyramid and a Transformer module. In this embodiment, the feature pyramid is composed of the first four convolutional modules of the ResNet50 network. Each convolutional module is connected to a Transformer module. Each feature extracted by the feature pyramid needs to be input into the corresponding Transformer module to evaluate the similarity between the local neighborhood and the global region in the feature map in order to obtain the dependency relationship between pixels in the feature.
[0081] First, the cross-domain features are input into the feature pyramid to extract features at four different scales. Its expression is:
[0082]
[0083] Where N = {1, 2, 3, 4} represents the number of scales, and C N Representation of features The channel dimension, the channel dimension C of each feature. N ={256,512,1024,2048}, Conv resnet50 (·) indicates a Resnet50 network;
[0084] Then, all extracted features The features are input into the corresponding Transformer module, which first processes the features... Perform dimensional adjustment operations to obtain features. Then, through the weight matrix W A ∈RHW×L The convolution operation will transform the features Converted into semantic information, semantic information and features After multiplication and activation, visual information T is obtained, as shown in equation (13):
[0085]
[0086] Where softmax(·) represents the activation operation;
[0087] The encoder in the Transformer module includes a multi-head self-attention and a multilayer perceptron module. Each head of self-attention includes L self-attention layers. Let Q', K', and V' be the attention features of the l-th self-attention layer of the k-th head of self-attention. Each attention feature is composed of its respective weight matrix and the visual information obtained from the (l-1)-th self-attention layer. Multiplying them together, we get the result, see equation (14);
[0088] Q' = T l-1 W Q' ,K'=T l-1 W K' V'=T l-1 W V' (14)
[0089] Among them, W Q' W K' , Represents the weight matrix;
[0090] The input SA of the k-th self-attention layer (l-1) k (T l-1 As shown in equation (15):
[0091]
[0092] Where d represents the dimension of attention features Q', K', and V';
[0093] The inputs of all head-self-attention layers at level l (1) are concatenated to obtain the input MSA(T) of the multi-head self-attention layer at level l (1). l-1 ), that is, MSA(T l-1 )=[SA1(T l-1 );...;SA k (T l-1 );...;SA 16 (T l-1 ));
[0094] Let the output of the (l-1)th layer of the multi-head self-attention be Z. l-1The outputs of the (l-1)th layer of the multi-head self-attention system are passed through a multilayer perceptron module and summed using residual connections to obtain the output of the lth layer of the multi-head self-attention system. The expression is shown in equation (16):
[0095] Z l =MSA(Z) l-1 )+MLP(MSA(Z l-1 (16)
[0096] MSA stands for Multi-head Self-Attention, and MLP stands for Multilayer Perceptron.
[0097] The output Z of the l-th layer of multi-head self-attention l The input is fed into the decoder of the Transformer module, and the output is restored to features that can be used for pixel-level representation, as shown in Equation (17):
[0098]
[0099] in, Represents the Nth feature The corresponding features used for pixel-level representation, Represents the learnable weight matrix;
[0100] Step 2.6: Use the multi-scale fusion module to fuse multi-scale features to more accurately locate the source and target regions, thereby obtaining the predicted segmentation map;
[0101] like Figure 6 As shown, the multi-scale fusion module includes cascaded convolutional and upsampling operations. In step 2.5, features at four scales are obtained, denoted as follows: These four features are respectively processed by a 1×1 convolution operation and a double upsampling operation to obtain four prediction masks M1, M2, M3, and M4 of the same scale. The expression of each prediction mask is as follows:
[0102]
[0103]
[0104]
[0105]
[0106] Among them, f Conv2d_1 (·) represents a convolution operation with a kernel size of 1×1, and Upsample2(·) represents a double upsampling operation;
[0107] The four prediction masks are transformed into the same dimension by a 3×3 convolution operation, and then added point by point to obtain the prediction segmentation map. The expression of the prediction segmentation map is shown in the following equation (22):
[0108]
[0109] Among them, f Conv2d_3 (·) indicates a convolution operation with a kernel size of 3×3. This indicates a point-by-point addition operation;
[0110] This completes the blind evidence collection of the small-target image copy-paste tampering.
[0111] The above-described blind forensics method for small-target copy-paste tampered images uses Residual Block (RB), Discrete Cosine Transform (DCT), and ResNet50 (Residual Network 50), all of which are well-known algorithms in this technical field. The hardware used is a computer with an RTX 3060 graphics card.
[0112] Any aspects not covered in this invention are applicable to existing technologies.
Claims
1. A blind forensic method for small-target copy-paste tampering images, characterized in that, This method consists of two stages, specifically including the following: In the first stage, the input image is preprocessed. The residual features of the preprocessed input image are extracted using a residual super-resolution network, and the residual features are super-resolutiond to obtain a super-resolution image. The residual super-resolution network comprises a feature activation unit module, a residual feature extraction module, and a feature pixel rearrangement module. The feature activation unit module includes convolution operations and activation functions, which activate the preprocessed input image to obtain activation features. The residual feature extraction module extracts residual features from the activation features. This module consists of multiple stacked residual blocks; the output of one residual block serves as the input to the next, and the results are added point-by-point to obtain the output of the next residual block. Each residual block consists of multiple sequential convolutional structures and activation functions. The feature pixel rearrangement module rearranges the residual features pixel by pixel to obtain the super-resolution image. This module includes convolution operations and sub-pixel convolution operations. In Phase Two, the tampered image is preprocessed and input into the trained residual super-resolution network to obtain residual features and the super-resolution image. Frequency domain features of the super-resolution image are extracted using a frequency domain information extraction network based on discrete cosine transform (DCT). This network includes DCT, adaptive filters, and inverse DCT. A cross-modal fusion network fuses frequency domain features and residual features through positional attention to obtain cross-domain features. Multi-scale features are extracted from the cross-domain features using a feature extraction network, which includes a feature pyramid and a Transformer module. Each feature extraction module in the feature pyramid is connected to a Transformer module, which obtains the dependencies between pixels in the features. A multi-scale fusion module fuses the multi-scale features. This module obtains prediction masks for the multi-scale features through convolution and upsampling operations. Each prediction mask is then convolved to the same dimension and added point-by-point to obtain the predicted segmentation map. This completes the blind evidence collection of the small-target image copy-paste tampering.
2. The blind evidence collection method for small-target copied-paste tampered images according to claim 1, characterized in that, The feature pixel rearrangement module includes two convolution operations and two sub-pixel convolution operations, expressed as follows: O H =PixelShuffle2(f Conv2D_1 (PixelShuffle2(f Conv2D_2 (X F )))) Among them, f Conv2D_2 (·) represents a convolution operation with a kernel size of 3×3 and padding of 2, f Conv2D_1 (·) represents a convolution operation with a kernel size of 3×3 and padding of 1, while PixelShuffle2(·) represents a subpixel convolution operation with a sampling rate of 2.
3. The blind evidence collection method for small-target copy-paste tampered images according to claim 1 or 2, characterized in that, The residual block includes a convolutional structure with a kernel size of 1×1, a PRelu activation function, a convolutional structure with a kernel size of 3×3, a PRelu activation function, a convolutional structure with a kernel size of 1×1, and a PRelu activation function.
4. The blind evidence collection method for small-target copied-paste tampered images according to claim 1, characterized in that, The frequency domain information extraction network based on discrete cosine transform first transforms the super-resolution image from the spatial domain to the frequency domain to obtain the frequency domain response. Then, it uses an adaptive filter to decompose the super-resolution image into three frequency domain bands: low frequency, mid frequency, and high frequency, and performs a Hadamard product between the frequency domain response and the adaptive filter. Finally, it performs an inverse discrete cosine transform to transfer the frequency domain response to the spatial domain, thereby extracting the frequency domain features of the super-resolution image.
5. The blind forensic method for small-target copy-paste tampered images according to claim 1 or 4, characterized in that, All features extracted from the feature pyramid are input into the corresponding Transformer module. The Transformer module performs dimensionality adjustment on the input features and then converts the dimensionality-adjusted features into semantic information through convolution. The semantic information is multiplied with the input features of the Transformer module and then activated to obtain visual information. The encoder of the Transformer module includes a multi-head self-attention and a multilayer perceptron module. Each self-attention module includes multiple self-attention layers. The attention features of each self-attention layer are obtained by multiplying its weight matrix with the visual information obtained from the previous self-attention layer.
6. The blind evidence collection method for small-target copied-paste tampered images according to claim 1, characterized in that, The preprocessing in Stage 1 includes random cropping, random horizontal flipping, random scaling, and normalization operations, while the preprocessing in Stage 2 includes normalization operations.