CN111145146B - Method and device for detecting style migration forged image based on HHT - Google Patents
Method and device for detecting style migration forged image based on HHT Download PDFInfo
- Publication number
- CN111145146B CN111145146B CN201911263956.XA CN201911263956A CN111145146B CN 111145146 B CN111145146 B CN 111145146B CN 201911263956 A CN201911263956 A CN 201911263956A CN 111145146 B CN111145146 B CN 111145146B
- Authority
- CN
- China
- Prior art keywords
- image
- instantaneous frequency
- training
- images
- forged
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 68
- 238000013508 migration Methods 0.000 title claims abstract description 68
- 230000005012 migration Effects 0.000 title claims abstract description 68
- 238000001514 detection method Methods 0.000 claims abstract description 89
- 238000012549 training Methods 0.000 claims abstract description 88
- 239000000203 mixture Substances 0.000 claims abstract description 59
- 238000009826 distribution Methods 0.000 claims abstract description 23
- 230000009466 transformation Effects 0.000 claims abstract description 13
- 230000008569 process Effects 0.000 claims description 14
- 238000004422 calculation algorithm Methods 0.000 claims description 8
- 238000000354 decomposition reaction Methods 0.000 claims description 8
- 238000010276 construction Methods 0.000 claims description 6
- 238000012706 support-vector machine Methods 0.000 claims description 5
- 238000006243 chemical reaction Methods 0.000 claims description 3
- 238000007637 random forest analysis Methods 0.000 claims description 3
- 239000011159 matrix material Substances 0.000 description 5
- 238000012545 processing Methods 0.000 description 4
- 238000012360 testing method Methods 0.000 description 4
- 238000011161 development Methods 0.000 description 3
- 238000012986 modification Methods 0.000 description 3
- 230000004048 modification Effects 0.000 description 3
- 230000000750 progressive effect Effects 0.000 description 3
- 238000012795 verification Methods 0.000 description 3
- 238000005516 engineering process Methods 0.000 description 2
- 238000013528 artificial neural network Methods 0.000 description 1
- 230000008901 benefit Effects 0.000 description 1
- 238000004364 calculation method Methods 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 238000013527 convolutional neural network Methods 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 238000011156 evaluation Methods 0.000 description 1
- 238000000605 extraction Methods 0.000 description 1
- 238000005242 forging Methods 0.000 description 1
- 238000013507 mapping Methods 0.000 description 1
- 238000005457 optimization Methods 0.000 description 1
- 230000000452 restraining effect Effects 0.000 description 1
- 238000001228 spectrum Methods 0.000 description 1
- 230000001131 transforming effect Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/0002—Inspection of images, e.g. flaw detection
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/21—Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
- G06F18/214—Generating training patterns; Bootstrap methods, e.g. bagging or boosting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/24—Classification techniques
-
- G06T5/90—
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02P—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
- Y02P90/00—Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
- Y02P90/30—Computing systems specially adapted for manufacturing
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Life Sciences & Earth Sciences (AREA)
- Artificial Intelligence (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Bioinformatics & Computational Biology (AREA)
- Evolutionary Biology (AREA)
- Evolutionary Computation (AREA)
- General Engineering & Computer Science (AREA)
- Quality & Reliability (AREA)
- Image Analysis (AREA)
Abstract
The invention discloses a method and a device for detecting style migration forged images based on HHT, which are used for converting two-dimensional images in a training image set into one-dimensional image signals and carrying out Hilbert-Huang transform on the one-dimensional image signals; fitting the distribution of the instantaneous frequency set obtained by transformation by adopting Gaussian mixture distribution, and encoding the instantaneous frequency to be used as the detection characteristic of each image in the training image set; training a classifier by using the detection features and labels corresponding to the images in the training image set to obtain a classifier capable of better detecting the style migration forged images; the image to be detected is converted into a one-dimensional image signal and subjected to Hilbert-Huang transformation, the instantaneous frequency of the image to be detected obtained through transformation is coded by using a constructed Gaussian mixture model and is used as the detection characteristic of the image to be detected, and the trained classifier is used for detecting, so that the real image and the style migration forged image can be effectively distinguished.
Description
Technical Field
The invention relates to the technical field of image processing, in particular to a method and a device for detecting style migration forged images based on HHT.
Background
With the continuous development of image counterfeiting methods, the detection methods of counterfeit images are also continuously enriched and improved. The detection methods of the existing forged images can be roughly classified into the following five types: pixel value-based detection methods, image compression-based detection methods, camera-based image acquisition process detection methods, ray-based detection methods, and geometry-based detection methods. Among them, the pixel value-based detection method is most widely used because it does not require additional a priori information.
The abundant and various forged image detection methods can identify various forged images including copying movement, splicing and image repairing, and can play an important role in identifying the authenticity of the images and restraining image forgery. However, in recent years, the rise of the convolutional neural network brings many difficulties for detecting a forged image, and neural network style migration is one of the non-negligible image forging forms. The style migration refers to the process of transforming any given image into a specified style, and because the image is globally modified, the traditional detection method has no good applicability in detecting the style migration forged image, and a more effective forged detection method needs to be designed for the specific image processing technology of the style migration.
Disclosure of Invention
In view of the above, the present invention provides a method and an apparatus for detecting a style migration forged image based on HHT, which are used to identify images generated by a plurality of style migration methods.
Therefore, the invention provides a method for detecting a style migration forged image based on HHT, which comprises the following steps:
s1: converting an image to be detected into a one-dimensional image signal;
s2: performing Hilbert-yellow transformation on a one-dimensional image signal corresponding to an image to be detected to obtain an instantaneous frequency sequence of the image to be detected;
s3: coding the obtained instantaneous frequency sequence of the image to be detected according to a pre-constructed Gaussian mixture model to obtain the detection characteristics of the image to be detected;
s4: and inputting the obtained detection characteristics of the image to be detected into a pre-trained classifier to obtain a detection result.
In a possible implementation manner, in the method for detecting a style migration-forged image provided by the present invention, the constructing process of the gaussian mixture model in step S3 and the training process of the classifier in step S4 specifically include the following steps:
SS1: constructing a training image set comprising a plurality of real images and a plurality of style migration forged images;
and (4) SS2: respectively converting each image in the training image set into a one-dimensional image signal to obtain a one-dimensional image signal set;
and (4) SS3: performing Hilbert-Huang transform on each one-dimensional image signal in the one-dimensional image signal set to obtain an instantaneous frequency sequence of each image;
and (4) SS: constructing an instantaneous frequency set according to the obtained instantaneous frequency sequence of each image, and carrying out Gaussian mixture modeling on the instantaneous frequency set to obtain a Gaussian mixture model;
and SS5: coding the instantaneous frequency sequence of each image according to the obtained Gaussian mixture model to obtain the detection characteristics of each image;
and SS6: and training a classifier based on the labels of all the images in the training image set and the obtained detection features of all the images.
In a possible implementation manner, in the method for detecting a style migration forged image provided by the present invention, in step SS2, each image in the training image set is converted into a one-dimensional image signal, so as to obtain a one-dimensional image signal set, which is specifically implemented by the following steps:
and performing horizontal line-by-line scanning or vertical line-by-line scanning on each image in the training image set to obtain one-dimensional image signals corresponding to the images one by one, and obtaining a one-dimensional image signal set.
In a possible implementation manner, in the method for detecting a style migration forged image provided by the present invention, step SS3 performs hilbert-yellow transform on each one-dimensional image signal in the set of one-dimensional image signals to obtain an instantaneous frequency sequence of each image, which specifically includes the following steps:
and SS31: performing empirical mode decomposition on each one-dimensional image signal in the one-dimensional image signal set until convergence to obtain an internal steady-state function set;
and (4) SS32: and selecting the first m internal steady-state functions in the internal steady-state function set, and solving the instantaneous frequency sequence of each image by using Hilbert transform.
In a possible implementation manner, in the method for detecting a style migration-forged image provided by the present invention, step SS4 is to construct an instantaneous frequency set according to the obtained instantaneous frequency sequence of each image, and perform gaussian mixture modeling on the instantaneous frequency set to obtain a gaussian mixture model, and specifically includes the following steps:
and SS41: forming an instantaneous frequency set by the obtained instantaneous frequency sequences of the images;
and SS42: selecting the number of Gaussian mixture distributions, and estimating each parameter variable of the Gaussian mixture distributions of the instantaneous frequency set by utilizing an EM (effective electromagnetic) algorithm; wherein the parameter variables include weight coefficients, means, and variances.
In a possible implementation manner, in the method for detecting a style migration forged image provided by the present invention, in step SS5, the instantaneous frequency sequence of each image is encoded according to the obtained gaussian mixture model, so as to obtain the detection characteristics of each image, which is specifically implemented by the following steps:
and calculating partial derivatives of parameter variables of the Gaussian mixture model aiming at the instantaneous frequency sequence of each image to form a Fisher vector as a detection characteristic of each image.
In a possible implementation manner, in the method for detecting a style migration forged image provided by the present invention, step SS6, based on the labels of the images in the training image set and the obtained detection features of the images, trains a classifier, and specifically includes the following steps:
and (2) SS61: the label of each image in the training image set is represented by {0,1 }; wherein 1 represents a style migration forged image, and 0 represents a real image;
SS62: extracting detection characteristics of each image;
and (4) SS63: carrying out Z-Score standardization on the detection characteristics of each image;
and SS64: and inputting the label of each image and the detection characteristics of each image after standardization into a classifier for training.
In a possible implementation manner, in the method for detecting a style migration forged image provided by the present invention, the classifier is a support vector machine or a random forest.
In a possible implementation manner, in the style migration forged image detection method provided by the present invention, the color channel for performing the hilbert-yellow transform includes a luminance channel of a YUV color space.
The invention also provides a style migration forged image detection device based on HHT, comprising:
the image signal conversion module is used for respectively converting the image to be detected and each image in the training image set into a one-dimensional image signal; the training image set comprises a plurality of real images and a plurality of style migration forged images;
the Hilbert-Huang transform module is used for performing empirical mode decomposition and Hilbert transform on each one-dimensional image signal to obtain an instantaneous frequency sequence of each image in the Hilbert-Huang transform frequency domain in the image to be detected and the training image set;
the Gaussian mixture model construction module is used for estimating each parameter variable of Gaussian mixture distribution of the instantaneous frequency sequence of each image in the training image set by using an EM algorithm;
the encoding module is used for encoding instantaneous frequency sequences of the images to be detected and all the images in the training image set by using a pre-constructed Gaussian mixture model to obtain detection characteristics of the images to be detected and all the images in the training image set;
the classifier training module is used for carrying out model training by using the detection characteristics and the labels of all the images in the training image set to obtain a classifier;
and the forged image detection module is used for extracting the detection characteristics of the image to be detected, detecting by using a pre-trained classifier and giving a detection result.
The method and the device for detecting the style migration forged image provided by the invention firstly convert a two-dimensional image in a training image set into a one-dimensional image signal, and then perform Hilbert-Huang transform on the one-dimensional image signal; fitting the distribution of the instantaneous frequency set obtained by transformation by adopting Gaussian mixture distribution, and encoding the instantaneous frequency to be used as the detection characteristic of each image in the training image set; training a classifier by using the detection features and labels corresponding to the images in the training image set so as to obtain the classifier capable of better detecting the style migration forged images; converting an image to be detected into a one-dimensional image signal, carrying out Hilbert-yellow transformation on the one-dimensional image signal, encoding instantaneous frequency of the image to be detected obtained by transformation by using a pre-constructed Gaussian mixture model, using the instantaneous frequency as a detection feature of the image to be detected, and detecting by using a pre-trained classifier. The experimental verification result shows that the style migration forged image detection method provided by the invention can effectively distinguish the real image from the style migration forged image.
Drawings
FIG. 1 is a flow chart of a method for detecting a style migration forged image based on HHT provided by the invention;
FIG. 2 is a schematic flow chart of a method for detecting a style migration forged image based on HHT according to the present invention;
FIG. 3 is a flow chart of a Gaussian mixture model construction process and a classifier training process in the HHT-based style migration counterfeit image detection method provided by the invention;
FIG. 4 is a schematic flow chart of a Gaussian mixture model construction process and a classifier training process in the HHT-based style migration counterfeit image detection method provided by the invention;
fig. 5 is a schematic structural diagram of a style migration forged image detection apparatus based on HHT according to the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only illustrative and are not intended to limit the present invention.
The invention provides a method for detecting a style migration forged image based on HHT (Hilbert-Huang transform frequency domain characteristics), which comprises the following steps as shown in figures 1 and 2:
s1: converting an image to be detected into a one-dimensional image signal;
s2: performing Hilbert-yellow transformation on a one-dimensional image signal corresponding to an image to be detected to obtain an instantaneous frequency sequence of the image to be detected;
s3: coding the obtained instantaneous frequency sequence of the image to be detected according to a pre-constructed Gaussian mixture model to obtain the detection characteristics of the image to be detected;
s4: and inputting the obtained detection characteristics of the image to be detected into a pre-trained classifier to obtain a detection result.
The style migration forged image detection method provided by the invention can effectively distinguish the real image from the style migration forged image. The Hilbert-Huang transform is a signal transform method which is widely applied in the field of signal processing and has better development prospect, and compared with the traditional transform methods such as Fourier transform, wavelet transform and the like, the Hilbert-Huang transform has the advantage of processing nonlinear and non-stationary signals. The Hilbert-Huang transform is applied to the field of style migration forgery detection images, so that the application scene of the Hilbert-Huang transform can be enriched, the technology for detecting the forged images can be further improved, and the continuous development of the field is promoted.
Before the style migration counterfeit image detection method provided by the invention is implemented, a Gaussian mixture model and a training classifier need to be constructed. Specifically, the constructing process of the gaussian mixture model in step S3 and the training process of the classifier in step S4, as shown in fig. 3 and fig. 4, may specifically include the following steps:
SS1: constructing a training image set comprising a plurality of real images and a plurality of style migration forged images;
specifically, the image to be detected in the step S1 belongs to a real image or a style migration forged image;
and (4) SS2: respectively converting each image in the training image set into a one-dimensional image signal to obtain a one-dimensional image signal set;
and (4) SS3: performing Hilbert-Huang transform on each one-dimensional image signal in the one-dimensional image signal set to obtain an instantaneous frequency sequence of each image;
and SS4: constructing an instantaneous frequency set according to the obtained instantaneous frequency sequence of each image, and carrying out Gaussian mixture modeling on the instantaneous frequency set to obtain a Gaussian mixture model;
SS5: coding the instantaneous frequency sequence of each image according to the obtained Gaussian mixture model to obtain the detection characteristics of each image;
and SS6: and training a classifier based on the labels of all the images in the training image set and the obtained detection features of all the images.
In specific implementation, when step SS2 in the style migration counterfeit image detection method provided by the present invention is executed, and each image in the training image set is respectively converted into a one-dimensional image signal, so as to obtain a one-dimensional image signal set, the method can be specifically implemented in the following two ways: performing horizontal progressive scanning on each image in the training image set to obtain one-dimensional image signals corresponding to the images one by one, and obtaining a one-dimensional image signal set; or, each image in the training image set is scanned vertically column by column to obtain one-dimensional image signals corresponding to the images one by one, and a one-dimensional image signal set is obtained.
Similarly, when step S1 in the method for detecting a style migration forged image provided by the present invention is executed to convert an image to be detected into a one-dimensional image signal, the method can also be implemented in the two ways: performing horizontal progressive scanning on an image to be detected to obtain a one-dimensional image signal corresponding to the image to be detected and obtain a one-dimensional image signal set; or, scanning the image to be detected vertically row by row to obtain a one-dimensional image signal corresponding to the image to be detected, and obtaining a one-dimensional image signal set.
In a specific implementation, in the method for detecting a style migration forged image provided by the present invention, step SS3 performs hilbert-yellow transform on each one-dimensional image signal in the one-dimensional image signal set to obtain an instantaneous frequency sequence of each image, which may specifically include the following steps:
and SS31: performing empirical mode decomposition on each one-dimensional image signal in the one-dimensional image signal set until convergence to obtain an internal steady-state function set;
and SS32: and selecting the first m internal steady-state functions in the internal steady-state function set, and solving the instantaneous frequency sequence of each image by using Hilbert transform. Specifically, m is determined by the experimental results or specified by the user.
Similarly, in step S2 of the method for detecting a style migration forged image provided by the present invention, the one-dimensional image signal corresponding to the image to be detected is subjected to hilbert-yellow transform to obtain an instantaneous frequency sequence of the image to be detected, which can also be implemented by the above-mentioned method: performing empirical mode decomposition on a one-dimensional image signal corresponding to an image to be detected until convergence to obtain an internal steady-state function set; and selecting the first m internal steady-state functions in the internal steady-state function set, and obtaining the instantaneous frequency sequence of the image to be detected by using Hilbert transform. Specifically, m is determined by the experimental results or specified by the user.
In specific implementation, in the method for detecting a style migration-forged image provided by the present invention, step SS4 is to construct an instantaneous frequency set according to the obtained instantaneous frequency sequence of each image, and perform gaussian mixture modeling on the instantaneous frequency set to obtain a gaussian mixture model, which may specifically include the following steps:
and SS41: forming an instantaneous frequency set by the obtained instantaneous frequency sequences of the images;
and SS42: selecting the number of Gaussian mixture distributions, and estimating each parameter variable of the Gaussian mixture distributions of the instantaneous frequency set by utilizing an EM (effective electromagnetic) algorithm; wherein the parameter variables include weight coefficients, means and variances. Specifically, the number of gaussian mixture distributions is determined by the experimental results or specified by the user.
In a specific implementation, when step SS5 in the style migration forged image detection method provided by the present invention is executed, and the instantaneous frequency sequence of each image is encoded according to the obtained gaussian mixture model to obtain the detection characteristics of each image, the method can be specifically implemented in the following manner: and calculating partial derivatives of parameter variables of the Gaussian mixture model aiming at the instantaneous frequency sequence of each image to form a Fisher vector as a detection characteristic of each image. The encoding method for the instantaneous frequency sequence of each image is not limited to fisher vector encoding, and other encoding methods may be used for the instantaneous frequency sequence of each image, and the encoding method is not limited to this.
Similarly, in step S3 of the method for detecting a style migration-forged image provided by the present invention, the obtained instantaneous frequency sequence of the image to be detected is encoded according to the pre-constructed gaussian mixture model to obtain the detection characteristics of the image to be detected, which can also be implemented by the following steps: and calculating partial derivatives of parameter variables of the Gaussian mixture model aiming at the instantaneous frequency sequence of the image to be detected to form a Fisher vector as the detection characteristic of the image to be detected. It should be noted that the encoding method of the instantaneous frequency sequence of the image to be detected is not limited to fisher vector encoding, and other encoding methods may be performed on the instantaneous frequency sequence of the image to be detected, and the encoding method is not limited herein.
In specific implementation, in the method for detecting a style migration forged image provided by the present invention, step SS6 is to train a classifier based on the labels of the images in the training image set and the obtained detection features of the images, and may specifically include the following steps:
and (2) SS61: the label of each image in the training image set is represented by {0,1 }; wherein 1 represents a style migration forged image, and 0 represents a real image;
and SS62: extracting detection characteristics of each image;
and SS63: carrying out Z-Score standardization on the detection characteristics of each image;
and SS64: and inputting the label of each image and the detection characteristics of each image after standardization into a classifier for training.
In specific implementation, in the method for detecting a style migration forged image provided by the invention, the classifier can be a support vector machine; alternatively, the classifier may be a random forest; alternatively, other types of classifiers may also be employed; and are not limited herein.
In a specific implementation, in the method for detecting a style migration forged image provided by the present invention, in step S2 and step SS3, the color channel for performing the hilbert-yellow transform may include a luminance channel of a YUV color space. Of course, the color channel for performing the hilbert-yellow transform may also be another type of color channel, and is not limited herein.
The following describes a specific implementation of the method for detecting a style migration-forged image according to the present invention in detail by using a specific embodiment.
Example 1:
construction process of Gaussian mixture model and training process of classifier
(1) Constructing a training image set comprising a plurality of real images and a plurality of style migration forged images;
forming a training image set by 753 real images and 528 style migration forged images, wherein the label of the real images is marked as 0, and the label of the style migration forged images is marked as 1;
(2) Acquiring one-dimensional image signals corresponding to all images in a training image set;
performing horizontal progressive scanning on each two-dimensional image matrix in the training image set to obtain a one-dimensional image vector, wherein a mapping relation formula is as follows:
V(i·col+j)=M(i,j)
wherein V represents a one-dimensional image vector, M (i, j) represents a two-dimensional image matrix, and col represents the number of columns of the two-dimensional image matrix;
(3) Performing Hilbert-yellow transformation on one-dimensional image signals of all images in the training image set;
firstly, empirical mode decomposition is carried out on each one-dimensional image signal based on the following steps to obtain an internal steady-state function set: (a) Respectively drawing an upper envelope line and a lower envelope line by utilizing cubic spline interpolation according to an upper extreme point and a lower extreme point of an original one-dimensional image signal; (b) Calculating the mean value of the upper envelope line and the lower envelope line, and drawing a mean value envelope line; (c) Subtracting the mean envelope curve from the original one-dimensional image signal to obtain an intermediate signal; (d) Judging whether the intermediate signal meets the condition of an internal steady-state function, if so, adding the intermediate signal into the internal steady-state function set, and entering the step (e), otherwise, iteratively repeating the steps (a) - (d); (e) After the first internal steady-state function is obtained by using the method, subtracting the internal steady-state function from the original one-dimensional image signal to be used as a new one-dimensional image signal, and repeating the steps (a) to (e) until a convergence condition is met;
then, selecting a first internal steady-state function, performing Hilbert transform on the amplitude of the first internal steady-state function to obtain a phase spectrum, and solving a first derivative of the phase to time to obtain an instantaneous frequency value, wherein the Hilbert transform formula is as follows:
wherein s (t) represents the amplitude value of the internal steady-state function at time t, and s (τ) represents the amplitude value of the internal steady-state function at time τ;
the phase values are expressed as:
the instantaneous frequency values are expressed as:
(4) Constructing a Gaussian mixture model;
the distribution of instantaneous frequencies is represented by a gaussian mixture distribution, and the formula is as follows:
wherein p is k (x | Θ) represents the kth gaussian distribution, K is the number of gaussian distributions, and K is selected to be 10 according to the experimental result; x represents the instantaneous frequency of the image, Θ = { w k ,μ k ,C k K =1, …, K } is a parameter variable corresponding to the gaussian mixture distribution, w k Denotes the mixing weight, mu k Denotes the mean value, C k Representing a covariance matrix; estimating theta by using an EM algorithm to obtain a Gaussian mixture model;
(5) Performing Fisher vector coding on the instantaneous frequency sequence of each image in the training image set;
calculating partial derivatives of each parameter variable in the theta to obtain a Fisher vector as a detection characteristic of each image in a training image set;
mixing weight w k The constraints need to be satisfied: w is a k >0 and Σ w k =1, for simplified representation, define new weights α using Softmax function k And satisfies the following conditions:
wherein alpha is k Representing a new weight, α, corresponding to the kth Gaussian distribution l Representing a new weight corresponding to the ith Gaussian distribution;
covariance matrix C k Has a diagonal vector of σ k 2 ;
The partial derivative calculation formula is as follows:
wherein, the first and the second end of the pipe are connected with each other,respectively for the parameter alpha k ,μ k ,σ k The partial derivative of (a), γ (k), is the posterior probability of x, and the formula is as follows:
(6) Training a classifier;
inputting labels of all images in a training image set and detection features obtained by extraction into a support vector machine model, training by using a support vector machine optimization algorithm, selecting a model by using a cross verification method, and obtaining optimal hyper-parameters (including kernel functions, cost parameters and gamma parameters) by using a grid search method;
(II) identifying the image to be detected
And (5) converting the image to be detected into a one-dimensional image signal, obtaining a detection characteristic corresponding to the instantaneous frequency of the image to be detected according to the steps (3) and (5), and inputting the detection characteristic into the classifier obtained in the step (6) to obtain a detection result.
In order to verify the effectiveness and the practicability of the method in embodiment 1 of the present invention, 753 real images and 528 style migration forged images are used as training image sets, and classifiers are trained according to steps (1) to (6). And performing model evaluation by using a test image set which is intersected with the training image set to form an empty set, wherein the test image set comprises 322 real images and 226 style migration and forgery images, classifying the test image set by using the classifier obtained by training, and comparing the test image set with real labels of the training image set, and finding that the accuracy of the prediction result of the classifier is 80.85%, which indicates that the method disclosed by the embodiment 1 of the invention is effective and feasible.
Based on the same inventive concept, the present invention provides a HHT-based style migration-counterfeit image detection apparatus, as shown in fig. 5, comprising:
the image signal conversion module is used for respectively converting the image to be detected and each image in the training image set into a one-dimensional image signal; the training image set comprises a plurality of real images and a plurality of style migration forged images;
the Hilbert-Huang transform module is used for performing empirical mode decomposition and Hilbert transform on each one-dimensional image signal to obtain an instantaneous frequency sequence of each image in the Hilbert-Huang transform frequency domain in the image to be detected and the training image set;
the Gaussian mixture model construction module is used for estimating each parameter variable of Gaussian mixture distribution of the instantaneous frequency sequence of each image in the training image set by using an EM algorithm;
the encoding module is used for encoding instantaneous frequency sequences of the images to be detected and all the images in the training image set by using a pre-constructed Gaussian mixture model to obtain detection characteristics of the images to be detected and all the images in the training image set;
the classifier training module is used for carrying out model training by using the detection characteristics and the labels of all the images in the training image set to obtain a classifier;
and the forged image detection module is used for extracting the detection characteristics of the image to be detected, detecting by using a pre-trained classifier and giving a detection result.
The method and the device for detecting the style migration forged image provided by the invention firstly convert a two-dimensional image in a training image set into a one-dimensional image signal, and then perform Hilbert-Huang transform on the one-dimensional image signal; fitting the distribution of the instantaneous frequency set obtained by transformation by adopting Gaussian mixture distribution, and encoding the instantaneous frequency to be used as the detection characteristic of each image in the training image set; training a classifier by using the detection features and labels corresponding to the images in the training image set so as to obtain the classifier capable of better detecting the style migration forged images; converting an image to be detected into a one-dimensional image signal, carrying out Hilbert-yellow transformation on the one-dimensional image signal, encoding instantaneous frequency of the image to be detected obtained by transformation by using a pre-constructed Gaussian mixture model, using the instantaneous frequency as a detection feature of the image to be detected, and detecting by using a pre-trained classifier. The experimental verification result shows that the style migration forged image detection method provided by the invention can effectively distinguish the real image from the style migration forged image.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.
Claims (8)
1. A method for detecting a style migration forged image based on HHT is characterized by comprising the following steps: s1: converting an image to be detected into a one-dimensional image signal; s2: performing Hilbert-yellow transformation on a one-dimensional image signal corresponding to an image to be detected to obtain an instantaneous frequency sequence of the image to be detected; s3: coding the obtained instantaneous frequency sequence of the image to be detected according to a pre-constructed Gaussian mixture model to obtain the detection characteristics of the image to be detected; s4: inputting the obtained detection characteristics of the image to be detected into a pre-trained classifier to obtain a detection result;
in the step S3, the construction process of the gaussian mixture model and the training process of the classifier in the step S4 specifically include the following steps: and (4) SS1: constructing a training image set comprising a plurality of real images and a plurality of style migration forged images; and SS2: respectively converting each image in the training image set into a one-dimensional image signal to obtain a one-dimensional image signal set; and SS3: performing Hilbert-Huang transform on each one-dimensional image signal in the one-dimensional image signal set to obtain an instantaneous frequency sequence of each image; and SS4: constructing an instantaneous frequency set according to the obtained instantaneous frequency sequence of each image, and carrying out Gaussian mixture modeling on the instantaneous frequency set to obtain a Gaussian mixture model; and SS5: coding the instantaneous frequency sequence of each image according to the obtained Gaussian mixture model to obtain the detection characteristics of each image; and SS6: training a classifier based on the labels of the images in the training image set and the obtained detection features of the images;
and SS4, constructing an instantaneous frequency set according to the obtained instantaneous frequency sequence of each image, and carrying out Gaussian mixture modeling on the instantaneous frequency set to obtain a Gaussian mixture model, wherein the method specifically comprises the following steps: and SS41: forming an instantaneous frequency set by the obtained instantaneous frequency sequences of the images; and SS42: selecting the number of Gaussian mixture distributions, and estimating each parameter variable of the Gaussian mixture distributions of the instantaneous frequency set by utilizing an EM (effective electromagnetic) algorithm; wherein the parameter variables include weight coefficients, means, and variances.
2. The method for detecting a style migration forged image according to claim 1, wherein in step SS2, each image in the training image set is converted into a one-dimensional image signal respectively, so as to obtain a one-dimensional image signal set, which is specifically implemented by the following means: and performing horizontal line-by-line scanning or vertical line-by-line scanning on each image in the training image set to obtain one-dimensional image signals corresponding to the images one by one, and obtaining a one-dimensional image signal set.
3. The method for detecting a style migration forged image according to claim 1, wherein the step SS3 of performing hilbert-yellow transform on each one-dimensional image signal in the set of one-dimensional image signals to obtain an instantaneous frequency sequence of each image specifically comprises the following steps: SS31: performing empirical mode decomposition on each one-dimensional image signal in the one-dimensional image signal set until convergence to obtain an internal steady-state function set; and SS32: and selecting the first m internal steady-state functions in the internal steady-state function set, and solving the instantaneous frequency sequence of each image by using Hilbert transform.
4. The method for detecting a style migration forged image according to claim 1, wherein step SS5, according to the obtained gaussian mixture model, encodes the instantaneous frequency sequence of each image to obtain the detection characteristics of each image, and is implemented by: and calculating partial derivatives of parameter variables of the Gaussian mixture model aiming at the instantaneous frequency sequence of each image to form a Fisher vector as a detection characteristic of each image.
5. The method for detecting a style migration forged image according to claim 1, wherein step SS6, based on the label of each image in the training image set and the obtained detection feature of each image, trains a classifier, and specifically comprises the following steps: and (2) SS61: the label of each image in the training image set is represented by {0,1 }; wherein 1 represents a style migration forged image, and 0 represents a real image; SS62: extracting detection characteristics of each image; and (4) SS63: carrying out Z-Score standardization on the detection characteristics of each image; and SS64: and inputting the label of each image and the detection characteristics of each image after standardization into a classifier for training.
6. The method of detecting a style migration forged image according to claim 5, wherein the classifier is a support vector machine or a random forest.
7. The method of detecting a style migration forged image according to claim 1, wherein the color channel for performing the hilbert-yellow transform includes a luminance channel of a YUV color space.
8. An HHT-based style migration-counterfeit image detection apparatus, comprising: the image signal conversion module is used for respectively converting the images to be detected and all the images in the training image set into one-dimensional image signals; the training image set comprises a plurality of real images and a plurality of style migration forged images; the Hilbert-Huang transform module is used for performing empirical mode decomposition and Hilbert transform on each one-dimensional image signal to obtain an instantaneous frequency sequence of each image in the Hilbert-Huang transform frequency domain in the image to be detected and the training image set; the Gaussian mixture model building module is used for estimating each parameter variable of Gaussian mixture distribution of the instantaneous frequency sequence of each image in the training image set by utilizing an EM algorithm, and the parameter variable comprises a weight coefficient, a mean value and a variance; the encoding module is used for encoding the instantaneous frequency sequences of the images to be detected and each image in the training image set by using a pre-constructed Gaussian mixture model to obtain the detection characteristics of the images to be detected and each image in the training image set; the classifier training module is used for carrying out model training by using the detection features and the labels of all the images in the training image set to obtain a classifier; and the forged image detection module is used for extracting the detection characteristics of the image to be detected, detecting by using a pre-trained classifier and giving a detection result.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911263956.XA CN111145146B (en) | 2019-12-11 | 2019-12-11 | Method and device for detecting style migration forged image based on HHT |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911263956.XA CN111145146B (en) | 2019-12-11 | 2019-12-11 | Method and device for detecting style migration forged image based on HHT |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111145146A CN111145146A (en) | 2020-05-12 |
CN111145146B true CN111145146B (en) | 2023-04-18 |
Family
ID=70517962
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201911263956.XA Active CN111145146B (en) | 2019-12-11 | 2019-12-11 | Method and device for detecting style migration forged image based on HHT |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111145146B (en) |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070258618A1 (en) * | 2006-05-05 | 2007-11-08 | Yun-Qing Shi | System and/or method for image tamper detection |
CN103310236A (en) * | 2013-06-27 | 2013-09-18 | 上海数据分析与处理技术研究所 | Mosaic image detection method and system based on local two-dimensional characteristics |
CN106056523A (en) * | 2016-05-20 | 2016-10-26 | 南京航空航天大学 | Digital image stitching tampering blind detection method |
-
2019
- 2019-12-11 CN CN201911263956.XA patent/CN111145146B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070258618A1 (en) * | 2006-05-05 | 2007-11-08 | Yun-Qing Shi | System and/or method for image tamper detection |
CN103310236A (en) * | 2013-06-27 | 2013-09-18 | 上海数据分析与处理技术研究所 | Mosaic image detection method and system based on local two-dimensional characteristics |
CN106056523A (en) * | 2016-05-20 | 2016-10-26 | 南京航空航天大学 | Digital image stitching tampering blind detection method |
Non-Patent Citations (2)
Title |
---|
Detection of Image Splicing Based on Hilbert-Huang Transform and Moments of Characteristic Functions with Wavelet Decomposition;Dongdong Fu et al.;《IWDW 2006》;20060101;全文 * |
Fake Colorized Image Detection;Yuanfang Guo et al.;《IEEE TRANSACTIONS ON INFORMATION FORENSICS AND SECURITY》;20180831;第13卷(第8期);第I、III节 * |
Also Published As
Publication number | Publication date |
---|---|
CN111145146A (en) | 2020-05-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105095856B (en) | Face identification method is blocked based on mask | |
Wang et al. | Optimized feature extraction for learning-based image steganalysis | |
Deb et al. | An efficient method of vehicle license plate recognition based on sliding concentric windows and artificial neural network | |
CN112907598B (en) | Method for detecting falsification of document and certificate images based on attention CNN | |
CN109872305B (en) | No-reference stereo image quality evaluation method based on quality map generation network | |
CN110457996B (en) | Video moving object tampering evidence obtaining method based on VGG-11 convolutional neural network | |
CN113506268B (en) | Semi-supervised foreign matter detection method for rail image | |
CN113744153B (en) | Double-branch image restoration forgery detection method, system, equipment and storage medium | |
CN110633655A (en) | Attention-attack face recognition attack algorithm | |
CN111754441B (en) | Image copying, pasting and forging passive detection method | |
CN114841972A (en) | Power transmission line defect identification method based on saliency map and semantic embedded feature pyramid | |
Zhou et al. | Image splicing detection based on image quality and analysis of variance | |
CN111445058A (en) | Data analysis method, device, equipment and computer readable storage medium | |
CN114842524B (en) | Face false distinguishing method based on irregular significant pixel cluster | |
CN113627503A (en) | Tracing method and device for generating image, model training method and device, electronic equipment and storage medium | |
Alaei et al. | Document image quality assessment based on improved gradient magnitude similarity deviation | |
CN103325123A (en) | Image edge detection method based on self-adaptive neural fuzzy inference systems | |
CN113421223B (en) | Industrial product surface defect detection method based on deep learning and Gaussian mixture | |
CN111145146B (en) | Method and device for detecting style migration forged image based on HHT | |
CN107180419B (en) | Median filtering detection method based on PCA (principal component analysis) network | |
CN115797970B (en) | Dense pedestrian target detection method and system based on YOLOv5 model | |
CN114821174B (en) | Content perception-based transmission line aerial image data cleaning method | |
CN116259087A (en) | Low-resolution face recognition method | |
CN113052080A (en) | Illegal unmanned aerial vehicle detection method based on unsupervised generation countermeasure network | |
CN112418085A (en) | Facial expression recognition method under partial shielding working condition |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |