JP2821177B2 - Image coding method and apparatus - Google Patents

Image coding method and apparatus

Info

Publication number
JP2821177B2
JP2821177B2 JP10660889A JP10660889A JP2821177B2 JP 2821177 B2 JP2821177 B2 JP 2821177B2 JP 10660889 A JP10660889 A JP 10660889A JP 10660889 A JP10660889 A JP 10660889A JP 2821177 B2 JP2821177 B2 JP 2821177B2
Authority
JP
Japan
Prior art keywords
index
symbol
encoding
signal
indexes
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 - Lifetime
Application number
JP10660889A
Other languages
Japanese (ja)
Other versions
JPH02285776A (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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP10660889A priority Critical patent/JP2821177B2/en
Priority to EP90304485A priority patent/EP0395394B1/en
Priority to DE69020424T priority patent/DE69020424T2/en
Publication of JPH02285776A publication Critical patent/JPH02285776A/en
Priority to US07/982,115 priority patent/US5317428A/en
Priority to US08/190,470 priority patent/US5710826A/en
Application granted granted Critical
Publication of JP2821177B2 publication Critical patent/JP2821177B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T9/00Image coding
    • G06T9/004Predictors, e.g. intraframe, interframe coding

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は、画像通信機器であるフアクシミリ装置や画
像フアイリング装置における画像符号化方式に関するも
のである。
Description: BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an image coding system in a facsimile apparatus or an image filing apparatus which is an image communication apparatus.

〔従来の技術〕[Conventional technology]

従来の画像符号化方式はCCITT(国際電信電話諮問委
員会)で勧告されているG3,G4フアクシミリに代表され
るランレングス符号化方式が一般に用いられている。こ
の符号化方式は、画素が白または黒が続く長さ(ランレ
ングス)をカウントし、あらかじめ用意された符号表か
らそのカウント値に対応する符号を決定する方式であ
る。ここで値いられる符号表は、文書画像に多い長い白
ランに対して比較的短かい符号を割りあてるような特徴
づけがされている。このためラン長さの統計的性質が符
号表を作成する時には基準とした画像のものと異なる場
合、例えば白,黒が頻繁に斑点する疑似中間調画像を符
号化する場合は、符号量が原データを越えてしまうとい
う問題が生じている。
As a conventional image coding method, a run-length coding method represented by G3, G4 facsimile recommended by CCITT (International Telegraph and Telephone Consultative Committee) is generally used. This encoding method is a method of counting the length (run length) of a pixel in which white or black continues, and determining a code corresponding to the count value from a code table prepared in advance. The code table valued here is characterized in that relatively short codes are assigned to long white runs, which are common in document images. For this reason, when the statistical properties of the run length are different from those of the reference image when creating the code table, for example, when encoding a pseudo halftone image in which white and black are frequently spotted, the code amount is reduced. There is a problem of exceeding the data.

そこで、この様なランレンズスに基づいて符号化した
場合に不都合を生じる画像に対しても効率良い符号化が
実行できる一つの符号化手法として、算術符号通のマル
コフモデル符号を用いた符号化が提案されている。
Therefore, as one encoding method that can efficiently perform encoding even on an image that causes inconvenience when encoding based on such a run lens, encoding using a Markov model code through arithmetic code is proposed. Have been.

従来から知られている算術符号は、入力信号列を小数
2進数で表わされる符号になるように算術演算により符
号形成がなされる方法である。この方法はLangdonおよ
びRissanenらによる文献“Compression of Blach/White
Images with Arithmetic Coding",IEEE Tran Com.COM
−29,6(1981.6)等に発表されている。この文献による
とすでに符号化した入力信号列をS、劣勢シンボル(LP
S)の出る確率をq、演算レジスタAugendをA(S)、
符号レジスタをC(S)とした時に、入力信号ごとに以
下の算術演算を行う。
A conventionally known arithmetic code is a method in which a code is formed by an arithmetic operation so that an input signal sequence becomes a code represented by a decimal binary number. This method is described in the document “Compression of Blach / White” by Langdon and Rissanen et al.
Images with Arithmetic Coding ", IEEE Tran Com.COM
−29,6 (1981.6). According to this document, an already coded input signal sequence is represented by S,
Q is the probability of S), A (S) is the arithmetic register Augend,
When the code register is set to C (S), the following arithmetic operation is performed for each input signal.

A(S1)=A(S)×q≒A(S)×2-Q …(1) A(S0)=<A(S)−A(S1)> …(2) <>は有効桁lbitで打ち切りを表す C(S0)=C(S) …(3) C(S1)=C(S)+A(S0) …(4) ここで、符号データが優勢シンボル(MSP:上の例では
0)の場合はA(S0),C(S0)を次のデータの符号化に
使う。また劣勢シンボル(LPS:上の例では1)の場合
は、A(S1),C(S1)を次のデータの符号化に使う。
A (S1) = A (S) × q ≒ A (S) × 2− Q (1) A (S0) = <A (S) −A (S1)> l (2) << 1 is valid C (S0) = C (S)... (3) C (S1) = C (S) + A (S0)... (4) where code data is a dominant symbol (MSP: the above example) In the case of 0), A (S0) and C (S0) are used for encoding the next data. Further, in the case of a less-probable symbol (LPS: 1 in the above example), A (S1) and C (S1) are used for encoding the next data.

新しいAの値は2S倍(Sは0以上の整数)され、0.5
A<1.0の範囲におさめられる。この処理は、ハード
ウエアでは演算レジスタAをS回シフトすることに相当
する。符号レジスタCに対しても同じ回数の左シフトが
行なわれ、シフトアウトされた信号が符号となる。以上
の処理を繰り返し符号形成がなされる。
The new value of A is multiplied by 2 S (S is an integer greater than or equal to 0), and 0.5
A is within the range of 1.0. This processing corresponds to shifting the operation register A S times in hardware. The same number of left shifts are performed on the code register C, and the shifted-out signal becomes a code. The above processing is repeated to form a code.

