CN102148989B - Method for detecting all-zero blocks in H.264 - Google Patents

Method for detecting all-zero blocks in H.264 Download PDF

Info

Publication number
CN102148989B
CN102148989B CN 201110102642 CN201110102642A CN102148989B CN 102148989 B CN102148989 B CN 102148989B CN 201110102642 CN201110102642 CN 201110102642 CN 201110102642 A CN201110102642 A CN 201110102642A CN 102148989 B CN102148989 B CN 102148989B
Authority
CN
China
Prior art keywords
piece
reference block
block
zero piece
complete zero
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
CN 201110102642
Other languages
Chinese (zh)
Other versions
CN102148989A (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.)
Xian Jiaotong University
Original Assignee
Xian Jiaotong University
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 Xian Jiaotong University filed Critical Xian Jiaotong University
Priority to CN 201110102642 priority Critical patent/CN102148989B/en
Publication of CN102148989A publication Critical patent/CN102148989A/en
Application granted granted Critical
Publication of CN102148989B publication Critical patent/CN102148989B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

The invention provides a method for detecting all-zero blocks in H.264. Based on the relativity between a reference block and a current encoding block and by combining with an idea of mode recognition, a linear classifier for all-zero block detection is provided. Through carrying out all-zero block prejudgment before transform and quantization, the condition that a residual block coefficient is zero can be detected in advance, thereby omitting the transform and quantization process of a residual block. The method has an extremely great significance for encoding of a video with a low code rate, because the proportion of the all-zero blocks is very large under the condition of low code rate, and the calculation complexity of the transform and quantization can be greatly reduced if most of all-zero blocks are detected, thereby improving encoding efficiency.

Description

A kind of H.264 in the method that detects of complete zero piece
Technical field
The invention belongs to technical field of video coding, be specifically related to a kind of H.264 in the method that detects of complete zero piece.
Background technology
H.264 the digital video coding standard of new generation that the joint video team JVT that is made up of the expert of International Telecommunication Union and International Standards Organization (ISO/IEC) proposes.Compare with video encoding standard before; H.264 new coding techniquess such as multiple predictive mode, 4 * 4 integer transforms, adaptive arithmetic code have been adopted; Its code efficiency improves more than 70%, but its computation complexity is very high, makes encoder realize that real-time coding is very difficult.Generally speaking, model selection and estimation are the highest two parts of coding side complexity H.264.In recent years, many quick modes selections and rapid motion estimating method are suggested to reduce encoder complexity H.264.After estimation and model selection were optimised, the computation complexity of transform and quantization part just became more outstanding.
Because in video compression coding, a lot of video sequences all have characteristics such as motion is slow, stationary background, have very strong correlation, so the effect of inter prediction encoding are splendid, the absolute value of the residual signals that is produced is also very little.If the coefficient after the residual signals of encoding block process dct transform, the quantification all is zero, claim that then such piece is complete zero piece.Obviously for complete zero piece, operations such as conversion, quantification all are unnecessary.Therefore,, reduce the corresponding calculated load, reduce encoder complexity if, just can skip operations such as conversion, quantification H.264 detecting complete zero piece in advance in the interframe encode process.H.264 inter prediction encoding process is following:
1, input current macro is carried out piece and is divided;
2, use motion estimation algorithm to obtain motion vector, find out the optimal reference piece of present encoding piece;
3, the present encoding piece deducts the optimal reference piece, obtains residual block;
4, residual block is carried out change quantization;
5, the data behind the change quantization are carried out inverse quantization and inverse transformation, obtain reconstructed block, do reference when supplying the next code frame to carry out inter prediction;
6, at last each macro block is carried out entropy coding.
Existing complete zero piece detection technique mostly through judge 4 * 4 absolute error with (SAD) and the relation between the pre-set threshold detect entirely zero piece; And the characteristic of encoding characteristics H.264 and video itself is not considered, therefore the verification and measurement ratio of complete zero piece still has the space of lifting.
Summary of the invention
The objective of the invention is to overcome the problem of the existence of above-mentioned prior art, provide a kind of can reduce H.264 encoder complexity H.264 in the method that detects of complete zero piece.
For achieving the above object, the technical scheme that the present invention adopts is:
The characteristic of the residual block of the dissimilar video sequence that 1) will store [MV_COST, MODE, SAD, QP, REF_AZB] is as training data;
2) training data that according to the value of the characteristic REF_AZB of reference block step 1) is obtained is divided into two kinds of situation: situation 1: when the characteristic REF_AZB=1 with reference to the domestic animal piece is a reference block when being complete zero piece, and situation 2: when the characteristic REF_AZB=0 with reference to the domestic animal piece is that reference block is when being the non-full zero piece;
3) to step 2) two kinds of situation under training data carry out training and operation respectively to obtain two graders be the linear classifier of linear classifier and the reference block of reference block when being complete zero piece when being the non-full zero piece:
3.1) utilize linear decision rule that all training datas are trained, obtain weight coefficient vector [a 1, a 2, a 3];
3.2) weight coefficient vector that will train brings formula (1) into, and the training data under the same quantization parameter QP is utilized 3.1) and in linear decision rule train the threshold value Threshold (QP) under the current quantization parameter QP;
Figure BDA0000056911870000031
In the formula, x 1Be the cost (MV_COST) of motion vector, x 2Be block type (MODE), x 3Be absolute error with (SAD);
3.3) utilize the principle of least square to fit to the order polynomial about quantization parameter QP to the threshold value Threshold (QP) under each quantization parameter QP, obtain the linear classifier of formula (2) form;
Figure BDA0000056911870000032
B wherein i(i ≠ 0) is weight coefficient, b 0Be constant, n represent in the multinomial which;
4) reference block as if the present encoding piece is complete zero piece execution in step 5 in the cataloged procedure); If reference block is the non-full zero piece, jump to step 6);
5) using reference block is the linear classifier of complete zero piece, if the present encoding piece is complete zero piece, jumps to step 7), otherwise jumps to step 8);
6) use the linear classifier of reference block,, jump to step 7), otherwise jump to step 8) if the present encoding piece is complete zero piece as the non-full zero piece;
7) skip the change quantization operation,, jump to step 9) the corresponding variable assignments of complete zero piece;
8) change quantization obtains coefficient block, jumps to step 9);
9) inverse quantization, inverse transformation, preservation information gets into next block encoding.
For solving the problem that exists in the background technology, the present invention is from the correlation of reference block and present encoding piece, and the thought of binding pattern identification has proposed the linear classifier that complete zero piece detects.Through carrying out complete zero piece anticipation before the change quantization, can detect residual block coefficient behind the change quantization in advance and be zero situation, thereby save the change quantization process of residual block.The present invention is particularly outstanding for the meaning of low bit-rate video coding, because the ratio of complete zero piece is very big under low code check situation, detects most of complete zero piece in advance and will reduce the computation complexity of change quantization greatly, thereby improve code efficiency.
Description of drawings
Fig. 1 is a flow chart of the present invention.
Embodiment
Below in conjunction with accompanying drawing the present invention is done further explain.
The present invention is divided into two types with 4 * 4 residual blocks: the first kind is complete zero piece class, and second type is non-full zero piece class.
Encoding characteristics by H.264 can know that the reference block that obtains through estimation is and the most similar piece of present encoding piece, so the characteristic of reference block (REF_AZB) can roughly reflect the characteristic of present encoding piece.Statistics finds, when reference block be complete zero piece (REF_AZB=1), the present encoding piece is 84.99% for the average probability of complete zero piece; When reference block is the non-full zero piece (REF_AZB=0), the present encoding piece is 31.31% for the average probability of complete zero piece.The characteristic that this shows reference block not simultaneously, the complete zero piece characteristic difference of present encoding piece is very big.Therefore the present invention is divided into two kinds of situation with 4 * 4 residual block data, when situation 1 is REF_AZB=1, when situation 2 is REF_AZB=0.
Feature Selection: the characteristic based on video sequence can know, when motion vector hour, the present encoding piece belongs to slowly zone of background or motion usually, and the residual block that obtain this moment probability for complete zero piece behind change quantization is bigger; When motion vector was big, the present encoding piece belonged to the complicated or violent zone of motion of background usually, and the residual block that obtain this moment is less for the probability of complete zero piece behind change quantization.Therefore motion vector can directly react the characteristic of present encoding piece.The present invention chooses a characteristic of the complete zero piece detection of cost (MV_COST) conduct of putting in order motion vector in the pixel motion estimation.
Because quantization parameter (QP) reflected quantization step, with residual block behind change quantization, whether be that complete zero piece has confidential relation: QP value more greatly then quantization step is big more, and residual block be that the probability of entirely zero piece is big more behind change quantization; The more little then quantization step of QP value is more little, and residual block is that the probability of complete zero piece is more little behind change quantization.Therefore the threshold value of linear classifier is relevant with the QP value, and the present invention chooses the characteristic that QP detects as complete zero piece.
Absolute error and the absolute value sum that (SAD) refers to each coefficient in 4 * 4 residual blocks.Obviously absolute error and with residual block behind change quantization, whether be that complete zero piece has very big relation, so the present invention chooses the characteristic that SAD detects as complete zero piece.
Block type (MODE) has reflected current macro is carried out estimation with what kind of division, and the motion vector that different divisions obtains is different with residual block, so the present invention selects the characteristic of block type as complete zero piece detection.
Detection method of the present invention is following:
The characteristic of the residual block of the dissimilar video sequence that 1) will store [MV_COST, MODE, SAD, QP, REF_AZB] is as training data;
2) training data that according to the value of the characteristic REF_AZB of reference block step 1) is obtained is divided into two kinds of situation: situation 1: when the characteristic REF_AZB=1 of reference block is a reference block when being complete zero piece, and situation 2: when the characteristic REF_AZB=0 of reference block is that reference block is when being the non-full zero piece;
3) to step 2) two kinds of situation under training data carry out training and operation respectively to obtain two graders be the linear classifier of linear classifier and the reference block of reference block when being complete zero piece when being the non-full zero piece:
3.1) utilize linear decision rule that all training datas are trained, obtain weight coefficient vector [a 1, a 2, a 3];
3.2) weight coefficient vector that will train brings formula (1) into, and the training data under the same quantization parameter QP is utilized 3.1) and in linear decision rule train the threshold value Threshold (QP) under the current quantization parameter QP;
Figure BDA0000056911870000061
In the formula, x 1Be the cost (MV_COST) of motion vector, x 2Be block type (MODE), x 3Be absolute error with (SAD);
3.3) utilize the principle of least square to fit to the multinomial about quantization parameter QP to the threshold value Threshold (QP) under each quantization parameter QP, obtain the linear classifier of formula (2) form;
Figure BDA0000056911870000062
B wherein i(i ≠ 0) is weight coefficient, b 0Be constant, n represent in the multinomial which;
4) reference block as if the present encoding piece is complete zero piece execution in step 5 in the cataloged procedure); If reference block is the non-full zero piece, jump to step 6);
5) using reference block is the linear classifier of complete zero piece, if the present encoding piece is complete zero piece, jumps to step 7), otherwise jumps to step 8);
6) use the linear classifier of reference block,, jump to step 7), otherwise jump to step 8) if the present encoding piece is complete zero piece as the non-full zero piece;
7) skip the change quantization operation,, jump to step 9) the corresponding variable assignments of complete zero piece;
8) change quantization obtains coefficient block, jumps to step 9);
9) inverse quantization, inverse transformation, preservation information gets into next block encoding.

Claims (1)

  1. One kind H.264 in the method that detects of complete zero piece, it is characterized in that:
    The characteristic of the residual block of the dissimilar video sequence that 1) will store is as training data, and wherein characteristic comprises: the cost MV_COST of motion vector, block type MODE, absolute error and SAD, quantization parameter QP, the characteristic REF_AZB of reference block;
    2) training data that according to the value of the characteristic REF_AZB of reference block step 1) is obtained is divided into two kinds of situation: situation 1: when the characteristic REF_AZB=1 of reference block is a reference block when being complete zero piece, and situation 2: when the characteristic REF_AZB=0 of reference block is that reference block is when being the non-full zero piece;
    3) to step 2) two kinds of situation under the linear classifier of training data linear classifier and second type of reference block when carrying out training and operation respectively to obtain two graders be first kind reference block when being the non-full zero piece to complete zero piece:
    3.1) utilize linear decision rule that all training datas are trained, obtain weight coefficient vector a 1, a 2, a 3
    3.2) weight coefficient vector that will train brings formula (1) into, and the training data under the same quantization parameter QP is utilized 3.1) and in linear decision rule train the threshold value Threshold (QP) under the current quantization parameter QP;
    Figure FDA0000158380590000011
    In the formula, x 1Be the cost (MV_COST) of motion vector, x 2Be block type (MODE), x 3Be absolute error with (SAD);
    3.3) utilize the principle of least square to fit to the multinomial about quantization parameter QP to the threshold value Threshold (QP) under each quantization parameter QP, obtain the linear classifier of formula (2) form;
    Figure FDA0000158380590000021
    B wherein iBe weight coefficient, i ≠ 0, b 0Be constant, n represent in the multinomial which;
    4) reference block as if the present encoding piece is complete zero piece execution in step 5 in the cataloged procedure); If reference block is the non-full zero piece, jump to step 6);
    5) using reference block is the linear classifier of complete zero piece, if the present encoding piece is complete zero piece, jumps to step 7), otherwise jumps to step 8);
    6) use the linear classifier of reference block,, jump to step 7), otherwise jump to step 8) if the present encoding piece is complete zero piece as the non-full zero piece;
    7) skip the change quantization operation,, jump to step 9) the corresponding variable assignments of complete zero piece;
    8) change quantization obtains coefficient block, jumps to step 9);
    9) inverse quantization, inverse transformation, preservation information gets into next block encoding.
CN 201110102642 2011-04-22 2011-04-22 Method for detecting all-zero blocks in H.264 Expired - Fee Related CN102148989B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 201110102642 CN102148989B (en) 2011-04-22 2011-04-22 Method for detecting all-zero blocks in H.264

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201110102642 CN102148989B (en) 2011-04-22 2011-04-22 Method for detecting all-zero blocks in H.264

Publications (2)

Publication Number Publication Date
CN102148989A CN102148989A (en) 2011-08-10
CN102148989B true CN102148989B (en) 2012-07-25

Family

ID=44422949

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 201110102642 Expired - Fee Related CN102148989B (en) 2011-04-22 2011-04-22 Method for detecting all-zero blocks in H.264

Country Status (1)

Country Link
CN (1) CN102148989B (en)

Families Citing this family (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2626013C1 (en) * 2011-10-19 2017-07-21 Кт Корпорейшен Video signal decoding method
JP2013150215A (en) * 2012-01-20 2013-08-01 Fujitsu Ltd Moving image decoding device, moving image encoding device, moving image decoding method, moving image encoding method, moving image decoding program, and moving image encoding program
WO2013181821A1 (en) * 2012-06-07 2013-12-12 Mediatek Singapore Pte. Ltd. Improved intra transform skip mode
WO2014190468A1 (en) 2013-05-27 2014-12-04 Microsoft Corporation Video encoder for images
CN105359531B (en) 2014-03-17 2019-08-06 微软技术许可有限责任公司 Method and system for determining for the coder side of screen content coding
CN106416254B (en) 2015-02-06 2019-08-02 微软技术许可有限责任公司 Evaluation stage is skipped during media coding
US10038917B2 (en) 2015-06-12 2018-07-31 Microsoft Technology Licensing, Llc Search strategies for intra-picture prediction modes
US10136132B2 (en) 2015-07-21 2018-11-20 Microsoft Technology Licensing, Llc Adaptive skip or zero block detection combined with transform size decision
CN108124163B (en) * 2017-12-14 2020-07-14 西北工业大学 All-zero block detection method suitable for HEVC (high efficiency video coding)
CN112261409A (en) * 2019-07-22 2021-01-22 中兴通讯股份有限公司 Residual encoding method, residual decoding method, residual encoding device, residual decoding device, storage medium and electronic device
CN111757111B (en) * 2020-06-29 2023-02-24 北京百度网讯科技有限公司 Video coding method, device, equipment and storage medium
CN113365062B (en) * 2021-05-26 2022-11-18 杭州电子科技大学 H.266/VVC-based step-by-step all-zero block decision fast algorithm

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101193304A (en) * 2007-09-14 2008-06-04 四川虹微技术有限公司 An implementation method for quick conversion and quantification of video coding

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101193304A (en) * 2007-09-14 2008-06-04 四川虹微技术有限公司 An implementation method for quick conversion and quantification of video coding

Non-Patent Citations (5)

* Cited by examiner, † Cited by third party
Title
Maojun Zhang et al..Adaptive Method for Early Detecting Zero Quantized DCT Coefficients in H.264/AVC Video Encoding.《IEEE Transactions on Circuits and Systems for Video Technology》.2009,第19卷(第1期),全文. *
Yongjun Chang et al..Fast All-Zero Block Detection Based on Classification Approach.《Digital Image Computing Techniques and Applications DICTA 2007》.2007,全文. *
封颖等.一种高效的H.264帧内编码全零块判决算法.《系统工程与电子技术》.2007,第29卷(第7期),全文. *
王嵩等.基于H.264/AVC整数变换的全零块检测方法.《计算机工程与应用》.2004,(第19期),全文. *
王英坤等.基于视觉特性的面向H.264的自适应全零块预先判别.《上海交通大学学报》.2006,第40卷(第9期),全文. *

Also Published As

Publication number Publication date
CN102148989A (en) 2011-08-10

Similar Documents

Publication Publication Date Title
CN102148989B (en) Method for detecting all-zero blocks in H.264
US9781443B2 (en) Motion vector encoding/decoding method and device and image encoding/decoding method and device using same
CN100551075C (en) A kind of method for choosing frame inner forecast mode of low complex degree
CN102137263B (en) Distributed video coding and decoding methods based on classification of key frames of correlation noise model (CNM)
RU2659733C2 (en) Method and device for coding and decoding the motion vector based on the reduced predictors-candidates of the motion vector
US10091526B2 (en) Method and apparatus for motion vector encoding/decoding using spatial division, and method and apparatus for image encoding/decoding using same
CN104769947B (en) A kind of more hypothesis motion compensation encoding methods based on P frame
CN102598670B (en) With reference to multiple frame, image is carried out to the method and apparatus of coding/decoding
CN101895751B (en) Method and device for intra-frame prediction and intra-frame prediction-based encoding/decoding method and system
CN102823250B (en) Picture coding device, picture decoding apparatus, method for encoding images and picture decoding method
CN102932642B (en) Interframe coding quick mode selection method
CN103384325A (en) Quick inter-frame prediction mode selection method for AVS-M video coding
CN103327327B (en) For the inter prediction encoding unit selection method of high-performance video coding HEVC
CN103248895A (en) Quick mode estimation method used for HEVC intra-frame coding
CN107079165A (en) Use the method for video coding and device of prediction residual
CN107318016A (en) A kind of HEVC inter-frame forecast mode method for rapidly judging based on zero piece of distribution
CN102291582A (en) Distributed video encoding method based on motion compensation refinement
CN103384327A (en) AVS fast mode selection algorithm based on adaptive threshold
CN104702959B (en) A kind of intra-frame prediction method and system of Video coding
CN101778281A (en) Method for estimating H.264-based fast motion on basis of structural similarity
CN102843555A (en) Intra-frame prediction method and system
CN103096064A (en) Methods for coding and reconstructing a pixel block and corresponding devices
CN103430543A (en) Method for reconstructing and coding image block
CN101783956A (en) Back-prediction forecast method based on spatio-temporal neighbor information
CN102685499B (en) All-zero-block detection method based on energy conservation law

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20120725

Termination date: 20150422

EXPY Termination of patent right or utility model