Decoding device and decoding method

The encoding device optimizes bit allocation in multi-rate lattice vector quantization by selectively encoding subvectors, reducing coding bits and addressing complexity issues in existing methods.

JP2025131849AActive Publication Date: 2025-09-09PANASONIC INTELLECTUAL PROPERTY CORP OF AMERICA
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
JP2025101205
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Priority Date
2021-07-16
Filing Date
2025-06-17
Publication Date
2025-09-09
Estimated Expiration
2041-11-16

AI Technical Summary

Technical Problem

Existing multi-rate lattice vector quantization methods face challenges in reducing the number of coding bits, particularly in cases where difference information becomes negative, increasing complexity and limiting bit reduction under certain conditions.

Method used

An encoding device and method that includes a quantization circuit and a control circuit to determine the encoding of subvectors based on available bits, employing a code conversion process to optimize bit allocation and reduce coding bits through selective encoding of codebook indication values.

Benefits of technology

The proposed solution effectively reduces the number of coding bits in multi-rate lattice vector quantization, addressing complexity issues and optimizing bit allocation for improved efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2025131849000001_ABST
    Figure 2025131849000001_ABST
Patent Text Reader

Abstract

To provide an encoding device, a decoding device, an encoding method and a decoding method for reducing the number of encoding bits in vector quantization.SOLUTION: A decoding device: receives a bit stream encoding a quantization parameter or the number of unused bits, in which the quantization parameter includes a codebook index used in vector quantization and a selected code vector index, for each of a plurality of sub-vectors; acquires the codebook index and the code vector index by decoding the quantization parameter for each sub-vector having received the quantization parameter; estimates the codebook index and the code vector index for the sub-vector having received the number of unused bits; and outputs a signal of a frequency area after vector quantization for each of the plurality of sub-vectors by performing reverse vector quantization based on the codebook index and the code vector index.SELECTED DRAWING: Figure 11
Need to check novelty before this filing date? Find Prior Art

Description

[Technical Field]

[0001] The present disclosure relates to an encoding device, a decoding device, an encoding method, and a decoding method. [Background technology]

[0002] One of the quantization methods used in audio or speech coding (e.g., excitation signal coding) is multi-rate lattice vector quantization (see, for example, Non-Patent Document 1). Multi-rate lattice vector quantization may be applied to split vector quantization (e.g., called split multi-rate lattice vector quantization or split multi-rate lattice vector quantization). Furthermore, split multi-rate lattice vector quantization may be applied to algebraic vector quantization (also called AVQ). [Prior art documents] [Patent documents]

[0003] [Patent Document 1] International Publication No. 2013 / 061531 [Non-patent literature]

[0004] [Non-Patent Document 1] 3GPP TS 26.445 V16.0.0,"Codec for Enhanced Voice Services (EVS); Detailed Algorithmic Description (Release 16)", 2019-06. Summary of the Invention [Problem to be solved by the invention]

[0005] However, there is room for further study on how to reduce the number of coding bits in multi-rate lattice vector quantization.

[0006] Non-limiting embodiments of the present disclosure contribute to providing an encoding device, a decoding device, an encoding method, and a decoding method that reduce the number of coding bits in vector quantization. [Means for solving the problem]

[0007] An encoding device according to one embodiment of the present disclosure includes a quantization circuit that generates a quantization parameter including information about a vector quantization codebook, and a control circuit that determines whether to perform a first encoding of the information for a target subvector based on the number of bits available for encoding a subvector in the vector quantization, or a second encoding based on the difference between the number of allocated bits for the vector quantization and the number of bits of the quantization parameter.

[0008] These comprehensive or specific aspects may be realized as a system, an apparatus, a method, an integrated circuit, a computer program, or a recording medium, or may be realized as any combination of a system, an apparatus, a method, an integrated circuit, a computer program, and a recording medium. [Effects of the Invention]

[0009] According to an embodiment of the present disclosure, the number of coding bits can be reduced in multi-rate lattice vector quantization.

[0010] Further advantages and benefits of an embodiment of the present disclosure will become apparent from the specification and drawings. Such advantages and / or benefits may be provided by some of the embodiments and features described in the specification and drawings, respectively, but not necessarily all of them may be provided to obtain one or more identical features. [Brief explanation of the drawings]

[0011] [Figure 1]FIG. 1 shows an example of a codebook list in split multirate lattice vector quantization. [Figure 2] Block diagram showing a partial configuration example of the Algebraic Code Excited Linear Prediction (ACELP) encoding unit in the Enhanced Voice Services (EVS) codec [Figure 3] Block diagram showing an example of the configuration related to Algebraic Vector Quantizer (AVQ) encoding in the EVS codec [Figure 4] FIG. 1 is a block diagram showing a configuration example of a coding device according to a first embodiment. [Figure 5] FIG. 10 is a diagram showing an example of sub-vector selection processing; [Figure 6] FIG. 10 is a diagram illustrating an example of code conversion processing. [Figure 7] FIG. 10 is a diagram illustrating an example of code conversion processing. [Figure 8] FIG. 10 is a diagram illustrating an example of code conversion processing. [Figure 9] FIG. 10 is a diagram showing an example of encoding processing of the number of unused bits. [Figure 10] FIG. 10 is a diagram showing an example of the correspondence between the number of unused bits and the unused bit number encoding code. [Figure 11] FIG. 1 is a block diagram showing a configuration example of a decoding device according to a first embodiment. [Figure 12] FIG. 10 is a block diagram showing a configuration example of an encoding device according to a second embodiment. [Figure 13] FIG. 10 is a diagram illustrating an example of code conversion processing. [Figure 14] FIG. 10 is a diagram illustrating an example of code conversion processing. [Figure 15] FIG. 10 is a diagram illustrating an example of code conversion processing. [Figure 16] FIG. 10 is a diagram illustrating an example of code conversion processing. [Figure 17] FIG. 10 is a diagram showing another example of code conversion processing; [Figure 18] FIG. 10 is a diagram showing an example of encoding processing of the number of unused bits. [Figure 19] FIG. 10 is a block diagram showing a configuration example of a decoding device according to a second embodiment. [Figure 20] FIG. 10 is a diagram showing an example of a decoding process; [Figure 21] FIG. 10 is a diagram showing an example of a decoding process; [Figure 22] FIG. 10 is a diagram showing an example of a decoding process; [Figure 23] FIG. 10 is a diagram showing an example of a decoding process; [Figure 24] FIG. 10 is a diagram showing another example of the decoding process. [Figure 25] FIG. 10 is a diagram showing an example of a decoding process based on the number of unused bits. DETAILED DESCRIPTION OF THE INVENTION

[0012] Hereinafter, embodiments of the present disclosure will be described in detail with reference to the drawings.

[0013] For example, in split multi-rate lattice vector quantization, a signal in the time domain or frequency domain (or spectral domain) may be divided into multiple sub-vectors (SVs, also called sub-bands or sub-blocks), and multi-rate lattice vector quantization may be performed on each of the multiple divided sub-vectors.

[0014] FIG. 1 is a diagram showing an example of a list of a codebook (also called a codebook) in multi-rate lattice vector quantization for subvectors (see, for example, Patent Document 1 or Non-Patent Document 1).

[0015] For example, as shown in FIG. 1, the quantization parameters in split multi-rate lattice vector quantization may include information identifying a codebook used for quantization (e.g., called a "codebook indicator" or codebook index) and information identifying a codevector to be selected from among multiple codevectors included in the codebook (e.g., called a "code vector index").

[0016] For example, in each of the codebooks Q0, Q2, Q3, Q4, Q5, ..., Qn shown in Fig. 1, 1, 10, 15, 20, 25, ..., 5n bits (n is an integer greater than or equal to 2) may be used to encode (or quantize) one subvector (SV). Of the number of bits used for encoding using each codebook (e.g., the total number of bits used), 1, 2, 3, 4, 5, ..., n bits (n is an integer greater than or equal to 2) may be used for the codebook indication value. In other words, in Fig. 1, the ratio of the number of bits allocated to encoding the codebook indication value to the total number of bits used for encoding using each codebook (e.g., 5n, n is an integer greater than 1) may be 1 / 5.

[0017] Note that the codebook Q0 may include one vector (for example, a zero vector or a null vector). The zero vector means, for example, that the quantized value of the vector is 0. Therefore, in the codebook Q0, the code vector index does not need to be defined, and the number of bits used for the code vector index may be 0. In the codebook Q0, for example, 1 bit may be used for the codebook indication value.

[0018] For example, an encoder may collectively encode multiple sub-vectors (e.g., eight SVs in Non-Patent Document 1) using the codebook shown in Fig. 1. The number of bits available for encoding multiple sub-vectors (e.g., referred to as the "total number of bits") may be known between the encoder and decoder.

[0019] For example, Patent Document 1 proposes a bit reduction method for split multi-rate lattice vector quantization for eight SVs. For example, based on the number of bits used for seven of the eight SVs, a codebook indication value (codebook index) used for the remaining one SV may be estimated according to the following equation (1) (see Patent Document 1, for example).

number

[0020] In equation (1), cb'fix indicates an estimate of the number of bits used in the codebook instruction value for one SV (for example, subvector number i=Pfix), and Bits available denotes the total number of bits available for encoding the 8 SVs, and ΣBits cbvi indicates the total number of bits used for encoding the subvector number i=Pfix and the other seven subvectors vi (i≠Pfix) that are different from the subvector number i=Pfix (for example, the total number of bits used in FIG. 1).

[0021] In Patent Document 1, for example, for one SV (e.g., i=Pfix), the encoding device quantizes (or encodes) the difference between the estimated value cb'fix of the number of bits used for the codebook indicated value shown in Equation (1) and the number of bits of the actual codebook indicated value, and transmits the difference information to the decoding device. For example, the larger the codebook number n used for one SV, the smaller the amount of information (e.g., the number of bits) of the difference information described above becomes than the codebook indicated value, and the number of encoding bits can be reduced.

[0022] However, in Patent Document 1, for example, there are cases where the difference information (in other words, the object to be coded) becomes a negative number (e.g., -1), and since a quantization level or code corresponding to the negative number is used, the complexity of coding (or quantization) may increase.

[0023] Furthermore, when encoding one identified SV using codebook Q0 (e.g., codebook instruction value "0") or codebook Q2 under special conditions (e.g., codebook instruction value "1"), it may not be possible to reduce the number of encoding bits.

[0024] Here, the special case may be, for example, a case where, of the total number of bits available for encoding, there are no bits unused for encoding and all bits are used for encoding. In this case, for example, in FIG. 1, among the multiple bits indicating the codebook indication value of each codebook, the trailing "0" (also called stop bit) may be omitted. For example, in the special case, the codebook indication value of codebook Q2 may be "1" (1 bit) obtained by omitting the "0" from "10".

[0025] Furthermore, for example, when focusing on bit reduction of an SV that uses a larger number of bits for encoding among multiple SVs, it may not be possible to reduce the number of encoding bits if an SV occurs that uses 0 bits for encoding (for example, an SV that is not encoded because the number of available bits is insufficient). Note that an SV that uses 0 bits for encoding is likely to be, for example, a high-frequency SV among multiple SVs (for example, the 6th, 7th, or 8th SV out of 8 SVs).

[0026] Therefore, in one embodiment of the present disclosure, a method for reducing the number of coding bits used in encoding (in other words, variable length code) of codebook indication values ​​of multi-rate lattice vector quantization (LVQ: Lattice VQ) applied to split vector quantization (e.g., SVQ: Split VQ) is described.

[0027] In the following, as an example, an Enhanced Voice Services (EVS) codec will be described in which multi-rate lattice vector quantization is used as AVQ. Here, an example will be described in which AVQ is used for vector quantization of Discrete Cosine Transform (DCT) coefficients, but it is not limited to quantization and coding of DCT coefficients (in other words, frequency domain). For example, AVQ (or multi-rate lattice vector quantization) can also be applied to vector quantization in the time domain.