また、(1)の色で示したようにLPSの出現確率qを
2のべき乗(2-Q:Qは正整数)で近似することにより、
乗算計算をシフト演算に置き換えている。この近似をさ
らによくするためにqを、例えば(5)の式の如くの2
のべき乗の多項式で近似することが提案されている。こ
の近似により効率最悪点の改善が行われている。
Also, as shown by the color of (1), by approximating the appearance probability q of LPS by a power of 2 (2- Q : Q is a positive integer),
Multiplication calculation is replaced by shift operation. In order to further improve this approximation, q is set to, for example, 2 as in the equation (5).
It has been proposed to approximate with a power of polynomial. This approximation improves the worst efficiency.

q≒2-Q1+2-Q2 …(5) 〔発明が解決しようとしている課題〕 しかしながら、前述の算術符号化では、2のべき乗で
近似された出現確率は固定であって、出現確率が異なる
画像に対しては、効率良い符号化がなされないことがあ
る。
q ≒ 2− Q1 + 2− Q2 (5) [Problem to be Solved by the Invention] However, in the above-described arithmetic coding, the appearance probabilities approximated by the power of 2 are fixed, and the appearance probabilities are different. May not be efficiently coded.

そこで、符号化すべき画像の特徴に応じてLPSの出現
確率qを変え、画像に適した効率的な符号化を行なうこ
とが提案されている。尚、この確率推定方法には、符号
化済の画素の状態により一義的に決定する静的な方法
と、符号化しながら確率を推定していく動的な方法が考
えられている。
Therefore, it has been proposed that the appearance probability q of the LPS is changed in accordance with the characteristics of the image to be encoded, and efficient encoding suitable for the image is performed. As the probability estimating method, there are considered a static method in which the probability is uniquely determined based on the state of the encoded pixels, and a dynamic method in which the probability is estimated while encoding.

ところで、LPSの出現確率qを2のべき乗の多項式で
近似した場合には、その出現確率qの値は不連続な値で
あって、ある出現確率から他の出現確率への変化をなさ
しめるための条件、時期等が最適な符号化を達成するた
めの大きな要素となる。
By the way, when the appearance probability q of the LPS is approximated by a power-of-two polynomial, the value of the appearance probability q is a discontinuous value, and the change from one occurrence probability to another occurrence probability is performed. Are important factors for achieving optimal encoding.

〔課題を解決するための手段〕[Means for solving the problem]

本発明は、以上の点に鑑みてなされたもので、画像を
効率よく予測符号化する画像符号化方法及び装置を提供
することを目的とし、詳しくは、符号化対象画像の予め
定められた複数の画素を参照する参照ステップと、前記
参照された複数の画素の状態に対応して前記符号化対象
画像の注目画素の優勢シンボルと劣勢シンボルの出現効
率を表わすインデックスを保持する保持ステップと、前
記保持されている前記優勢シンボルの値と前記インデッ
クスとに基づいて前記符号化対象性画像の注目画素を符
号化する符号化ステップと、前記符号化された前記符号
化対象画像の注目画素が優勢シンボルであるか劣勢シン
ボルであるかに応じて前記保持されている前記優勢シン
ボルの値と前記インデックスを更新する更新ステップと
を有し、更に、夫々が複数のインデックスを含み、且
つ、夫々に含まれる前記複数のインデックスの更新幅が
異なる複数のテーブルを設定する設定ステップと、前記
インデックスの更新履歴に基づいて前記複数のテーブル
の1つを選択する選択ステップとを備え、前記更新ステ
ップにおいて、前記選択されたテーブルに含まれる前記
複数のインデックスに基づいて前記保持されている前記
インデックスを更新することを特徴とする画像符号化方
法を提供するものであり、また、符号化対象画像の予め
定められた複数の画素を参照する参照手段と、前記参照
手段により参照される複数の画素の状態に対応して前記
符号化対象画像の注目画素の優勢シンボルの値と劣勢シ
ンボルの出現確率を表わすインデックスを保持する保持
手段と、前記保持手段により保持されている前記優勢シ
ンボルの値と前記インデックスとに基づいて前記符号化
対象画像の注目画素を符号化する符号化手段と、前記符
号化手段により符号化された前記符号化対象画像の注目
画素が優勢シンボルであるか劣勢シンボルであるかに応
じて前記保持手段に保持されている前記優勢シンボルの
値と前記インデックスを更新する更新手段とを有し、前
記更新手段は、夫々が複数のインデックスを含み、且
つ、夫々に含まれる前記複数のインデックスの更新幅が
異なる複数のテーブルを備え、前記インデックスの更新
履歴に基づいて前記複数のテーブルの1つを選択し、選
択したテーブルに含まれる前記複数のインデックスに基
づいて前記保持手段に保持されている前記インデックス
を更新することを特徴とする画像符号化装置を提供する
ものである。
The present invention has been made in view of the above points, and an object of the present invention is to provide an image encoding method and apparatus for efficiently predictively encoding an image. A reference step of referring to the pixel of the, and a holding step of holding an index indicating the appearance efficiency of the superior symbol and the inferior symbol of the pixel of interest of the encoding target image corresponding to the state of the plurality of pixels referred to, An encoding step of encoding a target pixel of the encoding target image based on the held value of the superior symbol and the index, wherein the encoding target pixel of the encoded target image has a superior symbol And an updating step of updating the value of the held superior symbol and the index in accordance with whether the symbol is the inferior symbol or the inferior symbol. A setting step of setting a plurality of tables including a plurality of indexes and having different update widths of the plurality of indexes included in each of the plurality of indexes, and selecting one of the plurality of tables based on the update history of the indexes And updating the held index based on the plurality of indexes included in the selected table in the updating step. A reference unit that refers to a plurality of predetermined pixels of the encoding target image; and a dominant symbol of a pixel of interest of the encoding target image corresponding to a state of the plurality of pixels referenced by the reference unit. Holding means for holding a value and an index representing the probability of occurrence of the inferior symbol; Encoding means for encoding a pixel of interest of the image to be encoded based on the value of the dominant symbol and the index, and a pixel of interest of the image to be encoded which has been encoded by the encoding means. Or updating means for updating the index and the value of the superior symbol held in the holding means depending on whether the symbol is the inferior symbol, the updating means, each including a plurality of indexes, And a plurality of tables each having a different update width of the plurality of indexes included therein, selecting one of the plurality of tables based on an update history of the index, and selecting the plurality of indexes included in the selected table. Updating the index held in the holding unit based on the image encoding apparatus. is there.

