An improved multi-scale image tampered region positioning method

Through the multi-scale image tampering area localization method, cascaded convolutional neural networks and void convolutional networks are used to extract multi-scale tampering features, and combined with the attention mechanism and adaptive loss function, the high false negative rate and classification bias problems of existing methods in detecting unknown tampering types are solved, and the positioning accuracy of the tampered area is improved.

CN115471733BActive Publication Date: 2025-10-10SICHUAN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211149912.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-21
Publication Date
2025-10-10
Estimated Expiration
2042-09-21

AI Technical Summary

Technical Problem

Existing image tampering detection methods perform poorly when faced with unknown tampering types and are prone to losing detailed features of the tampered area, resulting in a high false negative rate. They also have low detection accuracy for tampered areas that do not contain significant objects and suffer from classification bias.

Method used

A multi-scale image tampering region localization method is adopted, and multi-scale tampering features are extracted using cascaded convolutional neural networks and void convolutional networks. The features are fused by combining channel and spatial attention mechanisms, and the model is optimized using the binary cross entropy loss function with adaptive weights.

Benefits of technology

It reduces the missed reporting rate of tampered pixels, improves the accuracy of locating tampered areas, reduces the preference for semantic content, improves classification bias, and enhances the robustness of the model.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115471733B_ABST
    Figure CN115471733B_ABST
Patent Text Reader

Abstract

The application discloses an improved multi-scale image tampering region positioning method, in order to solve the shortage of the prior art, through the feature acquisition module, the input high-frequency feature component is collected shallow tampering feature component by using the cascaded convolutional neural network, and the collected minimum scale shallow tampering feature component is sent into the hollow convolution network, and the deep layer tampering feature component is output; the deep layer tampering feature component is sent into the attention mechanism fusion module, the channel attention weight map and the spatial attention weight map are calculated respectively, and the matrix multiplication is used to respectively distribute the weight in the space and the channel dimension of the deep layer tampering feature component, and then the feature fusion module is used for feature fusion output to obtain the fusion tampering feature component; the fusion tampering feature component and the shallow tampering feature component are fused through the three-level deconvolution network to gradually reconstruct the tampering region positioning effect picture.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of image tampering, region positioning, etc., and in particular to an improved multi-scale image tampering region positioning method. BACKGROUND

[0002] Compared with text information, images have the advantages of intuitive and concise in expressing content, and are an important information dissemination carrier in modern society. With the continuous development of computer technology, a batch of digital image editing tools such as Photoshop and Meitu Xiu Xiu have emerged in the market. With the help of these tools, people can modify images according to their own preferences without professional knowledge, and share and spread them on social platforms. However, while image editing has become easy, the authenticity of image content has been questioned. Some images can achieve the effect of being difficult to distinguish after being skillfully processed by forgers, so that it is difficult for the human eye to directly judge whether the image seen is modified. Common image tampering operations include copy-paste, splicing and erase-fill. Copy-paste is a tampering behavior of pasting the copied original image part area to the spatial position adjacent or not adjacent area; splicing is a tampering behavior of copying the area of an image to cover the area of another image; and erase-fill is a tampering behavior of replacing the pixel value of the selected image area with the pixel value of the adjacent texture. Once the maliciously tampered image is used in an inappropriate way, it may cause difficult to eliminate adverse effects on individuals, society and even the country. In order to avoid the potential adverse effects of tampered images being used intentionally, many scholars have made a lot of explorations and researches on image tampering detection methods.

[0003] The goal of localizing tampered image regions is to determine whether a pixel in a given image is tampered or original. The predicted result is then mapped back to the pixel's original spatial location in the image to obtain a localized image of the tampered region. This is essentially a binary classification image region segmentation problem. Existing passive image tampering detection methods are primarily based on two approaches: manual feature extraction and deep learning. Manual feature extraction methods primarily extract handcrafted features from the image to be detected and then use machine learning classifiers to analyze potential tampered regions. The major drawback of these methods is that they can only detect specific types of tampered images based on pre-determined assumptions, making them ineffective for images containing unknown types of tampering. Since the astonishing performance of AlexNet on the ImageNet Challenge image classification task in 2012, deep learning has become an indispensable tool in computer vision tasks such as object detection, semantic segmentation, and pose estimation. Compared to traditional machine learning, which requires tedious manual feature design, deep learning leverages the inherent regularities between data at different levels, mimicking the neuronal communication mechanisms of the human brain to automatically learn and model the target task. More and more researchers are applying deep learning networks to the field of image tampering area localization. This aims to leverage the powerful feature learning capabilities of neural networks to adaptively capture potential tampering clues in image data. This approach can also demonstrate robustness and accuracy when detecting images containing complex tampering operations. However, several issues remain:

[0004] 1. Convolutional neural networks are currently the mainstream deep learning architecture in the field of computer vision. They not only convert high-dimensional input features into low-dimensional features, but also effectively preserve the positional relationships and local spatial characteristics between adjacent pixels, making them excellent at processing image-based data. To capture information about large objects in an image, each pixel in the feature map output by a convolutional network must correspond to a sufficiently large area within the image. Existing methods typically achieve this by increasing the depth of stacked convolutional neural networks. However, as the depth of the convolutional neural network increases, the multiple downsampling operations it incorporates gradually lose detailed features of the tampered area, resulting in a high false negative rate in the final predicted tampered area.

[0005] 2. In real scenes, the semantic content contained in the tampered image region may be one or more salient objects with clear edges and outlines, such as vehicles and animals, or it may be some smooth background areas, such as grass and sky. A good image tampered region localization method should focus on tampered regions unrelated to semantic content, but most tampered region localization methods still tend to focus on tampered regions in the image scene that contain salient objects, and the detection accuracy of tampered regions that do not contain salient objects is low.

[0006] 3. The number of tampered pixels in existing public datasets of tampered images is far less than the number of non-tampered pixels, and the numerical ratio between the two is seriously unbalanced. This causes deep learning models to tend to learn the features of non-tampered pixels when trained using these datasets, resulting in serious classification bias. In actual applications, the model may misjudge a large number of tampered pixels as non-tampered pixels, resulting in a high false alarm rate. Summary of the Invention

[0007] The purpose of the present invention is to provide an improved multi-scale image tampering area localization method, which uses a hollow convolutional network in deep feature extraction to maintain the scale of the deep feature component unchanged while expanding the receptive field, thereby reducing the loss of tampering detail information; cross-layer fusion of shallow tampering feature components and deep tampering feature components of the same scale enhances the model's perception of global tampering details when reconstructing the tampered area.

[0008] The present invention is implemented by the following technical solution: an improved multi-scale image tampering area positioning method, comprising the following steps:

[0009] 1) The feature acquisition module uses a cascaded convolutional neural network to collect shallow tampering feature components of different scales containing global tampering feature information from the input high-frequency feature component f0, and sends the collected shallow tampering feature components of the smallest scale into the hollow convolutional network to output the deep tampering feature component f5; wherein, the acquisition module is provided with a three-level convolutional neural network and a two-level hollow convolutional network, each of which is provided with a convolution layer, an average pooling layer and an activation function for realizing continuous operation; each hollow convolutional network is provided with a hollow convolution layer and an activation function for realizing continuous operation;

[0010] 2) The deep tampering feature component f5 is sent to the attention mechanism fusion module including the channel attention mechanism module and the spatial attention mechanism module, and the channel attention weight map M is calculated respectively. C (f5) and spatial attention weight map M S (f5), and after using matrix multiplication to distribute weights with the deep tampering feature component f5 in the spatial and channel dimensions, the feature fusion module is used to perform feature fusion output to obtain the fused tampering feature component f6 with more prominent tampering trace expression;

[0011] 3) The tampered feature component f6 and the shallow tampered feature component are fused at the same scale through a cross-layer feature connection reconstruction module equipped with a three-level deconvolution network and a Sigmoid function, thereby gradually reconstructing the tampered area positioning effect map;

[0012] 4) The error between the tampered area positioning effect image and the tampered area actually marked in the input image is calculated using the binary cross entropy loss function with pixel-level adaptive weights to guide the entire network to optimize parameters in the optimal direction.

[0013] In order to better realize the improved multi-scale image tampering region positioning method described in the present invention, the following setting is particularly adopted: it also includes collecting a tampered image data set, normalizing the tampered image data, and using a high-pass filter layer to filter out a high-frequency feature component f0 with a scale of w×h×3, where w represents width, h represents height, and 3 represents the number of channels of the high-frequency feature component f0; when performing normalization, it is realized by the following formula: P′ v =P v ÷255, where P v Represents the original pixel value, P' v Represents the normalized pixel value; the high-pass filter layer is a convolution layer consisting of three fixed parameters and a 5×5 convolution kernel size.

[0014] To further implement the improved multi-scale image tampering region localization method of the present invention, the following configuration is particularly adopted: Step 1) includes the following specific steps:

[0015] 1.1) The high-frequency feature component f0 passes through the first-level convolutional neural network, and the output is a shallow tampering feature component with a scale of (w / 2)×(h / 2)×16;

[0016] 1.2) The shallow tampering feature component obtained in step 1.1) is passed through a second-stage convolutional neural network to output a shallow tampering feature component with a scale of (w / 4)×(h / 4)×32;

[0017] 1.3) The shallow tampering feature components obtained in step 1.2) are passed through a third-level convolutional neural network to output shallow tampering feature components with a scale of (w / 8)×(h / 8)×64;

[0018] 1.4) Input the shallow tampering feature component obtained in step 1.3) into the first-level dilated convolutional network, and output the tampering feature component with a scale of (w / 8)×(h / 8)×128;

[0019] 1.5) Input the tampering feature component obtained in step 1.4) into the second-level dilated convolutional network, and output a deep tampering feature component f5 with a scale of (w / 8)×(h / 8)×64.

[0020] In order to better realize the improved multi-scale image tampering region positioning method of the present invention, the following setting is particularly adopted: the deep tampering feature component f5 is subjected to the channel attention weight map M in the channel attention mechanism module. C(f5) is calculated using the following formula:

[0021]

[0022] in, and They represent the results of global average pooling and global maximum pooling operations on the deep tampering feature component f5 respectively; MLP(·) represents a multi-layer perceptron with a hidden layer, which consists of two neural network layers, and the activation function in the hidden layer is ReLU; σ(·) represents the Sigmoid activation function, and the calculation formula of the Sigmoid activation function is as follows:

[0023] x is the input variable, and the Sigmoid function is the calculation result;

[0024] The deep tampering feature component f5 is subjected to the spatial attention weight map M in the spatial attention mechanism module. S (f5) is calculated using the following formula:

[0025] M S (f5)=σ(F 7×7 ([AvgP c (f5);MaxP c (f5)])),

[0026] Among them, F 7×7 (·) represents the convolution operation with a kernel size of 7×7; AvgP c (·) indicates that the input features are globally averaged pooled in the channel dimension. The dimension of global average pooling is 1*w*h, where w represents the width of the input feature and h represents the height of the input feature. MaxP c (·) indicates that the global maximum pooling is performed on the input features in the channel dimension. The dimension of the global maximum pooling is 1*w*h, where w represents the width of the input feature and h represents the height of the input feature.

[0027] When the feature fusion module performs feature fusion, it is achieved through the following formula:

[0028]

[0029] in represents the element-wise multiplication operation, represents an element-by-element addition operation, and the scale of f6 is (w / 8)×(h / 8)×64.

[0030] To further implement the improved multi-scale image tampering region localization method of the present invention, the following configuration is particularly adopted: Step 3) is specifically as follows:

[0031] 3.1) The shallow tampering feature components obtained by fusing the tampering feature components and the third-level convolutional neural network are spliced ​​in the first-level deconvolution network and then output;

[0032] 3.2) The output of step 3.1) is concatenated with the shallow tampering feature component obtained by the second-level convolutional neural network in the second-level deconvolutional network, and then output;

[0033] 3.3) The output of step 3.2) is concatenated with the shallow tampering feature component obtained by the first-level convolutional neural network in a third-level deconvolutional network and output;

[0034] 3.4) The output of step 3.4) is activated by the Sigmoid function to obtain the probability value of each pixel, with a value range of [0, 1]. When the probability value is greater than the threshold of 0.5, it is classified as a tampered pixel; when the probability value is less than the threshold of 0.5, it is classified as a non-tampered pixel. After the classification is completed, the final reconstructed tampering area positioning effect map can be obtained.

[0035] In order to achieve this improved multi-scale image tampering region positioning, the present invention also provides an improved multi-scale image tampering region positioning model, which has the characteristics of reducing the loss of tampering detail information and reducing the false alarm rate of tampering pixel recognition. The fusion of features extracted by the two attention mechanisms can effectively suppress the model's preference for the semantic content of the tampered area and improve the positioning accuracy of the tampered area; the model includes a feature acquisition module for realizing multi-scale tampering feature acquisition, an attention mechanism fusion module with a dual-branch structure, and a cross-layer feature connection reconstruction module;