[0028] In the following, as an example, a case will be described in which the number of divisions into sub-vectors in AVQ is set to eight (for example, SV1 to SV8). Note that the number of divisions into sub-vectors is not limited to eight, and may be another number.

[0029] (Embodiment 1) [Example of encoding device configuration] Fig. 2 is a block diagram showing an example configuration of an Algebraic Code Excited Linear Prediction (ACELP) encoding device for the EVS codec (for example, Figure 29 in Non-Patent Document 1). Fig. 3 is a block diagram showing signal processing related to an AVQ encoding unit (for example, an AVQ encoder) in Fig. 2. An embodiment of the present disclosure is applicable to, for example, encoding of codebook indices output from the AVQ encoding unit (AVQ enc block or Split Lattice VQ block) in Figs. 2 and 3.

[0030] 4 is a block diagram showing an example of a signal processing configuration for an AVQ encoding unit (hereinafter, for convenience, referred to as "encoding device") 100 according to an embodiment of the present disclosure. The encoding device 100 shown in FIG. 4 may include a multiplier 101, a subtractor 102, a de-emphasis unit 103, a DCT unit 104, an AVQ encoding unit (or a split multi-rate lattice vector quantization unit) 105 (e.g., corresponding to a quantization circuit), a floating bit count management unit 106, an inverse DCT (iDCT) unit 107, a subvector identification unit 108, a code conversion unit 109 (e.g., corresponding to a control circuit), and a multiplexer 110.

[0031] For example, multiplying section 101 may multiply an adaptive codebook vector v(n) input from an adaptive codebook by an adaptive codebook gain (or pitch gain) gp, and output the multiplication result to subtractor .

[0032] The subtractor 102 subtracts the adaptive codebook vector multiplied by the adaptive codebook gain input from the multiplier 101 from the linear prediction residual signal r(n), which is the coding target in ACELP coding, to obtain an excitation residual signal q in (n) may be determined (e.g., calculated). in (n) may be calculated based on the following equation (2), for example: in (n) may be output to the de-emphasis unit 103.

number

[0033] The de-emphasis unit 103 is, for example, a de-emphasis filter Fp(z), and de-emphasizes the excitation residual signal q input from the subtractor 102. in The de-emphasis unit 103 may perform de-emphasis processing on the excitation residual signal q (n). in,d (n) may be output to the DCT unit 104.

[0034] The DCT unit 104 converts, for example, the excitation residual signal q in,d (n) may be converted into DCT coefficients and the DCT coefficients may be output to the AVQ encoding unit 105. Note that the method of converting a time domain signal into a frequency domain signal is not limited to DCT processing, and other methods such as a Discrete Fourier Transform (DFT) or a Modified Discrete Cosine Transform (MDCT) may also be used.

[0035] The AVQ encoding unit 105 receives the excitation residual signal q input from the DCT unit 104. in,d The DCT coefficients of (n) may be subjected to split lattice vector quantization (or AVQ coding).

[0036] For example, the AVQ encoding unit 105 may divide the DCT coefficients into a plurality of sub-vectors (SVs), quantize each of the plurality of sub-vectors, and generate quantization parameters including codebook numbers (also called codebook indicator values ​​or codebook indices) indicating a codebook and a codevector index indicating one of a plurality of codevectors included in the codebook.

[0037] Furthermore, the AVQ encoding unit 105 may determine the number of bits to be allocated to AVQ or the bit allocation (AVQ bit budget) based on, for example, the sum of the fixed number of bits (or a predetermined number of bits, fixed bit-budget) and the floating number of bits (e.g., the number of additional bits available for use) (floating bit-budget) input from the floating bit number management unit 106 for each subframe to be encoded, and output this to the code conversion unit 109. Furthermore, the AVQ encoding unit 105 may output, for example, information on the floating bit number (floating bit-budget), which is updated based on the number of bits remaining after AVQ, to the floating bit number management unit 106.

[0038] The AVQ encoding unit 105 may, for example, output a global gain code from among the quantization parameters obtained by quantization to the multiplexing unit 110. Furthermore, the AVQ encoding unit 105 may, for example, output codebook numbers for each subvector, codevector indices for each subvector, and the number of bits allocated to AVQ (AVQ bit budget) to the code conversion unit 109. Furthermore, the AVQ encoding unit 105 may, for example, output a quantized excitation residual signal q in,d The DCT coefficients (n) may be output to the inverse DCT unit 107.

[0039] The floating bits manager 106 may hold (or manage) information about the number of bits available for use in an encoding frame, based on information about the number of floating bits input from the AVQ encoder 105. For example, the floating bits manager 106 may output the number of bits it holds as the number of floating bits to the AVQ encoder 105 for AVQ encoding of a subsequent subframe.

[0040] The inverse DCT unit 107 converts the q input from the AVQ encoding unit 105 in,d The DCT coefficients of (n) are inverse DCT transformed to obtain the quantized excitation residual signal q d (n) may be output.

[0041] For example, subvector identification unit 108 may identify a dominant subvector from among multiple subvectors based on the input adaptive codebook vector v(n). Subvector identification unit 108 may output information related to the position of the dominant subvector (e.g., dominant subvector information) to code conversion unit 109. For example, since the target of quantization or encoding in AVQ encoding unit 105 is DCT coefficients, subvector identification unit 108 may convert adaptive codebook vector v(n) into DCT coefficients and identify the position (or frequency) of the subvector having the maximum energy in the DCT coefficient domain (or frequency domain) of adaptive codebook vector v(n). Note that if the target of quantization or encoding in AVQ encoding unit 105 is a time-domain signal, subvector identification unit 108 does not need to convert adaptive codebook vector v(n) into DCT coefficients.

[0042] Furthermore, the subvector identification unit 108 may be, for example, a memory that outputs information regarding the position of a predetermined specific subvector to the code conversion unit 109, regardless of the adaptive codebook vector v(n). In this case, since the position of the specific subvector is fixed, for example, when an embodiment of the present disclosure is realized by a software program, the position of the specific subvector may be written into the program. For example, the subvector identification unit 108 may set the third subvector or the last subvector of multiple (e.g., eight) subvectors as the specific subvector. Note that the specific subvector is not limited to the third subvector or the last subvector, and may be a subvector in another order. For example, the position of the specific subvector may be set to a position (e.g., the highest position) that has a higher probability (frequency) of having a larger codebook number, as determined experimentally or statistically.

[0043] The code conversion unit 109 (Codebook indications conversion) may convert the coding information of the codebook number of a specific subvector (e.g., a subvector to be code converted) based on, for example, the codebook number and code vector index of each of multiple subvectors input from the AVQ encoding unit 105, information on the number of bits allocated to AVQ in one subframe (AVQ bit-budget), and main subvector information input from the subvector identification unit 108.

[0044] For example, when the number of sub-vectors is eight, the code conversion unit 109 may output, to the multiplexing unit 110, coding information including codebook indexes and code vector indices for the eight sub-vectors, or may output, to the multiplexing unit 110, coding information including codebook indexes for seven sub-vectors, an index value for the number of unused bits (for example, referred to as an unused bit number index value), and code vector indices for the eight sub-vectors.

[0045] The multiplexing unit 110 may multiplex the global gain input from the AVQ encoding unit 105 and the encoded information input from the code conversion unit 109, and output the multiplexed bitstream information (for example, AVQ code).

[0046] Next, an example of the operation of the encoding device 100 will be described.

[0047] [Example of selecting subvectors for code conversion] The code conversion unit 109 may select a subvector to be code converted (e.g., also referred to as a target subvector) based on, for example, the primary subvector information input from the subvector identification unit 108 (e.g., information indicating a subvector identified as a primary subvector) and the number of bits allocated to AVQ of one subframe input from the AVQ encoding unit 105 (the number of bits allocated for vector quantization).

[0048] FIG. 5 is a diagram illustrating an example of a process for selecting sub-vectors to be subjected to code conversion.

[0049] In FIG. 5, the code conversion unit 109 determines, for example, the number of AVQ bits (AVQ bit-budget) available in a sub-frame (for example, AVQ sub-frame) (S101).

[0050] The code conversion unit 109 determines whether the AVQ bit-budget exceeds a threshold (S102). The threshold may be set to, for example, 85 bits / subframe, or another value. The threshold may be set experimentally or statistically.

[0051] If the AVQ bit-budget exceeds the threshold (S102: Yes), the code converting unit 109 may select, from among the multiple subvectors, a subvector identified by the primary subvector information as a subvector to be subjected to code conversion (S103).

[0052] On the other hand, if the AVQ bit-budget is equal to or less than the threshold (S102: No), the code conversion unit 109 may set, for example, the last subvector (e.g., the eighth subvector SV8) among the multiple subvectors as the subvector to be code converted (S104).

[0053] For example, the code conversion unit 109 may apply a code conversion process, which will be described later, to the selected sub-vectors to be code converted.

[0054] An example of selecting subvectors to be code converted has been described above.

[0055] Note that the selection of subvectors to be code converted may be performed in the subvector identification unit 108, rather than in the code conversion unit 109. In this case, information on the AVQ bit-budget may be input to the subvector identification unit 108. For example, the subvector identification unit 108 may output, to the code conversion unit 109, main subvector information related to the subvector selected as the subvector to be code converted.

[0056] [Code conversion example] Next, an example of the code conversion process in the code conversion unit 109 will be described.

[0057] For example, the code converting unit 109 may perform the following steps 1 to 3 based on the codebook instruction values ​​of the multiple subvectors input from the AVQ encoding unit 105 and the selected subvector to be code converted.

[0058] (Step 1) For example, the code converting unit 109 sets, among a plurality of (for example, N) codebook indicator values, the codebook indicator values ​​of other subvectors (for example, N-1 subvectors) at positions different from the subvector to be code converted, to a code (or an encoded code).Then, the code converting unit 109 may calculate, for example, the sum of the number of used bits of the codebook indicator values ​​and the number of used bits of the code vector index in the N-1 subvectors.

[0059] (Step 2) The code converting unit 109 may calculate, for example, the number of bits available for encoding the codebook indicator value of the sub-vector to be code converted. For example, the code converting unit 109 may calculate the number of bits available for encoding the codebook indicator value of the sub-vector to be code converted by subtracting the sum of the numbers of bits used for encoding the N-1 sub-vectors calculated in (Step 1) from the total number of bits available for AVQ encoding (AVQ bit-budget).

[0060] (Step 3) The code converting unit 109 may, for example, calculate the number of bits not used for encoding (e.g., referred to as the number of unused bits) from the number of bits available for encoding the subvector to be code converted calculated in (Step 2), and encode the number of unused bits. For example, the code converting unit 109 may calculate the number of unused bits by subtracting the sum of the number of bits used for the codebook indication value of the subvector to be code converted and the number of bits used for the code vector index from the number of available bits calculated in (Step 2).

[0061] The code conversion unit 109 may output, for example, the codebook indication value (encoded code) obtained by (step 1) to (step 3) and information obtained by encoding the number of unused bits (also referred to as, for example, the unused bit number indication value or the unused bit number encoded code) to the multiplexing unit 110.

[0062] Next, an example of the operation of the code conversion unit 109 will be described.

[0063] 6, 7 and 8 are flow charts showing examples of processing by the code conversion unit 109. In FIG.

[0064] 6, the code converting unit 109 may classify a plurality of sub-vectors to be coded into two groups (S201). For example, if the number of sub-vectors to be coded is eight (e.g., SV1 to SV8), the code converting unit 109 may classify the eight sub-vectors into the following two groups: Group 1: SV1 to SV5, excluding the sub-vector (SVd) selected for code conversion. Group 2: SV6 to SV8 and SVd

[0065] For example, if the sub-vector to be code converted is SVd=SV3, Group 1 may include SV1, SV2, SV4, and SV5, and Group 2 may include SV6 to SV8 and SV3. Also, if the sub-vector to be code converted is SVd=SV8, Group 1 may include SV1 to SV5, and Group 2 may include SV6 to SV83. Note that SVd is not limited to SV3 or SV8.

[0066] The code conversion unit 109 may, for example, sequentially encode the codebook index and the code vector index of the subvectors classified into Group 1 (S202). Then, the code conversion unit 109 may, for example, output encoding information (the codebook index and the code vector index) of the subvectors included in Group 1 to the multiplexing unit 110. Furthermore, the code conversion unit 109 may, for example, calculate the number of bits used for encoding Group 1 (represented as BITSgroup1, for example) (S202). Furthermore, the code conversion unit 109 may, for example, determine the number of bits available for encoding the subvectors classified into Group 2 (BITSgroup2, for example) based on the following equation (3) (S202). (BITSgroup2)=(AVQ bit-budget)-(BITSgroup1) (3)

[0067] The code conversion unit 109 may determine, for example, whether BITSgroup2 exceeds a threshold Threshold1 (S203).

[0068] If BITSgroup2 exceeds the threshold Threshold1 (S203: Yes), the code converting unit 109 may proceed to the process shown in FIG. 7 (for example, the process of S205).

[0069] On the other hand, if BITSgroup2 is equal to or smaller than the threshold Threshold1 (S203: No), the code converting unit 109 may determine the encoding order of the subvectors in Group2 as follows, and encode the subvectors in the determined order (S204). If SVd is any of SV1 to SV5: SVd, SV6, SV7, SV8 Other cases: SV6, SV7, SV8

[0070] Then, code conversion section 109 outputs the coding information including the codebook indication value and code vector index of each subvector of Group 2 to multiplexing section 110, and ends the code conversion process.

[0071] 7, for example, if SVd is not SV6, the code conversion unit 109 may update Group2 by excluding SV6 from Group2, encode SV6, and output encoded information including the codebook number code vector index of SV6 to the multiplexing unit 110 (S205). Also, the code conversion unit 109 may calculate the number of bits used to encode SV6 and update BITSgroup2 by subtracting the calculated number of bits from BITSgroup2. In other words, the updated BITSgroup2 may indicate the number of bits available for encoding SVs excluding SV6 from Group2.

[0072] If SVd is SV6, Group2 and BITSgroup2 do not need to be changed (or updated).

[0073] Next, the code converting unit 109 may determine whether or not BITSgroup2 exceeds a threshold Threshold2 (S206).

[0074] If BITSgroup2 exceeds the threshold Threshold2 (S206: Yes), the code converting unit 109 may proceed to the process shown in FIG. 8 (for example, the process of S208).

[0075] On the other hand, if BITSgroup2 is equal to or smaller than the threshold Threshold2 (S206: No), the code converting unit 109 may determine the encoding order of the subvectors in Group2 as follows, and encode the subvectors in the determined order (S207). If SVd is any of SV1 to SV6: SVd, SV7, SV8 Other cases: SV7, SV8

[0076] Then, code conversion section 109 outputs the coding information including the codebook indication value and code vector index of each subvector of Group 2 to multiplexing section 110, and ends the code conversion process.

[0077] 8, for example, if SVd is not SV7, the code conversion unit 109 may update Group2 by excluding SV7 from Group2, encode SV7, and output encoded information including the codebook number code vector index of SV7 to the multiplexing unit 110 (S208). Also, the code conversion unit 109 may calculate the number of bits used to encode SV7 and update BITSgroup2 by subtracting the calculated number of bits from BITSgroup2. In other words, the updated BITSgroup2 may indicate the number of bits available for encoding SVs excluding SV7 from Group2.

[0078] If SVd is SV7, Group2 and BITSgroup2 do not need to be changed (or updated).

[0079] Next, the code converting unit 109 may determine whether or not BITSgroup2 exceeds a threshold value Threshold3 (S209).

[0080] If BITSgroup2 is equal to or smaller than the threshold Threshold3 (S209: No), the code converting unit 109 may determine the encoding order of the subvectors in Group2 as follows, and encode the subvectors in the determined order (S210). If SVd is any of SV1 to SV7: SVd, SV8 Otherwise: SV8

[0081] Then, code conversion section 109 outputs the coding information including the codebook indication value and code vector index of each subvector of Group 2 to multiplexing section 110, and ends the code conversion process.

[0082] On the other hand, if BITSgroup2 exceeds the threshold Threshold3 (S209: Yes), the code converting unit 109 may determine the encoding order of the subvectors in Group2 as follows, and encode the subvectors in the determined order (S211). If SVd is any of SV1 to SV7: SV8, SVd Otherwise: SV8

[0083] Then, the code conversion unit 109 outputs coded information including the SV8 codebook indicator value and code vector index and the indicator value of the number of unused bits to the multiplexing unit 110, and ends the code conversion process. In other words, the code conversion unit 109 may output coded information of the number of unused bits to the multiplexing unit 110 instead of coded information of the SVd codebook indicator value.

[0084] When SVd is SV8, the code converting unit 109 may output, for example, either one of the SV8 codebook indication value and the indication value of the number of unused bits, and the code vector index to the multiplexing unit 110. Either one of the codebook indication value and the number of unused bits may be determined in advance.

[0085] In this way, the code conversion unit 109 may determine whether to encode the codebook number of SVd or the number of unused bits, based on the number of bits available for encoding in Group 2. For example, the code conversion unit 109 may determine to encode the codebook number (in other words, to output a codebook indication value) when the number of bits available for encoding Group 2 is equal to or smaller than a threshold (e.g., Threshold 1, Threshold 2, or Threshold 3), and may determine to encode the number of unused bits (in other words, to output a number of unused bits indication value) when the number of bits available for encoding Group 2 exceeds the threshold.

[0086] Here, in FIGS. 6, 7, and 8, the thresholds Threshold1, Threshold2, and Threshold3 may be set as follows.

[0087] For example, based on the number of bits fixedly allocated to AVQ, the average number of bits allocated per subvector is denoted as "BITSsv."

[0088] In the above example, for example, Threshold1 may be set to 4×BITSsv when SVd is any of SV1 to SV5, and may be set to 3×BITSsv when SVd is any of SV6 to SV8.

[0089] Also, for example, Threshold2 may be set to 3×BITSsv when SVd is any of SV1 to SV6, and may be set to 2×BITSsv when SVd is any of SV7 to SV8.

[0090] Also, for example, Threshold3 may be set to 2×BITSsv when SVd is any of SV1 to SV7, and may be set to BITSsv when SVd is SV8.

[0091] In this way, the number of bits obtained by multiplying BITSsv by the number of SVs classified into Group 2 may be set as the threshold.

[0092] [Example of encoding unused bits] Next, an example of encoding the number of unused bits in the code conversion unit 109 (for example, the process of S211 in FIG. 8) will be described.

[0093] FIG. 9 is a flowchart showing an example of the coding process of the unused bit number in the code conversion unit 109.

[0094] 9, the code conversion unit 109 determines whether the SV8 encoding result (e.g., codebook number) is zero (S301). In other words, the code conversion unit 109 may determine whether the SV8 is a null vector (or a zero vector). The process of S301 is a process for determining whether the SV8 encoding result is zero in AVQ encoding used in the EVS standard, and the number of bits available for AVQ has been used up for encoding subvectors, so that the encoding of the SV8 code 0 has been discontinued (e.g., the SV8 is encoded with 0 bits).

[0095] If SV8 is not zero (S301: No), the code conversion unit 109 may set the "number of unused bits" to, for example, the number of bits obtained by subtracting the number of bits used to encode the codebook number of SVd from the number of bits available for encoding the codebook number of SVd (S302).

[0096] Even when SV8 is not zero, there are cases in which the end of the codebook indication value of the SV8 encoding result (for example, stop bit 0) is truncated in AVQ encoding. In this case, the number of bits used in encoding SVd is reduced by 1 bit, but the shortage of 1 bit may be covered by truncating the stop bit 0 in encoding SVd, or the shortage of 1 bit may be covered by the number of bits saved by applying an embodiment of the present disclosure.

[0097] Furthermore, for example, if the encoding result of SV8 is zero and the stop bit 0 is truncated, there is a possibility that SV7 or SV6 will also be truncated (for example, SV7 or SV6 will be encoded with 0 bit). In this way, when two or more SVs are truncated, one bit (for example, codebook indication value 0) is assigned to the encoding of each of the two or more SVs, so the number of bits available for encoding SVd may be reduced by two or more bits. Such a case can be detected, for example, based on whether the number of bits available for encoding SVd is an odd number of bits compared to the number of bits used for encoding SV (for example, whether it is different from a multiple of 5).

[0098] As described above, in encoding the number of unused bits, the encoding order of SVd is set to the end of the subvectors included in Group 2 (in other words, swapped). Here, in FIG. 9, if SV8 is zero (S301: Yes), for example, there is a possibility that an SV encoded with 0 bits (e.g., an SV whose assigned number of bits is 0 and therefore not encoded) exists among the SVs encoded before SVd. For example, as in the process of S211 in FIG. 8, if encoding the number of unused bits is performed instead of encoding SVd, another SV may be encoded before SVd. If the SV encoded before SVd is an SV encoded with zero bits, one bit (e.g., the codebook indicated value 0 shown in FIG. 1) for encoding 0 for one SV is consumed (or wasted), and the number of bits available for encoding SVd (or the number of unused bits) may be reduced (or insufficient). Hereinafter, bits wasted for an SV encoded with zero bits are referred to as "wasted bits."

[0099] Note that when SV8 (or an SV before SV8) is coded with zero bits, the number of unused bits is 0 because all bits allocated for AVQ coding have been used up.

[0100] Therefore, if there is a difference between the number of bits available for encoding SVd (e.g., the number of remaining bits) and the number of bits used to encode SVd, this difference may correspond to the number of SVs encoded with zero bits. Also, for example, as shown in Figure 1, when the codebook number is 2 or greater, the number of bits used to encode SVd is a multiple of 5.

[0101] For example, the code conversion unit 109 may add the number of wasted bits to the number of bits available for encoding SVd (for example, the number of remaining bits) and update the number of bits available for encoding SVd to a multiple of 5 (S303). Also, the code conversion unit 109 may determine, for example, that the number of unused bits is zero.

[0102] In this way, the code conversion unit 109 may calculate the number of unused bits based on the number of bits that would normally be available for encoding SVd (in other words, when the encoding order of SVd is not rearranged) when wasted bits occur, by, for example, calculating the number of wasted bits and adding the wasted bits to the number of bits available for encoding SVd. In other words, the code conversion unit 109 may update the number of bits available for encoding SVd based on the number of consecutive subvectors whose quantization parameter is a null vector among subvectors different from the SVd of Group 2.

[0103] Next, the code conversion unit 109 may encode (e.g., convert into an indication value) the number of unused bits obtained in the process of S302 or S303 (S304). Fig. 10 is a diagram showing an example of encoding the number of unused bits. In Fig. 10, the number of unused bits different from 0 has a range, but the number of bits used for encoding is specified as a multiple of 5 (or 1), so that a unique number of bits can be derived depending on the number of available bits at the time of decoding.

[0104] As an example, if the number of available bits is 13 bits and the code (indication value) of the unused bits is "10", if there are no wasted bits, the number of unused bits can be specified as 3 bits since the number of bits excluding the unused bits is a multiple of 5.

[0105] Whether or not there are wasted bits can be determined, for example, by determining whether the decoded SV8 is a zero vector, and by using the remainder when the number of available bits is divided by 5 (for example, modulo 5) (hereinafter, also referred to as the "number of remaining bits"), and the number of consecutive decoded SVs that are zero vectors, including SV8. For example, if SV8 is not a zero vector, no wasted bits are generated. Also, for example, a wasted bit is generated when the number of unused bits is 0. The number of wasted bits can be specified, for example, by the number of consecutive decoded SVs that are zero vectors, including SV8, and the remainder of the number of available bits, modulo 5 (for example, the number of remaining bits).

[0106] The number of unused bits when wasted bits occur may be determined, for example, as follows.