〔実施例〕〔Example〕

第1図は本発明を適用した符号化装置の実施例であ
る。2値情報(0または1、白または黒)になった画像
信号100はラインメモリ10に入力され、数行分のデータ
が保持される。ここからの出力信号103を状態決定回路1
1に入力することにより、画像信号100中の注目画素が所
属する状態が決まる。総状態数は注目画素の周囲何画素
を参照するかにより決まり、参照画素数nとすると総状
態数は2nの関係がある。決定した状態を表わす状態信号
St104はカウンタメモリ13,符号化条件メモリ14に入力さ
れる。
FIG. 1 shows an embodiment of an encoding apparatus to which the present invention is applied. The image signal 100 that has become binary information (0 or 1, white or black) is input to the line memory 10, and data for several rows is held. The output signal 103 from here is sent to the state determination circuit 1
By inputting to 1, the state to which the pixel of interest in the image signal 100 belongs is determined. The total number of states is determined by how many pixels around the target pixel are to be referred to. If the number of reference pixels is n, the total number of states has a relationship of 2 n . State signal indicating the determined state
St104 is input to the counter memory 13 and the encoding condition memory 14.

符号化条件メモリ14には状態信号St104で表わされる
各状態毎に、出現しやすいシンボルである優勢シンボル
MSP108と後述する算術符号の符号化条件を示すインデツ
クス1107が記憶されている。MPS108は予測変換回路17に
入力され、予測変換回路17では、画像信号100がMPS108
と一致した時に1となるYN信号101を出力する。YN信号1
01は更新回路15に入力され、更新回路15では、YN信号が
1の時に、カウンタメモリ13に各状態毎に記憶されてい
るカウント値のうち対応する状態のカウントを1インク
リメントする。そして、カウンタメモリ13に記憶されて
いるカウント値C106がカウントテーブルROM12からの設
定値MC105に一致したならば、インデツクスI107が大き
くなる方向(LPSの出現確率qが小さくなる方向)に更
新する。(MPSの反転は行なわない。) 尚、カウントテーブルROM12は、LPSの出現確率qを表
わすインデツクスIに対応して決められている第1表で
示したMPSの数のMC105を更新回路15に供給する。
The encoding condition memory 14 stores, for each state represented by the state signal St104, a dominant symbol that is a symbol that is likely to appear.
An MSP 108 and an index 1107 indicating an encoding condition of an arithmetic code to be described later are stored. The MPS 108 is input to the predictive conversion circuit 17, where the image signal 100 is
And outputs a YN signal 101 which becomes 1 when it matches. YN signal 1
01 is input to the update circuit 15, and when the YN signal is 1, the update circuit 15 increments the count of the corresponding state among the count values stored in the counter memory 13 for each state by one. Then, when the count value C106 stored in the counter memory 13 matches the set value MC105 from the count table ROM 12, the index I107 is updated in a direction to increase (a direction in which the appearance probability q of LPS decreases). (The inversion of the MPS is not performed.) The count table ROM 12 supplies the update circuit 15 with the MC 105 of the number of MPSs shown in Table 1 determined in correspondence with the index I indicating the appearance probability q of the LPS. I do.

また、更新回路15では、MPS108と画素信号100が不一
致の場合、即ち、予測変換回路17からのYN信号が0の時
はインデツクスI107が小さくなる方向(LPSの出現確率
qが大きくなる方向)に更新する。また、インデツクス
が1の時に値が0のYN信号が来ると、MPSを反転(0→
1または1→0)する処理を行う。出力I′109、MPS′
110は更新後のインデツクスの値であり、符号化条件メ
モリ14に再記憶される。
Further, in the updating circuit 15, when the MPS 108 and the pixel signal 100 do not match, that is, when the YN signal from the predictive conversion circuit 17 is 0, the index I107 decreases (the LPS appearance probability q increases). Update. When a YN signal with a value of 0 comes when the index is 1, the MPS is inverted (0 →
1 or 1 → 0). Output I'109, MPS '
110 is the value of the updated index, which is stored in the encoding condition memory 14 again.

符号化パラメータ決定回路16では、インデツクスI107
の値に基づいて算術符号の符号化パラメータQ111を算術
符号器18にセツトする。この算術符号器18では、予測変
換回路17からのYN信号101をパラメータQ111を用いて算
術符号化し符号102を得る。
In the coding parameter determination circuit 16, the index I107
The arithmetic coding parameter Q111 of the arithmetic code is set in the arithmetic encoder 18 based on the value of. The arithmetic encoder 18 arithmetically encodes the YN signal 101 from the prediction conversion circuit 17 using the parameter Q111 to obtain a code 102.

第2図は予測変換回路17のブロツク図である。画像信
号100とMPS108がEX−NOR回路20に入力され、第2表の論
理式に従って画像信号100とMPS108が一致したときに
1、不一致のときに0となるYN信号101が出力される。
FIG. 2 is a block diagram of the predictive conversion circuit 17. The image signal 100 and the MPS 108 are input to the EX-NOR circuit 20, and a YN signal 101 that is 1 when the image signal 100 and the MPS 108 match and 0 when they do not match is output according to the logical formula in Table 2.

