JP3108404B2 - Data compression device and data decompression device - Google Patents

Data compression device and data decompression device

Info

Publication number
JP3108404B2
JP3108404B2 JP10171524A JP17152498A JP3108404B2 JP 3108404 B2 JP3108404 B2 JP 3108404B2 JP 10171524 A JP10171524 A JP 10171524A JP 17152498 A JP17152498 A JP 17152498A JP 3108404 B2 JP3108404 B2 JP 3108404B2
Authority
JP
Japan
Prior art keywords
unit
order
code
data
byte
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
JP10171524A
Other languages
Japanese (ja)
Other versions
JPH1146145A (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.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
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 Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP10171524A priority Critical patent/JP3108404B2/en
Publication of JPH1146145A publication Critical patent/JPH1146145A/en
Application granted granted Critical
Publication of JP3108404B2 publication Critical patent/JP3108404B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、文字コード、画像
等のデータをバイト単位又はワード単位で符号化するデ
ータ圧縮装置及びデータ復元装置に関し、特に、パイプ
ライン処理によりバイト単位又はワード単位の符号化に
おける処理性能を向上させたデータ圧縮装置及びデータ
復元装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a data compression device and a data decompression device for encoding data such as a character code and an image in a byte unit or a word unit. TECHNICAL FIELD The present invention relates to a data compression device and a data decompression device having improved processing performance in image processing.

【0002】[0002]

【従来の技術】近年、文字コード、ベクトル情報、画像
など様々な種類のデータがコンピュータで扱われるよう
になっており、扱われるデータ量も急速に増加してきて
いる。大量のデータを扱うときは、データの中の冗長な
部分を省いてデータ量を圧縮することで、記憶容量を減
らしたり、遠隔地へ遠く伝送したりできるようになる。
2. Description of the Related Art In recent years, various types of data such as character codes, vector information, and images have been handled by computers, and the amount of data handled has rapidly increased. When dealing with a large amount of data, by compressing the amount of data by omitting redundant portions in the data, it becomes possible to reduce the storage capacity or to transmit the data to a remote place.

【0003】本発明の分野は、文字コードの圧縮に限ら
ず、様々なデータに適用できるが、以下では、情報理論
で用いられている呼称を踏襲し、データの1ワード単位
を文字と呼び、データが任意のワード数がつながったも
のを文字列と呼ぶことにする。様々なデータを1つのア
ルゴリズムで圧縮できる方法としてユニバーサル符号化
がある。ユニバーサル符号化には様々な方法があるが、
代表的な方法として2つの方法が挙げられる。辞書型符
号化と確率統計型符号化である。
[0003] The field of the present invention is not limited to character code compression but can be applied to various types of data. In the following, one word unit of data is called a character, following the name used in information theory. Data in which an arbitrary number of words are connected is called a character string. Universal encoding is a method that can compress various data with one algorithm. There are various methods for universal encoding,
There are two typical methods. Dictionary coding and probability statistical coding.

【0004】辞書型(Dictionary coding 或いは Lem
pel-Ziv coding(発明者の名前)) 代表的方法:LZW法,LZSS法等 確率統計型(Statistical coding) 代表的方法:多値算術符号化,動的ハフマン符号化等 辞書型は、過去に現れた文字列(文字列長が可変)を辞
書というテーブルに登録し、次に現れる文字列を辞書内
に登録されている最も長い文字列の辞書内の位置情報
(符号長が一定)で符号化する。従って、可変の長い文
字列、例えば数十文字を固定の情報、例えば12ビット
で符号化を行うVF(Variable-Fixed coding )符号化
に基づいている。
[0004] Dictionary coding or Lem
pel-Ziv coding (name of the inventor)) Representative method: LZW method, LZSS method, etc. Stochastic coding (Statistical coding) Representative method: Multi-valued arithmetic coding, dynamic Huffman coding, etc. The appearing character string (character string length is variable) is registered in a table called a dictionary, and the next appearing character string is encoded with the position information (code length is constant) in the dictionary of the longest character string registered in the dictionary. Become Therefore, it is based on VF (Variable-Fixed coding) encoding in which a variable long character string, for example, several tens of characters, is encoded with fixed information, for example, 12 bits.

【0005】辞書型アルゴリズムの詳細は例えば (1)T.C.Bell etc, "Text Compression",Prentice-Hall,
1990.section 8, Dictionary Techniques. に記載される。これに対し確率統計型は、過去に現れた
個々の文字(1文字だから一定)の出現確率(直前の文
字列に従属した条件付確率も含む)から、次に現れる文
字を出現確率を反映した統計的(entropy )な情報(符
号長が可変)で符号化する。従って、1文字(固定)ず
つ、その出現確率を統計的情報(可変)で符号化を行う
FV(Fixed-Variable coding )符号化に基づいてい
る。
For details of the dictionary type algorithm, see, for example, (1) TCBell etc, "Text Compression", Prentice-Hall,
1990. section 8, Dictionary Techniques. On the other hand, the probability statistic type reflects the appearance probability of the next character from the appearance probability (including the conditional probability dependent on the immediately preceding character string) of the individual character (constant because it is one character) that appeared in the past. Encoding is performed with statistical (entropy) information (code length is variable). Therefore, it is based on FV (Fixed-Variable coding) coding in which the appearance probability of each character (fixed) is encoded with statistical information (variable).

【0006】確率統計型アルゴリズムの詳細は (2)T.C.Bell etc, "Text Compression",Prentice-Hall,
1990.section 5,From Probabilities To Bits. に記載される。この中で、代表的のものにハフマン符号
化(Huffman coding)や算術符号化(Arithmetic codin
g )がある。
The details of the stochastic algorithm are described in (2) TCBell etc, "Text Compression", Prentice-Hall,
1990.section 5, From Probabilities To Bits. Among these, Huffman coding (Huffman coding) and arithmetic coding (Arithmetic codin
g) There is.

【0007】更に、直前の文字列の従属関係を取り込む
文脈モデルの詳細は、 (3)T.C.Bell etc, "Text Compression",Prentice-Hall,
1990.section 6, Context modeling. に記載される。この場合の直前の文字列の従属関係は、
せいぜい数文字で無限に長い文字列を取り込む辞書型と
は異なる。
Further, the details of the context model that takes in the subordination relation of the immediately preceding character string are described in (3) TCBell etc, "Text Compression", Prentice-Hall,
1990.Section 6, Context modeling. In this case, the subordination of the previous string is
This is different from the dictionary type, which takes an infinitely long string with at most a few characters.

【0008】従って、辞書型符号化と確率統計型符号化
は、 過去に現れたデータの捉え方が、辞書型符号化は文字
列そのものであり、確率統計型符号化は出現確率であ
る。 符号化部分が辞書型符号化は固定長であるのに対し、
確率統計型符号化は可変長(原則的)である、 という点で、根本的に圧縮のメカニズムが大きく異な
る。
[0008] Therefore, in the dictionary type coding and the probability statistical type coding, the method of catching data that appeared in the past is the character string itself in the dictionary type coding, and the probability statistical type coding is the occurrence probability. The encoding part is fixed length in dictionary type encoding,
The compression mechanism is radically different in that stochastic coding is of variable length (in principle).

【0009】ここでは、主に英文テキスト等のバイトス
トリームのデータ列を対象としたユニバーサル符号化方
式として、多値算術符号化を取り上げる。算術符号化と
して、大きく分けて2つの符号化が提案されている。2
値算術符号化と多値算術符号化である。両者の違いは、
2値算術符号化が符号化の対象とするデータの単位が0
又は1のビット対応2値であり、多値算術符号化が符号
化の対象とするデータの単位が例えば8ビットを1まと
めにしたバイト対応の多値化の違いである。2値算術符
号化の代表的な例としては、CCITT/ISO で2値画像圧縮
の標準化方式であるJBIGのエントロピー符号化に使
われているQMコーダがある。例えば、 (4) 安田著,「マルチプロセッサメディア符号化の国際
標準:第3章 算術符号化」丸善,p68 〜82,1991,6 に詳細が示される。
Here, multi-value arithmetic coding will be described as a universal coding method for a data stream of a byte stream such as English text. Broadly speaking, two types of arithmetic coding have been proposed. 2
Value arithmetic coding and multi-value arithmetic coding. The difference between the two is
The unit of data to be encoded by binary arithmetic encoding is 0
Or, it is a binary corresponding to one bit, and the unit of data to be encoded by the multi-level arithmetic coding is a difference between byte-compatible multi-level coding in which, for example, 8 bits are grouped together. A typical example of binary arithmetic coding is a QM coder used in JBIG entropy coding, which is a standardized method for binary image compression in CCITT / ISO. For example, see (4) Yasuda, "International Standards for Multiprocessor Media Coding: Chapter 3, Arithmetic Coding", Maruzen, pp.68-82,1991,6.

【0010】多値算術符号化の代表的な例としては、WI
TTEN,ABRAHANSON の符号化がある。例えば、 (5)I.H.Witten 他, 「Arithmetic Coding for Data Com
pression」,Comunications of Association for Comput
ing Machinery,30(6),520- 540,1987.7 (6)D.M.Abrahamson,「An Adaptive Dependency source
Mode for DataCompre ssion 」 Comunications of Ass
ociation for Computing Machinery,32(1),77 -83,198
9.1 に詳細が示される。このうち、画像に適している等の理
由から2値算術符号化のみが実用化されている。しか
し、多値算術符号化が最も高い圧縮性能が得られること
から、その実用化が期待されている。
A typical example of multi-level arithmetic coding is WI
There is TTEN, ABRAHANSON encoding. For example, (5) IHWitten et al., "Arithmetic Coding for Data Com
pression '', Communications of Association for Comput
ing Machinery, 30 (6), 520-540, 1987.7 (6) DMAbrahamson, `` An Adaptive Dependency source
Mode for DataCompletion) Communications of Ass
ociation for Computing Machinery, 32 (1), 77 -83,198
Details are given in 9.1. Of these, only binary arithmetic coding has been put to practical use because it is suitable for images. However, since multi-level arithmetic coding provides the highest compression performance, its practical use is expected.

【0011】確率統計型符号化の処理は、図67のよう
に、出現頻度モデル部400とエントロピー符号化部4
02で構成される。出現頻度モデル部400では、入力
文字とその直前の文字列(文脈)を取り込み、その従属
関係を加味した入力文字の出現頻度を求める。エントロ
ピー符号化部402では、出現頻度モデル部400で求
めた出現数に基づき、動的に符号を作成し可変長符号化
を行う。
As shown in FIG. 67, the processing of the probability statistical coding is performed by using the appearance frequency model unit 400 and the entropy coding unit 4.
02. The appearance frequency model unit 400 takes in the input character and the character string (context) immediately before the input character, and obtains the appearance frequency of the input character in consideration of the dependency. The entropy coding unit 402 dynamically creates a code based on the number of appearances obtained by the appearance frequency model unit 400 and performs variable length coding.

【0012】更に詳細に説明すると、図68(A)のよ
うな3文字a,b,cで構成される文字列abcを例に
とると、直前文字列との関係が図68(B)のような木
構造で表される。出現頻度モデル部400では、この木
構造の各節点の文字を通る文字列が出現する毎に出現数
を計数することによって、直前の文字列との従属関係、
例えば条件付確率が求められる。このような入力文字と
直前文字列との従属関係を求める文脈収集の方法とし
て、固定次数の文脈を収集する方法と、ブレンド文脈の
収集方法の2つがある。ここで文脈の文字数を次数と呼
ぶ。
More specifically, when a character string abc composed of three characters a, b, and c as shown in FIG. 68A is taken as an example, the relationship with the immediately preceding character string is shown in FIG. It is represented by such a tree structure. The appearance frequency model unit 400 counts the number of appearances each time a character string that passes through a character at each node of the tree structure appears, thereby determining the dependency on the immediately preceding character string,
For example, a conditional probability is determined. There are two methods of collecting contexts for obtaining the dependency between the input character and the immediately preceding character string: a method of collecting fixed-order contexts and a method of collecting blend contexts. Here, the number of characters in the context is called an order.

【0013】固定次数の文脈を収集する方法は、文脈の
文字数を固定にする方法である。例えば2次の文脈で
は、出現頻度モデル部400は、直前2文字x1、x
に繋がる文字の文脈を収集し、直前文字X2,X1の後
に出現する文字yの従属関係、例えば条件付確率ρ(y
|x1,x2)を求めてエントロピー符号化部402に
渡す。ここで、yは注目する入力文字、x1,x2はそ
れぞれ直前の第1文字,第2文字とする。
The method of collecting a fixed-order context is a method of fixing the number of characters in the context. For example, in the secondary context, the appearance frequency model unit 400 determines that the immediately preceding two characters x1, x2
Is collected, and the dependency of the character y appearing after the immediately preceding characters X2 and X1, for example, the conditional probability ρ (y
| X1, x2) is passed to the entropy coding unit 402. Here, y is the target input character, and x1 and x2 are the first character and the second character immediately before, respectively.

【0014】ブレンド文脈の収集方法は、文脈の次数を
混合した方法である。固定次数の文脈の場合、直前の文
字列が出にくい場合はその従属関係の推定が不確かにな
る。逆に直前の文字列が出易い場合は、その従属関係の
推定が正確さを増し、更に次数を上げることができる可
能性を残す。一般に、直前の文字列が長くなる高次の文
脈を使うほど、文字間の偏りをより捉え易くすることが
でき、高圧縮率が得られる。
The method of collecting the blend context is a method in which the order of the context is mixed. In the case of a fixed-degree context, if the previous character string is difficult to appear, the estimation of its dependency becomes uncertain. Conversely, when the immediately preceding character string is likely to appear, the accuracy of the estimation of the dependency increases, leaving the possibility that the degree can be further increased. In general, the higher the context in which the immediately preceding character string becomes longer, the easier it is to catch the bias between characters, and a higher compression ratio is obtained.

【0015】しかし、高次文脈の相関が弱いデータで
は、かえって圧縮率が悪くなる。このような問題を解決
しようとしたのが次数を混合したブレンド文脈である。
ブレンド文脈の方法では、直前の次数を固定せずに、個
々の文脈によって出易い場合には、次数の高いところで
従属関係を導き出し、出にくい場合には次数の低いとこ
ろで従属関係を導き出すようにしたものである。
However, data having a weak correlation in a higher-order context has a worse compression ratio. An attempt to solve such a problem is a blend context in which orders are mixed.
In the method of blending context, the order is not fixed, and if it is easy to appear depending on the individual context, the dependency is derived at a high order, and if it is difficult to appear, the dependency is derived at a low order. Things.

【0016】このように出現頻度モデル部400で求め
た出現数に基づいて、動的符号を与えるエントロピー符
号化部402の代表的な符号化としては、算術符号化、
動的ハフマン符号化、自己組織化符号化等がある。算術
符号化は、各文字の出現確率から符号を演算で求めるた
め、1ビット/文字以下でも符号割当てが可能であり、
最も符号化効率が高いとされている。
Based on the number of appearances determined by the appearance frequency model unit 400, typical encodings of the entropy encoding unit 402 for giving a dynamic code include arithmetic encoding,
There are dynamic Huffman coding, self-organizing coding, and the like. In arithmetic coding, a code is calculated from the appearance probability of each character, so that a code can be assigned even at 1 bit / character or less.
It is said that the coding efficiency is the highest.

【0017】図69(A)〜(C)は多値算術符号化の
手順であり、複数ビット単位、例えばバイト単位の入力
文字の文字列を数直線[0,1]の1点に対応付けて1
つの符号で表す。ここで説明を簡単にするため、a,
b,c,dの4の文字よりなる文字列を考える。まず図
69(A)のように、各文字の出現頻度を求める。ここ
で出現頻度とは、各文字の出現数を総出現数で割った確
率である。例えば、文字aの出現頻度は0.15、文字
bの出現頻度は0.25、文字cの出現頻度は0.3
5、文字dの出現頻度は0.25であったとする。
FIGS. 69 (A) to 69 (C) show a multi-value arithmetic coding procedure in which a character string of an input character in units of a plurality of bits, for example, bytes, is associated with one point of a number line [0, 1]. 1
It is represented by two signs. Here, for simplicity, a,
Consider a character string consisting of the four characters b, c, and d. First, as shown in FIG. 69A, the appearance frequency of each character is obtained. Here, the appearance frequency is a probability obtained by dividing the number of appearances of each character by the total number of appearances. For example, the appearance frequency of the character a is 0.15, the appearance frequency of the character b is 0.25, and the appearance frequency of the character c is 0.3.
5. Assume that the appearance frequency of the character d is 0.25.

【0018】次に図69(A)の出現頻度について、頻
度の高い順番に文字を並べ替え、図69(B)のよう
に、累積出現頻度を算出する。累積頻度とは、注目文字
より順位の低い文字の出現頻度を加算したものである。
即ち、出現頻度の1番高い1位の文字cの累積出現頻度
は文字b,d,aの出現頻度を加算したもので、0.6
5となる。同様にして、残りの文字b,d,aの各累積
出現頻度は、0.40,0.15,0.0となる。
Next, regarding the appearance frequency in FIG. 69 (A), the characters are rearranged in descending order of frequency, and the cumulative appearance frequency is calculated as shown in FIG. 69 (B). The cumulative frequency is the sum of the frequencies of appearance of characters having a lower rank than the character of interest.
That is, the cumulative appearance frequency of the first character c having the highest appearance frequency is the sum of the appearance frequencies of the characters b, d, and a.
It becomes 5. Similarly, the cumulative appearance frequencies of the remaining characters b, d, and a are 0.40, 0.15, and 0.0.

【0019】この状態で例えば文字cが入力されたとす
ると、図67(C)のように、数直線で定義される符号
化区間[0,1]について、入力文字cの累積出現頻度
freq[c]=0.35と累積出現頻度cum fr
eq[c]=0.65から新区間404を求める。具体
的には、数直線で定義される符号化区間[0,1]、の
上端(ハイレベル)H1 =1、下端(ローレベル)L1
=0、区間幅W1 =1について、入力文字cの累積出現
頻度freq[c]=0.35と累積出現頻度cum
freq[c]=0.65から新区間404の上端(ハ
イレベル)H2、下端(ローレベル)L2 及び区間幅W2
を求める。即ち、新区間404の下端L2 は、前回区
間の下端(ローレベル)L1 と区間幅W1 から、 L2 =L1 +W1 ×cum freq[c] =0.0+1.0×0.65 =0.65 となる。また新区間404の幅W2 は、 W2 =W1 ×freq[c] =1.0×0.35 =0.35 更に、新区間404の上端(ハイレベル)H2 は、 H2 =L2 +W2 =0.65+0.35 =1.00 となる。このとき、文字cが入力したので、文字cの出
現数を1つインクリメントし、また総出現数を1つイン
クリメントし、これに応じて文字a,b,c,dの出現
頻度及び累積出現頻度が更新される。しかし、説明を簡
単にするため、図69(A)(B)の出現頻度と累積出
現頻度に固定して説明する。
If a character c is input in this state, for example, as shown in FIG. 67 (C), the cumulative appearance frequency freq [c of the input character c in the coding section [0, 1] defined by the number line ] = 0.35 and the cumulative appearance frequency cum fr
A new section 404 is obtained from eq [c] = 0.65. Specifically, the upper end (high level) H1 of the coding section [0, 1] defined by the number line, and the lower end (low level) L1
= 0, the section width W1 = 1, the cumulative appearance frequency freq [c] of the input character c = 0.35 and the cumulative appearance frequency cum
From freq [c] = 0.65, the upper end (high level) H2, lower end (low level) L2, and section width W2 of the new section 404
Ask for. That is, the lower end L2 of the new section 404 is calculated from the lower end (low level) L1 of the previous section and the section width W1 as follows: L2 = L1 + W1 × cum freq [c] = 0.0 + 1.0 × 0.65 = 0.65 Become. The width W2 of the new section 404 is W2 = W1.times.freq [c] = 1.0.times.0.35 = 0.35. The upper end (high level) H2 of the new section 404 is H2 = L2 + W2 = 0. 65 + 0.35 = 1.00. At this time, since the character c is input, the number of occurrences of the character c is incremented by one, and the total number of occurrences is incremented by one, and the appearance frequency and the cumulative appearance frequency of the characters a, b, c, and d are accordingly increased. Is updated. However, for the sake of simplicity, the description will be made with the appearance frequency and the cumulative appearance frequency shown in FIGS. 69 (A) and (B) fixed.

【0020】次に文字aが入力されると、前回の区間4
04を新たな区間[0,1]と見做し、この区間404
について、入力文字aの出現頻度freq[a]=0.
15と累積出現頻度cum freq[a]=0.15
に基づいて、新区間406の下端(ローレベル)L3 、
区間幅W3 、及び上端H3 を次のようにして求める。 L3 =L2 +W2 ×cum freq[a] =0.65+0.35×0.15 =0.7025 W3 =W2 ×freq[a] =0.35×0.15 =0.0525 H3 =L3 +W3 =0.7025+0.0525 =0.7550 次に文字dが入力されると、前回の区間406を新たな
区間[0,1]と見做し、この区間406について、入
力文字dの出現頻度freq[d]=0.25と累積出
現頻度cum freq[d]=0.4に基づいて、新
区間408の下端(ローレベル)L4 、区間幅W4 、及
び上端H4 を次のようにして求める。
Next, when the character a is input, the previous section 4
04 is regarded as a new section [0, 1], and this section 404
, The appearance frequency of the input character a, freq [a] = 0.
15 and the cumulative appearance frequency cum freq [a] = 0.15
, The lower end (low level) L3 of the new section 406,
The section width W3 and the upper end H3 are obtained as follows. L3 = L2 + W2.times.cum freq [a] = 0.65 + 0.35.times.0.15 = 0.7025 W3 = W2.times.freq [a] = 0.35.times.0.15 = 0.0525 H3 = L3 + W3 = 0 .7025 + 0.0525 = 0.7550 Next, when the character d is input, the previous section 406 is regarded as a new section [0, 1], and the appearance frequency freq [d ] = 0.25 and the cumulative appearance frequency cum freq [d] = 0.4, the lower end (low level) L4, the section width W4, and the upper end H4 of the new section 408 are obtained as follows.

【0021】 L4 =L3 +W3 ×cum freq[d] =0.7025+0.0525×0.40 =0.7235 W4 =W3 ×freq[d] =0.0525×0.40 =0.0210 H4 =L4 +W4 =0.7235+0.0210 =0.7445 この入力文字dが最終文字であったすると、区間408
を表わす任意の値、例えば区間408の上端と下端の間
の任意の値を算術化符号として出力する。具体的には、
前回の区間406を[1,0]に正規化して閾値1/
4,1/2,3/4により4つの分割区間に分け、最終
区間408の上端H4 と下端L4 が正規化された前回区
間406のどの分割区間に属するかを符号化する。例え
ば前回区間406について、次の条件で符号化する。
L4 = L3 + W3 × cum freq [d] = 0.725 + 0.0525 × 0.40 = 0.235 W4 = W3 × freq [d] = 0.0525 × 0.40 = 0.0210 H4 = L4 + W4 = 0.7235 + 0.0210 = 0.7445 If this input character d is the last character, section 408
, For example, an arbitrary value between the upper end and the lower end of the section 408 is output as an arithmetic code. In particular,
The previous section 406 was normalized to [1, 0] to obtain a threshold 1 /
The divided section is divided into four divided sections by 4, 1/2, and 3/4, and the upper end H4 and the lower end L4 of the final section 408 are coded to which of the normalized previous sections 406 belongs. For example, the previous section 406 is encoded under the following conditions.

【0022】1/2以上でビット1とし、1/2を下
回ったらビット0とする; 1/4以上で3/4以下の範囲にあればビット1と
し、この範囲を外れていればビット0とする; 最終区間408の場合には、H4 =0.7445である
から条件ではビット「1」となり、条件でもビット
「1」となる。またL4 =0.7235であるから条件
ではビット「1」となり、条件でもビット「1」と
なる。したがって、文字列「cad」の算術化符号は
「1111」となる。
Bit 1 is set when the value is 1/2 or more, and bit 0 is set when the value is less than 1/2. Bit 1 is set when the value is in the range of 1/4 or more and 3/4 or less, and bit 0 is set when the value is out of the range. In the case of the last section 408, since H4 = 0.7445, the bit becomes "1" under the condition, and the bit becomes "1" under the condition. Since L4 = 0.7235, the bit is "1" under the condition, and the bit is "1" under the condition. Therefore, the arithmetic code of the character string "cad" is "1111".

【0023】尚、実際の処理では、文字を入力して符号
化する際に、文字の出現数、累積出現数及び総出現数を
求めており、出現頻度及び累積出現頻度が必要となった
ときに、出現数を総出現数で割って累積出現頻度を求
め、また累積出現数を総出現数で割って累積出現頻度を
求めている。この意味で出現頻度は総出現数で正規化さ
れた出現数ということができ、また累積出現頻度は総出
現数で正規化された累積出現数ということができる。
In the actual processing, when characters are input and encoded, the number of occurrences, the cumulative number of occurrences, and the total number of occurrences of the characters are obtained. Then, the number of appearances is divided by the total number of appearances to determine the cumulative appearance frequency, and the cumulative number of appearances is divided by the total number of appearances to determine the cumulative occurrence frequency. In this sense, the appearance frequency can be referred to as the number of appearances normalized by the total number of appearances, and the cumulative appearance frequency can be referred to as the cumulative number of appearances normalized by the total number of appearances.

【0024】このような多値算術符号化によれば、出現
頻度が高い文字列ほど、最終区間の幅が大きくなり、短
い符号によって表せるため、データ量が圧縮される。ま
た、この方法は、符号後のビット表現に最小単位の制約
がなく、最小単位を1ビット以下に取ることができるた
め、効率の高い圧縮ができる。図70は従来の算術符号
化のデータ圧縮装置のブロック図である。図70におい
て、データ圧縮装置は、出現頻度順位並び替え部41
0、カウンタ412、頻度データ格納部414、辞書4
16、算術符号化部418で構成される。尚、この例で
は、出現頻度の代わりに出現数freq[ ]を使用
し、また累積出現頻度の代わりに累積出現数cum f
req[ ]を使用している。また辞書416は頻度デ
ータ格納部414に含めてもよい。
According to such multi-level arithmetic coding, the character string having a higher appearance frequency has a larger width of the last section and can be represented by a shorter code, so that the data amount is compressed. Further, in this method, since there is no restriction on the minimum unit in the bit representation after coding and the minimum unit can be set to 1 bit or less, highly efficient compression can be performed. FIG. 70 is a block diagram of a conventional arithmetic encoding data compression apparatus. 70, the data compression device includes an appearance frequency order rearranging unit 41.
0, counter 412, frequency data storage 414, dictionary 4
16, an arithmetic coding unit 418. In this example, the number of appearances freq [] is used instead of the frequency of appearance, and the number of appearances cum f
req [] is used. The dictionary 416 may be included in the frequency data storage 414.

【0025】カウンタ412は、入力された文字の出現
数freq[ ]をカウントし、更に、文字の累積出現
数cum freq[ ]と総出現数cum freq
[0]を求めて頻度データ格納部414に格納する。頻
度順位並び替え部410は、文字を入力する毎に、頻度
データ格納部414の全文字を出現数freq[ 」の
多い順に並べ替え、順位を示す登録番号に対応して出現
数freq[ 」と累積出現数cum freq[ ]
を格納する。同時に、辞書416のシンボルを、頻度デ
ータ格納部414の出現数の多い順番に、順位を示す登
録番号に対応して並べ替える。
The counter 412 counts the number of appearances freq [] of the input character, and furthermore, the cumulative number of characters cum freq [] and the total number of appearances freq [].
[0] is obtained and stored in the frequency data storage unit 414. Every time a character is input, the frequency order rearranging unit 410 rearranges all the characters in the frequency data storage unit 414 in descending order of the number of appearances freq [], and sets the number of appearances freq [] in correspondence with the registration number indicating the order. Cumulative appearance number cum freq []
Is stored. At the same time, the symbols in the dictionary 416 are rearranged in the order of the number of appearances in the frequency data storage unit 414 in accordance with the registration number indicating the order.

【0026】算術符号化部418は、入力文字kによる
辞書416の参照により順位を示す登録番号を頻度順並
び替え部410から受けると、この登録番号により頻度
データ格納部414を参照し、入力文字kの出現数fr
eq[k]、累積出現数cum freq[k]、及び
総出現数cum freq[0]を求める。そして、出
現数freq[k]及び累積出現数cum freq
[k]を、総出現数cum freq[0]で各々除算
して出現頻度および累積出現頻度を算出し、これに基づ
き新区間を求める。
When the arithmetic encoding unit 418 receives a registration number indicating the order from the frequency order rearranging unit 410 by referring to the dictionary 416 using the input character k, the arithmetic encoding unit 418 refers to the frequency data storage unit 414 based on the registration number, and Number of occurrences fr of k
eq [k], the cumulative appearance number cum freq [k], and the total appearance number cum freq [0] are obtained. Then, the number of appearances freq [k] and the cumulative number of appearances cum freq
[K] is divided by the total number of appearances cum freq [0] to calculate the appearance frequency and the cumulative appearance frequency, and a new section is obtained based on the calculated frequencies.

【0027】図70の動作を説明する。頻度順並び替え
部410は、入力文字kにより辞書416を検索し、出
現数の順位を示す登録番号を求め、算術符号化部418
に出力する。算術符号化部418は、頻度順並び替え部
410からの登録番号(順位)により頻度データ格納部
414を参照し、入力文字kの出現数freq[k]、
累積出現数cum freq[k]、及び総出現数cu
m freq[0]を求める。
The operation of FIG. 70 will be described. The frequency order rearranging unit 410 searches the dictionary 416 using the input character k, obtains a registration number indicating the order of the number of occurrences, and calculates the arithmetic encoding unit 418.
Output to The arithmetic encoding unit 418 refers to the frequency data storage unit 414 based on the registration number (order) from the frequency order rearranging unit 410, and displays the number of appearances freq [k] of the input character k,
Cumulative appearance number cum freq [k] and total appearance number cu
Find m freq [0].

【0028】そして、出現数freq[k]及び累積出
現数cum freq[k]を、総出現数cum fr
eq[0]で各々除算して出現頻度および累積出現頻度
を算出し、更に前回の区間幅Wk-1 に基づいて、新たな
区間Wk の上端(ハイレベル)Hk と下端(ローレベ
ル)Lk を求め、もし最終文字であれば新区間の任意の
値を符号として出力する。
Then, the number of appearances freq [k] and the cumulative number of appearances cum freq [k] are calculated as the total number of appearances fr fr [k].
eq [0] to calculate the appearance frequency and the cumulative appearance frequency. Further, based on the previous section width Wk-1, the upper end (high level) Hk and the lower end (low level) Lk of the new section Wk are calculated. If it is the last character, an arbitrary value in the new section is output as a code.

【0029】一方、カウンタ412は入力文字kの出現
数freq[k]、累積出現数cum freq[k]
及び総出現数cum freq[0]を各々1つずつイ
ンクリメントし、頻度データ格納部414の登録番号に
対応する値を更新する。続いて、頻度順並び替え部41
0は、更新後の出現数freq[ ]の順に頻度データ
格納部414及び辞書416の並び替えを行う。
On the other hand, the counter 412 indicates the number of appearances freq [k] of the input character k and the number of cumulative occurrences cum freq [k].
And the total number of occurrences cum freq [0] is incremented by one, and the value corresponding to the registration number in the frequency data storage unit 414 is updated. Subsequently, the frequency sorting unit 41
0 sorts the frequency data storage unit 414 and the dictionary 416 in the order of the updated appearance frequency freq [].

【0030】図71のフローチャートは多値算術符号化
の処理であり、出現文字について、直前までの文字との
履歴を考慮しない一重履歴、即ち0次文脈との従属関係
を推定する場合を例にとっている。ここで、符号化区間
の初期値は、上端H0 =1、下端L0 =1、区間幅W0
=1.0とする。iは出現数の高い順に並べ替えられた
辞書の順位(登録番号)であり、1,2,3,・・・,
Aの値をとる。
The flowchart of FIG. 71 is a process of multi-level arithmetic coding. In this example, a single-history of an appearing character without considering the history with the character immediately before it, that is, a case of estimating a subordinate relationship with a zero-order context is assumed. I have. Here, the initial values of the coding section are: upper end H0 = 1, lower end L0 = 1, section width W0
= 1.0. i is the order (registration number) of the dictionary sorted in descending order of the number of appearances, and 1, 2, 3,.
Take the value of A.

【0031】またfreq[i]は、出現数の高い順に
並び替えられた辞書の順位(登録番号)iの出現数であ
り、またcum freq[i]は辞書の順位iの累積
出現数である。更に、I=1,2,3,・・・,Aであ
ることから、cum freq[1]は、順位1位の累
積出現数であり、cum freq[A]は最下位Aの
累積出現数を表す。更に、符号化区間は、cum fr
eq[1]=1,cum freq[A]=0で正規化
される。
Further, freq [i] is the number of occurrences of the order (registration number) i of the dictionary sorted in descending order of the number of appearances, and cum freq [i] is the cumulative number of occurrences of the order i of the dictionary. . Furthermore, since I = 1, 2, 3,..., A, cum freq [1] is the cumulative appearance number of the first place, and cum freq [A] is the cumulative appearance number of the lowest A Represents Furthermore, the coding section is cum fr
It is normalized by eq [1] = 1, cum freq [A] = 0.

【0032】まずステップS1にあっては次の初期値の
設定を行う。 辞書Dの配列iに全ての単一文字を割り付ける。 D(i)=i 但し、i=1,2,3,・・・,Aであり、Aはアルフ
ァベット及び記号等の数で、最大256を採る。
First, in step S1, the following initial values are set. All single characters are assigned to the array i of the dictionary D. D (i) = i where i = 1, 2, 3,..., A, where A is the number of alphabets, symbols, etc. and takes a maximum of 256.

【0033】各文字に順位(登録番号)iを割り付け
る。 I(i)=i 但し,i=1,2,・・・,
A 全文字の出現数を初期化する。 freq(i)=1 但し,i=1,2,・・・,
A 全文字の累積出現数を初期化する。
An order (registration number) i is assigned to each character. I (i) = i where i = 1, 2,...,
A Initialize the number of appearances of all characters. freq (i) = 1, where i = 1, 2,.
A Initialize the cumulative number of all characters.

【0034】cum freq(i)=A−1 以上の初期値の設定が済んだならば、ステップS2でソ
ースデータの入力文字列から先頭の1文字kを入力す
る。次に、ステップS3に進み、入力文字kにより辞書
を検索して登録番号である順位jを求める。これはj=
I(k)と表現される。また順位jから符号区間に対応
する累積出現数のリストテーブルを参照して累積出現数
cum freq[j]を求める。これはi=D(j)
と表現される。
Cum freq (i) = A-1 After the initial values have been set, the first character k from the input character string of the source data is input in step S2. Next, the process proceeds to step S3, where the dictionary is searched by the input character k to determine the rank j as the registration number. This is j =
It is expressed as I (k). Further, the cumulative appearance number cum freq [j] is obtained from the rank j with reference to the list table of the cumulative appearance number corresponding to the code section. This is i = D (j)
Is expressed as

【0035】そして、辞書から検索した順位jを算術符
号化する。順位jの算術符号化とは、順位jの累積出現
数cum freq[j]を総出現数cum freq
[0]で除算して累積出現頻度を求め、前回の区間幅と
下端(ローレベル)から新区間を求める。ここで入力文
字が符号化単位となる所定バイト数の最終文字であれ
ば、新区間の任意の値を符号として出力する。
Then, the rank j searched from the dictionary is arithmetically encoded. Arithmetic encoding of rank j means that the cumulative appearance count cum freq [j] of rank j is calculated by the total appearance count cum freq
By dividing by [0], the cumulative appearance frequency is obtained, and a new section is obtained from the previous section width and the lower end (low level). Here, if the input character is the last character of a predetermined number of bytes serving as a coding unit, an arbitrary value in the new section is output as a code.

【0036】次に、ステップS4で順位jの入力文字k
と同じ出現数の文字が上の順位に並んでいる場合は、そ
の先頭順位に位置する文字、出現数、及び累積出現数の
入れ替えを行う。まず順位jより小さい順位の文字の内
で、j番目の文字kと出現数freq[k]の異なる文
字の1つ下の順位rを求める。即ち、freq[r]!
=freq[j]となる最大の順位rを見つける。ここ
で!は異なることを意味する。
Next, in step S4, the input character k in the order j
If the characters having the same number of occurrences are arranged in the higher order, the character located at the top order, the number of occurrences, and the cumulative number of occurrences are exchanged. First, among characters having a rank smaller than the rank j, a rank r that is one level lower than the j-th character k and a character having a different number of appearances freq [k] is obtained. That is, freq [r]!
Find the maximum rank r such that = freq [j]. here! Means different.

【0037】更に、辞書のr番目の文字に対応する区間
分の出現数のリストテーブルの順位がI(r)=s、同
じく対応する区間分の累積出現数のリストテーブルの順
位がD(r)=tであるとする。そこで、辞書について
j番目とr番目の文字を入れ替え、出現数の区間リスト
テーブルについてj番目とs番目の出現数を入れ替え、
更に累積出現数の区間リストテーブルについてj番目と
t番目の累積出現数を入れ替える。
Further, the rank of the list of the number of appearances of the section corresponding to the r-th character in the dictionary is I (r) = s, and the rank of the list of the cumulative number of appearances of the corresponding section is D (r). ) = T. Therefore, the j-th and r-th characters are exchanged in the dictionary, and the j-th and s-th occurrence numbers are exchanged in the section list table of the number of appearances.
Further, the j-th and t-th cumulative appearance numbers are exchanged in the section list table of the cumulative appearance number.

【0038】即ち、出現数の入れ替えI(j)=s、累
積出現数の入れ替えD(j)=t,辞書順位の入れ替え
I(r)=j,及び辞書文字の入れ替えD(r)=D
(j)を行う。例えば入力文字kの順位jと同じ出現数
をもつ上位の順位j−1,j−2,j−3が存在したと
すると、最上位のr=j−3が入れ替え先として求めら
れ、順位rと順位jの文字、出現数、累積出現数の入れ
替えを行う。
That is, the replacement of the number of appearances I (j) = s, the replacement of the cumulative number of occurrences D (j) = t, the replacement of dictionary order I (r) = j, and the replacement of dictionary characters D (r) = D
Perform (j). For example, if there are higher ranks j-1, j-2, and j-3 having the same number of appearances as the rank j of the input character k, the highest r = j-3 is obtained as the replacement destination, and the rank r And the character of rank j, the number of appearances, and the number of cumulative occurrences are exchanged.

【0039】続いて、ステップS5で、入れ替えが済ん
だ入力文字kの出現数freq[k]を1つインクリメ
ントし、更に、順位r+1以上の累積出現数cum f
req[ ]を1つインクリメントする。勿論、総出現
数cum freq[0]も1つインクリメントする。
そして再びステップS2に戻って次の1文字を入力し、
ソースデータがなくなるまて同じ処理を繰り返す。
Subsequently, in step S5, the number of appearances freq [k] of the replaced input character k is incremented by one, and further, the cumulative number of occurrences cum f of rank r + 1 or more is added.
Increment req [] by one. Of course, the total number of occurrences cum freq [0] is also incremented by one.
Then, returning to step S2 again, the next character is input,
Repeat the same process until there is no more source data.

【0040】図72のフローチャートは、出現文字につ
いて、直前の1文字との履歴を考慮した二重履歴、即ち
1次文脈との従属関係を推定する場合の多値算術符号化
である(参考文献(5)D.M.Abrahamson を参照)。この二
重履歴の処理にあっては、連続する2字の組み合わせを
考慮し、各文字毎に辞書を作成し、更に各文字毎に続く
文字の出現頻度を2番目の文字毎に辞書に登録する。例
えば、文字aの辞書には、文字aに続いて出現した文
字、例えばabに対するb、acに対するc等を登録
し、aに続く文字毎の出現数を求め、登録する。
The flowchart of FIG. 72 is a multi-level arithmetic coding for estimating a double history of appearance characters in consideration of the history with the immediately preceding character, that is, estimating the subordination relationship with the primary context (reference document). (5) See DMAbrahamson). In the processing of the double history, a dictionary is created for each character in consideration of a combination of two consecutive characters, and the appearance frequency of the character following each character is registered in the dictionary for each second character. I do. For example, in the dictionary of the character a, characters appearing after the character a, such as b for ab and c for ac, are registered, and the number of appearances of each character following a is obtained and registered.

【0041】このため、ステップS1の初期値の設定
で、辞書Dの配列には、文字pに対して続く文字i毎
に、D(p,i)を割り付ける。ここでp,i=1,
2,…,Aであり、Aはアルファベットの大きさ(数)
である。また、各文字に割り付ける番号はI(p,i)
とする。ここでp,i=1,2,…,Aである。これ以
外の点は、図71の一重履歴の処理と同じである。
Therefore, by setting the initial value in step S1, D (p, i) is assigned to the array of the dictionary D for each character i following the character p. Where p, i = 1,
2, ..., A, where A is the size (number) of the alphabet
It is. The number assigned to each character is I (p, i)
And Here, p, i = 1, 2,..., A. The other points are the same as the single history processing in FIG.

【0042】また図68(B)の木構造を使って動的符
号化を行う算術符号化以外のエントロピー符号化とし
て、動的ハフマン符号化や自己組織化符号化の一種であ
るスプレイ符号化等もある。動的ハフマン符号化は、例
えば (7)D.E.Knuth,"Dynamic Huffman Coding",Journal of A
logorithms 6, 163-180(1985) J.S.Vitter,"Design an
d Analysis of Dynamic Huffman Codes",Journal of AC
M,34,4,825-845(1987) (8) 植松友彦、“文書データ圧縮アルゴリズム入門”、
第5章、CQ出版社(19 94) 特許:整理番号94-11634 に詳細が示される。またスプレイ符号化は、 (9)D.W.Jones,"Application of Splay Tree to Data Co
mpression",Commun.of ACM,31,8,996-1007(1987) 特
許:整理番号94-01147 に詳細が示される。
As entropy coding other than arithmetic coding in which dynamic coding is performed using the tree structure of FIG. 68 (B), dynamic Huffman coding, spray coding which is a kind of self-organizing coding, and the like. There is also. Dynamic Huffman coding is described in, for example, (7) DEKnuth, "Dynamic Huffman Coding", Journal of A
logorithms 6, 163-180 (1985) JSVitter, "Design an
d Analysis of Dynamic Huffman Codes ", Journal of AC
M, 34, 4, 825-845 (1987) (8) Tomohiko Uematsu, "Introduction to Document Data Compression Algorithm",
Chapter 5, CQ Publishing Company (1994) Patents: Reference No. 94-11634, provides further details. Spray coding is based on (9) DWJones, "Application of Splay Tree to Data Co.
mpression ", Commun. of ACM, 31, 8, 996-1007 (1987) Patent: Reference No. 94-01147.

【0043】[0043]

【発明が解決しようとする課題】しかしながら、このよ
うな従来の確率統計型の符号化にあっては、図67のよ
うに、出現頻度モデル部400で出現頻度を求めた後、
エントロピー符号化部402で動的符号化を行うため、
処理に時間がかかるという問題があった。また、出現頻
度モデル部402でブレンド文脈を処理する場合には、
条件付確率等の従属関係を高次から低次に向けて逐次に
求めていたため、処理時間が大幅にかかり、とても実用
化にならなかった。
However, in such a conventional probability-statistic type encoding, as shown in FIG. 67, after the appearance frequency is obtained by the appearance frequency model unit 400,
In order to perform dynamic encoding in the entropy encoding unit 402,
There was a problem that processing took time. When the blend context is processed by the appearance frequency model unit 402,
Since dependency relations such as conditional probabilities were sequentially determined from a higher order to a lower order, processing time was greatly increased, and it was not practically used.

【0044】したがって本発明は、バイト単位の多値デ
ータの確率統計型の符号化と復号化を効率的に行って処
理時間を実用化レベルに短縮できるデータ圧縮装置およ
びデータ復元装置を提供することを目的とする。また従
来の符号化にあっては、主に英文テキスト、例えばAS
CIIの8ビットコードを対象にバイトストリーム方向
のバイト単位を基本に符号化することを考えている。
Accordingly, an object of the present invention is to provide a data compression device and a data decompression device capable of efficiently performing probability statistical coding and decoding of multivalued data in byte units to reduce the processing time to a practical level. With the goal. Also, in conventional encoding, mainly English texts, for example, AS
It is considered that the encoding is performed based on the byte unit in the byte stream direction for the CII 8-bit code.

【0045】このため、現在、国際言語コードとして採
用されている2バイト構成のUnicodeや日本語コ
ード,RGB3バイト構成のフルカラー画像データ,4
バイト又は8バイトといったプログラムコード等の複数
バイトのワード構成を持つデータに対して、従来の符号
化方法はあまり圧縮効率が良くない。即ち、従来の符号
化方法では、複数バイトのワード構成を持つデータに対
して、バイト単位で処理するため、処理に時間がかか
る、例えば、単純にバイト単位の符号化をワードに拡張
する例として1バイトを2バイトに拡張したとすると、
充分な圧縮率を得るためのデータ量、処理時間、メモリ
容量が全て1バイトに対し2バイトでは256倍が必要
となり、とても実用的にはならない。
For this reason, unicode or Japanese code having a 2-byte structure currently used as an international language code, full-color image data having a 3-byte RGB format,
For data having a word structure of a plurality of bytes such as a program code such as a byte or 8 bytes, the conventional encoding method is not very efficient. That is, in the conventional encoding method, data having a word structure of a plurality of bytes is processed in units of bytes, so that it takes a long time to process. For example, an example in which encoding in bytes is simply extended to words If one byte is extended to two bytes,
The amount of data, the processing time, and the memory capacity for obtaining a sufficient compression ratio are all 256 bytes for 1 byte, which is 256 times impractical.

【0046】そこで本発明は、ワードストリーム方向で
のバイト単位の辞書型および確率統計型による符号化と
復号化を効率的に行って、処理時間を実用化レベルに短
縮できるデータ圧縮装置およびデータ復元装置を提供す
ることを目的とする。
Accordingly, the present invention provides a data compression apparatus and a data decompression apparatus which can efficiently perform encoding and decoding by a dictionary type and a probability statistical type in a byte stream direction in a word stream direction, thereby reducing a processing time to a practical level. It is intended to provide a device.

【0047】[0047]

【課題を解決するための手段】図1,2,3,4図は本
発明の原理説明図である。本発明に従えば、バイト単位
の多値データの確率統計型の符号化と復号化を効率的に
行って処理時間を実用化レベルに短縮できるデータ圧縮
装置およびデータ復元装置が提供される。
FIGS. 1, 2, 3 and 4 are diagrams for explaining the principle of the present invention. According to the present invention, there is provided a data compression device and a data decompression device capable of efficiently performing probability statistical coding and decoding of multivalued data in byte units to reduce the processing time to a practical level.

【0048】(固定次数文脈のパイプライン処理) まず本発明は、図1(A)のように、入力文字を直前文
字列の条件付出易さにより符号化を行うデータ圧縮装置
を提供する。データ圧縮装置は、出現頻度モデル部10
とエントロピー符号化部12を、パイプライン制御部1
5によってパイプライン動作させる。
( Pipeline Processing in Fixed-Order Context ) First, as shown in FIG. 1A, the present invention provides a data compression apparatus for encoding an input character according to the conditional ease of the immediately preceding character string. The data compression device includes an appearance frequency model unit 10
And the entropy encoder 12 are connected to the pipeline controller 1
5 causes a pipeline operation.

【0049】即ち、出現頻度モデル部10は、直前の文
字列に繋がる入力文字の条件付出易さを各文字毎に登録
した頻度データ格納部を、入力文字により検索して条件
付出易さを求め、頻度データ格納部を登録更新する。エ
ントロピー符号化部12は、出現頻度モデル部10で求
めた条件付出易さにより入力文字を符号化する。パイプ
ライン制御部15は、出現頻度モデル部10に文字入力
させて条件付出易さを求めると同時に、エントロピー符
号化部12で1つ前の入力文字につき求めた条件付出易
さをエントロピー符号化させるパイプライン動作を行
う。
That is, the appearance frequency model unit 10 searches the frequency data storage unit in which the conditional easiness of the input character connected to the immediately preceding character string is registered for each character by the input character, and obtains the conditional easiness. The frequency data storage unit is registered and updated. The entropy encoding unit 12 encodes the input character according to the conditional ease determined by the appearance frequency model unit 10. The pipeline control unit 15 causes the appearance frequency model unit 10 to input a character to determine the conditional ease of appearance, and at the same time, causes the entropy encoding unit 12 to entropy encode the conditional ease of appearance determined for the immediately preceding input character. Perform a pipeline operation.

【0050】この出現頻度モデル部10とエントロピー
符号化部12のパイプライン化により、処理時間を短縮
し、確率統計型符号化を高速化できる。また本発明は、
入力された符号と既に復元されている直前の文字列の条
件付出易さにより文字を復元するデータ復元装置を提供
する。データ復元装置は、エントロピー復号化部46と
出現頻度モデル部48を、パイプライン制御部45によ
ってパイプライン動作させる。
The pipeline of the appearance frequency model unit 10 and the entropy coding unit 12 can shorten the processing time and speed up the probability statistical coding. The present invention also provides
Provided is a data restoring apparatus for restoring a character based on an input code and conditional ease of a character string immediately before being restored. In the data restoration apparatus, the pipeline control unit 45 causes the entropy decoding unit 46 and the appearance frequency model unit 48 to perform a pipeline operation.

【0051】エントロピー復号化部46は、入力された
符号と既に復元されている直前の文字列から条件付出易
さを求める。出現頻度モデル部48は、直前の文字列に
繋がる入力文字の条件付出易さを各文字毎に登録した頻
度データ格納部を入力した符号から求めた条件付出易さ
により検索して文字を復元すると共に、頻度データ格納
部を登録更新する。
The entropy decoding unit 46 obtains conditional ease of appearance from the input code and the character string immediately before being restored. The appearance frequency model unit 48 retrieves the conditional easiness of the input character connected to the immediately preceding character string by the conditional easiness obtained from the input code in the frequency data storage unit registered for each character, and restores the character. At the same time, the frequency data storage unit is registered and updated.

【0052】パイプライン制御部45は、エントロピー
復号化部46で入力した符号の条件付出易さを求めさせ
ると同時に、出現頻度モデル部48に1つ前の符号の条
件付出易さから文字を復元させるパイプライン動作を行
う。このエントロピー復号化部46と出現頻度モデル部
48のパイプライン化により、処理時間を短縮し、確率
統計型復号化を高速化できる。
The pipeline control unit 45 determines the conditional ease of appearance of the code input by the entropy decoding unit 46 and, at the same time, restores the appearance frequency model unit 48 from the conditional ease of appearance of the previous code. Perform a pipeline operation to By making the entropy decoding unit 46 and the appearance frequency model unit 48 into a pipeline, the processing time can be shortened and the probability statistical decoding can be speeded up.

【0053】(ブレンド文脈の一部の並列化) また本発明は、図1(B)のように、ブレンドモデルに
おいて、各次数の出現頻度モデル部の部分を並列化した
データ圧縮装置およびデータ復元装置を提供する。まず
ブレンド文脈を対象としたデータ圧縮装置は、文字を直
前の長い文字列でなる高次文脈から短い文字列でなる低
次文脈へと条件付出易さにより符号化を行うもので、各
次数毎に、例えば0次、1次、及び2次毎に出現頻度モ
デル部88,90,92を並列的に設けている。各次数
毎の出現頻度モデル部88,90,92は、直前の文字
列に繋がる入力文字の条件付出易さを各次数毎に登録し
た頻度データ格納部を有し、各次数における直前の文字
列に繋がる入力文字の条件付出易さを頻度データ格納部
の参照により検索すると共に、頻度データ格納部を登録
更新する。
( Parallelization of Part of Blend Context ) As shown in FIG. 1B, the present invention also provides a data compression apparatus and a data decompression apparatus in which the appearance frequency model part of each order is parallelized in a blend model. Provide equipment. First, a data compression device for blend contexts encodes a character from a high-order context consisting of a long character string immediately before to a low-order context consisting of a short character string with ease of conditional output. For example, appearance frequency model units 88, 90, and 92 are provided in parallel for each of the 0th, 1st, and 2nd orders. The appearance frequency model units 88, 90, and 92 for each order have a frequency data storage unit that registers, for each order, the conditional easiness of the input character connected to the immediately preceding character string. Is searched by referring to the frequency data storage unit, and the frequency data storage unit is registered and updated.

【0054】各次数毎の出現頻度モデル部88,90,
92に続いては、エントロピー符号化部12が設けら
れ、各次数毎の出現頻度モデル部88,90,92から
出力される各次数の条件付出易さを、高次の文脈から低
次の文脈の順に符号化する。更にパイプライン化は、各
次数毎の出現頻度モデル部88,90,92とエントロ
ピー符号化部12とをパイプライン動作させるパイプラ
イン制御部85を設けることで実現する。
The appearance frequency model units 88, 90,
Subsequent to 92, an entropy encoding unit 12 is provided, and the conditional ease of output of each order output from the appearance frequency model units 88, 90, 92 for each order is converted from a higher order context to a lower order context. In order. Further, the pipeline processing is realized by providing a pipeline control unit 85 that performs a pipeline operation of the appearance frequency model units 88, 90, and 92 and the entropy encoding unit 12 for each order.

【0055】ブレンド文脈を対象としたデータ復元装置
は、入力された符号と既に復元されている直前の長い文
字列でなる高次文脈から短い文字列でなる低次文脈の順
に文字を復元する。データ復元装置の並列化は、エント
ロピー復号化部46に続いて各次数毎に、例えば0次、
1次、2次毎の出現頻度モデル部130,132,13
4を並列的に設ける。
The data restoration apparatus for the blend context restores characters in order from a higher-order context consisting of an input code and a long character string just before being restored to a lower-order context consisting of a short character string. The parallelization of the data restoration apparatus is performed for each order following the entropy decoding unit 46, for example, the 0th order,
Primary and secondary appearance frequency model units 130, 132, 13
4 are provided in parallel.

【0056】エントロピー復号化部46は、入力された
符号と既に復元されている各次数の直前の文字列に基づ
き高次文脈から低次文脈の順に条件付出易さを求める。
各次数毎の出現頻度モデル部130,132,134
は、直前の文字列に繋がる入力文字の条件付出易さを各
次数毎に登録した頻度データ格納部を有し、エントロピ
ー復号化部46で求めた自己の次数の条件付出易さか
ら、頻度データ格納部の参照により文字を並列的に復元
する共に、頻度データ格納部を登録更新する。
The entropy decoding unit 46 obtains conditional ease of order from the higher-order context to the lower-order context based on the input code and the character string immediately before each degree already restored.
Appearance frequency model units 130, 132, 134 for each degree
Has a frequency data storage unit in which the degree of conditional appearance of the input character connected to the immediately preceding character string is registered for each degree. From the degree of conditional appearance of the own degree obtained by the entropy decoding unit 46, the frequency data is stored. Characters are restored in parallel by referring to the storage unit, and the frequency data storage unit is registered and updated.

【0057】データ復元装置のパイプライン化は、更
に、エントロピー復号化部46と各次数毎の出現頻度モ
デル部130,132,134とをパイプライン動作さ
せるパイプライン制御部125を設ける。 (ブレンド文脈の全体の並列化) 更に、本発明は、図2(C)のように、ブレンドモデル
において、出現頻度モデル部とエントロピー符号化部の
各々を各次数毎に並列化したデータ圧縮装置及びデータ
復元装置を提供する。
For the pipeline construction of the data restoration apparatus, a pipeline control unit 125 for performing a pipeline operation of the entropy decoding unit 46 and the appearance frequency model units 130, 132, 134 for each order is further provided. ( Parallelization of entire blend context ) Further, as shown in FIG. 2 (C), the present invention provides a data compression device in which, in a blend model, each of an appearance frequency model unit and an entropy encoding unit is parallelized for each degree. And a data restoration device.

【0058】このデータ圧縮装置は、各次数毎に、例え
ば0次、1次、及び2次毎に、出現頻度モデル部16
6、エントロピー符号化部168、及び符号マージ部1
70を独立に設けることで、並列化している。各次数毎
の出現頻度モデル部166は、直前の文字列に繋がる入
力文字の条件付出易さを各次数毎に登録した頻度データ
格納部を有し、各次数における直前の文字列に繋がる入
力文字の条件付出易さを頻度データ格納部の参照により
並列的に検索すると共に、頻度データ格納部を登録更新
する。
The data compression apparatus is provided with an appearance frequency model unit 16 for each order, for example, for each of the 0th, 1st and 2nd orders.
6, entropy coding section 168 and code merging section 1
70 are provided independently to parallelize. The appearance frequency model unit 166 for each order has a frequency data storage unit in which the degree of conditional appearance of the input character connected to the immediately preceding character string is registered for each order, and the input character connected to the immediately preceding character string in each order. Is searched in parallel with reference to the frequency data storage unit, and the frequency data storage unit is registered and updated.

【0059】各次数毎のエントロピー符号化部168
は、出現頻度モデル部166から出力された各次数にお
ける直前の文字列に繋がる入力文字の条件付出易さを並
列的にエントロピー符号化する。符号マージ部170
は、各次数のエントロピー符号部170からの符号をま
とめて出力する。データ圧縮装置のパイプライン化は、
各次数毎に設けられた複数の出現頻度モデル部166と
複数のエントロピー符号化部168を、各次数毎にパイ
プライン動作させるパイプライン制御部175を設け
る。
The entropy encoder 168 for each order
Performs entropy encoding in parallel with the conditional ease of input characters connected to the immediately preceding character string in each degree output from the appearance frequency model unit 166. Code merging section 170
Collectively outputs the codes from the entropy coding unit 170 of each order. Pipelining of data compression equipment
A pipeline control unit 175 is provided for operating a plurality of appearance frequency model units 166 and a plurality of entropy encoding units 168 provided for each order in a pipeline for each order.

【0060】一方、データ復元装置は、符号分離部21
1、各次数毎に独立に設けられたエントロピー復号化部
214、各次数毎に独立に設けられた複数の出現頻度モ
デル部216によって、各次数毎に並列化する。符号分
離部211は、入力された符号を各次数の符号に分離す
る。各次数毎のエントロピー復号化部214は、分離部
211で分離された各次数の符号と既に復元されている
各次数の直前の文字列に基づき各次数の条件付出易さを
求める処理を、各次数毎に並列的に行う。
On the other hand, the data decompression device
1. Parallelization is performed for each order by an entropy decoding unit 214 provided independently for each order and a plurality of appearance frequency model units 216 provided independently for each order. The code separation unit 211 separates the input code into codes of each order. The entropy decoding unit 214 for each order performs a process of obtaining conditional ease of output for each order based on the code of each order separated by the separation unit 211 and the character string immediately before each order already restored. Perform in parallel for each order.

【0061】各次数毎の出現頻度モデル部216は、直
前の文字列に繋がる入力文字の条件付出易さを各次数毎
に登録した頻度データ格納部を有し、各次数毎のエント
ロピー復号化部214で求めた各次数の条件付出易さに
より頻度データ格納部を検索して文字を復元すると共に
頻度データ格納部を登録更新する処理を、各次数毎に並
列的に行う。
The appearance frequency model unit 216 for each order has a frequency data storage unit in which the conditional ease of input characters connected to the immediately preceding character string is registered for each order, and the entropy decoding unit for each order. A process of retrieving the frequency data storage unit and restoring the frequency data storage unit and updating the registration of the frequency data storage unit is performed in parallel for each order based on the conditional ease of each order obtained in 214.

【0062】このデータ復元装置のパイプライン化は、
各次数毎のエントロピー復号化部214と出現頻度モデ
ル部216を、各次数毎にパイプライン動作させるパイ
プライン制御部を設ける。図1(A)(B)及び図2
(C)のデータ圧縮装置及びデータ復元装置の出現頻度
モデル部は、条件付出易さを導くための情報として、順
位、出現数、累積出現数、文脈下の総出現数の検索、登
録、更新を行う。またエントロピー符号化部とエントロ
ピー復号化部は算術符号化と算術復号化を行う。
The data restoration apparatus is pipelined as follows:
A pipeline control unit is provided for operating the entropy decoding unit 214 and the appearance frequency model unit 216 for each order in a pipeline operation for each order. 1 (A) (B) and 2
The appearance frequency model part of the data compression device and the data decompression device of (C) searches, registers, and updates the rank, the number of occurrences, the cumulative number of occurrences, and the total number of occurrences in context as information for guiding conditional ease of appearance. I do. The entropy coding unit and the entropy decoding unit perform arithmetic coding and arithmetic decoding.

【0063】またパイプライン制御部は、出現頻度モデ
ル部における条件付出易さを導くための順位、出現数、
累積出現数、文脈下の総出現数に関する読出、加算、書
込を、各情報ごとにパイプライン処理させる。またパイ
プライン制御部は、算術符号空間を表す上端と下端の演
算を、並列に行う。 (ワードストリーム方向の符号化)また本発明に従え
ば、ワードストリーム方向でのバイト単位の辞書型およ
び確率統計型による符号化と復号化を効率的に行って、
処理時間を実用化レベルに短縮できるデータ圧縮装置お
よびデータ復元装置が提供される。
Further, the pipeline control section determines the order, the number of appearances,
The reading, addition, and writing of the cumulative number of occurrences and the total number of occurrences in context are pipelined for each piece of information. Further, the pipeline control unit performs operations of the upper end and the lower end representing the arithmetic code space in parallel. (Encoding in the Word Stream Direction) According to the present invention, encoding and decoding by the dictionary type and the probability statistical type in byte units in the word stream direction are efficiently performed,
A data compression device and a data decompression device capable of reducing the processing time to a practical level are provided.

【0064】図3はワードストリーム方向での符号化と
復号化の原理説明図である。図3(A)は、複数バイト
で構成されたワードデータをワード単位で符号化するデ
ータ圧縮装置であり、ワードデータをバイト単位に分離
して同じバイト位置毎のバイトデータ列に変換するバイ
ト配列変換部500、バイト配列変換部500で得られ
た各バイト位置毎の入力バイトデータを、符号化を終了
したバイトデータとの条件付出易さにより符号化する複
数のバイト単位符号化部502、及び複数のバイト単位
符号化部502により符号化された各符号をまとめて出
力するマージ部503で構成される。
FIG. 3 is a diagram for explaining the principle of encoding and decoding in the word stream direction. FIG. 3A is a data compression apparatus that encodes word data composed of a plurality of bytes in units of words, and a byte array that separates the word data into units of bytes and converts them into byte data strings at the same byte positions. A plurality of byte encoding units 502 for encoding the input byte data at each byte position obtained by the conversion unit 500 and the byte array conversion unit 500 with conditional ease with the byte data which has been encoded; A merging unit 503 outputs the codes encoded by the plurality of byte unit encoding units 502 at a time.

【0065】2バイトのユニコードや日本語コード、R
GB3バイトのフルカラー画像データ、4バイトや8バ
イトといったプログラムコードを圧縮する符号化におい
て、ワードデータの中の同一バイト位置のバイトデータ
の間には強い相関関係がある。従来のバイトストリーム
方向でのバイト単位の符号化に対し本発明はワードスト
リーム方向でのバイト単位の符号化を行うため、ワード
内の同一バイト位置での相関を符号化に取り込むことが
でき、十分な圧縮効率が期待できる。
Two-byte Unicode, Japanese code, R
In encoding for compressing a program code such as full-color image data of 3 bytes of GB, 4 bytes or 8 bytes, there is a strong correlation between byte data at the same byte position in word data. The present invention performs byte-by-byte encoding in the word stream direction, as opposed to byte-by-byte encoding in the conventional byte stream direction.Therefore, the correlation at the same byte position in the word can be incorporated into the encoding. High compression efficiency can be expected.

【0066】バイト単位符号化部502としては辞書型
符号化部や確率統計型符号化部が用いられる。バイト単
位符号化部502を確率統計型符号化部とした場合、出
現頻度モデル部、エントロピー符号化部及びパイプライ
ン制御部で構成する。ここで文脈のバイト数を固定にす
る文脈固定の場合、出現頻度モデル部は、直前のバイト
データ列に繋がる入力バイトデータの条件付出易さを各
バイトデータ毎に登録した頻度データ格納部を有し、直
前のバイトデータ列に繋がる入力バイトデータの条件付
出易さを頻度データ格納部の参照により検索すると共
に、頻度データ格納部を登録更新する。
As the byte unit encoding unit 502 , a dictionary encoding unit or a probability statistical encoding unit is used. When the byte unit encoding unit 502 is a probability statistical encoding unit, it is configured by an appearance frequency model unit, an entropy encoding unit, and a pipeline control unit. Here, in the case of the context fixed in which the number of bytes of the context is fixed, the appearance frequency model unit has a frequency data storage unit in which the conditional ease of input byte data connected to the immediately preceding byte data string is registered for each byte data. Then, the conditionality of the input byte data connected to the immediately preceding byte data string is searched for by referring to the frequency data storage unit, and the frequency data storage unit is registered and updated.

【0067】エントロピー符号化部は、出現頻度モデル
部で求めた条件付出易さにより入力バイトデータを符号
化する。パイプライン制御部は、出現頻度モデル部とエ
ントロピー符号化部をパイプライン動作させる。またバ
イト単位符号化部502を確率統計型符号化部とし、且
つ直前の字数を固定せずに可変としたブレンド文脈を扱
う場合には、出現頻度モデル部は、直前のバイトデータ
列に繋がる入力バイトデータの条件付出易さを、直前の
高次文脈(長いバイトデータ列)から低次文脈(直前の
短いバイトデータ列)までの各次数毎に登録した頻度デ
ータ格納部を有し、各次数における直前のバイトデータ
列に繋がる入力バイトデータの条件付出易さを頻度デー
タ格納部の参照により検索すると共に、頻度データ格納
部を登録更新する処理を行うために各次数毎に設けられ
る。
The entropy encoding unit encodes the input byte data according to the conditional ease determined by the appearance frequency model unit. The pipeline control unit causes the appearance frequency model unit and the entropy coding unit to perform a pipeline operation. When the byte unit encoding unit 502 is a probability statistical encoding unit and a blend context in which the number of characters immediately before is fixed and variable is used, the appearance frequency model unit includes A frequency data storage unit registered for each degree from the immediately preceding higher-order context (long byte data string) to the lower-order context (shorter immediately preceding byte data string); Is provided for each order in order to retrieve the conditional ease of input byte data connected to the immediately preceding byte data string by referring to the frequency data storage unit and to perform a process of registering and updating the frequency data storage unit.

【0068】またエントロピー符号化部は、複数の出現
頻度モデル部の各次数の条件付出易さを高次の文脈から
低次の文脈の順に符号化する。そしてパイプライン制御
部は、複数の出現頻度モデル部とエントロピー符号化部
をパイプライン動作させる。このようにワードストリー
ム方向の符号化については、並列化とパイプライン化を
図ることで、処理時間を実用化レベルに短縮したデータ
圧縮装置が提供できる。
The entropy encoding unit encodes conditional ease of each order of the plurality of appearance frequency model units in order from a higher-order context to a lower-order context. Then, the pipeline control unit causes the plurality of appearance frequency model units and the entropy coding unit to perform a pipeline operation. As described above, for the encoding in the word stream direction, a data compression device in which the processing time is reduced to a practical level can be provided by achieving parallelization and pipelining.

【0069】図3(A)のデータ圧縮装置で符号化され
た符号からワードデータを復元するデータ復元装置は図
3(B)のように、入力符号列からワードデータの各バ
イト位置の符号を分離する符号分離部530、符号分離
部530で分離された各バイト位置の入力符号と既に復
元されている同一バイト位置のバイトデータの条件付出
易さによりバイトデータを復号する複数のバイト単位復
号化部532、及び複数のバイト単位復号化部532に
より復元された各バイトデータを、バイト位置の順番に
並べてワードデータを出力する切替出力部533で構成
される。
A data decompression device for decompressing word data from a code coded by the data compression device shown in FIG. 3A converts a code at each byte position of word data from an input code string as shown in FIG. 3B. A code separating unit 530 for separation, a plurality of byte-based decoding units for decoding byte data according to the conditional output of the input code of each byte position separated by the code separating unit 530 and the already restored byte data at the same byte position And a switching output unit 533 that outputs the word data by arranging the byte data restored by the plurality of byte unit decoding units 532 in the order of the byte positions.

【0070】このデータ復元装置もデータ圧縮装置に対
応して、バイト単位復号化部532を辞書型復号化部又
は確率統計型復号化部とする。確率統計型復号化部は、
固定文脈の場合、入力された符号と既に復元されている
直前のバイトデータ列から条件付出易さを求めるエント
ロピー復号化部、直前のバイトデータ列に繋がる入力バ
イトデータの条件付出易さを各バイトデータ毎に登録し
た頻度データ格納部を有しエントロピー復号化部で求め
た条件付出易さにより前記頻度データ格納部を検索して
バイトデータを復元すると共に頻度データ格納部を登録
更新する出現頻度モデル部、及びエントロピー復号化部
と出現頻度モデル部をパイプライン動作させるパイプラ
イン制御部で構成される。
This data decompression device also corresponds to the data compression device, and the byte unit decoding unit 532 is a dictionary type decoding unit or a probability statistical type decoding unit. The probability statistical decoding unit
In the case of a fixed context, an entropy decoding unit that determines conditional ease of input from the input code and the immediately preceding byte data string that has already been restored, the conditional ease of input byte data connected to the immediately preceding byte data string in each byte An appearance frequency model that has a frequency data storage unit registered for each data, retrieves the frequency data storage unit based on the conditional ease determined by the entropy decoding unit, restores byte data, and registers and updates the frequency data storage unit And a pipeline control unit that performs a pipeline operation of the entropy decoding unit and the appearance frequency model unit.

【0071】またブレンド文脈の場合には、確率統計型
復号化部は、入力された符号と既に復元されている高次
文脈から低次文脈の各次数における直前のバイトデータ
列に基づき高次文脈から低次文脈の順に条件付出易さを
求めるエントロピー復号化部、直前のバイトデータ列に
繋がる入力バイトデータの条件付出易さを各次数毎に登
録した頻度データ格納部を有しエントロピー復号化部で
求めた各次数の条件付出易さから頻度データ格納部の参
照によるバイトデータを復元すると共に頻度データ格納
部を登録更新する処理を行う各次数毎に設けられた複数
の出現頻度モデル部、及びエントロピー復号化部と複数
の出現頻度モデル部をパイプライン動作させるパイプラ
イン制御部で構成される。
In the case of the blend context, the probability statistic type decoding unit uses the input code and the already restored higher-order context to extract the higher-order context based on the immediately preceding byte data string in each order of the lower-order context. And an entropy decoding unit having a frequency data storage unit in which the conditional ease of input byte data connected to the immediately preceding byte data string is registered for each degree in order of low order context from A plurality of appearance frequency model units provided for each order for performing a process of restoring byte data by referring to the frequency data storage unit from the conditional easiness of each order obtained in the above and registering and updating the frequency data storage unit; and It is composed of an entropy decoding unit and a pipeline control unit that performs a pipeline operation of a plurality of appearance frequency model units.

【0072】確率統計型符号化として算術符号化を採用
した場合、データ圧縮装置及びデータ復元装置における
前記出現頻度モデル部は、条件付出易さを導くための情
報として、順位、出現数、累積出現数、文脈下の総出現
数の検索、登録、更新を行う。またエントロピー符号化
部とエントロピー復号化部は算術符号化と算術復号化を
行う。 (ワードストリーム方向とバイトストリーム方向の符号
化復号化の切替え)図4はワードストリーム方向とバイ
トストリーム方向でのバイト単位の符号化復号化を適応
的に切り替える場合の原理説明図である。
When arithmetic coding is employed as the probability statistical coding, the appearance frequency model section in the data compression device and the data decompression device includes the rank, the number of occurrences, and the cumulative occurrences as information for guiding conditional easiness. Search, register, and update the number and total number of occurrences in context. The entropy coding unit and the entropy decoding unit perform arithmetic coding and arithmetic decoding. (Switching between Encoding and Decoding in Word Stream Direction and Byte Stream Direction) FIG. 4 is a diagram illustrating the principle of adaptively switching encoding and decoding in byte units in the word stream direction and the byte stream direction.

【0073】図4(A)は複数バイトで構成されたワー
ドデータをワード単位で符号化するデータ圧縮装置であ
り、バイト配列変換部600、ワードストリーム符号化
部602、バイトストリーム符号化部604、符号切替
部605で構成される。バイト配列変換部600は、入
力ワードデータをバイトデータに分離した後にワードス
トリーム方向とバイトストリーム方向の複数ワード分の
二次元配列に変換し、この二次元配列を複数ワード分
(文脈の次数分)保持する。
FIG. 4A shows a data compression apparatus which encodes word data composed of a plurality of bytes in units of words, and includes a byte array conversion section 600, a word stream encoding section 602, a byte stream encoding section 604, It comprises a code switching unit 605. The byte array conversion unit 600 separates the input word data into byte data and then converts the input word data into a two-dimensional array for a plurality of words in the word stream direction and the byte stream direction, and converts this two-dimensional array for a plurality of words (an order of context). Hold.

【0074】ワードストリーム符号化部602は、バイ
ト配列変換部600による二次元配列のワードストリー
ム方向における入力ワードの各バイトデータを、符号化
を終了したワードデータ群の同一バイト位置のバイトデ
ータとの条件付出易さにより符号化してワードストリー
ム符号を生成する。これは図3のデータ圧縮装置に相当
する。
The word stream encoding unit 602 converts each byte data of the input word in the word stream direction of the two-dimensional array by the byte array conversion unit 600 with the byte data at the same byte position of the encoded word data group. A word stream code is generated by encoding according to conditional ease. This corresponds to the data compression device in FIG.

【0075】バイトストリーム符号化部604は、バイ
ト配列変換部600による二次元配列のバイトストリー
ム方向における入力ワードの各バイトデータを、先行す
るバイトデータとの条件付出易さにより符号化してバイ
トストリーム符号を生成する。これはバイトデータの並
びをそのまま取り入れてバイト単位に符号化する従来の
データ圧縮装置に相当する。
The byte stream encoding section 604 encodes each byte data of the input word in the byte stream direction of the two-dimensional array by the byte array conversion section 600 according to the conditional ease with the preceding byte data to perform byte stream encoding. Generate This is equivalent to a conventional data compression device that takes in the byte data sequence as it is and encodes it in byte units.

【0076】符号切替部605は、ワードストリーム符
号とバイトストリーム符号のどちらかを切替え出力す
る。例えば、符号切替部605は、ワードストリーム符
号とバイトストリーム符号の相関の強さに基づいて符号
出力を切り替える。またワードストリーム符号とバイト
ストリーム符号の内、符号長の短い方を選択する。符号
切替部605は、ワードストリーム符号とバイトストリ
ーム符号を、バイト単位に切替え出力する。また符号切
替部605は、ワードストリーム符号とバイトストリー
ム符号を、ワード単位に切替え出力することもできる。
更に、符号切替部は、ワードストリーム符号とバイトス
トリーム符号の切替毎に、切替符号を付加する。
The code switching unit 605 switches and outputs either a word stream code or a byte stream code. For example, the code switching unit 605 switches the code output based on the strength of the correlation between the word stream code and the byte stream code. Further, a shorter code length is selected from the word stream code and the byte stream code. The code switching unit 605 switches and outputs the word stream code and the byte stream code in byte units. The code switching unit 605 can also switch and output the word stream code and the byte stream code in word units.
Further, the code switching unit adds a switching code every time switching between the word stream code and the byte stream code.

【0077】符号切替部605は、ワードストリーム符
号とバイトストリーム符号の切替符号として、過去の各
符号の出現頻度に基づく切替符号を用いる。図4(B)
は、図4(A)のデータ圧縮装置による符号からワード
データを復元するデータ復元装置の原理説明図であり、
符号分離部700、ワードストリーム復号化部702、
バイトストリーム復号化部704及び出力切替部706
で構成される。
The code switching unit 605 uses a switching code based on the frequency of occurrence of each past code as a switching code between the word stream code and the byte stream code. FIG. 4 (B)
FIG. 4 is a diagram illustrating the principle of a data decompression device that decompresses word data from a code by the data compression device of FIG.
A code separation unit 700, a word stream decoding unit 702,
Byte stream decoding unit 704 and output switching unit 706
It consists of.

【0078】符号分離部700は、符号列を入力して1
ワードの各バイト位置のワードストリーム符号又はバイ
トストリーム符号に分離する。ワードストリーム復号化
部702は、分離部700で分離されたワードストリー
ム符号と既に復元されている同一バイト位置のバイトデ
ータの条件付出易さによりバイトデータを復号する。バ
イトストリーム復号化部704は、符号分離部700で
分離されたバイトストリーム符号と既に復元されている
先行するバイトデータの条件付出易さによりバイトデー
タを復号する。出力切替部706は、ワードストリーム
復号化部702又はバイトストリーム復号化部704で
復号された各バイトデータをバイト位置の順に結合して
復元したワードデータを出力する。
The code separation section 700 receives the code string and
Separate word stream code or byte stream code at each byte position of the word. The word stream decoding unit 702 decodes the byte data according to the conditional ease of byte data at the same byte position that has already been restored and the word stream code separated by the separation unit 700. The byte stream decoding unit 704 decodes the byte data according to the conditional ease of the byte stream code separated by the code separation unit 700 and the previously restored preceding byte data. The output switching unit 706 combines the byte data decoded by the word stream decoding unit 702 or the byte stream decoding unit 704 in the order of the byte positions, and outputs the restored word data.

【0079】図3のワードストリーム方向での符号化に
よれば、2バイトのユニコードや日本語コード、RGB
3バイトのフルカラー画像データ、4バイトや8バイト
といったプログラコード等の多バイトのワードデータの
符号化については、圧宿効率の向上が期待できる。しか
し、ワードデータによっては、従来のバイトストリーム
方向での符号化の方が圧縮効率が高くなる場合があり、
一義的に決められない場合がある。
According to the encoding in the word stream direction in FIG. 3, 2-byte Unicode, Japanese code, RGB
With regard to encoding of 3-byte full-color image data, multi-byte word data such as 4-byte and 8-byte program codes, etc., an improvement in compression efficiency can be expected. However, depending on the word data, the encoding efficiency in the conventional byte stream direction may be higher in compression efficiency,
There are cases where it cannot be decided uniquely.

【0080】そこで、同じバイトデータにつきワードス
トリーム方向とバイトストリーム方向を各々行ない、圧
縮効率の高いの符号を適応的に選択することで、さらに
圧縮効率を高めることができる。
Therefore, the compression efficiency can be further increased by performing the word stream direction and the byte stream direction for the same byte data and adaptively selecting a code having a high compression efficiency.

【0081】[0081]

【発明の実施の形態】BEST MODE FOR CARRYING OUT THE INVENTION

<目次> 1.固定次数文脈のパイプライン処理 2.ブレンド文脈の一部の並列化 3.ブレンド文脈の全体の並列化 4.ハッシュ構造による頻度データのアクセス 5.ワードストリーム方向での符号化復号化 6.ワードストリーム方向とバイトストリーム方向の適
応切替処理 1.固定次数文脈のパイプライン処理 図5は本発明による確率統計型のデータ圧縮装置の基本
構成である。データ圧縮装置は図5(A)のように、出
現頻度モデル部10、エントロピー符号化部12で構成
され、パイプライン制御部11によって出現頻度モデル
部10とエントロピー符号化部12がパイプライン処理
を行うように制御される。
<Table of Contents> 1. Pipeline processing in fixed order context 2. Parallelizing a part of the blend context 3. Overall blend context parallelization 4. Access to frequency data using hash structure 5. Coding and decoding in the word stream direction Adaptive switching process in word stream direction and byte stream direction Pipeline Processing in Fixed-Order Context FIG. 5 shows the basic configuration of a probability statistical data compression apparatus according to the present invention. As shown in FIG. 5A, the data compression device includes an appearance frequency model unit 10 and an entropy encoding unit 12, and the pipeline control unit 11 causes the appearance frequency model unit 10 and the entropy encoding unit 12 to perform pipeline processing. Controlled to do so.

【0082】出現頻度モデル部10はソースデータとし
て準備された文字列の先頭文字を入力し、直前の文字列
につながる入力文字の条件付出易さを検索する。即ち、
出現頻度モデル部10には直前の文字列につながる入力
文字の条件付出易さを各文字ごとに登録した頻度データ
格納部が設けられており、ソースデータから入力した文
字により頻度データ格納部を検索して、対応する入力文
字の条件付出易さを求める。入力文字の条件付出易さが
検索できたならば、頻度データ格納部の内容を登録更新
する。エントロピー符号化部12は、出現頻度モデル部
10で求めた入力文字の条件付出易さをエントロピー符
号化する。エントロピー符号化部12による符号化とし
ては、多値算術符号化や動的ハフマン符号化、あるいは
自己組織符号化の一種であるスプレイ符号化などを行
う。
The appearance frequency model section 10 inputs the first character of a character string prepared as source data, and searches for the conditional ease of input characters connected to the immediately preceding character string. That is,
The appearance frequency model unit 10 is provided with a frequency data storage unit that registers the conditional ease of input characters connected to the immediately preceding character string for each character, and searches the frequency data storage unit based on characters input from source data. Then, a conditional ease of appearance of the corresponding input character is obtained. If the conditional ease of input characters can be searched, the content of the frequency data storage unit is registered and updated. The entropy coding unit 12 performs entropy coding of the conditional ease of input characters obtained by the appearance frequency model unit 10. As the encoding by the entropy encoding unit 12, multi-level arithmetic encoding, dynamic Huffman encoding, or spray encoding, which is a type of self-organizing encoding, is performed.

【0083】図5(B)は、パイプライン制御部11に
よる出現頻度モデル部10及びエントロピー符号化部1
2のパイプライン動作を示している。ここで時間軸はタ
イムサイクルT1,T2,T3で示されている。いまソ
ースデータから文字a,b,a・・・を入力した場合を
考える。まず先頭文字aはT1サイクルで出現頻度モデ
ル部10に入力され、入力文字aの条件付出易さが求め
られる。次のT2サイクルにあっては、2つ目の文字b
が出現頻度モデル部10に入力されて条件付出易さが求
められると同時に、T1サイクルで求められた最初の文
字aの条件付出易さがエントロピー符号化部12に与え
られ、入力文字aの頻度のエントロピー符号化が行われ
る。
FIG. 5B shows the appearance frequency model unit 10 and the entropy coding unit 1 by the pipeline control unit 11.
2 illustrates a pipeline operation. Here, the time axis is shown by time cycles T1, T2, and T3. Now, consider a case where characters a, b, a... Are input from source data. First, the leading character a is input to the appearance frequency model unit 10 in a T1 cycle, and the conditional appearance of the input character a is determined. In the next T2 cycle, the second letter b
At the same time but has been ease out conditionally input to the occurrence frequency modeling unit 10 is required, conditional Deeki of the first character a obtained in T1 cycle is given to the entropy coding unit 12, the frequency of the input character a Is performed.

【0084】以下同様にして、出現頻度モデル部10で
1文字を入力して条件付出易さを求めると同時に、エン
トロピー符号化部12で前回出現頻度モデル部10で求
めた条件付出易さのエントロピー符号化を同時に並行し
て行う。このように出現頻度モデル部10及びエントロ
ピー符号化部12がパイプライン制御部11により独立
にパイプライン動作することから、文字列の確率統計型
による符号化をより高速に行うことができる。
In the same manner, the appearance frequency model unit 10 inputs one character to determine conditional ease of appearance, and at the same time, the entropy encoding unit 12 determines the entropy of the conditional ease of appearance previously determined by the appearance frequency model unit 10. The encoding is performed simultaneously and in parallel. As described above, since the appearance frequency model unit 10 and the entropy encoding unit 12 operate independently of the pipeline by the pipeline control unit 11, encoding of the character string by the probability statistical type can be performed at higher speed.

【0085】図6は、図5のデータ圧縮装置について算
術符号化を適用した本発明のデータ装置の実施形態であ
る。算術符号化を適用した場合には、データ圧縮装置は
確率モデル部14、算術符号化部16及びパイプライン
制御部15で構成される。確率モデル部14は、例えば
ソースデータとしての文字列から例えば1文字ずつa,
b,a,・・・を入力し、各入力文字ごとに入力文字の
条件付出易さである確率(出現頻度=正規化出現数)を
求める。
FIG. 6 shows an embodiment of the data device of the present invention in which arithmetic coding is applied to the data compression device of FIG. When arithmetic coding is applied, the data compression device includes a probability model unit 14, an arithmetic coding unit 16, and a pipeline control unit 15. The probability model unit 14 outputs, for example, a, a,
.. are input, and the probability (appearance frequency = normalized number of appearances) of the conditional appearance of the input character is calculated for each input character.

【0086】具体的には、確率モデル部14には頻度デ
ータ格納部が設けられ、この頻度データ格納部には各文
字の出現数の順番に並べられた登録番号即ち順位に従っ
て、各順位ごとに文字シンボル、出現数、累積出現数を
登録し、更に総出現数を格納している。このため入力文
字aで頻度データ格納部を検索し、入力文字aに対応す
る条件付き確率として順位を求め、算術符号化部16に
出力する。
More specifically, the probability model unit 14 is provided with a frequency data storage unit. The frequency data storage unit is provided for each rank in accordance with the registration numbers or ranks arranged in the order of the number of appearances of each character. The character symbol, the number of appearances, and the cumulative number of appearances are registered, and the total number of appearances is stored. For this reason, the frequency data storage unit is searched for the input character a, a rank is obtained as a conditional probability corresponding to the input character a, and the rank is output to the arithmetic coding unit 16.

【0087】同時に、算術符号化での出現頻度、累積出
現頻度の算出に使用する入力文字の出現数、累積出現数
及び総出現数を出力する。算術符号化部16は多値算術
符号化を行う。具体的には、確率モデル部14より出力
された入力文字の条件付き確率である順位の算術符号化
を行う。条件付き確率である入力文字の順位の算術符号
化とは、数直線[1,0]の符号空間を初期空間とし
て、入力文字の順位に対応する出現頻度と累積出現頻度
から前回の符号空間における入力文字の割当空間を算出
し、算出した空間を示す適宜の値を符号として出力す
る。
At the same time, the appearance frequency, the cumulative appearance frequency, and the total appearance frequency of the input characters used for calculating the appearance frequency and the accumulated appearance frequency in the arithmetic coding are output. The arithmetic coding unit 16 performs multi-level arithmetic coding. More specifically, arithmetic coding of a rank, which is a conditional probability of an input character output from the probability model unit 14, is performed. Arithmetic encoding of the rank of an input character, which is a conditional probability, means that the code space of the number line [1,0] is used as an initial space, and the appearance frequency and the cumulative appearance frequency corresponding to the rank of the input character in the previous code space are used. An assigned space for the input character is calculated, and an appropriate value indicating the calculated space is output as a code.

【0088】図6の例では、1文字ごとに符号を生成し
て圧縮データとして出力している。具体的には、入力文
字aについては確率モデル部14で順位1位が求めら
れ、これを算術符号化部16で符号化することで符号0
1を出力する。次の文字bについては、確率モデル部1
4で順位2位が求められ、これを算術符号化部16で符
号化して符号1001を出力する。更に3文字目aにつ
いては、1文字目と同様、順位1位を算術符号化して符
号01を出力する。
In the example of FIG. 6, a code is generated for each character and output as compressed data. Specifically, for the input character a, the first place is obtained by the probability model unit 14, and this is encoded by the arithmetic encoding unit 16 to obtain the code 0.
Outputs 1. For the next character b, the probability model unit 1
4, the second place is obtained. This is coded by the arithmetic coding unit 16 and the code 1001 is output. Further, as for the third character a, the first place is arithmetically coded and the code 01 is output, similarly to the first character.

【0089】実際の装置にあっては、所定バイト数の文
字例えば8バイトの複数文字を1グループとして、先頭
文字から順番に順位に対応した符号空間を求め、最終文
字について算出された符号空間を表わす値を符号として
出力する処理が行われる。図6(B)は、パイプライン
制御部15による確率モデル部14と算術符号化部16
のパイプライン処理の動作である。まずT1サイクルに
あっては、先頭文字aを入力して確率モデル部14でそ
の条件付き確率である順位1位を求める。このとき算術
符号化部16にあっては、前回の順位がないことから符
号化を行わない。
In an actual apparatus, a code space corresponding to the order is determined in order from the first character, with a plurality of characters of a predetermined number of bytes, for example, a plurality of characters of 8 bytes as one group. A process of outputting the represented value as a code is performed. FIG. 6B shows the probability model unit 14 and the arithmetic coding unit 16 by the pipeline control unit 15.
This is the operation of the pipeline processing. First, in the T1 cycle, the leading character a is input, and the probability model unit 14 obtains the first place of the conditional probability. At this time, the arithmetic encoding unit 16 does not perform encoding because there is no previous ranking.

【0090】次のT2サイクルにあっては、2文字目b
を入力して確率モデル部14で順位2位を求め、同時に
算術符号化部16で前サイクルで求めた入力文字aの順
位1位の算術符号化を行い、符号01を出力する。次の
T3サイクルにあっては、1文字目と同じ文字aを入力
して、確率モデル部14でその順位1位を求め、同時に
前サイクルT2で求めた文字bの順位2位の符号化を算
術符号化部16で行って符号1001を出力する。以下
同様にして、確率モデル部14で1文字を入力して順位
を求めると同時に、算術符号化部16で前サイクルで求
めた順位を算術符号化する処理を繰り返す。
In the next T2 cycle, the second character b
Is input, the probability model unit 14 obtains the second place, and the arithmetic coding unit 16 performs the arithmetic coding of the first place of the input character a obtained in the previous cycle, and outputs the code 01. In the next T3 cycle, the same character a as the first character is input, and the first place is obtained by the probability model unit 14, and at the same time, the encoding of the second place of the character b obtained in the previous cycle T2 is performed. The arithmetic operation is performed by the arithmetic coding unit 16 to output a code 1001. In the same manner, a process of inputting one character in the probability model unit 14 to obtain a rank and simultaneously performing arithmetic coding of the rank obtained in the previous cycle by the arithmetic coding unit 16 are repeated.

【0091】図7は図6の算術符号化を用いたデータ圧
縮装置の詳細構成のブロック図である。図7において、
データ圧縮装置は確率モデル部14、算術符号化部16
で構成され、両者はパイプライン制御部15によってパ
イプライン制御される。確率モデル部14には順位読出
更新部18、文字読出更新部20、頻度読出更新部2
2、累積頻度読出更新部24、総累積頻度読出更新部2
6、更に頻度データ格納部25が設けられている。また
算術符号化部16には、符号空間の上端(ハイレベル)
を算出する符号空間算出部28、符号空間の下端(ロー
レベル)を算出する符号空間算出部30、及び符号出力
部36が設けられている。
FIG. 7 is a block diagram showing the detailed configuration of the data compression apparatus using the arithmetic coding shown in FIG. In FIG.
The data compression device includes a probability model unit 14, an arithmetic coding unit 16
, And both are pipeline-controlled by the pipeline control unit 15. The probability model unit 14 includes a rank read / update unit 18, a character read / update unit 20, and a frequency read / update unit 2.
2. Cumulative frequency read / update unit 24, total cumulative frequency read / update unit 2
6. Further, a frequency data storage unit 25 is provided. The arithmetic coding unit 16 has an upper end (high level) of the code space.
, A code space calculation unit 30 for calculating the lower end (low level) of the code space, and a code output unit 36.

【0092】まず確率モデル部14の頻度データ格納部
25には、例えば図8のような頻度データが格納されて
いる。図8において、頻度データ格納部25は文字シン
ボルK1〜256出現数の大い順位1〜256に並べ
て登録している。この順位と文字シンボルの登録構造
は、図70の従来装置に示した辞書416の部分に相当
する。同時に順位1〜256に対応して文字K1〜K2
56の出現数f(1)〜f(256)を登録している。
更に、各文字について累積出現数cf(1)〜cf(2
56)を登録している。このように頻度データ格納部2
5は、出現数と累積出現数を登録していることから、出
現頻度は、 頻度=出現数/総出現数 として求められる。また累積頻度も 累積頻度=累積出現数cf(s)/総出現数S0 として求められる。尚、通常の算術符号化のアルゴリズ
ムにあっては、出現数はfreq( )で表わされ、ま
た累積出現数はcum freq( )で表わされる
が、図8でそれぞれf( ),cf( )と簡略化して
いる。
First, frequency data as shown in FIG. 8, for example, is stored in the frequency data storage unit 25 of the probability model unit 14. In FIG. 8, the frequency data storage unit 25 registers the character symbols K <b> 1 to K <b> 256 in order of the largest number of occurrences 1 to 256. The order and character symbol registration structure correspond to the dictionary 416 shown in the conventional device of FIG. At the same time, characters K1 to K2 corresponding to ranks 1 to 256
The number of appearances f (1) to f (256) of 56 are registered.
Further, the cumulative appearance numbers cf (1) to cf (2
56) is registered. Thus, the frequency data storage unit 2
In No. 5, since the number of appearances and the cumulative number of appearances are registered, the appearance frequency is obtained as frequency = number of appearances / total number of appearances. The cumulative frequency is also obtained as cumulative frequency = cumulative number of appearances cf (s) / total number of appearances S0. In the ordinary arithmetic coding algorithm, the number of appearances is represented by freq (), and the cumulative number of occurrences is represented by cum freq (). In FIG. 8, f () and cf () are respectively used. It has been simplified.

【0093】再び図7を参照するに、確率モデル部14
の順位読出更新部18は、文字列からその先頭文字を入
力するごとに頻度データ格納部25を参照し、入力文字
に該当する登録文字を検索する。この文字検索結果は文
字読出更新部20に与えられる。文字読出更新部20
は、検索された入力文字に対応する頻度データ格納部2
5の辞書登録番号である順位を読み出す。
Referring again to FIG. 7, the probability model unit 14
The order reading / updating unit 18 refers to the frequency data storage unit 25 every time the first character is input from the character string, and searches for a registered character corresponding to the input character. This character search result is provided to the character reading / updating unit 20. Character reading and updating unit 20
Is a frequency data storage unit 2 corresponding to the searched input characters.
5 is read as the dictionary registration number.

【0094】更に順位読出更新部18による検索結果
は、頻度読出更新部22、累積頻度読出更新部24にも
与えられ、頻度データ格納部25より検索した文字に対
応する出現数f( )及び累積出現数f( )を読み出
す。更に総累積頻度読出更新部26は、そのときの総出
現数cf(0)=S0 を読み出す。このようにして確率
モデル部14で入力文字に対応して頻度データ格納部2
5から読み出された入力文字の順位、出現数、累積出現
数及び総出現数は、算術符号化部16に与えられる。
Further, the search result by the rank reading / updating unit 18 is also given to the frequency reading / updating unit 22 and the cumulative frequency reading / updating unit 24, and the number of appearances f () corresponding to the character searched from the frequency data storage unit 25 and the cumulative Read the number of appearances f (). Further, the total cumulative frequency reading / updating unit 26 reads out the total number of appearances cf (0) = S0 at that time. In this manner, the frequency data storage unit 2 corresponding to the input character is
The rank, the number of appearances, the cumulative number of appearances, and the total number of appearances of the input characters read from 5 are given to the arithmetic encoding unit 16.

【0095】また入力文字に基づく頻度データの読出出
力が済むと、順位読出更新部18、文字読出更新部2
0、頻度読出更新部22、累積頻度読出更新部24及び
総累積頻度読出更新部26のそれぞれで頻度データ格納
部25の更新を行う。具体的には、入力文字の出現数に
1を加えた後に、出現数の大きい順番に文字出現数及び
累積出現数の並び替えを行う。
When the frequency data based on the input characters has been read out and output, the order reading and updating unit 18 and the character reading and updating unit 2
The frequency data storage unit 25 is updated by each of the frequency read / update unit 22, the cumulative frequency read / update unit 24, and the total cumulative frequency read / update unit 26. Specifically, after adding 1 to the number of appearances of the input characters, the number of characters and the number of cumulative occurrences are rearranged in the descending order of the number of appearances.

【0096】算術符号化部16は、確率モデル部14よ
り出力された入力文字の順位sの出現数f(s)と累積
出現数cf(s)及び総出現数cf(0 )=S0 から、
前回の符号空間に対する今回の入力文字の割当空間を新
たな符号空間として算出する。例えば図6の順位sとな
る入力文字について、出現数f(s)及び累積頻度f
(s)、更に総出現数S0 が確率モデル部14から与え
られたとすると、入力文字Ksの順位sより1つ上位の
順位s−1の累積出現数cf(s-1 )を読み出し、入力
文字sの割当区間となる新区間の区間幅Wnew、上限
(ハイレベル)Hnew、及び下限(ローレベル)Ln
ewを算出する。
The arithmetic coding unit 16 calculates the number of occurrences f (s), the cumulative number of occurrences cf (s), and the total number of occurrences cf (0) = S0 of the rank s of the input character output from the probability model unit 14 by using
The allocation space of the current input character with respect to the previous code space is calculated as a new code space. For example, for the input character having the rank s in FIG. 6, the number of appearances f (s) and the cumulative frequency f
(S) Further, assuming that the total number of appearances S0 is given from the probability model unit 14, the cumulative appearance number cf (s-1) of the rank s-1 which is one rank higher than the rank s of the input character Ks is read, and the input character Ks is read. The section width Wnew, the upper limit (high level) Hnew, and the lower limit (low level) Ln of the new section to be the assigned section of s
ew is calculated.

【0097】まず次の(1)式に従って前回の区間幅W
oldを算出する。最初の1文字の場合、前回の区間幅
Woldは初期値1.0を使用する。 Wold =(Hold −Lold)+1 (1) 但し、Wold は前回の区間幅(レンジ) Hold は前回の上端(ハイレベル) Lold は前回の下端(ローレベル) この(1)式で算出された区間幅に基づいて、新区間の
上端(ハイレベル)Hnewと下端(ローレベル)Ln
ewを次の(2)(3)式で算出する。 Hnew =Lold +{Wold ×cf(s-1) /S0 }−1 (2) 但し、Hnew は今回の上端(ハイレベル) cf(s-1) は1つ上の順位s-1 の累積出現数 So は総出現数 Lnew =Lold +{Wold ×cf(s) /S0 } (3) 但し、Hnew は今回の上端(ハイレベル) cf(s) は1つ上の順位sの累積出現数 So は総出現数 この(1)式、(2)式に従った符号空間におけるハイ
レベル(Hnew)の算出は、符号空間算出部28で行
われる。また(1)式及び(3)式に従った符号空間の
ローレベル(Lnew)の算出は、符号空間算出部30
で行われる。つまり新たな符号空間のハイレベルとロー
レベルが2つの符号空間算出部28,30によって並列
的に算出される。
First, the previous section width W is calculated according to the following equation (1).
Old is calculated. In the case of the first character, the previous section width Wold uses the initial value 1.0. Wold = (Hold−Lold) +1 (1) where Wold is the previous section width (range) Hold is the previous upper end (high level) Lold is the previous lower end (low level) The section calculated by this equation (1) Based on the width, the upper end (high level) Hnew and the lower end (low level) Ln of the new section
ew is calculated by the following equations (2) and (3). Hnew = Lold + {Wold × cf (s-1) / S0} -1 (2) where Hnew is the current upper end (high level) cf (s-1) is the cumulative appearance of the next higher rank s-1 The number So is the total number of occurrences Lnew = Lold + {Wold * cf (s) / S0} (3) where Hnew is the current upper end (high level) cf (s) is the cumulative number of occurrences of the next higher rank s So Is the total number of appearances. The calculation of the high level (Hnew) in the code space according to the equations (1) and (2) is performed by the code space calculation unit 28. The calculation of the low level (Lnew) of the code space according to the expressions (1) and (3) is performed by the code space calculation unit 30.
Done in That is, the high level and the low level of the new code space are calculated in parallel by the two code space calculation units 28 and 30.

【0098】符号空間算出部28,30における除算を
簡単にするため、逆数算出部32において総累積頻度読
出更新部26より出力された総出現数S0 の逆数1/S
0 が算出される。この逆数1/S0 の算出により符号空
間算出部28,30における(2)式、(3)式の除算
を乗算の形で行うことで高速化できる。符号空間算出部
28,30で算出された入力文字aの割当空間のハイレ
ベル及びローレベルは、算術符号導出部34に与えられ
る。算術符号導出部34は図9に示すような符号空間の
上端と下端を示すビット情報を生成する。即ち図10の
ように、前回の符号化区間を[1.0]として正規化
し、この区間[1,0]に閾値1/4,1/2,3/4
を設定して4つの区間に分割する。
In order to simplify the division in the code space calculators 28 and 30, the reciprocal 1 / S of the total number of appearances S0 output from the total cumulative frequency reading / updating unit 26 in the reciprocal calculator 32 is calculated.
0 is calculated. By calculating the reciprocal 1 / S0, the speed can be increased by performing the division of the expressions (2) and (3) in the code space calculation units 28 and 30 in the form of multiplication. The high level and low level of the assigned space of the input character a calculated by the code space calculation units 28 and 30 are given to the arithmetic code derivation unit 34. The arithmetic code deriving unit 34 generates bit information indicating the upper and lower ends of the code space as shown in FIG. That is, as shown in FIG. 10, the previous encoding section is normalized as [1.0], and this section [1,0] is thresholded by 1/4, 1/2, 3/4.
Is set and divided into four sections.

【0099】この分割された区間[1,0]について新
たに算出された入力符号の割当区間のハイレベルとロー
レベルがどの分割区間に存在するかを符号化する。即
ち、算出されたハイレベルとローレベルについて次の2
つの条件で符号化する。 <条件>1/2以上でビット1とし、1/2を下回っ
たらビット0とする。
For each of the divided sections [1, 0], an encoding is performed to determine which of the divided sections has the high level and the low level of the newly calculated input code allocation section. That is, the calculated high level and low level are as follows.
Encode with two conditions. <Condition> Bit 1 is set when the value is 1/2 or more, and bit 0 is set when the value falls below 1/2.

【0100】<条件> 1/4以上で3/4以下の範囲にあればビット1とし、
この範囲を外れていればビット0とする。図10は正規
化区間[1,0]に対し、算出された符号化区間の割当
範囲を太線で表わしている。まず符号空間38−1,3
8−2,38−3,38−4はハイレベルが1.0であ
り、ローレベルが分割空間に上から順番に存在した場合
である。この場合の出力符号は4ビットb0 ,b1 ,b
2 ,b3 で表わされ、図示の値をとる。例えば符号空間
38−1を例にとると、まずハイレベルは1.0であ
り、条件から1/2以上であることからb0 =1とな
る。
<Condition> Bit 1 is set if it is in the range of not less than 1/4 and not more than 3/4,
If it is out of this range, bit 0 is set. FIG. 10 shows the allocation range of the calculated coding section with respect to the normalized section [1, 0] by a thick line. First, the code space 38-1,3
8-2, 38 -3,38-4 the high level is 1.0, is when the low level is present in order from top to divided space. The output code in this case is 4 bits b0, b1, b
2 and b3 and take the values shown. For example, taking the code space 38-1 as an example, first, the high level is 1.0, and since it is 1/2 or more from the condition, b0 = 1.

【0101】また条件から1/4以上で3/4以下の
範囲を外れていることからb1 =0となる。次にローレ
ベルについては、条件から1/2以上であることから
b2=1となり、条件から1/4以上で3/4以下の
範囲を外れていることからb3 =0となる。符号空間3
8−2については、同様にしてb0 b1 b2 b3 =10
11となる。符号空間38−3については、b0 b1 b
2 b3 =1001となる。更に符号空間38−4につい
ては、b0 b1 b2 b3 =1000となる。なお符号空
間38−1〜38−4についてはハイレベルを1.0と
しているが、ハイレベルが1〜3/4にあれば同じ出力
符号となる。
Since the condition is outside the range of not less than 1/4 and not more than 3/4, b1 = 0. Next, for the low level, b2 = 1 because it is 1/2 or more from the condition, and b3 = 0 because it is outside the range of 1/4 or more and 3/4 or less from the condition. Code space 3
For 8-2, similarly, b0 b1 b2 b3 = 10
It becomes 11. For the code space 38-3, b0 b1 b
2b3 = 1001. Further, for the code space 38-4, b0 b1 b2 b3 = 1000. Although the high level is set to 1.0 for the code spaces 38-1 to 38-4, the same output code is obtained if the high level is 1 to 3/4.

【0102】符号空間40−1〜40−3はハイレベル
を3/4としてローレベルを下位の分割空間に順番に存
在した場合である。この場合、ハイレベルの出力符号b
0b1は全て11であり、ローレベルの符号b2 b3 が
11,01,00と変化している。符号空間40−1,
40−2は、ハイレベルが1/2でローレベルが下側の
分割空間に順番に存在した場合である。この場合、ハイ
レベルの出力符号b0 b1は01であり、ローレベルの
出力符号b2 b3 が01,00となる。既に符号空間4
4は1/4〜0の範囲にハイレベルとローレベルの両方
が存在した場合であり、この場合には出力符号b0〜b
3は全て0となる。
In the code spaces 40-1 to 40-3, the high level is / and the low level is present in the lower divided space in order. In this case, the high-level output code b
All 0b1 are 11, and the low level code b2 b3 changes to 11,01,00. Code space 40-1,
40-2 is a case where the high level is 1 / and the low level is present in the lower divided space in order. In this case, the high-level output code b0 b1 is 01, and the low-level output code b2 b3 is 01,00. Code space 4 already
4 is a case where both the high level and the low level exist in the range of 1/4 to 0, and in this case, the output codes b0 to b
All 3 are 0.

【0103】図10の分割符号空間との比較による算術
符号の領域に対応して、図9の出力符号の下端及び上端
は図示のように1/2レンジ判定ビット、1/4〜3/
4レンジ判定ビットを組み合わせた4ビット情報とな
る。次に図11のタイムチャートを参照して図7のデー
タ圧縮装置における算術符号化のパイプライン動作を説
明する。ここで図11はパイプライン動作をT1〜T1
9のタイムサイクルに分けている。このうちT1〜T9
サイクルが入力文字の順位が第1位でない通常の場合で
あり、T10〜T13サイクルが入力文字の順位が第1
位の場合であり、更にT14〜T19サイクルが入力文
字の順位の頻度に対し同じ頻度の上位の順位の文字がな
い場合である。
The lower and upper ends of the output code of FIG. 9 correspond to the range of the arithmetic code by comparison with the divided code space of FIG.
This is 4-bit information obtained by combining the four range determination bits. Next, the pipeline operation of arithmetic coding in the data compression device of FIG. 7 will be described with reference to the time chart of FIG. Here, FIG. 11 illustrates the pipeline operation from T1 to T1.
It is divided into nine time cycles. T1 to T9
The cycle is a normal case where the order of the input character is not the first place, and the T10 to T13 cycle is that the order of the input character is the first place.
In the case of the rank, the cycle of T14 to T19 is the case where there is no character of the higher rank having the same frequency as the rank of the input character.

【0104】まずT1〜T9サイクルの通常の場合のパ
イプライン動作を説明する。まず確率モデル部14の順
位読出更新部18は、T1サイクルで符号化すべき文字
Kを入力し、頻度データ格納部25の参照により、その
順位sを読み出す処理RK(Read Kの意味)を行
う。T1サイクルで読み出した入力文字Kの順位sは、
頻度読出更新部22、累積頻度読出更新部24、更に総
累積頻度読出更新部26に与えられ、T2サイクルで処
理Rs,Rs,R0 に示すように順位sの出現数f
(s)、累積出現数cf(s)及び総出現数S0 の読出
しが行われる。これに並行して順位sより1つ上の順位
s−1に対応する文字Ks-1 、出現数f(s−1)、及
び累積出現数cf(s−1)の読出しが、処理Rs-1 に
示すようにT3サイクルで並行して行われる。
First, the pipeline operation in the normal case of the T1 to T9 cycles will be described. First, the order reading / updating unit 18 of the probability model unit 14 inputs a character K to be encoded in the T1 cycle, and performs a process RK (meaning Read K) for reading out the order s by referring to the frequency data storage unit 25. The rank s of the input character K read in the T1 cycle is:
The frequency read / update unit 22, the cumulative frequency read / update unit 24, and the total cumulative frequency read / update unit 26 are further provided with the number of appearances f of the rank s in the T2 cycle as shown in the processes Rs, Rs, and R0.
(S), the cumulative appearance number cf (s) and the total appearance number S0 are read. In parallel with this, reading of the character Ks-1, the number of appearances f (s-1), and the number of cumulative occurrences cf (s-1) corresponding to the rank s-1 one rank higher than the rank s is performed by the processing Rs- As shown in FIG. 1, they are performed in parallel in the T3 cycle.

【0105】このようなT1〜T3サイクルにおける確
率モデル部14における出現データの読出結果は算術符
号化部16に与えられ、T3〜T5サイクルで符号空間
のハイレベルとローレベルの算出処理が並行して行われ
る。まずT3サイクルで例えば符号空間算出部28が前
記(1)式に従った前回の区間幅Woldの算出のため
の加減算を行い、この結果をローレベル算出を行う符号
空間算出部30側にも反映させる。
The result of reading the appearance data in the probability model unit 14 in the T1 to T3 cycles is provided to the arithmetic coding unit 16, and the high level and low level calculation processes of the code space are performed in parallel in the T3 to T5 cycles. Done. First, in the T3 cycle, for example, the code space calculation unit 28 performs addition and subtraction for calculating the previous section width Wold according to the above equation (1), and this result is also reflected on the code space calculation unit 30 that performs low level calculation. Let it.

【0106】同時にT3サイクルにあっては、逆数算出
部32で総出現数S0 の逆数1/S0 を算出し、符号空
間算出部28,30のそれぞれに供給する。T4〜T6
サイクルにあっては、符号空間算出部28,30のそれ
ぞれが(2)式に従ったハイレベルの算出と(3)式に
従ったローレベルの算出を並行して行う。このT3〜T
6サイクルに亘る符号空間のハイレベルとローレベルの
算出結果は算術符号導出部34に与えられ、T7〜T1
0サイクルにおける図8に示した分割空間の閾値との比
較処理により符号[0101]が導出される。この導出
符号は図8の符号空間42−1と同じである。導出され
た算術符号は、符号出力部36より例えばシリアルデー
タとして出力される。
At the same time, in the T3 cycle, the reciprocal 1 / S0 of the total number of appearances S0 is calculated by the reciprocal calculator 32 and supplied to the code space calculators 28 and 30. T4-T6
In the cycle, each of the code space calculation units 28 and 30 performs the calculation of the high level according to the equation (2) and the calculation of the low level according to the equation (3) in parallel. This T3-T
The calculation results of the high level and the low level of the code space over six cycles are provided to the arithmetic code deriving unit 34, and T7 to T1
The code [0101] is derived by comparison processing with the threshold value of the divided space shown in FIG. 8 in the 0 cycle. This derived code is the same as the code space 42-1 in FIG. The derived arithmetic code is output from the code output unit 36 as, for example, serial data.

【0107】一方、確率モデル部14にあっては、算術
符号化部16に必要とする頻度データを出力した後のT
3〜T9サイクルで頻度データ格納部25の更新処理を
行う。まずT3〜T5サイクルにおいて、入力文字Kの
順位sの出現数f(s)と同じ大きさをもつ最も高い順
位を求める。即ち、T3〜T5サイクルの処理Rs-1,
Rs-2 ,Rs-3 に示すように、上位の順位について順
次、順位から出現数を求め、順位sと同じ出現頻度をも
つ最上位の順位を検索する。
On the other hand, in the probability model unit 14, after outputting the necessary frequency data to the arithmetic coding unit 16,
The update processing of the frequency data storage unit 25 is performed in cycles 3 to T9. First, in the T3 to T5 cycles, the highest rank having the same size as the number of appearances f (s) of the rank s of the input character K is obtained. That is, processing Rs-1, T3 to T5 cycle processing,
As shown in Rs-2 and Rs-3, the number of appearances is sequentially obtained from the top ranks, and the highest rank having the same appearance frequency as the rank s is searched.

【0108】この様子は図8の頻度データ格納部25を
参照することで理解できる。いま入力文字の順位がsで
あったとすると、その出現数はf(s)となる。そこで
各サイクルごとに上位の順位s1,s2,s3,・・・
と順位を上げながら、それぞれの出現数f(s−1),
f(s−2),f(s−3)を読み出して、順位sの出
現数f(s)と比較する。
This situation can be understood by referring to the frequency data storage unit 25 shown in FIG. Assuming that the order of the input characters is s, the number of appearances is f (s). Therefore, the higher ranks s1, s2, s3,.
And the number of occurrences f (s-1),
f (s-2) and f (s-3) are read out and compared with the number of appearances f (s) of the rank s.

【0109】ここで順位s−3の出現数f(s−3)が
順位sの出現数f(s)より大きかったとすると、同じ
出現数f(s)をもつ順位はs2であることが分かる。
以後、入れ替えのための更新に際し、サイクルT3で順
位sの出現数f(s)は予め1つインクリメントしてお
く。このようにして順位sの出現数f(s)と同じ値を
もつ最上位の順位s−2が得られたならば、順位sと順
位s−2に対応する文字の出現数及び累積出現数の入れ
替えをT6〜T7サイクルで行う。
Here, assuming that the number of appearances f (s-3) of the rank s-3 is larger than the number of appearances f (s) of the rank s, the rank having the same number of appearances f (s) is s2. .
Thereafter, at the time of updating for replacement, the number of appearances f (s) of the rank s is incremented by one in cycle T3. When the highest rank s-2 having the same value as the number of appearances f (s) of the rank s is obtained in this manner, the number of appearances and the cumulative number of characters corresponding to the rank s and the rank s-2 are obtained. Are performed in cycles T6 to T7.

【0110】更に累積出現数については、順位s−3以
上の累積出現数cf(s−3)〜cf(1)を逐次読み
出して1つインクリメントする書込みを行う。この処理
はWs-3 ・・・W1 で示される。更にT6サイクルにあ
っては、処理W0 に示すように、総出現数S0 を1つイ
ンクリメントしておく。これによって文字Kの算術符号
化に伴う出現データ格納部25の更新処理が終了する。
Further, with respect to the cumulative appearance number, the cumulative appearance numbers cf (s-3) to cf (1) of the rank s-3 or higher are sequentially read and written to increment by one. This processing is represented by Ws-3... W1. Further, in the cycle T6, the total number of appearances S0 is incremented by one as shown in the processing W0. Thus, the update processing of the appearance data storage unit 25 accompanying the arithmetic encoding of the character K is completed.

【0111】T10〜T13サイクルは入力文字の順位
が第1位の場合である。この場合には頻度データ格納部
25の入れ替えが不要であり、それ以外はT1〜T9サ
イクルの通常の場合と同じである。更にT14〜T19
サイクルは、入力文字の出現数と同じ出現数をもつ上位
の順位が存在しない場合であり、この場合には文字の入
れ替えを行わずに、順位sについて順位sの出現数f
(s)のインクリメント、1つ上の順位s−1以上の累
積出現数cf(s−1)〜cf(1)のそれぞれのイン
クリメント、更に総出現数S0 のインクリメントを行
う。T10〜T13サイクル及びT14〜T19サイク
ルに続く算術符号化部16の処理は、T1〜T9サイク
ルに続く符号化処理と同じである。
The T10 to T13 cycles correspond to the case where the order of the input character is first. In this case, the frequency data storage unit 25 does not need to be replaced, and the rest is the same as the normal case of the T1 to T9 cycles. Further, T14 to T19
The cycle is a case where there is no higher rank having the same number of appearances as the number of appearances of the input character. In this case, the number of appearances f of the rank s is not changed for the rank s without replacing the characters.
The increment of (s), the respective increments of the cumulative appearance numbers cf (s-1) to cf (1) above the rank s-1 or higher, and the total appearance number S0 are also incremented. The processing of the arithmetic encoding unit 16 following the cycles T10 to T13 and T14 to T19 is the same as the encoding processing following the cycles T1 to T9.

【0112】図12は図5のデータ圧縮装置で得られた
圧縮データから元のソースデータを復元するデータ復元
装置の基本構成である。このデータ復元装置は図12
(A)のように、エントロピー復号化部46、出現頻度
モデル部48及びパイプライン制御部47で構成され
る。エントロピー復号化部46は圧縮データとしての符
号列の中から符号を1つずつ入力し、入力された符号と
既に復元されている直前の文字から条件付出易さを求
め、出現頻度モデル部48に出力する。出現頻度モデル
部48は直前の文字列につながる入力文字の条件付出易
さを各文字ごとに登録した頻度データ格納部を有し、エ
ントロピー復号化部46から出力された入力符号の条件
付出易さにより頻度データ格納部を検索して文字を復元
する。
FIG. 12 shows a basic configuration of a data decompression device for decompressing the original source data from the compressed data obtained by the data compression device of FIG. This data restoration device is shown in FIG.
As shown in (A), it is composed of an entropy decoding unit 46, an appearance frequency model unit 48, and a pipeline control unit 47. The entropy decoding unit 46 inputs codes one by one from the code string as compressed data, obtains conditional ease of appearance from the input code and the character immediately before being restored, Output. The appearance frequency model unit 48 has a frequency data storage unit that registers, for each character, the conditional easiness of the input character connected to the immediately preceding character string, and the conditional easiness of the input code output from the entropy decoding unit 46. To search the frequency data storage unit to restore characters.

【0113】パイプライン制御部47はエントロピー復
号化部46と出現頻度モデル部48をパイプライン動作
させる。ここでエントロピー復号化部46としては、図
5のエントロピー符号化部12で採用された算術符号
化、動的ハフマン符号化、自己組織化符号化の一種であ
るスプレイ符号化に対応して算術復号化、動的ハフマン
復号化、スプレイ復号化などを行うことになる。
The pipeline control unit 47 causes the entropy decoding unit 46 and the appearance frequency model unit 48 to perform a pipeline operation. Here, as the entropy decoding unit 46, arithmetic decoding, dynamic Huffman coding, and spray decoding, which is a kind of self-organizing coding, employed in the entropy coding unit 12 in FIG. , Dynamic Huffman decoding, splay decoding, and the like.

【0114】図12(B)はパイプライン制御部47に
よるエントロピー復号化部46及び出現頻度モデル部4
8のパイプライン動作のタイムチャートである。まずT
1サイクルで符号を入力して条件付出易さを求めるエン
トロピー復号化を行う。このとき出現頻度モデル部48
は、前回の復号化結果が得られていないので文字の復元
処理は行わない。
FIG. 12B shows an entropy decoding unit 46 and an appearance frequency model unit 4 by the pipeline control unit 47.
8 is a time chart of the pipeline operation of FIG. First T
A code is input in one cycle to perform entropy decoding for obtaining conditional ease. At this time, the appearance frequency model unit 48
Does not perform character restoration processing since the previous decoding result has not been obtained.

【0115】次のT2サイクルにあっては、次の符号を
入力して同様にして条件付出易さを求めるエントロピー
復号化をエントロピー復号化部46で行う。同時に出現
頻度モデル部48で前サイクルT1で求めた条件付出易
さによる頻度データ格納部の検索で文字aを復元する。
以下同様に、エントロピー復号化部46で符号を入力し
て復号すると同時に、出現頻度モデル部48で前サイク
ルで得られた復号結果から文字を復元して出力する。
In the next T2 cycle, entropy decoding is performed by the entropy decoding unit 46 for inputting the next code and similarly obtaining conditional easiness. At the same time, the character a is restored by the appearance frequency model unit 48 by searching the frequency data storage unit based on the conditional ease determined in the previous cycle T1.
Similarly, the code is input and decoded by the entropy decoding unit 46, and at the same time, the character is restored and output from the decoding result obtained in the previous cycle by the appearance frequency model unit 48.

【0116】図13は、図6の算術符号化を適用したデ
ータ圧縮装置で得られた圧縮データから文字を復元する
算術復号化を行うデータ復元装置である。このデータ復
元装置は、図13(A)のように算術復号化部50、確
率モデル部52及びパイプライン制御部51で構成され
る。算術復号化部50は圧縮データとして図4のデータ
圧縮装置で得られた符号01,1001,01を符号単
位に入力し、符号から求められた割当符号空間の順位を
求め、確率モデル部52に出力する。
FIG. 13 shows a data decompression device for performing an arithmetic decoding for restoring characters from the compressed data obtained by the data compression device to which the arithmetic coding shown in FIG. 6 is applied. This data restoration device includes an arithmetic decoding unit 50, a probability model unit 52, and a pipeline control unit 51 as shown in FIG. Arithmetic decoding section 50 inputs codes 01, 1001, and 01 obtained by the data compression apparatus of FIG. 4 as compressed data in code units, obtains the order of the allocated code space obtained from the codes, and sends the order to probability model section 52. Output.

【0117】この場合には、順位1位、2位、1位が順
次出力される。確率モデル部52は、各文字の出現数の
大きい順番に順位を付けて並べられた図6に示したと同
じ構造の出現データ格納部を備えており、算術復号化部
50から出力された順位により頻度データ格納部を検索
して、対応する文字をa,b,aのように復元する。図
13(B)はパイプライン制御部51による算術符号化
部50及び確率モデル部52のパイプライン動作のタイ
ムチャートである。まずT1サイクルで算術符号化部5
0に符号01を入力し、順位1位を復号化する。このと
き確率モデル部52には前回の復号順位が入力されてい
ないことから、文字の復元は行われない。
In this case, the first place, the second place, and the first place are sequentially output. The probability model unit 52 includes an appearance data storage unit having the same structure as that shown in FIG. 6 and arranged in the order of the number of appearances of each character in descending order, according to the order output from the arithmetic decoding unit 50. The frequency data storage unit is searched, and the corresponding characters are restored as a, b, and a. FIG. 13B is a time chart of the pipeline operation of the arithmetic coding unit 50 and the probability model unit 52 by the pipeline control unit 51. First, in the T1 cycle, the arithmetic coding unit 5
The code 01 is input to 0, and the first place is decoded. At this time, since the previous decoding order has not been input to the probability model unit 52, the character is not restored.

【0118】次のT2サイクルにあっては、2番目の符
号1001を算術符号化部50に入力して順位2を復号
化すると同時に、確率モデル部52に前サイクルT1で
求めた順位1により頻度データ格納部を検索して文字a
を復元する。以下同様に、算術復号化部50で新たな符
号を入力して順位の復号化を行うと同時に、確率モデル
部52で前回復号した順位による文字の復元を行う。
In the next T2 cycle, the second code 1001 is input to the arithmetic coding unit 50 to decode the rank 2, and at the same time, the frequency is calculated by the rank 1 obtained in the previous cycle T1 in the probability model unit 52. Search the data storage to find the letter a
To restore. Similarly, the arithmetic decoding unit 50 inputs a new code to decode the rank, and at the same time, the probability model unit 52 restores the character according to the previously decoded rank.

【0119】図14は図13のデータ復元装置の詳細で
ある。このデータ復元装置は算術復号化部50、確率モ
デル部52及びパイプライン制御部51で構成される。
算術復号化部50には符号入力部54、累積値導出部5
6、符号空間のハイレベルを算出する符号空間算出部5
8、符号空間のローレベルを算出する符号空間算出部6
0、ハイレベル及びローレベルの符号空間算出に使用す
る総出現数S0 の逆数1/S0 を算出する逆数算出部6
2、累積頻度導出部64、及び累積頻度導出に使用する
レンジWold の逆数1/Wold を算出する逆数算出部6
6が設けられている。
FIG. 14 shows details of the data restoration apparatus of FIG. This data restoration device includes an arithmetic decoding unit 50, a probability model unit 52, and a pipeline control unit 51.
The arithmetic decoding unit 50 includes a code input unit 54 and a cumulative value deriving unit 5
6. Code space calculation unit 5 for calculating the high level of the code space
8. Code space calculator 6 for calculating the low level of the code space
0, a reciprocal calculator 6 for calculating the reciprocal 1 / S0 of the total number of occurrences S0 used for calculating the high-level and low-level code spaces.
2. Cumulative frequency deriving unit 64 and reciprocal calculating unit 6 for calculating reciprocal 1 / Wold of range Wold used for cumulative frequency deriving
6 are provided.

【0120】また確率モデル部52には、順位導出部6
8、出現データ格納部70、文字読出更新部72、頻度
読出更新部74、累積頻度読出更新部76、総累積頻度
読出更新部78及び文字出力部80が設けられる。算術
復号化部50は符号を入力するごとに、入力符号で与え
られる累積出現数cf(code)を算出する。この符
号の累積出現数cf(code)は次式で与えられる。 cf(code)=[{(Value−Lold )×S0 }−1]/Wold (4) 但し、Valueは符号から求めた累積値 Lold は前回区間の下端(ローレベル) Wold は前回区間の区間幅(レンジ) この(4)式は、符号化の際に新空間のハイレベルを、
入力文字の順位より1つ上の順位s−1の累積出現数c
f(s−1)に基づいて算出する前記(2)式を変形し
て累積出現数cf(s−1)の算出式に変形した式と同
じである。即ち、(2)式の順位s−1の累積出現数c
f(s−1)を符号の累積出現数cf(code)に置
き替え、新空間のハイレベルHnewを累積値Valu
eに置き替えて変形することで、(4)式が得られる。
The probability model unit 52 includes a rank deriving unit 6
8, an appearance data storage unit 70, a character reading / updating unit 72, a frequency reading / updating unit 74, a cumulative frequency reading / updating unit 76, a total cumulative frequency reading / updating unit 78, and a character output unit 80 are provided. Each time a code is input, the arithmetic decoding unit 50 calculates a cumulative occurrence number cf (code) given by the input code. The cumulative occurrence number cf (code) of this code is given by the following equation. cf (code) = [{(Value−Lold) × S0} −1] / Wold (4) where “Value” is the cumulative value obtained from the code “Lold” is the lower end (low level) of the previous section. “Wold” is the section width of the previous section. (Range) This equation (4) defines the high level of the new space at the time of encoding,
Cumulative number c of rank s-1 which is one rank higher than the rank of the input character
This is the same as the expression (2) calculated based on f (s-1) and modified to the expression for calculating the cumulative appearance number cf (s-1). That is, the cumulative number c of the rank s-1 in the equation (2)
f (s−1) is replaced with the cumulative number of occurrences of the code cf (code), and the high level Hnew of the new space is calculated as the cumulative value Valu.
By substituting for e and deforming, equation (4) is obtained.

【0121】この(4)式における累積値Valueは
入力した符号から正規化された符号区間[1,0]に設
定した閾値1/4,1/2,3/4との比較により次の
条件に従って定められる。 <条件>符号から求めた新空間のローレベルが1/2
以上であれば、累積値Value=1/2とする。
The cumulative value Value in the equation (4) is obtained by comparing with the threshold values 1/4, 1/2, and 3/4 set in the code section [1, 0] normalized from the input code. It is determined according to. <Condition> The low level of the new space obtained from the code is 1/2.
If this is the case, the accumulated value Value is set to 1/2.

【0122】<条件>符号から求めた新空間のローレ
ベルが1/4以上で且つハイレベルが3/4未満であれ
ば、累積値Value=1/4とする。 このような条件に従った累積値Valueの導出
は、累積値導出部56で行われている。また(4)式の
演算に使用する前回復号された符号の符号空間のハイレ
ベルとローレベルの算出は、符号空間算出部58,60
で行われている。この場合の符号空間のハイレベルとロ
ーレベルの算出値は前記(2)式、(3)式と基本的に
同じである。
<Condition> If the low level of the new space obtained from the code is not less than 1/4 and the high level is less than 3/4, the accumulated value Value is set to 1/4. Derivation of the cumulative value Value according to such a condition is performed by the cumulative value deriving unit 56. The calculation of the high level and the low level of the code space of the previously decoded code used for the calculation of the equation (4) is performed by the code space calculation units 58 and 60.
It is done in. In this case, the calculated values of the high level and the low level of the code space are basically the same as the above-described equations (2) and (3).

【0123】累積頻度導出部64は前記(4)式に従っ
て符号の累積出現数cf(code)を算出すると共
に、算出した符号の累積出現数cf(code)に逆数
算出部66でレンズWold の逆数1/Wold を求めて乗
算することで、符号の累積頻度を導出する。一方、確率
モデル部52は、順位導出部68において算術復号化部
50より出力された符号から復元された累積出現数と、
頻度データ格納部70に格納されている各文字の累積出
現数を順位1位から順番に比較する。この符号の累積出
現数と頻度データ格納部70に格納された上位の順位か
らの累積出現数との比較により、順位を導出する。
The cumulative frequency deriving section 64 calculates the cumulative occurrence number cf (code) of the code according to the above equation (4), and calculates the reciprocal of the lens Wold by the reciprocal calculating section 66 to the calculated cumulative occurrence number cf (code) of the code. The cumulative frequency of the code is derived by multiplying 1 / Wold. On the other hand, the probability model unit 52 calculates the cumulative number of appearances restored from the code output from the arithmetic decoding unit 50 in the rank deriving unit 68,
The cumulative number of occurrences of each character stored in the frequency data storage unit 70 is compared in order from the first place. The rank is derived by comparing the cumulative number of occurrences of this code with the cumulative number of occurrences from the higher rank stored in the frequency data storage unit 70.

【0124】順位導出部68で符号の累積出現頻度から
順位が導出されると、この順位は文字読出更新部72に
与えられ、順位に対応する文字を頻度データ格納部70
から読み出すことで文字が復元され、文字出力部80よ
り文字出力が行われる。また頻度読出更新部74は復元
文字の出現数を1つインクリメントする。累積頻度読出
更新部76は、復元文字より大きい累積出現数をもつ上
位の順位について、それぞれの累積出現数を1つインク
リメントする更新を行う。更に復元順位の文字の上位の
順位に同じ累積出現数の順位が存在する場合には、同じ
累積出現数の最上位の順位と復元順位の入れ替えを文字
出現数及び累積出現数について行う。更に総累積頻度読
出更新部78は、総出現数を1つインクリメントする。
When the rank is derived from the cumulative appearance frequency of the code by the rank deriving section 68, the rank is given to the character reading / updating section 72, and the character corresponding to the rank is stored in the frequency data storage section 70.
The character is restored by reading from the character string, and the character output unit 80 outputs the character. The frequency read / update unit 74 increments the number of appearances of the restored character by one. The cumulative frequency reading / updating unit 76 performs an update for incrementing the cumulative number of occurrences by one for higher ranks having a cumulative number of occurrences larger than the restored character. Further, when the rank of the same cumulative appearance number exists in the upper rank of the character of the restoration rank, the highest rank of the same cumulative appearance count and the restoration rank are replaced with respect to the character appearance count and the cumulative appearance count. Further, the total cumulative frequency reading / updating unit 78 increments the total number of appearances by one.

【0125】図15及び図16は、図14のデータ復元
装置のパイプライン動作のタイムチャートである。ここ
で図15のT1〜T13サイクルは符号から復元した文
字の順位が1位以外となる通常の場合であり、また図1
5のT14サイクルから図16のT24サイクルは、符
号から復元した順位が1位の場合である。更に図16の
T25〜T38サイクルは符号から復元した順位が1位
以外の通常の場合であるが、復元順位について同じ頻度
の上位の順位がない場合である。
FIGS. 15 and 16 are time charts of the pipeline operation of the data restoration apparatus of FIG. Here, the T1 to T13 cycles in FIG. 15 are a normal case in which the order of the character restored from the code is other than the first place.
From the T14 cycle of No. 5 to the T24 cycle of FIG. 16, the order restored from the code is the first place. Further, cycles T25 to T38 in FIG. 16 are normal cases in which the order restored from the code is other than the first place, but there is no higher order of the same frequency in the restored order.

【0126】まず図15のT1〜T13サイクルの通常
の復元処理を説明する。T1〜T2サイクルにあって
は、符号入力部54によって符号ビットを入力し、累積
値導出部56によって前記した条件の比較処理によ
り累積値Valueを導出する。このときT1サイクル
以前のサイクルで符号空間導出部58,60により前回
復元された符号空間のハイレベル及びローレベルの算出
が既に済んでいる。
First, the normal restoration processing in the T1 to T13 cycles in FIG. 15 will be described. In the T1 to T2 cycles, a sign bit is input by the sign input unit 54, and the accumulated value derivation unit 56 derives the accumulated value by the above-described condition comparison processing. At this time, in the cycle before the T1 cycle, the calculation of the high level and the low level of the code space previously restored by the code space deriving units 58 and 60 has already been completed.

【0127】次のT3〜T6サイクルにあっては、前記
(4)式により累積頻度導出部64において、符号の累
積出現頻度の算出が行われる。このときT4サイクルに
おいて逆数算出部66が(4)式における1/Wold
の逆数演算を並行して行い、この結果をT6の乗算に使
用している。T6サイクルで算出された符号の累積出現
数cf(code)は確率モデル部52に与えられ、T
7〜T13サイクルにおいて文字の復元及び頻度データ
格納部70の更新が行われる。この確率モデル部52に
おける文字の復元及び頻度データの更新に並行して算術
復号化部50にあっては、T10〜T13サイクルで符
号空間算出部58,60による復元中の文字に関する符
号空間のハイレベルとローレベルの算出を並行して行っ
ている。
In the next T3 to T6 cycles, the cumulative frequency deriving unit 64 calculates the cumulative code appearance frequency according to the above equation (4). At this time, in the T4 cycle, the reciprocal calculator 66 calculates 1 / Wold in the equation (4).
Are performed in parallel, and the result is used for multiplication of T6. The cumulative occurrence number cf (code) of the code calculated in the T6 cycle is given to the probability model unit 52,
In the 7th to T13 cycles, the character is restored and the frequency data storage unit 70 is updated. In parallel with the restoration of the character and the update of the frequency data in the probability model unit 52, the arithmetic decoding unit 50 sets a high code space for the character being restored by the code space calculation units 58 and 60 in the T10 to T13 cycles. The calculation of the level and the low level are performed in parallel.

【0128】またT10〜T13サイクルにおける符号
空間のハイレベルとローレベルの算出に先立って、T8
サイクルにおいて逆数算出部62が総出現数S0 の逆数
1/S0 を予め算出し、T12サイクルにおける乗算を
可能としている。ここでT7〜T12サイクルにおける
確率モデル部52における文字の復元と頻度データの更
新処理を説明する。まずT7〜T10サイクルにおい
て、頻度データ格納部70に登録された頻度の高いもの
から順番に累積出現数を読み出して、算術復号化部50
から送られた符号の累積出現数cf(code)がどの
順位の間に位置するのかを、読み出した順位と1つ上の
順位の累積出現数の大小関係から導く。
Before calculating the high level and the low level of the code space in the T10 to T13 cycles, T8
In the cycle, the reciprocal calculation unit 62 previously calculates the reciprocal 1 / S0 of the total number of appearances S0, thereby enabling the multiplication in the T12 cycle. Here, a description will be given of a process of restoring characters and updating frequency data in the probability model unit 52 in the T7 to T12 cycles. First, in the T7 to T10 cycles, the cumulative appearance number is read out in order from the one with the highest frequency registered in the frequency data storage unit 70, and the arithmetic decoding unit 50
The order in which the cumulative occurrence number cf (code) of the code sent from is located is derived from the magnitude relation between the read order and the cumulative occurrence number of the next higher rank.

【0129】即ち、T7〜T10サイクルにあっては、
R1〜Rsのように順位から累積出現数及び文字の読出
しを並行して行っており、において算術復号化部50
から与えられた符号の累積出現数cf(code)と読
み出した各順位の累積出現数との比較を行い、この場
合、順位sと順位s−1の間に符号の累積出現数cf
(code)が位置することから順位sが復元され、T
11サイクルで順位sの文字出力が行われる。
That is, in the T7 to T10 cycles,
As in R1 to Rs, the cumulative number of appearances and the reading of characters are performed in parallel from the rank, and the arithmetic decoding unit 50
Is compared with the read cumulative appearance number of each rank, and in this case, the cumulative appearance number cf of the code between rank s and rank s-1
(Code) is located, the order s is restored, and T
The character output of order s is performed in 11 cycles.

【0130】またのようにT7〜T11サイクルで、
順位1〜sの読出しごとに1つ上の順位の隣接累積出現
数同士の比較を行っている。この場合、順位s−1の読
出時における比較と順位sの読出時における比較で隣接
する上位の累積出現数との比較結果が同一であった場合
には、順位s−2,s−1,sの累積出現数が同じであ
ることが分かる。
As described above, in the T7 to T11 cycles,
Each time the ranks 1 to s are read, the numbers of adjacent cumulative occurrences in the rank higher by one are compared. In this case, when the comparison result at the time of reading the rank s-1 and the comparison result at the time of reading at the rank s are the same as the number of adjacent cumulative occurrences, the ranks s-2, s-1,. It can be seen that the cumulative number of occurrences of s is the same.

【0131】そこでT11〜T13サイクルにおいて、
復元文字の順位sの格納データが同じ累積出現数をもつ
順位のうちの最上位の位置にs−2との格納データの入
れ替えを行う。この入れ替えに先立ち、T8〜T10で
読み出した順位s−3以上の累積出現数については1つ
インクリメントを行っており、また総累積出現数につい
てはT7でR0としてリードした後に、T8で1つイン
クリメントしてT9で書き込む。もちろん、T11〜T
13における順位sとs−2の頻度データの入れ替え
は、累積出現数、出現数及び文字の3つについて行う。
Therefore, in the cycles T11 to T13,
The stored data is replaced with s-2 at the highest position in the order in which the stored data of the restored character rank s has the same cumulative number of occurrences. Prior to this replacement, the cumulative number of occurrences of rank s−3 or higher read at T8 to T10 is incremented by one, and the total cumulative number of occurrences is read as R0 at T7 and then incremented by one at T8. And write at T9. Of course, T11-T
The replacement of the frequency data of the ranks s and s-2 in 13 is performed for three of the cumulative number of appearances, the number of appearances, and the characters.

【0132】図15のT14サイクルから図16のT2
4サイクルまでの復元順位が1位の場合については、確
率モデル部52における復元順位における頻度データの
入れ替えを行わない点が異なり、その他は同じである。
また図16のT25〜T38サイクルで復元順位が1位
でなく通常の場合で、復元された順位の累積出現数と同
じ累積出現数をもつ上位の順位がない場合については、
同じ累積出現数をもつ最上位の順位と復元順位との頻度
データの入れ替えを行わない点が相違し、それ以外は通
常の場合と同じになる。 2.ブレンド文脈の一部の並列化 図17(A)はブレンド文脈を対象とした本発明のデー
タ圧縮装置であり、ブレンド用の確率モデル部を各次数
ごとに並列化し、更に算術符号化部との間でパイプライ
ン処理を行うようにしたことを特徴とする。
The cycle from T14 in FIG. 15 to T2 in FIG.
In the case where the restoration order up to four cycles is the first place, the difference is that the frequency data in the restoration order in the probability model unit 52 is not replaced, and the rest is the same.
In the case where the restoration order is not the first place but the normal order in the cycles T25 to T38 in FIG. 16 and there is no higher rank having the same cumulative appearance number as the restored appearance cumulative number,
The difference is that the frequency data of the highest order and the restoration order having the same cumulative appearance number are not replaced, and the rest is the same as the normal case. 2. Partial Parallelization of Blend Context FIG. 17A shows a data compression apparatus according to the present invention for a blend context, in which a stochastic model part for blending is parallelized for each degree, and is further combined with an arithmetic coding part. It is characterized in that pipeline processing is performed between the two.

【0133】ブレンド用確率モデル部82は、この実施
例にあっては0次確率モデル部88、1次確率モデル部
90、2次確率モデル部92の並列回路で構成される。
0次、1次及び2次確率モデル部88,90,92のそ
れぞれは、並列的に1文字ずつ入力し、各次数における
従属関係となる出現頻度を求め、順位を出力する。バッ
ファ選択部84は、0次、1次、2次の確率モデル部8
8,90,92の出力順位を高次から低次に向けて選択
して算術符号化部86に出力する。具体的には、2次確
率モデル部92で有効順位が得られると、これを算術符
号化部86に出力して算術符号化を行う。
In this embodiment, the blending probability model unit 82 is constituted by a parallel circuit of a zero-order probability model unit 88 , a first-order probability model unit 90, and a second-order probability model unit 92.
Each of the zero-order, first-order, and second-order probability model units 88, 90, and 92 inputs one character at a time in parallel, obtains an appearance frequency that is dependent on each order, and outputs a rank. The buffer selection unit 84 includes a 0th-order, 1st-order, and 2nd-order probability model unit 8
The output order of 8, 90 and 92 is selected from the higher order to the lower order and output to the arithmetic encoding unit 86. Specifically, when the effective rank is obtained by the second-order probability model unit 92, this is output to the arithmetic coding unit 86 to perform arithmetic coding.

【0134】一方、2次確率モデル部92で順位が得ら
れずにエスケープ出力Eとなった場合には、算術符号化
を行わずに単にエスケープを示す符号を出力し、次の
次確率モデル部90の出力を選択し、有効順位が得られ
ていれば1次確率モデル部90の順位の算術符号化を行
う。また1次確率モデル部90からも有効順位が得られ
ずにエスケープ出力Eであった場合には、0次確率モデ
ル部88の出力順位を選択して算術符号化を行わせるこ
とになる。ここで2次確率モデル部92及び1次確率モ
デル部90でエスケープ出力となるのは、入力文字を親
とし各次数の文字を子供とするとき、各次数に子供はい
るけれども該当する子供がない場合、あるいは各次数に
子供が1つもない場合のいずれかである。
[0134] On the other hand, when the rank in the secondary probability modeling unit 92 becomes an escape output E to not obtained, and outputs a code simply indicates an escape without arithmetic coding, the following 1
The output of the next-order probability model unit 90 is selected, and if the effective rank is obtained, arithmetic coding of the order of the first-order probability model unit 90 is performed. When the effective order is not obtained from the first-order probability model unit 90 and the output is the escape output E, the output order of the zero-order probability model unit 88 is selected and arithmetic coding is performed. Here, the escape output in the second-order probability model unit 92 and the first-order probability model unit 90 is that when the input character is a parent and the characters of each order are children, there are children in each order, but there is no corresponding child Or no child of each order.

【0135】0次、1次及び2次確率モデル部88,9
0,92で使用する出現頻度データ格納部としては、符
号化対象とする全文字ごとに辞書をもち、文字入力ごと
に1次確率モデル部90で使用する入力文字の1つ前の
文字の登録及び2次確率モデル部92で使用する2つ前
の文字の登録を動的に行う。図17(B)は図17
(A)のブレンド用確率モデル部82を並列化したデー
タ圧縮装置のパイプライン動作のタイムチャートであ
る。ここでブレンド用確率モデル部82に対し、ソース
データから例えば文字dcabaの順に入力し、既に2
文字dcの符号化が済んでabaを符号化する場合であ
る。
0th, 1st and 2nd order probability model units 88, 9
The appearance frequency data storage unit used in 0, 92 has a dictionary for every character to be encoded, and registers the character immediately before the input character used in the primary probability model unit 90 for each character input. And the second previous character used in the second-order probability model unit 92 is dynamically registered. FIG. 17 (B) shows FIG.
5A is a time chart of a pipeline operation of the data compression device in which the blending probability model unit 82 of FIG. Here, for example, in the order of the characters dcaba from the source data,
This is a case where aba is encoded after encoding of the character dc.

【0136】まずT1サイクルにあっては、文字aが入
力し、0次、1次及び2次確率モデル部88,90,9
2のそれぞれにおいて並列的に各次数における出現頻度
が求められ、出現頻度順に並べた場合の順位が得られ
る。ここで2次確率モデル部92で先行する2文字dc
を組み合わせた文字列dcaの出現頻度が順位1位で存
在したとすると、次のT2サイクルでバッファ選択部8
4は2次確率モデル部92から出力された順位1位の出
2 を選択し、これを算術符号化部86に与えて算術
符号化して符号1を出力する。
First, in the T1 cycle, the character a is input, and the 0th, 1st and 2nd order probability model units 88, 90, 9
In each of 2, the frequency of appearance in each order is obtained in parallel, and the order in the order of frequency of appearance is obtained. Here, the preceding two characters dc in the second probability model unit 92
Assume that the appearance frequency of the character string dca in which the character string dca is combined exists in the first place, and the buffer selection unit 8 in the next T2 cycle.
Reference numeral 4 selects the output 1 2 of the first rank output from the second-order probability model unit 92, and supplies it to the arithmetic coding unit 86, arithmetically codes it, and outputs a code 1.

【0137】同時にT2サイクルにあっては、次の文字
bを0次、1次及び2次確率モデル部88,90,92
に並列的に入力して出現頻度による順位を求めている。
このとき2次確率モデル部92において、先行する2文
字caの子が検索できなかった場合には、次のT3サイ
クルで算術符号化部86はエスケープ符号E2をそのま
ま符号出力する。このT3サイクルにあっては、ブレン
ド用確率モデル部82は3番目の文字aを入力し、この
場合、先行する2文字abの存在による順位1位が2次
確率モデル部92で得られたとする。
At the same time, in the T2 cycle, the next character b is replaced by the 0th, 1st, and 2nd order probability model units 88, 90,
Are input in parallel with each other to determine the rank based on the appearance frequency.
At this time, if the second probability model unit 92 cannot retrieve the child of the preceding two characters ca, the arithmetic encoding unit 86 outputs the escape code E2 as it is in the next T3 cycle. In this T3 cycle, the blending probability model unit 82 inputs the third character a, and in this case, it is assumed that the secondary ranking model unit 92 has obtained the first place due to the presence of the preceding two characters ab. .

【0138】算術符号化部86にあっては、T3サイク
ルにおける2次確率モデル部92からのエスケープ出力
E2の符号化出力に続き、次のT4サイクルで1次確率
モデル部90の出力を選択して符号化しようとする。こ
のときT2サイクルで示したように、1次確率モデル部
90においても入力文字bに対する1つ前の文字aが子
供として存在せずに、有効順位が得られずにエスケープ
出力E1となっていたとすると、このエスケープ出力E
1をそのまま符号1として出力する。
In the arithmetic encoding unit 86, following the encoded output of the escape output E2 from the secondary probability model unit 92 in the T3 cycle, the output of the primary probability model unit 90 is selected in the next T4 cycle. Try to encode. At this time, as shown in the cycle T2, the character a immediately before the input character b does not exist as a child in the first-order probability model unit 90, and the escape order E1 is obtained without obtaining an effective rank. Then, this escape output E
1 is output as code 1 as it is.

【0139】そしてT5サイクルで0次確率モデル部8
8より出力される順位2の有効出力 0 を算術符号化部
86に与えて符号化し、符号01を出力する。このため
T2サイクルのブレンド用確率モデル部82における0
次、1次及び2次の並列処理による順位出力について
は、次のT3,T4,T5の3サイクルを使用した2つ
のエスケープ符号と0次の順位出力の算術符号化が行わ
れる。
In the T5 cycle, the 0th-order probability model unit 8
The valid output 2 0 of rank 2 output from 8 encoded given to the arithmetic coding unit 86, and outputs a code 01. Therefore, 0 in the blending probability model unit 82 in the T2 cycle.
As for the rank output by the first-order and second-order parallel processing, two escape codes using the next three cycles of T3, T4, and T5 and the arithmetic coding of the zeroth-order rank output are performed.

【0140】ブレンド用確率モデル部82のT3サイク
ルにおける2次確率モデル部92からの順位1の出力
2 については、次のT6サイクルで算術符号化部86に
よる符号化が行われ、符号1の出力となる。図18は図
17(A)のブレンド文脈を対象としたデータ圧縮装置
の詳細である。図18において、ブレンド用確率モデル
部82は0次確率モデル部88、1次確率モデル部9
0、及び2次確率モデル部92を並列的に備えており、
1次確率モデル部90に代表して示す構成をもつ。
Output 1 of rank 1 from the secondary probability model unit 92 in the T3 cycle of the blending probability model unit 82
Regarding 2 , encoding is performed by the arithmetic encoding unit 86 in the next T6 cycle, and an output of code 1 is obtained. FIG. 18 shows the details of the data compression apparatus for the blend context shown in FIG. In FIG. 18, the blending probability model unit 82 includes a zero-order probability model unit 88 and a first-order probability model unit 9.
0, and a second-order probability model unit 92 in parallel.
It has a configuration shown as a representative of the first-order probability model unit 90.

【0141】1次確率モデル部90には順位読出更新部
94、文字読出更新部98、頻度読出更新部100、累
積頻度読出更新部102、総累積頻度読出更新部106
が設けられる。これらのブロックは、図7の固定文脈を
対象とした確率モデル部14に設けている対応する回路
部と同じである。これに加えてブレンド用確率モデル部
82の場合には、エスケープ用頻度読出更新部95及び
エスケープ判断部104を新たに設けている。
The first-order probability model unit 90 includes a rank reading / updating unit 94, a character reading / updating unit 98, a frequency reading / updating unit 100, a cumulative frequency reading / updating unit 102, and a total cumulative frequency reading / updating unit 106.
Is provided. These blocks are the same as the corresponding circuit units provided in the probability model unit 14 for the fixed context in FIG. In addition, in the case of the blending probability model unit 82, an escape frequency readout update unit 95 and an escape determination unit 104 are newly provided.

【0142】エスケープ判断部104は入力文字の1つ
前の文字が子供として頻度データ格納部96の対応する
辞書に存在するか否か検出し、子供が存在しない場合に
はバッファ部110に対しエスケープ出力を行わせる。
エスケープ用頻度読出更新部95は、エスケープが検出
された場合に頻度データ格納部96に格納されているエ
スケープ出現数を1つインクリメントし、更にエスケー
プ出力も文字出現数の1つであることから、総累積頻度
読出更新部106を起動して総出現数のインクリメント
を行なわせる。
The escape determination unit 104 detects whether the character immediately before the input character exists as a child in the corresponding dictionary of the frequency data storage unit 96, and if there is no child, escapes to the buffer unit 110. Force output.
The escape frequency reading / updating unit 95 increments the number of escape occurrences stored in the frequency data storage unit 96 by one when an escape is detected, and furthermore, the escape output is one of the number of character occurrences. Activate the total cumulative frequency reading / updating unit 106 to increment the total number of appearances.

【0143】バッファ選択部84は、各次数ごとに設け
たバッファ部108,110,112と選択部114で
構成される。選択部114は、高次から低次に向けてバ
ッファ部112,110,108の順番に格納された確
率出力としての順位を選択して算術符号化部86に供給
する。算術符号化部86は、ハイレベル算出用の符号空
間算出部116、ローレベル算出用の符号空間算出部1
18、総出現数の逆数を算出する逆数算出部120、算
術符号導出部122、及び符号出力部124で構成され
る。この算術符号化部86の構成は、図7の算術符号化
部16の対応するブロックと同じである。
The buffer selection section 84 is composed of buffer sections 108, 110, 112 provided for each order and a selection section 114. The selection unit 114 selects the order as the probability output stored in the order of the buffer units 112, 110, and 108 from the higher order to the lower order and supplies the order to the arithmetic encoding unit 86. The arithmetic coding unit 86 includes a code space calculation unit 116 for high-level calculation and a code space calculation unit 1 for low-level calculation.
18, a reciprocal calculating unit 120 for calculating the reciprocal of the total number of appearances, an arithmetic code deriving unit 122, and a code output unit 124. The configuration of the arithmetic coding unit 86 is the same as that of the corresponding block of the arithmetic coding unit 16 in FIG.

【0144】図19は、図18のブレンド文脈を対象と
したデータ圧縮装置における1次モデル部90及び算術
符号化部86のパイプライン動作のフローチャートであ
る。ここで、T1〜T9サイクルは順位1位以外で符号
化する場合、T10〜T13サイクルは子供の登録が存
在しない場合のエスケープ符号化、T14〜T19サイ
クルは子供は存在するが該当する子供がない場合のエス
ケープ符号化である。
FIG. 19 is a flowchart of the pipeline operation of the primary model unit 90 and the arithmetic coding unit 86 in the data compression apparatus for the blend context shown in FIG. Here, when the T1 to T9 cycles are coded in other than the first place, the T10 to T13 cycles are escape coded when there is no child registration, and the T14 to T19 cycles have children but no corresponding children. Escape encoding in case.

【0145】この1次確率モデル90の動作にあって
は、例えばT1〜T9サイクルを例にとると、T1,T
2サイクルで入力文字に対し1つ前の文字となる子供の
有無をリードし、順位が有効に得られれば子供有りと判
断してバッファ選択部84を経由して算術符号化部86
に順位出力を行なっている。これ以外の点は図11のタ
イムチャートに示した固定次数の確率モデル部の場合と
同じである。また共通部としての算術符号化部86につ
いては、図11の算術符号化部16と全く同じである。
In the operation of the first-order probability model 90, for example, when the cycle of T1 to T9 is taken as an example, T1, T1
In two cycles, the presence or absence of a child that is the character immediately preceding the input character is read, and if the order is obtained effectively, it is determined that there is a child, and the arithmetic coding unit 86 via the buffer selecting unit 84
The ranking is output to. The other points are the same as those of the fixed-order probability model section shown in the time chart of FIG. The arithmetic coding unit 86 as a common unit is exactly the same as the arithmetic coding unit 16 in FIG.

【0146】T10〜T13サイクルの子供なしの場合
のエスケープ符号化にあっては、1次確率モデル部90
のみが動作し、算術符号化部は動作しない。またT14
〜T19サイクルの子供は存在するが該当する子供がな
い場合のエスケープ符号化については、T1〜T8と同
様の処理によりエスケープ出力を算術符号化部86で符
号化することになる。
In the escape encoding in the case where there are no children in the T10 to T13 cycles, the first-order probability model 90
Only the arithmetic unit operates, and the arithmetic coding unit does not operate. Also T14
In the escape encoding in the case where there are children in the T19 to T19 cycles but there is no corresponding child, the escape output is encoded by the arithmetic encoding unit 86 by the same processing as in T1 to T8.

【0147】図20(A)は、図15のブレンド用確率
モデル部を並列化したデータ圧縮装置で復号化された圧
縮データから文字列としてのソースデータを復元するブ
レンド文脈を対象としたデータ復元装置の基本構成であ
る。図20(A)において、このデータ復元装置は算術
復号化部126に続いてブレンド用確率モデル部128
を設けており、ブレンド用確率モデル部128は例えば
0次確率モデル部130、1次確率モデル部132及び
2次確率モデル部134を並列的に設けており、各モデ
ル部の出力を選択部136で選択して文字列を復元して
いる。またパイプライン制御部125が設けられ、算術
復号化部126とブレンド用確率モデル部128のパイ
プライン動作を行うようにしている。
FIG. 20A shows data restoration for a blend context for restoring source data as a character string from compressed data decoded by a data compression device in which the blending probability model unit of FIG. 15 is parallelized. This is the basic configuration of the device. In FIG. 20 (A), the data restoration apparatus includes an arithmetic decoding unit 126 followed by a blending probability model unit 128.
And the blending probability model unit 128 is provided with, for example, a 0th-order probability model unit 130, a first-order probability model unit 132, and a second-order probability model unit 134 in parallel, and outputs the output of each model unit to a selection unit 136. Is selected to restore the string. Further, a pipeline control unit 125 is provided so that the arithmetic decoding unit 126 and the blending probability model unit 128 perform a pipeline operation.

【0148】この図20(A)のデータ復元装置のパイ
プライン動作は、図20(B)のようになる。いま図1
7のデータ圧縮装置で得られた符号1 0101 1が
供給されたとする。また既に先行する2つの符号により
文字dcが既に復元されていたとする。まずT1サイク
ルでは符号1を算術復号化部126が入力し、2次の順
位1の符号化出力 2 を出力し、ブレンド用確率モデル
部128に設けている0次、1次、2次確率モデル部1
30,132,134に並列的に供給する。次のT2サ
イクルでは2番目の符号の先頭ビット0を入力し、算術
復号化部126は2次のエスケープ出力E2を出力す
る。このとき確率モデル部128にあっては、2次確率
モデル部134が順位1の復号化出力 2 から文字aを
復元し、選択部136を介して出力する。
The pipeline operation of the data restoration apparatus shown in FIG. 20A is as shown in FIG. Figure 1 now
It is assumed that the code 10101 1 obtained by the data compression device 7 is supplied. It is also assumed that the character dc has already been restored by the preceding two codes. First, in the T1 cycle, the code 1 is input to the arithmetic decoding unit 126, the second-order encoded output 1 2 is output, and the 0th, 1st, and 2nd order probabilities provided in the blending probability model unit 128 are provided. Model part 1
30, 132 and 134 are supplied in parallel. In the next T2 cycle, the first bit 0 of the second code is input, and the arithmetic decoding unit 126 outputs a secondary escape output E2. At this time In the probabilistic model 128, 2-order probability modeling unit 134 restores the character a the decoded output 1 2 of rank 1, and outputs via the selector 136.

【0149】次のT3サイクルでは2番目の符号のビッ
ト1を入力し、1次のエスケープ出力E1を算術復号化
部126が出力する。同時に2次確率モデル部134に
あっては、T2サイクルで出力された2次エスケープ出
力E2に基づいたエスケープ用頻度データの更新を行
う。T4サイクルでは2番目の符号のビット01を算術
復号化部126で入力し、0次の順位2の復号化出力
0 を出力する。このときブレンド用確率モデル部128
にあっては、1次確率モデル部132で1次のエスケー
プ復号化出力E1によりエスケープ用頻度データの更新
を行う。
In the next T3 cycle, bit 1 of the second code is input, and the primary escape output E1 is output by the arithmetic decoding unit 126. At the same time, the secondary probability model unit 134 updates the escape frequency data based on the secondary escape output E2 output in the cycle T2. In the T4 cycle, the bit 01 of the second code is input to the arithmetic decoding unit 126, and the 0-th order decoded output 2
Outputs 0 . At this time, the blending probability model unit 128
In the case of (1), the primary probability model unit 132 updates the escape frequency data with the primary escape decoded output E1.

【0150】T5サイクルにあっては3番目の符号1を
入力し、算術復号化部126は2次の順位1の復号化出
2 を出力する。このときブレンド用確率モデル部1
28にあっては0次確率モデル部130が動作して順位
2位の復号化出力 0 から文字bを復元して出力する。
T5サイクルで得られた復号化出力 2 は、T6サイク
ルで2次確率モデル部134による文字aの復元が行わ
れる。
In the T5 cycle, the third code 1 is input, and the arithmetic decoding unit 126 outputs a second- order first-order decoded output 12 . At this time, the blending probability model unit 1
In the 28 zero-order probability modeling unit 130 is operated from the decoded output 2 0 of the second rank to restore the character b output.
Decoded output 1 2 obtained by T5 cycle, restoration of character a by the secondary probability modeling unit 134 in cycle T6 is performed.

【0151】図21は図20(A)のデータ復元装置の
詳細である。算術復号化部126は符号入力部138、
累積値導出部140、符号空間算出部142,144、
逆数算出部146、累積頻度導出部148、逆数算出部
150で構成される。この算術復号化部126の構成及
び機能は、図12の固定次数のデータ復元装置における
算術復号化部50と同じである。
FIG. 21 shows details of the data restoration apparatus shown in FIG. The arithmetic decoding unit 126 includes a code input unit 138,
A cumulative value deriving unit 140, code space calculating units 142 and 144,
The reciprocal calculation unit 146, the cumulative frequency derivation unit 148, and the reciprocal calculation unit 150 are configured. The configuration and function of the arithmetic decoding unit 126 are the same as those of the arithmetic decoding unit 50 in the fixed-order data restoration device of FIG.

【0152】ブレンド用確率モデル部128は、0次確
率モデル部130、1次確モデル部132及び2次確
率モデル部134を有し、1次確率モデル部132に代
表して示す構成をもつ。1次確率モデル部132には文
字読出更新部156、頻度読出更新部158、累積頻度
読出更新部160及び総累積頻度読出更新部162が設
けられ、これらのブロック及び機能は図12の確率モデ
ル部52の対応するブロックと同じである。
[0152] Blends probability model unit 128 includes a zero-order probability modeling unit 130, one Tsugi確ratio model unit 132 and a secondary probability modeling unit 134 has a configuration shown as a representative in the primary probability model 132 . The primary probability model unit 132 is provided with a character reading / updating unit 156, a frequency reading / updating unit 158, a cumulative frequency reading / updating unit 160, and a total cumulative frequency reading / updating unit 162. These blocks and functions are the same as those in the probability model unit in FIG. It is the same as 52 corresponding blocks.

【0153】また順位導出部152が0次、1次及び2
次確率モデル部130,132,134に対する共通部
として設けられる。更に頻度データ格納部154も共通
部として設けられる。また3つの選択部136−1,1
36−2,136−3が設けられる。選択部136−1
は各次数の文字読出更新部156の復元文字を入力した
符号の次数に応じて選択して文字出力部164より出力
する。選択部136−2は各次数の累積頻度読出更新部
160の出力を入力し、復元した次数の出力を選択して
算術復号化部126の符号化空間算出部142,144
に出力する。選択部136−3は各次数の総累積頻度読
出更新部162の出力を入力し、復元した次数に対応す
る出力を選択して、選択した次数の総出現数を算術復号
化部126の逆数算出部146に出力する。
Also, the order deriving unit 152 determines whether the order is 0, 1 or 2
It is provided as a common part to the next probability model units 130, 132, 134. Further, a frequency data storage unit 154 is provided as a common unit. Also, three selection units 136-1 and 1
36-2 and 136-3 are provided. Selector 136-1
Is selected in accordance with the order of the input code and the restored character of each order of the character reading / updating unit 156 is selected and output from the character output unit 164. The selection unit 136-2 receives the output of the cumulative frequency read / update unit 160 of each order, selects the output of the restored order, and selects the coding space calculation units 142 and 144 of the arithmetic decoding unit 126.
Output to The selection unit 136-3 receives the output of the total cumulative frequency read / update unit 162 of each order, selects the output corresponding to the restored order, and calculates the reciprocal of the selected order by the arithmetic decoding unit 126. Output to the unit 146.

【0154】図22及び図23は、図21のデータ復元
装置のパイプライン動作のタイムチャートであり、共通
部としての算術復号化部126とブレンド用確率モデル
部128の中の1次確率モデル部132を代表して示し
ている。また図22のT1〜T13サイクルは、入力し
た符号から復元した順位1位で復号化する場合であり、
図22のT14から図23のT24サイクルは子供有り
の場合のエスケープ符号化であり、更にT25〜T38
サイクルは順位1位以外で符号化する通常の場合であ
る。 3.ブレンド文脈の全体の並列化 図24(A)はブレンド文脈を対象としたデータ圧縮装
置の他の実施例であり、この実施例にあっては、確率モ
デル部166、算術符号化部168、符号出力部170
の全てを並列化し、更に各部分をパイプライン制御部1
75でパイプライン動作させるようにしたことを特徴と
する。
FIGS. 22 and 23 are time charts of the pipeline operation of the data restoration apparatus shown in FIG. 21. The arithmetic decoding unit 126 as a common unit and the primary probability model unit in the blending probability model unit 128 are shown. 132 is shown as a representative. Further, the T1 to T13 cycles in FIG. 22 are for the case where decoding is performed in the first place restored from the input code,
The cycle from T14 in FIG. 22 to T24 in FIG. 23 is escape encoding when there is a child, and furthermore, T25 to T38.
The cycle is a normal case of encoding in a position other than the first place. 3. FIG. 24A shows another embodiment of a data compression apparatus for a blend context. In this embodiment, a probability model unit 166, an arithmetic encoding unit 168, a code Output unit 170
Are parallelized, and each part is further controlled by the pipeline control unit 1.
The pipeline operation is performed at 75.

【0155】即ち、この実施形態にあっては2次のブレ
ンド文脈を例にとっており、このため確率モデル部16
6は0次、1次及び2次の確率モデル部172,17
4,176を備え、算術符号化部168は0次、1次及
び2次の算術符号化部178,180,182を備え、
更に符号出力部170は0次、1次及び2次符号バッフ
ァ部184,186,188を備え、最終的にマージ
190で符号化が行われた次数の符号出力を選択して圧
縮データとしている。
That is, in the present embodiment, a second-order blend context is taken as an example.
6 is a zero-order, first-order, and second-order probability model units 172, 17
4,176, and the arithmetic coding unit 168 includes zero-order, first-order, and second-order arithmetic coding units 178, 180, and 182,
Further, the code output unit 170 includes zero-order, first-order, and second-order code buffer units 184, 186, and 188, and finally selects the code output of the order encoded by the merging unit 190 to obtain compressed data. .

【0156】図24(B)は図24(A)のデータ圧縮
装置のパイプライン動作のタイミングチャートである。
いま文字dcabaが入力し、既に2文字dcの符号化
が済んだ状態で文字abaの符号化を行う場合を例にと
る。まずT1サイクルにあっては、文字aを0次、1
次、2次確率モデル部172,174,176に並列的
に入力して順位を求める。
FIG. 24B is a timing chart of the pipeline operation of the data compression device of FIG.
An example will be described in which a character dcaba is input and a character aba is encoded in a state where two characters dc have already been encoded. First, in the T1 cycle, the character a is changed to the 0th order, 1st.
Next, the order is input to the second-order probability models 172, 174, and 176 in parallel to determine the order.

【0157】このとき2次確率モデル部176で符号化
済みの2文字dcの登録による順位1の符号化出力 2
が得られたとする。ここで上位の次数の順位出力が有効
に得られた場合には下位の確率モデル部にこれを伝え
て、その出力を禁止させる。したがってT1サイクルに
あっては、次確率モデル部176のみが順位1の符号
化出力 2を行う。
At this time, the encoded output I 2 of rank 1 by registering the encoded two characters dc in the second-order probability model unit 176
Is obtained. Here, when the higher-order output is effectively obtained, this is transmitted to the lower-order probability model unit to prohibit the output. In the cycle T1 Accordingly, only the secondary probability modeling unit 176 performs encoding output 1 2 of rank 1.

【0158】次のT2サイクルにあっては、次の文字b
を0次、1次、2次確率モデル部172,174,17
6に入力して順位を求める。このとき2次算術符号化部
182が2次確率モデル部176からの符号化出力 2
の算術符号化を行って、符号1を2次符号バッファ18
8に入力する。
In the next T2 cycle, the next character b
Into the 0th, 1st and 2nd order probability model units 172, 174, 17
Enter 6 and obtain the ranking. At this time, the secondary arithmetic encoding unit 182 outputs the encoded output 1 2 from the secondary probability model unit 176.
And encodes the code 1 into the secondary code buffer 18.
Enter 8

【0159】確率モデル部166のT2サイクルにあっ
ては、2次確率モデル部176で子としての2文字ca
がなく、エスケープ出力E2を生ずる。また1次確率モ
デル部174にあっても、子の文字aの登録がなく、1
次のエスケープ出力E1を生ずる。このようなエスケー
プ出力が生じた場合には、0次確率モデル部172が有
効となって0次の順位の符号化出力 0 を生ずる。
In the T2 cycle of the probability model unit 166, the two-character ca
And produces an escape output E2. Also, even in the first-order probability model unit 174, the child character a is not registered and
The next escape output E1 is produced. When such an escape output occurs, the 0th-order probability model unit 172 becomes valid and generates a 0th- order encoded output 20 .

【0160】T3サイクルにあっては3文字目aを入力
し、0次、1次、2次確率モデル部172,174,1
76で並列的に順位が求められ、この場合、2次確率モ
デル部176より2次の順位1の符号化出力 2 が有効
に得られる。このT3サイクルにあっては、0次、1
次、2次算術符号化部178,180,182が並列的
に動作して符号01,1,0を0次、1次及び2次符号
バッファ184,186,188に格納する。
In the T3 cycle, the third character a is input, and the 0th, 1st and 2nd probability models 172, 174, 1
Parallel rank determined in 76, in this case, the secondary probability modeling unit 176 from the secondary encoded output 1 2 of rank 1 is obtained effectively. In this T3 cycle, 0 order, 1
Next, the secondary arithmetic coding units 178, 180, and 182 operate in parallel to store the codes 01, 1, 0 in the zero-order, first-order, and second-order code buffers 184, 186, 188.

【0161】次のT4サイクルでは、T3サイクルで得
られた2次確率モデル部176からの順位1の符号化出
2 が2次算術符号化部182で符号化され、2次符
号バッファ部188に格納される。図25は、図24
(A)の各次数毎に並列化したデータ圧縮装置の詳細で
ある。まずブレンド用確率モデル部166は、0次、1
次、2次順位読出更新部192,194,196を並列
的に設け、続いて0次、1次、2次頻度、累積頻度読出
更新部198,200,202を前段に直列接続して並
列的に設けている。また算術符号化部168は0次、1
次、2次ごとに符号空間算出部260,262,26
4、算術符号導出部266,268,270、及びシリ
アル/パラレル変換符号出力部272,274,276
を設けている。
[0161] In the next cycle T4, the encoded output 1 2 of rank 1 from the secondary probability modeling unit 176 obtained in T3 cycle is coded in the secondary arithmetic coding unit 182, the secondary code buffer unit 188 Is stored in FIG.
3A is a detail of a data compression device parallelized for each order. First, the blending probability model unit 166 determines the 0th, 1st,
Next and second order reading / updating sections 192, 194, and 196 are provided in parallel, and subsequently, 0-order, first-order, second-order, and cumulative frequency reading / updating sections 198, 200, and 202 are connected in series at the preceding stage to be in parallel. Is provided. Arithmetic encoding section 168 calculates the order 0, 1
Next, the code space calculation units 260, 262, 26 for each of the secondary
4. Arithmetic code deriving units 266, 268, 270, and serial / parallel conversion code output units 272, 274, 276
Is provided.

【0162】算術符号化部168の各次数の符号出力
は、図24(A)の符号出力部170に設けられた0
次、1次、2次符号バッファ部184,186,188
に格納された後、マージ部190によりとりまとめられ
て圧縮データとして出力される。このマージ部190に
よるとりまとめの際に各次数の符号を独立して復元でき
るようにするため、図25(B)のデータ構造を生成し
ている。
The code output of each order of the arithmetic coding unit 168 is the same as that of the code output unit 170 provided in the code output unit 170 of FIG.
Next, primary and secondary code buffer units 184, 186, 188
After that, they are compiled by the merge unit 190 and output as compressed data. The data structure shown in FIG. 25B is generated so that the codes of the respective orders can be restored independently at the time of collection by the merging unit 190.

【0163】マージ部190で生成するデータ構造は、
先頭に0次、1次及び2次のバッファ符号のバイト長を
示す0次、1次及び2次のバイト長表示領域266,2
68,270を設け、その後ろに0次、1次,2次のバ
ッファ符号260,262,264を配置している更に
パイプライン制御部165が設けられ、ブレンド用確率
モデル部166、算術符号化部168のパイプライン動
作を行わせる。
The data structure generated by the merging unit 190 is as follows.
0th, 1st, and 2nd byte length display areas 266, 2 indicating the byte length of the 0th, 1st, and 2nd buffer codes at the beginning
68, 270, followed by a pipeline control unit 165 in which zero-order, first-order, and second-order buffer codes 260, 262, 264 are arranged, and a blending probability model unit 166, arithmetic coding The pipeline operation of the unit 168 is performed.

【0164】図26は、図25(A)のデータ圧縮装置
のパイプライン動作のタイムチャートである。まずT1
〜T10サイクルについて、図25(A)のブレンド用
確率モデル部166における2次、1次及び0次の各入
力文字に対する順位の導出と頻度データの更新の処理を
示している。また算術符号化部168における2次、1
次及び0次の算術符号化処理については、紙面の都合で
T2〜T15サイクルに直列的に示しているが、実際に
はT2サイクルから並列的に算術符号化の処理が行われ
る。
FIG. 26 is a time chart of the pipeline operation of the data compression device of FIG. First T1
25 shows the process of deriving the rank for each of the secondary, primary, and zeroth input characters and updating the frequency data in the blend probability model unit 166 of FIG. Also, the second order, 1
Although the next and zeroth-order arithmetic coding processes are shown in series in cycles T2 to T15 for convenience of space, the arithmetic coding processes are actually performed in parallel from the T2 cycle.

【0165】尚、図26における確率モデル部166及
び算術符号化部168のパイプライン動作は、図9の固
定次数の場合と基本的に同じである。図27は、図24
のデータ圧縮装置で符号化された圧縮データを復元する
データ復元装置の基本構成である。このデータ復元装置
は符号入力部212、算術復号化部214及び確率モデ
ル部216で構成される。符号入力部212には分離部
211が設けられ、例えば図25(B)のデータ構造を
もつ圧縮データを入力し、並列的に設けられた0次、1
次、2次符号バッファ部218,220,222に各次
数ごとの符号を格納できるようにしている。
The pipeline operations of the probability model unit 166 and the arithmetic coding unit 168 in FIG. 26 are basically the same as those of the fixed order shown in FIG. FIG.
1 is a basic configuration of a data decompression device that decompresses compressed data encoded by the data compression device of FIG. This data restoration device includes a code input unit 212, an arithmetic decoding unit 214, and a probability model unit 216. The code input unit 212 is provided with a separating unit 211, for example, to input compressed data having the data structure of FIG.
Next, a code for each order can be stored in the secondary code buffer units 218, 220, and 222.

【0166】算術復号化部214は0次、1次及び2次
算術復号化部224,226,228を並列的に設けて
いる。ブレンド用確率モデル部216は0次、1次、2
次確率モデル部230,232,234を並列的に設け
ており、それぞれの復元文字を選択部236に入力して
文字列を出力している。図27(A)のデータ復元装置
のパイプライン動作は、図27(B)のようになる。こ
のパイプライン動作は図24(A)で圧縮された符号1
0101 1を入力して復元する場合であり、既に文
字cdが復元された状態での動作としている。T1サイ
クルにあっては、2次符号バッファ部222に分離され
た符号1を2次算術復号化部228に出力し、2次の順
位1位の符号化出力 2 を得る。
The arithmetic decoding unit 214 has 0-order, first-order, and second-order arithmetic decoding units 224, 226, and 228 provided in parallel. The blending probability model unit 216 includes a zero-order, a first-order,
Next probability model units 230, 232, and 234 are provided in parallel. Each restored character is input to the selection unit 236 and a character string is output. The pipeline operation of the data restoration device in FIG. 27A is as shown in FIG. This pipeline operation corresponds to code 1 compressed in FIG.
01011 is input to restore, and the operation is performed in a state where the character cd has already been restored. In the T1 cycle, the code 1 separated by the secondary code buffer unit 222 is output to the secondary arithmetic decoding unit 228, and the first encoded output 12 of the second order is obtained.

【0167】次のT2サイクルでは2次符号バッファ部
222からのエスケープ符号0出力、1次符号バッファ
部220からのエスケープ符号1出力、更に0次符号バ
ッファ218からの符号出力01を入力して、2次、1
次、0次算術復号化部228,226,224は並列的
に復号化を行い、2次エスケープ出力E2、1次エスケ
ープ出力E1、及び0次の順位2の復号化出力 0 を生
ずる。
In the next T2 cycle, the escape code 0 output from the secondary code buffer unit 222, the escape code 1 output from the primary code buffer unit 220, and the code output 01 from the 0th order code buffer 218 are input. Secondary, 1
Next, the zero-order arithmetic decoding unit 228,226,224 performs parallel decoding, secondary escape output E2,1 primary escape output E1, and produces a decoded output 2 0 of the zero-order rank 2.

【0168】このT2サイクルにあっては、同時に2次
確率モデル部234がT1サイクルで得られた順位1位
の復号化出力 2 を受けて文字aを復元して出力する。
T3サイクルにあっては、2次符号バッファ部222よ
り3番目の符号1の出力が2次算術復号化部228に対
して行われ、順位1位の符号化出力 2 を生ずる。同時
にT3サイクルにあっては、2次確率モデル部234に
よるエスケープ出現数の更新、1次確率モデル部232
による同じくエスケープ出現数の更新、更に0次確率モ
デル部230による順位2位の文字bの復元出力が行わ
れる。
[0168] In the this T2 cycle, and outputs the restored character a 2-order probability modeling unit 234 receives the decoded output 1 2 of first ranking obtained in T1 cycle simultaneously.
In the cycle T3, the output of the secondary code buffer unit 222 from the third code 1 is performed on the secondary arithmetic decoding unit 228 produces a coded output 1 2 of first ranking. At the same time, in the T3 cycle, the secondary probability model unit 234 updates the number of escape occurrences, and the primary probability model unit 232
, The number of escape occurrences is updated, and the 0th-order probability model unit 230 restores and outputs the second character b.

【0169】T3サイクルで2次算術符号化部228で
得られた復号化出力 2 は、T4サイクルで2次確率モ
デル部234により順位1位の文字aの復元出力が行わ
れる。図28は図27(A)のデータ復元装置の詳細で
あり、算術復号化部214及びブレンド用確率モデル部
216について示している。算術復号化部214は0
次、1次、2次ごとにパラレル/シリアル変換符号入力
部278,280,282、算術符号順位導出部28
4,286,288及び符号空間算出部290,29
2,294を並列的に設けている。
The decoded output I 2 obtained by the secondary arithmetic coding unit 228 in the T3 cycle is restored and output by the second-order probability model unit 234 of the character a having the first rank in the T4 cycle. FIG. 28 shows details of the data restoration apparatus of FIG. 27A, and shows the arithmetic decoding unit 214 and the blending probability model unit 216. The arithmetic decoding unit 214 has 0
Next, primary and secondary parallel / serial conversion code input units 278, 280, 282, arithmetic code order derivation unit 28
4,286,288 and code space calculation units 290,29
2,294 are provided in parallel.

【0170】このため、符号入力部212で分離された
0次バッファ符号260、1次バッファ符号262及び
2次バッファ符号264のそれぞれを並列に入力して、
符号空間における順位を導出するための累積出現頻度を
算出する。確率モデル部216は0次、1次、2次ごと
に順位・頻度・累積頻度読出更新部246,248,2
50及び文字読出更新部252,254,256を設け
ており、いずれかの次数の部分で復元した文字を選択部
258で選択して出力している。このように各次数ごと
に並列的に設けられた算術復号化部214及びブレンド
用確率モデル部216は、パイプライン制御部215に
よりパイプライン動作が行われる。
For this reason, the 0-order buffer code 260, the primary buffer code 262 and the secondary buffer code 264 separated by the code input unit 212 are input in parallel,
The cumulative appearance frequency for deriving the rank in the code space is calculated. The probability model unit 216 reads and updates the rank / frequency / cumulative frequency reading units 246, 248, and 2 for each of the 0th, 1st, and 2nd orders.
50 and character reading / updating units 252, 254, 256 are provided, and the character restored at any order is selected by the selection unit 258 and output. As described above, the pipeline operation is performed by the pipeline control unit 215 on the arithmetic decoding unit 214 and the blending probability model unit 216 provided in parallel for each order.

【0171】図29のタイムチャートは図28のデータ
復元装置のパイプライン動作である。まず算術復号化部
214におけるビット符号入力、累積出現頻度算出、符
号化空間算出については、0次、1次、2次の処理を共
通に示している。次のブレンド用確率モデル部216に
ついては、2次、1次、0次に分けて並列的な処理を示
している。この各次数における算術復号化部及び確率モ
デル部のパイプライン動作は、図15,図16に示した
固定文脈の場合の算術復号化部及び確率モデル部と基本
的に同じである。
The time chart of FIG. 29 shows the pipeline operation of the data restoration device of FIG. First, regarding the bit code input, the cumulative appearance frequency calculation, and the coding space calculation in the arithmetic decoding unit 214, the 0th-order, first-order, and second-order processes are commonly shown. The next blending probability model unit 216 shows the parallel processing separately for the second order, first order, and zero order. The pipeline operation of the arithmetic decoding unit and the probability model unit in each order is basically the same as that of the arithmetic decoding unit and the probability model unit in the case of the fixed context shown in FIGS.

【0172】このように各次数の算術復号化部と確率モ
デル部とが独立して動作することで、復号処理の速度を
向上できる。またエスケープ符号の関係で復元処理を途
中まで実行しても無効になる場合が生ずるが、各次数ご
とに独立していることから復元処理に遅れを生ずること
はない。 4.ハッシュ構造による頻度データのアクセス 図30は本発明のデータ圧縮装置及びデータ復元装置の
確率モデル部で使用する頻度データ格納部のデータを読
出更新する際のアクセス構造の実施形態であり、この実
施例にあっては内部ハッシュ構造を使用したことを特徴
とする。
As described above, the arithmetic decoding section of each order and the probability model section operate independently, so that the speed of decoding processing can be improved. Even if the restoration process is executed halfway due to the escape code, it may become invalid. However, since the restoration process is independent for each order, there is no delay in the restoration process. 4. Access of Frequency Data Using Hash Structure FIG. 30 shows an embodiment of an access structure for reading and updating data in a frequency data storage unit used in a probability model unit of a data compression device and a data decompression device according to the present invention. Is characterized by using an internal hash structure.

【0173】図30において、内部ハッシュ構造は内部
ハッシュ関数部300、出現頻度モデルデータ格納部3
02、一致/不一致検出部304及びリハッシュ関数部
306で構成される。出現頻度モデルデータ格納部30
2の検索は、入力した注目文字に任意の次数をもつ直前
の文字列を加えた文字列を内部ハッシュ関数部300に
与えてハッシュアドレスを求め、このハッシュアドレス
によって出現頻度モデルデータ格納部302を検索し、
例えば出現頻度である確率や順位を読み出す。
In FIG. 30, the internal hash structure includes an internal hash function unit 300 and an appearance frequency model data storage unit 3.
02, a match / mismatch detection unit 304 and a rehash function unit 306. Appearance frequency model data storage unit 30
In the search of No. 2, a character string obtained by adding the immediately preceding character string having an arbitrary degree to the input character of interest is given to the internal hash function unit 300 to obtain a hash address, and the appearance frequency model data storage unit 302 is stored using the hash address. Search and
For example, a probability or a rank, which is an appearance frequency, is read.

【0174】一致/不一致検出部304は、ハッシュア
ドレスにより出現頻度モデルデータ格納部302から検
索した文字列と入力文字列との一致、不一致を判定して
おり、一致すればそのアドレスの頻度データを出力す
る。不一致となった場合、ハッシュアドレスの衝突によ
りリハッシュされたアドレスに登録されていることか
ら、ハッシュ関数部306を起動してハッシュ関数の生
成をやり直し、再度、出現頻度モデルデータ格納部30
2を検索し、直前の文字列とその下に位置する入力文字
の検索を行う。もちろん、登録更新についても同様であ
る。
The match / mismatch detection unit 304 determines whether or not the character string retrieved from the appearance frequency model data storage unit 302 matches the input character string based on the hash address. Output. In the case of a mismatch, since the hash function is registered at the rehashed address due to the collision of the hash address, the hash function unit 306 is activated to generate the hash function again, and again the appearance frequency model data storage unit 30
2 is searched, and the character string immediately before and the input character located thereunder are searched. Of course, the same applies to registration update.

【0175】図31は出現頻度モデル部に設ける出現頻
度データアクセス構造の他の実施例であり、この実施例
は内部ハッシュ構造により直前の文字列(文脈)の検
索,登録,更新を行い、外部ハッシュ構造により直前の
文字列(文脈)の下に存在する入力文字(注目文字)の
検索,登録,更新を行うようにしたことを特徴とする。
まず内部ハッシュ構造は、内部ハッシュ関数部300、
出現頻度モデルデータ格納部302、一致/不一致検出
部304及びリハッシュ関数部306で構成される。一
方、入力した注目文字の外部ハッシュ構造は注目文字デ
ータ格納部308及び一致/不一致検出部310で構成
される。
FIG. 31 shows another embodiment of the appearance frequency data access structure provided in the appearance frequency model unit. In this embodiment, the immediately preceding character string (context) is searched, registered, and updated using an internal hash structure. The input character (attention character) existing under the immediately preceding character string (context) is searched, registered, and updated by a hash structure.
First, the internal hash structure includes an internal hash function unit 300,
It comprises an appearance frequency model data storage unit 302, a match / mismatch detection unit 304, and a rehash function unit 306. On the other hand, the external hash structure of the input target character is constituted by the target character data storage unit 308 and the match / mismatch detection unit 310.

【0176】例えば入力文字を注目文字として直前の文
字列と注目文字を合わせた確率または順位などの出現頻
度を読み出す際には、直前の文字列を内部ハッシュ関数
部300に与えてハッシュアドレスを求め、出現頻度モ
デルデータ格納部302をアクセスして文字列データを
読み出す。直前文字列に一致すれば外部ハッシュ構造を
とる注目文字データ格納部308をアクセスし、直前文
字列の下に位置する注目文字を一致/不一致検出部31
0で一致が得られるまでリスト検索を繰り返す。そし
て、リスト検索により注目文字と注目文字データ格納部
308からの読出し文字との一致が得られれば、その出
現頻度を出力する。
For example, when an input character is set as a target character and the appearance frequency such as the probability or rank of the immediately preceding character string and the target character is read, the previous character string is given to the internal hash function unit 300 to obtain a hash address. The character string data is read out by accessing the appearance frequency model data storage unit 302. If the character string matches the immediately preceding character string, the attention character data storage unit 308 having an external hash structure is accessed, and the attention character located below the immediately preceding character string is matched / mismatched.
The list search is repeated until a match with 0 is obtained. Then, if the target character matches the character read from target character data storage unit 308 by the list search, the appearance frequency is output.

【0177】このような図30の内部ハッシュ構造ある
いは図30の内部ハッシュ構造と外部ハッシュ構造を組
み合わせたアクセスを行うことで、データ圧縮及びデー
タ復元における出現頻度モデル部における任意の次数を
もつ文脈に依存した文字の出現頻度の検索,登録,更新
を高速に行うことができる。尚、ブレンド文脈を対象と
した圧縮復元については、算術符号化と復号化を例にと
っているが、これ以外に動的ハフマン符号化及び復号化
や自己組織化符号の一種であるスプレイ符号化及び復号
化などを行うようにしてもよいことはもちろんである。 5.ワードストリーム方向での符号化と復号化 図32は複数バイトで構成されたワードデータをワード
単位に符号化するデータ圧縮装置のブロック図であり、
1ワードを構成する複数のバイトデータをバイトストリ
ーム方向で各バイトデータごとに符号化することを特徴
とする。
By performing such access using the internal hash structure shown in FIG. 30 or the combination of the internal hash structure and the external hash structure shown in FIG. 30, a context having an arbitrary degree in the appearance frequency model part in data compression and data restoration is obtained. The search, registration, and update of the appearance frequency of the dependent character can be performed at high speed. As for the compression / decompression for the blend context, arithmetic coding and decoding are taken as examples, but dynamic Huffman coding and decoding and spray coding and decoding which are a kind of self-organizing code are also used. Needless to say, the conversion may be performed. 5. Encoding and Decoding in Word Stream Direction FIG. 32 is a block diagram of a data compression device that encodes word data composed of a plurality of bytes in word units.
It is characterized in that a plurality of byte data constituting one word are encoded for each byte data in the byte stream direction.

【0178】図32においてデータ圧縮装置は、nバイ
ト構成のワードデータを例にとると、バイト配列変換
部、nバイト分のバイト単位符号化部502−1,50
2−2,・・・502−n、及び符号マージ部503で
構成される。バイト配列変換部500は、ソースデータ
からnバイトのバイトストリームとなる1ワード分のワ
ードデータを入力し、各バイト位置ごとに分離して並列
配置する。
In FIG. 32, when word data having an n-byte structure is taken as an example, the data compression apparatus has a byte array conversion section and n-byte byte unit coding sections 502-1 and 50-2.
2-2,..., 502-n, and a code merging unit 503. The byte array conversion unit 500 receives word data of one word, which becomes an n-byte byte stream from the source data, and separates and arranges each byte position in parallel.

【0179】即ち、バイトデータの1バイト目,2バイ
ト目,・・・nバイト目の各バイトデータに分離して各
バイト位置ごとにワードストリーム方向に配置する。こ
のバイト配列変換部500には、現時点で入力されたワ
ードデータ以外に、既に符号化された先行するワードデ
ータのバイト位置ごとのバイトデータも保存されてい
る。
That is, the first byte, the second byte,..., The n-th byte of the byte data are separated and arranged in the word stream direction for each byte position. The byte array conversion unit 500 stores, in addition to the currently input word data, byte data for each byte position of the preceding encoded word data.

【0180】この結果、バイト単位符号化部502−
1,502−2〜502−nに対しては、現時点のワー
ドデータと既に符号化されたワードデータの同一バイト
位置の各バイトデータがワードストリーム方向に並んだ
バイトデータ列を保持することになる。この1バイト目
からnバイト目までの複数ワード分の同一バイト位置の
入力バイトデータ及び符号化済みバイトデータ列を保持
することで、各バイト位置のバイトデータ列がワードス
トリーム方向のバイトデータ列を構成している。
As a result, the byte unit encoding unit 502-
For 1,502-2 to 502-n, each byte data at the same byte position of the current word data and the already encoded word data holds a byte data string in which the byte data is arranged in the word stream direction. . By holding the input byte data and the encoded byte data sequence at the same byte position for a plurality of words from the first byte to the n-th byte, the byte data sequence at each byte position becomes the byte data sequence in the word stream direction. Make up.

【0181】バイト単位符号化部502−1〜502−
nのそれぞれは、各バイト位置のワードストリーム方向
のバイト列を対象に、辞書型符号化あるいは確率統計型
符号化を行う。辞書型符号化としては、LZW法やLZ
SS法などの代表的な方法が使用される。また確率統計
型の符号化としては、多値算術符号化あるいは動的ハフ
マン符号化やスプレイ符号化などの復号器符号化方法が
使用される。
Byte unit encoding units 502-1 to 502-
Each of n performs dictionary-type coding or probability-statistic-type coding on a byte sequence in the word stream direction at each byte position. Dictionary coding includes LZW method and LZ method.
A typical method such as the SS method is used. As the coding of the probability statistical type, a decoder coding method such as multi-level arithmetic coding or dynamic Huffman coding or spray coding is used.

【0182】符号マージ部503は、バイト単位符号化
部502−1〜502−nのそれぞれで並列的に符号化
された入力ワードデータの各バイト位置のバイトデータ
の符号化を取りまとめて圧縮データとして出力する。符
号マージ部503による圧縮バイトデータのまとめ方に
は、ワードデータと同じバイトフォーマットのバイト位
置に各圧縮バイトデータを均一に配置してワード単位に
まとめる方法と、各バイト位置の圧縮バイトデータをフ
ァイル単位にまとめて圧縮データとする方法の2つがあ
る。
The code merging unit 503 collects the encoding of the byte data at each byte position of the input word data encoded in parallel by each of the byte unit encoding units 502-1 to 502-n and generates the compressed data. Output. The method of collecting the compressed byte data by the code merging unit 503 includes a method of uniformly arranging the compressed byte data at byte positions in the same byte format as the word data and collecting them in word units, and a method of combining the compressed byte data at each byte position into a file There are two methods of collecting compressed data in units.

【0183】図33は図32のデータ圧縮装置における
ワードストリーム方向での符号化処理のタイムチャート
であり、バイト単位符号化部502−1,502−2,
502−nに対応して、図33(A)〜(C)に1バイ
ト目,2バイト目及びnバイト目の符号化処理を表わし
ている。まずT1サイクルにあっては、第1ワード目の
第1バイト目からnバイト目の各バイトデータについ
て、バイト単位符号化部502−1〜502−nのそれ
ぞれでバイトデータの符号化を行っている。この場合、
最初に1バイト目の符号化が終了し、続いて2バイト目
の符号化が終了し、最後にnバイト目の符号化が終了し
ている。
FIG. 33 is a time chart of the encoding process in the word stream direction in the data compression apparatus shown in FIG. 32. The byte unit encoding sections 502-1, 502-2,
FIGS. 33A to 33C show the encoding process of the first byte, the second byte, and the n-th byte corresponding to 502-n. First, in the T1 cycle, each of the byte data from the first byte to the n-th byte of the first word is encoded by each of the byte unit encoding units 502-1 to 502-n. I have. in this case,
First, the encoding of the first byte is completed, then the encoding of the second byte is completed, and finally, the encoding of the nth byte is completed.

【0184】符号化が済んだ圧縮バイトデータは、符号
化マージ部503のバッファに格納してまとめられた後
に、所定のタイミングで圧縮データとして出力される。
第1ワード目の処理サイクルT1は、最後に符号化処理
が終了したnバイト目のバイト単位符号化部502−n
の処理終了タイミングから一定時間を経過した時間であ
り、符号化処理の内容によって変動する。
The encoded compressed byte data is stored in the buffer of the encoding merge unit 503 and is collected, and then output as compressed data at a predetermined timing.
The processing cycle T1 of the first word is the n-th byte unit encoding unit 502-n at the end of the encoding process.
This is the time when a certain time has elapsed from the processing end timing, and varies depending on the content of the encoding processing.

【0185】次のT2サイクルにあっては、2ワード目
の第1バイト目からnバイト目までの各バイトデータの
並列的な符号化をバイト単位符号化部502−1〜50
2−nで行っており、この場合には図33(B)の2バ
イト目の符号化処理が最後となっている。次のT3サイ
クルは第3ワード目の符号化であり、以下最終ワードデ
ータまで同様な処理を繰り返す。
In the next T2 cycle, the parallel encoding of each byte data from the first byte to the n-th byte of the second word is performed by the byte unit encoding units 502-1 to 50-2.
2-n, and in this case, the encoding process of the second byte in FIG. 33B is the last. The next T3 cycle is the encoding of the third word, and the same processing is repeated until the last word data.

【0186】図34は、図32において符号マージ部5
03でワード単位に圧縮バイトデータをまとめる場合の
符号化フローチャートである。まずステップS1で、n
バイト構成のワードデータを入力し、ステップS2で、
バイト配列変換部500がワードデータをバイト単位に
分割する。続いてステップS3で、分割された各バイト
位置のバイトデータごとにバイト単位符号化部502−
1〜502−nで並列的に符号化が行われる。そしてス
テップS4で各符号データをワード単位に結合し、ステ
ップS5で最終ワードデータの符号化が判別されるま
で、ステップS1〜S4の処理を繰り返す。
FIG. 34 is a block diagram of the code merging unit 5 shown in FIG.
13 is an encoding flowchart in a case where compressed byte data is grouped in words in 03. First, in step S1, n
Byte-structured word data is input, and in step S2,
The byte array conversion unit 500 divides the word data into bytes. Subsequently, in step S3, the byte unit encoding unit 502-
Encoding is performed in parallel in 1 to 502-n. Then, in step S4, each code data is combined in word units, and the processing in steps S1 to S4 is repeated until the encoding of the last word data is determined in step S5.

【0187】図35は図34で圧縮バイトデータをワー
ド単位にまとめる場合の圧縮データのフォーマット説明
図である。ワード単位にまとめる圧縮データは、ヘッダ
504と圧縮データ506で構成される。ヘッダ504
には1ワードデータを構成するnバイト分のバイトヘッ
ダ504−1,504−2,・・・504−nが設けら
れている。
FIG. 35 is an explanatory diagram of the format of the compressed data in the case where the compressed byte data is grouped in words in FIG. The compressed data grouped in words is composed of a header 504 and compressed data 506. Header 504
Are provided with byte headers 504-1, 504-2,... 504-n for n bytes constituting one word data.

【0188】このバイトヘッダ504−1〜504−n
のそれぞれには、各バイト位置での圧縮バイト数と、圧
縮バイトデータをワード単位にまとめた場合の各バイト
位置でのデータ数が格納されている。圧縮データ504
は符号化前のワードデータと同様、nバイト構成で1ワ
ードとしている。nバイト構成のワードデータの各バイ
ト位置には、1バイト目圧縮データ、2バイト目圧縮デ
ータ、・・・nバイト目圧縮データのそれぞれが格納さ
れている。
The byte headers 504-1 to 504-n
Each stores the number of compressed bytes at each byte position and the number of data at each byte position when the compressed byte data is put together in word units. Compressed data 504
Is a word having an n-byte configuration, like word data before encoding. At each byte position of the word data having the n-byte structure, the first byte compressed data, the second byte compressed data,..., the n-th byte compressed data are stored.

【0189】各バイト位置に格納される対応するバイト
データの圧縮データは、圧縮データのサイズ、即ちバイ
ト数が異なっているため、ワード単位の符号化で各バイ
トデータの圧縮バイトデータを均等に収納しても、実際
の各バイト位置での圧縮バイトデータの数は異なり、オ
ーバフローすると次の圧縮バイトデータ格納のワード位
置に格納する。
Since the compressed data of the corresponding byte data stored in each byte position has a different size of the compressed data, that is, the number of bytes, the compressed byte data of each byte data is uniformly stored by encoding in words. However, the actual number of compressed byte data at each byte position is different, and when overflow occurs, the data is stored at the next word position for storing compressed byte data.

【0190】図36は4バイト構成のワードデータを例
にとって、ワードデータ508−1,508−2,50
8−3,508−4の4ワードを順次入力して符号化し
た場合の圧縮データを表わしている。ワードデータ50
8−1は、バイト順にA1,A2,A3,A4の内容を
もっており、これが符号化により圧縮データ510−1
において圧縮バイトデータa1〜a4に圧縮されてい
る。次のワードデータ508−2はバイトデータB1〜
B4で構成され、符号化により圧縮データ510−2の
ように、圧縮バイトデータb1〜b4に圧縮されてい
る。
FIG. 36 shows word data 508-1, 508-2, 50 by taking word data having a 4-byte structure as an example.
8 represents compressed data when four words of 8-3 and 508-4 are sequentially input and encoded. Word data 50
8-1 has the contents of A1, A2, A3, and A4 in byte order, which are compressed data 510-1 by encoding.
Are compressed into compressed byte data a1 to a4. The next word data 508-2 is byte data B1 to B1.
B4, and are compressed into compressed byte data b1 to b4 like compressed data 510-2 by encoding.

【0191】ワードデータ508−3はバイトデータC
1〜C4で構成され、符号化により圧縮データ510−
3のように圧縮バイトデータc1〜c4となっている。
更にワードデータ508−4はバイトデータD1〜D4
で構成され、符号化により圧縮データ510−4で圧縮
バイトデータd1〜d4となっている。圧縮データ51
0−1〜510−4における各圧縮バイトデータは、そ
れぞれ異なったバイト数であり、例えば圧縮バイトデー
タa1,a2,a4は0.25バイトであり、圧縮バイ
トデータa3は0.5バイトとなっている。図35のワ
ード単位にまとめる圧縮データのフォーマットにあって
は、図37(A)のようなヘッダ504と図37(B)
のような圧縮データ506が、図36のワード単位の符
号化で得られた510−1〜510−4からまとめられ
る。
Word data 508-3 is byte data C
1 to C4, and compressed data 510-
3, compressed byte data c1 to c4.
Further, the word data 508-4 includes byte data D1 to D4.
The compressed data 510-4 is converted into compressed byte data d1 to d4 by encoding. Compressed data 51
Each of the compressed byte data in 0-1 to 510-4 has a different number of bytes. For example, the compressed byte data a1, a2, and a4 are 0.25 bytes, and the compressed byte data a3 is 0.5 bytes. ing. In the format of the compressed data to be summarized in word units in FIG. 35, the header 504 as shown in FIG.
The compressed data 506 as shown in FIG. 36 is put together from 510-1 to 510-4 obtained by encoding in word units in FIG.

【0192】まず図37(B)のワード単位の圧縮デー
タ506を形成するための図36の圧縮データ510−
1〜510−3の配置を説明する。最初のワードデータ
508−1の符号化で得られた圧縮データ510−1の
圧縮バイトデータa1,a2,a3,a4については、
ワードデータと同じ4バイトのバイト構成をもつ圧縮ワ
ードデータ512−1の1バイト目から4バイト目の対
応するバイト位置に対し均等に配置する。
First, the compressed data 510- in FIG. 36 for forming the compressed data 506 in word units in FIG.
The arrangement of 1 to 510-3 will be described. The compressed byte data a1, a2, a3, and a4 of the compressed data 510-1 obtained by encoding the first word data 508-1 are as follows:
The compressed word data 512-1 having the same 4-byte structure as the word data is evenly arranged at the corresponding byte positions from the first byte to the fourth byte.

【0193】即ち、圧縮ワードデータ512−1の1バ
イト目には圧縮バイトデータa1が格納され、2バイト
目には圧縮バイトデータa2が格納され、3バイト目に
は圧縮バイトデータa3が格納され、4バイト目には圧
縮バイトデータa4が格納される。次のワードデータ5
08−2の符号化で得られた図36の圧縮データ510
−2の圧縮バイトデータb1,b2,b3,b4につい
ても同様に、図37(B)の先頭の圧縮ワードデータ5
12−1の各バイト位置にb1,b2,b3,b4のよ
うに割り当てられる。以下同様に、図36の3ワード目
と4ワード目の圧縮データ510−3,510−4につ
いても、図37(B)のように割り当てる。
That is, compressed byte data a1 is stored in the first byte of the compressed word data 512-1, compressed byte data a2 is stored in the second byte, and compressed byte data a3 is stored in the third byte. The fourth byte stores compressed byte data a4. Next word data 5
The compressed data 510 of FIG. 36 obtained by the encoding of 08-2
Similarly, compressed byte data b1, b2, b3, and b4 of -2 shown in FIG.
Each byte position of 12-1 is assigned as b1, b2, b3, b4. Similarly, compressed data 510-3 and 510-4 of the third and fourth words in FIG. 36 are also allocated as shown in FIG.

【0194】ここで4ワード目の圧縮バイトデータd1
〜d4のうち、圧縮バイトデータd1については先頭の
圧縮ワードデータ512−1の1バイト目に格納できる
が、残りの圧縮バイトデータd2〜d4については、先
頭の圧縮ワードデータ512−1の2バイト目、3バイ
ト目、4バイト目がいっぱいになっているため、次の圧
縮ワードデータ512−2の対応するバイト位置に格納
する。
Here, the compressed byte data d1 of the fourth word
Among the compressed byte data d1, the first byte of the compressed word data 512-1 can be stored in the first byte, but the remaining compressed byte data d2 to d4 are two bytes of the first compressed word data 512-1. Since the first, third, and fourth bytes are full, they are stored in the corresponding byte positions of the next compressed word data 512-2.

【0195】このような4ワード分に圧縮バイトデータ
を格納した圧縮ワードデータ512−1,512−2を
まとめて出力する場合、ヘッダ504には1バイト目か
ら4バイト目の各圧縮バイトデータのバイト数と、圧縮
ワードデータ512−1,512−2のそれぞれにおけ
る各バイト位置での圧縮バイトデータの数を格納してい
る。
When the compressed word data 512-1 and 512-2 in which the compressed byte data are stored in such four words are output collectively, the header 504 includes the first to fourth bytes of each compressed byte data. The number of bytes and the number of compressed byte data at each byte position in each of the compressed word data 512-1 and 512-2 are stored.

【0196】例えばバイトヘッダ504−1にあって
は、圧縮データバイトa1〜d1の合計バイト数は1バ
イトであり、圧縮ワードデータ512−1の1バイト目
には4つの圧縮バイトデータa1,b1,c1,d1が
入っていることから、このデータ数4を示し、次の圧縮
ワードデータ512−2の1バイト目のデータ数は0で
あることから0を示し、「4,0」としている。
For example, in the byte header 504-1, the total number of the compressed data bytes a1 to d1 is one, and the first byte of the compressed word data 512-1 is the four compressed byte data a1, b1. , C1, and d1, the number of data 4 is shown. Since the number of data in the first byte of the next compressed word data 512-2 is 0, 0 is shown, and "4, 0" is set. .

【0197】このようなヘッダ504の各バイト位置ご
とのバイトヘッダ504−1,504−4のヘッダ情報
を使用すれば、ワード単位にまとめられた圧縮ワードデ
ータ512−1,512−2の中から各ワードごとの4
バイト分に対応した圧縮バイトデータを分離することが
できる。図38は図32の符号マージ部503におい
て、符号化済みの圧縮バイトデータを各バイト位置のフ
ァイル単位にまとめる場合の符号化処理のフローチャー
トである。まずステップS1でnバイト構成のワードデ
ータを入力し、ステップS2でバイト配列変換部500
がバイト単位にn個のバイトデータに分割し、ステップ
S3でバイト単位符号化部502−1〜502−nが並
列的に各バイトデータを符号化する。
By using the header information of the byte headers 504-1 and 504-4 for each byte position of the header 504, the compressed word data 512-1 and 512-2 arranged in word units can be used. 4 for each word
Compressed byte data corresponding to bytes can be separated. FIG. 38 is a flowchart of an encoding process when the encoded merged byte data is combined into a file unit at each byte position in the code merging unit 503 in FIG. First, in step S1, word data having an n-byte structure is input, and in step S2, a byte array conversion unit 500 is input.
Is divided into n byte data in byte units, and in step S3, the byte unit encoding units 502-1 to 502-n encode each byte data in parallel.

【0198】このようなステップS1〜S3のワードス
トリーム方向でのバイト単位の並列符号化を最終ワード
データの符号化終了がステップS4で判別されるまで繰
り返される。一連のワードストリームの符号化が終了す
ると、ステップS5で、ファイル単位にまとめられた各
バイト位置ごとの符号データを結合して圧縮データとし
て出力する。
The parallel encoding in units of bytes in the word stream direction in steps S1 to S3 is repeated until the end of encoding of the last word data is determined in step S4. When the encoding of the series of word streams is completed, in step S5, the code data for each byte position, which are grouped in file units, are combined and output as compressed data.

【0199】図39は図38の圧縮バイトデータをファ
イル単位にまとめる場合の圧縮データのフォーマットで
ある。この圧縮データのフォーマットは、ヘッダ514
と圧縮データ516で構成される。ヘッダ514にはワ
ードデータの各バイト位置に対応してn個のファイルヘ
ッダ514−1〜514−nが設けられる。ファイルヘ
ッダには各ファイルの圧縮データバイトのバイト数n
1,n2,・・・nnが格納される。圧縮データ516
には1バイト目、2バイト目、・・・nバイト目の各圧
縮データ516−1〜516−nが1つのファイル単位
で格納されている。
FIG. 39 shows the format of the compressed data when the compressed byte data of FIG. 38 is put together in file units. The format of this compressed data is the header 514
And compressed data 516. The header 514 is provided with n file headers 514-1 to 514-n corresponding to each byte position of the word data. In the file header, the number of bytes n of the compressed data bytes of each file
1, n2,... Nn are stored. Compressed data 516
Stores compressed data 516-1 to 516-n in the first byte, the second byte,..., The nth byte in one file unit.

【0200】図40は、図36の4ワードのワードデー
タ508−1〜508−4の符号化で得られた圧縮デー
タ510−1〜510−4を例にとって図39のファイ
ル単位にまとめた圧縮データの具体例である。まず図4
0(B)のファイル単位の圧縮データ516にあって
は、1バイト目、2バイト目、3バイト目、4バイト目
の各バイト位置ごとにバイトファイル516−1〜51
6−4が設けられている。
FIG. 40 shows an example of compressed data 510-1 to 510-4 obtained by encoding the 4-word word data 508-1 to 508-4 of FIG. It is a specific example of data. First, FIG.
In the compressed data 516 in the file unit of 0 (B), the byte files 516-1 to 516-51 are provided for each byte position of the first byte, the second byte, the third byte, and the fourth byte.
6-4 are provided.

【0201】各バイトファイル516−1〜516−4
には図36で得られた符号化による4ワード分の圧縮バ
イトデータの各圧縮バイトデータがそのバイト位置に対
応して格納されている。このファイル単位の圧縮データ
516の格納状態に対応して、図40(A)のヘッダ5
14におけるファイルヘッダ514−1〜514−4の
それぞれには、各バイトファイル516−1〜516−
4の圧縮バイトデータのバイト数とそのデータ数が格納
されている。なお、データ数は基本的には全て同じであ
る。
Each byte file 516-1 to 516-4
Stores compressed byte data of the compressed byte data of 4 words by the encoding obtained in FIG. 36 corresponding to the byte position. According to the storage state of the compressed data 516 in file units, the header 5 in FIG.
14, each of the file headers 514-1 to 514-4 has a byte file 516-1 to 516-46.
4 stores the number of bytes of the compressed byte data and the number of data. The number of data is basically the same.

【0202】このようなファイル単位にまとめた圧縮デ
ータについても、そのヘッダ514のヘッダ情報を使用
することで、復元の際に各ワードごとのバイト位置に対
応した圧縮バイトデータを符号列から分離することがで
きる。図41は図32のデータ圧縮装置の具体的な実施
形態であり、4バイト構成のワードデータを対象に確率
統計型の符号化を行うことを特徴とする。
[0202] Even for such compressed data compiled in file units, the compressed byte data corresponding to the byte position of each word is separated from the code string at the time of decompression by using the header information of the header 514. be able to. FIG. 41 shows a specific embodiment of the data compression apparatus shown in FIG. 32, which is characterized by performing probability statistic coding on 4-byte word data.

【0203】図41において、まずバイト配列変換部5
00にはワードデータの1バイト目、2バイト目、3バ
イト目、4バイト目に分けて、4個のレジスタを備えた
レジスタ群518−1,518−2,518−3及び5
18−4が設けられている。ここで1バイト目のレジス
タ群518−1の各レジスタをR11〜R14、2バイ
ト目のレジスタ群518−2の各レジスタをR21〜R
24、3バイト目のレジスタ群518−3の各レジスタ
をR31〜R34、及び4バイト目のレジスタ群518
−4の各レジスタをR41〜R44で表わしている。
In FIG. 41, first, the byte array conversion unit 5
00 is divided into the first byte, the second byte, the third byte, and the fourth byte of the word data, and a register group 518-1, 518-2, 518-3, and 5 having four registers is provided.
18-4 are provided. Here, the registers of the register group 518-1 at the first byte are R11 to R14, and the registers of the register group 518-2 at the second byte are R21 to R.
24, the registers of the register group 518-3 at the third byte are R31 to R34, and the register group 518 at the fourth byte
-4 are represented by R41 to R44.

【0204】入力されたソースデータは、1バイト目、
2バイト目、3バイト目、4バイト目の各バイトデータ
に分離されて、初段のレジスタR11,R21,R31
及びR41のそれぞれに保持される。ここでワードデー
タは32ビットであり、4バイトであるから1バイト当
たり8ビットデータとなっている。2段目のレジスタR
12,R22,R32,R42には、1つ前に符号化が
済んだワードデータの各バイトデータが保持されてい
る。
The input source data is the first byte,
The first-stage registers R11, R21, and R31 are separated into second byte data, third byte, and fourth byte data.
And R41. Here, the word data is 32 bits, and since it is 4 bytes, it is 8-bit data per byte. Second stage register R
12, R22, R32, and R42 hold each byte data of the previously encoded word data.

【0205】3段目のレジスタ群R13,R23,R3
3,R43には、更に1つ前に符号化が済んだワードデ
ータの各バイトデータが保持される。最後の4段目のレ
ジスタR14,R24,R34及びR44には、更に1
つ前に符号化が済んだワードデータの各バイトデータが
保持されている。この結果、1バイト目から4バイト目
の各レジスタ群518−1〜518−4のそれぞれに
は、現時点のバイトデータから既に符号化が済んだ3つ
前までのワードデータのバイトデータが各バイト位置に
つきワードストリーム方向に保持されている。
The third-stage register group R13, R23, R3
3, R43 holds each byte data of the word data which has been encoded one immediately before. The last fourth-stage registers R14, R24, R34 and R44 have an additional 1
Each byte data of the previously encoded word data is held. As a result, in each of the register groups 518-1 to 518-4 of the first to fourth bytes, the byte data of the word data up to three words that have already been encoded from the current byte data are stored in each byte. The position is held in the word stream direction.

【0206】バイト単位符号化部502は確率統計型符
号化を採用することから、各バイト位置ごとに出現頻度
モデル部520−1〜520−4、エントロピー符号化
部522−1〜522−4を有し、最終段に符号バッフ
ァ部524−1〜524−4をそれぞれ設けている。出
現頻度モデル部520−1〜520−4のそれぞれは、
現在符号化対象とするバイトデータと既に符号化が済ん
だ過去の3ワード分のバイトデータとの相関即ち文脈を
使って、出現頻度モデルにより条件付出易さを検出して
いる。
Since the byte unit coding unit 502 employs probability statistical coding, the appearance frequency model units 520-1 to 520-4 and the entropy coding units 522-1 to 522-4 are provided for each byte position. And the code buffer units 524-1 to 524-4 are provided at the last stage. Each of the appearance frequency model units 520-1 to 520-4 is
Using the correlation between the byte data to be currently encoded and the byte data of the past three words that have already been encoded, that is, the context, the ease of conditional appearance is detected by the appearance frequency model.

【0207】そして出現頻度モデル部520−1〜52
0−4のそれぞれで検出された条件付出易さ(順位)に
対し、エントロピー符号化部522−1〜522−4の
それぞれで統計的なエントロピー符号化を施して、バイ
ト単位の圧縮データである符号に変換し、符号バッファ
部524−1〜524−4のそれぞれに一時的に格納し
ている。
The appearance frequency model units 520-1 to 520-52
The entropy encoding units 522-1 to 522-4 perform statistical entropy encoding on the conditional ease of appearance (order) detected in each of 0 to 4, and are compressed data in byte units. The code is converted into a code and temporarily stored in each of the code buffer units 524-1 to 524-4.

【0208】符号バッファ部524−1〜524−4の
それぞれにあっては、図35のフォーマットに従ったバ
イト単位あるいは図39のフォーマットに従ったファイ
ル単位に圧縮バイトデータがたまった時点で、符号マー
ジ部533により各バイト位置の符号を結合させて一連
の圧縮データをヘッダと共に作成して出力する。図42
は図41の確率統計型の符号化を行うデータ圧縮装置の
各バイトごとの符号化処理のタイムチャートである。即
ち、出現頻度モデル処理とエントロピー符号化処理につ
いて、図42(A)は1バイト目、図42(B)は2バ
イト目、図42(C)は3バイト目、更に42(D)は
4バイト目を示している。例えばT1サイクルにあって
は、並列的に各バイト位置のバイトデータの出現頻度モ
デル処理が行われてる。
In each of the code buffer units 524-1 to 524-4, when the compressed byte data is accumulated in units of bytes according to the format of FIG. 35 or in units of files according to the format of FIG. The code at each byte position is combined by the merging unit 533 to create and output a series of compressed data together with the header. FIG.
42 is a time chart of an encoding process for each byte of the data compression device that performs the probability statistical encoding shown in FIG. That is, regarding the appearance frequency model processing and the entropy encoding processing, FIG. 42A shows the first byte, FIG. 42B shows the second byte, FIG. 42C shows the third byte, and 42 (D) shows the fourth byte. Indicates the byte. For example, in the T1 cycle, the appearance frequency model processing of the byte data at each byte position is performed in parallel.

【0209】この例では3バイト目、2バイト目、1バ
イト目、4バイト目の順に出現頻度モデル処理を終了し
ている。出現頻度モデル処理が終了すると、最後に終了
したタイミングから所定時間後にT2サイクルのエント
ロピー符号化処理が起動し、同時に次のワードデータに
ついて出現頻度モデル処理を並列的に実行するパイプラ
イン処理を行っている。以下同様にして、T3,T4,
T5,T6の各サイクルの出現頻度モデル処理とエント
ロピー符号化処理が各バイト位置ごとに並列的に行われ
る。
In this example, the appearance frequency model processing is completed in the order of the third byte, the second byte, the first byte, and the fourth byte. When the appearance frequency model processing ends, the entropy encoding processing of the T2 cycle starts a predetermined time after the last end timing, and at the same time, performs pipeline processing for executing the appearance frequency model processing in parallel for the next word data. I have. Hereinafter, similarly, T3, T4,
The appearance frequency model processing and entropy encoding processing of each cycle of T5 and T6 are performed in parallel for each byte position.

【0210】図43は、図32のワードストリーム方向
でのバイト単位の符号化を行うデータ圧縮装置から出力
された圧縮データを入力してワードデータ単位に復元す
るデータ復元装置の基本的なブロック図である。このデ
ータ復元装置は、符号分離部530、復元するnバイト
のワードデータの各バイト位置に対応したバイト単位復
号化部532−1,532−2,・・・532−n、及
び出力切替部533で構成される。
FIG. 43 is a basic block diagram of a data decompression device that inputs compressed data output from a data compression device that performs byte-by-byte encoding in the word stream direction in FIG. 32 and decompresses the data into word data units. It is. This data restoration device includes a code separation unit 530, byte unit decoding units 532-1, 532-2, ... 532-n corresponding to respective byte positions of n-byte word data to be restored, and an output switching unit 533. It consists of.

【0211】符号分離部530は図35のバイト単位の
まとまりをもつフォーマットあるいは図39のファイル
単位のまとまりをもつフォーマットに従った圧縮データ
を入力し、ヘッダ情報に基づいてワードデータ単位に各
バイト位置のバイト圧縮データである符号を分離して、
バイト単位符号化部532−1〜532−nに並列的に
出力する。
The code separation unit 530 inputs compressed data in accordance with the format having unity in byte units shown in FIG. 35 or the format having unity in file unit in FIG. 39, and converts each byte position into word data units based on header information. The code which is the byte compressed data of
The data is output in parallel to the byte unit encoding units 532-1 to 532-n.

【0212】バイト単位復号化部532−1〜532−
nのそれぞれは、各バイト位置の符号を入力して、符号
化と逆の操作により1バイト目からnバイト目の各バイ
トデータを並列的に復元する。切替出力部533は、バ
イト単位復号化部532−1〜532−nから出力され
たバイトデータをバイト位置の順に結合して、nバイト
構成のワードデータを復元してソースデータとして出力
する。
Byte unit decoding units 532-1 to 532-
Each of n inputs the code of each byte position, and restores each byte data from the 1st byte to the nth byte in parallel by the reverse operation of the encoding. The switching output unit 533 combines the byte data output from the byte unit decoding units 532-1 to 532-n in the order of the byte positions, restores n-byte word data, and outputs it as source data.

【0213】バイト単位復号化部532−1〜532−
nとしては、図32のデータ圧縮装置に対応して辞書型
復号化あるいは確率統計型復号化を行う。辞書型復号化
としては、LZW法やLZSS法に代表される方法を使
用する。また確率統計型の復号化法としては、多値算術
符号法あるいは動的ハフマン符号化や、スプレイ符号化
等の符号木符号化を使用することができる。
Byte unit decoding units 532-1 to 532-
As n, dictionary type decoding or probability statistical type decoding is performed in correspondence with the data compression apparatus of FIG. As the dictionary-type decoding, a method represented by the LZW method or the LZSS method is used. As the probability statistical decoding method, a multi-level arithmetic coding method, a dynamic Huffman coding method, or a code tree coding method such as a spray coding method can be used.

【0214】図44は図43のデータ復元装置における
バイト単位の復号化処理であり、図44(A)(B)
(C)に1バイト目、2バイト目及びnバイト目の各復
号化処理を示している。例えばT1サイクルにあって
は、符号分離部530で分離された1ワード分の圧縮バ
イトデータでなる各バイト位置の符号がバイト単位符号
化部532−1〜532−nに並列的に入力され、それ
ぞれ異なった符号化処理時間を経て各バイトデータが復
元される。
FIG. 44 shows the decoding process in byte units in the data restoration apparatus of FIG. 43, and FIGS. 44 (A) and 44 (B)
(C) shows each decoding process of the first byte, the second byte, and the nth byte. For example, in the T1 cycle, the code at each byte position consisting of one byte of compressed byte data separated by the code separation unit 530 is input in parallel to the byte unit coding units 532-1 to 532-n, Each byte data is restored after different encoding processing times.

【0215】T1サイクルにあっては、nバイト目の復
号化処理が最後であり、その後、所定時間を経過したタ
イミングから次のT2サイクルでの次のワードデータに
対応する各バイト位置の符号の並列的な符号化が行わ
れ、これを繰り返す。図43は図35のフォーマットに
従ってワード単位にまとめられた圧縮データの復元処理
のフローチャートである。まずステップS1で圧縮デー
タを入力し、ステップS2で、圧縮データのヘッダ情報
からワードデータのnバイト分の各バイト位置に対応す
る符号を分離し、即ちバイト圧縮データをバイト一単位
に分離し、この分離したバイト圧縮データをステップS
3で並列的に復号化する。
In the T1 cycle, the decoding process of the n-th byte is the last, and thereafter, from the timing when a predetermined time has elapsed, the sign of the code at each byte position corresponding to the next word data in the next T2 cycle Parallel encoding is performed and this is repeated. FIG. 43 is a flowchart of a process of restoring compressed data compiled in words in accordance with the format of FIG. First, in step S1, compressed data is input. In step S2, a code corresponding to each byte position of n bytes of word data is separated from the header information of the compressed data, that is, the byte compressed data is separated into one byte unit. The separated byte compressed data is stored in step S
In step 3, decoding is performed in parallel.

【0216】ステップS4で圧縮データが不足していな
ければ、ステップS5に進み、復号したバイト単位の各
復元バイトデータを結合して1ワード分のワードデータ
を出力する。このステップS3〜S5の処理を、ステッ
プS6で最終データの復元が終了するまで繰り返す。図
46は図39のフォーマットに示したファイル単位にま
とめられた圧縮データの復元処理のフローチャートであ
る。まずステップS1で圧縮データをまとめて入力し、
ステップS2で圧縮データに含まれる符号即ち各バイト
圧縮データを復元するワードデータの各バイト位置ごと
に全て分離する。続いてステップS3で、分離されたワ
ード単位の圧縮データのそれぞれについて並列的に復号
化を行う。
If it is determined in step S4 that the compressed data is not insufficient, the flow advances to step S5 to combine the decoded decompressed byte data in byte units and output one word of word data. The processes in steps S3 to S5 are repeated until the restoration of the final data is completed in step S6. FIG. 46 is a flowchart of a process for restoring compressed data compiled in file units shown in the format of FIG. First, in step S1, the compressed data is input collectively,
In step S2, the code included in the compressed data, that is, each byte compressed data, is all separated for each byte position of the word data to be restored. Subsequently, in step S3, decoding is performed in parallel on each of the separated compressed data in word units.

【0217】このとき圧縮データに不足がなければステ
ップS5に進み、復元した1ワード分の各バイトデータ
を結合してワードデータを出力する。ステップS3〜S
5の処理は、ステップS6で最終ワードデータの復元が
終了するまで繰り返される。図47は図43のデータ復
元装置の具体的な実施形態であり、図41の1ワード4
バイト構成で確率統計型符号化を行うデータ圧縮装置に
対応したデータ復元装置である。
At this time, if there is no shortage in the compressed data, the flow advances to step S5 to combine the decompressed byte data of one word and output word data. Steps S3 to S
Step 5 is repeated until the restoration of the last word data is completed in step S6. FIG. 47 shows a specific embodiment of the data restoration apparatus of FIG.
This is a data decompression device corresponding to a data compression device that performs probability statistical coding in a byte configuration.

【0218】図47のデータ復元装置は、符号分離部5
30に続いてバイト単位復号化部532を設けており、
1ワードが4バイト構成であることから、1バイト目、
2バイト目、3バイト目、4バイト目のそれぞれに対応
して、符号バッファ部534−1〜534−4、エント
ロピー復号化部536−1〜536−4、及び出現頻度
モデル部538−1〜538−4を並列的に設けてい
る。
The data decompression device shown in FIG.
A byte unit decoding unit 532 is provided following 30.
Since one word is composed of 4 bytes, the first byte,
The code buffer units 534-1 to 534-4, the entropy decoding units 536-1 to 536-4, and the appearance frequency model units 538-1 to 538-4 correspond to the second byte, the third byte, and the fourth byte, respectively. 538-4 are provided in parallel.

【0219】符号バッファ部534−1〜534−4の
それぞれは、符号分離部530で分離した1ワード分の
圧縮バイトデータとなる各バイト位置の符号を一時的に
バッファする。エントロピー復号化部536−1〜53
6−4は、入力された符号と既に復元されている直前の
バイトデータ列から条件付出易さを検出する。出現頻度
モデル部538−1〜538−4は、復元済みの直前の
バイトデータ列につながる現在復元したバイトデータの
条件付出易さを各バイトデータごとに頻度データとして
登録し、エントロピー復号化部536−1〜536−4
のそれぞれで求めた条件付出易さにより頻度データを検
索してバイトデータを復元すると共に、頻度データを登
録更新する。
Each of the code buffer units 534-1 to 534-4 temporarily buffers the code at each byte position which becomes one byte of compressed byte data separated by the code separation unit 530. Entropy decoding units 536-1 to 53-53
Step 6-4 detects the conditional ease of output from the input code and the byte data string immediately before being restored. The appearance frequency model units 538-1 to 538-4 register, as frequency data, the conditional ease of currently restored byte data connected to the immediately preceding restored byte data string as frequency data, and the entropy decoding unit 536 -1 to 536-4
The frequency data is retrieved by the conditional ease determined in each step to restore the byte data, and the frequency data is registered and updated.

【0220】出現頻度モデル部538−1〜538−4
に続く出力切替部533には、各バイト位置について復
元済みのバイトデータを3ワード分格納するためのレジ
スタ群540−1〜540−4が設けられている。ここ
で1バイト目のレジスタ群540−1はレジスタR11
0〜R130で示され、2バイト目のレジスタ群540
−2はレジスタR210〜R230で示される。
Appearance frequency model units 538-1 to 538-4
The output switching unit 533 is provided with a group of registers 540-1 to 540-4 for storing three words of byte data restored for each byte position. Here, the register group 540-1 of the first byte is the register R11
0-R130, second byte register group 540
-2 is indicated by registers R210 to R230.

【0221】3バイト目のレジスタ群540−3はレジ
スタR310〜R330で示され、更に4バイト目のレ
ジスタ群540−4はレジスタR410〜R430で示
されている。このようなレジスタ群540−1〜540
−4における各バイト位置の復元済みの3ワード分の各
バイトデータの出現頻度モデル部538−1〜538−
4のそれぞれが取り入れて直前のバイトデータ列につな
がる復元しようとするバイトデータの条件付出易さを求
めて登録更新している。
The register group 540-3 at the third byte is indicated by registers R310 to R330, and the register group 540-4 at the fourth byte is indicated by registers R410 to R430. Such a register group 540-1 to 540
-4, the appearance frequency model units 538-1 to 538- of the three bytes of the restored byte data of each byte position at each byte position
No. 4 is registered and updated in order to obtain the conditional ease of byte data to be restored and taken into connection with the immediately preceding byte data string.

【0222】また出力切替部533にあっては、所蔵の
レジスタR110,R210,R310,R410に保
持された各バイト位置の復元バイトデータを1バイト目
から4バイト目の各ソースデータとして取り出し、これ
をバイト順につなげてワードデータとして出力する。図
48は図47のデータ復元装置におけるエントロピー復
号化処理と出現頻度モデル処理のタイムチャートであ
り、図48(A)に1バイト目を、図48(B)に2バ
イト目を、図48(C)に3バイト目を、更に図48
(D)に4バイト目を示している。
The output switching unit 533 extracts the restored byte data at each byte position held in the registers R110, R210, R310, and R410 as source data of the first to fourth bytes. Are connected in byte order and output as word data. 48 is a time chart of the entropy decoding process and the appearance frequency model process in the data restoration device of FIG. 47. FIG. 48A shows the first byte, FIG. 48B shows the second byte, and FIG. The third byte is added to C), and FIG.
(D) shows the fourth byte.

【0223】例えばT1サイクルを例にとると、1バイ
ト目〜4バイト目のそれぞれについて、分離した各バイ
ト位置の符号を入力して、直前の復元済みバイトデータ
列から条件付出易さを求めるエントロピー復号化処理を
行い、この場合には例えば4バイト目のエントロピー復
号化処理が最後に終了したタイミングから所定時間後
に、T2サイクルとして2段の出現頻度モデル処理を行
っている。
For example, taking the T1 cycle as an example, for each of the first to fourth bytes, the code of each separated byte position is input, and the entropy for obtaining conditional ease from the immediately preceding restored byte data string is obtained. A decoding process is performed. In this case, for example, a predetermined time after the timing at which the entropy decoding process of the fourth byte is finally completed, a two-stage appearance frequency model process is performed as a T2 cycle.

【0224】同時に次のワードデータを復元するための
分離された各バイト位置の符号を入力してエントロピー
復号化処理を並列的に行っている。以下、T3,T4,
T5,T6・・・サイクルのように、同様な処理を繰り
返す。図49は図41に示したデータ圧縮装置の1バイ
ト目から4バイト目の各々に設けた出現頻度モデル部5
20−1とエントロピー符号化部522−1のパイプラ
イン制御の実施形態であり、確率統計的符号化として算
出符号化を適用した場合を例にとっている。
At the same time, the code of each separated byte position for restoring the next word data is input, and the entropy decoding processing is performed in parallel. Hereinafter, T3, T4,
Similar processing is repeated as in a T5, T6... Cycle. FIG. 49 shows the appearance frequency model unit 5 provided in each of the first to fourth bytes of the data compression apparatus shown in FIG.
This is an embodiment of pipeline control of 20-1 and the entropy coding unit 522-1, and exemplifies a case where calculation coding is applied as probability statistical coding.

【0225】この算術符号化にあっては、図6のパイプ
ライン制御と同様、確率モデル部14と算術符号化部1
6で構成され、これに対しパイプライン制御部15を設
けている。図49の算術符号化のパイプライン制御にあ
っては、確率モデル部14を確率モデル検索部542と
確率モデル更新部544に分け、また算術符号化部16
を符号空間演算部546と算術符号出力部548に分け
ている。
In this arithmetic coding, as in the pipeline control of FIG. 6, the probability model unit 14 and the arithmetic coding unit 1
6, and a pipeline control unit 15 is provided for this. In the arithmetic coding pipeline control of FIG. 49, the probability model unit 14 is divided into a probability model search unit 542 and a probability model update unit 544, and the arithmetic coding unit 16
Are divided into a code space operation unit 546 and an arithmetic code output unit 548.

【0226】ここで確率モデル部14は図7に示す構成
を備え、これに対応して確率モデル検索部542は図7
の順位読出更新部18、文字読出更新部20、頻度読出
更新部22、累積頻度読出更新部24及び総累積頻度読
出更新部26における読出し部としての機能をまとめた
確率モデル検索部542としている。これに対し確率モ
デル更新部544は、残りの更新部の機能をまとめたも
のである。
Here, the probability model section 14 has the configuration shown in FIG. 7, and the probability model search section 542 corresponds to FIG.
A probability model search unit 542 that combines the functions of the order reading / updating unit 18, the character reading / updating unit 20, the frequency reading / updating unit 22, the cumulative frequency reading / updating unit 24, and the total cumulative frequency reading / updating unit 26 as a reading unit. On the other hand, the probability model updating unit 544 summarizes the functions of the remaining updating units.

【0227】一方、算術符号化部16にあっては、符号
空間演算部546と算術符号出力部548に分けてい
る。符号空間演算部546は図7の算術符号化部16に
おける符号空間算出部28、符号空間算出部30及び逆
数算出部32の機能を備える。また算術符号出力分54
8は図7の算術符号化部16の算術符号導出部34と符
号出力部36の機能を有する。
On the other hand, the arithmetic encoding unit 16 is divided into a code space operation unit 546 and an arithmetic code output unit 548. The code space calculation unit 546 has functions of the code space calculation unit 28, the code space calculation unit 30, and the reciprocal calculation unit 32 in the arithmetic coding unit 16 in FIG. The arithmetic code output part 54
8 has the functions of the arithmetic code deriving unit 34 and the code output unit 36 of the arithmetic coding unit 16 in FIG.

【0228】パイプライン制御部15は、確率モデル更
新部544と符号空間演算部546の処理をパイプライ
ン化している点が図6,図7の実施形態と異なる。図4
9(B)は図49(A)における算術符号化のパイプラ
イン処理であり、図6(B)と同様、文字abaを入力
した場合の符号化を例にとっている。図6(B)と異な
るのは、確率モデル検索部542に続いて確率モデル更
新部544と符号空間演算部546の2つの処理が同時
に並行して行われるパイプライン化処理としている。こ
れによって図6,図7の場合に比べ、更にパイプライン
化による処理性能を向上している。
The pipeline control unit 15 differs from the embodiment of FIGS. 6 and 7 in that the processing of the probability model update unit 544 and the code space calculation unit 546 is pipelined. FIG.
9 (B) is a pipeline process of the arithmetic coding in FIG. 49 (A), and, as in FIG. 6 (B), exemplifies coding when a character aba is input. 6B is different from FIG. 6B in that a pipeline process is performed in which two processes of a probability model update unit 544 and a code space calculation unit 546 are performed simultaneously in parallel after the probability model search unit 542. As a result, the processing performance by pipelining is further improved as compared with the cases of FIGS.

【0229】図50は、図47のデータ復元装置の1バ
イト目から4バイト目の各バイト位置ごとに行われるエ
ントロピー符号化処理及び出現頻度モデル処理について
算術復号化を適用した場合の実施形態である。もちろ
ん、図50は4バイト分の並列処理部のうちの1つを代
表して示している。データ復元装置に算術復号化を適用
した場合、エントロピー復号化処理と出現頻度モデル処
理は算術復号化部50と確率モデル部52で構成され
る。この算術復号化部50の構成は、図13(A)と同
じである。図13(A)の詳細は図14に示されてい
る。
FIG. 50 shows an embodiment in which arithmetic decoding is applied to the entropy encoding process and the appearance frequency model process performed for each byte position from the 1st byte to the 4th byte of the data restoration device of FIG. is there. Of course, FIG. 50 shows one of the 4-byte parallel processing units as a representative. When arithmetic decoding is applied to the data restoration device, the entropy decoding process and the appearance frequency model process include an arithmetic decoding unit 50 and a probability model unit 52. The configuration of the arithmetic decoding unit 50 is the same as that of FIG. Details of FIG. 13A are shown in FIG.

【0230】図50の算術符号化部50にあっては、算
術符号化入力部550、累積値演算部552及び符号空
間演算部554に分けている。図14の実施形態との対
応を見ると、算術符号化部550は図14の符号入力部
54に相当する。累積値演算部552は、累積値導出部
56、累積頻度導出部64、逆数算出部66に相当す
る。また符号空間演算部554は符号空間算出部58,
60、及び逆数算出部62に相当する。
The arithmetic coding unit 50 shown in FIG. 50 is divided into an arithmetic coding input unit 550, a cumulative value calculation unit 552, and a code space calculation unit 554. Looking at the correspondence with the embodiment of FIG. 14, the arithmetic coding unit 550 corresponds to the code input unit 54 of FIG. The cumulative value calculating unit 552 corresponds to the cumulative value deriving unit 56, the cumulative frequency deriving unit 64, and the reciprocal calculating unit 66. The code space calculation unit 554 includes a code space calculation unit 58,
60 and the reciprocal calculation unit 62.

【0231】また図50の確率モデル部52は、確率モ
デル検索部556、出力文字検索部558及び確率モデ
ル更新部560に分けている。図14の確率モデル部5
2との対応を見ると、確率モデル検索部556と出力文
字検索部558は図14の順位導出部68、文字読出更
新部72、頻度読出更新部74、累積頻度読出更新部7
6及び総累積頻度読出更新部78における読出し部とし
ての機能、更に文字出力部80を含む。また確率モデル
更新部560は、図14における各更新部としての機能
をまとめたものである。
The probability model section 52 in FIG. 50 is divided into a probability model search section 556, an output character search section 558, and a probability model update section 560. Probability model part 5 in FIG.
Looking at the correspondence with No. 2, the probability model search unit 556 and the output character search unit 558 are the order derivation unit 68, the character read update unit 72, the frequency read update unit 74, and the cumulative frequency read update unit 7 of FIG.
6 and a function as a reading unit in the total cumulative frequency reading / updating unit 78, and further includes a character output unit 80. The probability model updating unit 560 is a collection of functions as each updating unit in FIG.

【0232】図14の算術符号化部50と確率モデル部
52にあっては、それぞれを並列的に行うパイプライン
処理であったが、図50の実施形態にあっては、算術符
号化部50の符号空間演算部554と確率モデル部52
の確率モデル検索部556についても並列化によるパイ
プライン処理を行っている点で相違する。図50(B)
は図50(A)の復号化処理であり、図13(B)と同
じ符号入力に対する文字の復元を行っている。このうち
確率モデル検索部556の出力を出力文字検索部558
と符号空間演算部554に並列的に供給して、両者の同
一タイミングでのパイプライン動作を可能とすること
で、処理性能を高めている。
In the arithmetic coding unit 50 and the probability model unit 52 in FIG. 14, the pipeline processing is performed in parallel with each other, but in the embodiment in FIG. Code space operation unit 554 and probability model unit 52
The difference is that the probability model search unit 556 also performs pipeline processing by parallelization. FIG. 50 (B)
FIG. 50A is a decoding process in FIG. 50A, in which a character is restored for the same code input as in FIG. 13B. The output of the probability model search unit 556 is output from the output character search unit 558.
And the code space operation unit 554 are supplied in parallel to enable pipeline operations at the same timing, thereby improving processing performance.

【0233】図51は図41の各バイト位置の出現頻度
モデル部及びエントロピー符号化処理について、動的ハ
フマン符号化やスプレイ符号化などの符号木符号化を適
用した場合の実施形態である。この符号木符号化の実施
形態は、文脈収集処理部562と符号木符号化部564
で構成される。文脈収集処理部562は、文脈木検索部
568、文脈木登録部570、同文脈判断部572で構
成され、入力されたバイトデータの文脈を収集して文脈
木を作成する。また符号木符号化部564は、符号木検
索部574と符号木更新登録部570及び符号並べ替え
出力部578で構成され、文脈収集処理部562による
入力バイトデータの文脈の研削結果に応じてスプレイ符
号化または動的ハフマン符号化を施しながら符号木を作
成更新する。
FIG. 51 shows an embodiment in which code tree coding such as dynamic Huffman coding or splay coding is applied to the appearance frequency model portion and entropy coding processing at each byte position in FIG. The embodiment of the code tree coding includes a context collection processing unit 562 and a code tree coding unit 564.
It consists of. The context collection processing unit 562 includes a context tree search unit 568, a context tree registration unit 570, and a context determination unit 572, and collects the context of the input byte data to create a context tree. The code tree coding unit 564 includes a code tree search unit 574, a code tree update registration unit 570, and a code rearrangement output unit 578, and performs spraying in accordance with a result of context grinding of input byte data by the context collection processing unit 562. Create and update a code tree while performing coding or dynamic Huffman coding.

【0234】特に、この実施形態あっては、符号木符号
化部564において、符号木検索部574に対し並列的
に符号木更新登録部576と符号並べ替え出力部578
を設け、図51(B)の文字列abaの符号化の例のよ
うに、符号木検索部564の検索結果を符号木更新登録
部576及び符号並べ替え出力部578に並列的に入力
して、同じタイミングでパイプライン動作を行って符号
化処理時間を短縮している。
In particular, in this embodiment, the code tree encoding section 564 makes the code tree search and registration section 574 parallel to the code tree update registration section 576 and the code rearrangement output section 578.
51, the search result of the code tree search unit 564 is input in parallel to the code tree update registration unit 576 and the code rearrangement output unit 578, as in the example of the encoding of the character string aba in FIG. In addition, the pipeline operation is performed at the same timing to shorten the encoding processing time.

【0235】図52は図51の符号木符号化に対応した
符号木復号化のための実施形態であり、符号木復号化部
580と文脈収集処理部582で構成される。符号木復
元部580は、符号木検索部586と符号木更新登録部
588で構成され、符号データを入力してスプレイ復号
化や動的ハフマン復号化等の符号木復号化を行いなが符
号木の作成更新を行い、更に、復元されたバイトデータ
の文脈を収集して文脈木を作成する。
FIG. 52 shows an embodiment for code tree decoding corresponding to the code tree coding shown in FIG. 51, and comprises a code tree decoding section 580 and a context collection processing section 582. The code tree restoration unit 580 includes a code tree search unit 586 and a code tree update registration unit 588. The code tree restoration unit 580 receives code data and performs code tree decoding such as spray decoding or dynamic Huffman decoding. Is created and updated, and the context of the restored byte data is collected to create a context tree.

【0236】この符号木復号化の実施形態にあっても、
符号木検索部586の検索結果を符号木更新登録部58
8と文脈木検索部590に入力することで、図52
(B)のように符号木検索部582の検索結果に対し符
号木更新登録部588と文脈木検索部590の処理を同
一タイミングで並列的に行ってパイプライン化し、復元
処理時間の短縮を図っている。
In this embodiment of the code tree decoding,
The search result of the code tree search unit 586 is stored in the code tree update registration unit 58
52 is input to the context tree search unit 590.
As shown in (B), the processing of the code tree update registration unit 588 and the context tree search unit 590 is performed in parallel on the search result of the code tree search unit 582 at the same timing to form a pipeline, thereby shortening the restoration processing time. ing.

【0237】尚、図51および図52で符号木符号化に
スプレイ符号化(Splay- Tree)を使用した場合の詳細
は、特開昭8−30432号(1996年2月2日公
開)に示される。 6.ワードストリーム方向とバイトストリーム方向の適
応切替処理 図53は図32に示した本発明におけるワードストリー
ム方向の符号化処理と従来行っていたバイトストリーム
方向の符号化処理を、符号化効率に基づいて適応的に切
り替えるデータ圧縮装置の実施形態である。このバイト
ストリームとワードストリームを並列的に符号化するデ
ータ復元装置は、バイト配列変換部600、ワードスト
リーム符号化部602、バイトストリーム符号化部60
4、及び符号切替部605で構成される。
The details of the case where the splay coding (Splay-Tree) is used for the coding tree coding in FIGS. 51 and 52 are shown in Japanese Patent Application Laid-Open No. 8-30432 (published on Feb. 2, 1996). It is. 6. FIG. 53 shows an adaptive switching process between the word stream direction and the byte stream direction according to the present invention shown in FIG. 32. 1 is an embodiment of a data compression device that switches the data in a dynamic manner. The data restoration apparatus that encodes the byte stream and the word stream in parallel includes a byte array conversion unit 600, a word stream encoding unit 602, and a byte stream encoding unit 60.
4 and a code switching unit 605.

【0238】バイト配列変換部600は、ソースデータ
として複数バイト構成のワードデータをワード単位に入
力して、各バイト位置のバイトデータに分離した後、ワ
ードストリーム符号化部602に対しては各バイト位置
でワード方向に複数のバイトデータが並んだワードスト
リーム方向のデータバイトとして入力し、一方、バイト
ストリーム符号化部604に対してはワードデータのデ
ータストリームそのもののデータバイトの並びをもつバ
イトストリーム方向のバイトデータとして入力する。
The byte array conversion unit 600 inputs word data having a plurality of bytes in units of words as source data, separates the data into byte data at each byte position, and sends the byte data to the word stream encoding unit 602. The position is input as a data byte in the word stream direction in which a plurality of byte data are arranged in the word direction at the position, while the byte stream direction having the data byte sequence of the data stream itself of the word data is input to the byte stream encoding unit 604. Input as byte data.

【0239】このバイト配列部600は、例えば1ワー
ド4バイト構成を例にとった図41のバイト配列変換部
500と同じレジスタ群で実現できる。図41のレジス
タ群における同一バイト位置のレジスタ並び方向がワー
ドストリーム方向であり、これに直交する各バイト位置
となる縦方向がバイトストリーム方向となる。ワードス
トリーム符号化部602における符号化は、図32の基
本構成をもち、より具体的には図41の1ワード4バイ
ト構成が使用でき、更に各バイト位置における確率統計
型の符号化の具体例としては、図42の算術符号化ある
いは図50の符号木符号化が使用できる。
The byte array section 600 can be realized by the same register group as the byte array conversion section 500 shown in FIG. 41 taking, for example, a 1-word 4-byte configuration. The register arrangement direction of the same byte position in the register group of FIG. 41 is the word stream direction, and the vertical direction that is each byte position orthogonal to this is the byte stream direction. The encoding in the word stream encoding unit 602 has the basic configuration shown in FIG. 32, and more specifically, the one-byte 4-byte configuration shown in FIG. 41 can be used. Further, a specific example of the probability statistical type encoding at each byte position For example, the arithmetic coding shown in FIG. 42 or the code tree coding shown in FIG. 50 can be used.

【0240】これに対しバイトストリーム符号化部60
4は、基本的な構成はワードストリーム符号化部602
と同じであるが、バイト配列変換部600から入力する
1ワード分の各バイトデータの並びがバイトストリーム
方向となっている点で相違する。符号切替部605は、
ワードストリーム符号化部602とバイトストリーム符
号化部604のそれぞれによる並列的な符号化の結果に
基づいて、いずれか一方を選択して圧縮データとして出
力する。
On the other hand, byte stream coding section 60
4 is basically composed of a word stream encoding unit 602.
However, the difference is that the arrangement of byte data for one word input from the byte array conversion unit 600 is in the byte stream direction. The code switching unit 605 includes:
Based on the results of the parallel encoding performed by the word stream encoding unit 602 and the byte stream encoding unit 604, one of them is selected and output as compressed data.

【0241】図54は図53のワードストリームとバイ
トストリームの符号化切替処理のタイムチャートであ
り、図54(A)がワードストリーム符号化処理であ
り、図54(B)がバイトストリーム符号化処理であ
り、図54(C)が選択符号出力である。例えば最初の
T1サイクルにあっては、ワードストリーム符号化部6
02及びバイトストリーム符号化部604がバイト配列
変換部600でワードデータを分離した各バイトデータ
を対象に並列的に符号化を行っており、符号化における
辞書型符号化あるいは確率統計型符号化の符号化済みワ
ードデータがワードストリーム方向かバイトストリーム
方向かの違いとなる。
FIG. 54 is a time chart of the word stream and byte stream encoding switching processing in FIG. 53. FIG. 54 (A) shows the word stream encoding processing, and FIG. 54 (B) shows the byte stream encoding processing. FIG. 54 (C) shows the selection code output. For example, in the first T1 cycle, the word stream encoding unit 6
02 and the byte stream coding unit 604 perform parallel coding on each byte data obtained by separating the word data in the byte array conversion unit 600, and perform dictionary coding or probability statistical coding in coding. The difference is whether the encoded word data is in the word stream direction or the byte stream direction.

【0242】T1サイクルにあっては、図54(B)の
バイトストリーム符号化が先に終了し、続いて図54
(A)のワードストリーム符号化が終了している。ワー
ドストリーム符号化が終了すると、所定時間後に次のT
2サイクルでのワードデータのワードストリーム符号化
及びバイトストリーム符号化が開始されるが、これに並
行して図54(C)のワードストリーム符号かバイトス
トリーム符号かの選択符号の付加と、選択された符号の
出力が行われる。
In the T1 cycle, the byte stream encoding shown in FIG.
The word stream encoding of (A) has been completed. When the word stream encoding is completed, the next T
The word stream encoding and the byte stream encoding of the word data in two cycles are started. In parallel with this, the selection code of the word stream code or the byte stream code shown in FIG. Is output.

【0243】即ち、T1サイクルの符号化にあっては、
例えばバイトストリーム符号608が選択され、このバ
イトストリーム符号608の選択を示す選択符号606
−1を先頭に付加して符号出力が行われる。次のT2サ
イクルにあっては、ワードストリーム符号610が選択
されており、同様にT3サイクルにおいて、まずワード
ストリーム符号610の選択を示す選択符号606−2
を付加した後にワードストリーム符号610を圧縮デー
タとして出力している。
That is, in the encoding of the T1 cycle,
For example, the byte stream code 608 is selected, and the selection code 606 indicating the selection of the byte stream code 608 is selected.
Code output is performed by adding -1 to the beginning. In the next T2 cycle, the word stream code 610 is selected. Similarly, in the T3 cycle, first, the selection code 606-2 indicating the selection of the word stream code 610.
, The word stream code 610 is output as compressed data.

【0244】図53の符号切替部606によるワードス
トリーム符号とバイトストリーム符号の選択は、バイト
単位の切替えかまたはワード単位の切替えのどちらでも
よい。図55(A)はバイト単位の符号切替えのフォー
マットである。例えば1ワード4バイト構成のワードデ
ータの符号化を例にとると、ワードストリーム符号化部
602及びバイトストリーム符号化部604のそれぞれ
においては、1バイト目、2バイト目、3バイト目、4
バイト目のそれぞれのバイトデータについて並列的に符
号化が行われている。
The selection of the word stream code and the byte stream code by the code switching unit 606 in FIG. 53 may be either byte-based switching or word-based switching. FIG. 55A shows a format of code switching in byte units. For example, taking the encoding of word data having a structure of one word and four bytes, in each of the word stream encoding unit 602 and the byte stream encoding unit 604, the first byte, the second byte, the third byte,
Each byte data of the byte is encoded in parallel.

【0245】そこで両方の符号化が終了した時点で、1
バイト目のワードストリーム符号とバイトストリーム符
号を比較して、例えばバイトストリーム符号を選択した
とすると、その切替符号606−1に続いてバイトスト
リーム符号でなる1バイト分の圧縮データ608を出力
する。次に2バイト目のワードストリーム符号とバイト
ストリーム符号を比較し、例えばワードストリーム符号
を選択したならば、その切替符号606−2を付加して
1バイト分の圧縮データ610としてワードストリーム
符号を出力する。以下同様に、バイト単位の切替符号の
付加と1バイト分の圧縮データの出力を繰り返す。
Therefore, when both encodings are completed, 1
The byte stream code of the byte is compared with the byte stream code, and if, for example, the byte stream code is selected, one byte compressed data 608 composed of the byte stream code is output following the switching code 606-1. Next, the word stream code of the second byte is compared with the byte stream code. If, for example, the word stream code is selected, the switching code 606-2 is added to output the word stream code as one byte of compressed data 610. I do. In the same manner, the addition of the switching code in byte units and the output of 1-byte compressed data are repeated in the same manner.

【0246】図55(B)はワード単位の符号切替であ
り、並列的に1ワード分の各ワードデータの符号化が終
了した時点でワード単位に圧縮データ、即ち1ワードの
バイト数分の圧縮バイトデータを比較して、例えばバイ
トストリーム符号側を選択したとすると、その切替符号
612に続いて、1ワードを構成するnバイト分の圧縮
バイトデータのバイトストリーム符号を出力する。
FIG. 55B shows code switching in word units. When encoding of each word data for one word is completed in parallel, compressed data in word units, that is, compression for the number of bytes of one word, is performed. If the byte data is compared and, for example, the byte stream code side is selected, a byte stream code of compressed byte data for n bytes constituting one word is output following the switching code 612.

【0247】図56は図55(A)のバイト単位に符号
切替を行う場合の符号化処理のフローチャートである。
まずステップS1でnバイト構成のワードデータを入力
して、ステップS2でバイト単位に分割し、ステップS
3及びステップS4で並列的にワードストリーム方向で
のバイトごとの符号化及びバイトストリーム方向でのバ
イトごとの符号化を行う。
FIG. 56 is a flowchart of an encoding process in the case of performing code switching in byte units in FIG. 55 (A).
First, in step S1, word data having an n-byte structure is input, and in step S2, the data is divided into byte units.
In step 3 and step S4, byte-by-byte encoding in the word stream direction and byte-by-byte encoding in the byte stream direction are performed in parallel.

【0248】続いてステップS5でバイトごとにワード
ストリーム方向及びバイトストリーム方向の符号化効率
を比較し、効率の高い方の符号をステップS6でバイト
ごとに選択し、切替えあるいは選択符号を付加し、ステ
ップS7でこれにバイトごとの符号データを結合して出
力する。このようなステップS1〜S7の処理を最終の
ワードデータの符号化が終了するまで繰り返す。
Subsequently, in step S5, the encoding efficiency in the word stream direction and the byte stream direction is compared for each byte, and the code with the higher efficiency is selected for each byte in step S6, and a switching or selection code is added. In step S7, the code data for each byte is combined and output. Such processing of steps S1 to S7 is repeated until the encoding of the final word data is completed.

【0249】図57は図55(B)のワード単位に符号
切替えを行う場合の符号化処理のフローチャートであ
る。まずステップS1でnバイト構成のワードデータを
入力し、ステップS2でワードデータをnバイト分のバ
イト単位に分割し、ステップS3及びステップS4で、
並列的に各バイトデータについてのワードストリーム方
向での符号化とバイトストリーム方向での符号化を行
う。
FIG. 57 is a flowchart of the encoding process in the case where code switching is performed in word units in FIG. 55 (B). First, in step S1, word data having an n-byte structure is input, and in step S2, the word data is divided into n-byte units. In steps S3 and S4,
The encoding in the word stream direction and the encoding in the byte stream direction for each byte data are performed in parallel.

【0250】符号化が済んだならば、ステップS5でワ
ードごとにワードストリーム方向とバイトストリーム方
向の符号化効率を比較する。そしてステップS6にあっ
ては、比較結果から符号効率のよいストリーム方向の符
号をワードごとに選択し、切替あるいは選択符号を付加
する。このようなステップS1〜S6の処理を、ステッ
プS7で最終ワードデータの符号化が終了するまで繰り
返し、ステップS8で最終的に各符号データを結合して
圧縮データとして出力する。
When the encoding is completed, the encoding efficiency in the word stream direction and the encoding efficiency in the byte stream direction are compared for each word in step S5. Then, in step S6, a code in the stream direction with good code efficiency is selected for each word from the comparison result, and switching or addition of a selected code is performed. Such processing of steps S1 to S6 is repeated until the encoding of the final word data is completed in step S7, and finally, in step S8, the respective encoded data are combined and output as compressed data.

【0251】図58は図53のワードストリーム方向と
バイトストリーム方向での符号化を並列的に行って符号
切替えを行うデータ圧縮装置の1ワードを4バイト構成
とした場合の実施形態であり、符号化として確率統計型
符号化を適用した場合を例にとっている。図58は、図
53のバイト配列変換部600、ワードストリーム符号
化部602及びバイトストリーム符号化部604の実施
形態である。バイト配列変換部600には文脈取り込み
用のレジスタ群として、1バイト目、2バイト目、3バ
イト目、4バイト目のそれぞれについて4つのレジスタ
を直列接続したレジスタ群618−1〜618−4を設
けている。
FIG. 58 shows an embodiment in which one word of the data compression apparatus for performing code switching by performing coding in the word stream direction and the byte stream direction in FIG. 53 in parallel is constituted by 4 bytes. The case where probability statistical coding is applied as an example is described. FIG. 58 shows an embodiment of the byte array conversion unit 600, the word stream coding unit 602, and the byte stream coding unit 604 of FIG. In the byte array conversion unit 600, register groups 618-1 to 618-4 in which four registers are connected in series for the first byte, the second byte, the third byte, and the fourth byte, respectively, as a register group for context capture. Provided.

【0252】符号化処理のために入力された4バイト構
成のソースデータは、例えば32ビットとすると、1バ
イト当たり8ビットの果てに分離され、初段のレジスタ
R1,R2,R3,R4に並列的に保持される。このと
き2段目のレジスタR1〜R4、3段目のレジスタR1
3〜R43、及び4段目のレジスタR14〜R44に
は、既に符号化が終了した先行する3ワード分の各バイ
ト位置のバイトデータが保持されている。
If the 4-byte source data input for the encoding process is, for example, 32 bits, the source data is separated into 8 bits per byte, and is divided into first-stage registers R1, R2, R3, and R4 in parallel. Is held. At this time, the second-stage registers R1 to R4 and the third-stage register R1
The third to fourth registers R14 to R44 hold the byte data at the respective byte positions of the preceding three words that have already been encoded.

【0253】このような文脈取り込み用のレジスタ群に
ついて、例えば現在符号化しようとするワードデータの
4バイト目のバイトデータを格納したレジスタR41に
着目すると、R41〜R44方向がワードストリーム方
向のバイトデータの並びとなる。これに対しバイトスト
リーム方向はレジスタR11に対し先行するバイトデー
タを順次格納したR31,R32,R11方向となる。
With regard to such a register group for context capture, for example, when focusing on the register R41 storing the byte data of the fourth byte of the word data to be encoded, the byte data in the word stream direction is R41 to R44. In a row. On the other hand, the byte stream direction is the direction of R31, R32, and R11 in which the preceding byte data is sequentially stored in the register R11.

【0254】このようなバイト配列変換部600に設け
たレジスタ群の格納バイトデータを対象にワードストリ
ーム符号化部602に対しては、現在符号化しようとす
るレジスタR11〜R14の各バイト位置のデータを基
準に、ワードストリーム方向に先行する3ワード分のバ
イトデータを文脈取り込みのために入力している。即ち
ワードストリーム符号化部600は、ソースデータの1
バイト目、2バイト目、3バイト目、及び4バイト目に
対応して、確率モデル部620−1〜620−4、エン
トロピー符号化部622−1〜622−4、バッファ選
択部624−1〜624−4を設けている。確率モデル
部620−1〜620−4のそれぞれは、0次、1次、
2次、3次の4つの確率モデル部を並列的に備えてい
る。
For the byte stream data stored in the group of registers provided in the byte array conversion unit 600, the word stream coding unit 602 sends the data at each byte position of the registers R11 to R14 to be currently coded. , Three bytes preceding the word stream in the word stream direction are input for context capture. That is, the word stream encoding unit 600 converts the source data 1
Probability model units 620-1 to 620-4, entropy coding units 622-1 to 622-4, and buffer selection units 624-1 to 62-4 corresponding to the second, third, and fourth bytes, respectively. 624-4. Each of the probability model units 620-1 to 620-4 is a 0th-order, a 1st-order,
Four probabilistic model units of second and third order are provided in parallel.

【0255】これに対応してエントロピー符号化部62
2−1〜622−4についても、0次、1次、2次、3
次の各エントロピー符号化部を並列的に備えている。即
ちワードストリーム符号化部600は、図24に示した
ブレンド文脈について全てを並列化したデータ圧縮装置
を使用している。この図24のブレンド文脈について全
並列化したデータ圧縮装置の詳細は、図25及び図26
に示したと同じである。
In response, entropy coding section 62
As for 2-1 to 622-4, 0th order, 1st order, 2nd order, 3rd order
The following entropy encoding units are provided in parallel. That is, the word stream encoding unit 600 uses a data compression device in which all the blend contexts shown in FIG. 24 are parallelized. Details of the data compression apparatus that is fully parallelized with respect to the blend context of FIG. 24 are described in FIGS.
Is the same as that shown in FIG.

【0256】ワードストリーム符号化部600の初段に
設けた確率モデル部620−1〜620−4に対するバ
イト配列変換部600の文脈取り込み用レジスタからの
入力は、そのレジスタ番号R11〜R44で示すとおり
である。例えば1バイト目の確率モデル部620−1
は、0次確率モデル部に対し、現在符号化しようとする
レジスタR11の1バイト目のバイトデータを入力す
る。
The input from the context fetch register of the byte array conversion unit 600 to the probability models 620-1 to 620-4 provided at the first stage of the word stream coding unit 600 is as shown by the register numbers R11 to R44. is there. For example, the first byte probability model unit 620-1
Inputs the byte data of the first byte of the register R11 to be encoded to the zero-order probability model unit.

【0257】また1次確率モデル部に対しては、前回符
号化が済んだ1バイト目のレジスタR11のバイトデー
タを入力し、2次確率モデル部に対しては更に1つ前に
符号化が済んだ1バイト目のレジスタR13のバイトデ
ータを入力し、3次確率モデル部に対しては更にもう1
つ前に符号化が済んだ1バイト目のレジスタR14のバ
イトデータを入力している。この点は2バイト目、3バ
イト目、4バイト目のモデル部620−2〜620−4
についても、各バイト位置のレジスタについて同様な0
次、1次、2次、3次のレジスタ入力が行われている。
The first-order probability model unit receives the byte data of the register R11 of the first byte which has been previously encoded, and the second-order probability model unit receives the immediately preceding encoding. The byte data of the register R13 of the completed first byte is input, and another one is sent to the third-order probability model unit.
The byte data of the register R14 of the first byte that has been encoded immediately before is input. This point is based on the model part 620-2 to 620-4 of the second byte, the third byte, and the fourth byte.
For the register at each byte position.
Next, primary, secondary, and tertiary register inputs are performed.

【0258】一方、バイトストリーム符号化部604
は、ブレンド文脈についての全並列化を実現したワード
ストリーム符号化部602と同様、1段目の確率モデル
部630−1〜630−4、次のエントロピー符号化部
632−1〜632−4、及びバッファ選択部634−
1〜634−4を、各バイト位置ごとに並列的に設けて
いる。
On the other hand, byte stream encoding section 604
Are the first-stage probability model units 630-1 to 630-4, the next-stage entropy encoding units 632-1 to 632-4, like the word stream encoding unit 602 that realizes all parallelization for the blend context. And the buffer selection unit 634
1 to 634-4 are provided in parallel for each byte position.

【0259】このバイトストリーム符号化部620に対
するバイト配列変換部600の文脈取り込み用レジスタ
群からの入力は、確率モデル部630−1〜630−4
における現在処理対象となっているワードデータの各バ
イト位置のバイトデータを入力する0次確率モデル部に
対するR11,R21,R31及びR41を起点に、バ
イトストリーム方向の並びをもつバイトデータのレジス
タ入力を行っている。
The input from the context fetch register group of the byte array conversion unit 600 to the byte stream encoding unit 620 is the probability model units 630-1 to 630-4.
Starting from R11, R21, R31 and R41 for the 0th-order probability model unit for inputting byte data at each byte position of the word data to be currently processed, register input of byte data having a sequence in the byte stream direction is performed. Is going.

【0260】即ち、4バイト目の確率モデル部630−
4にあっては、現在処理対象となっているワードデータ
の4バイト目が0次確率モデル部の入力となり、同じワ
ードデータの先行する3バイト目が1次確率モデル部の
入力となり、更に1つ先行する2バイト目のワードデー
タのレジスタR21が2次確率モデル部の入力となり、
一番先頭の1バイト目のバイトデータのレジスタR11
が3次確率モデル部の入力となる。
That is, the probability model part 630-at the fourth byte
In the case of No. 4, the fourth byte of the currently processed word data is input to the 0th-order probability model section, the preceding 3rd byte of the same word data is input to the first-order probability model section, and The register R21 of the second preceding word data of the second byte is input to the second-order probability model unit,
Register R11 of the first byte of the first byte
Is input to the third-order probability model unit.

【0261】次の現在処理対象となっているワードデー
タの3バイト目のバイトデータを保持したレジスタR3
1からの確率モデル部630−3に対する0次確率モデ
ル部の入力に対し、1次確率モデル部に対しては1バイ
ト前の同じワードデータの2バイト目のレジスタR21
のバイトデータを入力し、2次確率モデル部には同じワ
ードデータの更に1つ前の1バイト目のレジスタR11
によるバイトデータを入力し、3次確率モデル部には1
ワード前の4バイト目のレジスタR42のバイトデータ
を入力している。
The register R3 holding the third byte data of the next word data to be currently processed.
In response to the input from the 0th-order probability model unit to the probability model unit 630-3 from 1 the second byte register R21 of the same word data one byte before the first-order probability model unit
Is input to the second-order probability model unit, and the first byte register R11 which is one immediately before the same word data
Byte data is input to the third-order probability model part.
The byte data of the register R42 of the fourth byte before the word is input.

【0262】2バイト目のバイトデータをレジスタR2
1から0次確率モデル部に入力した確率モデル部630
−2についても、バイトストリーム方向にR11,R4
2,R32をそれぞれ1次、2次、3次の確率モデル部
の入力としている。更に1バイト目のバイトデータをレ
ジスタR11から0次確率モデル部に入力した確率モデ
ル部630−1についても、バイト方向に先行するレジ
スタR42、R32、R22の各バイトデータを1次、
2次、3次確率モデル部に入力している。これらバイト
ストリーム方向のバイト単位の入力については、ワード
は意識していない。
The byte data of the second byte is stored in the register R2.
Probability model unit 630 input to 1st to 0th order probability model unit
-2, R11, R4 in the byte stream direction.
2, R32 are input to the primary, secondary, and tertiary probability model units, respectively. Further, also regarding the probability model unit 630-1 in which the byte data of the first byte is input from the register R11 to the 0th-order probability model unit, each byte data of the registers R42, R32, R22 preceding in the byte direction is converted to the primary,
It is input to the second and third order probability models. Words are not considered for these byte-wise inputs in the byte stream direction.

【0263】図58のワードストリーム符号化部602
及びバイトストリーム符号化部604による各バイト位
置ごとの並列的な符号化により、各バッファ選択部62
4−1〜624−4及びバッファ選択部634−1〜6
34−4からは、ワードストリーム符号として符号W1
〜W4、ビット数BW1〜BW4が出力され、またバイ
トストリーム符号B1〜B4とそれぞれのビット数BB
1〜BB4が出力される。
The word stream coding section 602 shown in FIG.
And by the byte stream encoding unit 604 performing parallel encoding for each byte position,
4-1 to 624-4 and buffer selection units 634-1 to 634-6
34-4, the code W1 is used as the word stream code.
To W4 and the bit numbers BW1 to BW4 are output, and the byte stream codes B1 to B4 and the respective bit numbers BB
1 to BB4 are output.

【0264】図59は図53の符号切替部605の実施
形態であり、図58のワードストリーム符号化部602
及びバイトストリーム符号化部604の各符号化出力を
並列的に入力している。この符号切替部605は、1バ
イト目、2バイト目、3バイト目、4バイト目のそれぞ
れについて符号切替部648−1〜648−4と符号バ
ッファ650−1〜650−4を並列的に設け、最終的
に符号マージ部652でまとめて圧縮データを出力して
いる。
FIG. 59 shows an embodiment of the code switching unit 605 shown in FIG. 53. The word stream coding unit 602 shown in FIG.
And the respective encoded outputs of the byte stream encoding unit 604 are input in parallel. The code switching unit 605 is provided with code switching units 648-1 to 648-4 and code buffers 650-1 to 650-4 in parallel for the first byte, the second byte, the third byte, and the fourth byte. Finally, the code merge unit 652 outputs the compressed data as a whole.

【0265】各バイト位置ごとの符号切替部648−1
〜648−4に対しては、符号選択を行うためにビット
数比較部640−1〜640−4、ワード/バイト選択
確率モデル部642−1〜642−4、及び符号化部6
46−1〜646−4を設けている。ビット数比較部6
40−1〜64−4は、各ビット位置ごとに復元された
ワードストリーム符号W1〜W4と、バイトストリーム
符号B1〜B4のビット数BW1〜BW4とBB1〜B
B4の各々を比較し、符号長の短い方を選択し、選択結
果をワード/バイト選択確率モデル部642−1〜64
2−4に出力する。ワード/バイト選択確率モデル部6
42−1〜642−4は、ワードストリーム符号とバイ
トストリーム符号の頻度から確率を求めている。
Code switching section 648-1 for each byte position
648-4 to 648-4, the number of bits comparison units 640-1 to 640-4, the word / byte selection probability model units 642-1 to 642-4, and the encoding unit 6
46-1 to 646-4. Bit number comparison unit 6
40-1 to 64-4 are the word stream codes W1 to W4 restored for each bit position and the bit numbers BW1 to BW4 and BB1 to B4 of the byte stream codes B1 to B4.
B4 are compared with each other, the shorter code length is selected, and the selection result is expressed as a word / byte selection probability model unit 642-1 to 64-2.
Output to 2-4. Word / byte selection probability model part 6
42-1 to 642-4 calculate probabilities from the frequencies of word stream codes and byte stream codes.

【0266】符号化部646−1〜646−4はワード
/バイト選択確率モデル部642−1〜642−4から
符号切替用の切替符号を生成し、符号切替部648−1
〜648−4の各々で符号を選択すると同時に、先頭に
選択符号を付加する。符号バッファ650−1〜650
−4にあっては、ワード単位あるいはファイル単位にあ
る程度符号データがたまった時点で改めて符号マージ部
652で結合して一連の圧縮データとして出力する。
Encoding sections 646-1 to 646-4 generate code switching codes from word / byte selection probability model sections 642-1 to 642-4, and code switching section 648-1.
To 648-4, and at the same time, a selection code is added to the beginning. Code buffers 650-1 to 650
In the case of -4, when a certain amount of code data is accumulated in word units or file units, the data is combined again by the code merge unit 652 and output as a series of compressed data.

【0267】図60は、図53のワードストリーム方向
とバイトストリーム方向のそれぞれで符号化した後に切
替選択して得られた圧縮データから元のワードデータを
復元するデータ復元装置の実施形態である。このデータ
復元装置は、符号分離部700、ワードストリーム復号
化部702、バイトストリーム復号化部704及び出力
切替部706で構成される。
FIG. 60 shows an embodiment of a data decompression device for decompressing original word data from compressed data obtained by switching and selecting after encoding in the word stream direction and the byte stream direction in FIG. This data restoration device includes a code separation unit 700, a word stream decoding unit 702, a byte stream decoding unit 704, and an output switching unit 706.

【0268】符号分離部700は、図55(A)の圧縮
バイトデータ単位に切替符号をもつフォーマットの圧縮
データもしくは図55(B)のワード分の圧縮バイトデ
ータごとに切替符号をもつフォーマットのいずれかの圧
縮データを入力し、圧縮データに含まれる切替符号に基
づいてワードストリーム符号とバイトストリーム符号に
分けて、ワードストリーム復号化部702またはバイト
ストリーム復号化部704に入力する。
The code separation unit 700 is either a compressed data of a format having a switching code in units of compressed byte data in FIG. 55 (A) or a format having a switching code for each compressed byte data of words in FIG. 55 (B). The compressed data is input, divided into a word stream code and a byte stream code based on the switching code included in the compressed data, and input to the word stream decoding unit 702 or the byte stream decoding unit 704.

【0269】ワードストリーム復号化部702は図3
2、図41に示したデータ復元装置と基本的に同じであ
り、1ワードを構成するバイト数分の符号を並列的に復
号化し、対応する各バイト位置のバイトデータを復元す
る。バイトストリーム復号化部704は、復号化機能は
ワードストリーム復号化部702と同様に、1ワードを
構成する各バイト位置ごとに復号化回路を並列的に備え
ており、復号化回路そのものは図32と同じバイト単位
復号化部502−1〜502−nを並列的に設けてい
る。
The word stream decoding unit 702 operates as shown in FIG.
2. Basically the same as the data restoring device shown in FIG. 41, the code for the number of bytes constituting one word is decoded in parallel, and the byte data at each corresponding byte position is restored. The byte stream decoding unit 704 has a decoding function in parallel with the decoding function for each byte position forming one word in the same manner as the word stream decoding unit 702. And the byte unit decoding units 502-1 to 502-n are provided in parallel.

【0270】例えば確率統計型符号化を例にとると、図
47のバイト単位復号化部532と同じ回路が使用でき
る。バイトストリーム復号化部704がワードストリー
ム復号化部702と相違する点は、符号分離部700で
分離されたバイトストリーム符号を入力して復号化する
点だけである。図61は図60のデータ復元装置におけ
る復号化処理のタイムチャートであり、図61(A)に
選択符号復号化を、図61(B)にワードストリーム復
号化を、更に図61(C)にバイトストリーム復号化を
表わす。まず最初のT1サイクルにあっては、符号分離
部700が入力した圧縮データの先頭に設けられている
切替用の選択符号を復号化し、次に続く圧縮データがワ
ードストリーム符号かバイトストリーム符号かを識別す
る。
For example, taking the probability statistical type coding as an example, the same circuit as the byte unit decoding unit 532 in FIG. 47 can be used. The only difference between the byte stream decoding unit 704 and the word stream decoding unit 702 is that the byte stream decoding unit 704 receives and decodes the byte stream code separated by the code separating unit 700. FIG. 61 is a time chart of the decoding process in the data restoration apparatus of FIG. 60. FIG. 61 (A) shows the selection code decoding, FIG. 61 (B) shows the word stream decoding, and FIG. Represents byte stream decoding. First, in the first T1 cycle, the code separation unit 700 decodes the switching selection code provided at the head of the input compressed data, and determines whether the next compressed data is a word stream code or a byte stream code. Identify.

【0271】T1サイクルにあっては、選択符号の復号
化によりワードストリーム符号であることが識別され、
符号データがワードストリーム復号化部702に与えら
れてバイトデータの復号化が行われる。次のT2サイク
ルの選択符号708−2の復号化によりバイトストリー
ム符号が判別されたとすると、符号データはバイトスト
リーム復号化部704に与えられ、バイトデータの復号
化が行われる。以下同様に、選択符号708−3,70
8−4,・・・の復号結果に応じたワードストリーム符
号またはバイトストリーム符号の識別により、対応する
復号化を行ってバイトデータを復元する。
In the T1 cycle, the decoding of the selected code is identified as a word stream code,
The code data is supplied to the word stream decoding unit 702, and the byte data is decoded. Assuming that the byte stream code is determined by decoding the selection code 708-2 in the next T2 cycle, the code data is provided to the byte stream decoding unit 704, and the byte data is decoded. Hereinafter, similarly, selection codes 708-3, 70
According to the identification of the word stream code or the byte stream code according to the decoding result of 8-4,..., The corresponding decoding is performed to restore the byte data.

【0272】図62のフローチャートは図60のデータ
復元装置において、図55(A)に示したバイト単位の
圧縮データとなる符号ごとに切替符号を付加したフォー
マットの圧縮データを対象としたデータ復元処理であ
る。まずステップS1で各符号データを入力分離し、ス
テップS2で最終データでなければ、ステップS3で1
ワード分の符号が入力分離できたか否かチェックし、1
ワード分の符号が入力分離できたならば、ステップS4
で各選択符号を復号化する。
FIG. 62 is a flow chart showing a data decompression process for compressed data in a format in which a switching code is added to each code which is byte-based compressed data shown in FIG. It is. First, each code data is input-separated in step S1, and if it is not final data in step S2, 1
Check whether the code for the word could be input separated,
If the code for the word has been input-separated, step S4
Decodes each selected code.

【0273】この選択符号の復号化結果に基づき、ステ
ップS5で1ワードを構成するバイト数分の符号がワー
ドストリーム符号かバイトストリーム符号かを識別し、
それぞれに応じて図60のワードストリーム復号化部7
02またはバイトストリーム復号化部704に入力す
る。続いてステップS6及びS7で、並列的にワードス
トリーム方向及びバイトストリーム方向のそれぞれにつ
いてバイトごとに各符号を並列的に復号化する。
On the basis of the decoding result of the selected code, in step S5, it is determined whether the code for the number of bytes constituting one word is a word stream code or a byte stream code.
The word stream decoding unit 7 of FIG.
02 or the byte stream decoding unit 704. Subsequently, in steps S6 and S7, each code is decoded in parallel for each byte in the word stream direction and the byte stream direction in parallel.

【0274】続いてステップS8で、バイトごとに復元
されたワードストリーム方向の復元バイトデータとバイ
トストリーム方向の復元バイトデータをバッファに格納
する。そしてステップS9で、1ワード分のバイトデー
タが揃ったならば、ステップS10でバイト順に復元バ
イトデータを結合して1ワードのワードデータを出力す
る。続いてステップS2に戻り、最終データの復元が終
了したか否かチェックし、終了していなければ再びステ
ップS3からステップS1に戻って同様な処理を繰り返
す。
Subsequently, in step S8, the restored byte data in the word stream direction and the restored byte data in the byte stream direction restored for each byte are stored in the buffer. Then, in step S9, when the byte data for one word is prepared, in step S10, the restored byte data is combined in byte order and one word data is output. Subsequently, the process returns to step S2 to check whether or not the restoration of the final data has been completed. If the restoration has not been completed, the process returns from step S3 to step S1 again to repeat the same processing.

【0275】図63のフローチャートは図55(B)の
ワード単位に選択符号を付加したフォーマットの圧縮デ
ータを対象としたデータ復元処理である。まずステップ
S1で、復元対象とする全ての圧縮データをまとめて入
力して符号に分離する。続いてステップS2で最終デー
タの復元が済んでいなければ、ステップS3に進み、入
力分離した最初の選択符号を復号化し、ワードストリー
ム符号かバイトストリーム符号かを識別する。
The flowchart of FIG. 63 is a data decompression process for compressed data in a format in which a selection code is added in units of words of FIG. 55B. First, in step S1, all the compressed data to be restored are collectively input and separated into codes. Subsequently, if the restoration of the final data has not been completed in step S2, the process proceeds to step S3, where the first selected code separated from the input is decoded, and a word stream code or a byte stream code is identified.

【0276】ワードストリーム符号であればステップS
5に進み、1ワードを構成するバイト数分の符号を並列
的に復号化して各バイトデータを復元する。また符号が
バイトストリーム符号であればステップS6に進み、1
ワードを構成するバイト数分の符号を並列的に復号化し
て各バイトデータを復元する。次にステップS7で、ワ
ードごとに復号化されたワードストリーム方向またはバ
イトストリーム方向の復元データをバッファに格納す
る。そしてステップS8でnバイト構成の復元したワー
ドデータを出力し、これをステップS2で最後のワード
データの復元が終了するまで繰り返す。
If it is a word stream code, step S
Proceeding to 5, the codes for the number of bytes constituting one word are decoded in parallel to restore each byte data. If the code is a byte stream code, the process proceeds to step S6, where 1
The code for the number of bytes constituting the word is decoded in parallel to restore each byte data. Next, in step S7, the decoded data in the word stream direction or the byte stream direction decoded for each word is stored in the buffer. Then, in step S8, the restored word data having an n-byte structure is output, and this is repeated until the last word data is restored in step S2.

【0277】次に図60のデータ圧縮装置の具体的な実
施形態として、図53のデータ圧縮装置を図58,図5
9に示したブレンド文脈について全てを並列化したデー
タ圧縮装置で得られた圧縮データを復元するためのデー
タ復元装置の具体的な実施形態を説明する。このブレン
ド文脈について全て並列化したデータ圧縮装置で得られ
た圧縮データを復元するデータ復元装置は、図60の符
号分離選択部が図64の実施形態となり、図60のワー
ドストリーム復号化部702及びバイトストリーム復号
化部704が図65の実施形態となり、更に出力切替部
706が図66の実施形態となる。更にこの実施形態は
1ワード4バイト構成の場合の圧縮データの復元を例に
とっており、更に圧縮データのフォーマットとしては図
55(A)のバイト単位に選択符号を付加した場合を例
にとっている。
Next, as a specific embodiment of the data compression apparatus of FIG. 60, the data compression apparatus of FIG.
A specific embodiment of a data decompression device for decompressing compressed data obtained by a data compression device in which all of the blend contexts shown in FIG. 9 are parallelized will be described. In a data decompression device for decompressing compressed data obtained by a data compression device in which all of the blend contexts are parallelized, the code separation / selection unit in FIG. 60 is the embodiment in FIG. 64, and the word stream decoding unit 702 in FIG. The byte stream decoding unit 704 is the embodiment of FIG. 65, and the output switching unit 706 is the embodiment of FIG. Further, this embodiment exemplifies the restoration of compressed data in the case of a one-word 4-byte configuration, and further exemplifies a case in which a selection code is added in byte units as shown in FIG.

【0278】図64の符号分離選択部700は、入力段
に符号分離部708を有し、圧縮データを入力して1ワ
ードを構成するバイト数分即ち4バイト分の符号を分離
し、1バイト目、2バイト目、3バイト目、4バイト目
のそれぞれに設けている符号バッファ部710−1〜7
10−4に格納する。この分離された符号は、図55
(A)のように、先頭に選択符号をもち、その後ろに圧
縮バイトデータとなる符号データをもっている。
The code separation / selection section 700 shown in FIG. 64 has a code separation section 708 at the input stage, receives the compressed data, separates the number of bytes constituting one word, that is, the code of 4 bytes, and Code buffer units 710-1 to 710-7 provided for the first, second, third, and fourth bytes, respectively.
10-4. This separated code is shown in FIG.
As shown in (A), a selection code is provided at the beginning, and code data to be compressed byte data is provided after the selection code.

【0279】符号バッファ部710−1〜710−4に
続いては、選択符号復号化部712−1〜712−4、
ワード/バイト選択確率モデル部716−1〜716−
4及び符号切替部714−1〜714−4が各バイト位
置ごとに並列的に設けられている。例えば1バイト目を
例にとると、選択符号復号化部712は符号バッファ部
710−1に格納された1バイト目の符号データの先頭
の選択符号を入力し、既に復元されている直前の選択符
号列から条件付出易さを求め、選択符号がワードストリ
ーム符号を示すかバイトストリーム符号を示すかを復号
する。
Following the code buffer units 710-1 to 710-4, the selective code decoding units 712-1 to 712-4,
Word / byte selection probability model units 716-1 to 716-
4 and code switching units 714-1 to 714-4 are provided in parallel for each byte position. For example, taking the first byte as an example, the selection code decoding unit 712 inputs the first selection code of the code data of the first byte stored in the code buffer unit 710-1, and outputs the selected code immediately before the restoration. The conditional ease is determined from the code string, and whether the selected code indicates a word stream code or a byte stream code is decoded.

【0280】ワード/バイト選択確率モデル部716−
1は、直前の選択符号列につながる入力選択符号の条件
付出易さを登録した頻度データを格納しており、選択符
号復号化部712−1で求めた条件付出易さにより頻度
データを検索して選択符号を復元し、更に復元結果に応
じて頻度データを更新する。符号切替部714−1は選
択符号復号化部712−1の復号結果に応じ、符号バッ
ファ部710−1に格納された符号をワードストリーム
符号W1またはバイトストリーム符号B1として図65
のワードストリーム復号化部702の1バイト目及びバ
イトストリーム復号化部704の1バイト目に入力す
る。図64における残りの2バイト目、3バイト目、4
バイト目についても基本的に同じである。
Word / byte selection probability model unit 716-
Numeral 1 stores frequency data in which the conditional easiness of the input selection code connected to the immediately preceding selection code string is registered. The frequency data is searched by the conditional ease calculated by the selection code decoding unit 712-1. To restore the selected code, and further updates the frequency data according to the result of the restoration. The code switching unit 714-1 converts the code stored in the code buffer unit 710-1 into a word stream code W1 or a byte stream code B1 according to the decoding result of the selection code decoding unit 712-1 in FIG.
Of the word stream decoding unit 702 and the first byte of the byte stream decoding unit 704. The remaining second byte, third byte, and fourth byte in FIG.
The same applies to the byte.

【0281】図65のワードストリーム復号化部702
及びバイトストリーム復号化部704は、図64の符号
分離選択部700で分離選択された各バイト位置のワー
ドストリーム符号またはバイトストリーム符号を並列的
に復号化する。ワードストリーム復号化部702は1バ
イト目、2バイト目、3バイト目、4バイト目の各ワー
ドストリーム符号W1〜W4に対応して、符号分配部7
20−1〜720−4、復号化部722−1〜722−
4及び確率モデル部724−1〜724−4をもってい
る。
A word stream decoding unit 702 shown in FIG.
The byte stream decoding unit 704 decodes the word stream code or the byte stream code at each byte position separated and selected by the code separation / selection unit 700 in FIG. 64 in parallel. The word stream decoding unit 702 corresponds to each of the word stream codes W1 to W4 of the first byte, the second byte, the third byte, and the fourth byte.
20-1 to 720-4, decoding units 722-1 to 722-
4 and the probability model units 724-1 to 724-4.

【0282】このうち復号化部722−1〜722−4
にあっては、ブレンド文脈として0次から3次までの復
号化を扱うことから、0次〜3次の各符号化部を並列的
に備えている。同様に確率モデル部724−1〜724
−4についても、0次から3次までの各確率モデル部を
並列的に備えている。符号分配部720−1〜720−
4は1バイト目から4バイト目の各入力符号W1〜W4
のビット構成から文脈の次数である0次、1次、2次、
または3次を認識し、対応する復号化部722−1〜7
22−4の次数符号化部に入力する。ブレンド文脈の全
次数を並列的に復号化する復号化部722−1〜722
−4及び確率モデル部724−1〜724−4の詳細
は、図27〜図29に示したとおりである。
The decoding units 722-1 to 722-4 among them
, Since decoding from the 0th order to the 3rd order is handled as the blend context, 0th to 3rd order encoding units are provided in parallel. Similarly, the probability model units 724-1 to 724
-4 also includes the 0th to 3rd order probability model units in parallel. Code distribution units 720-1 to 720-
4 is each input code W1 to W4 of the 1st to 4th bytes
From the bit configuration of 0, 1 order, 2 order,
Alternatively, a third order is recognized, and the corresponding decoding units 722-1 to 72-7 are recognized.
22-4. Decoding sections 722-1 to 722 for decoding all orders of the blend context in parallel
-4 and the details of the probability model units 724-1 to 724-4 are as shown in FIGS.

【0283】一方、バイトストリーム復号化部704も
ワードストリーム復号化部702と同様、ブレンド文脈
について全次数の復号化を並列化した実施形態をとって
いる。即ち、1バイト目から4バイト目の入力バイトス
トリーム符号B1〜B4に対応して符号分配部730−
1〜730−4、0次から3次の復号化部を並列的に備
えた復号化部732−1〜732−4、及び0次から3
次の確率モデル部を並列的に備えた734−1〜734
−4を備えている。
On the other hand, like the word stream decoding unit 702, the byte stream decoding unit 704 adopts an embodiment in which decoding of all orders is performed in parallel for the blend context. That is, the code distribution unit 730- corresponds to the input byte stream codes B1 to B4 of the first to fourth bytes.
Decoding units 732-1 to 732-4 having decoding units of 0th to 3rd order in parallel and 0th to 3rd order
734-1 to 734 provided with the following probability models in parallel
-4.

【0284】このようなワードストリーム復号化部70
2及びバイトストリーム復号化部704により、図64
に設けた前段の符号分離選択部700で選択された1ワ
ードを構成する4バイト分の4つの符号が有効入力符号
としてワードストリーム復号化部702及びまたはバイ
トストリーム復号化部704に選択的に入力され、並列
的に1ワード分のバイトデータの復元が行われる。
[0284] Such a word stream decoding unit 70
64 and the byte stream decoding unit 704 in FIG.
The four codes of 4 bytes constituting one word selected by the code separation / selection unit 700 at the preceding stage provided as input signals are selectively input to the word stream decoding unit 702 and / or the byte stream decoding unit 704 as effective input codes. The byte data for one word is restored in parallel.

【0285】なお、ワード単位の復元において、ワード
ストリーム復号化部702及びバイトストリーム復号化
部704に対する入力符号W1〜W4,B1〜B4のう
ちの4つが有効な入力符号であり、有効な入力符号につ
いてのみ復号化を行わせ、有効な入力符号のない系統に
ついては復号化の処理を禁止する。図66の出力切替部
706は、図65のワードストリーム復号化部702及
びバイトストリーム復号化部704で並列的に復号され
たバイトデータ、即ちワードストリーム方向の復元バイ
トデータWR11〜WR41とバイトストリーム方向の
復元バイトデータBR11〜BR41を1バイト目から
4バイト目の各バイト位置ごとに入力し、有効な符号入
力で復号をした側の復元バイトデータを出力選択部84
0−1〜840−4で選択し、文脈取り込み用レジスタ
部842に入力している。
In the word unit restoration, four of the input codes W1 to W4 and B1 to B4 to the word stream decoding unit 702 and the byte stream decoding unit 704 are valid input codes, and , And decoding is prohibited for a system without a valid input code. The output switching unit 706 in FIG. 66 includes the byte data decoded in parallel by the word stream decoding unit 702 and the byte stream decoding unit 704 in FIG. 65, that is, the restored byte data WR11 to WR41 in the word stream direction and the byte stream direction. Of the restored byte data BR11-BR41 for each byte position from the first byte to the fourth byte, and outputs the restored byte data on the side decoded with valid code input to the output selector 84.
0-1 to 840-4 are selected and input to the context capture register unit 842.

【0286】文脈取り込み用レジスタ部842は、各バ
イト位置ごとに4つのレジスタを直列接続したレジスタ
群842−1〜842−4を備えている。ここで1バイ
ト目のレジスタ群842−1はレジスタR110〜R1
40で示され、2バイト目のレジスタ群842−2はレ
ジスタR210〜R240で示され、3バイト目のレジ
スタ群842−3はレジスタR310〜R340で示さ
れ、更に4バイト目のレジスタ群842−4はレジスタ
R410〜R440で示されている。
The context capturing register section 842 includes register groups 842-1 to 842-4 in which four registers are connected in series for each byte position. Here, the register group 842-1 of the first byte includes the registers R110 to R1.
The register group 842-2 at the second byte is indicated by registers R210 to R240, the register group 842-3 at the third byte is indicated by registers R310 to R340, and the register group 842- at the fourth byte. 4 is indicated by registers R410 to R440.

【0287】文脈取り込み用レジスタ部842の1段目
のレジスタ群R110,R210,R310,R410
には、復元された1ワード分の各バイト位置のバイトデ
ータが保持されている。このため、レジスタR110〜
R410の各バイトデータを並列的に読み出すことで、
復元ソースデータとして1ワード分のワードデータが得
られる。
The register group R110, R210, R310, R410 of the first stage of the register unit 842 for context capture
Holds the restored byte data of each byte position for one word. Therefore, the registers R110 to R110
By reading each byte data of R410 in parallel,
One-word word data is obtained as restoration source data.

【0288】このとき2段目のレジスタR120〜R4
20、3段目のレジスタR130〜R430、及び4段
目のレジスタR140〜R440には、各バイト位置ご
とに1つ前、2つ前、更に3つ前に復元された各ワード
のバイトデータが保持されている。これら既に復元済み
の各ワードのバイトデータは、図65のワードストリー
ム復号化部702及びバイトストリーム復号化部704
の確率モデル部に文脈として取り込まれている。
At this time, the second-stage registers R120 to R4
20, the third-stage registers R130 to R430 and the fourth-stage registers R140 to R440 store the byte data of each word restored one before, two before, and three before each byte position. Is held. The byte data of each of these already restored words is supplied to the word stream decoding unit 702 and the byte stream decoding unit 704 in FIG.
Is included as a context in the probability model part of.

【0289】この文脈の取り込みについて、ワードスト
リーム復号化部702に設けている確率モデル部724
−1〜724−4については、1次から3次の確率モデ
ル部に対し図66の文脈取り込み用レジスタ部842に
格納されたバイトデータにつき、ワードストリーム方向
のバイトデータの取り込みが行われている。例えば1バ
イト目の確率モデル部742−1を例にとると、図66
のレジスタR120,R130,R140に1ワード
前、2ワード前及び3ワード前の各1バイト目の復元さ
れたバイトデータが保持されていることから、これを図
65のように、レジスタR120,R130,R140
として1次から3次の確率モデル部に文脈として取り込
んでいる。
With respect to the capture of the context, the probability model unit 724 provided in the word stream decoding unit 702
Regarding −1 to 724-4, byte data in the word stream direction is captured for the byte data stored in the context capturing register unit 842 in FIG. 66 for the first to third-order probability model units. . For example, taking the probability model unit 742-1 at the first byte as an example, FIG.
Since the restored byte data of the 1st byte before one word, two words before, and three words before are stored in the registers R120, R130, R140 of FIG. , R140
As a context in the first to third order probability model parts.

【0290】これに対し図65のバイトストリーム復号
化部704の確率モデル部734−1〜734−4に対
しては、文脈取り込み用レジスタ部842におけるバイ
トストリーム方向のバイトデータの取り込みが行われて
いる。例えば4バイト目の確率モデル部734−4を例
にとると、0次確率モデル部に対する現時点の復元バイ
トデータに対し先行するバイトストリーム方向のバイト
データとして、レジスタR310,R210,R110
を1次、2次、3次の文脈に対するバイトデータとして
取り込んでいる。
On the other hand, with respect to the probability model units 734-1 to 734-4 of the byte stream decoding unit 704 in FIG. 65, byte data in the byte stream direction is captured in the context capturing register unit 842. I have. For example, taking the probability model unit 734-4 at the fourth byte as an example, registers R310, R210, and R110 are used as byte data in the byte stream direction preceding the current restored byte data for the zero-order probability model unit.
Is taken as byte data for the primary, secondary, and tertiary contexts.

【0291】もちろん、ワードストリーム復号化部70
2の確率モデル部724−1〜724−4及びバイトス
トリーム復号化部704の確率モデル部734−1〜7
34−4のいずれについても、0次確率モデル部に対す
るワードデータの取り込みは前段の0次復号化部による
復元データをそのまま使用することから、図66の文脈
取り込み用レジスタ部842からのバイトデータの取り
込みは必要ない。
Of course, the word stream decoding unit 70
2 probability model units 724-1 to 724-4 and the probability model units 734-1 to 734-1 of the byte stream decoding unit 704.
In any of the cases 34-4, since the restoration of the word data into the 0th-order probability model unit uses the restored data by the 0th-order decoding unit at the preceding stage as it is, the byte data from the context acquisition register unit 842 in FIG. No uptake required.

【0292】尚、上記の実施形態におけるワードストリ
ーム方向の符号化、復号化については、ワードデータを
複数のバイトデータに分離して圧縮または復元する場合
を例にとっているが、本発明はこれに限定されず、プロ
グラムなどのオペコードを対象に、オペコードをその中
の複数ビット単位の種類ごとに分離して、各分離したデ
ータ単位に符号化と復号化を行うことも可能である。
Although the encoding and decoding in the word stream direction in the above-described embodiment is an example in which word data is divided into a plurality of byte data and compressed or decompressed, the present invention is not limited to this. Instead, it is also possible to separate the operation code for each type of a plurality of bits in the operation code of a program or the like, and to perform encoding and decoding for each separated data unit.

【0293】更に上記の実施形態では、具体例として確
率統計型の符号化と復号化を例にとっているが、これ以
外にLZWやLZSSに代表される辞書型復号化と符号
化についても全く同様に適用することができる。
Further, in the above-described embodiment, as an example, the coding and decoding of the probability statistical type is taken as an example. In addition to this, the dictionary-type decoding and coding represented by LZW and LZSS are completely the same. Can be applied.

【0294】[0294]

【発明の効果】以上説明してきたように本発明によれ
ば、固定文脈のデータ圧縮については確率モデル部とエ
ントロピー符号化部をパイプライン動作させ、またデー
タ復元についてはエントロピー復号化部と確率モデル部
を同じくパイプライン動作させることで、従来複雑な処
理で時間が掛かっていた固定次数文脈の確率統計型の符
号化及び復号化を高速に実現することができる。
As described above, according to the present invention, the probability model unit and the entropy encoding unit are operated in a pipeline for data compression in a fixed context, and the entropy decoding unit and the probability model are used for data restoration in a fixed context. By performing the pipeline operation of the units in the same manner, it is possible to realize the coding and decoding of the probability statistical type of fixed-order context, which has conventionally taken a long time by complicated processing, at high speed.

【0295】またブレンド文脈の圧縮と復元ついても、
少なくとも確率モデル部を並列化し且つパイプライン化
することで、各次数ごとの直列処理により時間が掛かっ
ていたブレンド文脈についての確率統計型符号の圧縮と
復元を実用可能な処理時間でより高速に実現することが
できる。また本発明によれば、ワードストリーム方向で
のバイト単位の辞書型あるいは確率統計型による符号化
を行うことで、2バイトのユニコードや日本語コード、
RGB3バイトのフルカラー画像、4バイトや8バイト
といったプログラムコードなどのワードデータを圧縮す
る符号化において、ワードデータの中の同一バイト位置
の相関を符号化に取り込むことで圧縮効率を高めること
ができる。この場合にも、復号化及び符号化の処理をパ
イプライン化することで使用時間を実用化レベルに圧縮
した圧縮及び復元が実現できる。
Also, regarding the compression and decompression of the blend context,
By parallelizing and pipelining at least the stochastic model part, it is possible to compress and decompress the probability statistical code for the blend context, which took time due to the serial processing for each order, in a practically usable processing time and at a higher speed. can do. Further, according to the present invention, by performing encoding using a dictionary type or a probability statistical type in byte units in the word stream direction, 2-byte Unicode or Japanese code,
In encoding for compressing word data such as a program code such as a full-color image of 3 bytes of RGB, 4 bytes, and 8 bytes, the compression efficiency can be increased by incorporating the correlation of the same byte position in the word data into the encoding. Also in this case, compression and decompression in which the use time is reduced to a practical level can be realized by pipelining the decoding and encoding processes.

【0296】更にワードデータの圧縮復元として、ワー
ドデータを構成する各バイトデータにつきワードストリ
ーム方向とバイトストリーム方向での復号化を行って圧
縮効率の高い方の符号を適応的に選択することで、ワー
ドストリーム方向の符号化とバイトストリーム方向の符
号化の両方の利点を生かした効率的な圧縮処理を実現す
ることができる。
Further, as a decompression of the word data, decoding is performed in a word stream direction and a byte stream direction for each byte data constituting the word data, and a code having a higher compression efficiency is adaptively selected. Efficient compression processing that takes advantage of both the encoding in the word stream direction and the encoding in the byte stream direction can be realized.

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

【図1】本発明の原理説明図FIG. 1 is a diagram illustrating the principle of the present invention.

【図2】本発明の原理説明図(続き)FIG. 2 is a diagram illustrating the principle of the present invention (continued)

【図3】本発明の原理説明図FIG. 3 is a diagram illustrating the principle of the present invention.

【図4】本発明の原理説明図(続き)FIG. 4 is a diagram illustrating the principle of the present invention (continued).

【図5】固定次数文脈についてパイプライン化したデー
タ圧縮装置の基本構成のブロック図
FIG. 5 is a block diagram of a basic configuration of a data compression device pipelined for a fixed-order context.

【図6】図5のエントロピー符号化として算術符号化を
採用したデータ圧縮装置のブロック図
FIG. 6 is a block diagram of a data compression apparatus employing arithmetic coding as the entropy coding of FIG. 5;

【図7】図6のデータ圧縮装置の詳細構成のブロック図FIG. 7 is a block diagram of a detailed configuration of the data compression device of FIG. 6;

【図8】図7の頻度データ格納部の説明図FIG. 8 is an explanatory diagram of a frequency data storage unit in FIG. 7;

【図9】図7の算術符号化の出力符号形式の説明図9 is an explanatory diagram of an output code format of the arithmetic coding of FIG. 7;

【図10】図9の出力符号を生成する区間[1,0]の
比較処理の説明図
FIG. 10 is an explanatory diagram of a comparison process of a section [1, 0] for generating an output code in FIG. 9;

【図11】図7のパイプライン動作のタイムチャートFIG. 11 is a time chart of the pipeline operation of FIG. 7;

【図12】固定次数文脈についてパイプライン化したデ
ータ復元装置の基本構成のブロック図
FIG. 12 is a block diagram of a basic configuration of a data restoration apparatus pipelined for a fixed-order context.

【図13】図12のエントロピー復号化として算術復号
化を採用したデータ復元装置のブロック図
FIG. 13 is a block diagram of a data restoration apparatus employing arithmetic decoding as the entropy decoding of FIG. 12;

【図14】図13のデータ復元装置の詳細構成のブロッ
ク図
FIG. 14 is a block diagram of a detailed configuration of the data restoration device in FIG. 13;

【図15】図14のパイプライン動作のタイムチャートFIG. 15 is a time chart of the pipeline operation of FIG. 14;

【図16】図14のパイプライン動作のタイムチャート
(続き)
FIG. 16 is a time chart of the pipeline operation of FIG. 14 (continued)

【図17】ブレンド文脈について一部を並列化したデー
タ圧縮装置の基本ブロックと処理動作の説明図
FIG. 17 is an explanatory diagram of a basic block and a processing operation of a data compression device in which a blend context is partially parallelized;

【図18】図17のデータ圧縮装置の詳細構成のブロッ
ク図
18 is a block diagram of a detailed configuration of the data compression device in FIG.

【図19】図18のパイプライン動作のタイムチャートFIG. 19 is a time chart of the pipeline operation of FIG. 18;

【図20】ブレンド文脈について一部を並列化したデー
タ復元装置の基本ブロックと処理動作の説明図
FIG. 20 is an explanatory diagram of basic blocks and a processing operation of a data restoration device in which a part of a blend context is partially parallelized;

【図21】図20のデータ復元装置の詳細構成のブロッ
ク図
FIG. 21 is a block diagram of a detailed configuration of the data restoration device in FIG. 20;

【図22】図21のパイプライン動作のタイムチャートFIG. 22 is a time chart of the pipeline operation of FIG. 21;

【図23】図21のパイプライン動作のタイムチャート
(続き)
23 is a time chart of the pipeline operation in FIG. 21 (continued)

【図24】ブレンド文脈について全てを並列化したデー
タ圧縮装置の基本ブロックと処理動作の説明図
FIG. 24 is an explanatory diagram of basic blocks and processing operations of a data compression device in which all blend contexts are parallelized;

【図25】図24のデータ圧縮装置の詳細構成のブロッ
ク図
FIG. 25 is a block diagram of a detailed configuration of the data compression device in FIG. 24;

【図26】図25のパイプライン動作のタイムチャートFIG. 26 is a time chart of the pipeline operation of FIG. 25;

【図27】ブレンド文脈について全てを並列化したデー
タ復元装置の基本ブロックと処理動作の説明図
FIG. 27 is an explanatory diagram of basic blocks and a processing operation of a data restoration device in which all blend contexts are parallelized;

【図28】図27のデータ復元装置の詳細構成のブロッ
ク図
FIG. 28 is a block diagram of a detailed configuration of the data restoration device in FIG. 27;

【図29】図28のパイプライン動作のタイムチャートFIG. 29 is a time chart of the pipeline operation of FIG. 28;

【図30】本発明の出現頻度モデル部に設ける頻度デー
タ格納部の内部ハッシュ構造のブロック図
FIG. 30 is a block diagram of an internal hash structure of a frequency data storage unit provided in an appearance frequency model unit according to the present invention.

【図31】本発明の出現頻度モデル部に設ける頻度デー
タ格納部の内部ハッシュ構造及び外部ハッシュ構造のブ
ロック図
FIG. 31 is a block diagram of an internal hash structure and an external hash structure of a frequency data storage unit provided in an appearance frequency model unit according to the present invention.

【図32】ワードストリーム方向でバイト単位に符号化
するデータ圧縮装置のブロック図
FIG. 32 is a block diagram of a data compression device that performs encoding in byte units in the word stream direction.

【図33】図32の符号化処理のタイムチャートFIG. 33 is a time chart of the encoding process in FIG. 32;

【図34】ワード単位に圧縮バイトデータをまとめる符
号化処理のフローチャート
FIG. 34 is a flowchart of an encoding process for compiling compressed byte data in word units.

【図35】ワード単位に圧縮バイトデータをまとめた圧
縮データのフォーマット説明図
FIG. 35 is an explanatory diagram of a format of compressed data in which compressed byte data is collected in word units.

【図36】1ワード4バイト構成を例にとったワードス
トリーム方向の符号化の説明図
FIG. 36 is an explanatory diagram of encoding in the word stream direction taking a 1-word 4-byte configuration as an example.

【図37】図36の圧縮バイトデータを対象とした図3
5のフォーマットの具体的な説明図
FIG. 37 illustrates the compressed byte data of FIG. 36;
Illustration of format 5

【図38】ファイル単位に圧縮バイトデータをまとめる
符号化処理のフローチャート
FIG. 38 is a flowchart of an encoding process for combining compressed byte data in file units;

【図39】ファイル単位に圧縮バイトデータをまとめた
圧縮データのフォーマット説明図
FIG. 39 is an explanatory diagram of a format of compressed data in which compressed byte data is collected in file units;

【図40】図36の圧縮バイトデータを対象とした図3
9のフォーマットの具体的な説明図
FIG. 40 is a diagram showing the compressed byte data of FIG. 36 as a target;
Specific explanatory diagram of format 9

【図41】図32に確率統計型符号化を適用した場合の
ブロック図
FIG. 41 is a block diagram in the case where probability statistical coding is applied to FIG. 32;

【図42】図41の符号化パイプライン処理のタイムチ
ャート
FIG. 42 is a time chart of the encoding pipeline processing of FIG. 41;

【図43】ワードストリーム方向でバイト単位に復号化
するデータ復元装置のブロック図
FIG. 43 is a block diagram of a data restoration apparatus that decodes data in byte units in the word stream direction.

【図44】図43の復号化処理のタイムチャートFIG. 44 is a time chart of the decoding process in FIG. 43;

【図45】ワード単位に圧縮バイトデータをまとめた圧
縮データの復号化処理のフローチャート
FIG. 45 is a flowchart of a process of decoding compressed data in which compressed byte data is grouped in word units;

【図46】ファイル単位に圧縮バイトデータをまとめた
圧縮データの復号化処理のフローチャート
FIG. 46 is a flowchart of compressed data decoding processing in which compressed byte data is collected in file units;

【図47】図43に確率統計型復号化を適用した場合の
ブロック図
FIG. 47 is a block diagram in the case where probability statistical decoding is applied to FIG. 43;

【図48】図47の復号化パイプライン処理のタイムチ
ャート
FIG. 48 is a time chart of the decoding pipeline processing of FIG. 47;

【図49】ワードストリーム方向のバイトデータに算術
符号化を適用した場合のパイプライン制御の説明図
FIG. 49 is an explanatory diagram of pipeline control when arithmetic coding is applied to byte data in the word stream direction.

【図50】ワードストリーム方向のバイトデータに算術
復号化を適用した場合のパイプライン制御の説明図
FIG. 50 is an explanatory diagram of pipeline control when arithmetic decoding is applied to byte data in the word stream direction.

【図51】ワードストリーム方向のバイトデータに符号
木符号化を適用した場合のパイプライン制御の説明図
FIG. 51 is an explanatory diagram of pipeline control when code tree coding is applied to byte data in the word stream direction.

【図52】ワードストリーム方向のバイトデータに算術
復号化を適用した場合のパイプライン制御の説明図
FIG. 52 is an explanatory diagram of pipeline control when arithmetic decoding is applied to byte data in the word stream direction.

【図53】ワードストリーム方向とバイトストリーム方
向の符号化を適応的に切替えるデータ圧縮装置のブロッ
ク図
FIG. 53 is a block diagram of a data compression device that adaptively switches encoding in a word stream direction and a byte stream direction.

【図54】図53の符号化処理のタイムチャートFIG. 54 is a time chart of the encoding process in FIG. 53;

【図55】図54で得られる圧縮データのフォーマット
説明図
FIG. 55 is an explanatory diagram of a format of compressed data obtained in FIG. 54;

【図56】図54で圧縮バイトデータ単位に切替選択符
号を付加する場合の符号化処理のフローチャート
FIG. 56 is a flowchart of an encoding process when a switching selection code is added in units of compressed byte data in FIG. 54;

【図57】図54で圧縮ワード単位に切替選択符号を付
加する場合の符号化処理のフローチャート
FIG. 57 is a flowchart of an encoding process when a switching selection code is added in units of compressed words in FIG. 54;

【図58】ブレンド文脈を全並列化する確率統計型符号
化を適用した場合の図53のバイト配列変換部、ワード
ストリーム符号化部及びバイトストリーム符号化部の実
施形態のブロック図
FIG. 58 is a block diagram of an embodiment of a byte array conversion unit, a word stream coding unit, and a byte stream coding unit in FIG. 53 in the case of applying the probability statistical coding that makes the blend context all parallel;

【図59】ブレンド文脈を全並列化する確率統計型符号
化を適用した場合の図53の切替出力部の実施形態のブ
ロック図
FIG. 59 is a block diagram of an embodiment of the switching output unit in FIG. 53 in the case of applying the probability statistical coding for fully parallelizing the blend context.

【図60】ワードストリーム方向とバイトストリーム方
向の復号化を適応的に切替えるデータ復元装置のブロッ
ク図
FIG. 60 is a block diagram of a data restoration device that adaptively switches decoding in the word stream direction and the byte stream direction.

【図61】図60の復号化処理のタイムチャートFIG. 61 is a time chart of the decoding process in FIG. 60;

【図62】図60で圧縮バイトデータ単位に切替選択符
号を付加した圧縮データの復号化処理のフローチャート
FIG. 62 is a flowchart of a decoding process of compressed data in which a switching selection code is added in units of compressed byte data in FIG. 60;

【図63】図60で圧縮ワード単位に切替選択符号を付
加した圧縮データの復号化処理のフローチャート
FIG. 63 is a flowchart of a process of decoding compressed data to which a switching selection code is added in units of compressed words in FIG. 60;

【図64】ブレンド文脈を全並列化する確率統計型復号
化を適用した場合の図60の符号分離選択部の実施形態
のブロック図
FIG. 64 is a block diagram of an embodiment of the code separation / selection unit in FIG. 60 in the case of applying the probability statistical decoding that makes the blend contexts all parallel.

【図65】ブレンド文脈を全並列化する確率統計型符号
化を適用した場合の図60のワードストリーム符号化部
及びバイトストリーム符号化部の実施形態のブロック図
FIG. 65 is a block diagram of an embodiment of the word stream encoding unit and the byte stream encoding unit in FIG. 60 in the case of applying the probability statistical coding for fully parallelizing the blend context.

【図66】ブレンド文脈を全並列化する確率統計型復号
化を適用した場合の図60の切替出力部の実施形態のブ
ロック図
FIG. 66 is a block diagram of an embodiment of a switching output unit in FIG. 60 in the case of applying probability statistic type decoding that makes the blend contexts all parallel;

【図67】従来の確率統計型のデータ圧縮装置の基本構
成のブロック図
FIG. 67 is a block diagram of a basic configuration of a conventional probability statistical data compression apparatus.

【図68】文字列に対する文脈の木構造と条件付確率の
説明図
FIG. 68 is an explanatory diagram of a tree structure of a context and a conditional probability with respect to a character string;

【図69】従来の多値算術符号化の原理説明図FIG. 69 is a view for explaining the principle of conventional multi-level arithmetic coding.

【図70】従来の多値算術符号化の機能ブロック図FIG. 70 is a functional block diagram of a conventional multi-level arithmetic coding.

【図71】従来の一重履歴(0次固定文脈)による多値
算術符号化のフローチャート
FIG. 71 is a flowchart of conventional multi-level arithmetic coding using a single history (zero-order fixed context).

【図72】従来の二重履歴(1次固定文脈)による多値
算術符号化のフローチャート
FIG. 72 is a flowchart of conventional multi-level arithmetic coding using double history (primary fixed context).

【符号の説明】[Explanation of symbols]

10:出現頻度モデル部 11,15,47,51,85,125,175,21
5:パイプライン制御部 12:エントロピー符号化部 14:確率モデル部 16:算術符号化部 18,94:順位読出更新部 20,72,98,156:文字読出更新部 22,74,100,158:頻度読出更新部 24,76,100,160:累積頻度読出更新部 25,70,96,154:頻度データ格納部 26,78,106,162:総累積頻度読出更新部 28,58,116,142:符号空間算出部(ハイレ
ベル算出部) 30,60,118,144:符号空間算出部(ローレ
ベル算出部) 32,62,66,120,146,150:逆数算出
部 34,122:算術符号導出部 36,124,138,170:符号出力部 38-1〜38-4,40-1〜40-3,42-1,42-2,44:最終文字の符号
空間 46:エントロピー復号化部 48:出現頻度モデル部 50,126,224:算術復号化部 52:確率モデル部 54,212:符号入力部 56,140:累積値導出部 64,148:累積頻度導出部 68,152:順位導出部 80,164:文字出力部 82,128,170,216,166:ブレンド用確
率モデル部 84:バッファ選択部 86,168:算術符号化部 88,130,172,230:0次確率モデル部 90,132,174,232:1次確率モデル部 92,134,176,234:2次確率モデル部 95:エスケープ用頻度検索更新部 104:エスケープ判断部 108,110,112:バッファ部 114,136,136−1〜136−3,190,2
36:選択部 178,172:0次算術符号化部 180,174:1次算術符号化部 182,176:2次算術符号化部 184,218:0次符号バッファ部 186,220:1次符号バッファ部 188,222:2次符号バッファ部 190:マージ部 192:,194,196:順位読出更新部 198,200,202:頻度・累積頻度読出更新部 204,258:選択部 211:分離部 260,262,264:符号空間算出部 266,268,270:算術符号導出部 272,274,276:シリアル/パラレル変換符号
出力部 211:分離部 224,172:0次算術復号化部 226,174:1次算術復号化部 228,176:2次算術復号化部 278,280,282:パラレル/シリアル変換符号
入力部 284,286,288:算術符号順位導出部 290,292,294:符号空間算出部 246,248,250:順位・頻度・累積頻度読出更
新部 246,248,250:文字読出更新部 500:バイト配列変換部 502,502−1〜502−n:バイト単位符号化部 503:符号マージ部 504,514:ヘッダ 504−1〜504−n:バイトヘッダ 506,516:圧縮データ 512−1,512−2:圧縮ワードデータ 514−1〜514−n:ファイルヘッダ 516−1〜516−n:バイトファイル 518−1〜518−4,540−1〜540−4:レ
ジスタ群(文脈取込み用) 520−1〜520−4:出現頻度モデル部 522−1〜522−4:エントロピー符号化部 524−1〜524−4,534−1〜534−4:符
号バッファ部 530:符号分離部 530,532−1〜532−n:バイト単位復号化部 530:符号分離部 536−1〜536−4:エントロピー復号化部 538−1〜538−4:出現頻度モデル部(復元用) 542:確率モデル検索部 544:確率モデル更新部 546:符号空間演算部 548:算術符号出力部 550:算術符号入力部 552:累積値演算部 554:符号空間演算部 556:確率モデル検索部 558:出力文字検索部 560:確率モデル更新部 562:文脈収集処理部 564:符号木符号化部 568:文脈木検索部 570:文脈木登録部 572:同文脈判断部 574:符号木検索部 576:符号木更新登録部 578:符号並べ替え部 580:符号木復号化部 582:文脈収集処理部 586:符号木検索部 588:符号木更新登録部 590:文脈木検索部 592:文脈木登録部 600:バイト配列変換部 602:ワードストリーム符号化部 604:バイトストリーム符号化部 606:符号切替部 620−1〜620−4,630−1〜630−4:確
率モデル部 622−1〜622−4,632−1〜632−4:符
号化部 624−1〜624−4,634−1〜634−4:符
号バッファ部 640−1〜640−4:ビット数比較部 642−1〜642−4:ワード/バイト選択確率モデ
ル部 644−1〜644−4:符号化部 648−1〜648−4:符号切替部 652:符号マージ部 700:符号分離選択部 702:ワードストリーム復号化部 704:バイトストリーム復号化部 706:出力切替部 708:符号分離部 712−1〜712−4:選択符号復号化部 714−1〜714−4:符号切替部 716−1〜716−4:ワード/バイト選択確率モデ
ル部 720−1〜720−4,730−1〜730−4:符
号分配部 722−1〜722−4,732−1〜732−4:復
号化部 724−1〜724−4,734−1〜734−4:確
率モデル部 840−1〜840−4:出力選択部
10: Appearance frequency model part 11, 15, 47, 51, 85, 125, 175, 21
5: Pipeline control unit 12: Entropy coding unit 14: Probability model unit 16: Arithmetic coding unit 18, 94: Rank reading / updating unit 20, 72, 98, 156: Character reading / updating unit 22, 74, 100, 158 : Frequency read / update units 24, 76, 100, 160: cumulative frequency read / update units 25, 70, 96, 154: frequency data storage units 26, 78, 106, 162: total cumulative frequency read / update units 28, 58, 116, 142: code space calculation unit (high level calculation unit) 30, 60, 118, 144: code space calculation unit (low level calculation unit) 32, 62, 66, 120, 146, 150: reciprocal calculation unit 34, 122: arithmetic Code deriving units 36, 124, 138, 170: Code output units 38-1 to 38-4, 40-1 to 40-3, 42-1, 42-2, 44: Code space of the last character 46: Entropy decoding Part 48: Frequency of appearance Model part 50, 126, 224: arithmetic decoding part 52: probability model part 54, 212: code input part 56, 140: cumulative value deriving part 64, 148: cumulative frequency deriving part 68, 152: rank deriving part 80, 164 : Character output unit 82, 128, 170, 216, 166: Blending probability model unit 84: Buffer selection unit 86, 168: Arithmetic coding unit 88, 130, 172, 230: 0th-order probability model unit 90, 132, 174 , 232: first-order probability model unit 92, 134, 176, 234: second-order probability model unit 95: escape frequency search / update unit 104: escape determination unit 108, 110, 112: buffer unit 114, 136, 136-1 136-3,190,2
36: Selection unit 178, 172: 0th-order arithmetic coding unit 180, 174: 1st-order arithmetic coding unit 182, 176: Secondary-arithmetic coding unit 184, 218: 0th-order code buffer unit 186, 220: 1st-order code Buffer unit 188, 222: Secondary code buffer unit 190: Merging unit 192 :, 194, 196: Rank reading / updating unit 198, 200, 202: Frequency / cumulative frequency reading / updating unit 204, 258: Selection unit 211: Separation unit 260 , 262, 264: code space calculation unit 266, 268, 270: arithmetic code derivation unit 272, 274, 276: serial / parallel conversion code output unit 211: separation unit 224, 172: zero-order arithmetic decoding unit 226, 174: Primary arithmetic decoding unit 228, 176: Secondary arithmetic decoding unit 278, 280, 282: Parallel / serial conversion code input unit 28 , 286, 288: Arithmetic code rank deriving unit 290, 292, 294: Code space calculation unit 246, 248, 250: Rank / frequency / cumulative frequency reading / updating unit 246, 248, 250: Character reading / updating unit 500: Byte array conversion Units 502, 502-1 to 502-n: Byte unit encoding unit 503: Code merging unit 504, 514: Header 504-1 to 504-n: Byte header 506, 516: Compressed data 512-1, 512-2: Compressed word data 514-1 to 514-n: file header 516-1 to 516-n: byte file 518-1 to 518-4, 540-1 to 540-4: register group (for capturing context) 520-1 520-4: Appearance frequency model section 522-1 to 522-4: Entropy coding section 524-1 to 524-4, 534-1 to 34-4: Code buffer unit 530: Code separation unit 530, 532-1 to 532-n: Byte unit decoding unit 530: Code separation unit 536-1 to 536-4: Entropy decoding unit 538-1 to 538- 4: appearance frequency model unit (for restoration) 542: probability model search unit 544: probability model update unit 546: code space operation unit 548: arithmetic code output unit 550: arithmetic code input unit 552: cumulative value operation unit 554: code space Arithmetic unit 556: Probability model search unit 558: Output character search unit 560: Probability model update unit 562: Context collection processing unit 564: Code tree coding unit 568: Context tree search unit 570: Context tree registration unit 572: Same context judgment Unit 574: code tree search unit 576: code tree update registration unit 578: code rearrangement unit 580: code tree decoding unit 582: context collection processing unit 58 : Code tree search unit 588: code tree update registration unit 590: context tree search unit 592: context tree registration unit 600: byte array conversion unit 602: word stream coding unit 604: byte stream coding unit 606: code switching unit 620 -1 to 620-4, 630-1 to 630-4: Probability model unit 622-1 to 622-4, 632-1 to 632-4: Encoding unit 624-1 to 624-4, 634-1 to 634 -4: code buffer section 640-1 to 640-4: bit number comparing section 642-1 to 642-4: word / byte selection probability model section 644-1 to 644-4: coding section 648-1 to 648- 4: code switching unit 652: code merging unit 700: code separation selection unit 702: word stream decoding unit 704: byte stream decoding unit 706: output switching unit 708: Code separation units 712-1 to 712-4: selected code decoding units 714-1 to 714-4: code switching units 716-1 to 716-4: word / byte selection probability model units 720-1 to 720-4, 730-1 to 730-4: code distribution units 722-1 to 722-4, 732-1 to 732-4: decoding units 724-1 to 724-4, 734-1 to 734-4: probability model units 840 -1 to 840-4: output selection unit

フロントページの続き (56)参考文献 特開 平2−202267(JP,A) 特開 平4−280517(JP,A) 特開 平5−128103(JP,A) 特開 平5−14206(JP,A) 特開 平5−224878(JP,A) 特開 平5−128100(JP,A) 特開 平5−241777(JP,A) 特開 平6−28149(JP,A) 特開 平6−90362(JP,A) 特開 平6−44038(JP,A) 特開 平6−149537(JP,A) 特開 平3−213019(JP,A) (58)調査した分野(Int.Cl.7,DB名) H03M 7/40 Continuation of front page (56) References JP-A-2-202267 (JP, A) JP-A-4-280517 (JP, A) JP-A-5-128103 (JP, A) JP-A-5-14206 (JP) JP-A-5-224878 (JP, A) JP-A-5-128100 (JP, A) JP-A-5-241777 (JP, A) JP-A-6-28149 (JP, A) 6-90362 (JP, A) JP-A-6-44038 (JP, A) JP-A-6-149537 (JP, A) JP-A-3-213019 (JP, A) (58) Fields investigated (Int. Cl. 7 , DB name) H03M 7/40

Claims (11)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】入力文字を直前文字列の条件付出易さによ
り符号化を行うデータ圧縮装置に於いて、 直前の文字列に繋がる入力文字の条件付出易さを各文字
毎に登録した頻度データ格納部を有し、直前の文字列に
繋がる入力文字の条件付出易さを前記頻度データ格納部
の参照により検索すると共に、前記頻度データ格納部を
登録更新する出現頻度モデル部と、 前記出現頻度モデル部で求めた前記条件付出易さにより
入力文字を符号化するエントロピー符号化部と、 前記出現頻度モデル部とエントロピー符号化部をパイプ
ライン動作させるパイプライン制御部と、 を備え、前記パイプライン制御部は、第1サイクル目で入力文字
列の先頭文字を前記出現頻度モデル部に入力して該入力
文字の条件付出易さを求め、第2サイクル目以降の各サ
イクルでは、前記文字列の次の文字を前記出現頻度モデ
ル部に入力して該入力文字の条件付出易さを求めると共
に、前サイクルで求められた文字の条件付出易さを前記
エントロピー符号化部に入力して該入力文字の出現頻度
の符号化する処理を繰り返す ことを特徴とするデータ圧
縮装置。
In a data compression apparatus for encoding an input character according to a conditional ease of a preceding character string, frequency data in which the conditional ease of an input character connected to the immediately preceding character string is registered for each character An appearance frequency model unit that has a storage unit, searches for the conditional ease of input characters connected to the immediately preceding character string by referring to the frequency data storage unit, and registers and updates the frequency data storage unit; comprising an entropy encoding unit encoding an input character by the conditional Deeki of determined model unit, a pipeline control unit for the occurrence frequency modeling unit and entropy coding unit pipelined operation, said pipeline In the first cycle, the control unit
Input the first character of the column to the appearance frequency model
The conditional ease of character output is determined, and each
In the cycle, the next character of the character string is
Input to the text box to determine the conditional ease of input characters.
In addition, the conditional ease of character obtained in the previous cycle
Appearance frequency of the input character input to the entropy encoding unit
A data compression apparatus that repeats the encoding process .
【請求項2】入力された符号と既に復元されている直前
の文字列の条件付出易さにより文字を復元するデータ復
元装置に於いて、 入力された符号と既に復元されている直前の文字列から
条件付出易さを求めるエントロピー復号化部と、 直前の文字列に繋がる入力文字の条件付出易さを各文字
毎に登録した頻度データ格納部を有し、前記エントロピ
ー復号化部で求めた条件付出易さにより前記頻度データ
格納部を検索して文字を復元すると共に、前記頻度デー
タ格納部を登録更新する出現頻度モデル部と、 前記エントロピー復号化部と出現頻度モデル部とをパイ
プライン動作させるパイプライン制御部と、 を備え、前記パイプライン制御部は、第1サイクル目で入力文字
列の先頭文字を前記エントロピー復号化部に入力して該
入力文字の条件付出易さを求め、第2サイクル目以降の
各サイクルでは、前記文字列の次の文字を前記エントロ
ピー復号化部に入力して該入力文字の条件付出易さを求
めると共に、前サイクルで求められた文字の条件付出易
さを前記出現頻度モデル部に入力して該入力文字の復元
する処理を繰り返す ことを特徴とするデータ復元装置。
2. A data restoration apparatus for restoring a character according to a conditional ease of input of an inputted code and a character string immediately before being restored. An entropy decoding unit that obtains a conditional ease from the input data, and a frequency data storage unit that registers, for each character, the conditional ease of an input character connected to the immediately preceding character string, and a condition obtained by the entropy decoding unit. The frequency data storage unit is searched according to the ease of attachment to restore characters, and an appearance frequency model unit for registering and updating the frequency data storage unit is pipelined with the entropy decoding unit and the appearance frequency model unit. And a pipeline control unit, wherein the pipeline control unit receives an input character in a first cycle.
The first character of the column is input to the entropy decoding unit and
The conditional ease of input characters is determined, and the second and subsequent cycles
In each cycle, the next character of the string is
To the conditional decoding of the input character
As well as conditional access to characters determined in the previous cycle
Is input to the appearance frequency model section to restore the input characters.
A data restoring apparatus characterized by repeating a process of performing a data restoration.
【請求項3】入力文字を直前の長い文字列でなる高次文
脈から短い文字列でなる低次文脈へと条件付出易さによ
り符号化を行うデータ圧縮装置に於いて、 直前の文字列に繋がる入力文字の条件付出易さを前記各
次数毎に登録した頻度データ格納部を有し、前記各次数
における直前の文字列に繋がる入力文字の条件付出易さ
を前記頻度データ格納部の参照により検索すると共に前
記頻度データ格納部を登録更新する処理を、各次数毎に
並列的に行う各次数毎に設けられた複数の出現頻度モデ
ル部と、 前記複数の出現頻度モデル部の各次数の条件付出易さを
高次の文脈から低次の文脈の順に符号化するエントロピ
ー符号化部と、前記複数の出現頻度モデル部と前記エントロピー符号化
部とをパイプライン動作させるパイプライン制御部と、 を備え前記パイプライン制御部は、第1サイクル目で入力文字
列の先頭文字を前記複数の出現頻度モデル部に並列的に
入力して各次数の条件付出易さを並列的に求め、第2サ
イクル目以降は、第1サイクル目で求めた各次数の条件
付出易さを前記エントロピー符号化部に出力して高次文
脈の符号から低次文脈の符号の順に算術符号化すると同
時に、前記入力文字列の次の文字を前記複数の出現頻度
モデル部に入力して各字数の出現頻度を並列的に求める
処理を繰り返す ことを特徴とするデータ圧縮装置。
3. A data compression apparatus for encoding an input character from a high-order context consisting of a long character string immediately before to a low-order context consisting of a short character string according to conditional easiness of output. A frequency data storage unit in which the conditional ease of input characters connected is registered for each of the orders, and the conditional ease of input characters connected to the immediately preceding character string in each order is referred to by referring to the frequency data storage unit. A plurality of appearance frequency model units provided for each order, in which a search and a process of registering and updating the frequency data storage unit are performed in parallel for each order, and a condition for each order of the plurality of appearance frequency model units An entropy encoding unit that encodes the ease of attachment from a higher-order context to a lower-order context, the plurality of appearance frequency model units, and the entropy encoding
Includes a pipeline control unit for the parts pipeline operation, said pipeline control unit, an input character in a first cycle
The first character of the column is added in parallel to the plurality of appearance frequency model parts.
To obtain the conditional ease of output of each order in parallel.
After the cycle, the conditions for each order obtained in the first cycle
The degree of attachment is output to the entropy encoding unit, and
Arithmetic encoding is performed in the order of pulse code and low-order context code.
Sometimes, the next character of the input character string is
Input to the model part and calculate the appearance frequency of each number of characters in parallel
A data compression device characterized by repeating processing .
【請求項4】入力された符号と既に復元されている直前
の長い文字列でなる高次文脈から短い文字列でなる低次
文脈の順に文字を復元するデータ復元装置に於いて、 入力された符号と既に復元されている各次数の直前の文
字列に基づき高次文脈から低次文脈の順に条件付出易さ
を求めるエントロピー復号化部と、 直前の文字列に繋がる入力文字の条件付出易さを前記各
次数毎に登録した頻度データ格納部を有し、前記エント
ロピー復号化部で求めた各次数の条件付出易さから前記
頻度データ格納部の参照による文字を復元すると共に前
記頻度データ格納部を登録更新する処理を、各次数毎に
並列的に行う各次数毎に設けられた複数の出現頻度モデ
ル部と、前記エントロピー復号化部と複数の出現頻度モデル部と
をパイプライン動作させるパイプライン制御部と、 を備え、 前記パイプライン制御部は、第1サイクル目で入力符号
列の先頭符号を前記エントロピー復号化部に入力してあ
る次数の条件付出易さを求めて前記複数の出現頻度モデ
ル部に並列的に出力し、第2サイクル目以降は、前記第
1サイクル目で出力された条件付き出易さの次数に対応
する前記出現頻度モデル部で復元された文字を出力する
と同時、前記入力符号列の次の符号を前記エントロピー
復号化部に入力してある次数の条件付出易さを求め前記
複数の出現頻度モデル部に並列的に出力する処理を繰り
返す ことを特徴とするデータ復元装置。
4. A data restoration apparatus for restoring characters in order from a high-order context consisting of a long character string immediately before being restored with an inputted code and a short character string. An entropy decoding unit that obtains conditional ease in order from higher-order context to lower-order context based on the code and the character string immediately before each degree that has already been restored; and conditional ease of input characters connected to the immediately preceding character string. Has a frequency data storage unit registered for each of the degrees, and restores a character by referring to the frequency data storage unit from the conditional ease of each degree obtained by the entropy decoding unit, and stores the frequency data storage unit A plurality of appearance frequency model units provided for each order to perform a process of registering and updating in parallel for each order, and the entropy decoding unit and a plurality of appearance frequency model units.
The includes a pipeline control unit for pipeline operation, and the pipeline control unit, an input code in the first cycle
The head code of the column is input to the entropy decoding unit.
The conditional appearance easiness of the order is calculated to obtain the plurality of appearance frequency models.
Output to the controller in parallel.
Corresponds to the degree of conditional ease output in the first cycle
Output the characters restored by the appearance frequency model part
At the same time as the next code of the input code sequence
Determining the conditional ease of order that has been input to the decoding unit,
Repeat the process of outputting to multiple appearance frequency model parts in parallel.
A data restoration device characterized by returning .
【請求項5】入力文字を直前の長い文字列でなる高次文
脈から短い文字列でなる低次文脈へと条件付出易さによ
り符号化を行うデータ圧縮装置に於いて、 直前の文字列に繋がる入力文字の条件付出易さを前記各
次数毎に登録した頻度データ格納部を有し、前記各次数
における直前の文字列に繋がる入力文字の条件付出易さ
を前記頻度データ格納部の参照により検索すると共に前
記頻度データ格納部を登録更新する処理を、各次数毎に
並列的に行う各次数毎に独立に設けられた複数の出現頻
度モデル部と、 前記複数の出現頻度モデル部の各次数の条件付出易さを
エントロピー符号化する処理を、各次数毎に並列的に行
う各次数毎に独立に設けられたエントロピー符号化部
と、 前記各次数のエントロピー符号化部より出力される符号
をまとめて出力する符号マージ部と、各次数毎に並列的に設けられた前記複数の出現頻度モデ
ル部と前記複数のエントロピー符号化部とを、各次数毎
にパイプライン動作させるパイプライン制御部と、 を備え、 前記パイプライン制御部は、 第1サイクル目で入力文字列の先頭文字を前記複数の出
現頻度モデル部に並列的に入力して各次数の条件付出易
さを並列的に求め、各次数に対応した前記複数の出現頻
度モデル部の各々に出力し第2サイクル目以降は、第1サイクル目で求めた各次数
の条件付出易さを対応する前記複数のエントロピー符号
化部に入力して高次文脈から低次文脈の各符号に符号化
して出力する同時に、前記入力文字列の次の文字を前記
複数の出現頻度モデル部に入力して各字数の出現頻度を
並列的に求め、各次数に対応した前記複数の出現頻度モ
デル部の各々に出力する処理を繰り返す ことを特徴とす
るデータ圧縮装置。
5. A data compression apparatus for encoding an input character from a high-order context consisting of a long character string immediately before to a low-order context consisting of a short character string by conditional easiness of output. A frequency data storage unit in which the conditional ease of input characters connected is registered for each of the orders, and the conditional ease of input characters connected to the immediately preceding character string in each order is referred to by referring to the frequency data storage unit. A plurality of appearance frequency model units independently provided for each order, in which a search and a process of registering and updating the frequency data storage unit are performed in parallel for each order, and each order of the plurality of appearance frequency model units. The entropy encoding of the conditional ease of execution is performed in parallel for each order.An entropy encoding unit provided independently for each order, and a code output from the entropy encoding unit for each order. collect A code merging unit for force, said plurality of frequency model provided in parallel for each order
And a plurality of entropy coding units for each order
Pipeline and a pipeline control unit for operating the pipeline control unit, out of the first character of the input string of the plurality in the first cycle to
Conditional output of each order by parallel input to the current frequency model
Are calculated in parallel, and the plurality of occurrence frequencies corresponding to the respective orders are calculated.
Output to each of the degree model parts , and for the second and subsequent cycles, each order obtained in the first cycle
The plurality of entropy codes corresponding to conditional ease of
Input to encoding unit to encode from higher-order context to each code in lower-order context
At the same time, the next character of the input character string is
Input to multiple appearance frequency model sections to calculate the appearance frequency of each character
The plurality of appearance frequency models corresponding to each order are obtained in parallel.
A data compression device for repeating a process of outputting to each of the Dell units.
【請求項6】請求項5記載のデータ圧縮装置に於いて、
前記パイプライン制御部は、前記複数の出現頻度モデル
部の各々で各次数の条件付出易さが求められた場合、最
も順位の高い次数の出現頻度モデル部で求めた条件付出
易さの出力を許容し、それ以外の次数の低い出現頻度モ
デル部で求めた条件付き出易さの出力を禁止することを
特徴とするデータ圧縮装置。
6. A data compression apparatus according to claim 5, wherein:
The pipeline control unit includes the plurality of appearance frequency models.
If the conditional accessibility of each order is required for each of the
Conditional output determined by the appearance frequency model part of the higher-order order
Easiness output, and other low-order occurrence frequency models
To prohibit the output of conditional ease that was requested by Dell
Characteristic data compression device.
【請求項7】入力された符号と既に復元されている直前
の長い文字列でなる高次文脈から短い文字列でなる低次
文脈の順に文字を復元するデータ復元装置に於いて、 入力された符号を各次数の符号に分離する符号分離部
と、 前記分離部で分離された各次数の符号と既に復元されて
いる各次数の直前の文字列に基づき各次数の条件付出易
さを求める処理を、各次数毎に並列的に行う各次数毎に
独立に設けられたエントロピー復号化部と、 直前の文字列に繋がる入力文字の条件付出易さを前記各
次数毎に登録した頻度データ格納部を有し、前記複数の
エントロピー復号化部で求めた各次数の条件付出易さに
より前記頻度データ格納部を検索して文字を復元すると
共に前記頻度データ格納部を登録更新する処理を、各次
数毎に行う各次数毎に設けられた複数の出現頻度モデル
部と、各次数毎に並列的に設けられた前記複数のエントロピー
復号化部と前記複数の出現頻度モデル部とを、各次数毎
にパイプライン動作させるパイプライン制御部と、 を備え、前記パイプライン制御部は、 前記パイプライン制御部は、第1サイクル目で前記符号
分離部で分離された入力符号列の先頭符号を構成する各
次数の符号を前記複数の前記エントロピー復号化部に並
列的に入力し条件付出易さを求めて前記複数の出現頻度
モデル部に並列的に出力し、第2サイクル目以降は、前
記第1サイクル目で求めた各次数の条件付き出易さを対
応する前記複数の出現頻度モデル部に入力し特定の出現
頻度モデル部で復元された文字を出力させると同時、前
記符号分離部で分離された入力符号列の次の符号を構成
する各次数の符号を前記複数の前記エントロピー復号化
部に並列的に入力し条件付出易さを求めて前記複数の出
現頻度モデル部に並列的に出力する処理を繰り返す こと
を特徴とするデータ復元装置。
7. A data restoration apparatus for restoring characters in order from a high-order context consisting of a long character string immediately before being restored with an inputted code and a short character string, which has already been restored. A code separation unit that separates a code into codes of each order, and a process of obtaining conditional ease of output of each order based on the code of each order separated by the separation unit and a character string immediately before each order that has been restored. , An entropy decoding unit provided independently for each order that performs each order in parallel, and a frequency data storage unit that registers the conditional ease of input characters connected to the immediately preceding character string for each of the orders A process of retrieving the frequency data storage unit and restoring characters by retrieving the character with the conditional ease of each order obtained by the plurality of entropy decoding units and registering and updating the frequency data storage unit; Provided for each order performed for each A plurality of occurrence frequency modeling unit that, said plurality of entropy provided in parallel for each order
The decoding unit and the plurality of appearance frequency model units are
A pipeline control unit for performing a pipeline operation , wherein the pipeline control unit is configured to perform the pipeline operation in a first cycle.
Each of the constituents of the leading code of the input code string separated by the separation unit
A code of order is sent to the plurality of entropy decoding units.
Entering in a row and finding conditional ease of said multiple occurrence frequencies
Output to the model part in parallel.
The conditional ease of each order determined in the first cycle
Input to the plurality of appearance frequency model parts corresponding to
At the same time as outputting the characters restored by the frequency model part,
Constructs the next code of the input code string separated by the code separation unit
The plurality of codes of each order
Section in parallel to obtain the conditional output
A data restoration apparatus characterized by repeating a process of outputting to a current frequency model part in parallel .
【請求項8】請求項7記載のデータ復元装置に於いて、
前記パイプライン制御部は、前記符 号分離部で分離され
た1又は複数の次数の符号に対応する1又は複数の前記
エントロピー復号化部で求めた条件付出易さの出力を許
容し、それ以外の前記エントロピー復号化部の出力を禁
止することを特徴とするデータ復元装置。
8. The data restoration device according to claim 7, wherein:
The pipeline control unit, separated by the sign-separating unit
One or more of the above-mentioned one or more
Allow the output of conditional ease determined by the entropy decoding unit.
And other outputs of the entropy decoding unit are prohibited.
A data restoration device characterized by stopping.
【請求項9】請求項1乃至のいずれかに記載のデータ
圧縮装置及びデータ復元装置に於いて、前記出現頻度モ
デル部は、前記条件付出易さを導くための情報として、
順位、出現数、累積出現数、文脈下の総出現数の検索、
登録、更新を行い、前記エントロピー符号化部と前記エ
ントロピー復号化部は算術符号化と算術復号化を行うこ
とを特徴とするデータ圧縮装置及びデータ復元装置。
9. In the data compression apparatus and a data restoration apparatus according to any one of claims 1 to 8, wherein the occurrence frequency modeling unit as information for directing Deeki of the conditional,
Search for rank, number of occurrences, cumulative number of occurrences, total number of occurrences in context,
A data compression device and a data decompression device which perform registration and updating, and wherein the entropy coding unit and the entropy decoding unit perform arithmetic coding and arithmetic decoding.
【請求項10】請求項9に記載のデータ圧縮装置及びデ
ータ復元装置に於いて、 前記パイプライン制御部は、前記出現頻度モデル部にお
ける条件付出易さを導くための順位、出現数、累積出現
数、文脈下の総出現数の読出、加算、書込を、各情報ご
とにパイプライン処理することを特徴とするデータ圧縮
装置およびデータ復元装置。
10. The data compression device and the data decompression device according to claim 9 , wherein the pipeline control unit determines the order of appearance, the number of occurrences, and the cumulative occurrence of the conditional appearance in the appearance frequency model unit. A data compression device and a data decompression device characterized in that reading, addition and writing of the total number of occurrences under a number and a context are pipelined for each information.
【請求項11】請求項10記載のデータ圧縮装置及びデ
ータ復元装置に於いて、 前記パイプライン制御部は、算術符号空間を表す上端と
下端の演算を並列に行うことを特徴とするデータ圧縮装
置及びデータ復元装置。
11. A data compression apparatus according to claim 10 , wherein said pipeline control unit performs an operation of an upper end and an lower end representing an arithmetic code space in parallel. And a data restoration device.
JP10171524A 1998-06-18 1998-06-18 Data compression device and data decompression device Expired - Fee Related JP3108404B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP10171524A JP3108404B2 (en) 1998-06-18 1998-06-18 Data compression device and data decompression device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP10171524A JP3108404B2 (en) 1998-06-18 1998-06-18 Data compression device and data decompression device

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP27919096A Division JP2840589B2 (en) 1996-02-09 1996-10-22 Data compression device and data decompression device

Publications (2)

Publication Number Publication Date
JPH1146145A JPH1146145A (en) 1999-02-16
JP3108404B2 true JP3108404B2 (en) 2000-11-13

Family

ID=15924725

Family Applications (1)

Application Number Title Priority Date Filing Date
JP10171524A Expired - Fee Related JP3108404B2 (en) 1998-06-18 1998-06-18 Data compression device and data decompression device

Country Status (1)

Country Link
JP (1) JP3108404B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2312854A1 (en) 2009-10-15 2011-04-20 Siemens Aktiengesellschaft Method for coding symbols from a digital image sequence
CN112580297B (en) * 2020-12-28 2023-04-18 芯华章科技股份有限公司 Method for encoding and decoding data, electronic equipment and storage medium

Also Published As

Publication number Publication date
JPH1146145A (en) 1999-02-16

Similar Documents

Publication Publication Date Title
JP2840589B2 (en) Data compression device and data decompression device
JP3278297B2 (en) Data compression method, data decompression method, data compression device, and data decompression device
Nelson et al. The data compression book 2nd edition
US5179378A (en) Method and apparatus for the compression and decompression of data using Lempel-Ziv based techniques
JP3258552B2 (en) Data compression device and data decompression device
JP3276860B2 (en) Data compression / decompression method
JPH09162748A (en) Data encoding method, data decoding method, data compressor, data restoring device and data compression/ restoration system
JP3083730B2 (en) System and method for compressing data information
US6801141B2 (en) Method for lossless data compression using greedy sequential context-dependent grammar transform
US6518895B1 (en) Approximate prefix coding for data compression
JPH08167852A (en) Method and device for compressing data
JP3231105B2 (en) Data encoding method and data restoration method
JP3108404B2 (en) Data compression device and data decompression device
JP3127016B2 (en) Data compression and decompression method
Wolff Recoding of natural language for economy of transmission or storage
JP2590287B2 (en) Data compression method and data compression apparatus
JPH06168097A (en) Data encoding system and data decoding system
JPH05241776A (en) Data compression system
JPH1155125A (en) Method for compressing and restoring character data
JPH0527943A (en) Data compressing system
JPH0644038A (en) Data compressing method, data restoring method, and data compressing/restoring method
RU2080738C1 (en) Method for compression of information signals
JP3648944B2 (en) Data encoding method, data encoding device, data decoding method, and data decoding device
JP2002232298A (en) Method and device for compressing and restoring data
JPH04100322A (en) Data compression and decoding system

Legal Events

Date Code Title Description
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20000808

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

Free format text: PAYMENT UNTIL: 20080908

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20080908

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20090908

Year of fee payment: 9

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

Free format text: PAYMENT UNTIL: 20090908

Year of fee payment: 9

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

Free format text: PAYMENT UNTIL: 20100908

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20100908

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20110908

Year of fee payment: 11

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

Free format text: PAYMENT UNTIL: 20120908

Year of fee payment: 12

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

Free format text: PAYMENT UNTIL: 20120908

Year of fee payment: 12

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

Free format text: PAYMENT UNTIL: 20130908

Year of fee payment: 13

LAPS Cancellation because of no payment of annual fees