[0036] The feature acquisition module uses a cascaded convolutional neural network to collect shallow tampering feature components of different scales that contain global tampering feature information, and feeds the collected shallow tampering feature components of the smallest scale into a dilated convolutional network to output deep tampering feature components;

[0037] The attention mechanism fusion module is based on the combination of spatial attention mechanism and channel attention mechanism to suppress the model structure's preference for the semantic content of the tampered area, and finally outputs the fused tampered feature component;

[0038] The cross-layer feature connection reconstruction module uses the shallow tampering feature components and the fused tampering feature components collected by the feature collection module to perform cross-layer fusion of the same scale, and gradually reconstructs the tampering area positioning effect map.

[0039] In order to further better realize the improved multi-scale image tampering area positioning model described in the present invention, the following setting is particularly adopted: it also includes a high-pass filter layer for extracting high-frequency feature components of the tampered image data after normalization, and the extracted high-frequency feature components (scale is w×h×3, where w represents width, h represents height, and 3 represents the number of high-frequency feature component channels) will be transmitted to the feature acquisition module for subsequent processing; wherein, the high-pass filter layer is a convolution layer composed of three fixed parameters and a convolution kernel of size 5×5.

[0040] In order to further better realize the improved multi-scale image tampering area positioning model described in the present invention, the following setting is particularly adopted: the feature acquisition module is provided with a three-level convolutional neural network and a two-level void convolutional network, each convolutional neural network is provided with a convolution layer, an average pooling layer and an activation function for realizing continuous operation; each void convolutional network is provided with a void convolution layer and an activation function for realizing continuous operation; wherein, the convolution layer input channel of the first-level convolutional neural network is 3, and the output channel is 16; the convolution layer input channel of the second-level convolutional neural network is 16, and the output channel is 32; the convolution layer input channel of the third-level convolutional neural network is 16, and the output channel is 64; the specific values ​​of the convolution kernel size, padding and step size of all convolutional layers are 5×5, 2 and 1 respectively; the pooling window size and step size of all average pooling layers are 2×2 and 2 respectively; the activation function selects the ReLU function. The calculation formula of the ReLU function is as follows:

[0041] When the input variable x is greater than 0, the calculation result of ReLU(x) is x; when the input variable x is less than 0, the calculation result of ReLU(x) is 0.

[0042] The first-level atrous convolutional network has 64 input channels and 128 output channels; the second-level atrous convolutional network has 128 input channels and 64 output channels; the specific values ​​of the convolution kernel size, padding, stride, and atrous rate of the two atrous convolutional layers are 3×3, 2, 1, and 2, respectively, and the activation function is ReLU.

[0043] In order to further better realize the improved multi-scale image tampering area positioning model described in the present invention, the following setting method is particularly adopted: the attention mechanism fusion module is provided with a channel attention mechanism module, a spatial attention mechanism module, two matrix multiplications and a feature fusion module. The channel attention mechanism module is used to realize the calculation of the channel attention weight map, and the spatial attention mechanism module is used to realize the calculation of the spatial attention weight map. The calculated channel attention weight map and spatial attention weight map are respectively weighted with the deep tampering feature components by matrix multiplication, and then feature fusion is performed through the feature fusion module to output a fused tampering feature component with more prominent tampering trace expression.

[0044] Furthermore, in order to better realize the improved multi-scale image tampering area positioning model described in the present invention, the following setting is particularly adopted: the cross-layer feature connection reconstruction module is provided with a three-level deconvolution network and a Sigmoid function, and the fused tampering feature component and the shallow tampering feature component are fused across layers of the same scale through a three-level deconvolution network, and then through the Sigmoid function, the tampering area positioning effect diagram is finally reconstructed.

[0045] Among them, each deconvolution network is equipped with a deconvolution layer and activation function to realize continuous operation; the number of input channels of the deconvolution layer of the first-level deconvolution network is 128, and the number of output channels is 32; the number of input channels of the deconvolution layer of the second-level deconvolution network is 64, and the number of output channels is 16; the number of input channels of the deconvolution layer of the third-level deconvolution network is 32, and the number of output channels is 1; the specific values ​​of the convolution kernel size, padding and step size of the convolution layer contained in the three-level deconvolution neural network are 2×2, 0 and 2 respectively, and the activation function is the ReLU function.

[0046] Compared with the prior art, the present invention has the following advantages and beneficial effects:

[0047] (1) The present invention proposes a multi-scale feature cross-layer fusion structure consisting of two modules: multi-scale tampering feature acquisition and cross-layer feature connection reconstruction. The multi-scale tampering feature acquisition uses a cascaded convolutional neural network to collect shallow feature components with different scales that contain global tampering feature information, and uses a hollow convolutional network in the extraction of deep feature components to maintain the scale of the deep feature components unchanged while expanding the receptive field, thereby reducing the loss of tampering detail information. At the same time, the cross-layer feature connection reconstruction module integrates shallow tampering feature components of different scales into the tampering area positioning, enhancing the model's ability to perceive global tampering details when reconstructing the tampering area, thereby reducing the missed reporting rate of tampering pixel point recognition.

[0048] (2) The dual-branch attention module proposed in this paper can effectively suppress the model's preference for the semantic content of the tampered area and improve the accuracy of locating the tampered area.

[0049] (3) The binary cross-entropy loss function with adaptive weight proposed by the application makes the model optimize parameters in the best direction, greatly improves the pixel point classification bias problem, and reduces the false positive rate of pixel classification.

[0050] (4) The convolutional neural network is the mainstream deep learning architecture in the field of computer vision at present, which can not only convert the input high-dimensional features into low-dimensional features, but also can well preserve the position relationship and local spatial features between adjacent pixels, and has good performance in processing image type data. In order to obtain stable and rich deep tampering features, each pixel point in the feature map output by the convolutional neural network must respond to a large enough area in the tampered image. Most methods use the depth of stacked convolutional neural network to achieve this effect. However, with the increase of the depth of the convolutional neural network, the multiple downsampling operations contained in the convolutional neural network will gradually lose the detail features of the tampered area, resulting in a high false negative rate of the tampered pixel points in the final reconstructed tampered area positioning map. In view of the above problems, the application uses the cascaded convolutional neural network to collect shallow feature components containing global tampering feature information and different scales, and uses the empty convolution network to maintain the scale of the deep feature component unchanged while expanding the receptive field during the extraction of the deep feature component, thereby reducing the loss of tampering detail information. The cross-layer feature connection reconstruction module is set to fuse the previously collected shallow tampering feature components in the same scale when the deep tampering feature components are used for tampering area reconstruction, so as to fill the lost global tampering information for the deep tampering feature, and strengthen the perception ability of the model to the global tampering details during the tampering area reconstruction, thereby reducing the false negative rate of the tampered pixel point identification.