第3図は、更新回路15のブロツク図である。YN信号10
1が1の時、カウンタメモリ13からのカウント値C106が
加算器21で+1インクリメントされ、信号C′112にな
る。この値は比較器23でカウントテーブルROM12からのM
C105と比較され、C′の値がMCの値に一致したならば更
新信号UPA113をセツトする。またYN信号101は反転器25
を通り更新信号UPB114となり、UPA,UPBはインデツクス
変更回路25に入る。また、UPAとUPBはOR回路27で論理OR
がとられ、OR回路27の出力信号115はセレクタ22の切り
換え信号となる。セレクタ22では信号115が1の時はカ
ウンタの値をリセツトするため0信号119を選び、それ
以外は加算器21の出力信号C′112を選び、カウンタ更
新信号C′116として出力し、これをカウンタメモリ13
に記憶させる。
FIG. 3 is a block diagram of the updating circuit 15. YN signal 10
When 1 is 1, the count value C106 from the counter memory 13 is incremented by +1 in the adder 21 to become a signal C'112. This value is calculated by the comparator 23 as M from the count table ROM12.
Compared with C105, if the value of C 'coincides with the value of MC, the update signal UPA113 is set. In addition, the YN signal 101 is
, The update signal UPB114, and UPA and UPB enter the index change circuit 25. UPA and UPB are logically ORed by OR circuit 27.
And the output signal 115 of the OR circuit 27 becomes a switching signal of the selector 22. When the signal 115 is 1, the selector 22 selects the 0 signal 119 to reset the counter value, and otherwise selects the output signal C'112 of the adder 21 and outputs it as the counter update signal C'116. Counter memory 13
To memorize.

インデツクス変更回路25には、インデツクスの更新き
ざみを制御する信号d117(標準的にはd=1)とUPA11
3,UPB114および符号化条件メモリ14から現在のインデツ
クスI107が入力されている。
The index change circuit 25 includes a signal d117 (typically d = 1) for controlling the index update interval and the UPA11.
3. The current index I107 is input from the UPB 114 and the encoding condition memory 14.

第3表はインデツクス変更図路25におけるインデツク
ス更新方法を示すテーブルである(第3表には更新きざ
みがd=1とd=2の場合を示している。)このテーブ
ルを入力I,条件d,UPA,UPBで参照することにより更新し
たインデツクスI′を決定する。また、I=1でUPB1の
時はEX信号118をセツトする。EX信号が1の時には反転
器26では現在のMPS108のシンボルを反転させ(0→1ま
たは1→0)、更新MPS′110を得る。また、EX=0の時
はMPS′は変化させない。更新されたI′109およびMP
S′110は符号化条件メモリ14に記憶され、次の処理用の
インデツクスI及びMPSとして用いられる。尚、第3表
に示した更新法は、ROMなどによりテーブルでも構成で
きるし、加減算器を使ってロジックで構成することも可
能である。
Table 3 is a table showing an index update method in the index change map 25 (Table 3 shows a case where the update interval is d = 1 and d = 2). , UPA, and UPB to determine the updated index I '. When I = 1 and UPB1, the EX signal 118 is set. When the EX signal is 1, the inverter 26 inverts the symbol of the current MPS 108 (0 → 1 or 1 → 0) to obtain an updated MPS′110. When EX = 0, MPS 'is not changed. Updated I'109 and MP
S'110 is stored in the encoding condition memory 14, and is used as an index I and MPS for the next processing. The updating method shown in Table 3 can be constituted by a table using a ROM or the like, or can be constituted by logic using an adder / subtractor.

以上の如く、2のべき乗の多項式で近似したLPSの出
現確率qを表わすインデツクスIの値に応じて定められ
たMPSの数分のMPSが発生したときには、インデツクスI
をd加算し、算術符号に用いるLPSの出現確率qを小さ
くせしめ、一方、LPSが発生したときには、インデツク
スIをd減算し、算術符号に用いるUPSの出現確率qを
大きくせしめる。また、更にLPSの出現確率qが0.5を表
わすインデツクスIが1の状態においてLPSが発生した
場合は、MPSを反転する。
As described above, when as many MPSs as the number of MPSs determined according to the value of the index I representing the appearance probability q of the LPS approximated by the power-of-two polynomial are generated, the index I
Is added, and the appearance probability q of the LPS used for the arithmetic code is reduced. On the other hand, when the LPS occurs, the index I is subtracted by d to increase the appearance probability q of the UPS used for the arithmetic code. Further, when the LPS is generated while the index I indicating that the appearance probability q of the LPS is 0.5 is 1, the MPS is inverted.

この様に、入力画像に適応的にインデツクス及びMPS
を更新することにより、符号化効率の良い算術符号化が
達成できる。
In this way, the index and MPS
Is updated, arithmetic coding with good coding efficiency can be achieved.

第4図は状態決定回路11のブロツク図である。状態決
定のための参照画素は第5図に示したA,B,C,Dの4画素
である。*は符号化する注目画素位置を示している。第
4図の42,43,44,45はラツチであり、Aラツチ42は注目
嵩*の画像信号100の1画素前のデータを保持してお
り、また、Bラツチ43,Cラツチ44,Dラツチ45は夫々1ラ
イン前の第5図に示す如く、現在の注目画素位置の1画
素前、注目画素位置、注目画素位置の1画素後に対応す
る位置のデータを保持しており、これらラツチのラツチ
データはデコーダ41に入力される。デコーダ41からの出
力は16の状態を示す状態信号St104(0〜15)になる。
尚、参照画素数は4画素に限られるものではない。
FIG. 4 is a block diagram of the state determination circuit 11. The reference pixels for determining the state are the four pixels A, B, C, and D shown in FIG. * Indicates a target pixel position to be encoded. In FIG. 4, reference numerals 42, 43, 44, and 45 denote latches, an A latch 42 holds data one pixel before the image signal 100 of the volume of interest *, and a B latch 43, a C latch 44, D As shown in FIG. 5, each of the latches 45 holds data of a position corresponding to one pixel before the current target pixel position, a target pixel position, and a position corresponding to one pixel after the target pixel position, as shown in FIG. The latch data is input to the decoder 41. The output from the decoder 41 becomes a state signal St104 (0 to 15) indicating 16 states.
Note that the number of reference pixels is not limited to four pixels.