[0107] As an example, if the number of bits available for encoding SVd is 12 bits, and the decoded value of three consecutive SVs, including SV8, is a zero vector (null vector), the three bits (e.g., 5-(12 modulo 5)=3) used to encode the three zero vectors (e.g., SV6 to SV8) when rearranging the encoding order of SVd are wasted bits. Therefore, the number of bits available for encoding SVd is 15 bits, obtained by adding 3 bits to 12 bits. As a result, the number of bits available for encoding SVd is equal to the number of bits used for encoding SVd (e.g., a multiple of 5), and the number of unused bits is zero.

[0108] As another example, consider a case where the number of bits available for encoding SVd is 13 bits, the decoded values ​​of three consecutive SVs (e.g., SV6 to SV8) including SV8 are zero vectors (null vectors), SV6 is encoded with 1 bit, and SV7 and SV8 are encoded with 0 bits (e.g., zero vectors without encoding). In this case, of the three bits used to encode the three zero vectors (encoding SV6 to SV8) when rearranging the encoding order of SVd, at least two bits (e.g., 5 - (13 modulo 5) = 2) are wasted bits. Therefore, the number of bits available for encoding SVd is 15 bits, obtained by adding 2 bits to 13 bits. As a result, the number of bits available for encoding SVd is equal to the number of bits used for encoding SVd (e.g., a multiple of 5), and the number of unused bits is zero.

[0109] For example, when the number of unused bits is 0, the number of bits used for encoding is 1, as shown in Fig. 10. Also, when the number of bits used for encoding SVd is 15, the codebook number is 3, and the number of bits used for encoding the codebook indication value is 3, as shown in Fig. 1. In the example above, the number of bits used for encoding the number of unused bits is 1, and there are 2 wasted bits, for a total of 3 bits. Therefore, when wasted bits occur, the number of bits used for encoding is the same when encoding the codebook indication value of SVd (for example, 3 bits) and when encoding the number of unused bits (for example, 1 bit + 2 wasted bits).

[0110] In this way, even if bits are wasted, the encoding device 100 can suppress an increase in the number of bits used for encoding and encode the number of unused bits.

[0111] Note that, since the number of unused bits is 0 when it is determined that a wasted bit has occurred, the code converting unit 109 may, for example, determine the number of unused bits to be 0 without changing (or updating) the number of bits available for encoding SVd and then calculating the difference from the number of bits used for encoding SVd. Note that, for example, when decoding the codebook number of SVd by dividing the number of bits available for encoding SVd by 5, the number of bits available for encoding SVd may be changed as described above. Alternatively, depending on the case, the decoding procedure may be changed so that the codebook number is decoded by adding 1 to the codebook number obtained by dividing the number of bits available for encoding SVd by 5.

[0112] 10 shows an example in which the codes for the number of unused bits are assigned in ascending order of the number of unused bits, but this is not limiting, and for example, the codes may be assigned in descending order of the frequency of occurrence of the number of unused bits. For example, the more frequently the number of unused bits appears, the fewer the number of bits may be assigned. This allows the number of bits used to encode the number of unused bits to be reduced.

[0113] [Example of the configuration of a decoding device] 11 is a block diagram showing an example of signal processing related to an AVQ decoding unit (hereinafter, for convenience, referred to as a "decoding device") 200 according to an embodiment of the present disclosure. The decoding device 200 shown in FIG. 11 may include, for example, a separating unit 201, a subvector identifying unit 202, a code converting unit 203 (e.g., corresponding to a control circuit), an AVQ decoding unit 204 (e.g., corresponding to an inverse quantization circuit), a floating bit count managing unit 205, and an inverse DCT unit 206.

[0114] In the decoding device 200 , the bit stream transmitted from the encoding device 100 is input to a demultiplexing unit 201 .

[0115] The demultiplexing unit 201 may, for example, demultiplex a global gain code, code vector indices, codebook indices, and an unused-bit number indicator value (unused-bit code or unused-bit index) from an AVQ code included in an input bitstream. The demultiplexing unit 201 may, for example, output the global gain code to the AVQ decoding unit 204, and output the codebook indicator value, code vector indices, and unused-bit number indicator value to the code conversion unit 203.

[0116] The subvector identification unit 202 may identify a dominant subvector from among a plurality of subvectors based on, for example, the input adaptive codebook vector v(n). The subvector identification unit 202 may output, for example, information related to the position of the dominant subvector (for example, dominant subvector information) to the code conversion unit 203. For example, since the target of quantization or encoding in the encoding device 100 (for example, the AVQ encoding unit 105) is a DCT coefficient, the subvector identification unit 202 may convert the adaptive codebook vector v(n) into a DCT coefficient and identify the position (or frequency) of the subvector having the maximum energy in the DCT coefficient domain of the adaptive codebook vector v(n). Note that if the target of quantization or encoding in the encoding device 100 is a time-domain signal, the subvector identification unit 202 does not need to convert the adaptive codebook vector v(n) into a DCT coefficient.

[0117] The code conversion unit 203 may calculate a codebook indicator value of a subvector at a specific position (e.g., a subvector to be code converted) based on, for example, information input from the demultiplexing unit 201 and information input from the subvector identifying unit 202. For example, the code conversion unit 203 may calculate the codebook indicator value of the subvector to be code converted based on the codebook indicator value, code vector index, and unused bit number indicator value input from the demultiplexing unit 201, and the number of bits available for AVQ (e.g., AVQ bit-budget) input from the AVQ decoding unit 204. The code conversion unit 203 may output the codebook indicator value and code vector index of each subvector to the AVQ decoding unit 204.

[0118] For example, the code conversion unit 203 may perform the following steps 4 to 7.

[0119] (Step 4) The code conversion unit 203 may, for example, decode a codebook indicator value of a sub-vector other than the sub-vector to be code converted based on the codebook indicator value. Furthermore, the code conversion unit 203 may, for example, calculate, based on the decoded codebook indicator value, the number of bits used for encoding the sub-vector other than the sub-vector to be code converted (for example, the sum of the number of bits used in the codebook indicator value and the number of bits used in the code vector).

[0120] (Step 5) The code conversion unit 203 may decode the number of unused bits based on, for example, the unused bit number indication value.

[0121] (Step 6) The code conversion unit 203 may calculate the number of coding bits for the sub-vector to be code converted, for example, based on the number of coding bits for the sub-vector calculated in (step 4) and the number of unused bits decoded in (step 5).

[0122] (Step 7) The code converting unit 203 may calculate (or decode) a codebook indication value of the subvector to be code converted, based on the number of coding bits of the subvector calculated in (Step 6), for example.

[0123] The AVQ decoding unit 204 may decode (or inverse quantize) the quantized DCT coefficients based on, for example, the global gain code input from the demultiplexing unit, the codebook instruction value and code vector index of each SV input from the code conversion unit 203, and the number of floating bits input from the number of floating bits management unit 205, and output the decoded quantized DCT coefficients to the inverse DCT unit 206. The AVQ decoding unit 204 may also determine (e.g., calculate) the number of bits to be allocated to AVQ based on, for example, the sum of a fixed number of bits (or a predetermined number of bits) and the number of floating bits input from the number of floating bits management unit 205, and output the determined number of bits to the code conversion unit 203. The AVQ decoding unit 204 may also output, for example, information regarding the number of floating bits, which is updated based on the number of bits remaining after the AVQ decoding process, to the number of floating bits management unit 205.

[0124] The floating bit number management unit 205 may hold (or manage) information regarding the number of bits available for use within a decoding processing frame, based on information regarding the number of floating bits input from the AVQ decoding unit 204. For example, the floating bit number management unit 205 may output the held number of bits as the number of floating bits to the AVQ decoding unit 204 for AVQ decoding of a subsequent subframe.

[0125] The inverse DCT unit 206 performs an inverse DCT transformation on the dequantized DCT coefficients input from the AVQ decoding unit 204, converting them into a time domain signal, and generates a decoded excitation residual signal q d It may be output as (n).

[0126] As described above, in this embodiment, the encoding device 100 determines whether to perform encoding of the codebook number for the subvector to be code converted or encoding based on the difference between the number of allocated bits for vector quantization and the number of bits of the quantization parameter (e.g., encoding of the number of unused bits) based on the number of bits available for encoding the subvector in vector quantization.

[0127] In this way, by switching between encoding the codebook number and encoding the number of unused bits based on the number of bits available for encoding, it is possible to perform encoding according to the number of bits available for encoding in multi-rate lattice vector quantization, thereby reducing the number of encoding bits. Thus, according to this embodiment, it is possible to reduce the number of encoding bits in multi-rate lattice vector quantization.

[0128] Furthermore, according to this embodiment, even when the subvector to be code converted into the unused bit number indication value is a subvector different from the last subvector (e.g., SV8) (in other words, when the encoding order is reversed), the encoding device 100 can accurately determine the number of unused bits according to the number of wasted bits that may result from the reversal of the encoding order. For example, when wasted bits occur, the encoding device 100 can accurately estimate the number of unused bits according to the number of wasted bits, thereby suppressing errors or a reduction in codebook number (e.g., a reduction in codebook accuracy) due to an insufficient number of coding bits, and suppressing degradation of encoding performance.

[0129] Note that, for example, even in the case of a bit allocation in which changing the SV coding order does not result in wasted bits (for example, in the case of a bit allocation in which no SV to be coded with 0 bits exists), if it is possible that wasted bits will occur (for example, if an SV to be coded with 0 bits exists), the coding apparatus 100 may rearrange the allocation of coding bits so that wasted bits will occur. As an example, a case will be described in which, in Group 2 including SVd, SV6, SV7, and SV8, SV6, SV7, and SV8 are coded with 0 (1 bit), SVd is coded with 10 bits (codebook number 2), and the number of bits available for coding SVd is 13 bits. In this case, since SV6 to SV8 are each a zero vector, the coding apparatus 100 may set the bit allocation for SV6 to SV8 to 0 bits and allocate (in other words, reallocate) the 3 bits allocated to SV6 to SV8 to the coding bits for SVd. Note that a wasted bit occurs (for example, 0 bit allocation is possible) when the number of unused bits is 0, and since the sum of the number of remaining bits and the number of consecutive zero vectors is limited to a multiple of 5, the subvectors for which 0 bit allocation is possible are SV7 and SV8. Therefore, the number of bits that can be reassigned to the coding bits of SVd is 2 bits. In this case, the encoding device 100 sets the number of available bits of SVd to 15 bits, for example, by adding 2 bits to 13 bits, and encodes SVd using codebook number 3 (for example, 15 bits). In this case, the number of unused bits is 0. In this way, by rearranging the bit allocation, it is possible to reliably determine whether or not there are wasted bits on the decoding side, and the encoding accuracy of SVd can be improved.

[0130] Furthermore, according to this embodiment, the decoding device 200 can identify coding information for a subvector to be code converted, based on parameters such as the number of bits used for coding and decoding information (e.g., a codebook indication value of a subvector different from the subvector to be code converted). Therefore, for example, a signal for switching between coding for the codebook indication value and coding for the number of unused bits (e.g., a flag or control information dedicated to switching) does not need to be notified from the coding device 100 to the decoding device 200.

[0131] (Embodiment 2) 12 is a block diagram showing an example configuration of an AVQ encoding unit (hereinafter referred to as "encoding device" for convenience) 300 according to an embodiment of the present disclosure. Note that in FIG. 12, components that perform the same processes as those of the encoding device 100 shown in FIG. 4 are denoted by the same reference numerals.

[0132] 12, the subvector identification unit 301 may output information relating to the position of a predetermined subvector (e.g., referred to as a target subvector or fixed subvector) to the code conversion unit 109. The predetermined subvector may be, for example, one of eight subvectors (e.g., SV1 to SV8). For example, in the following, a case will be described in which the predetermined subvector of the eight subvectors SV1 to SV8 is the third lowest subvector in the frequency domain (e.g., SV3) or the last subvector (e.g., SV8).

[0133] Note that the subvector identification unit 301 does not need to perform any signal processing to identify (specify) a subvector at a predetermined specific position, and for example, does not need to be explicitly provided as a component. In Fig. 12, as an example, the subvector identification unit 301 may be a memory that stores the positions of predetermined subvectors.

