[go: up one dir, main page]

JP2025024868A - Decoder, Encoder, Decoding Method, and Encoding Method - Google Patents

Decoder, Encoder, Decoding Method, and Encoding Method Download PDF

Info

Publication number
JP2025024868A
JP2025024868A JP2023129213A JP2023129213A JP2025024868A JP 2025024868 A JP2025024868 A JP 2025024868A JP 2023129213 A JP2023129213 A JP 2023129213A JP 2023129213 A JP2023129213 A JP 2023129213A JP 2025024868 A JP2025024868 A JP 2025024868A
Authority
JP
Japan
Prior art keywords
encoding
code
data
cbt
symbol
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2023129213A
Other languages
Japanese (ja)
Inventor
悠貴 小島
Yuki Kojima
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.)
Axell Corp
Original Assignee
Axell Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Axell Corp filed Critical Axell Corp
Priority to JP2023129213A priority Critical patent/JP2025024868A/en
Publication of JP2025024868A publication Critical patent/JP2025024868A/en
Pending legal-status Critical Current

Links

Landscapes

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

Abstract

To improve compression efficiency of data.SOLUTION: An encoder 10 which encodes encoding target data including a plurality of integer values comprises an encoding section 13 which identifies block data, in which a plurality of integer values is arranged side by side, from among the encoding target data and encodes the block data into a coupled code for which a plurality of alpha codes is coupled with a CBT code. The encoding section 13 may also encode a plurality of kinds of block data into coupled codes for which values of a plurality of alpha codes are equal and values of CBT codes are different.SELECTED DRAWING: Figure 1

Description

本発明は、データを圧縮する技術に関する。 The present invention relates to a technology for compressing data.

従来、データの容量を抑えるために圧縮処理が行われている。例えば、幾何分布に従う整数データ列を少ない符号量で符号化する技術としてゴロム符号化(例えば、非特許文献1参照)が知られている。 Conventionally, compression processing has been used to reduce the volume of data. For example, Golomb coding (see, for example, Non-Patent Document 1) is known as a technique for coding integer data strings that follow a geometric distribution with a small amount of code.

また、整数データ列である情報源を符号化するときに、符号化効率を向上するために、情報源を拡大した拡大情報源を符号化する技術が知られている(例えば、非特許文献2参照)。 In addition, when encoding an information source that is an integer data string, a technique is known in which the information source is expanded to encode an expanded information source in order to improve the encoding efficiency (see, for example, Non-Patent Document 2).

S. W. Golomb, “Run-Length Encodings,” IEEE Transactions on Information Theory, vol. IT-12, no. 3, pp. 399-401, July 1966.S. W. Golomb, “Run-Length Encodings,” IEEE Transactions on Information Theory, vol. IT-12, no. 3, pp. 399-401, July 1966. 宮川 洋,“情報理論”,電気通信学会編,コロナ社,1979Hiroshi Miyagawa, "Information Theory", edited by the Institute of Electrical Communication Engineers, Corona Publishing, 1979

シャノンの情報源符号化定理によれば、1シンボルあたりの平均符号長は、情報源のエントロピーまで減らすことができるとされている。このように、エントロピーまで減らした場合には、1シンボルあたりの平均符号長は整数とならない場合が多い。 According to Shannon's source coding theorem, the average code length per symbol can be reduced to the entropy of the source. In this way, when reduced to the entropy, the average code length per symbol is often not an integer.

例えば、1シンボルに対して符号を1つ割り当てるゴロム符号化により符号化を行う場合には、各シンボルに対する符号長を整数以外にすることができないために、平均符号長を可能な限り短くすることができず、情報源のエントロピーに十分近づけられない場合が多い。 For example, when encoding using Golomb coding, which assigns one code to each symbol, the code length for each symbol cannot be set to anything other than an integer, so the average code length cannot be made as short as possible, and it is often impossible to get close enough to the entropy of the information source.

一方、1シンボルあたりの符号量をエントロピーに近づける方法としては、拡大情報源に対するハフマン符号化や、算術符号化を用いる方法が考えられるが、これらの方法では、各シンボルを記述する符号以外の付加情報が多くなり、結果として圧縮効率を向上できないという場合も起こり得る。 On the other hand, methods of bringing the amount of code per symbol closer to the entropy include Huffman coding of the extended information source and arithmetic coding, but these methods involve a lot of additional information other than the codes describing each symbol, and as a result, there are cases where compression efficiency cannot be improved.

本発明は、上記事情に鑑みなされたものであり、その目的は、データの圧縮効率を向上することのできる技術を提供することにある。 The present invention has been made in consideration of the above circumstances, and its purpose is to provide a technology that can improve data compression efficiency.

上記目的を達成するため、一観点に係るエンコーダは、複数の整数値を含む符号化対象データを符号化するエンコーダであって、前記符号化対象データから複数個の整数値が並ぶブロックデータを特定する特定部と、前記ブロックデータを、複数のアルファ符号とCBT符号とを結合した結合符号に符号化する符号化部と、を備える。 To achieve the above object, an encoder according to one aspect is an encoder that encodes encoding target data that includes multiple integer values, and includes an identification unit that identifies block data containing a series of multiple integer values from the encoding target data, and an encoding unit that encodes the block data into a combined code that combines multiple alpha codes and CBT codes.

本発明によれば、データの圧縮効率を向上することができる。 The present invention can improve data compression efficiency.

図1は、一実施形態に係る処理システムの全体構成図である。FIG. 1 is a diagram showing the overall configuration of a processing system according to an embodiment. 図2は、ゴロム符号化の第1の例を説明する図である。FIG. 2 is a diagram illustrating a first example of Golomb coding. 図3は、ゴロム符号化の第2の例を説明する図である。FIG. 3 is a diagram illustrating a second example of Golomb coding. 図4は、一実施形態に係る群の番号を説明する図である。FIG. 4 is a diagram illustrating group numbers according to one embodiment. 図5は、一実施形態に係るg=2の群に属するシンボルを説明する図である。FIG. 5 is a diagram illustrating symbols belonging to a group with g 3 =2 according to one embodiment. 図6は、一実施形態に係る一次元インデックスtを説明する図である。FIG. 6 is a diagram illustrating a one-dimensional index t n according to an embodiment. 図7は、一実施形態に係るm=2の場合におけるg=2の群に属するシンボルを説明する図である。FIG. 7 is a diagram illustrating symbols belonging to a group with g 3 =2 when m 3 =2 according to an embodiment. 図8は、一実施形態に係るa,a,aとtg’との関係図である。FIG. 8 is a diagram showing the relationship between a 0 , a 1 , a 2 and tg′ 3 according to one embodiment. 図9は、一実施形態に係るローカルなインデックスtg’を説明する図である。FIG. 9 is a diagram illustrating a local index tg'2 according to an embodiment. 図10は、一実施形態に係るローカルなインデックスtg’を説明する図である。FIG. 10 is a diagram illustrating a local index tg'1 according to an embodiment. 図11は、一実施形態に係るm=2の場合のインデックスt’を説明する図である。FIG. 11 is a diagram illustrating index t'2 when m2 =2 according to one embodiment. 図12は、一実施形態に係るa,aとt’との関係図である。FIG. 12 is a diagram showing the relationship between a 0 , a 1 and t′ 2 according to one embodiment. 図13は、一実施形態に係るa,aとtとの関係図である。FIG. 13 is a diagram showing the relationship between a 0 , a 1 and t 2 according to one embodiment. 図14は、一実施形態に係るエンコード処理のフローチャートである。FIG. 14 is a flowchart of an encoding process according to an embodiment. 図15は、一実施形態に係るデコード処理のフローチャートである。FIG. 15 is a flowchart of a decoding process according to an embodiment. 図16は、一実施形態に係る符号化による平均符号長を説明する図である。FIG. 16 is a diagram illustrating an average code length by encoding according to an embodiment. 図17は、一実施形態に係るコンピュータ装置の構成図である。FIG. 17 is a diagram illustrating the configuration of a computer device according to an embodiment.

実施形態について、図面を参照して説明する。なお、以下に説明する実施形態は特許請求の範囲に係る発明を限定するものではなく、また実施形態の中で説明されている諸要素及びその組み合わせの全てが発明の解決手段に必須であるとは限らない。 The following embodiments are described with reference to the drawings. Note that the embodiments described below do not limit the invention as claimed, and not all of the elements and combinations thereof described in the embodiments are necessarily essential to the solution of the invention.

まず、一実施形態に係る処理システムについて説明する。 First, we will explain the processing system according to one embodiment.

図1は、一実施形態に係る処理システムの全体構成図である。 Figure 1 is an overall configuration diagram of a processing system according to one embodiment.

処理システム1は、エンコーダ10と、デコーダ30とを備える。エンコーダ10とデコーダ30とは、ネットワーク50を介して接続されている。ネットワーク50は、例えば、Local Area Netowork(LAN)や、Wide Area Network(WAN)等である。 The processing system 1 includes an encoder 10 and a decoder 30. The encoder 10 and the decoder 30 are connected via a network 50. The network 50 is, for example, a Local Area Network (LAN) or a Wide Area Network (WAN).

エンコーダ10は、対象データ入力部11と、予測差分算出部12と、符号化部13と、圧縮データ出力部14と、を有する。ここで、符号化部13は、特定部の一例であり、圧縮データ出力部14は、送信部の一例である。 The encoder 10 includes a target data input unit 11, a prediction difference calculation unit 12, an encoding unit 13, and a compressed data output unit 14. Here, the encoding unit 13 is an example of a determination unit, and the compressed data output unit 14 is an example of a transmission unit.

対象データ入力部11は、圧縮対象のデータ(圧縮対象データ)を入力する。圧縮対象データとしては、例えば、PCM(Pulse Code Modulation)により変換された音声データであってもよい。圧縮対象データは、エンコーダ10内の補助記憶装置106(図17参照)から取得するようにしてもよく、或いは、図示しない録音装置から取得するようにしてもよい。 The target data input unit 11 inputs data to be compressed. The target data may be, for example, audio data converted by PCM (Pulse Code Modulation). The target data may be obtained from the auxiliary storage device 106 (see FIG. 17) in the encoder 10, or may be obtained from a recording device (not shown).

予測差分算出部12は、音声データの各データ要素(所定の時点のデータ)についての予測差分を算出する処理を行う。以下に、予測差分を算出する処理の例について説明する。 The prediction difference calculation unit 12 performs a process of calculating a prediction difference for each data element (data at a specified point in time) of the audio data. An example of the process of calculating the prediction difference is described below.

ここで、音声データのデータ列をx[t]とし、t=0,1,2,・・・,n-1とし、x[t]は、整数であるとする。
x[t]の予測差分x’[t]を、一つ前のデータx[t-1]で予測するとした場合には、予測差分x’[t]は、以下の式(1)に示すように表すことができる。
Here, the data string of the audio data is denoted by x[t], where t=0, 1, 2, . . . , n-1, and x[t] is an integer.
When the prediction difference x′[t] of x[t] is predicted using the previous data x[t−1], the prediction difference x′[t] can be expressed as shown in the following equation (1).

符号化部13は、予測差分算出部12により算出された予測差分x’[t]を、以下の式(2)により、符号化を行う対象とする変換対象データp[t](処理対象データ)に変換する。
p[t]=g(x’[t]) ・・・(2)
ここで、g()は、正負の整数を非負の整数へマッピングする関数であり、式(3)に示すように表すことができる。
The encoding unit 13 converts the prediction difference x′[t] calculated by the prediction difference calculation unit 12 into conversion target data p[t] (data to be processed) to be encoded, using the following equation (2).
p[t]=g(x'[t])...(2)
Here, g( ) is a function that maps positive and negative integers to non-negative integers, and can be expressed as shown in equation (3).

符号化部13は、p[t]の各値をn個単位でブロック化することで、以下の式(4)に示すブロック化時系列p[t]を生成する。
[t]=(p[nt]p[nt+1]・・・p[nt+n-1]) ・・・(4)
The encoding unit 13 generates a blocked time series p n [t] shown in the following equation (4) by blocking each value of p[t] in units of n.
p n [t] = (p[nt]p[nt+1]...p[nt+n-1])...(4)

次に符号化部13は、p[t](符号化対象データ)を対象に以下に示す本実施形態に係る符号化を行う。なお、本実施形態に係る符号化は、後述するようにゴロム符号化に類似する符号化を利用しており、符号化部13は、符号化におけるパラメータmを決定する。パラメータmは、例えば、p[t]の平均値に基づいて推定してもよいし、パラメータmの値を変えて実際に符号化を行って最も符号化効率の良いパラメータを探索してもよい。 Next, the encoding unit 13 performs the encoding according to this embodiment shown below on p n [t] (data to be encoded). Note that the encoding according to this embodiment uses encoding similar to Golomb encoding as described later, and the encoding unit 13 determines a parameter m n in the encoding. The parameter m n may be estimated based on the average value of p [t], for example, or the value of the parameter m n may be changed to actually perform encoding and search for a parameter with the highest encoding efficiency.

次に、本実施形態に係る符号化について説明する。 Next, we will explain the encoding process according to this embodiment.

本実施形態では、例えば、幾何分布に従う定常分布を持つデータを出力する情報源Sから出力されるデータ列を符号化対象とする。ここで、データ列の要素iについての確率質量関数を以下の式(5)に示すように表すことができる。 In this embodiment, the data sequence output from an information source S that outputs data having a stationary distribution that follows a geometric distribution is the target for encoding. Here, the probability mass function for element i of the data sequence can be expressed as shown in the following formula (5).

ここで、θは、P[i]が0以外を出力する確率を意味し、0<θ<1である。 Here, θ means the probability that P[i] outputs something other than 0, and 0<θ<1.

本実施形態では、情報源Sから出力されるデータ列をn個ずつで区切ったブロックを出力するn次の拡大情報源Sを考え、拡大情報源Sから出力されるブロックのそれぞれを符号化対象のシンボルとして扱う。 In this embodiment, an n-th order extended information source S n is considered, which outputs blocks obtained by dividing a data sequence output from an information source S into n blocks, and each block output from the extended information source S n is treated as a symbol to be coded.

例えば、情報源Sから出力されるデータ列が{0,1,0,0,2,3,0,0,1,0,2,1,0,0}である場合には、拡大情報源Sから出力されるシンボルは、{01,00,23,00,10,21,00}となる。 For example, if the data string output from the information source S is {0, 1, 0, 0, 2, 3, 0, 0, 1, 0, 2, 1, 0, 0}, the symbols output from the extended information source S2 will be {01, 00, 23, 00, 10, 21, 00}.

ここで、拡大情報源Sから出力される各シンボルの発生確率(出現確率)を考える。
まず、式(5)によると、情報源Sがシンボル「0」を発生させる確率は、(1-θ)である。また、シンボル「0」に続けてシンボル「0」を発生させる確率は、(1-θ)となる。同様に、シンボル「0」に続けてシンボル「1」を発生させる確率は、(1-θ)θとなる。
したがって、情報源Sがシンボル「i」に続けてシンボル「i」を発生させる発生確率P(i)P(i)は、以下の式(6)に示すように表すことができる。
Here, let us consider the occurrence probability (appearance probability) of each symbol output from the extended information source S2 .
First, according to equation (5), the probability that the information source S generates the symbol "0" is (1-θ). Also, the probability of generating the symbol "0" followed by the symbol "0" is (1-θ) 2. Similarly, the probability of generating the symbol "1" followed by the symbol "0" is (1-θ) 2 θ.
Therefore, the probability P(i 0 )P(i 1 ) that the information source S generates the symbol "i 1 " following the symbol "i 0 " can be expressed as shown in the following equation (6).

発生確率P(i)P(i)は、拡大情報源Sがシンボル「i」を発生させる発生確率P(i)と同じである。
なお、式(6)を一般化すると、n次の拡大情報源Sから出力されるシンボルを発生させる発生確率P(i,i,・・・,in-1)は、以下の式(7)に示すように表すことができる。
The occurrence probability P(i 0 )P(i 1 ) is the same as the occurrence probability P(i 0 i 1 ) that the extended information source S 2 generates the symbol “i 0 i 1 ”.
Furthermore, by generalizing equation (6), the occurrence probability P(i 0 , i 1 , ..., i n-1 ) of generating a symbol output from the n-th order extended information source S n can be expressed as shown in the following equation (7).

例えば、θ=1/2の場合には、ゴロム符号化により情報源Sから出力される各シンボルを最も効率よく符号化するときの各シンボルの符号長は整数となる。この場合、拡大情報源Sから出力されるシンボル「i」に適用すると、シンボルi,iとをそれぞれゴロムパラメータm=1で符号化したものとなり、符号量は変わらず、最も効率よく符号化できる。ここで、ゴロム符号化におけるm=1のゴロム符号は、CBT符号が存在せずにアルファ符号そのものである。すなわち、iに対するアルファ符号と、iに対するアルファ符号とを合わせたものとなる。 For example, when θ=1/2, the code length of each symbol output from the information source S is an integer when the symbol is most efficiently encoded by Golomb encoding. In this case, when applied to the symbol "i 0 i 1 " output from the extended information source S 2 , the symbols i 0 and i 1 are each encoded with the Golomb parameter m=1, and the amount of code remains the same, allowing most efficient encoding. Here, the Golomb code with m=1 in Golomb encoding is the alpha code itself, without the CBT code. That is, it is a combination of the alpha code for i 0 and the alpha code for i 1 .

ところで、ゴロム符号をアルファ符号とCBT符号とを結合した符号化方法とみることができ、アルファ符号部分でθ=1/2に対応する幾何分布を表現し、これをCBT符号によってm倍に引き伸ばすことで実質的なθ設定していると解釈することができる。 By the way, Golomb coding can be seen as a coding method that combines alpha coding and CBT coding, and it can be interpreted that the geometric distribution corresponding to θ = 1/2 is expressed in the alpha coding part, and the effective θ is set by stretching this by m times using the CBT coding.

ここで、ゴロム符号化について図面を用いて説明する。 Here, we explain Golomb coding using diagrams.

図2は、ゴロム符号化の第1の例を説明する図である。図3は、ゴロム符号化の第2の例を説明する図である。図2は、ゴロムパラメータm=1の場合に最適となるゴロム符号化を示し、図3は、ゴロムパラメータm=2の場合に最適となるゴロム符号化を示す、図2及び図3において、矩形は、シンボルを示し、各シンボルを示す矩形内の数字は、シンボルの番号を示している。また、矩形の下には、シンボルを符号化した場合のアルファ符号とCBT符号とを示している。また、矩形間の矢印上の数字(1/2)は、シンボル(シンボル群)間の発生確率の関係を示している。 Figure 2 is a diagram for explaining a first example of Golomb coding. Figure 3 is a diagram for explaining a second example of Golomb coding. Figure 2 shows Golomb coding that is optimal when the Golomb parameter m = 1, and Figure 3 shows Golomb coding that is optimal when the Golomb parameter m = 2. In Figures 2 and 3, rectangles indicate symbols, and the numbers in the rectangles indicating each symbol indicate the symbol number. In addition, below the rectangles, the alpha code and CBT code when the symbol is coded are shown. In addition, the numbers (1/2) on the arrows between the rectangles indicate the relationship of occurrence probability between symbols (symbol groups).

m=1の場合には、図2に示すように、シンボルに対する符号は、アルファ符号のみで、CBT符号は存在せずに、シンボル0は「1」、シンボル1は「01」、シンボル2は「001」、・・・のように符号化される。この場合には、右側のシンボルの発生確率が左側のシンボルに対して1/2であることを示している。 When m=1, as shown in Figure 2, the codes for the symbols are only alpha codes, there are no CBT codes, and symbol 0 is coded as "1", symbol 1 as "01", symbol 2 as "001", and so on. In this case, it indicates that the probability of occurrence of the right-hand symbol is 1/2 compared to the left-hand symbol.

m=2の場合には、図3に示すように、シンボルに対する符号は、1つのアルファ符号とCBT符号とを含む符号であり、シンボル0は「10」、シンボル1は「11」、シンボル2は「010」、・・・のように符号化される。 When m=2, as shown in Figure 3, the code for the symbols is a code that includes one alpha code and a CBT code, and symbol 0 is encoded as "10", symbol 1 is encoded as "11", symbol 2 is encoded as "010", and so on.

m=1の場合には、1シンボル毎に発生確率が1/2になっているので、式(5)に照らすと、θ=1/2に対応し、m=2の場合には、2シンボル毎に発生確率が1/2になっているので、式(5)に照らすと、θ=√(1/2)(本明細書では、この表記は、1/2に√が架かっていることを示す)に対応する。 When m = 1, the occurrence probability is 1/2 for every symbol, which corresponds to θ = 1/2 according to equation (5). When m = 2, the occurrence probability is 1/2 for every two symbols, which corresponds to θ = √(1/2) according to equation (5) (in this specification, this notation indicates that √ is crossed over 1/2).

本実施形態では、ゴロム符号化の方法を発展させて、拡大情報源Sから出力される各シンボルを複数のアルファ符号とCBT符号とを結合した結合符号により符号化させるようにしている。 In this embodiment, the Golomb coding method is developed so that each symbol output from the extended information source S2 is coded by a combined code that combines a plurality of alpha codes and a CBT code.

ここで、上記したように、θ=1/2の場合には、シンボル「i」を効率よく符号化するには、iに対するアルファ符号に続けてiに対するアルファ符号を加えればよい。この符号に対して、CBT符号を結合した、アルファ符号+アルファ符号+CBT符号との結合符号によりシンボルを表現することで、1/2よりも大きいθに適した符号化を実現することができる。 Here, as described above, when θ=1/2, in order to efficiently encode the symbol "i 0 i 1 ", it is sufficient to add the alpha code for i 1 following the alpha code for i 0. By expressing the symbol as a combined code of alpha code + alpha code + CBT code, which is obtained by combining this code with a CBT code, it is possible to realize encoding suitable for θ larger than 1/2.

CBT符号で符号化する入力の種類をmとすると、m=1の場合は、CBT符号が必要なく、θ=1/2となる。m=2の場合は、式(6)のP(i)P(i)の全体が2倍に引き延ばされることを意味するので、P(i)とP(i)とのθが同一である場合のシンボル「i」および「i」それぞれ1つあたりの確率質量関数の確率変数方向の拡大率は√(2)倍となる。よって、この符号化によると、θ=2-1/√(2)の幾何分布に適した符号化を実現できる。したがって、パラメータmで一般化すると、この符号化によると、θ=2-1/mの幾何分布に適した符号化を実現できる。 If the type of input to be coded by the CBT code is m2 , then when m2 =1, the CBT code is not necessary, and θ=1/2. When m2 =2, this means that the entire P( i0 )P( i1 ) in formula (6) is stretched twice, so the expansion rate in the direction of the probability variable of the probability mass function for each of the symbols " i0 " and " i1 " when θ of P( i0 ) and P( i1 ) is the same is √(2) times. Therefore, this coding can realize coding suitable for the geometric distribution of θ=2 -1/√(2) . Therefore, when generalized with the parameter m2 , this coding can realize coding suitable for the geometric distribution of θ=2 -1/m .

[拡大情報源Sからの出力データ(シンボル)の符号化]
以下に、n次のシンボル「i…in-1」を符号化する対象とし、パラメータmが与えられている場合における符号化部13による符号化の手順(ステップE1~E8)について説明する。本実施形態では、符号化部13は、例えば、以下の手順により、n次のシンボルの複数個の整数値の並びの出現確率に基づいて、シンボルに割り当てる複数のアルファ符号の値を決定する。この際、符号化部13は、出現確率が高いシンボルに割り当てられる複数のアルファ符号が短くなる傾向となるように符号化を行う。また、符号化部13は、出現確率が高いシンボルに割り当てられるCBT符号が短くなるように符号化を行ってもよい。
[Encoding of output data (symbols) from extended information source S n ]
The following describes the procedure (steps E1 to E8) of encoding by the encoding unit 13 when the nth order symbol "i 0 i 1 i 2 ...i n-1 " is the target to be encoded and a parameter m n is given. In this embodiment, the encoding unit 13 determines the values of multiple alpha codes to be assigned to symbols based on the occurrence probability of a sequence of multiple integer values of the nth order symbol, for example, by the following procedure. At this time, the encoding unit 13 performs encoding such that the multiple alpha codes assigned to symbols with a high occurrence probability tend to be shorter. The encoding unit 13 may also perform encoding such that the CBT codes assigned to symbols with a high occurrence probability are shorter.

[ステップE1]
符号化部13は、符号化対象のシンボル(この処理の説明において対象シンボルという)におけるi,i,i,…,in-1からシンボルの一次元インデックスtを求める。ここで、一次元インデックスtとは、ブロックデータのシンボルとして取り得る全てのシンボルについて、式(7)で示される確率質量関数によるモデルにより算出される確率が大きいものから順に並べた時の対象シンボルの順番である。
[Step E1]
The encoding unit 13 obtains a one-dimensional index tn of the symbol to be encoded (referred to as the target symbol in the description of this process) from i0 , i1 , i2 , ..., in-1 . Here, the one-dimensional index tn is the order of the target symbol when all symbols that can be used as symbols of block data are sorted in descending order of probability calculated by a model based on the probability mass function shown in equation (7).

以下、一次元インデックスtを求める方法の一例について説明する。まず、Σk=0 n-1=gとおく。gは、群を意味している。gが等しいシンボルの中で一次元インデックスtの最小値を示すη(g)は、以下の式(8)に示すように表すことができる。式(8)の導出については後述する。 An example of a method for calculating the one-dimensional index t n will be described below. First, let Σ k=0 n-1 i k =g n , where g n denotes a group. η n (g n ), which indicates the minimum value of the one-dimensional index t n among symbols with the same g n , can be expressed as shown in the following formula (8). The derivation of formula (8) will be described later.

ここで、Πは、総乗の記号である。 Here, Π is the symbol for multiplication.

η(g)は、例えば、n=1~4の場合には、以下の式(9)~(12)に示すように式展開することができる。 For example, when n=1 to 4, η n (g n ) can be expanded as shown in the following equations (9) to (12).

ここで、gが等しいシンボルのことをgに属するシンボルということとする。式(7)によると、同じgに属するシンボルは、同確率で出現する。したがって、gの中で何番目のシンボルであるかという情報を任意の方法で決めても、一次元インデックスtが大きくなるほど出現確率が減少していくことを満たす。但し、デコードが行えることを担保するために、エンコーダ及びデコーダとで一意に特定できるようにする必要がある。
例えば、gの中の何番目のシンボルであるかについては、i,i,i,…,in-2から識別してもよく、次数が1つ減っているので、gn-1に対するインデックスtn-1をそのまま利用することができる。
Here, symbols with the same g n are referred to as symbols belonging to g n . According to formula (7), symbols belonging to the same g n appear with the same probability. Therefore, even if the information on the number of a symbol in g n is determined by any method, the probability of appearance decreases as the one-dimensional index t n increases. However, in order to ensure that decoding can be performed, it is necessary to make it possible to uniquely identify the symbol between the encoder and the decoder.
For example, the ordinal number of a symbol in g n can be identified from i 0 , i 1 , i 2 , ..., i n-2 , and since the degree is reduced by one, the index t n-1 for g n-1 can be used as is.

具体的な例を挙げると、拡大情報源Sでの「i,i,i」に対するgは、図4(C)において矩形内に記載した数値となる。ここで、g=2のシンボルのみに着目すると、図5に示すようになる。図5を参照すると、各シンボルについて、i,i,iのいずれか1つがかけてもシンボルを識別可能であることがわかる。そのため、i,iを使ってシンボルを識別することができる。さらに、i,iを一次元インデックスにする方法は、一次元インデックスtを計算し、同様な計算を繰り返すことであり、一つ下の次元の一次元インデックスを計算することを繰り返すようにすれば、各シンボルの一次元インデックスを計算することができる。
このようにしてインデックスtを決める場合には、一次元インデックスtは、式(13)に示すように、式(8)のη(g)と、gn-1に対するインデックスtn-1との和で表すことができる。
As a specific example, g3 for " i0 , i1 , i2 " in the extended information source S3 is the numerical value written in the rectangle in FIG. 4(C). Here, if we focus only on the symbol with g3 =2, it will be as shown in FIG. 5. Referring to FIG. 5, it can be seen that for each symbol, even if any one of i0 , i1 , and i2 is missing, the symbol can be identified. Therefore, the symbol can be identified using i0 and i1 . Furthermore, a method of making i0 and i1 into a one-dimensional index is to calculate a one-dimensional index t2 and repeat the same calculation, and by repeatedly calculating the one-dimensional index of the dimension one level lower, the one-dimensional index of each symbol can be calculated.
When the index t n is determined in this manner, the one-dimensional index t n can be expressed as the sum of η n (g n ) in equation (8) and the index t n-1 for g n-1 , as shown in equation (13).

ここで、t=0である。
式(13)によると、n=1,2,3である場合には、以下の式(14)~(16)に示すように表される。つまり、式(13)は、以下の式(17)に示すように表すことができる。
Here, t 0 =0.
According to formula (13), when n = 1, 2, or 3, it can be expressed as shown in the following formulas (14) to (16). In other words, formula (13) can be expressed as shown in the following formula (17).

情報源S,S,Sのぞれぞれの場合において式(17)によって算出される一次元インデックスt,t,tの値は、図6に示すように表すことができる。例えば、拡大情報源Sの場合には、式(6)によると、i+iにより出現確率が決まり、i+i1が大きくなるほど出現確率は低くなる。したがって、i,iによる2変数平面を考えた場合には、原点からのマンハッタン距離が大きくなるほど出現確率が単調減少していく。したがって、出現確率の順にインデックスを決めるようにすると、一次元インデックスtは、図6(B)に示すようになる。 The values of the one-dimensional indexes t1 , t2, and t3 calculated by formula (17) for each of the information sources S1 , S2 , and S3 can be expressed as shown in FIG. 6. For example, in the case of the expanded information source S2 , according to formula (6), the occurrence probability is determined by i0 + i1 , and the larger i0 +i1 is, the lower the occurrence probability is. Therefore, when considering a two-variable plane of i0 and i1 , the larger the Manhattan distance from the origin is, the more the occurrence probability monotonically decreases. Therefore, if the indexes are determined in order of occurrence probability, the one-dimensional index t2 will be as shown in FIG. 6(B).

[ステップE2]
符号化部13は、n個のアルファ符号で符号化する場合のインデックスt’を求める。なお、n個のアルファ符号で符号化する場合には、θ=1/2である場合に各シンボルを符号化する場合に相当する。ここで、インデックスt’は、インデックスtを以下の式(18)に示すように、量子化した値である。
[Step E2]
The encoding unit 13 obtains index t'n when encoding with n alpha codes. Note that encoding with n alpha codes corresponds to encoding each symbol when θ=1/2. Here, index t'n is a quantized value of index tn as shown in the following equation (18).

[ステップE3]
符号化部13は、インデックスt’の群のインデックスg’を求める。
具体的には、まず、式(8)で群に属する最小のインデックスtを求めた場合と逆の計算を行う。つまり、n=2の時は、以下の式(19)において、n=3の時は、以下の式(20)において、n=4の時は、以下の式(21)において、g^’について解いて、零又は正の数となる解を選ぶ。nが2,3,4以外の場合でも同様である。
[Step E3]
The encoding unit 13 obtains an index g'n of the group of indexes t'n .
Specifically, first, the calculation is performed inversely to that for finding the smallest index tn belonging to the group in equation (8). That is, when n=2, solve g^'n in the following equation (19), when n=3, in the following equation (20), and when n=4, in the following equation ( 21 ), and select a solution that is zero or a positive number. The same applies when n is other than 2, 3, or 4.

ここで、g’は、g^’に属するインデックスt’の最小値であり、整数値になることから、g^’から小数部分を切り捨てることによりg’を算出できる。 Here, g'n is the minimum value of index t'n belonging to g^' n , and is an integer value, so g'n can be calculated by truncating the decimal portion from g^' n .

例えば、g’は、n=2の場合には、式(19)に基づく以下の式(22)により算出でき、n=3の場合には、式(20)に基づく以下の式(23)により算出でき、n=4の場合には、式(21)に基づく以下の式(24)により算出できる。 For example, when n=2, g′ n can be calculated by the following formula (22) based on formula (19), when n=3, g′ n can be calculated by the following formula (23) based on formula (20), and when n=4, g′ n can be calculated by the following formula (24) based on formula (21).

なお、g’を上記外の方法により算出してもよく、例えば、高次の代数方程式の解を求めることのできる数値計算方法により算出してもよく、インデックスt’を数え上げることにより対応するg’を求めてもよく、t’とg’との対応関係のテーブルを予め用意し、テーブルに基づいて求めるようにしてもよい。 Note that g'n may be calculated by a method other than the above. For example, it may be calculated by a numerical calculation method capable of finding a solution to a high-order algebraic equation, or the corresponding g'n may be found by counting up the index t'n , or a table of the correspondence between t'n and g'n may be prepared in advance and found based on the table.

[ステップE4]
符号化部13は、インデックスtがg’の群の中で何番目のシンボルであるかを示す序列番号tを求める。
[Step E4]
The encoding unit 13 obtains a sequence number tg which indicates the ordinal number of the symbol that the index tn is in the group g'n .

例えば、g’の群の最小のインデックスを式(8)と同様な計算により求め、最小のインデックスをm倍することでtと同じスケールの値に復元し、この値をインデックスtから引くことにより算出する。具体的には、以下の式(25)により算出する。 For example, the minimum index of the group of g'n is found by a calculation similar to that of equation (8), and the minimum index is multiplied by mn to restore it to a value of the same scale as tn , and this value is subtracted from the index tn . Specifically, the calculation is performed by the following equation (25).

=t-η(g’)m ・・・(25) t g =t nn (g' n )m n ...(25)

[ステップE5]
符号化部13は、g’の群の中でのCBT符号の種別番号sを以下の式(26)により計算する。
[Step E5]
The encoding unit 13 calculates the type number s of the CBT code in the group g'n by the following equation (26).

ここで、g’の群の中には、1つ小さいnの最小インデックス番号を利用した(ηn-1(g’+1))m個のシンボルが含まれているので、0≦s<mとなる。図7は、m=2の場合におけるg’=2の群に属するシンボルを示す図である。図7に示すように、(ηn-1(g’+1))m=(η3-1(2+1))2=12個のシンボル(図中で〇で示す)が含まれていることがわかる。 Here, the group g'n contains (η n-1 (g' n +1))m n symbols using the minimum index number of the next smaller n, so 0≦s<m n . FIG. 7 is a diagram showing symbols belonging to the group g' 3 =2 when m 3 =2. As shown in FIG. 7, it can be seen that (η n-1 (g' n +1))m n = (η 3-1 (2+1))2 = 12 symbols (indicated by circles in the diagram) are contained.

[ステップE6]
符号化部13は、g’の群の中でのインデックスtg’nを以下の式(27)により算出する。
[Step E6]
The encoding unit 13 calculates an index t g'n within the group of g'n by the following equation (27).

g‘n=t mod (ηn-1(g’+1)) ・・・(27)
ここで、modは剰余演算を示し、インデックスtg’nは、0≦tg’n<(ηn-1(g’+1))となる。
t g'n =t g mod (η n-1 (g' n +1)) ... (27)
Here, mod indicates a modulus operation, and the index t g'n satisfies 0≦t g'n <(η n-1 (g' n +1)).

[ステップE7]
符号化部13は、インデックスtg’nからアルファ符号に変換する際の入力となるa,a,・・・・,an-1を決定する。
本実施形態では、g’群の中でのシンボルの確率はすべて等しいものとしているので、a,a,・・・・,an-1は、Σk=0 n-1=g’を満たし、且つ群の中のシンボルを一意に識別できるものであればよい。例えば、シンボルをtg’n=Σk=1 η(g’)に従った順番で並べるときのa,a,・・・・,an-1を決定する方法を以下に示す。
まず、インデックスtg’nが含まれる群g’kの中でのローカルなインデックスtg’n-1を以下の式(28)により算出する。
[Step E7]
The encoding unit 13 determines a 0 , a 1 , . . . , a n-1 , which are inputs when converting the index t g'n into an alpha code.
In this embodiment, since all symbols in the g'n group have the same probability, a0 , a1 , ..., an -1 only need to satisfy Σk =0n -1a k = g'n and be able to uniquely identify the symbols in the group. For example, the method of determining a0 , a1 , ..., an-1 when the symbols are arranged in the order according to tg'n = Σk = 1nηk ( g'k ) is shown below.
First, a local index tg' n-1 in the group g'k containing the index t g'n is calculated by the following formula (28).

tg’n-1=tg’-η(g’) ・・・(28) tg' n-1 = tg' nn (g' k )...(28)

次いで、インデックスtg’n-1が含まれる群g’n-1をステップE3と同様な方法により算出する。つまり、以下の式(29)を解くことによって、g^’n-1を求め、小数部分を切り捨ててg’n―1を算出する。ここでは、式(29)を解いて得られた解のうち零または正の数となるものをg’n―1として選ぶこととなる。 Next, the group g' n-1 containing the index t g' n- 1 is calculated in the same manner as in step E3. That is, g^' n-1 is found by solving the following equation (29), and g' n-1 is calculated by truncating the decimal part. Here, from among the solutions obtained by solving equation (29), a solution that is zero or a positive number is selected as g' n-1 .

次いで、an-1を以下の式(30)により算出する。 Next, a n-1 is calculated by the following formula (30).

n-1=g’-g’n-1 ・・・(30) a n-1 = g' n - g' n-1 ...(30)

n-1は、最大値であるg’からローカルな群g’n-1の数だけずれているとして特定できる。 a n-1 can be identified as being offset from the maximum value g' n by the number of local groups g' n-1 .

同様な処理を繰り返し行うことにより、an-2,・・・aを特定し、aについては、以下の式(31)に示すものとする。 By repeating the same process, a n-2 , . . . a 1 are specified, and a 0 is set as shown in the following formula (31).

=g’=tg’1 ・・・(31) a 0 = g' 1 = t g'1 ...(31)

これにより、a,a,・・・・,an-1のすべてを決定することができる。 This makes it possible to determine all of a 0 , a 1 , . . . , a n-1 .

ここで、Sのシンボルを符号化する場合として、群g’=3であり、インデックスtg’3=18である場合において、a,a,aを決定する例について説明する。 Here, an example of determining a 0 , a 1 , and a 2 when encoding the symbol of S 3 and the group g′ 3 =3 and the index t g′3 =18 will be described.

群g’=3である場合には、a,a,aとtg’3との関係は、図8に示す関係となる。この図からは、インデックスtg’3=18は、(a,a,a)=(2,1,0)とわかる。図8に示す関係図は、例えば、インデックスtg’nを順に並べながら数え上げていくことで作成することができるので、nやtg’nが小さい場合には、図8に示すような関係図を作成し、この図に基づいて(a,a,a)を決定してもよい。
以下には、関係図からではなく計算により、(a,a,a)を決定する例を説明する。
When group g'3 = 3, the relationship between a0 , a1 , a2 and tg'3 is as shown in Fig. 8. From this diagram, it can be seen that index tg'3 = 18 is ( a0 , a1 , a2 ) = (2, 1, 0). The relationship diagram shown in Fig. 8 can be created, for example, by arranging index tg'n in order and counting up, so when n or tg'n is small, a relationship diagram like that shown in Fig. 8 can be created and ( a0 , a1 , a2 ) can be determined based on this diagram.
An example in which (a 0 , a 1 , a 2 ) is determined by calculation rather than from a relationship diagram will be described below.

群g’の中に含まれるインデックスtg’3は、図9に示すように、10,11,12,・・・,19であり、ローカルなインデックスtg’2は、式(28)により、以下の式(32)に示すように「8」と算出でき、図9に示すように表すことができる。 The index t g'3 included in the group g'3 is 10, 11, 12, ..., 19 as shown in Figure 9, and the local index t g'2 can be calculated as "8" as shown in the following equation (32) using equation (28), and can be expressed as shown in Figure 9.

次に、インデックスtg’2が8であるシンボルが含まれる群g’は、式(22)により、以下の式(33)に示すように「3」と算出される。 Next, the group g'2 including the symbol with index t g'2 being 8 is calculated as "3" according to equation (22), as shown in the following equation (33).

この結果、式(30)により、aは、以下の式(34)に示すように算出できる。 As a result, a2 can be calculated from equation (30) as shown in the following equation (34).

=g’-g’=0 ・・・(34) a 2 = g' 3 - g' 2 = 0 (34)

次に、群g’=3の中に含まれるインデックスtg’2は、図10に示すように、6,7,8,9であり、ローカルなインデックスtg’2は、式(28)により、以下の式(35)に示すように「2」と算出でき、図10に示すように表すことができる。 Next, the indexes t g'2 included in the group g' 2 =3 are 6, 7, 8, and 9 as shown in FIG. 10, and the local index t g'2 can be calculated as "2" according to equation (28) as shown in equation (35) below, and can be expressed as shown in FIG. 10.

次に、インデックスtg’1が2であるシンボルが含まれる群g’は、以下の式(36)に示すように算出される。 Next, the group g′ 1 including the symbol with index t g′ 1 being 2 is calculated as shown in the following equation (36).

g’=tg’=2 ・・・(36) g' 1 = tg' 1 = 2 (36)

この結果、式(30)により、aは、以下の式(37)に示すように算出できる。 As a result, a1 can be calculated from equation (30) as shown in the following equation (37).

=g’-g’=1 ・・・(37) a 1 = g' 2 - g' 1 = 1 (37)

最後に、aは、式(31)により、以下の式(38)に示すように算出できる。 Finally, a 0 can be calculated from equation (31) as shown in the following equation (38).

=g’=2 ・・・(38) a 0 = g' 1 = 2 (38)

これにより、(a,a,a)=(2,1,0)との結果が得られる。 This results in (a 0 , a 1 , a 2 )=(2, 1, 0).

[ステップE8]
符号化部13は、ステップE7で得られた、a,a,・・・・,an-1のそれぞれを順にアルファ符号に符号化することにより、n個のアルファ符号として、さらに、種別番号sに対してmシンボル向けのCBT符号化を行ってCBT符号を算出し、n個のアルファ符号とCBT符号とを結合した結合符号を作成する。これにより、拡大情報源Sからの出力とされるn次のブロックの1つを結合符号に符号化することができる。
[Step E8]
The encoding unit 13 sequentially encodes each of a 0 , a 1 , ..., a n-1 obtained in step E7 into an alpha code to obtain n alpha codes, and then performs CBT encoding for m n symbols on the type number s to calculate a CBT code, and creates a combined code by combining the n alpha codes and the CBT code. This makes it possible to encode one of the n-th order blocks output from the extended information source S n into a combined code.

これにより、n次のシンボルに割り当てられる複数のアルファ符号を短くなるように符号化を行うことができ、出現確率が高いシンボルに割り当てられるCBT符号を短くなるようにすることができる。 This allows multiple alpha codes assigned to n-th order symbols to be coded so that they are shorter, and allows the CBT codes assigned to symbols with a high probability of occurrence to be shorter.

[式(8)の導出]
ここで、式(8)の導出について説明する。
[Derivation of Equation (8)]
Here, the derivation of equation (8) will be explained.

n=1の場合には、図4のSに示すように、gに属するシンボルの数は、常に1であるので、群における一次元インデックスtの最小値η(g)は、以下の式(39)に示すように表すことができる。 When n=1, the number of symbols belonging to g1 is always 1, as shown by S1 in Figure 4, so the minimum value η1 ( g1 ) of the one-dimensional index t1 in the group can be expressed as shown in the following equation (39).

また、n=2の場合は、図4のSに示すように、各群の数は、0,1,2,・・・と変化する数の総和を取ることとなるので、群における一次元インデックスtの最小値η(g)は、以下の式(40)に示すように表すことができる。 Furthermore, when n = 2, as shown in S2 in Figure 4, the number of each group is the sum of numbers that change from 0, 1, 2, ..., so the minimum value η2 ( g2 ) of the one-dimensional index t2 in the group can be expressed as shown in the following equation (40).

また、n=3の場合は、図4のSに示すように、各群の数は、0,3,6,10,・・・と変化する数の総和をとることとなるので、Sにおけるgについての総和を取ることを意味するので、群における一次元インデックスtの最小値η(g)は、以下の式(41)に示すように表すことができる。 Furthermore, when n=3, as shown in S3 in FIG. 4, the numbers in each group are the sum of the numbers that change as 0, 3, 6, 10, ..., which means taking the sum for g2 in S2. Therefore, the minimum value η3 ( g3 ) of the one-dimensional index t3 in the group can be expressed as shown in the following equation (41).

このように、nについての群における一次元インデックスtの最小値η(g)は、1つ次数の低い場合における各群の数から再帰的に求まることとなり、式(8)が導かれることがわかる。 In this way, the minimum value η n (g n ) of the one-dimensional index t n in the group for n is recursively found from the number of each group in the case of the next lower degree, leading to equation (8).

[拡大情報源Sからの出力データの符号化]
上記した例では、拡大情報源Sについての符号化を説明したが、理解を容易にするために拡大情報源Sについての符号化について説明する。具体的には、2次のシンボル「i」を符号化する対象とし、パラメータmが与えられている場合における符号化部13による符号化の手順(ステップE1~E8)について説明する。
[Encoding of output data from the augmented information source S2 ]
In the above example, the encoding of the extended information source S n has been described, but to facilitate understanding, the encoding of the extended information source S 2 will be described. Specifically, the encoding procedure (steps E1 to E8) by the encoding unit 13 will be described when the secondary symbol "i 0 i 1 " is to be encoded and a parameter m 2 is given.

[ステップE1]
符号化部13は、符号化対象のシンボル(この処理の説明において対象シンボルという)におけるi,iからシンボルの一次元インデックスtを求める。
[Step E1]
The encoding unit 13 obtains a one-dimensional index t2 of the symbol to be encoded (referred to as a target symbol in the explanation of this process) from i0 , i1 .

まず、i+i=gとおく。gは、群を意味している。gに属するシンボルの中の一次元インデックスtの最小値を示すη(g)は、上述した式(10)に示すように表すことができる。また、群gの中でシンボルの順番を考慮すると、以下の式(42)に示すように表すことができる。 First, let i0 + i1 = g2 . g2 denotes a group. η2 (g2), which indicates the minimum value of the one-dimensional index t2 among the symbols belonging to g2 , can be expressed as shown in the above formula ( 10 ). In addition, taking into account the order of the symbols in the group g2 , it can be expressed as shown in the following formula (42).

[ステップE2]
符号化部13は、2個のアルファ符号で符号化する場合のインデックスt’を求める。なお、2個のアルファ符号で符号化する場合には、θ=1/2である場合に各シンボルを符号化する場合に相当する。ここで、インデックスt’は、インデックスtを以下の式(43)に示すように、量子化した値である。
[Step E2]
The encoding unit 13 obtains index t'2 when encoding with two alpha codes. Note that encoding with two alpha codes corresponds to encoding each symbol when θ=1/2. Here, index t'2 is a quantized value of index t2 as shown in the following equation (43).

例えば、インデックスtが図6に示す場合には、m=2であれば、インデックスt’は、図11に示すようになる。 For example, when index t 2 is as shown in FIG. 6, if m 2 =2, index t′ 2 becomes as shown in FIG.

[ステップE3]
符号化部13は、インデックスt’の群g’を求める。
具体的には、まず、式(10)で群に属する最小のインデックスtを求めた場合と逆の計算を行う。つまり、式(19)において、g^’について解いて、g^’≧0となる解を選ぶ。ここで、g’は、g^’に属するインデックスt’の最小値で整数値になることからg^’から小数部分を切り捨てることによりg’を算出できる。
[Step E3]
The encoding unit 13 obtains a group g'2 of the index t'2 .
Specifically, first, the calculation is performed inversely to that for finding the minimum index t2 belonging to the group in equation (10). That is, in equation (19), g^' 2 is solved and a solution that satisfies g^' 2 ≧0 is selected. Here, g'2 is the minimum value of index t'2 belonging to g^' 2 and is an integer value, so g'2 can be calculated by truncating the decimal portion from g^ ' 2 .

したがって、g’は、式(22)により算出できる。 Therefore, g'2 can be calculated by equation (22).

[ステップE4]
符号化部13は、インデックスtがg’の群の中で何番目のシンボルであるかを示す序列番号tを求める。
[Step E4]
The encoding unit 13 obtains a sequence number tg which indicates the ordinal number of the symbol that the index t2 is in the group g'n .

例えば、g’の群の最小のインデックスを式(10)と同様な計算により求め、最小のインデックスをm倍することでtと同じスケールの値に復元し、この値をインデックスtから引くことにより算出する。具体的には、以下の式(44)により算出する。 For example, the minimum index of the group of g'n is found by a calculation similar to that of equation (10), and the minimum index is multiplied by m2 to restore it to a value of the same scale as t2 , and this value is subtracted from index t2 . Specifically, the calculation is performed by the following equation (44).

[ステップE5]
符号化部13は、g’の群の中でのCBT符号の種別番号sを以下の式(45)により計算する。
[Step E5]
The encoding unit 13 calculates the type number s of the CBT code in the group g′2 by the following equation (45).

ここで、g’の群の中には、(g+1)m個のシンボルが含まれているので、0≦s<mとなる。 Here, the group g'2 contains ( g2 +1) m2 symbols, so that 0≦s< m2 .

[ステップE6]
符号化部13は、g’の群の中でのインデックスtg’2を以下の式(46)により算出する。
[Step E6]
The encoding unit 13 calculates an index t g'2 within the group of g'2 by the following equation (46).

g’2=t mod (g’+1) ・・・(46)
ここで、modは剰余演算を示し、インデックスtg’2は、0≦tg’2<(g’+1)となる。
t g'2 = t g mod (g' 2 +1) ... (46)
Here, mod indicates a modulus operation, and the index t g'2 satisfies 0≦t g'2 <(g' 2 +1).

[ステップE7]
符号化部13は、インデックスtg’2からアルファ符号に変換する際の入力となるa,aを決定する。
本実施形態では、g’群の中でのシンボルの確率はすべて等しいものとしているので、a+a=g’を満たし、且つ群の中のシンボルを一意に識別できるものであればよい。例えば、a,aは、以下の式(47)、(48)により決定してもよい。
[Step E7]
The encoding unit 13 determines a 0 and a 1 which are inputs when converting the index t g′2 into an alpha code.
In this embodiment, since the probabilities of all symbols in group g'2 are equal, it is sufficient that a0 + a1 = g'2 is satisfied and the symbols in the group can be uniquely identified. For example, a0 and a1 may be determined by the following equations (47) and (48).

=tg’1 ・・・(47)
=g’-tg’1 ・・・(48)
a 0 =t g'1 ...(47)
a 1 = g' 2 -t g'1 ...(48)

[ステップE8]
符号化部13は、ステップE7で得られた、a,aを順にアルファ符号に符号化することにより、2個のアルファ符号として、さらに、種別番号sに対してmシンボル向けのCBT符号化を行ってCBT符号を算出し、2個のアルファ符号とCBT符号とを結合した結合符号を作成する。これにより、拡大情報源Sからの出力とされる2次のブロックの1つを結合符号に符号化することができる。
[Step E8]
The encoding unit 13 sequentially encodes a0 and a1 obtained in step E7 into alpha codes to obtain two alpha codes, and then performs CBT encoding for m2 symbols on the type number s to calculate a CBT code, and creates a combined code by combining the two alpha codes and the CBT code. This makes it possible to encode one of the secondary blocks output from the extended information source S2 into a combined code.

上記した符号化処理によると、図6に示すようなインデックスtで表されるシンボルに対しては、図13に示すような、(a,a)に決定される。ここで、同じ(a,a1,・・・)に決定される複数種類のシンボルについては、長さの違うCBT符号に符号化される場合(例えば、mが2冪の数以外の場合)がある。例えば、m=3の場合には、バイナリ形式で、0,10,11のようにCBT符号の長さが異なる。本実施形態では、図13に示すように、インデックスtに対して(a,a,・・・)を決定しているので、例えば、同じ群に属するシンボルについては、複数のアルファ符号の長さを同じにすることができ、その中でインデックスの小さい(出現確率が同じか、又は高い)シンボルについて、できるだけ短いCBT符号に符号化されるようにすることができる。このため、インデックスの小さいシンボルをより短い結合符号になるようにすることができ、圧縮効率を向上することができる。 According to the above-mentioned encoding process, for a symbol represented by index t2 as shown in FIG. 6, ( a0 , a1 ) as shown in FIG. 13 is determined. Here, for a plurality of types of symbols determined to be the same ( a0 , a1 , ... ), they may be encoded into CBT codes of different lengths (for example, when m2 is not a power of 2). For example, when m2 = 3, the lengths of the CBT codes are different in binary format, such as 0, 10, and 11. In this embodiment, since ( a0 , a1 , ...) is determined for index tn as shown in FIG. 13, for example, for symbols belonging to the same group, the lengths of a plurality of alpha codes can be made the same, and among them, symbols with small indices (with the same or high occurrence probability) can be encoded into the shortest possible CBT code. Therefore, symbols with small indices can be made into shorter combined codes, and compression efficiency can be improved.

[拡大情報源Sからの出力データの符号化:CBT符号の符号長を考慮しない場合]
上記した例では、同じ群に属するシンボルについては、インデックスの小さい(出現確率が同じか、又は高い)シンボルについて、より短いCBT符号に符号化できるように処理を行っていたが、同一の群に属するシンボルについては、CBT符号についての長さを考慮しないようにしてもよい。この場合でも、複数のアルファ符号の長さについては、出現確率が高いシンボルほど短くすることができ、圧縮効率を向上することができる。
[Encoding of output data from extended information source S2 : When the code length of the CBT code is not taken into consideration]
In the above example, for symbols belonging to the same group, processing was performed so that symbols with smaller indexes (with the same or higher occurrence probability) could be encoded into shorter CBT codes, but for symbols belonging to the same group, the length of the CBT code may not be taken into consideration. Even in this case, the length of the multiple alpha codes can be made shorter for symbols with higher occurrence probability, improving compression efficiency.

以下に、CBT符号の符号長を考慮しない場合における拡大情報源Sについての符号化について説明する。具体的には、2次のシンボル「i」を符号化する対象とし、パラメータmが与えられている場合における符号化部13による符号化の手順(ステップE1’~E6’)について説明する。 The following describes the coding of the extended information source S2 when the code length of the CBT code is not taken into consideration. Specifically, the coding procedure (steps E1' to E6 ' ) by the coding unit 13 when the second-order symbol " i0i1 " is to be coded and the parameter m2 is given will be described.

[ステップE1’]
符号化部13は、ステップE1と同様な処理を実行する。
[ステップE2’]
符号化部13は、ステップE2と同様な処理を実行する。
[ステップE3’]
符号化部13は、ステップE3と同様な処理を実行する。
[Step E1′]
The encoding unit 13 executes the same process as in step E1.
[Step E2′]
The encoding unit 13 executes the same process as in step E2.
[Step E3′]
The encoding unit 13 executes the same process as in step E3.

[ステップE4’]
符号化部13は、インデックスt’からアルファ符号に変換する際の入力となるa,aを決定する。
本実施形態では、g’群の中でのシンボルの確率はすべて等しいものとしているので、a+a=g’を満たし、且つ群の中のシンボルを一意に識別できるものであればよい。例えば、a,aは、以下の式(49)、(50)により決定してもよい。
[Step E4′]
The encoding unit 13 determines a 0 and a 1 which are inputs when converting the index t' 2 into an alpha code.
In this embodiment, since the probabilities of all symbols in group g'2 are equal, it is sufficient that a0 + a1 = g'2 is satisfied and the symbols in the group can be uniquely identified. For example, a0 and a1 may be determined by the following equations (49) and (50).

=t’ ・・・(49)
=g’-t’ ・・・(50)
a 0 =t' 2 ...(49)
a 1 = g' 2 - t' 2 ...(50)

本例では、式(49)、式(50)によると、インデックスt’に対して、図12に示すようにa,aが決定される。 In this example, according to equations (49) and (50), a 0 and a 1 are determined for index t' 2 as shown in FIG.

[ステップE5’]
符号化部13は、同じ(a,a)に符号化されるシンボルを識別するためのCBT符号の種別番号sm2を計算する。識別番号Sm2は、以下の式(51)により計算する。
[Step E5′]
The encoding unit 13 calculates a CBT code type number s m2 for identifying symbols encoded to the same (a 0 , a 1 ). The identification number S m2 is calculated by the following equation (51).

m2=t mod m ・・・(51) s m2 = t mod m 2 (51)

[ステップE6’]
符号化部13は、ステップE5’で得られた、a,aを順にアルファ符号に符号化することにより、2個のアルファ符号として、さらに、種別番号sm2に対してmシンボル向けのCBT符号化を行ってCBT符号を算出し、2個のアルファ符号とCBT符号とを結合した結合符号を作成する。これにより、拡大情報源Sからの出力とされる2次のブロックの1つを結合符号に符号化することができる。このCBT符号の符号長を考慮しない場合における拡大情報源Sについての符号化によると、CBT符号の符号長を考慮する場合に比して処理を簡略化することができる。
[Step E6′]
The encoding unit 13 sequentially encodes a0 and a1 obtained in step E5' into alpha codes to obtain two alpha codes, and then performs CBT encoding for m2 symbols on the type number sm2 to calculate a CBT code, and creates a combined code by combining the two alpha codes and the CBT code. This makes it possible to encode one of the secondary blocks output from the extended information source S2 into a combined code. This encoding of the extended information source S2 without taking into account the code length of the CBT code can simplify the processing compared to the case where the code length of the CBT code is taken into account.

図1の説明に戻り、圧縮データ出力部14は、各ブロック(シンボル)を符号化した結合符号と、CBT符号の種類数を示すパラメータmと、をまとめたファイル形式の圧縮データ(符号化データ)を作成し、デコーダ30に出力する。ここで、各ブロックの結合符号のヘッダ部分にパラメータmを設定するようにしてもよい。 Returning to the explanation of Fig. 1, the compressed data output unit 14 creates compressed data (encoded data) in a file format that combines the combined code obtained by encoding each block (symbol) and the parameter m n indicating the number of types of CBT codes, and outputs the data to the decoder 30. Here, the parameter m n may be set in the header portion of the combined code of each block.

デコーダ30は、圧縮データ入力部31と、符号復号部32と、対象データ算出部33と、対象データ処理部34と、を有する。ここで、圧縮データ入力部21は、受付部の一例であり、符号復号部32は、復号部の一例である。 The decoder 30 has a compressed data input unit 31, an encoding/decoding unit 32, a target data calculation unit 33, and a target data processing unit 34. Here, the compressed data input unit 21 is an example of a reception unit, and the encoding/decoding unit 32 is an example of a decoding unit.

圧縮データ入力部31は、ネットワーク50を介してエンコーダ10から送信される圧縮データ(処理対象データ)を入力する。 The compressed data input unit 31 inputs compressed data (data to be processed) transmitted from the encoder 10 via the network 50.

符号復号部32は、圧縮データに含まれる各ブロック(シンボル)についての結合符号に対して、このシンボルに対応するパラメータmを用いて、以下に示す本実施形態に係る復号を行う。 The codec 32 performs the decoding according to this embodiment, which will be described below, on the combined code for each block (symbol) included in the compressed data, using parameters m n corresponding to this symbol.

次に、本実施形態に係る復号について説明する。 Next, we will explain the decoding process according to this embodiment.

[n次のシンボルが符号化された結合符号の復号]
以下に、n次のシンボル「i…in-1」が符号化された結合符号を復号対象とし、パラメータmが与えられている場合における符号復号部32による復号の手順(ステップD1~D6)について説明する。
Decoding of a joint code in which n-th symbol is encoded
The following describes the procedure (steps D1 to D6) of decoding by the code-decoding unit 32 when a combined code in which n-th order symbols "i 0 i 1 i 2 ...i n-1 " are encoded is to be decoded and a parameter m n is given.

[ステップD1]
符号復号部32は、n個のアルファ符号と、CBT符号とを含む結合符号を復号して、a,a,・・・・,an-1,sを求める。
[Step D1]
The code decoder 32 decodes the combined code including the n alpha codes and the CBT code to obtain a 0 , a 1 , . . . , a n-1 , and s.

[ステップD2]
符号復号部32は、θ=1/2に相当する群の各ローカル群{g’,g’,・・・,g’}を以下の式(52)により算出する。
[Step D2]
The codec 32 calculates each local group {g' 1 , g' 2 , . . . , g' n } of the group corresponding to θ=½ by using the following equation (52).

{g’,g’,・・・,g’}={a,Σk=0 2-1,・・・,Σk=0 n-1
・・・(52)
{g' 1 , g' 2 ,..., g' n }={a 0 , Σ k=0 2-1 a k ,..., Σ k=0 n-1 a k }
...(52)

[ステップD3]
符号復号部32は、g’の群の中でのθ=1/2に相当するインデックスtg’nを、以下の式(53)により算出する。
[Step D3]
The codec 32 calculates an index t g'n corresponding to θ=1/2 in the group of g'n by the following equation (53).

g’n=Σk=1 η(g’) ・・・(53) t g'nk=1 n η k (g' k )...(53)

[ステップD4]
符号復号部32は、復号対象のシンボルがg’の群の中で何番目のシンボルなのかを示す序列番号tを式(54)により算出する。
[Step D4]
The codec 32 calculates a sequence number tg , which indicates the ordinal number of the symbol to be decoded within the group g'n , using equation (54).

=s(ηn-1(g+1))+tg’n ・・・(54) t g = s (η n-1 (g n +1)) + t g'n ... (54)

[ステップD5]
符号復号部32は、復号対象のシンボルのインデックスtを、式(25)に基づいて算出する。
[Step D5]
The codec 32 calculates the index tn of the symbol to be decoded based on equation (25).

[ステップD6]
符号復号部32は、復号対象のシンボルのインデックスtから、以下の処理により、i,i,i,…,in-1を復元する。
まず、符号復号部32は、式(29)と同じ計算により、すなわち、以下の式(55)を解くことによって、g^を求め、小数部分を切り捨ててgを算出する。
[Step D6]
The codec 32 restores i 0 , i 1 , i 2 , . . . , i n-1 from the index t n of the symbol to be decoded by the following process.
First, the coder/decoder 32 finds g^ n by performing the same calculation as in equation (29), that is, by solving the following equation (55), and calculates g n by truncating the decimal part.

次いで、符号復号部32は、群gの中でローカルなインデックスtn-1を以下の式(56)により算出する。 Next, the codec 32 calculates a local index t n-1 in the group g n by the following equation (56).

n-1=t-η(g) ・・・(56) t n-1 = t nn (g n )...(56)

次いで、符号復号部32は、インデックスtgn-1が属する群gn-1を、式(30)と同様な式(57)により算出する。 Next, the coder/decoder 32 calculates the group g n-1 to which the index t gn-1 belongs, using equation (57), which is similar to equation (30).

n-1=g-gn-1 ・・・(57) i n-1 = g n - g n-1 (57)

次いで、符号復号部32は、式(57)の関係式を繰り返し用いることで、in-2,・・・,iを算出し、iについては、i=g=tとする。これにより、n次のシンボル(i…in-1)を復元することができる。これにより、各シンボル、すなわち、ブロック化時系列p[t]を得ることができる。 Next, the coder/decoder 32 calculates i n-2 , ..., i 1 by repeatedly using the relational expression (57), and for i 0 , it sets i 0 = g 1 = t 1. This makes it possible to restore the n-th order symbols (i 0 i 1 i 2 ...i n-1 ). This makes it possible to obtain each symbol, that is, the blocked time series p n [t].

[2次のシンボルが符号化された結合符号の復号]
以下に、2次のシンボル「i」が符号化された結合符号を復号対象とし、パラメータmが与えられている場合における符号復号部32による復号の手順(ステップD1~D6)について説明する。
Decoding of Secondary Symbol-Encoded Joint Codes
The following describes the procedure (steps D1 to D6) of decoding by the code-decoder 32 when the combined code obtained by encoding the secondary symbol "i 0 i 1 " is to be decoded and the parameter m 2 is given.

[ステップD1]
符号復号部32は、2個のアルファ符号と、CBT符号とを含む結合符号を復号して、a,a,sを求める。
[Step D1]
The code decoder 32 decodes the combined code including the two alpha codes and the CBT code to obtain a 0 , a 1 , and s.

[ステップD2]
符号復号部32は、θ=1/2に相当する群の各ローカル群g’を以下の式(58)により算出する。
[Step D2]
The codec 32 calculates each local group g'2 of the group corresponding to θ=1/2 by the following equation (58).

g’=a+a ・・・(58) g' 2 = a 0 + a 1 ... (58)

[ステップD3]
符号復号部32は、g’の群の中でのθ=1/2に相当するインデックスtg’1をaとする。
[Step D3]
The codec 32 sets the index t g'1 corresponding to θ=1/2 in the group g'2 as a 0 .

[ステップD4]
符号復号部32は、復号対象のシンボルがg’の群の中で何番目のシンボルなのかを示す序列番号tを式(59)により算出する。
[Step D4]
The codec 32 calculates the sequence number tg , which indicates the ordinal number of the symbol to be decoded within the group g'2 , using equation (59).

=s(g+1)+tg’ ・・・(59) t g =s(g n +1)+tg' 1 ...(59)

[ステップD5]
符号復号部32は、復号対象のシンボルのインデックスtを、式(44)に基づいて算出する。
[Step D5]
The codec 32 calculates the index t2 of the symbol to be decoded based on equation (44).

[ステップD6]
符号復号部32は、復号対象のシンボルのインデックスtから、以下の処理により、i,iを復元する。
まず、符号復号部32は、式(22)と同じ計算により、すなわち、以下の式(60)を解くことによって、gを算出する。
[Step D6]
The codec 32 restores i 0 and i 1 from the index t 2 of the symbol to be decoded by the following process.
First, the coder/decoder 32 calculates g2 by the same calculation as in equation (22), that is, by solving the following equation (60).

次いで、符号復号部32は、式(42)の関係を用いて、iを算出する。 Next, the coder/decoder 32 calculates i0 using the relationship in equation (42).

次いで、符号復号部32は、i+i=gの関係からiを算出する。これにより、2次のシンボル(i)を復元することができる。これにより、各シンボル、すなわち、ブロック化時系列p[t]を得ることができる。 Next, the codec 32 calculates i 1 from the relationship i 0 +i 1 =g 2. This makes it possible to restore the second-order symbol (i 0 i 1 ). This makes it possible to obtain each symbol, i.e., the blocked time series p 2 [t].

図1の説明に戻り、対象データ算出部33は、ブロック化時系列p[t]のn次のシンボルの各要素の値を分割した変換対象データp[t]のそれぞれを、以下の式(60)により、式(3)による正負の整数を非負の整数へマッピングする処理の逆マッピング、すなわち、非負の整数をもとの正負の整数に変換する処理を行うことにより、予測差分x’[t]を算出する。
x’[t]=g(p[t]) ・・・(60)
ここで、g()は、非負の整数を正負の整数へ変換する関数であり、式(61)に示すように表すことができる。
Returning to the explanation of Figure 1, the target data calculation unit 33 calculates a prediction difference x ' [t] for each of the conversion target data p[t] obtained by dividing the values of each element of the n-th order symbol of the blocked time series pn[t], by performing an inverse mapping of the process of mapping positive and negative integers to non-negative integers using equation (3) below, i.e., a process of converting the non-negative integers back to the original positive and negative integers, using equation (60) below.
x'[t]=g - (p[t]) ...(60)
Here, g ( ) is a function that converts a non-negative integer into a positive or negative integer, and can be expressed as shown in equation (61).

対象データ算出部33は、予測差分x’[t]に対して式(62)に示す処理を行うことにより、音声データのデータ列x[t]を復元して、元の音声データ(圧縮対象データ)を作成する。 The target data calculation unit 33 performs the process shown in equation (62) on the predicted difference x'[t] to restore the data string x[t] of the audio data and create the original audio data (data to be compressed).

対象データ処理部34は、作成された音声データを処理することにより音声を出力する。 The target data processing unit 34 outputs audio by processing the created audio data.

次に、処理システム1における処理動作について説明する。 Next, we will explain the processing operations in processing system 1.

まず、エンコーダ10によるエンコード処理について説明する。 First, we will explain the encoding process performed by the encoder 10.

図14は、一実施形態に係るエンコード処理のフローチャートである。 Figure 14 is a flowchart of the encoding process according to one embodiment.

エンコード処理においては、まず、対象データ入力部11が、エンコード対象の音声データを受け付ける(S11)。 In the encoding process, first, the target data input unit 11 accepts the audio data to be encoded (S11).

次いで、予測差分算出部12は、音声データの各データ要素(各時点のデータ)についての予測差分x’[t]を算出する処理を行う(S12)。 Next, the prediction difference calculation unit 12 performs a process of calculating the prediction difference x'[t] for each data element (data at each point in time) of the audio data (S12).

次いで、符号化部13は、予測差分算出部12により算出された予測差分x’[t]を、符号化を行う対象とする変換対象データp[t](処理対象データ)に変換し、変換対象データp[t]の各値をn個単位でブロック化することで、ブロック化時系列p[t]を生成する(S13)。 Next, the encoding unit 13 converts the prediction difference x'[t] calculated by the prediction difference calculation unit 12 into conversion target data p[t] (data to be processed) to be encoded, and generates a blocked time series pn [t] by blocking each value of the conversion target data p[t] in units of n (S13).

次いで、符号化部13は、CBT符号についてのパラメータmを推定(決定)する(S14)。 Next, the encoding unit 13 estimates (determines) parameters m and n for the CBT code (S14).

次いで、符号化部13は、推定したパラメータmに従ってブロック化時系列p[t]の各ブロックを結合符号に符号化する符号化処理を行う(S15)。 Next, the encoding unit 13 performs an encoding process of encoding each block of the blocked time series p n [t] into a combined code in accordance with the estimated parameters m n (S15).

次いで、圧縮データ出力部14は、全てのブロックを符号化した結合符号と、符号化処理のパラメータmとをまとめた圧縮データを作成し、デコーダ30に出力(送信)する。 Next, the compressed data output unit 14 creates compressed data that combines the combined code obtained by encoding all the blocks and the parameters m and n of the encoding process, and outputs (transmits) the compressed data to the decoder 30.

このエンコード処理では、音声データを符号化した際の符号長を短くすることができ、音声データの圧縮効率を向上することができる。 This encoding process can shorten the code length when encoding audio data, improving the compression efficiency of the audio data.

次に、デコーダ30によるデコード処理について説明する。 Next, we will explain the decoding process performed by the decoder 30.

図15は、一実施形態に係るデコード処理のフローチャートである。 Figure 15 is a flowchart of the decoding process according to one embodiment.

圧縮データ入力部31は、ネットワーク50を介してエンコーダ10から送信される圧縮データ(処理対象データの一例)を入力する(ステップS31)。 The compressed data input unit 31 inputs compressed data (an example of data to be processed) transmitted from the encoder 10 via the network 50 (step S31).

次いで、符号復号部32は、圧縮データに含まれる各結合符号に対して、対応するパラメータmを用いて復号処理を行うことにより、符号化前のデータ、すなわち、ブロック化時系列p[t]を得て、ブロック化時系列p[t]の各ブロックに含まれるn個の要素の値を分割して、変換対象データp[t]を得る(S32)。 Next, the coder/decoder 32 performs a decoding process on each combined code included in the compressed data using the corresponding parameter mn to obtain the data before encoding, i.e., the blocked time series pn [t], and divides the values of the n elements included in each block of the blocked time series pn [t] to obtain the data to be converted p[t] (S32).

次いで、対象データ算出部33は、変換対象データp[t]のそれぞれの要素を予測差分x’[t]に変換し、予測差分x’[t]の各要素を元のデータ列x[t]に復元する(S33)。 Next, the target data calculation unit 33 converts each element of the conversion target data p[t] into a prediction difference x'[t], and restores each element of the prediction difference x'[t] to the original data sequence x[t] (S33).

次いで、対象データ算出部33は、全てのデータ列x[t]をまとめて音声データを作成し、対象データ処理部34は、作成された音声データにより音声出力処理を行い(S34)、処理を終了する。 Next, the target data calculation unit 33 puts all the data strings x[t] together to create voice data, and the target data processing unit 34 performs voice output processing using the created voice data (S34), and the process ends.

上記したデコード処理によると、エンコーダ10で作成された圧縮データに基づいて、適切に音声を出力することができる。 The above-mentioned decoding process allows appropriate audio output based on the compressed data created by the encoder 10.

次に、上記した符号化による結合符号の平均符号長について説明する。 Next, we will explain the average code length of the combined code generated by the above encoding.

図16は、一実施形態に係る符号化による平均符号長を説明する図である。図16(A)は、拡大情報源Sについての幾何分布のθを変えた場合における、本実施形態の符号化で使用したパラメータmと、符号化により得られる結合符号の平均符号長と、パラメータm=1,2,3とした場合のそれぞれにおけるゴロム符号化により得られる符号の平均符号長を示し、図16(B)は、拡大情報源Sについての幾何分布のθを変えた場合における、各符号化における平均符号長を示し、図16(C)は、拡大情報源Sについての幾何分布のθを変えた場合における、各符号化における平均符号長を示す。 Fig. 16 is a diagram for explaining the average code length by the encoding according to an embodiment. Fig. 16(A) shows the parameter m2 used in the encoding of this embodiment, the average code length of the combined code obtained by encoding, and the average code length of the code obtained by Golomb encoding in each case where the parameter m= 1 , 2, 3 is set, when the geometric distribution θ of the extended information source S2 is changed, Fig. 16(B) shows the average code length in each encoding when the geometric distribution θ of the extended information source S3 is changed, and Fig. 16(C) shows the average code length in each encoding when the geometric distribution θ of the extended information source S4 is changed.

例えば、図16(A)に示すように、θ=2-1/√(5)である幾何分布に従う拡大情報源Sについて、本実施形態の符号化でm=5とした場合における結合符号の平均符号長は、3.154[bit]であるのに対して、m=1,2,3とした場合のゴロム符号化による符号の平均符号長は、それぞれ、3.753、3.164、3.211[bit]となる。 For example, as shown in FIG. 16A, for an extended information source S2 that follows a geometric distribution with θ=2−1 /√(5) , the average code length of the combined code when m2 =5 in the encoding of this embodiment is 3.154 [bits], whereas the average code lengths of the codes by Golomb encoding when m=1, 2, and 3 are 3.753, 3.164, and 3.211 [bits], respectively.

拡大情報源Sに対しては、図16(A)に示すように、本実施形態の結合符号の平均符号長は、θが2-1/2である場合には、m=2の場合のゴロム符号化による符号の平均符号長と同じであるが、それ以外は、いずれのゴロム符号化による符号の平均符号長よりも短くすることができ、データの圧縮効率を向上することができる。 For the extended information source S2 , as shown in FIG. 16A, when θ is 2−1 /2 , the average code length of the combined code of this embodiment is the same as the average code length of the code by Golomb coding when m=2, but otherwise can be made shorter than the average code length of any code by Golomb coding, thereby improving the data compression efficiency.

また、拡大情報源Sに対しては、図16(B)に示すように、本実施形態の結合符号の平均符号長を、いずれのゴロム符号化による符号の平均符号長よりも短くすることができ、データの圧縮効率を向上することができる。 Furthermore, for the extended information source S3 , as shown in FIG. 16(B), the average code length of the combined code of this embodiment can be made shorter than the average code length of any code based on Golomb coding, thereby improving the data compression efficiency.

また、拡大情報源Sに対しては、図16(C)に示すように、本実施形態の結合符号の平均符号長を、いずれのゴロム符号化による符号の平均符号長よりも短くすることができ、データの圧縮効率を向上することができる。 Furthermore, for the extended information source S4 , as shown in FIG. 16(C), the average code length of the combined code of this embodiment can be made shorter than the average code length of any code based on Golomb coding, thereby improving the data compression efficiency.

上記したエンコーダ10及びデコーダ30は、それぞれコンピュータ装置により構成することができる。 The above-mentioned encoder 10 and decoder 30 can each be configured as a computer device.

図17は、一実施形態に係るコンピュータ装置の構成図である。なお、本実施形態では、エンコーダ10及びデコーダ30は、別々のコンピュータ装置で構成されているが、これらコンピュータ装置は、同様な構成を有するものとすることができる。したがって、以下の説明では、便宜的に図17に示すコンピュータ装置を用いて、エンコーダ10及びデコーダ30を構成するコンピュータ装置について説明することとする。 Figure 17 is a configuration diagram of a computer device according to one embodiment. Note that in this embodiment, the encoder 10 and the decoder 30 are configured as separate computer devices, but these computer devices can have similar configurations. Therefore, for the sake of convenience, in the following explanation, the computer device that constitutes the encoder 10 and the decoder 30 will be explained using the computer device shown in Figure 17.

コンピュータ装置100は、例えば、Central Processin Unit(CPU)101と、メインメモリ102と、Graphics Processing Unit(GPU)103と、リーダライタ104と、通信インターフェース(通信I/F)105と、補助記憶装置106と、入出力インターフェース(入出力I/F)107と、出力装置108と、入力装置109とを備える。CPU101、メインメモリ102、GPU103、リーダライタ104、通信I/F105、補助記憶装置106、入出力I/F107、及び出力装置108は、バス110を介して接続されている。エンコーダ10と、デコーダ30とは、それぞれコンピュータ装置100に記載の構成要素の一部または全てを適宜選択して構成される。 The computer device 100 includes, for example, a Central Processing Unit (CPU) 101, a main memory 102, a Graphics Processing Unit (GPU) 103, a reader/writer 104, a communication interface (communication I/F) 105, an auxiliary storage device 106, an input/output interface (input/output I/F) 107, an output device 108, and an input device 109. The CPU 101, the main memory 102, the GPU 103, the reader/writer 104, the communication I/F 105, the auxiliary storage device 106, the input/output I/F 107, and the output device 108 are connected via a bus 110. The encoder 10 and the decoder 30 are each configured by appropriately selecting some or all of the components described in the computer device 100.

エンコーダ10を構成するコンピュータ装置100において、CPU101は、補助記憶装置106に格納された処理プログラムを実行することにより、例えば、対象データ入力部11、予測差分算出部12、符号化部13、及び圧縮データ出力部14を構成する。 In the computer device 100 constituting the encoder 10, the CPU 101 executes a processing program stored in the auxiliary storage device 106 to constitute, for example, a target data input unit 11, a prediction difference calculation unit 12, an encoding unit 13, and a compressed data output unit 14.

デコーダ30を構成するコンピュータ装置100において、CPU101は、補助記憶装置106に格納された処理プログラムを実行することにより、例えば、圧縮データ入力部31、符号復号部32、対象データ算出部33、及び対象データ処理部34を構成する。 In the computer device 100 constituting the decoder 30, the CPU 101 executes a processing program stored in the auxiliary storage device 106 to constitute, for example, a compressed data input unit 31, an encoding/decoding unit 32, a target data calculation unit 33, and a target data processing unit 34.

メインメモリ102は、例えば、RAM、ROM等であり、CPU101に実行されるプログラム(処理プログラム等)や、各種情報を記憶する。補助記憶装置106は、例えば、Hard DISK Drive(HDD)、Solid State Drive(SSD)等の非一時的記憶デバイス(不揮発性記憶デバイス)であり、CPU101で実行されるプログラムや、各種情報を記憶する。 The main memory 102 is, for example, a RAM, a ROM, etc., and stores programs (processing programs, etc.) executed by the CPU 101 and various information. The auxiliary storage device 106 is, for example, a non-transitory storage device (non-volatile storage device) such as a hard disk drive (HDD) or a solid state drive (SSD), and stores programs executed by the CPU 101 and various information.

GPU103は、例えば、特定の処理の実行に適しているプロセッサであり、例えば、並列的に行われる処理の実行に適している。本実施形態では、GPU103は、CPU101の指示に従って所定の処理を実行する。 The GPU 103 is, for example, a processor that is suitable for executing a specific process, for example, a process that is performed in parallel. In this embodiment, the GPU 103 executes a predetermined process according to instructions from the CPU 101.

リーダライタ104は、記録媒体111を着脱可能であり、記録媒体111からのデータの読み出し、及び記録媒体111へのデータの書き込みを行う。記録媒体111としては、例えば、SDメモリーカード、FD(フロッピーディスク:登録商標)、CD、DVD、BD(登録商標)、フラッシュメモリ等の非一時的記録媒体(不揮発性記録媒体)がある。本実施形態においては、記録媒体111に、処理プログラムを格納しておき、リーダライタ104により、これを読み出して、利用するようにしてもよい。また、エンコーダ10を構成するコンピュータ装置100において、記録媒体111に、処理対象の音声データを格納しておき、リーダライタ104により、これを読み出して使用するようにしてもよい。また、エンコーダ10を構成するコンピュータ装置100において、リーダライタ104により、圧縮データを記録媒体111に格納するようにしてもよい。また、デコーダ30を構成するコンピュータ装置100において、リーダライタ104により、記録媒体111から圧縮データを読み出して利用するようにしてもよい。 The reader/writer 104 is detachable from the recording medium 111, and reads data from the recording medium 111 and writes data to the recording medium 111. The recording medium 111 may be, for example, a non-temporary recording medium (non-volatile recording medium) such as an SD memory card, a floppy disk (FD: registered trademark), a CD, a DVD, a BD (registered trademark), or a flash memory. In this embodiment, a processing program may be stored in the recording medium 111, and the reader/writer 104 may read and use the program. In the computer device 100 constituting the encoder 10, audio data to be processed may be stored in the recording medium 111, and the reader/writer 104 may read and use the program. In the computer device 100 constituting the encoder 10, the reader/writer 104 may store compressed data in the recording medium 111. In the computer device 100 constituting the decoder 30, the reader/writer 104 may read and use the compressed data from the recording medium 111.

通信I/F105は、ネットワーク50に接続されており、ネットワーク50に接続された他の装置との間でのデータの送受信を行う。 The communication I/F 105 is connected to the network 50 and transmits and receives data to and from other devices connected to the network 50.

入出力I/F107は、例えば、マウス、キーボード等の入力装置109と接続されている。エンコーダ10を構成するコンピュータ装置100において、入出力I/F107は、入力装置109を用いた、エンコーダ10のユーザによる操作入力を受け付ける。また、デコーダ30を構成するコンピュータ装置100において、入出力I/F107は、入力装置109を用いた、デコーダ30のユーザによる操作入力を受け付ける。 The input/output I/F 107 is connected to an input device 109 such as a mouse or a keyboard. In the computer device 100 constituting the encoder 10, the input/output I/F 107 accepts operational input by a user of the encoder 10 using the input device 109. In the computer device 100 constituting the decoder 30, the input/output I/F 107 accepts operational input by a user of the decoder 30 using the input device 109.

出力装置108は、例えば、液晶ディスプレイ等のディスプレイ装置やスピーカ装置であり、各種情報の表示出力や音声を出力する。出力装置108は、例えば、デコーダ30において、対象データ処理部34による音声の出力に使用される。 The output device 108 is, for example, a display device such as an LCD display or a speaker device, and outputs various types of information and audio. The output device 108 is used, for example, in the decoder 30, for audio output by the target data processing unit 34.

なお、本発明は、上述の実施形態及び変形例に限定されるものではなく、本発明の趣旨を逸脱しない範囲で、適宜変形して実施することが可能である。 The present invention is not limited to the above-described embodiment and modifications, and may be modified as appropriate without departing from the spirit of the present invention.

例えば、上記実施形態では、エンコーダ10では、対象データの全体についてのファイルを作成し、そのファイルをデコーダ30に送信するようにしていた。本発明はこれに限られず、エンコーダ10は、例えば、ブロックごとの圧縮データを逐次送信するようにしてもよい。 For example, in the above embodiment, the encoder 10 creates a file for the entire target data and transmits the file to the decoder 30. The present invention is not limited to this, and the encoder 10 may, for example, transmit compressed data for each block sequentially.

また、上記実施形態では、元のデータを無歪みで符号化するようにしていたが、本発明はこれに限られず、元のデータを量子化等による歪み処理後に符号化するようにしてもよい。 In addition, in the above embodiment, the original data is encoded without distortion, but the present invention is not limited to this, and the original data may be encoded after distortion processing such as quantization.

また、上記実施形態では、符号化の対象を音声データとしていたが、本発明はこれに限られず、符号化の対象を音声以外のデータ、例えば、画像データとしてもよい。 In addition, in the above embodiment, the target of encoding is audio data, but the present invention is not limited to this, and the target of encoding may be data other than audio, for example, image data.

また、上記実施形態では、コンピュータ装置100がエンコーダ10又はデコーダ30のいずれか一方を備えている例を示していた。本発明はこれに限られず、コンピュータ装置100内にエンコーダ10とデコーダ30との両方を備えるようにしてもよい。 In addition, in the above embodiment, an example was shown in which the computer device 100 includes either the encoder 10 or the decoder 30. The present invention is not limited to this, and the computer device 100 may include both the encoder 10 and the decoder 30.

1…処理システム、10…エンコーダ、11…対象データ入力部、12…予測差分算出部、13…符号化部、14…圧縮データ出力部、30…デコーダ、31…圧縮データ入力部、32…符号復号部、33…対象データ算出部、34…対象データ処理部、50…ネットワーク、100…コンピュータ装置、101…CPU、102…メインメモリ、108…出力装置、111…記録媒体 1... Processing system, 10... Encoder, 11... Target data input unit, 12... Prediction difference calculation unit, 13... Encoding unit, 14... Compressed data output unit, 30... Decoder, 31... Compressed data input unit, 32... Encoding/decoding unit, 33... Target data calculation unit, 34... Target data processing unit, 50... Network, 100... Computer device, 101... CPU, 102... Main memory, 108... Output device, 111... Recording medium

Claims (9)

複数の整数値を含む符号化対象データを符号化するエンコーダであって、
前記符号化対象データから複数個の整数値が並ぶブロックデータを特定する特定部と、
前記ブロックデータを、複数のアルファ符号とCBT符号とを結合した結合符号に符号化する符号化部と、を備える
エンコーダ。
1. An encoder for encoding encoding target data including a plurality of integer values, comprising:
an identification unit that identifies block data in which a plurality of integer values are arranged from the encoding target data;
An encoder that encodes the block data into a combined code that combines a plurality of alpha codes and a CBT code.
前記符号化部は、複数種類のブロックデータについて、前記複数のアルファ符号の値が同一であり、前記CBT符号の値が異なる結合符号に符号化する
請求項1に記載のエンコーダ。
The encoder according to claim 1 , wherein the encoding unit encodes a plurality of types of block data into a combined code in which the plurality of alpha codes have the same value and the CBT code has a different value.
前記符号化部は、前記ブロックデータの前記複数個の整数値の並びの出現確率に基づいて、前記ブロックデータに割り当てる前記複数のアルファ符号の値を決定する
請求項2に記載のエンコーダ。
The encoder according to claim 2 , wherein the encoding unit determines the plurality of alpha code values to be assigned to the block data based on an occurrence probability of the sequence of the plurality of integer values of the block data.
前記符号化部は、前記出現確率が高い前記ブロックデータに割り当てられる前記複数のアルファ符号が短くなる傾向となるように符号化を行う
請求項3に記載のエンコーダ。
The encoder according to claim 3 , wherein the encoding section performs encoding such that the plurality of alpha codes assigned to the block data having a high occurrence probability tend to be short.
前記符号化部は、前記出現確率が高い前記ブロックデータに割り当てられる前記CBT符号が短くなるように符号化を行う
請求項3に記載のエンコーダ。
The encoder according to claim 3 , wherein the encoding unit performs encoding so that the CBT code assigned to the block data having a high occurrence probability is short.
前記結合符号をエンコーダに送信する送信部を更に備える
請求項1に記載のエンコーダ。
The encoder of claim 1 , further comprising a transmitter for transmitting the combined code to an encoder.
符号化データを復号するデコーダであって、
前記符号化データは、複数個の整数値が並ぶブロックデータを符号化することにより得られた、複数のアルファ符号とCBT符号とを結合した結合符号を含み、
前記符号化データを受け付ける受付部と、
前記符号化データに含まれる結合符号を、前記複数個の整数値に復号する復号部と、を備える
デコーダ。
A decoder for decoding encoded data, comprising:
The encoded data includes a combined code obtained by encoding block data in which a plurality of integer values are arranged, the combined code being a combination of a plurality of alpha codes and a CBT code,
A reception unit that receives the encoded data;
a decoding unit configured to decode a combined code included in the encoded data into the plurality of integer values.
複数の整数値を含む符号化対象データを符号化するエンコーダによるエンコード方法であって、
前記符号化対象データから複数個の整数値が並ぶブロックデータを特定し、
前記ブロックデータを、複数のアルファ符号とCBT符号とを結合した結合符号に符号化する
エンコード方法。
An encoding method for encoding target data including a plurality of integer values, comprising:
Identifying a block of data in which a plurality of integer values are arranged from the encoding target data;
An encoding method for encoding the block data into a combined code that combines a plurality of alpha codes and a CBT code.
符号化データを復号するデコーダによるデコード方法であって、
前記符号化データは、複数個の整数値が並ぶブロックデータを符号化することにより得られた、複数のアルファ符号とCBT符号とを結合した結合符号を含み、
符号化データを受け付け、
前記符号化データに含まれる結合符号を、前記複数個の整数値に復号する
デコード方法。
A decoding method for decoding encoded data, comprising:
The encoded data includes a combined code obtained by encoding block data in which a plurality of integer values are arranged, the combined code being a combination of a plurality of alpha codes and a CBT code,
Accepts the encoded data,
A decoding method for decoding a combined code included in the encoded data into the plurality of integer values.
JP2023129213A 2023-08-08 2023-08-08 Decoder, Encoder, Decoding Method, and Encoding Method Pending JP2025024868A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2023129213A JP2025024868A (en) 2023-08-08 2023-08-08 Decoder, Encoder, Decoding Method, and Encoding Method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2023129213A JP2025024868A (en) 2023-08-08 2023-08-08 Decoder, Encoder, Decoding Method, and Encoding Method

Publications (1)

Publication Number Publication Date
JP2025024868A true JP2025024868A (en) 2025-02-21

Family

ID=94644754

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2023129213A Pending JP2025024868A (en) 2023-08-08 2023-08-08 Decoder, Encoder, Decoding Method, and Encoding Method

Country Status (1)

Country Link
JP (1) JP2025024868A (en)

Similar Documents

Publication Publication Date Title
JP3017379B2 (en) Encoding method, encoding device, decoding method, decoder, data compression device, and transition machine generation method
JP6239652B2 (en) Encoding method and encoding apparatus
CN100553152C (en) Encoding method and device and decoding method and device based on CABAC
CN103067022B (en) A kind of integer data lossless compression method, decompression method and device
US11722148B2 (en) Systems and methods of data compression
KR20110007865A (en) Data Compression Method
CN101420231A (en) Encoding method and device, and program
JP5619326B2 (en) Encoding device, decoding device, encoding method, encoding program, decoding method, and decoding program
WO2019080670A1 (en) Gene sequencing data compression method and decompression method, system, and computer readable medium
CN115882866A (en) Data compression method based on data difference characteristic
WO2020095706A1 (en) Coding device, decoding device, code string data structure, coding method, decoding method, coding program, and decoding program
JP2012134858A (en) Data compression apparatus, data compression method and data compression program
CN106537914B (en) The method and apparatus of arithmetic compiling is executed by the carry operations of limitation
JP4758494B2 (en) Circuit and method for converting bit length to code
JP5095033B2 (en) Data compression apparatus, data compression method, and program
JP6885466B2 (en) Coding device, decoding device, coding method, decoding method, coding program, decoding program
JP2025024868A (en) Decoder, Encoder, Decoding Method, and Encoding Method
US20060125660A1 (en) Digital data compression robust relative to transmission noise
US12028093B2 (en) Encoder, decoder, encoding method, decoding method and program
JP2004120623A (en) Encoding device, encoding method, decoding device and decoding method
Rani et al. A survey on lossless text data compression techniques
JP2024149053A (en) Processing device, processing method, and processing program
WO2019198383A1 (en) Encoding device, decoding device, encoding method, decoding method, program, and recording medium
Das ByteZip: Efficient Lossless Compression for Structured Byte Streams Using DNNs
JPH0828668B2 (en) Audio signal encoding method