第6図は本実施例で用いる算術符号の符号化効率曲線
である。以下、インデツクスIの値を小文字iで示す。
この曲線はLPSの出現確率をq、符号化時での近似確率q
eiとした時に式(6)で示される。そして、LPSの出現
確率qの値の大きい方から小さい方へ、順次インデツク
スIを1,2,3,…と付与する。
FIG. 6 is an encoding efficiency curve of the arithmetic code used in this embodiment. Hereinafter, the value of the index I is indicated by a small letter i.
This curve shows the appearance probability of LPS as q and the approximate probability q at the time of encoding.
When expressed as ei , it is expressed by equation (6). Then, the indexes I are sequentially assigned as 1, 2, 3,... From the larger value of the appearance probability q of the LPS to the smaller value.

ここで、分子はエトロピであり、qeiは式(7)で示さ
れる値である。
Here, the numerator is etropy, and q ei is a value represented by Expression (7).

qei=q1+q2 …(7) q1,q2の値は2のべき乗の多項近似の値で第4表で与え
られている。例えば(8)〜(10)で示される。
q ei = q 1 + q 2 (7) The values of q 1 and q 2 are power-of-two polynomial approximations and are given in Table 4. For example, they are shown in (8) to (10).

qe1=2-2+2-2 …(8) qe2=2-1+2-4 …(9) qe3=2-2+2-3 …(10) となり、この確率において効率ηが1.0になるピーク点
となるqeiを以降実効確率と呼ぶ。また効率曲線の交点
を境界確率qbiと呼び、この確率を境に隣りの実効確率
を使って符号化するほうが効率が向上することは明らか
である。
q e1 = 2 -2 +2 -2 ... (8) q e2 = 2 -1 +2 -4 ... (9) q e3 = 2 -2 +2 -3 ... (10), and the efficiency η becomes 1.0 at this probability. The peak point q ei is hereinafter referred to as the effective probability. In addition, it is clear that the efficiency is improved when the intersection of the efficiency curves is called a boundary probability q bi and coding is performed using the adjacent effective probability with this probability as a boundary.

本実施例では、式(5)で示したように2つの項で近
似できる確率から第4表に示した実効確率qeiを選んで
いる。また、第4表のQ1,Q2,Q3は算術符号器18に送るパ
ラメータQc111である。即ち、Q1,Q2はシフトレジスタへ
与えるシフト量であり、このシフト演算により2のべき
乗計算を行っている。またQ3は第2項めの係数を示し、
+,−の切り換えを行う。
In the present embodiment, the effective probabilities q ei shown in Table 4 are selected from the probabilities that can be approximated by two terms as shown in Expression (5). Further, Q 1 , Q 2 , Q 3 in Table 4 are parameters Q c 111 to be sent to the arithmetic encoder 18. That is, Q 1 and Q 2 are shift amounts given to the shift register, and a power of 2 is calculated by this shift operation. Q 3 represents the coefficient of the second term,
Switches between + and-.

第1表のMCの値は、以下のように決定している。 The MC values in Table 1 are determined as follows.

即ち、LPSの数をNL、MPSの数をNMとした時、LPSの発
生確率は式(11)で与えられる。
That is, when the number of LPS N L, the number of MPS was N M, the probability of LPS is given by equation (11).

この式をNMで解くと式(12)になる。 Solving this equation with N M gives equation (12).

NM=NL(1/q−1) …(12) ただしxは小数点以下の切り上げを表す。式(1
2)におけるqに第6図に示した境界確率qbiを与えるこ
とにより、そこでの優勢シンボル(MPS)の数NMiが計算
される。したがって、MCは式(13)から計算される。
N M = N L (1 / q−1) (12) where x represents the fractional part rounded up. Expression (1
By giving the boundary probability q bi shown in FIG. 6 to q in 2), the number N Mi of dominant symbols (MPS) there is calculated. Therefore, MC is calculated from equation (13).

MCi=NMi+1−NMi …(13) 第1表のMCの値は式(11),(12),(13)からNL=2
として計算したものである。
MCi = N Mi + 1 −N Mi (13) The value of MC in Table 1 is obtained from equations (11), (12), and (13) as N L = 2
It is calculated as

この様に、第6図示の如く各境界確率qbiに基づいて
各インデツクスIに対応した優勢シンボルMPSの数NMi
求め、隣り合ったインデツクス間の優勢シンボルNMの差
を各インデツクスIに対するMCとする。
Thus, to the number of calculated N Mi, the difference of each Indetsukusu I dominant symbols N M between adjacent Indetsukusu the symbol MPS corresponding to each Indetsukusu I on the basis of each boundary probability q bi as sixth illustrated MC.

そして、このMCの値と発生する優勢シンボルの数を前
述の如く比較し、MCの値と優勢シンボルの数が一致した
ならば、その状態は隣りのインデツクスIを用いた符号
化が適した状態と判断して、インデツクスIを変更す
る。これによって、優勢シンボルの発生数を基にして良
好なタイミングでインデツクスIの変更がなされ、且
つ、最適のインデツクスIを用いた符号化を適応適に達
成できる。
Then, the MC value is compared with the number of dominant symbols to be generated as described above. If the MC value matches the number of dominant symbols, the state is determined to be suitable for encoding using the adjacent index I. And the index I is changed. As a result, the index I is changed at a good timing based on the number of occurrences of the superior symbols, and the encoding using the optimal index I can be adaptively achieved.

第7図は算術符号器18のブロツク図である。 FIG. 7 is a block diagram of the arithmetic encoder 18.

符号パラメータ決定回路16で決められたコントロール
信号Qc111(第4表)のうちシフトレジスタA70にQ1を、
シフトレジスタBにQ2、セレクタ72にQ3が入力される。
Q1,Q2はそれぞれシフトレジスタA,Bに対してAugend信号
であるAs123を何bit右にシフトするかを指示する。シフ
トされた結果が出力信号130,131となる。
Q 1 of the control signal Q c 111 (Table 4) determined by the code parameter determination circuit 16 is assigned to the shift register A 70,
Q 2 is input to the shift register B, and Q 3 is input to the selector 72.
Q 1 and Q 2 instruct shift registers A and B how many bits to shift As123, which is the Augend signal, to the right. The shifted results are output signals 130 and 131.

信号131は、反転器76により補数がとられ、セレクタ7
2はコントロール信号Q3により信号131又は反転器76の出
力信号を選択し、出力信号132を得る。加算器73ではシ
フトレジスタA70からの信号130とセレクタ72からの信号
132の加算が行われ、AS1信号124が出力される。減算器7
4では、AS信号123からAS1信号124を減算し、AS0信号125
を得る。セレクタ75ではAS0信号125とAS1信号124のいず
れかをYN信号101により選択する。即ちYN信号が1の時
はAS0信号が、また、YN信号が0の時はAS1信号がA′信
号126になる。シフト回路80ではA′信号のMSBが1にな
るまで左へシフトする処理が行われ、このシフトにより
AS′信号127が得られる。このシフトの回数に相当する
シフト信号132は、コードレジスタ79に入り、コードレ
ジスタ79からはシフト回数に相当する数のbitがKSBから
順番に出力され符号データ130になる。
The signal 131 is complemented by the inverter 76 and
2 selects the output signal of the signal 131 or the inverter 76 by the control signal Q 3, to obtain an output signal 132. The adder 73 outputs a signal 130 from the shift register A70 and a signal from the selector 72.
The addition of 132 is performed, and an AS1 signal 124 is output. Subtractor 7
In 4 subtracts the A S1 signal 124 from the A S signal 123, A S0 signal 125
Get. One of the selectors 75 in the A S0 signal 125 and A S1 signal 124 selected by the YN signal 101. That is A S0 signal when the YN signal is 1, also the A S1 signal when the YN signal is 0 is A 'signal 126. In the shift circuit 80, a process of shifting to the left until the MSB of the A 'signal becomes 1 is performed.
An A S 'signal 127 is obtained. The shift signal 132 corresponding to the number of shifts enters the code register 79, and the number of bits corresponding to the number of shifts is output from the code register 79 in order from the KSB to become the code data 130.

符号データ130は、図示しないbit処理方法にて、bit1
の連続が有限個内になるように処理され、図示しない受
信器に送られる。
Code data 130 is stored in bit 1 by a bit processing method (not shown).
Are processed so as to be within a finite number, and sent to a receiver (not shown).

また、コードレジスタ79の内容CR128は加算器77でAS0
信号125と加算され、セレクタ78に入る。また、AS0信号
125の加算されていない信号CR128もセレクタ78に入り、
YN信号101が1の時はCR′=CR、YN=0の時はCR′=CR
+AS0となるCR′信号129として出力される。コードレジ
スタ79に関して前述したシフト処理はCR′信号に対して
行う。
The contents CR128 code register 79 by the adder 77 A S0
The signal is added to the signal 125 and the result is input to the selector 78. Also, the A S0 signal
The 125 non-added signal CR128 also enters the selector 78,
CR '= CR when YN signal 101 is 1, CR' = CR when YN = 0
It is output as a CR 'signal 129 which becomes + A S0 . The shift processing described above for the code register 79 is performed on the CR 'signal.

尚、第3図示の更新回路におけるd117の信号は、例え
ばd=1のように固定させておいてもよいが、以下に示
すように追従をさらに早くすることも可能である。
Incidentally, the signal of d117 in the update circuit shown in FIG. 3 may be fixed, for example, d = 1, but the following can be further accelerated as shown below.

第8図はdの決定回路のブロツク図である。 FIG. 8 is a block diagram of the decision circuit of d.

UPA,UPB信号のどちらかが1にセツトされたことをEXO
R回路80で検出し、検出信号140が出力される。この出力
140がセツトされている時にラツチ83〜87を駆動し、UP
A,UPB信号の過去数回の履歴を保持させる。信号146は第
5表に示したように、1の時はUPAが、また、0の時はU
PBが1にセツトされたことを表わしている。ラツチ83〜
87からの出力信号141〜145は判定回路88にて、例えば、
全部1か、全部0か、それ以外か等を表わす判定信号14
7をd設定回路89に出力する。dの設定回路89では、全
部1もしくは全部0の時はd=2、それ以外はd=1と
なるようにd信号117を出力する。これにより第3表で
示したテーブルを切り換えることが可能となる。
EXO indicates that either UPA or UPB signal is set to 1
Detection is performed by the R circuit 80, and a detection signal 140 is output. This output
Drives latches 83-87 when 140 is set, UP
The history of the past several times of the A and UPB signals is retained. As shown in Table 5, the signal 146 is UPA when it is 1 and U when it is 0.
This indicates that PB has been set to 1. Ratch 83 ~
The output signals 141 to 145 from 87 are determined by the determination circuit 88, for example,
A determination signal 14 indicating whether all 1's, all 0's, other than that, etc.
7 is output to the d setting circuit 89. The d setting circuit 89 outputs the d signal 117 so that d = 2 when all 1 or all 0, and d = 1 otherwise. This makes it possible to switch between the tables shown in Table 3.

この様に、インデツクスの更新処理が連続する場合
は、インデツクスの更新幅を大きくするので、画像に応
じたインデツクスIの追従を迅速になさしめることがで
きる。
As described above, when the index update processing is continuous, the index update width is increased, so that the index I can be quickly followed in accordance with the image.

また、本実施例ではdの値を正整数としたが、d=1/
2や1/4などの値をとれるように回路を変更することも可
能である。
In the present embodiment, the value of d is a positive integer, but d = 1 /
It is also possible to change the circuit to take values such as 2 or 1/4.