[0134] In the encoding device 300 shown in FIG. 12, the operations of the components other than the subvector identification unit 301 may be similar to the operations of the encoding device 100 shown in FIG.

[0135] Next, an example of the operation of the encoding device 300 that differs from that in the first embodiment will be described.

[0136] The method of selecting subvectors to be code converted may be the same as the method shown in Fig. 5. In this embodiment, the code converting unit 109 may use position information of subvectors identified in advance instead of the main subvector information. Furthermore, the subvector selection process may be performed, for example, by the subvector identifying unit 301 rather than by the code converting unit 109. In this case, AVQ bit-budget information may be input to the subvector identifying unit 301, and information regarding the subvector to be selected may be input to the code converting unit 109 as position information of the subvector.

[0137] 13 to 16 are flow diagrams illustrating exemplary operations of encoding device 300. As an example, Fig. 13 to 16 illustrate exemplary operations of encoding device 300 when the position of the subvector to be code converted is the third lowest subvector SV3 in the frequency domain.

[0138] 13, encoding apparatus 300 may classify subvectors SV1 to SV8 into Group 1 including SV1 and SV2 and Group 2 including five subvectors SV3 to SV8 (S401). For example, encoding apparatus 300 may classify subvectors SV1 to SV8 into Group 1 including subvectors (before the subvector to be code converted) and Group 2 including subvectors (after the subvector to be code converted). In other words, encoding apparatus 300 may classify subvectors SV1 to SV8 into Group 1 which does not include the subvector to be code converted and Group 2 which includes the subvector to be code converted.

[0139] Next, the encoding device 300 encodes the quantization parameters of the sub-vectors included in Group1 (e.g., SV1 and SV2) and outputs encoding information (e.g., codebook indication value and code vector index) (S402). Furthermore, the encoding device 300 may determine the number of bits used (or consumed) for encoding Group1, and may determine the number of bits available for encoding the sub-vectors of Group2 (e.g., SV3 to SV8).

[0140] Next, the encoding device 300 determines whether the number of bits available for encoding the sub-vectors of Group 2 is equal to or greater than a threshold value Threshold 1 (S403). For example, if the number of bits available for encoding the sub-vectors of Group 2 is less than Threshold 1 (S403: No), the encoding device 300 proceeds to the process shown in Fig. 14 (e.g., the process of S404), and if the number of bits available for encoding the sub-vectors of Group 2 is equal to or greater than Threshold 1 (S403: Yes), the encoding device 300 proceeds to the process shown in Fig. 15 (e.g., the process of S408).

[0141] Here, when the position of the subvector selected for code conversion is the third (e.g., SV3), Threshold1 may be set to 30 bits. For example, when SV3 is set as the last subvector to be coded among the subvectors SV1 to SV8 (in other words, when the coding order is changed), if the decoded results of the subvectors SV4 to SV8 after SV3 are 0 (e.g., null vectors), one bit may be used for coding each of them (e.g., up to five bits for five subvectors). On the other hand, when AVQ coding is used (in other words, when the coding order is not changed), SV4 to SV8 after SV3 may each be coded with 0 bits. If SV4 to SV8 are coded with 0 bits by AVQ coding, the coding method for code conversion according to this embodiment uses a total of five bits for coding SV4 to SV8, and thus a bit reduction of five or more bits is expected in coding SV3. 1 and 10, for example, the number of coding bits is 1 when the number of unused bits is 0, so to achieve a 5-bit reduction effect, the SV3 codebook number may be 6 or more. For example, when the codebook number is 6, the coding information including the code vector index is 30 bits. Therefore, the threshold Threshold1 may be set to 30 bits.

[0142] If the position of a specific subvector is different from SV3, the subbands included in Group 2 and the threshold Threshold 1 may be set according to the specific subvector. For example, if SV4 is set to a specific subvector, Group 2 may include SV4 to SV8, and Threshold 1 may be set to 25 bits.

[0143] 14, the encoding device 300 determines the encoding order of the subvectors in Group2 as SV3, SV4, SV5, SV6, SV7, and SV8, encodes SV3 to SV7, and outputs encoding information (e.g., codebook indication value and code vector index) (S404). The encoding device 300 may also determine the number of bits used to encode SV3 to SV7, and determine the number of bits available for encoding SV8 (S404).

[0144] In this way, for example, when the number of bits available for encoding Group 2 is less than Threshold 1 (S403: No), encoding device 300 does not need to perform code conversion on subvector SV3 (in other words, change the encoding order) in encoding Group 2. In other words, when the number of bits available for encoding Group 2 is less than Threshold 1, encoding device 300 may set (or change or update) the subvector to be code converted from SV3 to the last subvector in Group 2, SV8. This process can, for example, prevent a shortage of bits from occurring in encoding the subvector to be code converted.

[0145] Next, the encoding device 300 may determine, for example, whether the number of bits available for SV8 encoding is less than a threshold Threshold2 or exceeds a threshold Threshold3 (S405).

[0146] If the number of bits available for SV8 encoding is less than Threshold 2 or exceeds Threshold 3 (S405: Yes), the encoding device 300 may encode the SV8 using, for example, an AVQ encoding method (a method for encoding a codebook number), output encoding information (for example, a codebook indication value and a code vector index), and terminate the code conversion process (S406). In this way, if the number of bits available for SV8 encoding is less than Threshold 2 or exceeds Threshold 3, the encoding device 300 may encode the codebook number without encoding the unused bits, because the number of encoding bits is not reduced by encoding the unused bits.

[0147] On the other hand, if the number of bits available for SV8 encoding is equal to or greater than Threshold 2 and does not exceed Threshold 3 (S405: No), the encoding device 300 may encode the number of unused bits instead of encoding the codebook number, output encoding information (e.g., an indication value of the number of unused bits and a code vector index), and terminate the code conversion process (S407).

[0148] Here, for example, Threshold 2 may be set to 9 bits and Threshold 3 may be set to 80 bits. The reason for setting Threshold 2 to 9 bits is that, for example, if the number of bits available for SV8 encoding is less than 10 bits, the number of bits used for encoding the codebook number in AVQ encoding is also 1 bit, and the effect of reducing the number of bits by code conversion cannot be obtained.

[0149] Furthermore, for example, Threshold 3 may be set experimentally or empirically. For example, the greater the number of bits available for SV8 encoding, the greater the number of unused bits, so Threshold 3 may be set to avoid an increase in the number of unused bits. Note that a large number of unused bits may occur, for example, when the encoding target contains a small amount of information, such as silence, so even if no bit reduction effect is achieved, there is no problem with the encoding quality. For this reason, Threshold 3 may be set to a somewhat large number of bits empirically, for example.

[0150] 15, the encoding device 300 may determine the encoding order of the subvectors in Group2 as SV4, SV5, SV6, SV7, SV8, and SV3 (S408). In other words, the encoding device 300 may set the subvector SVd=SV3 to be code converted as the last subvector in Group2.

[0151] Next, the encoding device 300 may encode the subvectors one by one in the order of, for example, SV4, SV5, SV6, SV7, and SV8, and output encoding information (for example, a codebook indication value and a code vector index) (S409). Furthermore, the encoding device 300 may determine the number of bits used to encode the subvectors, and determine (in other words, update) the number of bits available for encoding the remaining subvectors of Group 2 (S409).

[0152] Next, the encoding device 300 determines whether the number of bits available for encoding the remaining subvectors of Group2 is equal to or greater than Threshold1 (S410).

[0153] If the number of bits available for encoding Group2 is less than Threshold1 (S410: No), encoding device 300 may, for example, proceed to the process of S404 in Fig. 14, change the encoding order of the remaining subvectors in Group2 to SV3 first, followed by the other remaining subvectors, and perform the encoding processes of S404 to S407 in Fig. 14. These processes are performed, for example, because the number of bits available for encoding Group2 is not sufficient to encode all of the remaining subvectors, and so the encoding order of SV3 is reversed to encode SV3 first.

[0154] On the other hand, if the number of bits available for encoding Group2 is equal to or greater than Threshold1 (S410: Yes), encoding device 300 determines, for example, whether the subvector to be encoded next is SV3 (S411). If the subvector to be encoded next is not SV3 (the subvector to be code converted) (S411: No), encoding device 300 may proceed to the process of S409, for example, and encode the next subvector. Encoding device 300 may repeat the processes of S409 to S411, for example, to encode SV4, SV5, SV6, SV7, and SV8 in order.

[0155] If the subvector to be coded next is SV3 (S411: Yes), the coding device 300 proceeds to the process of S412 shown in FIG. 16, for example.

[0156] In FIG. 16, the encoding device 300 may determine whether the number of bits available for encoding SV3 (=SVd) exceeds Threshold3 (S412).

[0157] If the number of bits available for SV3 encoding exceeds Threshold 3 (S412: Yes), encoding device 300 may, for example, encode SV3 based on AVQ encoding without performing code conversion, output coding information (e.g., codebook indicator value and code vector index), and end the code conversion process (S413). In this way, if the number of bits available for SV3 encoding exceeds Threshold 3, the number of unused bits increases, and the number of bits of the unused bit indicator value is likely to increase, so encoding device 300 may encode the codebook number.

[0158] On the other hand, if the number of bits available for encoding SV3 is less than or equal to Threshold 3 (S412: No), the encoding device 300 may, for example, encode the number of unused bits instead of encoding the SV3 codebook number, output encoding information (e.g., codebook indication value and code vector index), and terminate the code conversion process (S414).

[0159] Next, another example of the operation of the encoding device 300 will be described.

[0160] Fig. 17 is a flow diagram showing another example of the operation of encoding device 300. Fig. 17 shows, as an example, an example of the operation of encoding device 300 when the position of the subvector to be code converted is the subvector SV8 (e.g., the last subvector) at the highest position in the frequency domain.

[0161] Note that the operation example shown in Fig. 17 may be the same as the operation example shown in Fig. 14. Fig. 14 shows an operation example in which, when the position of a subvector selected as a target for code conversion is SV3 and code conversion of the coding information of SV3 is not possible (for example, the coding order of subvectors cannot be rearranged to code SV3 last in order to code the number of unused bits in SV3 coding), SV8 is switched to the subvector to be code converted instead of SV3, and it is determined whether coding the number of unused bits can be applied to coding SV8 (for example, whether coding the number of unused bits results in fewer coding bits than coding a codebook number).

[0162] 17, the encoding device 300 encodes, for example, SV1 to SV7 and outputs encoding information (for example, a codebook indication value and a code vector index) (S501). The encoding device 300 may also determine the number of bits used to encode SV1 to SV7 and the number of bits available for encoding SV8 (S501).

[0163] Next, the encoding device 300 may determine, for example, whether the number of bits available for SV8 encoding is less than a threshold Threshold2 or exceeds a threshold Threshold3 (S502).

[0164] If the number of bits available for SV8 encoding is less than Threshold 2 or more than Threshold 3 (S502: Yes), the encoding device 300 may encode the SV8 using, for example, an AVQ encoding method (encoding the codebook number), output encoding information (for example, a codebook indication value and a code vector index), and terminate the code conversion process (S503). In this way, if the number of bits available for SV8 encoding is less than Threshold 2 or more than Threshold 3, the encoding device 300 may encode the codebook number without encoding the unused bits, because the number of encoding bits is not reduced by encoding the unused bits.

[0165] On the other hand, if the number of bits available for SV8 encoding is equal to or greater than Threshold 2 and does not exceed Threshold 3 (S502: No), the encoding device 300 may encode the number of unused bits instead of encoding the codebook number, output encoding information (e.g., an unused bit number indication value and a code vector index), and terminate the code conversion process (S504).

[0166] In FIG. 17, for example, the values ​​set in FIG. 14 may be applied to Threshold2 and Threshold3.

[0167] Next, an example of the encoding process of the number of unused bits in the process of S407 in FIG. 14, the process of S414 in FIG. 16, or the process of S504 in FIG. 17 will be described.