[0051] (5) In real scenes, the semantic content contained in the image tampering area may be one or more significant objects with clear edge contours, such as vehicles, animals, etc., or some smooth background areas, such as grass, sky, etc. A good image tampering area positioning method should focus on the tampering area that is irrelevant to the semantic content, but the existing image tampering area positioning method still tends to focus on the semantic content in the image data, that is, the detection accuracy of the tampering area containing significant objects is higher, and the detection accuracy of the tampering area not containing significant objects is lower. In response to the above problems, the present invention constructs an attention mechanism fusion module that combines the spatial attention mechanism and the channel attention mechanism between the feature acquisition module and the cross-layer feature connection reconstruction module. Among them, the spatial attention mechanism module can guide the model to pay attention to the location of meaningful tampering features in the spatial dimension; the channel attention mechanism module assigns weights according to the richness of tampering traces between the channels of the input features. The channels with richer tampering traces have a greater weight, and the channels with poorer tampering traces have a smaller weight, which strengthens the expression of tampering feature channels to a certain extent. Fusing the features extracted by the two attention mechanisms can effectively suppress the model's preference for the semantic content of the tampered area and improve the accuracy of locating the tampered area.

[0052] (6) The number of tampered pixels in the existing public datasets of tampered images is far less than the number of non-tampered pixels, and the numerical ratio of the two is seriously unbalanced. This leads to the tendency of deep learning networks to learn the features of non-tampered pixels when using these datasets for training. When actually detecting tampered images, tampered pixels will be judged as non-tampered pixels on a large scale, resulting in classification bias. In response to the above problem, the present invention proposes a binary cross entropy loss function with adaptive weights to guide network parameter optimization. The actual value of the adaptive weight is determined by the actual ratio of the number of tampered pixels to the number of non-tampered pixels in the input image. The purpose of this is to increase the contribution of the smaller number of tampered pixels or non-tampered pixel samples to the error calculation, correct the optimization direction of the deep learning network, improve the classification bias problem of the deep learning model, and reduce the false alarm rate of pixel classification. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] Figure 1 This is an architectural diagram of the model described in the present invention.

[0054] Figure 2 These are the specific parameters of the high-pass filter layer described in the present invention. DETAILED DESCRIPTION

[0055] The present invention will be further described in detail below with reference to the examples, but the embodiments of the present invention are not limited thereto.

[0056] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the invention for which protection is sought, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.

[0057] The present invention proposes an improved multi-scale image tampering region localization model and method. The multi-scale feature cross-layer fusion structure consists of two modules: a feature acquisition module that realizes multi-scale tampering feature acquisition and a cross-layer feature connection reconstruction module. The feature acquisition module uses a cascaded convolutional neural network to collect shallow tampering feature components of different scales that contain global tampering feature information, and uses a hollow convolutional network in deep feature extraction to maintain the scale of the deep feature components unchanged while expanding the receptive field, thereby reducing the loss of tampering detail information. The cross-layer feature connection reconstruction module uses the shallow tampering feature components and deep tampering feature components collected by the multi-scale tampering feature acquisition module to perform cross-layer fusion of the same scale, thereby enhancing the model's perception of global tampering details when reconstructing the tampered area. In addition, in order to enhance the model's focus on tampering trace features, the present invention constructs a dual-branch attention mechanism fusion module that combines a spatial attention mechanism and a channel attention mechanism between the feature acquisition module and the cross-layer feature connection reconstruction module to suppress the model's preference for the semantic content of the tampered area. To address the pixel classification bias problem that occurs in deep learning models when using existing public tampered datasets, this paper proposes an adaptive weighted binary cross entropy loss function to guide the entire network to optimize parameters in the optimal direction.

[0058] Example 1:

[0059] The present invention designs an improved multi-scale image tampering region localization model, which has the characteristics of reducing the loss of tampering detail information and lowering the false alarm rate of tampering pixel point identification. The fusion of features extracted by two attention mechanisms can effectively suppress the model's preference for the semantic content of the tampered area and improve the accuracy of tampering area localization. The model includes a feature acquisition module for realizing multi-scale tampering feature acquisition, an attention mechanism fusion module with a dual-branch structure, and a cross-layer feature connection reconstruction module.

[0060] The feature acquisition module uses a cascaded convolutional neural network to collect shallow tampering feature components of different scales that contain global tampering feature information, and feeds the collected shallow tampering feature components of the smallest scale into a dilated convolutional network to output a deep tampering feature component;

[0061] The attention mechanism fusion module is based on the combination of spatial attention mechanism and channel attention mechanism to suppress the model structure's preference for the semantic content of the tampered area, and finally outputs the fused tampered feature component;

[0062] The cross-layer feature connection reconstruction module uses the shallow tampering feature components and the fused tampering feature components collected by the feature collection module to perform cross-layer fusion of the same scale, and gradually reconstructs the tampering area positioning effect map.

[0063] Example 2:

[0064] This embodiment is further optimized on the basis of the above embodiment, and the similarities with the above technical solutions are not repeated here. Further, in order to better realize the improved multi-scale image tampering region positioning model described in the present invention, the following setting method is particularly adopted: it also includes a high-pass filter layer for extracting high-frequency feature components from the tampered image data after normalization. The extracted high-frequency feature components (scale is w×h×3, where w represents width, h represents height, and 3 represents the number of high-frequency feature component channels) will be delivered to the feature acquisition module for subsequent processing; wherein, the high-pass filter layer is a convolution layer composed of three convolution kernels with fixed parameters and a size of 5×5. The specific parameters of the 3 convolution kernels are as follows: Figure 2 shown.

[0065] Example 3:

[0066] This embodiment is further optimized on the basis of any of the above embodiments, and the similarities with the above technical solutions are not repeated here. In order to better realize the improved multi-scale image tampering area positioning model described in the present invention, the following setting method is particularly adopted: the feature acquisition module is provided with a three-level convolutional neural network and a two-level hole convolutional network, and each convolutional neural network is provided with a convolution layer, an average pooling layer and an activation function for realizing continuous operation; each hole convolutional network is provided with a hole convolution layer and an activation function for realizing continuous operation; wherein, the convolution layer input channel of the first-level convolutional neural network is 3, and the output channel is 16; the convolution layer input channel of the second-level convolutional neural network is 16, and the output channel is 32; the convolution layer input channel of the third-level convolutional neural network is 16, and the output channel is 64; the specific values ​​of the convolution kernel size, padding and step size of all convolutional layers are 5×5, 2 and 1 respectively; the pooling window size and step size of all average pooling layers are 2×2 and 2 respectively; the activation function selects the ReLU function. The calculation formula of the ReLU function is as follows:

[0067] When the input variable x is greater than 0, the calculation result of ReLU(x) is x; when the input variable x is less than 0, the calculation result of ReLU(x) is 0.

[0068] The first-level atrous convolutional network has 64 input channels and 128 output channels; the second-level atrous convolutional network has 128 input channels and 64 output channels; the specific values ​​of the convolution kernel size, padding, stride, and atrous rate of the two atrous convolutional layers are 3×3, 2, 1, and 2, respectively, and the activation function is ReLU.

[0069] Example 4:

[0070] This embodiment is further optimized on the basis of any of the above embodiments, and the similarities with the above technical solutions are not repeated here. Further, in order to better realize the improved multi-scale image tampering area positioning model described in the present invention, the following setting method is particularly adopted: the attention mechanism fusion module is provided with a channel attention mechanism module, a spatial attention mechanism module, two matrix multiplications and a feature fusion module. The channel attention mechanism module is used to realize the calculation of the channel attention weight map, and the spatial attention mechanism module is used to realize the calculation of the spatial attention weight map. The calculated channel attention weight map and spatial attention weight map are respectively weighted with the deep tampering feature components by matrix multiplication, and then feature fusion is performed through the feature fusion module to output the fused tampering feature component with more prominent tampering trace expression.

[0071] Example 5:

[0072] This embodiment is further optimized on the basis of any of the above embodiments, and the similarities with the above technical solutions are not repeated here. In order to better realize the improved multi-scale image tampering area positioning model described in the present invention, the following setting method is particularly adopted: the cross-layer feature connection reconstruction module is provided with a three-level deconvolution network and a Sigmoid function, and the fused tampering feature component and the shallow tampering feature component are cross-layer fused at the same scale through the three-level deconvolution network, and then the Sigmoid function is used to finally reconstruct the tampering area positioning effect diagram.

[0073] Each of the deconvolutional networks is provided with a deconvolutional layer and an activation function for realizing continuous operation; the deconvolutional layer of the first deconvolutional network has 128 input channels and 32 output channels; the deconvolutional layer of the second deconvolutional network has 64 input channels and 16 output channels; the deconvolutional layer of the third deconvolutional network has 32 input channels and 1 output channel; the convolution kernel size, padding and step length of the convolutional layer included in the three deconvolutional neural networks are respectively 2x2, 0 and 2, and the activation function is ReLU function.

[0074] Embodiment 6

[0075] An improved multi-scale image tampered region positioning method is realized based on an improved multi-scale image tampered region positioning model, comprising the following steps:

[0076] 1) The feature acquisition module uses a cascaded convolutional neural network to acquire shallow tampered feature components containing global tampered feature information and different scales from the input high-frequency feature component f0, and sends the shallow tampered feature component with the smallest scale to a hollow convolutional network to output a deep tampered feature component f5; wherein the acquisition module is provided with three convolutional neural networks and two hollow convolutional networks, each of which is provided with a convolutional layer, an average pooling layer and an activation function for realizing continuous operation; each hollow convolutional network is provided with a hollow convolutional layer and an activation function for realizing continuous operation;

[0077] 2) The deep tampered feature component f5 is sent to an attention mechanism fusion module comprising a channel attention mechanism module and a spatial attention mechanism module, and the channel attention weight map M C (f5) and the spatial attention weight map M S (f5) are calculated respectively, and after weight distribution in the spatial and channel dimensions by using matrix multiplication, the feature fusion module is used for feature fusion to output a fusion tampered feature component f6 with more prominent tampered trace expression;

[0078] 3) The fusion tampered feature component f6 and the shallow tampered feature component are subjected to cross-layer fusion of the same scale by a cross-layer feature connection reconstruction module provided with a three-level deconvolutional network and a Sigmoid function, so as to gradually reconstruct a tampered region positioning effect picture;

[0079] 4) The tampered region positioning effect picture and the tampered region of the input image true label are calculated for error by using a pixel-level adaptive weight binary cross-entropy loss function, so as to guide the whole network to optimize the parameters in the best direction; wherein the calculation formula of the adaptive weight binary cross-entropy loss function L cla is as follows:

[0080]

[0081] Where N represents the total number of pixels in the tampered area positioning effect map; i represents the actual label of the i-th pixel, i.e., tampered pixel or non-tampered pixel, usually represented by 0 or 1 respectively; i represents the predicted probability of the i-th pixel, and its value range is [0,1]; w represents the weight value, and its calculation formula is as follows:

[0082]

[0083] N0 represents the number of non-tampered pixels in the input image, and N1 represents the number of tampered pixels in the input image. The purpose of setting weights is to increase the contribution of the smaller number of tampered or non-tampered pixel samples to the error calculation, correct the model's optimization direction, optimize the model parameters toward the optimal direction, improve pixel classification bias, and reduce the false positive rate of pixel classification.

[0084] Example 7:

[0085] This embodiment is further optimized on the basis of the above embodiment, and the similarities with the above technical solutions are not repeated here. Further, in order to better realize the improved multi-scale image tampering area positioning method described in the present invention, the following setting method is particularly adopted: it also includes collecting a tampered image data set, normalizing the tampered image data, and using a high-pass filter layer to filter out a high-frequency feature component f0 with a scale of w×h×3, where w represents width, h represents height, and 3 represents the number of channels of the high-frequency feature component f0; when performing normalization, it is realized by the following formula: P′ v =P v ÷255, where P v Represents the original pixel value, P' v Represents the normalized pixel value; the high-pass filter layer is a convolution layer consisting of three fixed parameters and a 5×5 convolution kernel size.

[0086] Example 8:

[0087] This embodiment is further optimized on the basis of embodiment 6 or 7. The similarities with the above technical solutions are not repeated here. In order to better implement the improved multi-scale image tampering area positioning method of the present invention, the following setting is particularly adopted: step 1) includes the following specific steps:

[0088] 1.1) The high-frequency feature component f0 passes through the first-level convolutional neural network, and the output is a shallow tampering feature component with a scale of (w / 2)×(h / 2)×16;