また、劣勢シンボルLPSの出現確率を2のべき乗の2
項の加減算にて近似したが、この項数はこれに限るもの
ではないことは言う迄もない。
In addition, the appearance probability of the inferior symbol LPS is set to the
Although approximation was made by addition and subtraction of terms, it goes without saying that the number of terms is not limited to this.

〔発明の効果〕 以上説明したように、本によると、符号化対象画像の
予め定められた複数の画素を参照し、複数の画素の状態
に対応して符号化対象画像の注目画素の優勢シンボルの
値と劣勢シンボルの出現確率を表わすインデックスを保
持し、この劣勢シンボルの値とインデックスとに基づい
て符号化対象画像の注目画素を符号化する構成におい
て、符号化された符号化対象画像の注目画素が優勢シン
ボルであるか劣勢シンボルであるかに応じて優勢シンボ
ルの値とインデックスを更新するので、符号化対象画像
の内容(性質)に適した優勢シンボルの値とインデック
スを用いた符号化を動的、且つ、適応的に実効すること
が可能となり、符号化効率を向上せしめることができ、
また、更に、夫々が複数のインデックスを含み、且つ、
夫々に含まれる複数のインデックスの更新幅が異なる複
数のテーブルを備え、インデックスの更新履歴に基づい
て複数のテーブルの1つを選択し、選択したテーブルに
含まれる複数のインデックスに基づいてインデックスを
更新するので、例えば、インデックスの更新処理がまれ
に起こる場合は、インデックスの更新幅の小さいテーブ
ルを選択し、一方、インデックスの更新処理が連続する
場合は、インデックスの更新幅の大きいテーブルを選択
することにより、動的、且つ、適応的符号化に用いるイ
ンデックスを優勢シンボル及び劣勢シンボルの発生状況
にあった適正なものとすることができ、符号化効率をよ
り一層向上せしめることができる。
[Effects of the Invention] As described above, according to the book, with reference to a plurality of predetermined pixels of the encoding target image, the dominant symbol of the target pixel of the encoding target image corresponding to the state of the plurality of pixels. And an index indicating the probability of occurrence of the inferior symbol, and encoding the pixel of interest of the image to be encoded based on the value of the inferior symbol and the index. Since the value and index of the superior symbol are updated according to whether the pixel is the superior symbol or the inferior symbol, encoding using the superior symbol value and the index suitable for the content (property) of the encoding target image is performed. Dynamically and adaptively, it is possible to improve the coding efficiency,
Further, each further includes a plurality of indexes, and
Providing a plurality of tables each having a different update width of a plurality of indexes included therein, selecting one of the plurality of tables based on the update history of the index, and updating the index based on the plurality of indexes included in the selected table Therefore, for example, if the index update processing occurs infrequently, select a table with a small index update width, while if the index update processing is continuous, select a table with a large index update width. Accordingly, the index used for dynamic and adaptive coding can be made appropriate for the occurrence state of the superior symbol and the inferior symbol, and the encoding efficiency can be further improved.

【図面の簡単な説明】[Brief description of the drawings]

第1図は本発明を適用した符号器のブロツク図、 第2図は予測変換回路のブロツク図、 第3図は更新回路のブロツク図、 第4図は状態決定回路のブロツク図、 第5図は参照画素を示す図、 第6図は符号化効率曲線を示す図、 第7図は算術符号器のブロツク図、 第8図は更新履歴によるdの決定回路のブロツク図であ
り、 11は状態決定回路、12はカウントテーブルROM、13はカ
ウンタメモリ、14は符号化条件メモリ、15は更新回路、
16は符号化パラメータ決定回路、17は予測変換回路、18
は算術符号器である。
FIG. 1 is a block diagram of an encoder to which the present invention is applied, FIG. 2 is a block diagram of a prediction conversion circuit, FIG. 3 is a block diagram of an update circuit, FIG. 4 is a block diagram of a state determination circuit, FIG. 6 is a diagram showing a reference pixel, FIG. 6 is a diagram showing an encoding efficiency curve, FIG. 7 is a block diagram of an arithmetic encoder, FIG. 8 is a block diagram of a circuit for determining d based on an update history, and 11 is a state. A decision circuit, 12 is a count table ROM, 13 is a counter memory, 14 is an encoding condition memory, 15 is an update circuit,
16 is an encoding parameter decision circuit, 17 is a predictive conversion circuit, 18
Is an arithmetic encoder.

───────────────────────────────────────────────────── フロントページの続き (58)調査した分野(Int.Cl.6,DB名) H04N 7/24 - 7/68 H04N 1/41 - 1/419──────────────────────────────────────────────────続 き Continued on the front page (58) Field surveyed (Int.Cl. 6 , DB name) H04N 7/24-7/68 H04N 1/41-1/419