[0168] FIG. 18 shows a flow diagram of an example of a process for encoding the number of unused bits.

[0169] 18, the encoding device 300 may determine, for example, whether the subvector to be code converted is SV8 (S601). If the subvector to be code converted is SV8 (S601: Yes), the encoding device 300 proceeds to the process of, for example, S605.

[0170] On the other hand, if the subvector to be code converted is not SV8 (e.g., SV3) (S601: No), the encoding order of the subvectors is changed, and the number of bits used to encode the subvectors after the encoding order change may differ from the number of bits used when encoding the subvectors without changing the encoding order (e.g., AVQ encoding). In other words, changing the encoding order may result in bits being wasted (e.g., wasted bits). For example, wasted bits may occur when the number of bits available for encoding becomes zero before encoding a subvector in the middle, and subsequent subvectors (e.g., consecutive subvectors including SV8) are forced to become zero vectors without being encoded (in other words, encoded with 0 bits).

[0171] In this embodiment, if the subvector to be code converted is not SV8 (S601: No), the encoding device 300 counts the number of consecutive subvectors whose quantization parameters are null vectors (hereinafter referred to as "Null Vector, all-zero vector, or zero vector") among the subvectors to be AVQ encoded, and checks whether the subvectors that are null vectors include SV8 (e.g., the last subvector) (S602). In other words, NCNV may indicate the number of consecutive subvectors that are null vectors and include SV8.

[0172] Furthermore, the encoding device 300 may calculate, for example, the number of remaining bits (hereinafter referred to as "RB") (S602). The number of remaining bits RB may be calculated, for example, by (the number of bits available for encoding the subvector to be code converted)%5, where "%" represents a modulo operation.

[0173] Next, the encoding device 300 may determine, for example, whether or not there is a possibility that wasted bits will occur due to the change in the encoding order of the subvectors (S603). The encoding device 300 may determine, for example, whether or not there is a possibility that wasted bits will occur based on NCNV and RB (an example of the determination will be described later). If there is no possibility that wasted bits will occur (S603: No), the encoding device 300 may proceed to the process of, for example, S605.

[0174] On the other hand, if there is a possibility that wasted bits will occur (S603: Yes), the encoding apparatus 300 may, for example, update the number of bits available for encoding the subvector to be code converted (e.g., SVd) (S604). For example, the encoding apparatus 300 may add (5-RB) bits to the number of bits available for encoding the subvector to be code converted. In other words, the encoding apparatus 300 may, for example, increase the number of bits available for encoding the subvector to be code converted by the number of wasted bits (e.g., the number of bits that may be used wastefully). Furthermore, the encoding apparatus 300 may, for example, update the number of remaining bits RB to 0 (S604).

[0175] The value "5" used to calculate the number of bits to add (e.g., 5-RB) and the number of remaining bits RB is just an example, and may be determined based on, for example, the ratio of the number of bits allocated to the codebook to the total number of bits used to encode multiple sub-vectors (e.g., 1 / 5), or a multiple of the number of bits used to encode the sub-vectors.

[0176] Next, the encoding device 300 determines whether the number of remaining bits RB is 4, for example (S605). If RB is not 4 (S605: No), the encoding device 300 may proceed to the process of S607, for example, and perform a process of determining the number of unused bits.

[0177] If RB=4 (S605: Yes), the encoding apparatus 300 may increase the number of bits available for encoding the subvector to be code converted by one bit (S606).

[0178] Next, the encoding device 300 may determine, for example, the number of unused bits (S607). For example, the encoding device 300 may calculate, as the number of unused bits, the difference between the number of bits available for the subvector to be code converted and the number of bits used to encode the subvector to be code converted (for example, the number of unused bits).

[0179] The encoding device 300 may, for example, encode the calculated number of unused bits (S608).

[0180] Next, an example of a method for determining whether or not there is a possibility that wasted bits will occur due to a change in the encoding order of subvectors in the process of S603 in FIG. 18 will be described.

[0181] For example, the encoding device 300 may determine that there is a possibility of wasted bits occurring when at least the following conditions 1 and 2 are satisfied. Condition 1: The SV8 after quantization (or the SV8 to be decoded) is a null vector. Condition 2: RB+NCNV≧4

[0182] For example, in the case of condition 1, if SV8 is not a null vector, all of the sub-vectors (e.g., SV1 to SV8) are coded in AVQ coding, so the number of bits used for coding remains the same whether the coding order of the sub-vectors is changed or not. Therefore, if SV8 is not a null vector, no wasted bits can occur. In other words, if SV8 is a null vector, there is a possibility that wasted bits will occur.

[0183] Furthermore, for example, in condition 2, wasted bits occur only when the number of unused bits (for example, the number of bits that become unused in AVQ encoding) is zero.

[0184] Here, for example, the number of remaining bits RB corresponds to the number of bits remaining due to the reduction (or shortage) of the number of bits available for encoding SVd caused by the change in the encoding order being wasted. Also, for example, the number of bits NCNV corresponds to the number of bits wasted (wasted bits) caused by the change in the encoding order.

[0185] Therefore, RB+NCNV can be a value of 5 or more. Note that, for example, while the number of bits used to encode a subvector is a multiple of 5 (e.g., 5n), there are cases where the last bit (stop bit) of the codebook indication value can be omitted, so RB+NCNV can be a value of 4 or more. Thus, in condition 2, if the number of unused bits is zero, RB+NCNV can be 4 or more. In other words, if RB+NCNV is 4 or more, the unused bits are zero and wasted bits may occur, and if RB+NCNV is less than 4, unused bits exist and so wasted bits cannot occur.

[0186] Condition 2 may be set as follows: Condition 2': If the number of remaining bits is RB, the number of consecutive null subvectors (including SV8) is "NCNVV", and the estimated codebook number is ECBI, then (number of bits available for SVd) + NCNVV ≥ 5 × ECBI + 4

[0187] Here, ECBI=(INT)(number of bits available for SVd / 5) may be used. The function (INT)(X) may be a function that returns the value of X truncated to an integer.

[0188] Next, an example of the operation of the AVQ decoding unit according to this embodiment will be described.

[0189] 19 is a block diagram showing an example configuration of an AVQ decoding unit (hereinafter referred to as a "decoding device" for convenience) 400 according to an embodiment of the present disclosure. Note that in FIG. 19, components that perform the same processes as those of the decoding device 200 shown in FIG. 11 are assigned the same reference numerals.

[0190] 19, the sub-vector identification unit 401 may output information relating to the position of a predetermined sub-vector (e.g., referred to as a target sub-vector or fixed sub-vector) to the code conversion unit 203. The predetermined sub-vector may be, for example, one of eight sub-vectors (e.g., SV1 to SV8). For example, in the following, a case will be described in which the predetermined sub-vector among the eight sub-vectors SV1 to SV8 is the third lowest sub-vector in the frequency domain (e.g., SV3) or the last sub-vector (e.g., SV8).

[0191] The subvector identification unit 401 does not need to perform any signal processing to identify (specify) a subvector at a predetermined specific position, and for example, does not need to be explicitly provided as a component. In Fig. 19, as an example, the subvector identification unit 401 may be a memory that stores the positions of predetermined subvectors.

[0192] In the decoding device 400 shown in FIG. 19, the operations of the components other than the subvector identification unit 401 may be similar to the operations of the decoding device 200 shown in FIG.

[0193] Next, an example of the operation of the decoding device 400 that differs from that in the second embodiment will be described.

[0194] The method of selecting subvectors to be code converted may be the same as the method shown in Fig. 5. In this embodiment, the code converting unit 203 may use position information of subvectors identified in advance instead of main subvector information. Furthermore, the subvector selection process may be performed, for example, by the subvector identifying unit 401 rather than by the code converting unit 203. In this case, AVQ bit-budget information may be input to the subvector identifying unit 401, and information regarding the subvector to be selected may be input to the code converting unit 203 as position information of the subvector.

[0195] 20 to 23 are flow diagrams illustrating exemplary operations of the decoding device 400. As an example, Fig. 20 to 23 illustrate exemplary operations of the decoding device 400 when the position of the subvector to be code converted is the third lowest subvector SV3 in the frequency domain.

[0196] In the explanation of FIGS. 20 to 23, the plurality of sub-vectors SV1 to SV8 and the thresholds Threshold1, Threshold2, and Threshold3 may be the same as those in FIGS.

[0197] 20, the decoding device 400 may, for example, decode the sub-vectors of Group 1 (e.g., SV1 and SV2) and output decoding information (e.g., codebook number and code vector index) (S701). Also, the decoding device 400 may, for example, calculate the number of bits of the bit string used to decode the sub-vectors of Group 1 (e.g., SV1 and SV2), and calculate the number of bits remaining as the bit string of the sub-vectors of Group 2 (remaining bits) by subtracting the number of bits used to decode SV1 and SV2 from the number of bits allocated to the entire AVQ (e.g., AVQ bit-budget) (S701).

[0198] Next, the decoding device 400 determines whether the number of bits remaining as the bit string of the sub-vectors of Group 2 is equal to or greater than a threshold value Threshold 1 (S702). For example, if the number of bits remaining as the bit string of the sub-vectors of Group 2 is less than Threshold 1 (S702: No), the decoding device 400 proceeds to the processing shown in Fig. 21 (e.g., the processing of S703), and if the number of bits remaining as the bit string of the sub-vectors of Group 2 is equal to or greater than Threshold 1 (S702: Yes), the decoding device 400 proceeds to the processing shown in Fig. 22 (e.g., the processing of S703).

[0199] 21, the decoding device 400 determines (or interprets) the coding order of the subvectors in Group 2 as SV3, SV4, SV5, SV6, SV7, and SV8, decodes SV3 to SV7, and outputs the decoding results (codebook number and code vector index) (S703). Furthermore, the decoding device 400 may calculate the number of bits in the bit strings used to decode SV3 to SV7, and calculate the number of bits remaining as the bit string (encoded code) of SV8 (S703).

[0200] In this way, for example, if the number of bits remaining as a bit string of a subvector of Group 2 is less than Threshold 1 (S702: No), the decoding device 400 may determine that the encoding device 100 has not performed code conversion (in other words, rearrangement of the encoding order) on the subvector SV3 to be code converted.

[0201] Next, the decoding device 400 may determine whether the number of bits remaining as an SV8 bit string is less than a threshold Threshold2 or exceeds a threshold Threshold3 (S704).

[0202] If the number of bits remaining as the SV8 bit string is less than Threshold 2 or more than Threshold 3 (S704: Yes), the decoding device 400 may, for example, determine that the SV8 is encoded using the AVQ encoding method (a method for encoding a codebook number), decode the SV8, output decoding information (e.g., the codebook number and code vector index), and terminate the decoding process (S705).

[0203] On the other hand, if the number of bits remaining in the SV8 bit string is equal to or greater than Threshold 2 but does not exceed Threshold 3 (S704: No), the decoding device 400 determines, for example, that the number of unused bits is to be encoded instead of the SV8 codebook number, and decodes the number of unused bits and the code vector index (S706). The decoding device 400 may also determine the SV8 codebook number based on, for example, the number of bits remaining in the SV8 bit string and the decoded number of unused bits (S706). An example of a method for determining the codebook number will be described later. The decoding device 400 may output the determined SV8 decoding information (for example, the codebook number and the code vector index) and terminate the decoding process.

[0204] 22, the decoding device 400 may determine (or interpret) the coding order of the subvectors in Group 2 as SV4, SV5, SV6, SV7, SV8, and SV3 (S707). In other words, the decoding device 400 may set the subvector SVd=SV3 to be code converted as the last subvector in Group 2.

[0205] Next, the decoding device 400 may decode the subvectors one by one in the order of, for example, SV4, SV5, SV6, SV7, and SV8, and output decoding information (for example, a codebook number and a code vector index) (S708). Furthermore, the decoding device 400 may determine the number of bits in a bit string used to decode the subvector, and may determine the number of bits in the bit strings of the remaining subvectors in Group 2 (S708).