[0089] 1.2) The shallow tampering feature component obtained in step 1.1) is passed through a second-stage convolutional neural network to output a shallow tampering feature component with a scale of (w / 4)×(h / 4)×32;

[0090] 1.3) The shallow tampering feature components obtained in step 1.2) are passed through a third-level convolutional neural network to output shallow tampering feature components with a scale of (w / 8)×(h / 8)×64;

[0091] 1.4) Input the shallow tampering feature component obtained in step 1.3) into the first-level dilated convolutional network, and output the tampering feature component with a scale of (w / 8)×(h / 8)×128;

[0092] 1.5) Input the tampering feature component obtained in step 1.4) into the second-level dilated convolutional network, and output a deep tampering feature component f5 with a scale of (w / 8)×(h / 8)×64.

[0093] Example 9:

[0094] This embodiment is further optimized on the basis of embodiment 6, 7 or 8, and the similarities with the above technical solutions are not repeated here. In order to better realize the improved multi-scale image tampering area positioning method described in the present invention, the following setting is particularly adopted: the deep tampering feature component f5 is subjected to the channel attention weight map M in the channel attention mechanism module. C (f5) is calculated using the following formula:

[0095]

[0096] in, and They represent the results of global average pooling and global maximum pooling operations on the deep tampering feature component f5 respectively; MLP(·) represents a multi-layer perceptron with a hidden layer, which consists of two neural network layers, and the activation function in the hidden layer is ReLU; σ(·) represents the Sigmoid activation function, and the calculation formula of the Sigmoid activation function is as follows:

[0097] x is the input variable, and the Sigmoid function is the calculation result;

[0098] The deep tampering feature component f5 is subjected to the spatial attention weight map M in the spatial attention mechanism module. S (f5) is calculated using the following formula:

[0099] M S (f5)=σ(F 7×7 ([AvgP c (f5);MaxPc (f5)])),

[0100] wherein, F 7×7 (·) represents a convolution operation with a kernel size of 7x7; AvgP c (·) represents global average pooling on the input feature in the channel dimension, and the dimension of the global average pooling is 1*w*h, wherein w represents the width of the input feature, and h represents the height of the input feature; MaxP c (·) represents global maximum pooling on the input feature in the channel dimension, and the dimension of the global maximum pooling is 1*w*h, wherein w represents the width of the input feature, and h represents the height of the input feature;

[0101] When the feature fusion module performs feature fusion, the following formula is used:

[0102]

[0103] wherein represents an element-wise multiplication operation, represents an element-wise addition operation, and the size of f6 is (w / 8)x(h / 8)x64.

[0104] Embodiment 10:

[0105] This embodiment is further optimized on the basis of Embodiment 6 or 7 or 8 or 9, and the same parts as the foregoing technical solutions will not be described again. Further, an improved multi-scale image tamper region positioning method is used to better achieve the present application, and the following setting method is particularly used: the step 3) is specifically:

[0106] 3.1) fuse the tamper feature components and the shallow tamper feature components obtained by the third-level convolutional neural network in the first-level deconvolutional network, and then output;

[0107] 3.2) splice the output of step 3.1) and the shallow tamper feature components obtained by the second-level convolutional neural network in the second-level deconvolutional network, and then output;

[0108] 3.3) splice the output of step 3.2) and the shallow tamper feature components obtained by the first-level convolutional neural network in the third-level deconvolutional network, and output;

[0109] 3.4) obtain the probability value of each pixel point by using the Sigmoid function to activate the output of step 3.4), and the value range is [0, 1]. When the probability value is greater than the threshold value 0.5, the pixel is classified as a tampered pixel. When the probability value is less than the threshold value 0.5, the pixel is classified as a non-tampered pixel. After the classification is completed, the final reconstructed tamper region positioning effect map can be obtained.

[0110] Embodiment 11:

[0111] An improved multi-scale image tampered region positioning method, comprising the following steps:

[0112] S1, collect the tampered image dataset, and filter out the high-frequency feature component f0 after normalizing the image data and using a high-pass filter layer. The normalization process refers to the constraint of the image pixel value size to the [0, 1] interval range, and the formula is as follows: P' v = P v ÷255, wherein P v represents the original pixel value, and P' v represents the pixel value after normalization. The high-pass filter layer is a convolution layer composed of three fixed parameters and a 5x5 convolution kernel. The specific parameters of the three convolution kernels are shown in Figure 2 . After the above processing, a high-frequency feature component f0 with a size of w x h x 3 is obtained, wherein w represents the width, h represents the height, and 3 represents the number of high-frequency feature component channels.

[0113] S2, the extracted high-frequency component f0 is sent to a feature acquisition module (i.e. a multi-scale tampered feature acquisition module), and the internal structure is shown in the dashed box Figure 1 . The multi-scale tampered feature acquisition module first uses a cascaded convolutional neural network to acquire shallow tampered feature components containing global tampered feature information and different scales. The cascaded convolutional neural network has three, which are numbered as Conv1, Conv2 and Conv3. Each convolutional neural network includes a convolution layer, an average pooling layer and an activation function for continuous operation. Among them, the number of input channels of the convolution layer numbered as Conv1 is 3, and the number of output channels is 16; the number of input channels of the convolution layer numbered as Conv2 is 16, and the number of output channels is 32; the number of input channels of the convolution layer numbered as Conv3 is 16, and the number of output channels is 64. The specific values of the convolution kernel size, padding and step length of the convolution layers included in the three convolutional neural networks are 5x5, 2 and 1, respectively; the pooling window size and step length of all average pooling layers are 2x2 and 2, respectively; the activation function is ReLU function. The calculation formula of ReLU function is as follows:

[0114] When the input variable x is greater than 0, the calculation result of ReLU(x) is x; when the input variable x is less than 0, the calculation result of ReLU(x) is 0.

[0115] The specific collection process of shallow tampering features of different scales is as follows: (1) The high-frequency feature component f0 obtained by the output of S1 is used as the input of the convolutional neural network numbered Conv1, and the output is a shallow tampering feature component f1 with a scale of (w / 2)×(h / 2)×16; (2) The shallow tampering feature component f1 is used as the input of the convolutional neural network numbered Conv2, and the output is a shallow tampering feature component f2 with a scale of (w / 4)×(h / 4)×32; (3) The shallow tampering feature component f2 is used as the input of the convolutional neural network numbered Conv3, and the output is a shallow tampering feature component f3 with a scale of (w / 8)×(h / 8)×64. In summary, the shallow tampering feature components of different scales collected are arranged in descending order as f1, f2 and f3 according to their scale.

