[go: up one dir, main page]

JP2004165894A - Bit rate control method for encoder - Google Patents

Bit rate control method for encoder Download PDF

Info

Publication number
JP2004165894A
JP2004165894A JP2002328194A JP2002328194A JP2004165894A JP 2004165894 A JP2004165894 A JP 2004165894A JP 2002328194 A JP2002328194 A JP 2002328194A JP 2002328194 A JP2002328194 A JP 2002328194A JP 2004165894 A JP2004165894 A JP 2004165894A
Authority
JP
Japan
Prior art keywords
qsize
quantization parameter
bit rate
encoder
virtual buffer
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.)
Pending
Application number
JP2002328194A
Other languages
Japanese (ja)
Inventor
Koichi Takagi
幸一 高木
Yasuhiro Takishima
康弘 滝嶋
Yasuyuki Nakajima
康之 中島
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.)
KDDI Corp
Original Assignee
KDDI Corp
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 KDDI Corp filed Critical KDDI Corp
Priority to JP2002328194A priority Critical patent/JP2004165894A/en
Publication of JP2004165894A publication Critical patent/JP2004165894A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

【課題】処理時間を短縮できる符号化器のビットレート制御方法を提供することにある。
【解決手段】量子化パラメータ決定部14は、画面複雑度演算部12で求められた画面複雑度を用いて仮想バッファ占有量dを求め、該仮想バッファ占有量dを含む下記の(1)式から量子化パラメータQPを求める。
QP=QSIZE×d/r ・・・(1)
ここに、QSIZEは全QPの取りうる値の総数、r=bitrate/picrateであり、QSIZEとrは定数である。
次いで、該量子化パラメータQPを用いて、RDoptimization法を基に、最適な動きベクトルとモードを選択する。
【選択図】 図1
The present invention provides a method for controlling a bit rate of an encoder that can reduce processing time.
A quantization parameter determination unit calculates a virtual buffer occupancy d using a screen complexity calculated by a screen complexity calculation unit, and includes the following equation (1) including the virtual buffer occupancy d. To obtain a quantization parameter QP.
QP = QSIZE × d / r (1)
Here, QSIZE is the total number of possible values of all QPs, r = bitrate / picrate, and QSIZE and r are constants.
Next, using the quantization parameter QP, an optimal motion vector and mode are selected based on the RDOptimization method.
[Selection diagram] Fig. 1

Description