[0206] Next, the decoding device 400 determines whether the number of bits in the bit strings of the remaining subvectors of Group 2 is equal to or greater than Threshold 1 (S709).

[0207] If the number of bits in the bit strings of the remaining subvectors in Group 2 is less than Threshold 1 (S709: No), the decoding device 400 may, for example, proceed to processing S703 in Figure 21, change the encoding order of the remaining subvectors in Group 2 to SV3, then the other remaining subvectors, and perform the decoding processing of S703 to S706 in Figure 21.

[0208] On the other hand, if the number of bits in the bit strings of the remaining subvectors of Group 2 is equal to or greater than Threshold 1 (S709: Yes), decoding device 400 determines, for example, whether the subvector to be decoded next is SV3 (S710). If the subvector to be decoded next is not SV3 (the subvector to be code converted) (S710: No), decoding device 400 may proceed to the process of S708, for example, and decode the next subvector. Decoding device 400 may repeat the processes of S708 to S710, for example, to decode SV4, SV5, SV6, SV7, and SV8 in order.

[0209] If the subvector to be decoded next is SV3 (S710: Yes), the decoding device 400 proceeds to the process of S711 shown in FIG. 23, for example.

[0210] In FIG. 23, the decoding device 400 may determine whether or not the number of bits remaining as the bit string of SV3 (=SVd) exceeds Threshold3 (S711).

[0211] If the number of bits remaining as the SV3 bit string exceeds Threshold 3 (S711: Yes), the decoding device 400 may, for example, decode the SV3 based on the AVQ encoding method without performing code conversion, output decoding information (e.g., codebook number and code vector index), and terminate the decoding process (S712).

[0212] On the other hand, if the number of bits remaining in the SV3 bit string is equal to or less than Threshold 3 (S711: No), the decoding device 400 may, for example, decode an unused bit number indication value instead of the SV3 codebook number, and may also decode a code vector index (S713). The decoding device 400 may also determine the SV3 codebook number based on the number of bits remaining in the SV3 bit string and the decoded unused bit number information (S713). The decoding device 400 may, for example, output the SV3 codebook number and code vector index, and then terminate the decoding process. An example of a method for determining the codebook number will be described later.

[0213] Next, another example of the operation of the decoding device 400 will be described.

[0214] Fig. 24 is a flow diagram showing another example of the operation of the decoding device 400. Fig. 24 shows, as an example, an example of the operation of the decoding device 400 when the position of the subvector to be code converted is the subvector SV8 (e.g., the last subvector) at the highest position in the frequency domain.

[0215] For example, the process in Fig. 24 is an example of a decoding process corresponding to the encoding process shown in Fig. 17. Furthermore, the example of operation shown in Fig. 24 may be the same as the example of operation shown in Fig. 21, for example.

[0216] 21, the decoding device 400 decodes, for example, SV1 to SV7 and outputs decoding information (for example, a codebook number and a code vector index) (S801). Also, the decoding device 400 may determine the number of bits of a bit string used to decode SV1 to SV7, and determine the number of bits remaining as a bit string of SV8 (S801).

[0217] Next, the decoding device 400 may determine whether the number of bits remaining as an SV8 bit string is less than a threshold Threshold2 or exceeds a threshold Threshold3 (S802).

[0218] If the number of bits remaining as the SV8 bit string is less than Threshold 2 or more than Threshold 3 (S802: Yes), the decoding device 400 may, for example, determine that the SV8 is encoded using the AVQ encoding method (a method for encoding a codebook number), decode the SV8, output decoding information (e.g., the codebook number and code vector index), and terminate the decoding process (S803).

[0219] On the other hand, if the number of bits remaining in the SV8 bit string is equal to or greater than Threshold 2 but does not exceed Threshold 3 (S802: No), the decoding device 400 determines, for example, that the number of unused bits is to be encoded instead of the SV8 codebook number, and decodes the number of unused bits and the code vector index (S804). The decoding device 400 may also determine the SV8 codebook number based on, for example, the number of bits remaining in the SV8 bit string and the decoded number of unused bits (S804). An example of a method for determining the codebook number will be described later. The decoding device 400 may output the determined SV8 decoding information (for example, the codebook number and the code vector index) and terminate the decoding process.

[0220] Next, an example of the SVd (for example, SV3 or SV8) decoding process in the process of S706 in FIG. 21, the process of S713 in FIG. 23, or the process of S804 in FIG. 24 will be described.

[0221] Fig. 25 shows a flow diagram of an example of a decoding process of SVd. The process shown in Fig. 25 may correspond to, for example, the encoding process shown in Fig. 18. The process shown in Fig. 25 includes, for example, a procedure for determining a codebook number of SVd based on the number of bits remaining as the encoded bit string of SVd and the number of unused bits.

[0222] 25, the decoding device 400 may determine, for example, whether the subvector to be code converted is SV8 (S901). If the subvector to be code converted is SV8 (S901: Yes), the decoding device 400 proceeds to the process of, for example, S905.

[0223] On the other hand, if the subvector to be code converted is not SV8 (here, for example, SV3) (S901: No), the decoding device 400 may, for example, count the number of consecutive subvectors (including SV8) whose quantization parameter is a null vector (zero vector) (e.g., NCNV) in the decoded subvectors (S902).

[0224] Furthermore, the decoding device 400 may calculate, for example, the number of remaining bits (for example, RB) (S902). The number of remaining bits RB may be calculated, for example, by (the number of bits remaining as the code bit string of the sub-vector (for example, SV3) to be code converted)%5. Here, "%" represents a modulo operation.

[0225] Next, the decoding device 400 may determine whether to update the number of bits remaining in the bit string of SVd (e.g., SV3) based on, for example, NCNV and RB (S903). In other words, the decoding device 400 may determine whether there is a possibility that wasted bits have occurred due to, for example, a change in the encoding order of the subvectors. Note that the determination method in S903 may be the same as the determination method in the encoding device 300.

[0226] If there is no possibility that a wasted bit has occurred (S903: No), the decoding device 400 proceeds to the process of, for example, S905.

[0227] On the other hand, if there is a possibility that wasted bits have occurred (S903: Yes), the decoding device 400 may, for example, update the number of bits remaining as a bit string of a subvector to be code converted (e.g., SVd) (S904). For example, the decoding device 400 may add (5-RB) bits to the number of bits remaining as a bit string of a subvector to be code converted. In other words, the decoding device 400 may, for example, increase the number of bits remaining as a bit string of SVd by the number of wasted bits (e.g., the number of bits that may be used wastefully). Furthermore, the decoding device 400 may, for example, update the number of remaining bits RB to 0 (S904).

[0228] Next, the decoding device 400 determines whether the number of remaining bits RB is 4 bits (S905). If RB is not 4 (S905: No), the decoding device 400 may proceed to the process of S907, for example, and determine the code length of SVd obtained by AVQ encoding based on the number of unused bits (an example will be described later).

[0229] If RB=4 (S905: Yes), the decoding device 400 may increase the number of bits remaining as the bit string of the subvector to be code converted by one bit, for example (S906).

[0230] Next, the decoding device 400 may determine the code length of the SVd obtained by AVQ encoding, for example, based on the unused bit number information (S907). For example, the decoding device 400 may calculate the code length of the SVd (for example, the number of bits of the code (bit string) obtained by AVQ encoding) by subtracting the number of unused bits to be decoded from the number of bits remaining as the bit string of the subvector to be code converted.

[0231] As an example, when the association between the number of unused bits and the code (unused bit number indication value) is defined as shown in FIG. 10, the code length of SV8 may be determined as follows. SV8 code length = (INT(number of bits remaining as SV8 encoded bit string - (number of bits in Figure 10 - 1) x 5) / 5) + 1) x 5

[0232] For example, if the number of bits remaining in the SV8 encoded bit string is 13 bits and the code for the number of unused bits is 10, the SV8 code length is (INT((13-5) / 5)+1)×5=10 bits. Note that when the code for the number of unused bits is 10, the number of unused bits to be decoded is any one of 1 to 5 bits based on FIG. 10, but if the number of bits remaining in the SV8 encoded bit string is 13 bits, the number of unused bits to be decoded may be specified as 3. This is because the code length of the subvector is set to a multiple of 5.

[0233] Next, the decoding device 400 may decode the codebook number and code vector index of SVd based on the code length of SVd (S908). For example, when the code length of SV8 is 10 bits, the decoding device 400 may decode the codebook number=2 based on FIG.

[0234] As described above, in this embodiment, the encoding device 300 determines whether to perform encoding of the codebook number for the subvector to be code converted or encoding based on the difference between the number of allocated bits for vector quantization and the number of bits of the quantization parameter (e.g., encoding of the number of unused bits), based on the number of bits available for encoding the subvector in vector quantization.

[0235] In this way, by switching between encoding the codebook number and encoding the number of unused bits based on the number of bits available for encoding, it is possible to perform encoding according to the number of bits available for encoding in multi-rate lattice vector quantization, thereby reducing the number of encoding bits. Thus, according to this embodiment, it is possible to reduce the number of encoding bits in multi-rate lattice vector quantization.

[0236] Furthermore, according to this embodiment, even when the subvector to be code converted into the unused bit number indication value is a subvector different from the last subvector (e.g., SV8) (in other words, when the encoding order is reversed), the encoding device 300 can accurately determine the number of unused bits according to the number of wasted bits that may result from the reversal of the encoding order.

[0237] Furthermore, according to this embodiment, the decoding device 400 can identify coding information for a subvector to be code converted, based on parameters such as the number of bits used for coding and decoding information (e.g., a codebook indication value of a subvector different from the subvector to be code converted). Therefore, for example, a signal for switching between coding for the codebook indication value and coding for the number of unused bits (e.g., a flag or control information dedicated to switching) does not need to be notified from the coding device 300 to the decoding device 400.

[0238] The embodiments of the present disclosure have been described above.

[0239] In an embodiment of the present disclosure, the codebook list is not limited to the example shown in Fig. 1, and the codebook indicator value in the codebook and the code value and the number of used bits (or the total number of used bits) of the code vector index may be other values. Also, the above-mentioned threshold may be set according to the codebook list applied to encoding and decoding.

[0240] Also, for example, in FIG. 1, a case has been described in which the ratio of the number of bits used by the codebook indication value to the total number of bits used in each codebook is 1 / 5 (in other words, when using a remainder, the divisor is 5), but this is not limiting.

[0241] Furthermore, in the above-described embodiment, the case where the number of sub-vectors into which the input signal S(f) is divided is described as eight, but the number of sub-vectors into which the input signal S(f) is divided is not limited to eight.

[0242] Furthermore, in the above-described embodiment, as an example, an input signal is divided into a plurality of subvectors in the frequency domain. However, the present disclosure is not limited to this, and the input signal may be divided into a plurality of subvectors in the time domain. In the case of the time domain, for example, the subvector SVd to be code converted may be set to a specific subvector among the subvectors arranged in the time domain (for example, the third subvector from the earliest or the last subvector). Thus, in an embodiment of the present disclosure, when an input signal is divided into subvectors of a certain length in either the frequency domain or the time domain, the subvector SVd to be code converted may be set to a subvector of any order among the arranged subvectors (for example, a subvector of a specific order (for example, the third subvector) or the last subvector).

[0243] Furthermore, in the above-described embodiment, vector quantization is not limited to AVQ, and other methods may be used.

[0244] The present disclosure can be realized by software, hardware, or software integrated with hardware. Each functional block described in the above embodiments may be partially or entirely realized as an LSI, which is an integrated circuit. Each process described in the above embodiments may be partially or entirely controlled by a single LSI or a combination of LSIs. An LSI may be composed of individual chips, or may be composed of a single chip that includes some or all of the functional blocks. An LSI may have data inputs and outputs. Depending on the level of integration, an LSI may be referred to as an IC, system LSI, super LSI, or ultra LSI. The integration method is not limited to LSIs; it may also be realized by dedicated circuits, general-purpose processors, or dedicated processors. Furthermore, a field programmable gate array (FPGA), which can be programmed after LSI fabrication, or a reconfigurable processor, which allows the connections and settings of circuit cells within an LSI to be reconfigured, may also be used. The present disclosure may be realized as digital or analog processing. Furthermore, if an integrated circuit technology that can replace LSI emerges due to advances in semiconductor technology or other derivative technologies, it is natural that such technology can be used to integrate functional blocks. The application of biotechnology is also a possibility.

[0245] The present disclosure may be implemented in any type of apparatus, device, or system (collectively referred to as a communications apparatus) that has a communications function. The communications apparatus may include a wireless transceiver and processing / control circuitry. The wireless transceiver may include a receiver and a transmitter, or both functions. The wireless transceiver (transmitter and receiver) may include a radio frequency (RF) module and one or more antennas. The RF module may include an amplifier, an RF modulator / demodulator, or the like. Non-limiting examples of communication devices include telephones (e.g., cell phones, smartphones), tablets, personal computers (PCs) (e.g., laptops, desktops, notebooks), cameras (e.g., digital still / video cameras), digital players (e.g., digital audio / video players), wearable devices (e.g., wearable cameras, smartwatches, tracking devices), game consoles, digital book readers, telehealth / telemedicine devices, communication-enabled vehicles or mobile transportation (e.g., cars, airplanes, ships), and combinations of the above devices.

[0246] Communications equipment is not limited to portable or mobile equipment, but also includes non-portable or fixed equipment, devices, and systems of any kind, such as smart home devices (such as appliances, lighting equipment, smart meters or metering devices, control panels, etc.), vending machines, and any other "things" that may exist on an IoT (Internet of Things) network.

[0247] Communications include data communications via cellular systems, wireless LAN systems, communications satellite systems, etc., as well as data communications via combinations of these.

[0248] A communications apparatus also includes devices such as controllers and sensors connected or coupled to a communications device that performs the communications functions described in this disclosure, such as controllers and sensors that generate control and data signals used by the communications device to perform the communications functions of the communications apparatus.

[0249] The communication apparatus also includes infrastructure facilities, such as base stations, access points, and any other apparatus, device, or system that communicates with or controls the various apparatuses listed above, but are not limited to these.

[0250] An encoding device according to one embodiment of the present disclosure includes a quantization circuit that generates a quantization parameter including information about a vector quantization codebook, and a control circuit that determines whether to perform a first encoding of the information for a target subvector based on the number of bits available for encoding a subvector in the vector quantization, or a second encoding based on the difference between the number of allocated bits for the vector quantization and the number of bits of the quantization parameter.

[0251] In one embodiment of the present disclosure, the control circuit classifies a plurality of subvectors into a first group that does not include the target subvector and a second group that includes the target subvector, encodes the quantization parameters of the subvectors included in the first group, and determines whether to perform the first encoding or the second encoding based on the number of available bits in the second group.

[0252] In one embodiment of the present disclosure, when the number of available bits in the second group is less than a first threshold, the control circuit sets the target subvector to the subvector in the second group with the highest frequency or the last subvector in the time domain.

[0253] In one embodiment of the present disclosure, the control circuit determines to perform the first encoding when the number of available bits of the target subvector is less than a second threshold or greater than a third threshold, and determines to perform the second encoding when the number of available bits of the target subvector is greater than or equal to the second threshold and less than or equal to the third threshold.

[0254] In one embodiment of the present disclosure, the control circuit determines to perform the first encoding when the number of available bits of the target subvector exceeds a threshold, and determines to perform the second encoding when the number of available bits of the target subvector is less than the threshold.

[0255] In one embodiment of the present disclosure, the control circuit sets the encoding order of the target subvector to be the last of the subvectors included in the second group in the second encoding.

[0256] In one embodiment of the present disclosure, the control circuit updates the number of available bits based on the number of consecutive subvectors in the second group that are different from the target subvector and whose quantization parameter indicates a null vector.

[0257] In one embodiment of the present disclosure, the control circuit adds a value obtained by subtracting the remainder of the number of usable bits modulo 5 from 5 to the number of usable bits.

[0258] In one embodiment of the present disclosure, the plurality of subvectors include eight subvectors, and the target subvector is the third lowest subvector in the frequency domain or the third earliest subvector in the time domain among the eight subvectors.

[0259] In one embodiment of the present disclosure, the target subvector is the subvector with the highest frequency among the plurality of subvectors or the last subvector in the time domain.

[0260] In one embodiment of the present disclosure, the target subvector is a subvector among the plurality of subvectors that has the highest energy of an adaptive codebook vector.

[0261] In one embodiment of the present disclosure, the number of bits of coded information for a candidate with a higher occurrence probability among the information coded for each of the second number of bits is smaller.

[0262] A decoding device according to one embodiment of the present disclosure includes a control circuit that determines whether to perform first decoding of first information related to a codebook of vector quantization for a target subvector based on the number of bits available for encoding subvectors in vector quantization, or second decoding based on the difference between the number of allocated bits of the vector quantization and the number of bits of a quantization parameter including the first information, and an inverse quantization circuit that performs inverse vector quantization based on the result of either the first decoding or the second decoding.

[0263] In an encoding device according to one embodiment of the present disclosure, the encoding device generates a quantization parameter including information about a codebook for vector quantization, and determines whether to perform a first encoding of the information for a target subvector based on the number of bits available for encoding a subvector in the vector quantization, or a second encoding based on the difference between the number of allocated bits for the vector quantization and the number of bits of the quantization parameter.

[0264] In a decoding method according to one embodiment of the present disclosure, a decoding device determines whether to perform first decoding of first information regarding the vector quantization codebook for a target subvector based on the number of bits available for encoding subvectors in vector quantization, or second decoding based on the difference between the number of allocated bits for vector quantization and the number of bits of a quantization parameter including the first information, and performs inverse vector quantization based on the result of either the first decoding or the second decoding.

[0265] The disclosures of the U.S. provisional application No. 63 / 164,942 filed on March 23, 2021, and the specification, drawings, and abstract contained in the Japanese patent application No. 2021-118130 filed on July 16, 2021, are incorporated herein by reference in their entirety. [Industrial Applicability]

[0266] An embodiment of the present disclosure is useful for coding systems and the like. [Explanation of symbols]

[0267] 100,300 encoder 101 Multiplication section 102 Subtractor 103 De-emphasis section 104 DCT section 105 AVQ encoding section 106,205 Floating bit number management section 107,206 Inverse DCT section 108,202,301,401 Subvector identification part 109,203 Code conversion unit 110 Multiplexer 200 Decryption Device 201 Separation section 204 AVQ Decoding Unit

Claims

1. a receiving unit that receives, from the encoding device, a bitstream obtained by encoding quantization parameters, the quantization parameters including a codebook index indicating a codebook used for vector quantization in the encoding device and a codevector index indicating a codevector selected from a plurality of codevectors included in the codebook, for each of a plurality of subvectors obtained by dividing a frequency domain signal, or a bitstream obtained by encoding a number of unused bits obtained by subtracting a number of bits required to encode the quantization parameters of the subvector from a number of bits available for encoding the quantization parameters of the subvector in the encoding device; for each sub-vector that has received the coded quantization parameter, obtaining the codebook index and the code vector index by decoding the coded quantization parameter; a decoding unit that decodes the number of unused bits before encoding for a target subvector that is a subvector that has received the encoded number of unused bits, calculates the number of bits available for encoding the quantization parameter of the target subvector by subtracting the sum of the number of bits used for encoding the quantization parameter of each of the plurality of subvectors other than the target subvector from the number of allocated bits allocated to vector quantization in one subframe including the plurality of subvectors (AVQ bit budget), calculates the number of bits required for encoding the quantization parameter of the target subvector by subtracting the decoded number of unused bits from the calculated number of available bits, and estimates the codebook index and the code vector index; an inverse quantization unit that performs inverse vector quantization based on the codebook index and the code vector index of each sub-vector other than the target sub-vector and the codebook index and the code vector index of the target sub-vector, and outputs a frequency domain signal after the vector quantization for each of the plurality of sub-vectors; A decoding device comprising:

2. the receiving unit receives identification information for identifying the target subvector; the decoding unit decodes the number of unused bits before encoding for a target subvector identified by the identification information among the plurality of subvectors, and estimates the codebook index and the code vector index. The decoding device according to claim 1 .

3. a value obtained by subtracting a remainder of the number of usable bits modulo 5 from 5 is added to the number of usable bits in the encoding device; the decoding unit subtracts a value obtained by subtracting a remainder of the number of usable bits from 5 from the decoded number of unused bits, and then calculates the number of bits required to encode the quantization parameter of the target subvector. The decoding device according to claim 1 .

4. The target subvector is a subvector with the highest frequency among the plurality of subvectors. The decoding device according to claim 1 .

5. The target subvector is the third lowest subvector in the frequency domain among the eight subvectors. The decoding device according to claim 1 .

6. The target sub-vector is a sub-vector among the plurality of sub-vectors that has the highest energy of a codebook vector. The decoding device according to claim 1 .

7. receiving, from the encoding device, a bitstream in which quantization parameters, for each of a plurality of sub-vectors obtained by dividing a frequency domain signal, include a codebook index indicating a codebook used for vector quantization in the encoding device and a codevector index indicating a codevector selected from a plurality of codevectors included in the codebook, or a bitstream in which a number of unused bits obtained by subtracting a number of bits required to encode the quantization parameter of the sub-vector from a number of bits available for encoding the quantization parameter of the sub-vector in the encoding device, are encoded; for each sub-vector that has received the coded quantization parameter, obtaining the codebook index and the code vector index by decoding the coded quantization parameter; For a target subvector that is a subvector that has received the coded number of unused bits, the method decodes the number of unused bits before coding, calculates the number of bits available for coding the quantization parameter of the target subvector by subtracting the sum of the number of bits used for coding the quantization parameter of each of the subvectors other than the target subvector from the number of allocated bits allocated to vector quantization in one subframe including the plurality of subvectors (AVQ bit budget), calculates the number of bits required for coding the quantization parameter of the target subvector by subtracting the decoded number of unused bits from the calculated number of available bits, and estimates the codebook index and the code vector index; performing inverse vector quantization based on the codebook index and the code vector index of each subvector other than the target subvector and the codebook index and the code vector index of the target subvector, thereby outputting a frequency domain signal after vector quantization for each of the plurality of subvectors. Decryption method.

8. receiving identification information for identifying the target subvector; decoding the number of unused bits before encoding for a target sub-vector identified by the identification information among the plurality of sub-vectors, and estimating the codebook index and the code vector index; The decoding method according to claim 7.

9. a value obtained by subtracting a remainder of the number of usable bits modulo 5 from 5 is added to the number of usable bits in the encoding device; subtracting a value obtained by subtracting the remainder of the number of available bits from 5 from the number of decoded unused bits, and then calculating the number of bits required to encode the quantization parameter of the target subvector; The decoding method according to claim 7.

10. The target subvector is a subvector with the highest frequency among the plurality of subvectors. The decoding method according to claim 7.

11. The target subvector is the third lowest subvector in the frequency domain among the eight subvectors. The decoding method according to claim 7.

12. The target sub-vector is a sub-vector among the plurality of sub-vectors that has the highest energy of a codebook vector. The decoding method according to claim 7.

Citation Information

Patent Citations

  • Encoding method, apparatus and device, and decoding method

    JP2012194574A

  • Energy lossless encoding method and device thereof, signal encoding method and device thereof, energy lossless decoding method and device thereof, and signal decoding method and device thereof

    JP2016535317A

  • Method and Apparatus for Audio Coding

    US20100223061A1

  • Multi-Rate Algebraic Vector Quantization with Supplemental Coding of Missing Spectrum Sub-Bands

    US20120146831A1

  • Audio and speech coding device, audio and speech decoding device, method for coding audio and speech, and method for decoding audio and speech

    WO2013118476A1