[0116] Then, the collected shallow tampering feature components of the smallest scale are fed into the dilated convolutional network, and the deep tampering feature components f5 are output. From the above, it can be seen that the shallow tampering feature component of the smallest scale is f3. There are two dilated convolutional networks, numbered Dia-Conv1 and Dia-Conv2. Each dilated convolutional network contains a dilated convolution layer and an activation function. Among them, the dilated convolution layer numbered Dia-Conv1 has 64 input channels and 128 output channels; the dilated convolution layer numbered Dia-Conv2 has 128 input channels and 64 output channels. The specific values ​​of the convolution kernel size, padding, stride, and dilation rate of the dilated convolution layers contained in these two dilated convolutional networks are 3×3, 2, 1, and 2, respectively. The activation function is ReLU. The deep tampering feature component is obtained as follows: (1) the shallow tampering feature component f3 is input into the dilated convolutional network numbered Dia-Conv1, and the output is the tampering feature component f4 with a scale of (w / 8)×(h / 8)×128; (2) the tampering feature component f4 is input into the dilated convolutional network numbered Dia-Conv2, and the output is the deep tampering feature component f5 with a scale of (w / 8)×(h / 8)×64.

[0117] S3, sends the deep tampering feature component f5 output by S2 to the attention mechanism fusion module (i.e., the dual-branch attention mechanism fusion module) containing the channel attention mechanism module and the spatial attention mechanism module. Its internal structure is as follows Figure 2 As shown in the dotted box, the channel attention weight map and the spatial attention weight map are calculated respectively. From the previous step, we can know that the deep tampering feature component is f5. The channel attention mechanism assigns weights according to the richness of tampering traces between the input feature channels. The channels with richer tampering traces have greater weights, and the channels with less tampering traces have smaller weights. This strengthens the expression of tampering feature channels to a certain extent. The channel attention weight map M of the deep tampering feature component f5 is C(f5) is calculated by the following formula:

[0118]

[0119] in, and Respectively, they represent the results of global average pooling and global maximum pooling on the deep tampering feature component f5. MLP(·) represents a multilayer perceptron with a hidden layer, which consists of two neural network layers, and the activation function in the hidden layer is ReLU. In addition, σ(·) represents the Sigmoid activation function, and the calculation formula of the Sigmoid activation function is as follows:

[0120] x is the input variable and the Sigmoid function is the calculation result.

[0121] The spatial attention mechanism can guide the model to focus on the location of meaningful tampering features in the spatial dimension. The spatial attention weight map M of the deep tampering feature component f5 S (f5) is calculated by the following formula: M S (f5)=σ(F 7×7 ([AvgP c (f5);MaxP c (f5)])), where F 7×7 (·) represents the convolution operation with a kernel size of 7×7; AvgP c (·) indicates that the input features are globally averaged pooled in the channel dimension. The dimension of global average pooling is 1*w*h, where w represents the width of the input feature and h represents the height of the input feature. MaxP c (·) indicates that the global maximum pooling is performed on the input features in the channel dimension. The dimension of the global maximum pooling is 1*w*h, where w represents the width of the input feature and h represents the height of the input feature.

[0122] The calculated channel attention weight map M C (f5) and spatial attention weight map M S (f5) is weighted and then fused with the deep tampering feature component f5, and the fused tampering feature component f6 with more prominent tampering traces is output. The calculation process of the fused tampering feature component f6 is as follows:

[0123] in represents the element-wise multiplication operation, represents the element-by-element addition operation, Figure 2 The feature fusion in operation, the scale of f6 is (w / 8)×(h / 8)×64.

[0124] S4, sends the fused tampering feature component f6 output by S3 to the cross-layer feature connection reconstruction module, and uses the shallow tampering feature components collected by the previous multi-scale tampering feature acquisition module to perform cross-layer fusion of the same scale as the input of the cascaded deconvolution network, so as to gradually reconstruct the tampering area positioning effect map. There are three deconvolution networks, which are numbered Deconv1, Deconv2 and Deconv3 respectively. Each deconvolution network contains a deconvolution layer and an activation function to form a continuous operation. Among them, the deconvolution layer numbered Deconv1 has 128 input channels and 32 output channels; the deconvolution layer numbered Deconv2 has 64 input channels and 16 output channels; the deconvolution layer numbered Deconv3 has 32 input channels and 1 output channel. The specific values ​​of the convolution kernel size, padding and stride of the convolution layers contained in these two deconvolution neural networks are 2×2, 0 and 2 respectively, and the activation function selects the ReLU function. The internal structure of the cross-layer feature connection reconstruction module is as follows. Figure 2 As shown in the dotted box, the process of reconstructing the tampering area positioning effect map is as follows: (1) The fused tampering feature component f6 and the shallow tampering feature component f3 obtained by the output of S3 are spliced ​​along the channel direction to obtain a feature component f with a scale of (w / 8)×(h / 8)×128 3-6 , input it into the deconvolution network numbered Deconv1, and output the feature component f7 with a scale of (w / 4)×(h / 4)×32; (2) The feature component f7 and the shallow tampering feature component f2 are concatenated along the channel direction to obtain a feature component f with a scale of (w / 4)×(h / 4)×64 7-2 , input it into the deconvolution network numbered Deconv2, and output the feature component f8 with a scale of (w / 2)×(h / 2)×16; (3) The feature component f8 and the shallow tampering feature component f1 are spliced ​​along the channel direction to obtain the feature component f with a scale of (w / 2)×(h / 2)×32 8-1 , input it into the deconvolution network numbered Deconv3, and output the feature component f9 with a scale of w×h×1; (4) Activate the feature component f9 using the Sigmoid function to obtain the probability value of each pixel in the feature component f9, the value range is [0,1], and when the probability value is greater than the threshold value 0.5, it is classified as a tampered pixel; when the probability value is less than the threshold value 0.5, it is classified as a non-tampered pixel. After the classification is completed, the final reconstructed tampering area positioning effect map (i.e., tampering area prediction effect map) can be obtained.

[0125] S5 calculates the error of the predicted tampering region prediction effect map and the input image true label tampering region using a pixel-level adaptive weight binary cross entropy loss function, to guide the entire network to optimize the parameters in the best direction. The adaptive weight binary cross entropy loss function L cla The calculation formula is as follows:

[0126] Wherein N represents the total number of pixels of the tampering region positioning effect image; y i represents the actual label of the i-th pixel point, i.e. tampered pixel point or non-tampered pixel point, which is usually represented by 0 or 1; x i represents the prediction probability of the i-th pixel point, the value range is [0, 1]; w represents the weight value, and the calculation formula is as follows:

[0127] Wherein, N0 represents the number of actual non-tampered pixel points of the input picture, and N1 represents the number of actual tampered pixel points of the input picture. The purpose of setting the weight is to improve the contribution of the smaller one of the tampered pixel or non-tampered pixel sample to the error calculation, correct the optimization direction of the model, make the model optimize the parameters in the best direction, improve the pixel point classification bias problem, and reduce the false positive rate of pixel classification.

[0128] The above is only a preferred embodiment of the present application, and does not limit the present application in any form. Any simple modification or equivalent change based on the technical essence of the present application to the above embodiment falls within the protection scope of the present application.

Claims

1. An improved multi-scale image tampering region localization method, characterized by: The steps include: 1) The feature acquisition module uses a cascaded convolutional neural network to collect shallow tampering feature components of different scales containing global tampering feature information from the input high-frequency feature component f0, and sends the collected shallow tampering feature components of the smallest scale into the hollow convolutional network to output the deep tampering feature component f5; wherein, the acquisition module is provided with a three-level convolutional neural network and a two-level hollow convolutional network, each of which is provided with a convolution layer, an average pooling layer and an activation function for realizing continuous operation; each hollow convolutional network is provided with a hollow convolution layer and an activation function for realizing continuous operation; 2) The deep tampering feature component f5 is sent to the attention mechanism fusion module including the channel attention mechanism module and the spatial attention mechanism module, and the channel attention weight map M is calculated respectively. C (f5) and spatial attention weight map M S (f5), and after using matrix multiplication to distribute weights with the deep tampering feature component f5 in the spatial and channel dimensions, the feature fusion module is used to perform feature fusion output to obtain the fused tampering feature component f6 with more prominent tampering trace expression; 3) The tampered feature component f6 and the shallow tampered feature component are fused at the same scale through a cross-layer feature connection reconstruction module equipped with a three-level deconvolution network and a Sigmoid function, thereby gradually reconstructing the tampered area positioning effect map; 4) The error between the tampered area positioning effect image and the tampered area actually marked in the input image is calculated using the binary cross entropy loss function with pixel-level adaptive weights to guide the entire network to optimize parameters in the optimal direction.

2. The improved multi-scale image tampering region localization method according to claim 1, characterized in that: The method also includes collecting a tampered image data set, normalizing the tampered image data, and using a high-pass filter layer to filter out a high-frequency feature component f0 with a scale of w×h×3, where w represents width, h represents height, and 3 represents the number of channels of the high-frequency feature component f0; when performing normalization, the following formula is used to implement it: P′ v =P v ÷255, where P v Represents the original pixel value, P' v Represents the normalized pixel value; the high-pass filter layer is a convolution layer consisting of three fixed parameters and a 5×5 convolution kernel size.

3. The improved multi-scale image tampering region localization method according to claim 1 or 2, characterized in that: The step 1) includes the following specific steps: 1.1) The high-frequency feature component f0 passes through the first-level convolutional neural network, and the output is a shallow tampering feature component with a scale of (w / 2)×(h / 2)×16; 1.2) The shallow tampering feature component obtained in step 1.1) is passed through a second-stage convolutional neural network to output a shallow tampering feature component with a scale of (w / 4)×(h / 4)×32; 1.3) The shallow tampering feature components obtained in step 1.2) are passed through a third-level convolutional neural network to output shallow tampering feature components with a scale of (w / 8)×(h / 8)×64; 1.4) Input the shallow tampering feature component obtained in step 1.3) into the first-level dilated convolutional network, and output the tampering feature component with a scale of (w / 8)×(h / 8)×128; 1.5) Input the tampering feature component obtained in step 1.4) into the second-level dilated convolutional network, and output a deep tampering feature component f5 with a scale of (w / 8)×(h / 8)×64.

4. The improved multi-scale image tampering region localization method according to claim 1 or 2, characterized in that: The deep tampering feature component f5 is subjected to the channel attention weight map M in the channel attention mechanism module. C (f5) is calculated using the following formula: in, and They represent the results of global average pooling and global maximum pooling operations on the deep tampering feature component f5 respectively; MLP(·) represents a multi-layer perceptron with a hidden layer, which consists of two neural network layers, and the activation function in the hidden layer is ReLU; σ(·) represents the Sigmoid activation function, and the calculation formula of the Sigmoid activation function is as follows: x is the input variable, and the Sigmoid function is the calculation result; The deep tampering feature component f5 is subjected to the spatial attention weight map M in the spatial attention mechanism module. S (f5) is calculated using the following formula: M s (f5)=σ(F 7×7 ([AvgP c (f5);MaxP c (f5)])), Among them, F 7×7 (·) represents the convolution operation with a kernel size of 7×7; AvgP c (·) indicates that the input features are globally averaged pooled in the channel dimension. The dimension of global average pooling is 1*w*h, where w represents the width of the input feature and h represents the height of the input feature. MaxP c (·) indicates that the global maximum pooling is performed on the input features in the channel dimension. The dimension of the global maximum pooling is 1*w*h, where w represents the width of the input feature and h represents the height of the input feature. When the feature fusion module performs feature fusion, it is achieved through the following formula: in represents the element-wise multiplication operation, represents an element-by-element addition operation, and the scale of f6 is (w / 8)×(h / 8)×64.

5. The improved multi-scale image tampering region location method according to claim 1 or 2, characterized in that: The step 3) is specifically as follows: 3.1) The shallow tampering feature components obtained by fusing the tampering feature components and the third-level convolutional neural network are spliced ​​in the first-level deconvolution network and then output; 3.2) The output of step 3.1) is concatenated with the shallow tampering feature component obtained by the second-level convolutional neural network in the second-level deconvolutional network, and then output; 3.3) The output of step 3.2) is concatenated with the shallow tampering feature component obtained by the first-level convolutional neural network in a third-level deconvolutional network and output; 3.4) The output of step 3.4) is activated by the Sigmoid function to obtain the probability value of each pixel, with a value range of [0, 1]. When the probability value is greater than the threshold of 0.5, it is classified as a tampered pixel; when the probability value is less than the threshold of 0.5, it is classified as a non-tampered pixel. After the classification is completed, the final reconstructed tampering area positioning effect map can be obtained.

Citation Information

Patent Citations

  • Multitask tampered image detection method guided by global features

    CN114202529A

  • Multi-scale feature fusion tampered video detection method, system, medium and equipment

    CN114743148A