CN108366295B - Video classification feature extraction method, transcoding recompression detection method and storage medium - Google Patents

Video classification feature extraction method, transcoding recompression detection method and storage medium Download PDF

Info

Publication number
CN108366295B
CN108366295B CN201810144370.0A CN201810144370A CN108366295B CN 108366295 B CN108366295 B CN 108366295B CN 201810144370 A CN201810144370 A CN 201810144370A CN 108366295 B CN108366295 B CN 108366295B
Authority
CN
China
Prior art keywords
video
frame
compressed
classification
partition type
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.)
Expired - Fee Related
Application number
CN201810144370.0A
Other languages
Chinese (zh)
Other versions
CN108366295A (en
Inventor
于丽芳
李赵红
张珍珍
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Jiaotong University
Beijing Institute of Graphic Communication
Original Assignee
Beijing Jiaotong University
Beijing Institute of Graphic Communication
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Beijing Jiaotong University, Beijing Institute of Graphic Communication filed Critical Beijing Jiaotong University
Priority to CN201810144370.0A priority Critical patent/CN108366295B/en
Publication of CN108366295A publication Critical patent/CN108366295A/en
Application granted granted Critical
Publication of CN108366295B publication Critical patent/CN108366295B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/4402Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display
    • H04N21/440218Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display by transcoding between formats or standards, e.g. from MPEG-2 to MPEG-4
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/17Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
    • H04N19/172Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object the region being a picture, frame or field
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/177Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a group of pictures [GOP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/70Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by syntax aspects related to video coding, e.g. related to compression standards
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/44008Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving operations for analysing video streams, e.g. detecting features or characteristics in the video stream

Abstract

The invention provides a video classification feature extraction method, a transcoding recompression detection method and a storage medium, wherein the video classification feature extraction method comprises the following steps: extracting PU partition types of video frames by using a visual analyzer, and marking the extracted PU partition types of the video frames by using pixel blocks as basic units; counting the number of pixel blocks corresponding to each PU partition type of a first P frame in each group of continuous pictures in the video; and calculating the average value of the pixel block numbers corresponding to the PU partition types of the first P frame in all the groups of continuous pictures to obtain the classification characteristics of the PU partition types of the first P frame in all the groups of continuous pictures. The invention uses the features of fewer dimensions, and achieves higher detection rate of the recompressed video.

Description

Video classification feature extraction method, transcoding recompression detection method and storage medium
Technical Field
The invention relates to the technical field of video processing, in particular to a video classification feature extraction method, a video transcoding recompression detection method and a computer readable storage medium.
Background
With the rapid growth of the current internet, the acquisition and transmission of digital video is becoming increasingly sophisticated and popular. Meanwhile, video editing software with increasingly powerful functions is also sought by people more and more, so that the situation that the digital video is tampered occurs sometimes. When the tampered video is used in the industries of judicial and media, the fact is distorted, and serious consequences of judicial misjudgment and media misappropriation are caused. Thus, the authenticity and integrity of digital video is a problem that is urgently needed to be solved by the current society.
At present, domestic and foreign research is mainly focused on digital images, and a large number of research results are obtained. For example, detecting illegal copies of copyrighted images, copy movement detection in images, and distinguishing computer-generated images from photographic images. Due to the characteristics of large information amount, various tampering modes and the like of videos, the evidence obtaining research of the videos is difficult and serious. By means of the progress of image evidence collection research, video evidence collection technology has been developed greatly in recent years.
Common video tampering means generally need to undergo tampering operations such as decoding, frame deletion or frame insertion, and the like, and tampered video sequences can be regenerated into video code streams only after being compressed again. Therefore, detecting whether a video is recompressed can be used as a technical means for detecting whether a video is tampered. In the prior art, there are various methods for detecting the counterweight compression, such as: when the MPEG video is recompressed at the same bit rate, the change number of DCT coefficient of single compression and double compression is more than that of double compression and triple compression, and the recompression detection of the video is performed by using the phenomenon. The recompression of the MPEG video is detected by examining the blockiness intensity regularity of the recompressed video and the variance of the mean value thereof. The difference in motion compensation edge effects of adjacent P frames is exploited and the recompression of MPEG video is detected by determining whether a spike is present in the fourier transform domain. The convex characteristic of a statistic histogram of quantized DCT coefficients in the recompressed video is utilized to distinguish the MPEG-2 single-time compressed video from the recompressed video, and the algorithm is suitable for detecting the recompression adopting different MPEG-2 encoders and has robustness for frame deletion tampering. A detection algorithm characterized by the probability of non-zero quantized AC coefficients is used to distinguish H.264 single-compression videos from double-compression videos, and achieves high classification accuracy when the second-compression quantization parameters are smaller than the first-compression quantization parameters. A H.264 video multiple compression evidence obtaining algorithm under the same quantization parameter constructs a feature set containing quartile by using the ratio difference of different quantization DCT coefficients between adjacent three times of compression, and the feature set is used as the input of a support vector machine to realize the classification of single compression video and multiple compression video. The algorithm has high classification precision and stronger robustness to copy/paste attacks and frame deletion attacks.
Compared with H.264, the HEVC provides double data compression ratio under the condition of the same video quality, namely the HEVC can greatly improve the video quality under the condition of the same bit rate, and the supported resolution is up to 8192 × 4320, wherein 8k UHD is also included.
Therefore, in order to solve the above technical problems, a video classification feature extraction method and a video transcoding recompression detection method that have few classification feature dimensions and achieve a high detection rate are needed.
Disclosure of Invention
The invention aims to provide a video classification feature extraction method and a video transcoding recompression detection method, so as to solve at least one defect in the prior art.
One aspect of the present invention provides a method for detecting recompression of a video transcoding, the method comprising:
extracting a Prediction Unit (PU) partition type of a video frame by using a visual analyzer, and marking the extracted PU partition type of the video frame by using a pixel block as a basic unit;
counting the number of pixel blocks corresponding to each PU partition type of a first P frame in each group of continuous pictures in the video;
and calculating the average value of the pixel block numbers corresponding to the PU partition types of the first P frame in all the groups of continuous pictures to obtain the classification characteristics of the PU partition types of the first P frame in all the groups of continuous pictures.
Preferably, the RGB components of the boundary color of the visual analyzer are set when the PU partition type of the video frame is extracted, and may preferably be set to (255,0,255) or any other suitable component value capable of distinguishing the PU partition border from the video content.
Preferably, the PU partition type of the video frame is marked by using an N × N pixel block as a basic unit, wherein N is 4 or an integral multiple value of 4.
Preferably, the averaging of the numbers of pixel blocks corresponding to the PU partition types of the first P frame in all the groups of consecutive pictures is implemented by the following formula:
Figure GDA0002407401330000031
wherein P isi={pi,0,pi,1,...,pi,24M is the number of groups of consecutive pictures contained in the video.
Another aspect of the present invention is to provide a method for detecting recompression of video transcoding, including:
randomly selecting single compressed videos and re-compressed videos with the same number as training samples to be sent to a support vector machine;
performing video classification feature extraction on the single-time compressed video and the recompressed video according to the following method: analyzing the PU partition type, extracting the PU partition type of the video frame by using a visual analyzer, and marking the extracted PU partition type of the video frame by using a pixel block as a basic unit; counting the number of pixel blocks corresponding to each PU partition type of a first P frame in each group of continuous pictures in the video; calculating the average value of the pixel block numbers corresponding to the PU partition types of the first P frame in all the groups of continuous pictures to obtain the classification characteristics of the PU partition types of the first P frame in all the groups of continuous pictures;
the support vector machine constructs a decision function according to the extracted classification features;
and randomly selecting a single compressed video and a recompressed video for testing as test samples and sending the test samples to the support vector machine, wherein the support vector machine outputs a classification detection result for judging whether the tested video is the single compressed video or the recompressed video according to the decision function.
Preferably, the method further includes calculating an evaluation index representing classification performance by:
Figure GDA0002407401330000032
wherein, AR is an evaluation index, and TNR is a ratio judged as a single-pass compressed video; the TPR is a ratio determined to recompress the video.
Preferably, the method further comprises: the detection rate representing the detection of video compression is calculated by:
Figure GDA0002407401330000041
where n is the number of times different video samples are tested and trained.
The recompressed video is original video compressed in any standard format of H.261, H.263+, H.264, MPEG-1, MPEG-2 and MPEG-4 at a first bit rate. For example, the recompressed video is obtained by performing h.264 compression on an original video at a first bit rate, decoding the original video, and performing HEVC compression on the decoded video at a second bit rate.
Preferably, the single-compression video is a video obtained by HEVC compression of an original video at a second bit rate.
For example, when the PU partition type of the video frame is extracted, RGB components of the boundary color of the visual analyzer are selected to be (255,0,255), and the PU partition type of the video frame is marked by using an 8 × pixel block as a basic unit.
Preferably, the averaging of the number of pixel blocks corresponding to each PU partition type of the first P frame in all groups of consecutive pictures is implemented by:
Figure GDA0002407401330000042
wherein P isi={pi,0,pi,1,...,pi,24M is the number of groups of consecutive pictures contained in the video.
Yet another aspect of the present invention also provides a computer-readable storage medium having stored thereon a computer program which, when executed, performs the method steps as described above.
According to the video classification feature extraction method and the video transcoding recompression detection method, recompression detection is performed on the H.264-HEVC standard video transcoding recompression video, the extracted classification feature dimension is small, and higher detection rate can be achieved. In addition, the method provided by the invention can also be applied to the video coding standard before the first video coding standard is detected to be other HEVC standards, for example, the method can also be applied to any one of H.261, H.263+, MPEG-1, MPEG-2 and MPEG-4 standards.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention, as claimed.
Drawings
Further objects, features and advantages of the present invention will become apparent from the following description of embodiments of the invention, with reference to the accompanying drawings, in which:
FIG. 1 is a diagram illustrating PU partition modes in different prediction modes;
FIG. 2 is a block flow diagram of a video classification feature extraction method of the present invention;
FIGS. 3a to 3d are schematic diagrams of P frame PU partition types of single-compression video and re-compression video;
FIG. 4 is a schematic diagram of the marking of PU partition types according to the present invention;
fig. 5 is a flow chart of the video transcoding recompression detection method of the present invention.
Detailed Description
The objects and functions of the present invention and methods for accomplishing the same will be apparent by reference to the exemplary embodiments. However, the present invention is not limited to the exemplary embodiments disclosed below; it can be implemented in different forms. The nature of the description is merely to assist those skilled in the relevant art in a comprehensive understanding of the specific details of the invention.
Hereinafter, embodiments of the present invention will be described with reference to the accompanying drawings. In the drawings, the same reference numerals denote the same or similar parts, or the same or similar steps. In the following, the content of the present invention will be described by specific embodiments, and after a video falsifier has falsified a video by deleting or inserting frames, another video compression format is required to recompress the video sequence. Compared with other coding standards, h.264 coding is most relevant to HEVC coding, and the coding architecture is roughly similar. After a tamperer tampers the original video in the H.264 format, HEVC coding is adopted for recompression when recompressing. The h.264 coding standard is adopted in this example as the standard for the first video compression.
After the video is transcoded and recompressed, due to the change of the pixel value of the key frame, when the first P frame in a group of consecutive pictures (GOP) is inter-frame prediction encoded by using the key frame as a reference frame, the intra-frame PU partition type is also changed correspondingly. Based on the phenomenon, the invention adopts the histogram to count the pixel block number corresponding to each PU partition type in the frame, and the pixel block number is used as a classification characteristic to detect transcoding and recompression of the video.
In order to make the present invention more clearly illustrated for transcoding recompression detection from other coding standards to HEVC, it is necessary to describe P-frame PU partition types, HEVC adopts a hybrid coding framework of prediction plus transform, and HEVC introduces three basic units, i.e., a Coding Unit (CU), a Prediction Unit (PU) and a Transform Unit (TU), so that HEVC is more flexible than the coding mode of h.264/AVC, wherein a CU is a coding basic unit, a PU is used for intra and inter prediction, and a TU is used for transform and quantization, a PU is a basic unit containing prediction information, a CU can be partitioned into one or more PUs, PU prediction modes can be partitioned into skip, intra, and inter modes, as shown in fig. 1, the PU size can only be 2N × N when the prediction mode is skip mode a, a PU size can only be 2N × N when the prediction mode is intra mode b, a PU partition mode has two partition modes, i.e., 2N × N and N × N, when the prediction mode is intra mode b, a PU partition mode has two partition modes, 8N 2N 462N 12N and N5N 2N, a symmetric partition mode, a partition mode can be configured by turning on, a symmetric partition mode, a partition mode, a.
In the transcoding video recompression process, the prediction information contained by the PU block explains the prediction process of the CU block. As shown in fig. 2, a flow chart of the video classification feature extraction method of the present invention is shown, and as shown in fig. 2, the video classification feature extraction method provided by the embodiment of the present invention includes the following steps:
and step S101, analyzing the PU partition types, extracting the PU partition types of the video frame and marking.
For the PU partition type analysis, as shown in fig. 3a to 3d, P frame PU partition type diagrams of a single-time compressed video and an h.264 to HEVC re-compressed video are shown, and in the embodiment, the classification features of the video are extracted by analyzing the PU partition types. Fig. 3a shows PU partition type of the first P frame in the first group of consecutive pictures (GOP) of bridge _ far compressed at 3.5M bit rate using HEVC coding. Fig. 3b shows the PU partition type of the first P frame in the first group of consecutive pictures (GOP) compressed at 3M bit rate using h.264 coding and then compressed at 3.5M bit rate using HEVC coding. Fig. 3c shows PU partition types for the first P frame in the first group of consecutive pictures (GOP) of bridge _ far compressed at 3.5M bit rate using HEVC coding after compression at 3.5M bit rate using h.264 coding. Fig. 3d shows PU partition types for the first P frame in the first group of consecutive pictures (GOP) of bridge _ far compressed at 3.5M bit rate using HEVC coding after 4M bit rate compression using h.264 coding.
TABLE 1 number of pixel blocks corresponding to each PU partition type
Figure GDA0002407401330000061
Figure GDA0002407401330000071
As can be seen from Table 1, the pixel block number distribution trends for each of the PU partition types 3M-3.5M, 3.5M-3.5M, and 4M-3.5 are approximately the same, with a greater difference from the pixel block number distribution for the PU partition type 3.5M, especially for PU partition types 4 × 4, 8 × 8, 4 × 8, 8 × 4, the pixel block number distributions for each of the PU partition types 3M-3.5M, 3.5M-3.5M, and 4M-3.5 have a greater difference from the pixel block number distribution for the PU partition type 3.5M.
Analyzing the PU partition type and displaying the PU partition type in the table 1, wherein the PU partition type of the first P frame in the first group of continuous pictures (GOP) compressed by HEVC coding is mainly a small pixel block after H.264 coding is used; the PU partition type of the first P frame in a first group of consecutive pictures (GOP) compressed by single-use HEVC coding is dominated by large pixel blocks. Thus, the PU of the first P frame in the first group of consecutive pictures (GOP) compressed using HEVC coding after h.264 coding is a fine PU partition type.
It should be understood that in h.264 coding compression, each pixel block is DCT transformed separately and the correlation between blocks is ignored. Discontinuous transitions occur in pixel values at block-to-block boundaries. When video is compressed by HEVC coding again, a smaller PU partition type is needed at the boundary between blocks to express the image jump due to the block effect. The video coding standards before HEVC except h.264 also use block DCT transform, and there is also block effect, so it can be expected that when video coding standards before HEVC are used for video compression and then transcoding into HEVC format video, smaller PU partition types are required to express image jump at block boundaries.
According to the embodiment of the invention, after the PU partition type is analyzed, the visual analyzer is utilized to extract the PU partition type of the video frame, and the extracted PU partition type of the video frame is marked by taking the pixel block as a basic unit.
In particular, in an embodiment, the visualization analyzer may employ video analysis software such as Gitl _ HEVC _ Analyze or any other suitable software to perform PU partition type extraction on the video frame. To distinguish the video background from the PU partition type boundary, the RGB components of the visual analyzer boundary color are set to (255,0, 255).
According to the present invention, the PU partition types of the video frame in the embodiment are marked by using 8 × 8 pixel blocks as basic units, the PU partition types in the embodiment are marked by labels, table 2 is the PU partition types corresponding to the labels, and according to the present invention, there are 25 PU partition types in the embodiment, as shown in fig. 4, a schematic diagram of the marking of the PU partition types in the present invention.
TABLE 2 PU partition types corresponding to the designations
Figure GDA0002407401330000081
Figure GDA0002407401330000091
Step S102, counting the number of pixel blocks corresponding to each PU partition type of the first P frame in each group of continuous pictures in the video.
And counting the pixel block number corresponding to each PU partition type of the first P frame in each group of continuous pictures in the video. Recording the number of pixel blocks corresponding to each PU partition type of the first P frame in each group of continuous pictures as: pi={pi,0,pi,1,...,pi,24M is the number of groups of consecutive pictures contained in the video, i.e. each PiThe number of 8 × 8 pixel blocks corresponding to the 25 PU partition types is recorded.
And step S103, extracting the classification features of the video.
And calculating the average value of the pixel block numbers corresponding to the PU partition types of the first P frame in all the groups of continuous pictures to obtain the classification characteristics of the PU partition types of the first P frame in all the groups of continuous pictures. The average value of the pixel block numbers corresponding to the PU partition types of the first P frame in all the groups of continuous pictures is obtained by the following formula:
Figure GDA0002407401330000092
wherein P isi={pi,0,pi,1,...,pi,24M is the number of groups of consecutive pictures contained in the video.
And taking the average value of the number of pixel blocks corresponding to each PU partition type of the first P frame in all the groups of continuous pictures as a histogram of the number of pixel blocks corresponding to each PU partition type of the first P frame in each group of continuous pictures to obtain the classification characteristics of the video.
The video transcoding recompression detection method by the video classification feature extraction method of the invention is shown in fig. 5, which is a flow diagram of the video transcoding recompression detection method of the invention, and specifically a video transcoding recompression detection method comprises:
step S201, randomly selecting single compressed videos and recompressed videos with the same number as training samples and sending the training samples to a support vector machine.
The recompressed video is obtained by performing H.264 compression on an original video at a first bit rate, decoding the original video, and performing HEVC compression on the decoded video at a second bit rate. The single-compression video is a video obtained by performing HEVC compression on an original video at a second bit rate.
Specifically, in the embodiment, a single-pass compressed video and a recompressed video are first produced as detection targets.
Using 34 uncompressed YUV sequences as the initial video, including 17 QCIF format videos (resolution 176 × 144) and 17 CIF format videos (resolution 352 × 288) — to increase the sample capacity, each video is split into non-overlapping video slices of 100 frames in length.
HM10.0 uses the encoder _ lowdelay _ P _ main profile for the HEVC encoding and decoding process. The JM performs the h.264 encoding and decoding process using the encoder _ main profile. The frame rate, I-frame period and GOP size are set to 30, 4 and 4, respectively.
Making a single passAnd (3) compressing the video: at a second bit rate (B) for the original video2) HEVC compression is carried out.
Making a recompressed video: at a first bit rate (B) to the original video1) H.264 compressed, decoded and then decoded video at a second bit rate (B)2) And performing HEVC compression.
In the embodiment, since QCIF and CIF videos have different spatial resolutions, different bit rates should be selected to ensure the visual quality of the encoded video. For QCIF video, a first bit rate (B)1) And a second bit rate (B)2) Are selected from {100,200,300} (kbps) and {200,300,400} (kbps), respectively. For CIF video, a first bit rate (B)1) And a second bit rate (B)2) Selected from {3,3.5,4} (Mbps) and {3.5,4,4.5} (Mbps), respectively.
And selecting the single compressed videos and the re-compressed videos with the same number from the single compressed videos and the re-compressed videos which are manufactured as training samples, and sending the training samples to a Support Vector Machine (SVM) for training. In the embodiment, 30 single-compression videos and 30 recompressed videos are randomly selected for the video in the QCIF format to be trained. And randomly selecting 35 single-compression videos and 35 recompressed videos for training for the videos in the CIF format.
In the training phase, a Support Vector Machine (SVM) executes the steps 2 and 3 to construct a decision function.
And step 202, extracting classification features of the single-time compressed video and the recompressed video.
According to the invention, the embodiment performs video classification feature extraction on the single-time compressed video and the recompressed video according to the following method:
extracting PU partition types of video frames by using a visual analyzer, and marking the extracted PU partition types of the video frames by using pixel blocks as basic units;
counting the number of pixel blocks corresponding to each PU partition type of a first P frame in each group of continuous pictures in the video;
and calculating the average value of the pixel block numbers corresponding to the PU partition types of the first P frame in all the groups of continuous pictures to obtain the classification characteristics of the PU partition types of the first P frame in all the groups of continuous pictures.
And S203, the support vector machine constructs a decision function according to the extracted classification features.
The extraction of the video classification features in step 2 has already been explained in detail above, and is not described here again.
Preferably, the support vector machine in the embodiment can select L IBSVM open source software with SVMcg kernel or other software with similar functions as the classifier.
And S204, randomly selecting single compressed video and recompressed video for testing as test samples, sending the test samples into the support vector machine, and outputting a classification result.
And randomly selecting a single compressed video and a recompressed video for testing as test samples and sending the test samples to the support vector machine, wherein the support vector machine outputs a classification detection result for judging whether the tested video is the single compressed video or the recompressed video according to the decision function.
According to the present invention, the present embodiment can calculate the evaluation index representing the classification performance by:
Figure GDA0002407401330000111
wherein, AR is an evaluation index, and TNR is a ratio judged as a single-pass compressed video; the TPR is a ratio determined to recompress the video.
The detection rate of video compression detection is calculated and expressed by the following way:
Figure GDA0002407401330000112
where n is the number of times different video samples are tested and trained.
In this embodiment, an average value of the detection rates obtained by selecting 20 times of training and testing is calculated as follows:
Figure GDA0002407401330000113
where AR is the evaluation index and n is 20.
In order to more clearly embody the advantages of the video classification feature extraction method and the video transcoding recompression detection method provided by the present invention, in this embodiment, the video classification feature extraction method and the video transcoding recompression detection method provided by the present invention are respectively adopted to compare with the video transcoding recompression detection method that adopts the co-occurrence matrix of the pixel block number corresponding to the PU partition type of the I frame as the video classification feature. Table 3 shows the detection rate of the recompressed video in QCIF format of the present invention, table 3 shows the detection rate of the recompressed video in CIF format of the present invention, and table 5 shows the detection rate of the recompressed video in QCIF format of the video transcoding recompression detection method that uses the co-occurrence matrix of the number of pixel blocks corresponding to the PU partition type of the I frame as the video classification characteristic.
TABLE 3 detection Rate of recompressed video in QCIF format of the present invention
B1/B2 200k 300k 400k
100k 0.9667 0.9167 0.9125
200k 0.9208 0.9750 0.9750
300k 0.9208 0.9417 0.9500
TABLE 4 detection Rate of recompressed video in CIF format of the invention
B1/B2 3.5M 4M 4.5M
3M 0.9813 0.9781 0.9875
3.5M 0.9875 0.9750 0.9688
4M 0.9813 0.9844 0.9813
Table 5. detection rate of recompressed video in QCIF format of video transcoding recompression detection method adopting symbiotic matrix of pixel block number corresponding to PU partition type of I frame as video classification characteristic
B1/B2 200k 300k 400k
100k 0.7750 0.8417 0.8667
200k 0.8375 0.8709 0.8667
300k 0.7957 0.8375 0.8917
As can be seen from tables 3 and 4, by using the video classification feature extraction method and the video transcoding recompression detection method of the present invention, the recompression detection rates of the QCIF and CIF formats both reach over 90%, the highest rate reaches 98.75%, and the lowest rate is 92.08%.
As can be seen from table 5, in the prior art, a video transcoding recompression detection method that uses a co-occurrence matrix of the number of pixel blocks corresponding to the PU partition type of the I frame as a video classification feature is adopted, and the recompression video detection rate in the QCIF format is between 77% and 90%. The detection accuracy of the recompressed video is 91-97.5%, which is obviously higher than that of the prior art. Meanwhile, in the embodiment, the video classification feature extraction method and the video transcoding recompression detection method are adopted, the PU partition types are 25, and in the prior art, the PU partition types of the video transcoding recompression detection method adopting the co-occurrence matrix of the number of pixel blocks corresponding to the PU partition type of the I frame as the video classification feature are 100. The PU partition type of the present invention is prior art 1/4. The PU division type dimension is lower than that of the prior art, the calculation amount is reduced, and the detection rate of the recompressed video is improved. The video classification feature extraction method and the video transcoding recompression detection method are more effective.
According to the video classification feature extraction method and the video transcoding recompression detection method, recompression detection is performed on the H.264-HEVC standard video transcoding recompression video, the extracted classification feature dimension is small, and higher detection rate can be achieved.
Portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any one or a combination of the following technologies, which are well known in the art, may be implemented: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
The logic and/or steps represented in the flowcharts or otherwise described herein, such as an ordered listing of executable instructions that can be considered to implement logical functions, can be embodied in any computer-readable storage medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. "computer-readable storage media" may include any medium that can store or transfer information. Examples of a machine-readable medium include electronic circuits, semiconductor memory devices, ROM, flash memory, Erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, fiber optic media, Radio Frequency (RF) links, and so forth.
Features that are described and/or illustrated above with respect to one embodiment may be used in the same way or in a similar way in one or more other embodiments and/or in combination with or instead of the features of the other embodiments.
It should also be noted that the exemplary embodiments mentioned in this patent describe some methods or systems based on a series of steps or devices. However, the present invention is not limited to the order of the above-described steps, that is, the steps may be performed in the order mentioned in the embodiments, may be performed in an order different from the order in the embodiments, or may be performed simultaneously.
In addition, the method provided by the invention can also be applied to the scene of transcoding the compressed format standard into the HEVC format before other HEVC standards, for example, any one of H.261, H.263+, MPEG-1, MPEG-2 and MPEG-4 standards.
Other embodiments of the invention will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the invention being indicated by the following claims.

Claims (9)

1. A video classification feature extraction method is characterized by comprising the following steps:
extracting a PU partition type of a prediction unit of a video frame by using a visual analyzer, and marking the extracted PU partition type of the video frame by using a pixel block as a basic unit;
counting the number of pixel blocks corresponding to each PU partition type of a first P frame in each group of continuous pictures in the video;
and calculating the average value of the pixel block numbers corresponding to the PU partition types of the first P frame in all the groups of continuous pictures to obtain the classification characteristics of the PU partition types of the first P frame in all the groups of continuous pictures.
2. The method of claim 1, wherein the PU partition type of the video frame is marked with a basic unit of N × N pixel blocks, wherein N is 4 or 8.
3. The method according to claim 1, wherein the averaging of the number of pixel blocks corresponding to each PU partition type of the first P frame in all groups of consecutive pictures is performed by the following formula:
Figure FDA0002407401320000011
wherein P isi={pi,0,pi,1,...,pi,24M is the number of groups of consecutive pictures contained in the video.
4. A method for detecting transcoding and recompression of a video, the method comprising:
randomly selecting single compressed videos and re-compressed videos with the same number as training samples to be sent to a support vector machine;
performing video classification feature extraction on the single-pass compressed video and the re-compressed video according to the video classification feature extraction method of any one of claims 1 to 3;
the support vector machine constructs a decision function according to the extracted classification features;
and randomly selecting a single compressed video and a recompressed video for testing as test samples and sending the test samples to the support vector machine, wherein the support vector machine outputs a classification detection result for judging whether the tested video is the single compressed video or the recompressed video according to the decision function.
5. The method of claim 4, further comprising:
an evaluation index representing classification performance is calculated by:
Figure FDA0002407401320000021
wherein, AR is an evaluation index, and TNR is a ratio judged as a single-pass compressed video; the TPR is a ratio determined to recompress the video.
6. The method of claim 5, further comprising:
the detection rate representing the detection of video compression is calculated by:
Figure FDA0002407401320000022
where n is the number of times different video samples are tested and trained.
7. The method according to claim 4, wherein the re-compressed video is an original video compressed in any one of standard formats of H.261, H.263+, H.264, MPEG-1, MPEG-2 and MPEG-4 at a first bit rate, and the original video is subjected to HEVC compression at a second bit rate after being decoded.
8. The method of claim 4, wherein the single-pass compressed video is HEVC compressed video at a second bit rate from an original video.
9. A computer-readable storage medium, in which a computer program is stored which, when being executed, carries out the method steps of any one of claims 1 to 8.
CN201810144370.0A 2018-02-12 2018-02-12 Video classification feature extraction method, transcoding recompression detection method and storage medium Expired - Fee Related CN108366295B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810144370.0A CN108366295B (en) 2018-02-12 2018-02-12 Video classification feature extraction method, transcoding recompression detection method and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810144370.0A CN108366295B (en) 2018-02-12 2018-02-12 Video classification feature extraction method, transcoding recompression detection method and storage medium

Publications (2)

Publication Number Publication Date
CN108366295A CN108366295A (en) 2018-08-03
CN108366295B true CN108366295B (en) 2020-07-14

Family

ID=63006028

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810144370.0A Expired - Fee Related CN108366295B (en) 2018-02-12 2018-02-12 Video classification feature extraction method, transcoding recompression detection method and storage medium

Country Status (1)

Country Link
CN (1) CN108366295B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2020061008A1 (en) * 2018-09-18 2020-03-26 Google Llc Receptive-field-conforming convolution models for video coding
CN109587498B (en) * 2018-12-25 2022-07-08 华南农业大学 Identification method for transcoding HEVC video by AVC
CN109982071B (en) * 2019-03-16 2020-08-11 四川大学 HEVC (high efficiency video coding) dual-compression video detection method based on space-time complexity measurement and local prediction residual distribution
CN113065533B (en) * 2021-06-01 2021-11-02 北京达佳互联信息技术有限公司 Feature extraction model generation method and device, electronic equipment and storage medium

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006279573A (en) * 2005-03-29 2006-10-12 Sanyo Electric Co Ltd Encoder and encoding method, and decoder and decoding method
CN101790097B (en) * 2010-03-05 2012-05-09 天津大学 Method for detecting multiple times of compression and coding of digital video
US8711940B2 (en) * 2010-11-29 2014-04-29 Mediatek Inc. Method and apparatus of motion vector prediction with extended motion vector predictor
CN102413327A (en) * 2011-11-10 2012-04-11 中山大学深圳研究院 Video tampering detection method based on compressed sensing semi fragile watermark
CN105072444B (en) * 2015-07-31 2018-01-05 宁波大学 A kind of HEVC video second-compressed detection methods under different quantization parameters

Also Published As

Publication number Publication date
CN108366295A (en) 2018-08-03

Similar Documents

Publication Publication Date Title
CN108366295B (en) Video classification feature extraction method, transcoding recompression detection method and storage medium
US8848061B2 (en) Image and video quality assessment
US6473459B1 (en) Scene change detector
JP5467651B2 (en) Encoding bitstream modification
Aghamaleki et al. Inter-frame video forgery detection and localization using intrinsic effects of double compression on quantization errors of video coding
US20100303150A1 (en) System and method for cartoon compression
CN109104609B (en) Shot boundary detection method fusing HEVC (high efficiency video coding) compression domain and pixel domain
Ravi et al. Compression noise based video forgery detection
Luo et al. MPEG recompression detection based on block artifacts
He et al. Double compression detection based on local motion vector field analysis in static-background videos
JP4951521B2 (en) Video fingerprint system, method, and computer program product
US8433143B1 (en) Automated detection of video artifacts in an information signal
KR101149522B1 (en) Apparatus and method for detecting scene change
JP2005510149A (en) Method and system for detecting intra-coded pictures and extracting intra DC scheme and macroblock coding parameters from uncompressed digital video
CN106331730B (en) H.264 video same quantization factor double compression detection method
Tan et al. GOP based automatic detection of object-based forgery in advanced video
Ye et al. A new adaptive watermarking for real-time MPEG videos
Xu et al. Detection of video transcoding for digital forensics
CN110728613B (en) Non-additive distortion JPEG image steganography method based on blocking effect
JP2012054818A (en) Image processing apparatus and image processing method
CN111711822B (en) Video steganography method, system and device based on macro block complexity
US20120133836A1 (en) Frame level quantization estimation
US8768004B2 (en) Method for watermark detection using reference blocks comparison
Jin et al. Video frame deletion detection based on time–frequency analysis
Liu et al. Perceptual quality measurement of video frames affected by both packet losses and coding artifacts

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
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20200714

Termination date: 20210212

CF01 Termination of patent right due to non-payment of annual fee