【0001】
【発明の属する技術分野】
本発明は符号化器のビットレート制御方法に関し、特にJVT(Joint VideoTeam)の符号化器に適用して好適なビットレート制御方法に関する。
【0002】
【従来の技術】
従来のビットレート制御技術では、MPEG−2の検証モデルTM5[2]におけるビットレート制御方式を利用して、次のような方式が採用されている。
【0003】
1.ピクチャレベルで目標符号量の割当を行う(TM5レート制御のステップ1に相当)。
【0004】
2.各マクロブロック(MB)に対して、以下の処理を行う。
【0005】
(2−1)量子化パラメータ(QP)値を直前に符号化されたMBのQP値とし、既知のRDoptimization法を利用して、最適なモード、および動きベクトル(MV)を求める。
【0006】
(2−2)アクティビテイ値を考慮し、仮想バッファ占有量を計算し、そこから当該MBに使用するQPを計算する(TM5レート制御のステップ2に相当)。
【0007】
(2−3)求められたQPを使って、前記(2−1)をもとに、最適なMV,モードを選択する。(ただし、(2−2)で求められたQP値が(2−1)のQP値と同じであれば、この処理は行われない。)
【0008】
ここで、前記RDoptimization(以下、RDO)法の概略を説明する。前記(2−1)におけるRDOモードにおける動き推定およびモード選択は、以下の手順で行われる。
【0009】
(1)与えられた量子化パラメータQPに対し、ラグランジェ(Lagrange)定数を以下のように与える。
λMODE=0.85×2QP/3 ,λMOTION=√λMODE
【0010】
(2)複数の4×4イントラ予測モードの中で、下記のコスト(cost)関数を最小にするモードを選択する。
J(s,c,IMODE\QP,λMODE)=SSD(s,c,IMODE\QP)+λMODE(s,c,IMODE\QP)
ここで、sは原画像、cは予測画像、IMODEは4×4イントラ予測モードの集合である。
【0011】
(3)原画像sと予測画像cの差分に2次元アダマール(Hadamard)変換を施したものの絶対値和の1/2(これを、SATDと呼ぶ)が最小になる16×16イントラ予測モードを選択する。
【0012】
(4)8×8画素サイズのブロックを複数ブロックに分割した各モードに対し、動き推定、参照フレームの推定を行い、コスト関数、すなわちSSD+λR(MV,REF)の値を最小にするものをそれぞれ選択する。
【0013】
(5)16×16,8×16,16×8画素サイズのMBを複数のブロックに分割した各モードに対し、動き推定、参照フレームの推定を行い、下記のコスト関数を最小にするものを、それぞれ選択する。
J(REF,m(REF)\λMOTION
=SATD(s,c(REF,m(REF)))+λMOTION・(R(m(REF)−p(REF))+R(REF))
ただし、m(REF)、p(REF)は、それぞれ参照画像REFに対する動ベクトルおよびその予測値、R( )は、UniversalVLC(UVLC)を使って計算されたビット量である。
【0014】
(6)Bフレームに関しては、予測方向も考慮に入れて、コスト関数が最小になる予測方向を選択する。
J(PDIR\λMOTION
=SATD(s,c(PDIR,m(PDIR)))+λMOTION・(R(m(PDIR)−p(PDIR))+R(PDIR))
ここに、PDIRは予測方向を示す。
【0015】
(7)以上、前記(2)〜(5)の各モードで選ばれたそれぞれのパラメータに対して、次のコスト関数を最小にするモードMODEを選択する。
J(s,c,MODE\QP,λMODE)=SSD(s,c,MODE\QP)+λMODE(s,c,MODE\QP)
【0016】
なお、PフレームではSKIPモード、BフレームではDIRECTモードも考慮に入れる。
【0017】
【発明が解決しようとする課題】
しかしながら、前記した従来技術では、最適MV探索およびモード判定を、各MBで最悪2度ずつ行わなければならない。すなわち、前記(2−1)と(2−3)の処理を行わなければならない。これらの処理は、符号化に要する時間の大きな部分を占めるため、符号化の処理時間が長くなるという課題があった。
【0018】
本発明は、前記課題に鑑みてなされたものであり、処理時間を低減できる符号化器のビットレート制御方法を提供することにある。
【0019】
【課題を解決するための手段】
前記した目的を達成するために、本発明は、JVT(Joint Video Team)の符号化器のビットレート制御方法が、各ピクチャタイプごとの画面複雑度を基に、各画面の目標符号量の割当てを行うステップと、前記画面の各マクロブロックにおける仮想バッファ占有量dを求めるステップと、前記仮想バッファ占有量dを含む下記の(1)または(2)式から量子化パラメータQPを求めるステップと、該量子化パラメータQPを用いて、RDoptimization法を基に、最適な動きベクトルとモードを選択するステップとからなるようにした点に第1の特徴がある。
QP=QSIZE×d/r ・・・(1)
ここに、QSIZEは全QPの取りうる値の総数、r=bitrate/picrateであり、QSIZEとrは定数である。
QP=alog(QSIZE×d/r)+b…(2)
ここに、a、bは定数である。
【0020】
また、本発明は、前記量子化パラメータQPは、0≦QP≦51であり、範囲外のものは、0または51にクリップすることとし、前記QSIZE=52とした点に第2の特徴がある。
【0021】
該第1、第2の特徴によれば、RDoptimization法を一度しか行わなくても、レート−歪み特性が改善できるとともに、符号化の処理時間を大幅に短縮できる。
【0022】
また、本発明は、前記仮想バッファ占有量の初期値dを、ピクチャタイプ(i,p,b)毎に、di0=30×r/QSIZE、dp0=K×di0、db0=K×di0とし、またr=2×bitrate/picrateとした点に第3の特徴がある。
【0023】
この特徴によれば、初期状態のフレーム毎の符号量の変動、およびPSNRの変動を安定化させることが可能になる。
【0024】
【発明の実施の形態】
以下に、図面を参照して、本発明を詳細に説明する。図1は、本発明を適用して好適なJVT(Joint Video Team)の符号化器の概略の構成を示すブロック図である。
【0025】
図において、動画像信号の第1画面の入力画像信号1が入力される時には、イントラ予測部15からの制御信号によりスイッチ2は端子a側に接続されており、入力画像信号は高い符号化効率を得るために直交変換器および量子化器3に入力する。該直交変換器および量子化器3では、該入力画像信号はDCT(離散コサイン変換)などを用いて直交変換され、その直交変換係数が量子化される。この量子化係数は、エントロピ符号化部4でエントロピ符号化される。
【0026】
一方、逆量子化器および逆直交変換器5に入力した量子化係数は、逆量子化および逆直交変換されて画像データが復元される。復元された画像データは、ループフィルタ6を経てフレームバッファ7に蓄積される。
【0027】
次の画面の入力画像信号1が入力されるようになると、前記スイッチ2はイントラ予測部15からの制御信号により端子bに接続され、また該入力画像信号1は、予測信号減算器10および動き推定部8に入力される。動き推定部8では、該入力画像信号1を参照して、フレームバッファ7から読み出された画像データの動きを推定し、動きベクトルMVを検出する。動き補償部9は、該動きベクトルMVを基に動き補償された動き補償予測信号を生成し、予測信号減算器10と局所復号加算器11に送出する。
【0028】
予測信号減算器10では、入力画像信号1から動き補償予測信号を減算し、前記直交変換器および量子化器3に出力する。直交変換器および量子化器3は、高い符号化効率を得るために、予測信号減算器10からの信号を直交変換し、量子化する。一方、局所復号加算器11は、逆量子化器および逆直交変換器5で復元された画像データに前記動き補償予測信号を加算し、ループフィルタ6に出力する。
【0029】
量子化パラメータ決定部14は、画面複雑度演算部12から得られた画面複雑度および仮想バッファ占有量演算部13から得られた仮想バッファ占有量を用いて量子化パラメータ(QP)を決定する。該量子化パラメータQPは、イントラ予測部15と前記動き推定部8に送られる。イントラ予測部15は、該量子化パラメータQPに従ってイントラモードにするか否かの予測を行い、前記スイッチ2を切り替える制御信号を発生する。
【0030】
次に、本発明の一実施形態のビットレート制御方式を説明する。該ビットレート制御は主に前記量子化パラメータ決定部14で行われる。
【0031】
1.まず、従来技術と同様に、ピクチャレベル(1画面毎)で目標符号量の割当が行われる(TM5レート制御のステップ1に相当)。図2は、符号化されるピクチャの概念図を示す。
【0032】
以下に、該ピクチャレベルでの目標符号量の割当について説明する。まず、画面複雑度Xtypeを定義し、符号化されたピクチャタイプにより更新する。ここで、添え字「type」は、I,P,Bの各ピクチャタイプを示し、以下でも同様とする。
【0033】
更新式は、Xtype=StypeQPtypeとする。ここに、Stypeは当該ピクチャの符号量、QPtypeは実際に求められた量子化パラメータQPの平均である。なお、画面複雑度Xtypeの初期値は、それぞれX=155×bitrate/115、X=15×bitrate/115、X=5×bitrate/115とする。該「bitrate」は、符号化器から出力されるビットストリーム速度であり、既知である。
【0034】
上記の画面複雑度Xtypeを用いて、各ピクチャの目標符号量Ttypeすなわち、T、T、およびTをTM5と同様に、以下の通り求める。

Figure 2004165894
【0035】
ここで、Ktypeは各ピクチャタイプ間の複雑度の違いを表す比例成分であり、K=1.1,K=1.5とするのが好適である。また、Ntypeは当該GOP(group of pictures)で符号化されていないフレームの数、Rは当該GOPにおいて符号化されていないフレームに割当て可能なビット量を示す。
【0036】
なお、GOPの最初のピクチャを符号化する前に、前記Rは下記の通りとする。
R=(bitrate/picrate)×N+Rprev
ただし、picrateはピクチャレート(枚/sec)、NはGOPに含まれるフレームの数、Rprevは直前のGOPにおけるRとする。また、符号化後のRは、R=R−Stypeとする。
以上により、ピクチャレベルの目標符号量Ttypeが求められる。
【0037】
2.次に、各マクロブロックMBに対して、以下の処理を行う。
【0038】
(2−1)前記仮想バッファ占有量演算部13が仮想バッファ占有量を計算する。第m番目のマクロブロックMBmにおける仮想バッファ占有量dを、次のように定義する。
=d+Bm−1−Ttype×(m−1)/MBcnt
ここで、Bm−1は、当該m−1番目のMBまでの消費符号量、MBcntは、全MB数である。また、dは、直前に符号化された同一ピクチャタイプをもつフレームの最後に求められた仮想バッファ占有量を使用する。なお、dの初期値は、ピクチャタイプ毎に、di0=30×r/QSIZE、dp0=K×di0、db0=K×di0、またr=2×bitrate/picrateとする。ここで、QSIZEは、全QPの取りうる値の総数を示している。該総数は、52とするのが好適である。
【0039】
以上を基に、量子化パラメータQPを、下記の(1)式の通り定める。
QP=QSIZE×d/r …(1)
ただし、0≦QP≦51とし、範囲外のものは、0,51にそれぞれクリップする。
なお、前記(1)式に代えて、下記の(2)式を用いてもよい。
QP=alog(QSIZE×d/r)+b…(2)
ここに、a,bは定数である。
【0040】
(2−2)以上のようにして求められたQPを用いて、前記RDoptimization法を利用して、最適な動きベクトルMVおよびモードを選択する。
【0041】
以上の説明から明らかなように、本実施形態では、前記RDoptimization法は一度しか行われず、その他の処理は従来方式と等価であるため、従来法式に比べて、符号化の処理時間を大幅に短縮することができる。
【0042】
また、テスト画像を使った本実施形態に係るシミュレーション実験を行い、以下のようにして、レート−歪み特性を求めた。
【0043】
実験条件を、図3に示す。テスト画像Foremanを用いた実験では、図4(a)に示されているように、従来方式と本実施形態方式とでは、レート−歪み特性はほぼ同じであったが、Mobile&Calendarを用いた実験では、図4(b)に示されているように、本実施形態方式の方が優れていることが確認できた。また、このことから、Bピクチャが存在している場合でも、存在していない場合でも、全ビットレートで本実施形態方式の方が優れていることが確認できる。特に、Bピクチャが存在している場合には、高レートでの向上が著しいことが確認できる。この効果は、量子化パラメータを前記(1)式で求め、QSIZE=52とした点に、主たる要因があると考えられる。
【0044】
次に、フレーム毎の符号量と、PSNRの推移を図5に示す。実線が本実施形態方式、破線が従来方式を示している。
【0045】
図5により、特に従来法式は初期状態が不安定であるのに対し、本実施形態方式は終始安定し続けていること、また従来方式ではIピクチャで符号量を多く消費しており、同一GOPのPピクチャに悪影響を与えていることが伺える。
前者の効果は、仮想バッファ占有量dの初期値として、ピクチャタイプ毎に、di0=30×r/QSIZE、dp0=K×di0、db0=K×di0、またr=2×bitrate/picrateとした点に、主たる要因があると考えられる。
以上により、本実施形態方式の有効性が確認できた。
【0046】
上記のように、本実施形態方式が有効である原因は、量子化パラメータQPを求めるために、仮想バッファ占有量dを含む前記(1)式を用いたこと、および/またはdの初期値は、ピクチャタイプ毎に、di0=30×r/QSIZE、dp0=K×di0、db0=K×di0、またr=2×bitrate/picrateとし、QSIZE=52とした点であると考えられる。
【0047】
【発明の効果】
以上の説明から明らかなように、請求項1の発明によれば、RDoptimization法を一度しか行わないにもかかわらず、従来方式と同等またはそれ以上の効果を上げることができるようになる。また、このため、符号化に要する処理時間を大幅に短縮することができる。
【0048】
また、請求項2の発明によれば、量子化パラメータQPを、0≦QP≦51、その総数QSIZEを、QSIZE=52としたので、レート−歪み特性を従来法式に比べて向上させることができる。
【0049】
さらに、請求項3の発明によれば、仮想バッファ占有量の初期値dを、ピクチャタイプ(i,p,b)毎に、di0=30×r/QSIZE、dp0=K×di0、db0=K×di0、またr=2×bitrate/picrateとしたので、初期状態のフレーム毎の符号量の変動、およびPSNRの変動を安定化させることが可能になる。
【図面の簡単な説明】
【図1】本発明が適用されるJVT(Joint Video Team)の符号化器の概略の構成を示すブロック図である。
【図2】符号化されるピクチャとマクロブロックMBの説明図である。
【図3】実験条件を示す図である。
【図4】テスト画像Foreman、Mobile&Calendarを用いた時のレート−歪み特性を示す図である。
【図5】符号量とPSNRの推移を、従来方式と本発明方式とで表した図である。
【符号の説明】
12・・・面複雑度演算部、13・・・仮想バッファ占有量演算部、14・・・量子化パラメータ決定部。[0001]
TECHNICAL FIELD OF THE INVENTION
The present invention relates to a bit rate control method for an encoder, and more particularly, to a bit rate control method suitable for being applied to a JVT (Joint Video Team) encoder.
[0002]
[Prior art]
In the conventional bit rate control technology, the following method is adopted by using the bit rate control method in the MPEG-2 verification model TM5 [2].
[0003]
1. The target code amount is assigned at the picture level (corresponding to step 1 of TM5 rate control).
[0004]
2. The following processing is performed on each macroblock (MB).
[0005]
(2-1) Using the quantization parameter (QP) value as the QP value of the MB coded immediately before, and using a known RDoptimization method, an optimum mode and a motion vector (MV) are obtained.
[0006]
(2-2) The virtual buffer occupancy is calculated in consideration of the activity value, and the QP used for the MB is calculated therefrom (corresponding to step 2 of the TM5 rate control).
[0007]
(2-3) Using the obtained QP, select an optimal MV and mode based on the above (2-1). (However, if the QP value obtained in (2-2) is the same as the QP value in (2-1), this processing is not performed.)
[0008]
Here, an outline of the RDOptimization (hereinafter, RDO) method will be described. The motion estimation and mode selection in the RDO mode in (2-1) are performed in the following procedure.
[0009]
(1) For a given quantization parameter QP, a Lagrange constant is given as follows.
λ MODE = 0.85 × 2 QP / 3 , λ MOTION = √λ MODE
[0010]
(2) A mode that minimizes the following cost function is selected from a plurality of 4 × 4 intra prediction modes.
J (s, c, IMODE\QP, λ MODE) = SSD (s, c, IMODE\QP) + λ MODE (s, c, IMODE\QP)
Here, s is an original image, c is a predicted image, and IMODE is a set of 4 × 4 intra prediction modes.
[0011]
(3) A 16 × 16 intra-prediction mode in which the difference between the original image s and the predicted image c is subjected to a two-dimensional Hadamard transformation and the half of the sum of absolute values (this is called SATD) is minimized select.
[0012]
(4) For each mode obtained by dividing a block of 8 × 8 pixels into a plurality of blocks, motion estimation and reference frame estimation are performed, and the cost function, that is, the one that minimizes the value of SSD + λR (MV, REF) is determined. select.
[0013]
(5) For each mode obtained by dividing a 16 × 16, 8 × 16, 16 × 8 pixel size MB into a plurality of blocks, motion estimation and reference frame estimation are performed to minimize the following cost function. , Select each.
J (REF, m (REF) \λ MOTION )
= SATD (s, c (REF, m (REF))) + λ MOTION · (R (m (REF) −p (REF)) + R (REF))
Here, m (REF) and p (REF) are a motion vector and a predicted value thereof for the reference image REF, respectively, and R () is a bit amount calculated using Universal VLC (UVLC).
[0014]
(6) For the B frame, taking into account the prediction direction, select the prediction direction that minimizes the cost function.
J (PDIR @ λ MOTION )
= SATD (s, c (PDIR, m (PDIR))) + λ MOTION · (R (m (PDIR) −p (PDIR)) + R (PDIR))
Here, PDIR indicates the prediction direction.
[0015]
(7) As described above, for each parameter selected in each of the modes (2) to (5), the mode MODE that minimizes the following cost function is selected.
J (s, c, MODE @ QP, λ MODE ) = SSD (s, c, MODE @ QP) + λ MODE (s, c, MODE @ QP)
[0016]
It should be noted that the SKIP mode is also taken into account for the P frame, and the DIRECT mode is taken into account for the B frame.
[0017]
[Problems to be solved by the invention]
However, in the above-described conventional technique, the optimum MV search and the mode determination must be performed twice at worst for each MB. That is, the processes (2-1) and (2-3) must be performed. Since these processes occupy a large part of the time required for encoding, there has been a problem that the encoding processing time becomes long.
[0018]
SUMMARY OF THE INVENTION The present invention has been made in view of the above problems, and an object of the present invention is to provide a bit rate control method for an encoder that can reduce processing time.
[0019]
[Means for Solving the Problems]
In order to achieve the above object, the present invention provides a method for controlling a bit rate of a JVT (Joint Video Team) encoder by allocating a target code amount for each screen based on the screen complexity for each picture type. , A step of obtaining a virtual buffer occupancy d in each macroblock of the screen, and a step of obtaining a quantization parameter QP from the following equation (1) or (2) including the virtual buffer occupancy d: The first feature is that the method includes a step of selecting an optimal motion vector and a mode based on the RDoptimization method using the quantization parameter QP.
QP = QSIZE × d / r (1)
Here, QSIZE is the total number of possible values of all QPs, r = bitrate / picrate, and QSIZE and r are constants.
QP = alog (QSIZE × d / r) + b (2)
Here, a and b are constants.
[0020]
Further, the present invention has a second feature in that the quantization parameter QP satisfies 0 ≦ QP ≦ 51, and values outside the range are clipped to 0 or 51, and QSIZE = 52. .
[0021]
According to the first and second features, even if the RDOptimization method is performed only once, the rate-distortion characteristics can be improved and the encoding processing time can be significantly reduced.
[0022]
Further, the present invention is that the initial value d 0 of the virtual buffer occupancy, picture type (i, p, b) for each, d i0 = 30 × r / QSIZE, d p0 = K p × d i0, d b0 = a K b × d i0, also has a third feature in that the r = 2 × bitrate / picrate.
[0023]
According to this feature, it is possible to stabilize the variation of the code amount for each frame in the initial state and the variation of the PSNR.
[0024]
BEST MODE FOR CARRYING OUT THE INVENTION
Hereinafter, the present invention will be described in detail with reference to the drawings. FIG. 1 is a block diagram showing a schematic configuration of a JVT (Joint Video Team) encoder suitable for applying the present invention.
[0025]
In the figure, when the input image signal 1 of the first screen of the moving image signal is input, the switch 2 is connected to the terminal a by the control signal from the intra prediction unit 15, and the input image signal has a high coding efficiency. Is input to the orthogonal transformer and quantizer 3 to obtain. In the orthogonal transformer and quantizer 3, the input image signal is orthogonally transformed using DCT (discrete cosine transform) or the like, and the orthogonal transform coefficient is quantized. The quantized coefficients are entropy-coded by the entropy coding unit 4.
[0026]
On the other hand, the quantized coefficients input to the inverse quantizer and inverse orthogonal transformer 5 are subjected to inverse quantization and inverse orthogonal transform, and image data is restored. The restored image data is stored in the frame buffer 7 via the loop filter 6.
[0027]
When the input image signal 1 of the next screen is input, the switch 2 is connected to the terminal b by a control signal from the intra prediction unit 15, and the input image signal 1 It is input to the estimating unit 8. The motion estimating unit 8 estimates the motion of the image data read from the frame buffer 7 with reference to the input image signal 1 and detects the motion vector MV. The motion compensator 9 generates a motion-compensated prediction signal that is motion-compensated based on the motion vector MV, and sends it to the prediction signal subtractor 10 and the local decoding adder 11.
[0028]
The prediction signal subtracter 10 subtracts the motion compensation prediction signal from the input image signal 1 and outputs the result to the orthogonal transformer and the quantizer 3. The orthogonal transformer and the quantizer 3 orthogonally transform and quantize the signal from the prediction signal subtractor 10 in order to obtain high coding efficiency. On the other hand, the local decoding adder 11 adds the motion compensation prediction signal to the image data restored by the inverse quantizer and the inverse orthogonal transformer 5, and outputs the result to the loop filter 6.
[0029]
The quantization parameter determination unit 14 determines a quantization parameter (QP) using the screen complexity obtained from the screen complexity calculation unit 12 and the virtual buffer occupancy obtained from the virtual buffer occupancy calculation unit 13. The quantization parameter QP is sent to the intra prediction unit 15 and the motion estimation unit 8. The intra prediction unit 15 predicts whether or not to switch to the intra mode according to the quantization parameter QP, and generates a control signal for switching the switch 2.
[0030]
Next, a bit rate control method according to an embodiment of the present invention will be described. The bit rate control is mainly performed by the quantization parameter determination unit 14.
[0031]
1. First, a target code amount is allocated at a picture level (for each screen), as in the prior art (corresponding to step 1 of TM5 rate control). FIG. 2 shows a conceptual diagram of a picture to be encoded.
[0032]
The assignment of the target code amount at the picture level will be described below. First, the screen complexity X type is defined, and updated by the coded picture type. Here, the subscript “type” indicates each picture type of I, P, and B, and the same applies to the following.
[0033]
The update formula is set as X type = S type QP type . Here, S type is the code amount of the picture, and QP type is the average of the quantization parameter QP actually obtained. The screenshots initial value of complexity X type, respectively with X i = 155 × bitrate / 115 , X p = 15 × bitrate / 115, X b = 5 × bitrate / 115. The “bitrate” is a bit stream rate output from the encoder, and is known.
[0034]
Using the above-mentioned screen complexity X type , the target code amount T type of each picture, that is, T i , T p , and T b is obtained as follows in the same manner as TM5.
Figure 2004165894
[0035]
Here, K type is a proportional component representing a difference in complexity between each picture type, and it is preferable that K p = 1.1 and K b = 1.5. N type indicates the number of frames that are not encoded in the GOP (group of pictures), and R indicates the amount of bits that can be allocated to frames that are not encoded in the GOP.
[0036]
Note that, before encoding the first picture of the GOP, R is as follows.
R = (bitrate / picrate) × N + R prev
Here, picrate is the picture rate (frames / sec), N is the number of frames included in the GOP, and R prev is R in the immediately preceding GOP. Also, R after encoding is R = R-S type .
As described above, the target code amount T type at the picture level is obtained.
[0037]
2. Next, the following processing is performed on each macro block MB.
[0038]
(2-1) The virtual buffer occupancy calculator 13 calculates the virtual buffer occupancy. The virtual buffer fullness d m in the m-th macroblock MBm, defined as follows.
d m = d 0 + B m -1 -T type × (m-1) / MBcnt
Here, B m-1 is the consumed code amount up to the (m-1) th MB, and MBcnt is the total number of MBs. For d 0 , the virtual buffer occupancy obtained at the end of the immediately preceding frame having the same picture type is used. The initial value of d 0, for each picture type, and d i0 = 30 × r / QSIZE , d p0 = K p × d i0, d b0 = K b × d i0 Further, r = 2 × bitrate / picrate I do. Here, QSIZE indicates the total number of possible values of all QPs. The total number is preferably 52.
[0039]
Based on the above, the quantization parameter QP is determined according to the following equation (1).
QP = QSIZE × d / r (1)
However, 0 ≦ QP ≦ 51, and those outside the range are clipped to 0 and 51, respectively.
Note that the following equation (2) may be used instead of the above equation (1).
QP = alog (QSIZE × d / r) + b (2)
Here, a and b are constants.
[0040]
(2-2) Using the QP obtained as described above, the optimal motion vector MV and mode are selected by using the RDoptimization method.
[0041]
As is clear from the above description, in the present embodiment, the RDOptimization method is performed only once, and the other processing is equivalent to the conventional method. Therefore, the encoding processing time is significantly reduced as compared with the conventional method. can do.
[0042]
Further, a simulation experiment according to the present embodiment using a test image was performed, and a rate-distortion characteristic was obtained as follows.
[0043]
The experimental conditions are shown in FIG. In the experiment using the test image Foreman, as shown in FIG. 4A, the rate-distortion characteristics were almost the same between the conventional method and the present embodiment, but in the experiment using Mobile & Calender, As shown in FIG. 4B, it was confirmed that the method of the present embodiment was superior. From this, it can be confirmed that the system of the present embodiment is superior at all bit rates regardless of whether a B picture exists or does not exist. In particular, when a B picture exists, it can be confirmed that the improvement at a high rate is remarkable. This effect is considered to be mainly due to the fact that the quantization parameter is obtained by the above equation (1) and QSIZE = 52.
[0044]
Next, FIG. 5 shows the transition of the code amount and the PSNR for each frame. The solid line indicates the method of the present embodiment, and the broken line indicates the conventional method.
[0045]
According to FIG. 5, the initial state is particularly unstable in the conventional method, whereas the method of the present embodiment is stable throughout. In the conventional method, a large amount of code is consumed in the I picture, and the same GOP It seems that the P picture has been adversely affected.
The effect of the former is that, as an initial value of the virtual buffer occupation amount d, d i0 = 30 × r / QSIZE, d p0 = K p × d i0 , d b0 = K b × d i0 , and r = It is considered that there is a main factor in the point of 2 × bitrate / picrate.
From the above, the effectiveness of the method of the present embodiment was confirmed.
[0046]
As described above, the reason why the method of the present embodiment is effective is that the expression (1) including the virtual buffer occupancy d is used to obtain the quantization parameter QP, and / or the initial value of d 0 . , for each picture type that, a d i0 = 30 × r / QSIZE , d p0 = K p × d i0, d b0 = K b × d i0, also r = 2 × bitrate / picrate, was QSIZE = 52 It is considered to be.
[0047]
【The invention's effect】
As is apparent from the above description, according to the first aspect of the present invention, it is possible to achieve an effect equal to or higher than that of the conventional method, even though the RDOptimization method is performed only once. Therefore, the processing time required for encoding can be significantly reduced.
[0048]
According to the second aspect of the present invention, since the quantization parameter QP is 0 ≦ QP ≦ 51 and the total number QSIZE is QSIZE = 52, the rate-distortion characteristic can be improved as compared with the conventional method. .
[0049]
Furthermore, according to the invention of claim 3, the initial value d 0 for the virtual buffer occupancy, picture type (i, p, b) for each, d i0 = 30 × r / QSIZE, d p0 = K p × d i0, d b0 = K b × d i0, also since the r = 2 × bitrate / picrate, it is possible to stabilize fluctuations, and variations in PSNR of code amount for each of the initial state frame.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a schematic configuration of a JVT (Joint Video Team) encoder to which the present invention is applied.
FIG. 2 is an explanatory diagram of a picture to be encoded and a macroblock MB.
FIG. 3 is a view showing experimental conditions.
FIG. 4 is a diagram illustrating a rate-distortion characteristic when a test image Foreman, Mobile & Calender is used.
FIG. 5 is a diagram illustrating transitions of a code amount and a PSNR in a conventional method and a method of the present invention.
[Explanation of symbols]
12: surface complexity calculation unit, 13: virtual buffer occupancy calculation unit, 14: quantization parameter determination unit

Claims (3)

JVT(Joint Video Team)の符号化器のビットレート制御方法において、
各ピクチャタイプごとの画面複雑度を基に、各画面の目標符号量の割当てを行うステップと、
前記画面の各マクロブロックにおける仮想バッファ占有量dを求めるステップと、
前記仮想バッファ占有量dを含む下記の(1)または(2)式から量子化パラメータQPを求めるステップと、
該量子化パラメータQPを用いて、RDoptimization法を基に、最適な動きベクトルとモードを選択するステップとからなる符号化器のビットレート制御方法。
QP=QSIZE×d/r ・・・(1)
ここに、QSIZEは全QPの取りうる値の総数、r=bitrate/picrateであり、QSIZEとrは定数である。
QP=alog(QSIZE×d/r)+b…(2)
ここに、a、bは定数である。
In a bit rate control method of an encoder of JVT (Joint Video Team),
Allocating a target code amount for each screen based on the screen complexity for each picture type;
Determining a virtual buffer occupancy d in each macroblock of the screen;
Obtaining a quantization parameter QP from the following equation (1) or (2) including the virtual buffer occupancy d;
Selecting an optimal motion vector and mode based on the RDOptimization method using the quantization parameter QP.
QP = QSIZE × d / r (1)
Here, QSIZE is the total number of possible values of all QPs, r = bitrate / picrate, and QSIZE and r are constants.
QP = alog (QSIZE × d / r) + b (2)
Here, a and b are constants.
請求項1に記載の符号化器のビットレート制御方法において、
前記量子化パラメータQPは、0≦QP≦51であり、範囲外のものは、0または51にクリップすることとし、前記QSIZE=52とすることを特徴とする符号化器のビットレート制御方法。
A method for controlling a bit rate of an encoder according to claim 1,
The bit rate control method for an encoder, wherein the quantization parameter QP satisfies 0 ≦ QP ≦ 51, and values outside the range are clipped to 0 or 51, and the QSIZE = 52.
請求項1または2に記載の符号化器のビットレート制御方法において、
前記仮想バッファ占有量の初期値dを、ピクチャタイプ(i,p,b)毎に、di0=30×r/QSIZE、dp0=K×di0、db0=K×di0、またr=2×bitrate/picrateとしたことを特徴とする符号化器のビットレート制御方法。
A method for controlling a bit rate of an encoder according to claim 1 or 2,
An initial value d 0 of the virtual buffer occupancy, picture type (i, p, b) for each, d i0 = 30 × r / QSIZE, d p0 = K p × d i0, d b0 = K b × d i0 , And r = 2 × bitrate / picrate.
JP2002328194A 2002-11-12 2002-11-12 Bit rate control method for encoder Pending JP2004165894A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002328194A JP2004165894A (en) 2002-11-12 2002-11-12 Bit rate control method for encoder

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002328194A JP2004165894A (en) 2002-11-12 2002-11-12 Bit rate control method for encoder

Publications (1)

Publication Number Publication Date
JP2004165894A true JP2004165894A (en) 2004-06-10

Family

ID=32806562

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002328194A Pending JP2004165894A (en) 2002-11-12 2002-11-12 Bit rate control method for encoder

Country Status (1)

Country Link
JP (1) JP2004165894A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006246474A (en) * 2005-02-28 2006-09-14 Samsung Electronics Co Ltd Method and apparatus for generating predicted video using single encoding mode between color components, and method and apparatus for encoding / decoding video and video using single encoding mode
JP2007104182A (en) * 2005-10-03 2007-04-19 Nec Electronics Corp Image coding device, image coding method, and image editing device
JP2007288627A (en) * 2006-04-19 2007-11-01 Nec Corp Mpeg decoding processing circuit and mpeg filtering display method to be used therefor
WO2008007759A1 (en) 2006-07-14 2008-01-17 Sony Corporation Image processing device, method, and program
JP2010252394A (en) * 2010-07-23 2010-11-04 Renesas Electronics Corp Image coding apparatus, image coding method, and image editing apparatus

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006246474A (en) * 2005-02-28 2006-09-14 Samsung Electronics Co Ltd Method and apparatus for generating predicted video using single encoding mode between color components, and method and apparatus for encoding / decoding video and video using single encoding mode
JP2007104182A (en) * 2005-10-03 2007-04-19 Nec Electronics Corp Image coding device, image coding method, and image editing device
JP2007288627A (en) * 2006-04-19 2007-11-01 Nec Corp Mpeg decoding processing circuit and mpeg filtering display method to be used therefor
WO2008007759A1 (en) 2006-07-14 2008-01-17 Sony Corporation Image processing device, method, and program
JP2008022405A (en) * 2006-07-14 2008-01-31 Sony Corp Image processing apparatus and method, and program
US8432964B2 (en) 2006-07-14 2013-04-30 Sony Corporation Image processing device, method, and program
US9077968B2 (en) 2006-07-14 2015-07-07 Sony Corporation Image processing apparatus and method, and program
JP2010252394A (en) * 2010-07-23 2010-11-04 Renesas Electronics Corp Image coding apparatus, image coding method, and image editing apparatus

Similar Documents

Publication Publication Date Title
KR101984764B1 (en) Video Coding and Decoding Method and Apparatus
CN1723706B (en) Apparatus and method for hybrid inter/intra coding of macroblock partitions
KR101089325B1 (en) Encoding method, decoding method, and encoding apparatus for a digital picture sequence
KR101362590B1 (en) Image processing device and method
CN101902647B (en) A video decoder for decoding video signal data of a picture with image blocks
US20050069211A1 (en) Prediction method, apparatus, and medium for video encoder
JP4247680B2 (en) Encoding apparatus, encoding method, encoding method program, and recording medium recording the encoding method program
JP4256574B2 (en) Image signal encoding method and image signal encoding apparatus
KR100950743B1 (en) Image information encoding apparatus and method, and image information decoding apparatus and method
KR20100027384A (en) Method and apparatus for determining a prediction mode
KR20090099234A (en) Image encoding and decoding method and apparatus
CN1949877B (en) Adaptive quantization controller and method thereof
JP2000197049A (en) Dynamic image variable bit rate encoding device and method therefor
JP2006157881A (en) Variable length coding apparatus and method
JP3508916B2 (en) Moving image variable bit rate encoding method and apparatus
JP4362795B2 (en) Video encoding apparatus and method
JP5007761B2 (en) Image processing apparatus and method, program, and recording medium
JP4277530B2 (en) Image processing apparatus and encoding apparatus and methods thereof
JP2004165894A (en) Bit rate control method for encoder
JP5136470B2 (en) Moving picture coding apparatus and moving picture coding method
JP4407249B2 (en) Data processing apparatus, method and encoding apparatus, method and program
KR100708182B1 (en) Apparatus and method for controlling bit rate of video encoder
KR100336497B1 (en) Rate Control Apparatus and Method Using Spatial Prediction Error Model for Moving Picture Coding
JPH0775095A (en) Rate control circuit
JP3013602B2 (en) Video signal encoding device