Claims (2)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】符号化対象画像の予め定められた複数の画
素を参照する参照ステップと、 前記参照された複数の画素の状態に対応して前記符号化
対象画像の注目画素の優勢シンボルと劣勢シンボルの出
現確率を示すインデックスを保持する保持ステップと、 前記保持されている前記優勢シンボルと前記インデック
スとに基づいて前記符号化対象画像の注目画素を符号化
する符号化ステップと、 前記符号化された前記符号化対象画像の注目画素が優勢
シンボルであるか劣勢シンボルであるかに応じて前記保
持されている前記優勢シンボルの値と前記インデックス
を更新する更新ステップとを有し、 更に、夫々が複数のインデックスを含み、且つ、夫々に
含まれる前記複数のインデックスの更新幅が異なる複数
のテーブルを設定する設定ステップと、 前記インデックスの更新履歴に基づいて前記複数のテー
ブルの1つを選択する選択ステップとを備え、 前記更新ステップにおいて、前記選択されたテーブルに
含まれる前記複数のインデックスに基づいて前記保持さ
れている前記インデックスを更新することを特徴とする
画像符号化方法。
A reference step of referring to a plurality of predetermined pixels of an encoding target image; and a dominant symbol and a dominant symbol of a pixel of interest of the encoding target image corresponding to a state of the referenced plurality of pixels. A holding step of holding an index indicating a symbol appearance probability; an encoding step of encoding a target pixel of the encoding target image based on the held dominant symbol and the index; and Updating the value of the retained superior symbol and the index according to whether the pixel of interest in the encoding target image is a superior symbol or an inferior symbol, further comprising: A setting step of setting a plurality of tables including a plurality of indexes and having different update widths of the plurality of indexes included in each of the plurality of indexes; And a selecting step of selecting one of the plurality of tables based on an update history of the index. In the updating step, the selected table is stored based on the plurality of indexes included in the selected table. And updating the index.
【請求項2】符号化対象画像の予め定められた複数の画
素を参照する参照手段と、 前記参照手段により参照される複数の画素の状態に対応
して前記符号化対象画像の注目画素の優勢シンボルの値
と劣勢シンボルの出現確率を表わすインデックスを保持
する保持手段と、 前記保持手段により保持されている前記優勢シンボルの
値と前記インデックスとに基づいて前記符号化対象画像
の注目画素を符号化する符号化手段と、 前記符号化手段により符号化された前記符号化対象画像
の注目画素が優勢シンボルであるか劣勢シンボルである
かに応じて前記保持手段に保持されている前記優先シン
ボルの値と前記インデックスを更新する更新手段とを有
し、 前記更新手段は、夫々が複数のインデックスを含み、且
つ、夫々に含まれる前記複数のインデックスの更新幅が
異なる複数のテーブルを備え、 前記インデックスの更新履歴に基づいて前記複数のテー
ブルの1つを選択し、選択したテーブルに含まれる前記
複数のインデックスに基づいて前記保持手段に保持され
ている前記インデックスを更新することを特徴とする画
像符号化装置。
2. A reference unit for referring to a plurality of predetermined pixels of an image to be encoded, and a dominant pixel of interest of the image to be encoded corresponding to a state of the plurality of pixels referenced by the reference unit. Holding means for holding a symbol value and an index indicating the probability of occurrence of the inferior symbol; and encoding a target pixel of the encoding target image based on the value of the superior symbol and the index held by the holding means. Encoding means, and the value of the priority symbol held in the holding means depending on whether the pixel of interest of the encoding target image encoded by the encoding means is a superior symbol or an inferior symbol. And updating means for updating the index, wherein the updating means includes a plurality of indexes, and the plurality of indexes included in each of the plurality of indexes. A plurality of tables having different update widths of the indexes, selecting one of the plurality of tables based on the update history of the index, and holding the selected table based on the plurality of indexes included in the selected table. An image encoding device for updating the index.
JP10660889A 1989-04-26 1989-04-26 Image coding method and apparatus Expired - Lifetime JP2821177B2 (en)

Priority Applications (5)

Application Number Priority Date Filing Date Title
JP10660889A JP2821177B2 (en) 1989-04-26 1989-04-26 Image coding method and apparatus
EP90304485A EP0395394B1 (en) 1989-04-26 1990-04-25 Image encoding method
DE69020424T DE69020424T2 (en) 1989-04-26 1990-04-25 Image coding process.
US07/982,115 US5317428A (en) 1989-04-26 1992-11-25 Image encoding method and apparatus providing variable length bit stream signals
US08/190,470 US5710826A (en) 1989-04-26 1994-02-02 Image encoding method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP10660889A JP2821177B2 (en) 1989-04-26 1989-04-26 Image coding method and apparatus

Publications (2)

Publication Number Publication Date
JPH02285776A JPH02285776A (en) 1990-11-26
JP2821177B2 true JP2821177B2 (en) 1998-11-05

Family

ID=14437831

Family Applications (1)

Application Number Title Priority Date Filing Date
JP10660889A Expired - Lifetime JP2821177B2 (en) 1989-04-26 1989-04-26 Image coding method and apparatus

Country Status (1)

Country Link
JP (1) JP2821177B2 (en)

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
IBM Journal R&D 32[6](1988.11)p.737−752

Also Published As

Publication number Publication date
JPH02285776A (en) 1990-11-26

Similar Documents

Publication Publication Date Title
EP0395394B1 (en) Image encoding method
US5297220A (en) Image processing system for image compression and decompression
US5363219A (en) Image processing method and apparatus
EP0858210B1 (en) Image processing apparatus
WO2018127167A1 (en) Method and apparatus for range derivation in context adaptive binary arithmetic coding
JP3684128B2 (en) Arithmetic encoding / decoding method and arithmetic encoding / decoding device
JP2002033925A (en) Method arithmetic encoding and decoding, and apparatus for arithmetic encoding and decoding
JP2821177B2 (en) Image coding method and apparatus
US5784497A (en) Arithmetic encoding with carry over processing
JP2810478B2 (en) Image coding device
JP2872334B2 (en) Color image encoding device
JP3119373B2 (en) Image coding device
JP2952007B2 (en) Image coding device
JP2697897B2 (en) Color image encoding method and apparatus
JP2877451B2 (en) Image coding method
JP2675903B2 (en) Image coding method
JP2832059B2 (en) Color image encoding device
JP2832072B2 (en) Image coding method and apparatus
JPH046954A (en) Picture prediction coding system
JP2815510B2 (en) Motion vector calculation circuit for color difference signal
JPH04316279A (en) Color picture encoder
JPH0393359A (en) Color picture coding system
JP3698797B2 (en) Arithmetic encoder / decoder
JPH0645945A (en) Arithmetic coding method and its decoding method
JPH0795693B2 (en) Encoding / decoding device

Legal Events

Date Code Title Description
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20070828

Year of fee payment: 9

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080828

Year of fee payment: 10

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080828

Year of fee payment: 10

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090828

Year of fee payment: 11

EXPY Cancellation because of completion of term
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090828

Year of fee payment: 11