Coding method, device, program product and recording medium
By selecting encoding processing based on the energy and sparsity of the high frequency component of the audio signal in the frequency domain, the existing technology has solved the problem of low encoding efficiency under large spectrum envelope fluctuations and high spectrum concentration, and achieved efficient encoding and excellent decoding Sound quality.
Patent Information
- Application Number
- CN202110195328.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2014-07-28
- Filing Date
- 2015-05-15
- Publication Date
- 2024-12-06
- Estimated Expiration
- 2035-05-15
AI Technical Summary
The existing audio signal encoding methods are inefficient when the spectrum envelope fluctuates greatly, and cannot efficiently encode, and do not handle the high spectrum concentration, resulting in an increase in code volume and affecting the decoding sound quality.
The choice of multiple encoding processes in the frequency domain is adopted, and the encoding process is determined based on the energy and sparsity of the high-frequency component energy and sparseness of the input audio signal, and a suitable encoding method is selected to reduce the code amount and improve the decoding sound quality. The specific steps include frequency domain transformation, the decision unit determines the energy threshold of the high-frequency component, divides the frequency domain coefficient series and performs variable length encoding, and selects linear prediction coefficient encoding or average energy differential encoding.
It realizes efficient encoding under different audio signal characteristics, reduces the number of codes, reduces unnatural phenomena during decoding, improves sound quality, and adapts to different spectrum conditions.
Smart Images

Figure CN112992164B_ABST
Abstract
Description
[0001] This application is a divisional application of the following patent application: the application date is May 15, 2015, the application number is 201580041465.4, and the invention name is "Encoding method, device, and recording medium". Technical Field
[0002] The present invention relates to a coding technology for acoustic signals, and more particularly to a coding technology for encoding acoustic signals by transforming them into a frequency domain. Background Art
[0003] In encoding of sound signals such as voices and music, a method of encoding an input sound signal in the frequency domain is widely used. As a method of encoding a sound signal in the frequency domain, there are methods disclosed in Non-Patent Document 1 or Non-Patent Document 2, for example.
[0004] In the encoding method described in non-patent document 1, encoding processing using a spectrum envelope based on coefficients that can be transformed into linear prediction coefficients is performed. Specifically, in the encoding method described in non-patent document 1, coefficients that can be transformed into linear prediction coefficients obtained from an input sound signal are encoded to obtain linear prediction coefficient codes, and a normalized coefficient sequence obtained by normalizing a frequency domain coefficient sequence corresponding to the input sound signal is encoded using a spectrum envelope coefficient sequence corresponding to the coefficients that can be transformed into quantized linear prediction coefficients corresponding to the linear prediction coefficient codes, thereby obtaining normalized coefficient codes. The coefficients that can be transformed into linear prediction coefficients are linear prediction coefficients themselves, PARCOR coefficients (partial autocorrelation coefficients), or LSP parameters, etc.
[0005] In the encoding method described in non-patent document 2, the difference between the logarithmic value of the average energy of the coefficient of each divided frequency domain and the logarithmic value of the average energy of the adjacent frequency domain is obtained, and the encoding process accompanied by variable length coding of the difference value is performed. Specifically, in the encoding method described in non-patent document 2, the frequency domain coefficient sequence corresponding to the input sound signal is divided into frequency domains with fewer samples for lower frequencies and more samples for higher frequencies, and the average energy of each divided frequency domain is obtained, and the average energy is quantized on the logarithmic axis. The difference between the quantized value and the value obtained by quantizing the average energy of the adjacent frequency domain in the same way on the logarithmic axis is variable length coded. The number of quantization bits of each frequency domain coefficient or the quantization step size of each frequency domain coefficient is adaptively determined using the average energy of each divided frequency domain quantized on the logarithmic axis, so that each frequency domain coefficient is quantized and variable length coded.
[0006] Prior art literature
[0007] Non-patent literature
[0008] Non-patent document 1: Anthony Vetro, "MPEG Unified Speech and Audio Coding", Industry and Standards, IEEE MultiMedia, April-June, 2013.
[0009] Non-patent document 2: M. Bosi and RE Goldberg, "Introduction to Digital Audio Coding and Standards", Kluwer Academic Publishers, 2003. Summary of the invention
[0010] Problems to be solved by the invention
[0011] According to the encoding method of non-patent document 2, when the fluctuation of the spectrum envelope of the input acoustic signal is not large or the concentration of the spectrum is not high, the code amount of the average energy code can be reduced by performing variable length coding on the difference of the average energy, so that the input acoustic signal can be efficiently encoded. However, when the fluctuation of the spectrum envelope of the input acoustic signal is large or the concentration of the spectrum is high, the code amount of the average energy code obtained by performing variable length coding on the difference of the average energy becomes large.
[0012] In contrast, according to the encoding method of Non-Patent Document 1, the spectrum envelope can be efficiently encoded by using coefficients that can be converted into linear prediction coefficients. Therefore, when the fluctuation of the spectrum envelope of the input sound signal is large or the concentration of the spectrum is high, the input sound signal can be encoded more efficiently than the encoding method of Non-Patent Document 2. However, when the fluctuation of the spectrum envelope of the input sound signal is not large or the concentration of the spectrum is not high, the encoding cannot be performed as efficiently as the encoding method of Non-Patent Document 2.
[0013] As described above, in the conventional encoding method, there are cases where efficient encoding cannot be performed depending on the characteristics of the input sound signal.
[0014] An object of the present invention is to provide a coding method, apparatus, program, and recording medium that can efficiently perform coding regardless of the characteristics of an input sound signal and obtain a decoded sound signal that is less likely to sound unnatural to a listener.
[0015] Means for solving problems
[0016] A coding method according to one embodiment of the present invention is a coding method for encoding an input sound signal by a coding process determined among a plurality of coding processes in a frequency domain for each frame of a predetermined time interval, the coding method comprising a determining step of determining, when at least one of the magnitude of energy of a high-frequency component of the input sound signal of a previous frame and the magnitude of energy of a high-frequency component of the input sound signal of a current frame is equal to or less than a predetermined threshold value, a coding process different from that of a previous frame as a coding process of a current frame.
[0017] A coding method according to one embodiment of the present invention is a coding method for encoding an input sound signal by a coding process determined among a plurality of coding processes in a frequency domain for each frame of a predetermined time interval, the coding method comprising: a determination step of determining, when at least one of the magnitude of energy of a high-frequency component of an input sound signal of a previous frame and the magnitude of energy of a high-frequency component of an input sound signal of a current frame is equal to or less than a predetermined threshold, determining that a coding process different from that of a previous frame can be determined as the coding process of a current frame, and when this is not the case, determining, based on a state in which the high-frequency component of the input sound signal is sparse, whether a coding process different from that of a previous frame can be determined as the coding process of the current frame or a coding process the same as that of the previous frame is determined as the coding process of the current frame.
[0018] A coding method according to an aspect of the present invention is a coding method for coding an input sound signal by a coding process determined among a plurality of coding processes in a frequency domain for each frame of a predetermined time interval, the coding method comprising: a first coding step of coding a frequency domain coefficient sequence corresponding to the input sound signal using a spectrum envelope based on coefficients that can be transformed into linear prediction coefficients corresponding to the input sound signal; a second coding step of coding the frequency domain coefficient sequence corresponding to the input sound signal by variable length coding of a difference between a logarithm of an average energy of each frequency domain coefficient after division and a logarithm of an average energy of an adjacent frequency domain; and a determining step of determining that the current frame is coded by the first coding step when the frequency spectrum of the input sound signal of the current frame has large fluctuations or high concentration, and determining that the current frame is coded by the second coding step when the frequency spectrum of the input sound signal of the current frame has small fluctuations or low concentration.
[0019] Effects of the Invention
[0020] With a configuration that allows selection of one of a plurality of encoding processes for encoding in the frequency domain for each frame, it is possible to obtain a decoded acoustic signal that is less likely to sound unnatural to a listener. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 is a block diagram illustrating the structure of an encoding device.
[0022] Figure 2 is a block diagram illustrating the structure of a decoding device.
[0023] Figure 3 This is a diagram showing an example of the process flow of the encoding method.
[0024] Figure 4 This is a diagram showing an example of the flow of processing by the determination unit 380 .
[0025] Figure 5 This is a diagram showing an example of a process flow suitable for the encoding process determination unit 382.
[0026] Figure 6 This is a diagram showing an example of the process flow of the switching determination unit 383 according to the second embodiment.
[0027] Figure 7 This is a diagram showing an example of the process flow of the encoding process determination unit 382 according to the third embodiment.
[0028] Figure 8 This is a conceptual diagram of the first encoding process and the second encoding process. DETAILED DESCRIPTION
[0029] [First embodiment]
[0030] The first embodiment of the present invention is described below. The first embodiment is a configuration in which, in a configuration in which a coefficient sequence in the frequency domain corresponding to an input sound signal of each frame is encoded by performing one of a plurality of different encoding processes in the frequency domain, the encoding process is switched only when the energy of the high-frequency component of the input sound signal or / and the coefficient sequence in the frequency domain corresponding to the input sound signal is small. The energy of the high-frequency component of the input sound signal refers to the magnitude of the energy of the high-frequency component of the input sound signal itself, or the magnitude of the energy of the high-frequency component in the input sound signal, etc.
[0031] <Encoding device 300>
[0032] The structure of the encoding device 300 is Figure 1As shown in. The encoding device 300 includes: a frequency domain transformation unit 110, a determination unit 380, a first encoding unit 101, and a second encoding unit 201. The first encoding unit 101 includes: for example, a linear prediction analysis encoding unit 120, a spectrum envelope coefficient sequence generation unit 130, an envelope normalization unit 140, and a normalization coefficient encoding unit 150. The second encoding unit 201 includes: for example, a domain segmentation unit 220, an average logarithmic energy difference variable length encoding unit 240, and a coefficient encoding unit 250. In the encoding device 300, a time domain sound sound digital signal (hereinafter referred to as an input sound signal) is input in units of a predetermined time interval, i.e., a frame, and the following processing is performed for each frame. In the following, it is assumed that the current input sound signal is the f-th frame, and the specific processing of each unit is described. Let the input sound signal of the f-th frame be x f (n) (n=1, ..., Nt) Here, Nt is the number of samples per frame.
[0033] The following describes the operation of the encoding device 300. Figure 3 Processing of each step of the encoding method exemplified in .
[0034] <Frequency Domain Converter 110>
[0035] The frequency domain conversion unit 110 converts the input sound signal x f (n) (n=1, ..., Nt) is transformed into a coefficient sequence in the frequency domain, for example, an N-point MDCT coefficient sequence X f (n) (n=1, ..., N), and output (step S110). Here, N is the number of samples in the frequency domain, which is a positive integer. The transformation to the frequency domain can also be performed by a known transformation method other than MDCT.
[0036] In addition, when the coefficient sequence of the frequency domain obtained by multiple precisions or methods in the first coding unit 101, the second coding unit 201, and the determination unit 380 is required, the coefficient sequence of the frequency domain may be obtained by multiple precisions or methods in the frequency domain conversion unit 110. For example, when the first coding unit 101 and the second coding unit 201 use the MDCT coefficient sequence as the coefficient sequence of the frequency domain, and the determination unit 380 uses the power spectrum sequence as the coefficient sequence of the frequency domain, the frequency domain conversion unit 110 may obtain the MDCT coefficient sequence and the power spectrum sequence from the input sound signal. In addition, when the first coding unit 101 and the second coding unit 201 use the MDCT coefficient sequence as the coefficient sequence of the frequency domain, and the determination unit 380 uses the sequence of energy of each frequency band as the coefficient sequence of the frequency domain, the frequency domain conversion unit 110 may obtain the MDCT coefficient sequence and the sequence of energy of each frequency band from the input sound signal. In addition, for example, when the first encoding unit 101 and the second encoding unit 201 use the MDCT coefficient sequence as the coefficient sequence in the frequency domain, and the switching possibility determination unit 381 of the determination unit 380 uses the sequence of energy in each frequency band as the coefficient sequence in the frequency domain, and the encoding suitability determination unit 382 of the determination unit 380 uses the power spectrum sequence as the coefficient sequence in the frequency domain, the frequency domain transformation unit 110 can obtain the MDCT coefficient sequence and the sequence of energy in each frequency band and the power spectrum sequence from the input sound signal.
[0037] <Decision section 380>
[0038] The decision unit 380 can decide to use a different encoding process from that of the previous frame as the encoding process of the current frame when at least one of the magnitude of the energy of the high-frequency component of the input sound signal of the previous frame and the magnitude of the energy of the high-frequency component of the input sound signal of the current frame is smaller than a predetermined threshold value (step S380).
[0039] In other words, the decision unit 380 makes the following determination and performs switching control so that the coefficient sequence in the frequency domain of the current frame is encoded according to the determination result, wherein the determination is that when the energy of at least the high-frequency component of the input sound signal is small, the coefficient sequence in the frequency domain of the current frame is allowed to be encoded by a coding process different from the coding process used to encode the coefficient sequence in the frequency domain of the previous frame, and when this is not the case, the coefficient sequence in the frequency domain of the current frame is not allowed to be encoded by a coding process different from the coding process used to encode the coefficient sequence in the frequency domain of the previous frame.
[0040] The decision unit 380 includes, for example, a switching possibility determination unit 381, a suitable coding process determination unit 382, a switching determination unit 383, and a switching unit 384. An example of the decision unit 380 will be described below. The decision unit 380 performs Figure 4Processing of each step in the example.
[0041] <Switchability Determination Unit 381>
[0042] When at least one of the magnitude of the energy of the high-frequency component of the input audio signal in the previous frame and the magnitude of the energy of the high-frequency component of the input audio signal in the current frame is smaller than a specified threshold, the Switchability Determination Unit 381 determines that switching is possible, that is, the coefficient sequence in the frequency domain of the current frame can be encoded by an encoding process different from the encoding process that encoded the coefficient sequence in the frequency domain of the previous frame. Otherwise, it determines that switching is not possible, that is, it does not allow the coefficient sequence in the frequency domain of the current frame to be encoded by an encoding process different from the encoding process that encoded the coefficient sequence in the frequency domain of the previous frame, and outputs the determination result (step S381).
[0043] Hereinafter, an example of the operation of the Switchability Determination Unit 381 will be described. First, an example of using the energy of the high-frequency part of the MDCT coefficient sequence as the magnitude of the energy of the high-frequency component of the input audio signal will be described.
[0044] The Switchability Determination Unit 381 first obtains the high-frequency energy Eh of the MDCT coefficient sequence X(n) (n = 1,..., N) of the previous frame respectively by the following formula (1) f-1 (n) (n = 1,..., N), and obtains the high-frequency energy Eh of the MDCT coefficient sequence X(n) (n = 1,..., N) of the current frame by the following formula (2) f-1 (n) (n = 1,..., N) (step S3811). In formulas (1) and (2), M is a predetermined positive integer smaller than N. f (n) (n = 1,..., N) of the high-frequency energy Eh f (step S3811). In formulas (1) and (2), M is a predetermined positive integer smaller than N.
[0045]
[0046]
[0047] The Switchability Determination Unit 381 then determines that switching is possible when at least one of the high-frequency energy Eh of the previous frame f-1 and the high-frequency energy Eh of the current frame f is smaller than a predetermined threshold TH1, that is, Eh f-1 < TH1 and / or Eh f < TH1, and determines that switching is not possible otherwise, and outputs information on whether switching is possible (step S3812).
[0048] In addition, in step S3811 of the current frame, the high-frequency energy Eh of the previous frame obtained f-1 and the high-frequency energy Eh of the current frame obtained in step S3811 of the previous frame fis the same. Therefore, if the calculated high-frequency energy Eh f is stored in the switching permission determination unit 381 until at least the next frame, it is not necessary to calculate the high-frequency energy Eh f-1 of the previous frame.
[0049] Next, an example in which the magnitude of the energy of the high-frequency component of the input audio signal is represented by the ratio of the high-frequency energy to the total energy of the MDCT coefficient sequence will be described.
[0050] The switching permission determination unit 381 first obtains the ratio Eh' of the high-frequency energy of the previous frame to the total energy of the MDCT coefficient sequence X f-1 (n) (n = 1,..., N) respectively by the following formula (1A), and obtains the ratio Eh' of the high-frequency energy of the current frame to the total energy of the MDCT coefficient sequence X f-1 (n) (n = 1,..., N) by the following formula (2A) (step S3811). In formulas (1A) and (2A), M is a predetermined positive integer. f (n) (n = 1,..., N) (step S3811). In formulas (1A) and (2A), M is a predetermined positive integer. f (Step S3811). In equations (1A) and (2A), M is a predetermined positive integer.
[0051]
[0052]
[0053] The switching permission determination unit 381 then determines that switching is possible when at least one of the ratio Eh' of the high-frequency energy of the previous frame to the total energy and the ratio Eh' of the high-frequency energy of the current frame to the total energy is smaller than a predetermined threshold TH1, that is, when Eh' f-1 < TH1 and / or Eh' f < TH1, and determines that switching is not possible otherwise, and outputs information on whether switching is possible (step S3812). f-1 < TH1 and / or Eh' f < TH1, and determines that switching is not possible otherwise, and outputs information on whether switching is possible (step S3812).
[0054] In addition, the ratio Eh' of the high-frequency energy of the previous frame to the total energy obtained in step S3811 of the current frame f-1 is the same as the ratio Eh' of the high-frequency energy of the current frame to the total energy obtained in step S3811 of the previous frame. Therefore, if the calculated ratio Eh' of the high-frequency energy to the total energy f is stored in the switching permission determination unit 381 until at least the next frame, it is not necessary to calculate the ratio Eh' of the high-frequency energy of the previous frame to the total energy. f is stored in the switching permission determination unit 381 until at least the next frame, it is not necessary to calculate the ratio Eh' of the high-frequency energy of the previous frame to the total energy. f-1 of the previous frame.
[0055] In addition, in the above two examples, in the case of Eh f-1 <TH1 and / or Eh f <TH1, it is determined to be switchable, or in the case of Eh' f-1 <TH1 and / or Eh' f <TH1, it is determined to be switchable, and in other cases, it is determined to be non-switchable. However, it is also possible to determine it to be switchable in the case of Eh f-1 <TH1 and Eh f <TH1, or it is also possible to determine it to be switchable in the case of Eh' f-1 <TH1 and Eh' f <TH1, and in other cases, it is determined to be non-switchable. That is, it is also possible to determine it to be switchable when the ratio of the magnitudes of the energies of the high-frequency components of the input audio signal in the previous frame and the current frame to a specified threshold is small, that is, it is possible to encode the coefficient sequence in the frequency domain of the current frame by an encoding process different from the encoding process that encoded the coefficient sequence in the frequency domain of the previous frame, and in other cases, it is determined to be non-switchable, that is, it is not allowed to encode the coefficient sequence in the frequency domain of the current frame by an encoding process different from the encoding process that encoded the coefficient sequence in the frequency domain of the previous frame.
[0056] In addition, in the above examples, the high-frequency energy or the ratio of the high-frequency energy to the total energy was obtained using the MDCT coefficient sequence. However, it is also possible to use the power spectrum sequence or the sequence of energies in each frequency band to obtain the high-frequency energy or the ratio of the high-frequency energy to the total energy.
[0057] <Suitable Encoding Process Determination Unit 382>
[0058] The suitable encoding process determination unit 382 determines which of the encoding processes of the first encoding unit 101 and the second encoding unit 201 is suitable for the coefficient sequence in the frequency domain corresponding to the input audio signal of the current frame, and outputs the determination result (step S382).
[0059] Hereinafter, an example of the operation of the suitable encoding process determination unit 382 will be described. The suitable encoding process determination unit 382 performs the processing of each step exemplified in Figure 5 In the following example, the encoding process of the first encoding unit 101 is the encoding process exemplified in Non-Patent Document 1, which uses the spectral envelope based on the coefficients that can be transformed into linear prediction coefficients, and the encoding process of the second encoding unit 201 is the encoding process exemplified in Non-Patent Document 2, which is a variable-length encoding accompanied by the difference between the logarithm of the average energy of the coefficients in each divided frequency domain and the logarithm of the average energy of the adjacent frequency domain.
[0060] In this example, when the fluctuation of the spectrum envelope of the input sound signal is large and / or the concentration is high, it is determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding process of the first encoding unit 101, and when the fluctuation of the spectrum envelope of the input sound signal is small and / or the concentration is low, it is determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding process of the second encoding unit 201, and the determination result is output.
[0061] As a method for estimating the fluctuation or concentration of the spectrum, any method can be used. In the following example, a structure for estimating the depth of the valley of the spectrum or the envelope is described. In this structure, when the valley of the spectrum or the envelope is shallow, it is determined that the fluctuation of the spectrum is small and the concentration is low, and when the valley of the spectrum or the envelope is deep, it is determined that the fluctuation of the spectrum is large and the concentration is high. The shallow valley of the spectrum or the envelope can also be said to have a high noise floor. In addition, the deep valley of the spectrum or the envelope can also be said to have a low noise floor.
[0062] The coding suitability determination unit 382 first converts the MDCT coefficient sequence X of the current frame into f (n) (n = 1, ..., N) is divided into Q partial coefficient sequences XS for each P samples f (1)(n)(n=1,...,P),XS f (2)(n)(n=1,...,P),...,XS f (Q)(n)(n=1, ..., P)(step S3821). P and Q are positive integers satisfying the relationship P×Q=N. P=1 is also acceptable. In addition, it is assumed that the frequency domain coefficient sequence that becomes the object of the encoding process in the first encoding unit 101 or the second encoding unit 201, that is, the MDCT coefficient sequence X is also used in the encoding process suitability determination unit 382. f (n) (n = 1, ..., N) structure, but it is also possible to pass through the MDCT coefficient sequence X f The coefficient sequence in the frequency domain obtained by transforming into the frequency domain using different accuracies or methods (n) (n=1, . . . , N), for example, a power spectrum sequence, is used as an object for processing by the encoding processing determination unit 382.
[0063] The coding suitability determination unit 382 then obtains the partial coefficient sequence XS f (1)(n)(n=1,...,P),XS f (2)(n)(n=1,...,P),...,XS f The average value of the power of each of (Q)(n)(n=1,...,P) or the sequence of its logarithmic values AVE XS(q)(q=1,…,Q)(Step S3822). The average power value is AVE calculated by equation (3) XS (q). In addition, the logarithm of the average power is obtained by equation (3A) as AVE XS (q).
[0064]
[0065]
[0066] The coding suitable processing determination unit 382 then determines the sequence AVE of the average value of power or the logarithmic value of the average value of power. XS (1),AVE XS (2),...,AVE XS For each element of (Q), it is determined whether it is smaller than any of the two adjacent elements, and the number of elements determined is obtained (step S3823). That is, the number Vally of q that satisfies the formula (4) is obtained.
[0067] AVE XS (q)-min(AVE XS (q-1),AVE XS (q+1))<0(4)
[0068] The coding suitability determination unit 382 then obtains the number of Vally AVEs corresponding to q satisfying equation (4): XS The average value of (q) V , that is, the average value E of the valley area V (Step S3824). XS If (q) is the average power, E obtained in step S3824 V is the average of the power of the area in the valley. XS When (q) is the logarithmic value of the average power, E obtained in step S3824 V The average value of the logarithm of the average power of the partial region is the average value of the valley of the logarithm of the average power of the partial region. In addition, the coding processing determination unit 382 obtains the average power value of all partial regions or the logarithm of the average power value (step S3825). The average power value of all partial regions is the MDCT coefficient sequence X. f The average value of the power of (n) (n = 1, ..., N) is E obtained by equation (11). The logarithm of the average value of the power of all partial regions is the MDCT coefficient sequence X f The logarithm of the average value of the power of (n) (n=1, . . . , N) is E obtained by equation (11A).
[0069]
[0070]
[0071] The suitable encoding process determination unit 382 then calculates the AVE of all partial areas. XS (q) The average value E and the AVE of the valley area XS The average value of (q) V If the difference between AVE and AVE is less than the predetermined threshold value TH2, it is estimated that the spectrum has shallow valleys, few fluctuations in the spectrum envelope, or a spectrum with low concentration, so it is determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding process of the second encoding unit 201. On the contrary, in all partial regions, AVE XS (q) The average value E and the AVE of the valley area XS The average value of (q) V When the difference is greater than the threshold value TH2, it is estimated that the spectrum has a deep valley, a large fluctuation of the spectrum envelope, or a high concentration spectrum, so it is determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding process of the first encoding unit 101. The suitable encoding process determination unit 382 outputs information on which encoding process is suitable (step S3826). The information on the suitable encoding process is also called suitable information.
[0072] In addition, in step S3821, different sampling numbers may be set for each partial coefficient sequence. For example, the MDCT coefficient sequence X of the current frame may be f (n) (n = 1, ..., N) is divided into Q partial coefficient sequences XS f (1)(n)(n=1,...,P1),XS f (2)(n)(n=1,...,P2),...,XS f (Q)(n)(n=1,...,P Q ). P1,P2,...,P Q It satisfies P1+P2+...+P Q =N is a positive integer. In addition, preferably P1, P2, ..., P Q Satisfies P1≤P2≤...≤P Q . Furthermore, Q is a positive integer.
[0073] <Switch determination unit 383>
[0074] The switching decision unit 383 determines whether the coefficient sequence of the frequency domain of the current frame is encoded in the first encoding unit 101 or in the second encoding unit 201 based on the information on the switching possibility obtained by the switching possibility determination unit 381 and the information on which encoding process is suitable obtained by the suitable encoding process determination unit 382, and outputs a code that can determine the determined encoding process, that is, a switching code (step S383). The output switching code is input to the decoding device 400. Here, the switching decision unit 383 determines to encode the coefficient sequence of the frequency domain of the current frame by the same encoding process as the previous frame, regardless of which encoding process is suitable for the current frame, when it is not switchable. In addition, when it is switchable, regardless of which encoding process is used for the previous frame, it is determined to encode the coefficient sequence of the frequency domain of the current frame by the encoding process suitable for the current frame. Among them, the following situation may also be included: even in the case of switchability, it is determined not to encode the coefficient sequence of the frequency domain of the current frame by the encoding process suitable for the current frame, but by the same encoding process as the previous frame.
[0075] An example of the operation of the switching decision unit 383 is described below. In the following example, the encoding process of the first encoding unit 101 is an encoding process using a spectrum envelope based on coefficients that can be transformed into linear prediction coefficients as exemplified in non-patent document 1, and the encoding process of the second encoding unit 201 is an encoding process using variable length coding with a difference between the logarithm of the average energy of the coefficients in each divided frequency domain and the logarithm of the average energy of the adjacent frequency domain as exemplified in non-patent document 2.
[0076] The switching decision unit 383 determines whether the switching possibility information obtained by the switching possibility determination unit 381 indicates that switching is not possible, and / or whether the information on which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates that the MDCT coefficient sequence X of the previous frame is different from the MDCT coefficient sequence X of the previous frame. f-1 In the case of the same encoding process as the encoding process of the previous frame, the MDCT coefficient sequence X f-1 The same encoding process as the encoding process of (n) (n=1, ..., N) is determined as the MDCT coefficient sequence X of the current frame f (n) (n=1,...,N) encoding processing.
[0077] That is, the MDCT coefficient column X in the previous frame f-1 (n) (n=1, ..., N) is encoded in the first encoding unit 101, and when the switching possibility information obtained by the switching possibility determination unit 381 indicates that switching is not possible, it is determined to be the MDCT coefficient sequence X of the current frame. f (n) (n=1, ..., N) is also encoded in the first encoding unit 101. In addition, in the MDCT coefficient sequence X of the previous framef-1 (n) (n=1, ..., N) is encoded in the first encoding unit 101, and when the information on which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates the encoding process of the first encoding unit 101, the MDCT coefficient sequence X of the current frame is also determined. f (n) (n=1, . . . , N) is also encoded in the first encoding unit 101.
[0078] In addition, the MDCT coefficient column X of the previous frame f-1 (n) (n=1, ..., N) is encoded in the second encoding unit 201, and when the switching possibility information obtained by the switching possibility determination unit 381 indicates that switching is not possible, it is determined to be the MDCT coefficient sequence X of the current frame. f (n) (n=1, ..., N) is also encoded in the second encoding unit 201. In addition, in the MDCT coefficient sequence X of the previous frame f-1 (n) (n=1, ..., N) When the second coding unit 201 is coded, and the information on which coding process is suitable obtained by the suitable coding process determination unit 382 indicates the coding process of the second coding unit 201, the MDCT coefficient sequence X of the current frame is also determined. f (n) (n=1, . . . , N) is also encoded in the second encoding unit 201.
[0079] The information on the switching possibility obtained by the switching possibility determination unit 381 indicates that the switching is possible, and the information on which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates the MDCT coefficient sequence X of the previous frame. f-1 In the case of a coding process different from the coding process of the previous frame, the MDCT coefficient sequence X f-1 The different encoding processes of (n) (n=1, ..., N) are determined as the MDCT coefficient sequence X of the current frame. f (n) (n = 1, ..., N) encoding process. That is, in the MDCT coefficient sequence X of the previous frame f-1 (n) (n=1, ..., N) is encoded in the first encoding unit 101, and the information on the switching possibility obtained by the switching possibility determination unit 381 indicates that switching is possible, and the information on which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates the encoding process of the second encoding unit 201, the MDCT coefficient sequence X of the current frame is determined. f (n) (n=1, ..., N) is encoded in the second encoding unit 201. In addition, in the MDCT coefficient sequence X of the previous frame f-1(n) (n=1, ..., N) is encoded in the second encoding unit 201, and the information on the switching possibility obtained by the switching possibility determination unit 381 indicates that switching is possible, and the information on which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates the encoding process of the first encoding unit 101, the MDCT coefficient sequence X of the current frame is determined. f (n) (n=1, . . . , N) is encoded in the first encoding unit 101.
[0080] <Switch section 384>
[0081] The switching unit 384 performs control so that the MDCT coefficient sequence X output by the frequency domain transform unit 110 is f (n) (n=1, . . . , N) is input to the first encoding unit 101 or the second encoding unit 201, so that the MDCT coefficient sequence X of the current frame is processed by the encoding process determined in the switching determination unit 383. f (n) (n=1, ..., N) is encoded (step S384). f (n) (n = 1, ..., N) encoding, the input sound signal x of the current frame f (n) (n = 1, ..., Nt) is also necessary, the input sound signal x of the current frame f (n) (n=1, . . . , Nt) is also input to the first encoding unit 101 and / or the second encoding unit 201.
[0082] For example, when the encoding process of the first encoding unit 101 is the encoding process using the spectrum envelope based on the coefficients that can be transformed into the linear prediction coefficients as exemplified in Non-Patent Document 1, and the encoding process of the second encoding unit 201 is the encoding process with variable length coding of the difference between the average energy of the coefficients in each divided frequency domain and the average energy of the adjacent frequency domain as exemplified in Non-Patent Document 2, since only the input sound signal x of the current frame in the first encoding unit 101 f (n) (n = 1, ..., Nt) becomes necessary, so when the MDCT coefficient column X f (n) (n=1, ..., N) is input to the first encoding unit 101, and the input sound signal x of the current frame is f (n) (n=1, . . . , Nt) is also input to the first encoding unit 101.
[0083] <First Encoding Unit 101, Second Encoding Unit 201>
[0084] The first coding unit 101 and the second coding unit 201 both perform a coding process of encoding a coefficient sequence in the frequency domain, but the coding processes performed are different from each other. That is, the first coding unit 101 encodes the coefficient sequence in the frequency domain of the current frame through a coding process different from that of the second coding unit 201, and outputs a first code as the obtained code (step S101). In addition, the second coding unit 201 encodes the coefficient sequence in the frequency domain of the current frame through a coding process different from that of the first coding unit 101, and outputs a second code as the obtained code (step S201). For example, the first coding unit 101 performs a coding process using a spectrum envelope based on coefficients that can be transformed into linear prediction coefficients, and the second coding unit 201 performs a coding process using the average energy of each coefficient in the divided frequency domain.
[0085] An example of the operation of the first encoding unit 101 and the second encoding unit 201 is described below. In the following example, the encoding process of the first encoding unit 101 is the encoding process using the spectrum envelope based on the coefficients that can be transformed into the linear prediction coefficients as exemplified in Non-Patent Document 1, and the encoding process of the second encoding unit 201 is the encoding process using variable length coding accompanied by the difference between the average energy of the coefficients in each divided frequency domain and the average energy of the adjacent frequency domain as exemplified in Non-Patent Document 2.
[0086] In this example, the first encoding process of the first encoding unit 101 is as follows Figure 8 On the other hand, the second encoding process of the second encoding unit 201 is as follows: Figure 8 The envelope shape is represented by a scale factor band (division of the frequency domain coefficient sequence into multiple fields) as in the example on the right of FIG. According to the second encoding process, since variable length encoding of the difference value of the average height of each field is used, it can be said that the efficiency is very good even when the average value changes smoothly.
[0087] Based on the result of the decision or selection by the decision unit 380 , one of the processes of the first coding unit 101 and the second coding unit 201 , which are a plurality of coding processes in the frequency domain, is performed.
[0088] <First Encoding Unit 101>
[0089] The first coding unit 101 includes a linear prediction analysis coding unit 120, a spectrum envelope coefficient sequence generation unit 130, an envelope normalization unit 140, and a normalization coefficient coding unit 150. The first coding unit 101 receives the MDCT coefficient sequence X of the current frame as input. f (n) (n = 1, ..., N) and the input sound signal x f(n)(n=1,...,Nt), the output contains the linear prediction coefficient code CL f and the normalized coefficient code CN f The output first code is input to the decoding device 400. In addition, the first coding unit 101 is a component that removes the part of transforming the input sound signal into the coefficient sequence in the frequency domain from the coding process described in the non-patent document 1. That is, the coding process performed in the frequency domain transform unit 110 and the first coding unit 101 is the same as the coding process described in the non-patent document 1.
[0090] <Linear prediction analysis encoding unit 120>
[0091] The linear prediction analysis encoding unit 120 receives the input sound signal x f (n) (n=1, ..., Nt) performs linear prediction analysis to obtain coefficients that can be transformed into linear prediction coefficients, and encodes the coefficients that can be transformed into linear prediction coefficients to obtain a linear prediction coefficient code CL f , and can be transformed into linear prediction coefficient code CL f The corresponding quantized linear prediction coefficients are converted and output (step S120). The coefficients that can be converted into linear prediction coefficients are the linear prediction coefficients themselves, PARCOR coefficients (partial autocorrelation coefficients) or LSP parameters.
[0092] <Spectrum Envelope Coefficient Sequence Generator 130>
[0093] The spectrum envelope coefficient sequence generation unit 130 obtains a power spectrum envelope coefficient sequence W corresponding to the coefficients that can be converted into quantized linear prediction coefficients obtained by the linear prediction analysis encoding unit 120. f (n) (n=1, ..., N), and output (step S130).
[0094] <Envelope normalization unit 140>
[0095] The envelope normalization unit 140 uses the power spectrum envelope coefficient sequence W obtained by the spectrum envelope coefficient sequence generation unit 130 f (n) (n=1, ..., N), for each coefficient X of the MDCT coefficient sequence obtained by the frequency domain transform unit 110 f (n) (n = 1, ..., N) is normalized, and the normalized MDCT coefficient sequence XN f (n) (n = 1, ..., N) is output (step S140). That is, the MDCT coefficient sequence X is obtained. f The coefficients of (n) (n=1,...,N) are divided by the power spectrum envelope coefficient sequence W fThe sequence of values after the corresponding coefficients are included in (n) (n = 1, ..., N) is the normalized MDCT coefficient sequence XN f (n)(n=1,...,N).
[0096] <Normalization coefficient encoding unit 150>
[0097] The normalized coefficient encoding unit 150 performs the normalized MDCT coefficient sequence XN obtained by the envelope normalization unit 140. f (n) (n = 1, ..., N) is encoded to obtain the normalized coefficient code CN f (Step S150).
[0098] <Second Encoding Unit 201>
[0099] In addition, the second coding unit 201 includes a region dividing unit 220, an average logarithmic energy difference variable length coding unit 240, and a coefficient coding unit 250. The second coding unit 201 inputs the MDCT coefficient sequence X of the current frame. f (n)(n=1,...,N), the output contains the average energy code CA f and coefficient code CD f The output second code is input to the decoding device 400. In addition, the second coding unit 201 is a component that removes the part of transforming the input sound signal into the coefficient sequence in the frequency domain from the coding process described in the non-patent document 2. That is, the coding process performed in the frequency domain transform unit 110 and the second coding unit 201 is the same as the coding process described in the non-patent document 2.
[0100] <Area division unit 220>
[0101] The domain segmentation unit 220 converts the MDCT coefficient sequence X obtained by the frequency domain transformation unit 110 into f (n) (n = 1, ..., N) is divided into a plurality of partial areas, wherein the lower the frequency, the fewer the samples, and the higher the frequency, the more the samples (step S220). If the number of partial areas is set to R, and the number of samples contained in each partial area is set to S1, ..., S R , then the coefficients X of the MDCT coefficient sequence f (n) (n = 1, ..., N) is divided into XB according to each part area starting from the lowest frequency sampling. f (1)(n)(n=1,...,S1),XB f (2)(n)(n=1,...,S2),...,XB f (R)(n)(n=1,...,S R ). R and S1,...,S R is a positive integer. S1,...,SR Assume that S1≤S2≤...≤S R The relationship between XB f (1)(n)(n=1,...,S1),XB f (2)(n)(n=1,...,S2),...,XB f (R)(n)(n=1,...,S R ) is called the partial domain coefficient series.
[0102] <Average logarithmic energy difference variable length encoding unit 240>
[0103] The average logarithmic energy difference variable length coding unit 240 obtains the average energy of the coefficients contained in each partial field obtained by the field division unit 220, quantizes the average energy of the partial field on the logarithmic axis, and performs variable length coding on the difference between the quantized value on the logarithmic axis of the average energy of the adjacent partial field to obtain the average energy code CA f (Step S240).
[0104] The average logarithmic energy difference variable length coding unit 240 first calculates the average energy E of each sub-region r (r=1, ..., R) by equation (5): XB (r)(r=1,...,R)(step S2401).
[0105]
[0106] The average logarithmic energy difference variable length coding unit 240 then performs average energy E on each sub-area. XB scalar quantization in the logarithmic domain of (r)(r=1,...,R) to obtain the quantized value Q(log(E XB (r)))(r=1, ..., R)(step S2402). The average logarithmic energy difference variable length coding unit 240 then obtains the quantized value Q (log(E XB (r)))) and the quantized value Q(log(E XB (r-1)))DiffE XB (r) (step S2403). In the case of r=1, the average energy E XB The scalar quantization value Q(log(E XB (r))) itself is set to DiffE XB (1) DiffE XB(r) (r = 1, ..., R) is called the average logarithmic energy difference. That is, DiffE XB (r) (r = 1, ..., R) is obtained by equation (6). Here, Q() is a scalar quantization function, which is a function that outputs an integer value obtained by rounding off the decimal part of a value obtained by normalizing (dividing) an input by a predetermined value.
[0107]
[0108] The average logarithmic energy difference variable length coding unit 240 then performs the average logarithmic energy difference DiffE XB (r) (r = 1, ..., R) is variable length coded to obtain the average energy code CA f (Step S2404). In addition, due to the average logarithmic energy difference DiffE XB The case where the absolute value of (r) is small has a higher frequency of occurrence in statistics, so the variable length code is predetermined to have a smaller code size than the case where the absolute value is large. That is, when the variation of the average logarithmic energy per region is small, that is, when the fluctuation of the spectrum envelope is small and the concentration of the spectrum envelope is low, there is a possibility that the average energy code CA can be shortened. f The trend of the length of the code.
[0109] <Coefficient encoding unit 250>
[0110] The coefficient coding unit 250 uses the quantized value Q(log(E XB (r)) (r = 1, ..., R), the partial domain coefficient sequence XB obtained by the domain division unit 220 f (1)(n)(n=1,...,S1),XB f (2)(n)(n=1,...,S2),...,XB f (R)(n)(n=1,...,S R ) are subjected to scalar quantization to obtain coefficient code CD f (Step S250) The quantization step width or the number of quantization bits used in the scalar quantization is the partial region coefficient sequence XB obtained by the region division unit 220. f (1)(n)(n=1,...,S1),XB f (2)(n)(n=1,...,S2),...,XB f (R)(n)(n=1,...,S R ), according to the quantized value Q(E XB(r)) (r = 1, ..., R). In addition, the quantized value Q (E XB (r))(r=1,...,R) is the quantized value Q(log(E XB (r)) (r = 1, ..., R) is obtained by setting the equation (7) to a value in the linear region.
[0111]
[0112] The coefficient encoding unit 250 first considers the quantized value Q(log(E XB The value of the difference between the logarithm of the energy of the spectral level that cannot be perceived auditorily by frequency estimation and (r)) (r = 1, ..., R) is used as the coefficient code CD f A given number of bits is allocated to each coefficient of each partial domain coefficient sequence according to the amount of code (step S2501).
[0113] The coefficient encoding unit 250 then calculates the quantized value Q (E XB (r))(r=1, . . . , R) and the number of allocated bits, the step size of scalar quantization of each coefficient in each sub-region coefficient sequence is calculated (step S2502).
[0114] The coefficient coding unit 250 then quantizes each coefficient of each partial region coefficient sequence with the determined step size and bit number, and further performs variable length coding on the integer value of each quantized coefficient to obtain a coefficient code CD f (Step S2503).
[0115] <Decoding device 400>
[0116] exist Figure 2 The structure of the decoding device 400 is shown in FIG. The decoding device 400 includes a switching unit 480, a first decoding unit 401, and a second decoding unit 501. The first decoding unit 401 includes, for example, a linear prediction decoding unit 420, a spectrum envelope coefficient sequence generation unit 430, a normalization coefficient decoding unit 450, and an envelope denormalization unit 440. The second decoding unit 501 includes, for example, an average logarithmic energy difference variable length decoding unit 540 and a coefficient decoding unit 550. In the decoding device 400, a code including a switching code and an input code is input in units of frames as a predetermined time interval. In the case of a frame encoded by the first encoding unit 101, the input code includes a linear prediction coefficient code CL f and the normalized coefficient code CN f In the case of a frame encoded by the second encoding unit 201, the input code includes the average energy code CA f and coefficient code CDf In the following, it is assumed that the frame currently being processed is the f-th frame, and specific processing of each unit is described.
[0117] The operation of decoding device 400 will be described below.
[0118] <Switch 480>
[0119] The switching unit 480 decides whether to decode the input code of the current frame in the first decoding unit 401 or in the second decoding unit 501 according to the input switching code, and controls the input code to be input to the first decoding unit 401 or the second decoding unit 501 so that the determined decoding process can be performed (step S480).
[0120] Specifically, when the input switching code is a code for determining the encoding process of the first encoding unit 101, that is, a code for determining the encoding process using the spectrum envelope based on the coefficients that can be transformed into the linear prediction coefficients, the switching unit 480 controls so that the input code is input to the first decoding unit 401 that performs the decoding process corresponding to the encoding process of the first encoding unit 101. In addition, when the input switching code is a code for determining the encoding process of the second encoding unit 201, that is, a code for determining the encoding process of variable length coding accompanied by the difference between the average energy of each coefficient of the divided frequency domain and the average energy of the adjacent frequency domain, the switching unit 480 controls so that the input code is input to the second decoding unit 501 that performs the decoding process corresponding to the encoding process of the second encoding unit 201.
[0121] <First Decoding Unit 401>
[0122] The first decoding unit 401 includes a linear prediction decoding unit 420, a spectrum envelope coefficient sequence generation unit 430, a normalization coefficient decoding unit 450, and an envelope denormalization unit 440. The first decoding unit 401 receives the linear prediction coefficient code CL of the current frame as input. f and the normalized coefficient code CN f , output frequency domain coefficient column X f (n)(n=1,...,N).
[0123] <Linear prediction decoding unit 420>
[0124] The linear prediction decoding unit 420 decodes the linear prediction coefficient code CL included in the input code. fThe linear prediction coefficients 120 and 120 are decoded to obtain coefficients that can be transformed into decoded linear prediction coefficients. The coefficients that can be transformed into decoded linear prediction coefficients are the same as the coefficients that can be transformed into quantized linear prediction coefficients obtained by the linear prediction analysis coding unit 120 of the coding device 300. In addition, the decoding process performed by the linear prediction decoding unit 420 is a process corresponding to the encoding process performed by the linear prediction analysis coding unit 120 of the coding device 300. In addition, the coefficients that can be transformed into linear prediction coefficients refer to the linear prediction coefficients themselves, PARCOR coefficients (partial autocorrelation coefficients) or LSP parameters, etc.
[0125] <Spectrum envelope coefficient sequence generation unit 430>
[0126] The spectrum envelope coefficient sequence generator 430 obtains a power spectrum envelope coefficient sequence W corresponding to the coefficients that can be converted into decoded linear prediction coefficients obtained by the linear prediction decoder 420. f (n) (n=1,...,N), and output. Where N is the number of samples in the frequency domain and is a positive integer.
[0127] <Normalization coefficient decoding unit 450>
[0128] The normalization coefficient decoding unit 450 decodes the input normalization coefficient code CN f Decode and obtain the decoded normalized MDCT coefficient column ^XN f (n) (n=1, ..., N) (step S450). Here, the decoding process performed by the normalization coefficient decoding unit 450 corresponds to the encoding process performed by the normalization coefficient encoding unit 150 of the encoding device 300. That is, when the encoding device 300 performs a transform process to the frequency domain other than the MDCT, ^XN f (n) (n=1, ..., N) is a coefficient sequence in the frequency domain that is not a domain of MDCT and corresponds to the transform process to the frequency domain of the encoding device 300. In addition, the decoded normalized MDCT coefficient sequence ^XN f (n) (n=1, . . . , N) corresponds to the normalized MDCT coefficient sequence XN input to the normalized coefficient encoding unit 150 of the encoding device 300 f (n) (n = 1, ..., N), since each coefficient contains a quantization error, let XN f (n) ^XN with "^" appended f (n).
[0129] <Envelope Denormalization Unit 440>
[0130] The envelope denormalization unit 440 uses the power spectrum envelope coefficient sequence W obtained by the spectrum envelope coefficient sequence generation unit 430 f(n) (n=1, ..., N), each coefficient of the decoded normalized MDCT coefficient sequence obtained by the normalized coefficient decoding unit 450 is ^XN f (n) (n = 1, ..., N) is denormalized and the decoded MDCT coefficient column ^XN is output f (n) (n=1, ..., N) (step S440). That is, the decoded normalized MDCT coefficient sequence XN is obtained. f The coefficients of (n) (n = 1, ..., N) and the power spectrum envelope coefficient sequence W f The sequence of values obtained by multiplying the coefficients corresponding to each coefficient of (n) (n = 1, ..., N) is used as the decoded MDCT coefficient sequence ^X f (n)(n=1,...,N).
[0131] <Second Decoding Unit 501>
[0132] The second decoding unit 501 includes an average logarithmic energy difference variable length decoding unit 540 and a coefficient decoding unit 550. The average energy code CA of the current frame is input to the second decoding unit 501. f and coefficient code CD f , output frequency domain coefficient column X f (n)(n=1,...,N).
[0133] <Average logarithmic energy difference variable length decoding unit 540>
[0134] The average logarithmic energy difference variable length decoding unit 540 decodes the input average energy code CA f Decode and obtain the average decoding energy Q(E XB (r)) (r = 1, ..., R) (step S540). The decoded average energy is the same as the quantized value of the average energy obtained in the coefficient encoding unit 250 of the encoding device 300, and therefore uses the same symbol Q (E XB (r)).
[0135] The average logarithmic energy difference variable length decoding unit 540 first decodes the average energy code CA f Decode and obtain the energy difference DiffE in the logarithmic domain of each part of the domain XB(r)(r=1,...,R)(Step S5401). Here, the decoding process performed by the average logarithmic energy difference variable length decoding unit 540 corresponds to the encoding process performed by the average logarithmic energy difference variable length encoding unit 240 of the encoding device 300. In addition, since the energy difference in the logarithmic domain of each partial area is the same as the energy difference in the logarithmic domain of each partial area obtained in the average logarithmic energy difference variable length encoding unit 240 of the encoding device 300, the same symbol DiffE is used. XB (r).
[0136] The average logarithmic energy difference variable length decoding unit 540 then converts the energy difference DiffE in the logarithmic domain into XB The decoded value Q(log(E) in the logarithmic domain of the average energy of the adjacent partial domain is added to (r)(r=1,...,R) XB (r-1))) to obtain the decoded value Q(log(E XB (r)) (step S5402). In addition, since the decoded value in the logarithmic domain of the average energy is the same as the quantized value in the logarithmic domain of the average energy obtained in the average logarithmic energy difference variable length coding unit 240 of the encoding device 300, the same notation Q(log(E XB (r)).
[0137]
[0138] The average logarithmic energy difference variable length decoding unit 540 then obtains the decoded value Q(log(E XB The value after (r-1)))(r=1,...,R) is set to the value in the linear domain is used as the decoding average energy Q(E XB (r))(r=1,...,R)(step S5403).
[0139] <Coefficient decoding unit 550>
[0140] The coefficient decoding unit 550 uses the decoded average energy Q (E XB (r))(r=1,...,R), for coefficient code CD f Decode to obtain the decoded coefficient column ^X f (n) (n=1, ..., N) (step S550). Here, the decoding process performed by the coefficient decoding unit 550 corresponds to the encoding process performed by the coefficient encoding unit 250 of the encoding device 300. The input coefficient code CD fThe coefficient code CD is obtained by performing variable length coding on each coefficient of each sub-region coefficient sequence in the coefficient coding unit 250 of the coding device 300. f The code length of the code part corresponding to each coefficient in can be automatically restored. In addition, according to the decoded average energy Q (E XB (r)), and find the quantization step size of each area. Based on this, it is possible to f The decoded MDCT coefficient sequence ^X in the frequency domain is obtained f (n)(n=1,...,N).
[0141] <Time Domain Converter 410>
[0142] The time domain transform unit 410 transforms the decoded MDCT coefficient sequence of N points into f (n) (n = 1, ..., N) is transformed into the time domain to obtain the decoded sound signal ^x f (n) (n=1, ..., Nt), and output (step S410). Where Nt is the number of samples in the time domain and is a positive integer. When the frequency domain transform unit 110 of the encoding device 300 performs a transform to the frequency domain other than the MDCT, a transform to the time domain corresponding to the transform may be performed.
[0143] According to the first embodiment, since the encoding process and the decoding process can be switched only when the energy of the high frequency of the input sound signal is small, even when a plurality of encoding processes and decoding processes with different quantization characteristics of the high frequency components are implemented, a decoded sound signal that is less likely to sound unnatural to the listener can be obtained.
[0144] According to the first embodiment, in addition, without actually performing an encoding attempt, it is possible to select an encoding process suitable for the input sound signal from between an encoding process using a spectral envelope based on coefficients that can be transformed into linear prediction coefficients and an encoding process using average energy of coefficients in each divided frequency domain, thereby enabling an encoding process suitable for the input sound signal to be performed with a small amount of calculation processing.
[0145] According to the first embodiment, further, it is possible to select a coding process from a coding process using a spectrum envelope based on coefficients that can be transformed into linear prediction coefficients and a coding process using average energy of coefficients in each divided frequency domain and perform coding. Therefore, regardless of whether the fluctuation of the spectrum of the input sound signal is large or the concentration is high, or whether this is not the case, it is possible to perform a highly efficient coding process regardless of the characteristics of the input sound signal.
[0146] [Second Embodiment]
[0147] In the first embodiment, when the energy of the high-frequency component of the input sound signal is large, the coefficient sequence in the frequency domain of the current frame is always encoded by the same encoding process as the encoding process of the previous frame. However, in the second embodiment, even when the energy of the high-frequency component of the input sound signal is large, it is allowed to encode the coefficient sequence in the frequency domain of the current frame by an encoding process different from the encoding process of the previous frame in a state where the high-frequency component of the input sound signal is sparse.
[0148] The encoding device of the second embodiment can determine the encoding process different from that of the previous frame as the encoding process of the current frame when the energy of the high-frequency component of the input sound signal is small, and when this is not the case, it is determined whether the encoding process different from that of the previous frame can be determined as the encoding process of the current frame or the encoding process the same as that of the previous frame can be determined as the encoding process of the current frame according to the state that the high-frequency component of the input sound signal is sparse.
[0149] The configuration of the encoding device of the second embodiment is the same as that of the first embodiment. Figure 1 The encoding device 300 of the second embodiment is the same as the encoding device 300 of the first embodiment except for the different processing of the switching possibility determination unit 381 and the switching determination unit 383 in the determination unit 380. The structure of the decoding device of the second embodiment is the same as that of the first embodiment. Figure 2 The processing of each unit is also the same as that of the decoding device of the first embodiment. The following describes the switching possibility determination unit 381 and the switching determination unit 383 in the determination unit 380 that perform processing different from that of the encoding device 300 of the first embodiment.
[0150] <Switchability Determination Unit 381>
[0151] The switchability determination unit 381 determines that the switching is possible, that is, it is possible to encode the frequency domain coefficient sequence of the current frame by a coding process different from the coding process for encoding the frequency domain coefficient sequence of the previous frame, when at least one of the magnitude of the energy of the high frequency component of the input sound signal of the previous frame and the magnitude of the energy of the high frequency component of the input sound signal of the current frame is smaller than a predetermined threshold value, and outputs the determination result (step S381). In other cases, neither the switching is determined to be possible nor the switching is determined to be impossible, and information indicating that neither is determined is output as the determination result, or the determination result is not output. As the magnitude of the energy of the high frequency component of the input sound signal, the high frequency energy may be used, or the ratio of the high frequency energy to the total energy may be used, which is the same as the first embodiment.
[0152] <Switch determination unit 383>
[0153] The switching decision unit 383 determines whether the coefficient column in the frequency domain of the current frame is encoded in the first encoding unit 101 or in the second encoding unit 201 based on the switching availability information obtained by the switching availability determination unit 381, the information on which encoding process is suitable obtained by the suitable encoding process determination unit 382, and whether the high-frequency component of the input sound signal obtained from the input sound signal is sparse, and outputs a switching code that is a code that can identify the determined encoding process (step S383B). The output switching code is input to the decoding device 400.
[0154] When the information on the switching feasibility obtained by the switching feasibility determination unit 381 indicates that the switch is possible, that is, when the energy of the high-frequency component of the input acoustic signal is small, the switching determination unit 383 performs the same processing as the switching determination unit 383 of the first embodiment. When the information on the switching feasibility obtained by the switching feasibility determination unit 381 indicates that the switch is not determined as either, or when the determination result is not input to the switching feasibility determination unit 381, that is, when the energy of the high-frequency component of the input acoustic signal is large, it is determined whether or not to allow the frequency domain coefficient sequence of the current frame to be encoded by an encoding process different from the encoding process of the previous frame based on whether the high-frequency component of the input acoustic signal obtained from the input acoustic signal is sparse.
[0155] The following describes an example of the operation of the switching decision unit 383 that is different from the operation of the switching decision unit 383 of the first embodiment, that is, an example of the operation of the switching decision unit 383 when the energy of the high-frequency component of the input sound signal is large. In the following example, as in the first embodiment, the encoding process of the first encoding unit 101 is the encoding process illustrated in non-patent document 1, which uses a spectrum envelope based on coefficients that can be transformed into linear prediction coefficients, and the encoding process of the second encoding unit 201 is the encoding process illustrated in non-patent document 2, which is accompanied by variable length coding of the difference between the logarithm of the average energy of the coefficients of each divided frequency domain and the logarithm of the average energy of the adjacent frequency domain. The switching decision unit 383 performs, for example, Figure 6 Processing of steps S3831B to S3836B.
[0156] The switching decision unit 383 first converts the MDCT coefficient sequence X of the current frame into f (n) (n = 1, ..., N) is divided into Q partial coefficient sequences XS for each P samples f (1)(n)(n=1,...,P),XS f (2)(n)(n=1,...,P),...,XS f(Q)(n)(n=1, ..., P)(step S3831B). P and Q are positive integers satisfying the relationship P×Q=N. P=1 is also acceptable. In addition, it is assumed that the frequency domain coefficient sequence that is the target of the encoding process in the first encoding unit 101 or the second encoding unit 201, that is, the MDCT coefficient sequence X is also used in the switching determination unit 383. f (n) (n = 1, ..., N) structure, but it is also possible to pass through the MDCT coefficient sequence X f The switching decision unit 383 processes a frequency domain coefficient sequence obtained by transforming the frequency domain into the frequency domain by (n) (n=1, . . . , N) different accuracies or methods, such as a power spectrum sequence.
[0157] The switching decision unit 383 then obtains the partial coefficient sequence XS f (1)(n)(n=1,...,P),XS f (2)(n)(n=1,...,P),...,XS f The sequence AVE of the logarithmic values of the average power of each of (Q)(n)(n=1,...,P) XS (q) (q = 1, ..., Q) (step S3832B). The logarithm of the average value of the power of each partial coefficient sequence is AVE calculated by equation (3A): XS (q).
[0158] The switching decision unit 383 further obtains the MDCT coefficient sequence X f The logarithm of the average power of the MDCT coefficient sequence is obtained by equation (9): AVE Total .
[0159]
[0160] The switching decision unit 383 then finds the value of q in the preset Q Low (Among them, 1 Low ) to Q High (Among them, Q Low ≤Q High ≤Q), that is, within the range of one or more partial areas on the predetermined high-frequency side, the AVE that satisfies the formula (10) XS (q), that is, the number of peak areas (step S3834B). M and λ are positive constants.
[0161] AVE XS (q)≥μ·AVE Total +λ (10)
[0162] The switching decision unit 383 then determines that the high-frequency component of the input sound signal of the current frame is sparse when the number of peak regions is less than the threshold value TH3, and determines that the high-frequency component of the input sound signal of the current frame is not sparse when the number of peak regions exceeds the threshold value TH3 (step S3835B). Here, the threshold value TH3 is a value determined according to a predetermined rule so that when the high-frequency component of the input sound signal of the past frame close to the current frame is sparse, it becomes a value larger than when the high-frequency component of the input sound signal of the past frame close to the current frame is not sparse. For example, when the high-frequency component of the input sound signal of the past frame close to the current frame is sparse, a predetermined value TH3_1 is set as the threshold value TH3, and when the high-frequency component of the input sound signal of the past frame close to the current frame is not sparse, a predetermined value TH3_2 which is a value smaller than TH3_1 is set as the threshold value TH3. Here, the past frame close to the current frame refers to, for example, the previous frame or the frame two frames ago. The result of determining whether the high-frequency component of the input acoustic signal of the current frame is sparse is stored in the switching determination unit 383 until at least two frames later.
[0163] The switching decision unit 383 then determines whether the frequency domain coefficient sequence of the current frame is to be encoded by the first encoding unit 101 or the second encoding unit 201 based on the encoding process of the previous frame and the determination result of whether the high frequency components of the input acoustic signal of the current frame and past frames close to the current frame are sparse (step S3836B). In other words, it is determined whether the frequency domain coefficient sequence of the current frame is to be encoded by an encoding process different from the encoding process of the previous frame.
[0164] For example, the switching decision unit 383 determines the MDCT coefficient sequence X of the previous frame. f-1 (n) (n=1, ..., N) is encoded in the first encoding unit 101, when the high-frequency components of the current frame are not sparse, and the high-frequency components of at least one of the previous frame and the frame 2 frames ago are sparse, it can be determined that the MDCT coefficient sequence X of the current frame is f (n) (n=1, ..., N) is encoded in the second encoding unit 201. In other cases, it is determined that the MDCT coefficient sequence X of the current frame f (n) (n=1, ..., N) is encoded in the first encoding unit 101. That is, the switching determination unit 383 performs coding on the MDCT coefficient sequence X of the previous frame. f-1(n)(n=1,...,N) is encoded in the first encoding unit 101. When the high-frequency component of the current frame is not sparse and the high-frequency component of at least one of the previous frame and the frame 2 frames ago is sparse, it is allowed to encode the coefficient column in the frequency domain of the current frame by a coding process different from the coding process of the previous frame. In other cases, it is not allowed to encode the coefficient column in the frequency domain of the current frame by a coding process different from the coding process of the previous frame.
[0165] Furthermore, the switching decision unit 383 determines the MDCT coefficient sequence X of the previous frame. f-1 When (n) (n=1, ..., N) is encoded in the second encoding unit 201, it is possible to determine whether to convert the MDCT coefficient sequence X of the current frame into the MDCT coefficient sequence X of the current frame when (1) the high-frequency components of the current frame are sparse and the high-frequency components of the previous frame are not sparse, or (2) the high-frequency components of the current frame are sparse and the high-frequency components of the previous frame are sparse and the high-frequency components of the frame two frames ago are not sparse. f (n) (n=1, ..., N) is encoded in the first encoding unit 101. In other cases, it is determined that the MDCT coefficient sequence X of the current frame f (n) (n=1, ..., N) is encoded in the second encoding unit 201. That is, the switching determination unit 383 performs coding on the MDCT coefficient sequence X of the previous frame. f-1 (n)(n=1,...,N) is encoded in the second encoding unit 201. In the case where (1) the high-frequency component of the current frame is sparse and the high-frequency component of the previous frame is not sparse, or (2) the high-frequency component of the current frame is sparse and the high-frequency component of the previous frame is sparse and the high-frequency component of the frame 2 frames ago is not sparse, it is allowed to encode the coefficient column in the frequency domain of the current frame by a coding process different from the coding process of the previous frame. In other cases, it is not allowed to encode the coefficient column in the frequency domain of the current frame by a coding process different from the coding process of the previous frame.
[0166] Furthermore, when it is permitted to encode the frequency domain coefficient sequence of the current frame by a coding process different from that of the previous frame, the switching decision unit 383 determines the coding process of the frequency domain coefficient sequence of the current frame based on the information of which coding process is suitable obtained by the suitable coding process determination unit 382. For example, when it is permitted to encode the frequency domain coefficient sequence of the current frame by a coding process different from that of the previous frame, the switching decision unit 383 determines the coding process of the frequency domain coefficient sequence of the current frame even if the MDCT coefficient sequence X of the previous frame is not encoded. f-1 (n) (n=1, ..., N) is encoded in the second encoding unit 201, and when the information on which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates the encoding process of the first encoding unit 101, it is determined that the MDCT coefficient sequence X of the current frame isf (n) (n=1, ..., N) is encoded in the first encoding unit 101. In addition, when it is permitted to encode the coefficient sequence in the frequency domain of the current frame by an encoding process different from the encoding process of the previous frame, the switching determination unit 383 may select the MDCT coefficient sequence X in the previous frame. f-1 (n) (n=1, ..., N) is encoded in the first encoding unit 101, and when the information on which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates the encoding process of the second encoding unit 201, it is determined that the MDCT coefficient sequence X of the current frame is f (n) (n=1, . . . , N) is encoded in the second encoding unit 201.
[0167] Furthermore, even when it is permitted to encode the frequency domain coefficient sequence of the current frame by a coding process different from that of the previous frame, the switching decision unit 383 may encode the frequency domain coefficient sequence corresponding to the input sound signal of the current frame by the same coding process as that of the previous frame, when it is determined based on other information obtained from a component not shown in the coding device 300 that the frequency domain coefficient sequence of the current frame should be encoded by the same coding process as that of the previous frame.
[0168] In addition, in step S3831B, different sampling numbers may be set for each partial coefficient sequence. For example, the MDCT coefficient sequence X of the current frame may be f (n) (n = 1, ..., N) is divided into Q partial coefficient sequences XS f (1)(n)(n=1,...,P1),XS f (2)(n)(n=1,...,P2),...,XS f (Q)(n)(n=1,...,P Q ). P1,P2,...,P Q It satisfies P1+P2+...+P Q =N is a positive integer. In addition, preferably P1, P2, ..., P Q Satisfies P1≤P2≤...≤P Q . Furthermore, Q is a positive integer.
[0169] In addition, when the coding processing suitability determination unit 382 performs the same processing as step S3831B, step S3832B, or step S3833B, the switching decision unit 383 may use the processing result performed by the coding processing suitability determination unit 382 instead of performing step S3831B, step S3832B, or step S3833B.
[0170] [Third Embodiment]
[0171] In the first and second embodiments, one threshold is used to determine the encoding process suitable for the current frame. However, the third embodiment performs determination using two thresholds.
[0172] The structure of the encoding device of the third embodiment is the same as that of the first embodiment. Figure 1 The encoding device 300 of the third embodiment is the same as the encoding device 300 of the first embodiment or the second embodiment except for the different processing of the suitable encoding processing determination unit 382 and the switching determination unit 383 in the determination unit 380. The structure of the decoding device of the third embodiment is the same as that of the first embodiment. Figure 2 The processing of each unit is also the same as that of the decoding device of the first embodiment. The following describes the suitable encoding processing determination unit 382 and the switching determination unit 383 in the determination unit 380 that perform processing different from that of the encoding device 300 of the first embodiment.
[0173] <Encoding suitability determination unit 382>
[0174] Suitable for encoding processing determination unit 382 Figure 7 The coding process suitability determination unit 382 determines whether the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for the coding process of the first coding unit 101 or the coding process of the second coding unit 201. In other words, it determines whether one of the coding processes is sufficient, and outputs the determination result (step S382A).
[0175] An example of the operation of the suitable encoding process determination unit 382 is described below. The suitable encoding process determination unit 382 performs Figure 7 In the following example, the encoding process of the first encoding unit 101 is the encoding process illustrated in non-patent document 1, which uses a spectrum envelope based on coefficients that can be transformed into linear prediction coefficients, and the encoding process of the second encoding unit 201 is the encoding process illustrated in non-patent document 2, which is accompanied by variable length coding of the difference between the logarithm of the average energy of the coefficients in each divided frequency domain and the logarithm of the average energy of the adjacent frequency domain.
[0176] In this example, the coding suitability determination unit 382 determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for coding by the first coding unit 101 when the fluctuation of the spectral envelope of the input sound signal is large and / or the concentration is high; determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for coding by the second coding unit 201 when the fluctuation of the spectral envelope of the input sound signal is small and / or the concentration is low; and determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for either the coding by the first coding unit 101 or the coding by the second coding unit 201 when the fluctuation of the spectral envelope of the input sound signal is medium and / or the concentration is medium, and outputs the determination result.
[0177] When the fluctuation of the spectrum envelope of the input sound signal is of medium degree and / or the concentration is of medium degree, as described later, the switching decision unit 383 determines to encode the coefficient sequence in the frequency domain of the current frame by the same encoding process as the previous frame. That is, the switching decision unit 383 determines the encoding process of the current frame so that the listener will not feel unnatural due to the switching of the encoding process between the previous frame and the current frame. Therefore, the case where the fluctuation of the spectral envelope of the input sound signal is of medium degree and / or the concentration is of medium degree not only includes the case where the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame can be subjected to either the encoding process of the first encoding unit 101 or the encoding process of the second encoding unit 201, or the case where the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for either the encoding process of the first encoding unit 101 or the encoding process of the second encoding unit 201, but also includes the case where it is difficult to tell whether the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for either the encoding process of the first encoding unit 101 or the encoding process of the second encoding unit 201, or the case where the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is likely to be unsuitable for either the encoding process of the first encoding unit 101 or the encoding process of the second encoding unit 201. That is, the above-mentioned judgment of "suitable for either the encoding processing of the first encoding unit 101 or the encoding processing of the second encoding unit 201" can also be read as a judgment of "unable to determine the suitability for either the encoding processing of the first encoding unit 101 or the encoding processing of the second encoding unit 201".
[0178] As a method of estimating the fluctuation or concentration of the spectrum, any method may be adopted, but a structure for estimating the depth of the valley of the spectrum envelope is described. In this structure, when the valley of the spectrum envelope is shallow, it is determined that the fluctuation of the spectrum is small and the concentration is low, when the valley of the spectrum envelope is deep, it is determined that the fluctuation of the spectrum is large and the concentration is high, and when the depth of the valley of the spectrum envelope is medium, it is determined that the fluctuation of the spectrum is medium and the concentration is medium.
[0179] The suitable coding process determination unit 382 performs steps S3821 to S3825 which are the same as those of the suitable coding process determination unit 382 of the first embodiment, and step S3826A which is different from that of the suitable coding process determination unit 382 of the first embodiment. The following describes the parts which are different from the suitable coding process determination unit 382 of the first embodiment.
[0180] After step S3825, the suitable encoding process determination unit 382 performs the following determination process using the threshold values TH2_1 and TH2_2 and outputs the suitable information described later (step S3826A).
[0181] The AVE suitable for the coding process determination unit 382 in all partial areas XS (q) The average value E and the AVE of the valley area XS The average value of (q) V When the difference is smaller than the predetermined threshold value TH2_1, it is estimated that the spectrum has shallow valleys, the spectrum envelope has little fluctuations, or the spectrum has low concentration. Therefore, it is determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding process of the second encoding unit 201.
[0182] In addition, the AVE suitable for the coding process determination unit 382 in all partial areas XS (q) The average value E and the AVE of the valley area XS The average value of (q) V When the difference is greater than a predetermined threshold value TH2_2 which is a value greater than the threshold value TH2_1, it is estimated that the spectrum has a deep valley, a large fluctuation of the spectrum envelope, or a spectrum with high concentration, and therefore, it is determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding processing of the first encoding unit 101.
[0183] In addition, the AVE suitable for the coding process determination unit 382 in all partial areas XS (q) The average value E and the AVE of the valley area XS The average value of (q) VWhen the difference is greater than or equal to the threshold value TH2_1 and less than or equal to the threshold value TH2_2, it is estimated that the depth of the valley of the spectrum is medium, the fluctuation of the spectrum envelope is medium, or the concentration is medium, so the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame can be subjected to either the encoding process of the first encoding unit 101 or the encoding process of the second encoding unit 201. In other words, it is determined that the coefficient sequence is suitable for either the encoding process of the first encoding unit 101 or the encoding process of the second encoding unit 201.
[0184] Then, the suitable coding process determination unit 382 outputs suitable information, which is information about the suitable coding process. The suitable information is the determination result of the suitable coding process determination unit 382, and may also be referred to as information on whether one or both coding processes are suitable.
[0185] The coding suitability determination unit 382 may be configured to output information indicating suitability for the coding process by the first coding unit 101 or information indicating suitability for the coding process by the second coding unit 201 only when it is determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for either the coding process by the first coding unit 101 or the coding process by the second coding unit 201, and not output a determination result when it is determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame can be subjected to either the coding process by the first coding unit 101 or the coding process by the second coding unit 201, that is, is suitable for either the coding process by the first coding unit 101 or the coding process by the second coding unit 201.
[0186] <Switch determination unit 383>
[0187] The switching decision unit 383 determines whether the coefficient sequence in the frequency domain of the current frame is encoded in the first encoding unit 101 or in the second encoding unit 201 based on the information on whether the switching is possible obtained by the switching possibility determination unit 381 and the information on whether one or both of the encoding processes are suitable obtained by the suitable encoding process determination unit 382, that is, the information on the suitable encoding process (suitability information), and outputs a code that can determine the determined encoding process, that is, a switching code (step S383A). The output switching code is input to the decoding device 400. Here, the switching decision unit 383 determines to encode the coefficient sequence in the frequency domain of the current frame by the same encoding process as the previous frame regardless of which encoding process is suitable for the current frame when the switching is not possible. In addition, the switching decision unit 383 determines to encode the coefficient sequence in the frequency domain of the current frame by the same encoding process as the previous frame when the switching is possible and the current frame is suitable for either the encoding process of the first encoding unit 101 or the encoding process of the second encoding unit 201. In addition, when the switching decision unit 383 is switchable and the current frame is suitable for one of the encoding processes of the first encoding unit 101 and the encoding process of the second encoding unit 201, regardless of which encoding process the previous frame was, it is decided to encode the coefficient column in the frequency domain of the current frame through the encoding process suitable for the current frame.
[0188] An example of the operation of the switching decision unit 383 is described below. In the following example, the encoding process of the first encoding unit 101 is an encoding process using a spectrum envelope based on coefficients that can be transformed into linear prediction coefficients as exemplified in non-patent document 1, and the encoding process of the second encoding unit 201 is an encoding process using variable length coding with a difference between the logarithm of the average energy of the coefficients in each divided frequency domain and the logarithm of the average energy of the adjacent frequency domain as exemplified in non-patent document 2.
[0189] The switching decision unit 383 determines whether the switching possibility information obtained by the switching possibility determination unit 381 indicates that switching is not possible, and / or whether the information (suitability information) on which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates whether the MDCT coefficient sequence X of the previous frame is suitable. f-1 (n) (n=1, ..., N) or when the encoding process of the first encoding unit 101 and the encoding process of the second encoding unit 201 are both suitable, the MDCT coefficient sequence X of the previous frame is f-1 The same encoding process as the encoding process of (n) (n=1, ..., N) is determined as the MDCT coefficient sequence X of the current frame. f (n) (n=1,...,N) encoding processing.
[0190] That is, the switching decision unit 383 selects the MDCT coefficient sequence X of the previous frame. f-1 (n) (n=1, ..., N) is encoded in the first encoding unit 101, and when the switching possibility information obtained by the switching possibility determination unit 381 indicates that switching is not possible, it is determined to be the MDCT coefficient sequence X of the current frame. f (n) (n=1, ..., N) is also encoded in the first encoding unit 101. In addition, the switching determination unit 383 selects the MDCT coefficient sequence X of the previous frame. f-1 (n) (n=1, ..., N) is encoded in the first encoding unit 101, and when the information (suitability information) of which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates the encoding process of the first encoding unit 101, it is determined to be the MDCT coefficient sequence X of the current frame. f (n) (n=1, ..., N) is also encoded in the first encoding unit 101. In addition, the switching determination unit 383 selects the MDCT coefficient sequence X of the previous frame. f-1 (n) (n=1, ..., N) is encoded in the first encoding unit 101, and when the information (suitability information) obtained by the suitable encoding process determination unit 382 indicates that any one of the encoding process of the first encoding unit 101 and the encoding process of the second encoding unit 201 is suitable, it is determined to be the MDCT coefficient sequence X of the current frame f (n) (n=1, . . . , N) is also encoded in the first encoding unit 101.
[0191] In addition, the switching decision unit 383 selects the MDCT coefficient sequence X of the previous frame. f-1 (n) (n=1, ..., N) is encoded in the second encoding unit 201, and when the switching possibility information obtained by the switching possibility determination unit 381 indicates that switching is not possible, it is determined to be the MDCT coefficient sequence X of the current frame. f (n) (n=1, ..., N) is also encoded in the second encoding unit 201. In addition, the switching determination unit 383 selects the MDCT coefficient sequence X of the previous frame. f-1 (n) (n=1, ..., N) is encoded in the second encoding unit 201, and when the information (suitability information) of which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates the encoding process of the second encoding unit 201, it is determined to be the MDCT coefficient sequence X of the current frame. f (n) (n=1, ..., N) is also encoded in the second encoding unit 201. In addition, the switching determination unit 383 selects the MDCT coefficient sequence X of the previous frame. f-1(n) (n=1, ..., N) is encoded in the second encoding unit 201, and when the information (suitability information) obtained by the suitable encoding process determination unit 382 indicates that any one of the encoding process of the first encoding unit 101 and the encoding process of the second encoding unit 201 is suitable, it is determined to be the MDCT coefficient sequence X of the current frame f (n) (n=1, . . . , N) is also encoded in the second encoding unit 201.
[0192] The switching decision unit 383 obtains the switching availability information from the switching availability determination unit 381 indicating that switching is possible, and the information (suitability information) indicating which encoding process is suitable from the suitable encoding process determination unit 382 indicates whether the MDCT coefficient sequence X of the previous frame is suitable. f-1 In the case of a coding process different from the coding process of the previous frame, the MDCT coefficient sequence X f-1 (n) (n = 1, ..., N) different encoding processes are determined to be the MDCT coefficient sequence X of the current frame f That is, the switching decision unit 383 performs the coding process of the MDCT coefficient sequence X of the previous frame. f-1 (n) (n=1, ..., N) is encoded in the first encoding unit 101, the switching possibility information obtained by the switching possibility determination unit 381 indicates that switching is possible, and the information (suitability information) on which encoding process is suitable obtained by the suitable encoding process determination unit 382 indicates the encoding process of the second encoding unit 201, it is determined that the MDCT coefficient sequence X of the current frame is f (n) (n=1, ..., N) is encoded in the second encoding unit 201. In addition, the switching determination unit 383 selects the MDCT coefficient sequence X of the previous frame. f-1 When (n) (n=1, ..., N) is encoded in the second encoding unit 201, the information on the switching possibility obtained by the switching possibility determination unit 381 indicates that switching is possible, and the information on which encoding process is suitable (suitability information) obtained by the suitable encoding process determination unit 382 indicates the encoding process of the first encoding unit 101, it is determined that the MDCT coefficient sequence X of the current frame is f (n) (n=1, . . . , N) is encoded in the first encoding unit 101.
[0193] In addition, when the coding processing suitability determination unit 382 is configured not to output a determination result when it is determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for any one of the coding processing of the first coding unit 101 and the coding processing of the second coding unit 201, the switching decision unit 383 may perform processing in which the information on which coding processing is suitable (suitability information) indicates that the coding processing is suitable for any one of the coding processing of the first coding unit 101 and the coding processing of the second coding unit 201 without inputting information on the suitable coding processing.
[0194] [First Modification]
[0195] In determining whether the input sound signal of the current frame is suitable for the coding process using the spectral envelope based on the coefficients that can be transformed into the linear prediction coefficients as exemplified in Non-Patent Document 1 or the coding process involving variable length coding of the difference between the logarithm of the average energy of each coefficient in the divided frequency domain and the logarithm of the average energy of the adjacent frequency domain as exemplified in Non-Patent Document 2, in addition to the magnitude or concentration of the fluctuation of the spectral envelope of the input sound signal, the determination may include other information.
[0196] For example, even when the coefficient sequence in the frequency domain corresponding to the input sound signal of the previous frame is encoded by the first encoding unit 101, the switching possibility determination unit 381 determines that the switching is possible, and the encoding suitability determination unit 382 determines that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding process of the second encoding unit 201, when it is determined based on other information obtained from a component not shown in the encoding device 300 that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame should be encoded by the encoding process of the first encoding unit 101, the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame may be encoded by the first encoding unit 101. That is, the encoding device 300 may be configured such that, when the coefficient sequence in the frequency domain corresponding to the input sound signal of the previous frame is encoded by the first encoding unit 101, the switching possibility determination unit 381 determines that the switching is possible, and the encoding suitability determination unit 382 determines that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for encoding by the second encoding unit 201, it is possible to determine that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is encoded by the second encoding unit 201.
[0197] Furthermore, conversely, even if the coefficient sequence in the frequency domain corresponding to the input sound signal of the previous frame is encoded by the second encoding unit 201, the switchability determination unit 381 determines that the switch is possible, and the encoding suitability determination unit 382 determines that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding process of the first encoding unit 101, when it is determined based on other information obtained from a component not shown in the encoding device 300 that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame should be encoded by the encoding process of the second encoding unit 201, the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame may be encoded by the second encoding unit 201. That is, the encoding device 300 may be configured such that, when the coefficient sequence in the frequency domain corresponding to the input sound signal of the previous frame is encoded by the second encoding unit 201, the switching possibility determination unit 381 determines that the switching is possible, and the encoding suitability determination unit 382 determines that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for encoding by the first encoding unit 101, it is possible to determine that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is encoded by the first encoding unit 101.
[0198] Furthermore, for example, in the encoding device 300 of the third embodiment, even if the frequency domain coefficient sequence corresponding to the input sound signal of the previous frame is encoded by the first encoding unit 101 and the encoding process suitability determination unit 382 determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for any one of the encoding process of the first encoding unit 101 and the encoding process of the second encoding unit 201, if the switching possibility determination unit 381 determines that switching is possible and determines based on other information obtained by a component not shown in the encoding device 300 that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame should be encoded by the encoding process of the second encoding unit 201, the frequency domain coefficient sequence corresponding to the input sound signal of the current frame may be encoded by the second encoding unit 201.
[0199] Furthermore, conversely, even if the coefficient sequence in the frequency domain corresponding to the input sound signal of the previous frame is encoded by the second encoder 201 and the encoding process suitability determination unit 382 determines that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for any of the encoding processes of the second encoder 201 of the encoding process of the first encoder 101, if the switching possibility determination unit 381 determines that switching is possible and determines based on other information obtained by a component not shown in the encoding device 300 that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame should be encoded by the encoding process of the first encoder 101, the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame may be encoded by the first encoder 101.
[0200] That is, the encoding device 300 of the third embodiment may be configured such that, when the switching possibility determination unit 381 determines that the switch is possible and the encoding process suitability determination unit 382 determines that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for any one of the encoding processes of the first encoding unit 101 and the encoding process of the second encoding unit 201, it is possible to determine that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is encoded by the same encoding process as that of the previous frame.
[0201] [Second Modification]
[0202] The switching availability information obtained by the switching availability determination unit 381 may not be used to determine whether to encode the frequency domain coefficient column of the current frame in the first encoding unit 101 or in the second encoding unit 201. In this case, the determination unit 380 may not include the switching availability determination unit 381.
[0203] In this case, the switching decision unit 383 does not use the switching feasibility information obtained by the switching feasibility determination unit 381, but decides whether to encode the coefficient column in the frequency domain of the current frame in the first encoding unit 101 or in the second encoding unit 201 based on the suitability information obtained by the coding processing suitability determination unit 382, and outputs the code that can determine the determined coding processing, i.e., the switching code.
[0204] For example, when the coding suitability determination unit 382 determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for coding by the first coding unit 101, the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is encoded by the first coding unit 101. When the coding suitability determination unit 382 determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for coding by the second coding unit 201, the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is encoded by the second coding unit 201.
[0205] In this case, as in the first modification, determination including other information may be performed. For example, even when the coding suitability determination unit 382 determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for coding by the first coding unit 101, if it is determined based on other information obtained from a component not shown in the coding device 300 that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame should be coded by the coding by the second coding unit 201, the frequency domain coefficient sequence corresponding to the input sound signal of the current frame may be coded by the second coding unit 201.
[0206] On the contrary, even when the coding suitability determination unit 382 determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for coding by the second coding unit 201, when it is determined based on other information obtained from a component not shown in the coding device 300 that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame should be coded by the coding by the first coding unit 101, the frequency domain coefficient sequence corresponding to the input sound signal of the current frame may be coded by the first coding unit 101.
[0207] That is, when the coding suitability determination unit 382 determines that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the coding process of the first coding unit 101, it is possible to determine that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is coded by the coding process of the first coding unit 101. Also, when the coding suitability determination unit 382 determines that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the coding process of the second coding unit 201, it is possible to determine that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is coded by the coding process of the second coding unit 201.
[0208] Furthermore, for example, in the encoding device 300 of the third embodiment, when the encoding process suitability determination unit 382 determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for any one of the encoding process of the first encoding unit 101 and the encoding process of the second encoding unit 201, when it is determined based on other information obtained from a component not shown in the encoding device 300 that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame should be encoded by the encoding process of the first encoding unit 101, the frequency domain coefficient sequence corresponding to the input sound signal of the current frame may be encoded by the first encoding unit 101.
[0209] Furthermore, in a case where the coding suitability determination unit 382 determines that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame is suitable for any one of the coding processes of the first coding unit 101 and the coding process of the second coding unit 201, in a case where it is determined based on other information obtained from a component not shown in the coding device 300 that the frequency domain coefficient sequence corresponding to the input sound signal of the current frame should be encoded by the coding process of the second coding unit 201, the frequency domain coefficient sequence corresponding to the input sound signal of the current frame may be encoded by the second coding unit 201.
[0210] That is, the encoding device 300 of the third embodiment may be configured such that, when the encoding processing suitability determination unit 382 determines that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for any one of the encoding processing of the first encoding unit 101 and the encoding processing of the second encoding unit 201, it is possible to determine that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is encoded by the same encoding processing as that of the previous frame.
[0211] In the above-mentioned embodiments, when the calculated value and the threshold are compared, if the calculated value and the threshold are the same value, it is sufficient to set the value to be classified into any one of the two adjacent cases with the threshold as the boundary. That is, the case above a certain threshold may be regarded as a case greater than the threshold, and the case smaller than the threshold may be regarded as a case below the threshold. In addition, the case greater than a certain threshold may be regarded as a case above the threshold, and the case below the threshold may be regarded as a case smaller than the threshold.
[0212] For example, in the first embodiment, the decision unit 380 may determine a different encoding process from that of the previous frame as the encoding process of the current frame when at least one of the magnitude of the energy of the high-frequency component of the input sound signal of the previous frame and the magnitude of the energy of the high-frequency component of the input sound signal of the current frame is below a predetermined threshold value (step S380).
[0213] Furthermore, in the second embodiment, the switching possibility determination unit 381 may determine that switching is possible, that is, that the frequency domain coefficient sequence of the current frame can be encoded by a coding process different from the coding process for encoding the frequency domain coefficient sequence of the previous frame, when at least one of the magnitude of the energy of the high-frequency component of the input sound signal of the previous frame and the magnitude of the energy of the high-frequency component of the input sound signal of the current frame is below a predetermined threshold value, and output the determination result.
[0214] In the first embodiment, the AVE suitable for the encoding process determination unit 382 in all partial areas XS (q) The average value E and the AVE of the valley area XS The average value of (q) V If the difference between AVE and AVE is smaller than the predetermined threshold value TH2, it is estimated that the spectrum has shallow valleys, few fluctuations in the spectrum envelope, or a spectrum with low concentration. Therefore, it can be determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding process of the second encoding unit 201. XS (q) The average value E and the AVE of the valley area XS The average value of (q) VWhen the difference is greater than the threshold value TH2, it is estimated that the spectrum has a deep valley, the spectrum envelope has large fluctuations, or the spectrum has a high concentration. Therefore, it can be determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding processing of the first encoding unit 101.
[0215] In the third embodiment, the AVE of the coding process determination unit 382 is adapted to all partial areas. XS (q) The average value E and the AVE of the valley area XS The average value of (q) V 1 is greater than the predetermined threshold value TH2_2, which is a value greater than the threshold value TH2_1, it is estimated that the spectrum has a deep valley, a large fluctuation of the spectrum envelope, or a high concentration spectrum, so it can be determined that the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame is suitable for the encoding process of the first encoding unit 101. In this case, the encoding process determination unit 382 determines the AVE in all partial regions. XS (q) The average value E and the AVE of the valley area XS The average value of (q) V When the difference is greater than or equal to the threshold value TH2_1 and less than the threshold value TH2_2, it is estimated that the depth of the valley of the spectrum is medium, the fluctuation of the spectrum envelope is medium, or the concentration is medium. Therefore, the coefficient sequence in the frequency domain corresponding to the input sound signal of the current frame can also be encoded by either the encoding process of the first encoding unit 101 or the encoding process of the second encoding unit 201.
[0216] The processes described in the encoding device and the encoding method may be executed not only in time series according to the order described but also in parallel or individually according to the processing capability of the device executing the processes or as needed.
[0217] In addition, when each step in the encoding method is implemented by a computer, the processing content of the functions that the encoding method should have is described in a program. Then, the program is executed on the computer, so that each step is implemented on the computer.
[0218] The program describing the processing contents can be recorded in a computer-readable recording medium. The computer-readable recording medium may be any medium such as a magnetic recording device, an optical disk, a magneto-optical recording medium, or a semiconductor memory.
[0219] Furthermore, each processing unit may be configured by executing a predetermined program on a computer, or at least a part of the processing contents may be realized in hardware.
[0220] In addition, it is needless to say that appropriate changes can be made without departing from the spirit of the present invention.
Claims
1. A coding method for coding an input sound signal for each frame of a predetermined time interval by coding processing determined between coding processing in a first coding step and coding processing in a second coding step, characterized in that: The encoding method comprises: a step of determining, when at least one of the magnitude of energy of the high frequency component of the input sound signal of the previous frame and the magnitude of energy of the high frequency component of the input sound signal of the current frame is equal to or less than a predetermined threshold value, enabling a coding process different from that of the previous frame to be determined as the coding process of the current frame; The first encoding step encodes a coefficient sequence in the frequency domain corresponding to the input sound signal using a spectral envelope based on coefficients that can be transformed into linear prediction coefficients corresponding to the input sound signal; as well as The second encoding step encodes the frequency domain coefficient sequence corresponding to the input sound signal with variable length coding, wherein the difference is a difference between a logarithm of average energy of the coefficients of each divided frequency domain and a logarithm of average energy of an adjacent frequency domain, In the determining step, when the difference between the average power of all regions of the input sound signal in the current frame and the average power of the partial region of the valley is less than a predetermined threshold, it is determined that the current frame is encoded by the second encoding step, and when the difference between the average power of all regions of the input sound signal in the current frame and the average power of the partial region of the valley is greater than a predetermined threshold, it is determined that the current frame is encoded by the first encoding step, The partial area of the valley is an area smaller than any of the two adjacent elements.
2. A coding method for coding an input sound signal for each frame of a predetermined time interval by coding processing determined between coding processing in a first coding step and coding processing in a second coding step, characterized in that: The encoding method comprises: a step of determining whether to determine a coding process different from that of the previous frame as the coding process of the current frame when at least one of the magnitude of energy of the high-frequency component of the input sound signal of the previous frame and the magnitude of energy of the high-frequency component of the input sound signal of the current frame is equal to or less than a predetermined threshold value, and, if not, determining whether to determine a coding process different from that of the previous frame as the coding process of the current frame or to determine the same coding process as that of the previous frame as the coding process of the current frame according to a state in which the high-frequency component of the input sound signal is sparse, The encoding method also has: The first encoding step encodes a coefficient sequence in the frequency domain corresponding to the input sound signal using a spectral envelope based on coefficients that can be transformed into linear prediction coefficients corresponding to the input sound signal; as well as The second encoding step encodes the frequency domain coefficient sequence corresponding to the input sound signal with variable length coding, wherein the difference is a difference between a logarithm of average energy of the coefficients of each divided frequency domain and a logarithm of average energy of an adjacent frequency domain, The determining step is configured to determine that the current frame is encoded by the second encoding step when the difference between the average power of all regions of the input sound signal in the current frame and the average power of the partial region of the valley is less than a predetermined threshold, and to determine that the current frame is encoded by the first encoding step when the difference between the average power of all regions of the input sound signal in the current frame and the average power of the partial region of the valley is greater than a predetermined threshold, The partial area of the valley is an area smaller than any of the two adjacent elements.
3. A coding device that encodes an input sound signal for each frame of a predetermined time interval by performing a coding process determined between a coding process of a first coding unit and a coding process of a second coding unit, wherein: The encoding device comprises: The decision unit is configured to determine, when at least one of the magnitude of energy of the high-frequency component of the input sound signal of the previous frame and the magnitude of energy of the high-frequency component of the input sound signal of the current frame is equal to or less than a predetermined threshold, a coding process different from that of the previous frame as the coding process of the current frame, The first encoding unit encodes a coefficient sequence in the frequency domain corresponding to the input sound signal using a spectral envelope based on coefficients that can be transformed into linear prediction coefficients corresponding to the input sound signal; and The second encoding unit encodes the frequency domain coefficient sequence corresponding to the input sound signal with variable length coding, wherein the difference is a difference between a logarithm of average energy of each coefficient of the divided frequency domain and a logarithm of average energy of an adjacent frequency domain, the decision unit is configured to determine that the current frame is encoded by the second coding unit when a difference between an average value of power of all regions of the input sound signal in the current frame and an average value of power of a partial region of the valley is less than a predetermined threshold, and to determine that the current frame is encoded by the first coding unit when a difference between an average value of power of all regions of the input sound signal in the current frame and an average value of power of a partial region of the valley is greater than a predetermined threshold, The partial area of the valley is an area smaller than any of the two adjacent elements.
4. A coding device that encodes an input sound signal for each frame of a predetermined time interval by performing a coding process determined between a coding process of a first coding unit and a coding process of a second coding unit, wherein: The encoding device comprises: a decision unit that, when at least one of the magnitude of energy of the high-frequency component of the input sound signal of the previous frame and the magnitude of energy of the high-frequency component of the input sound signal of the current frame is less than or equal to a predetermined threshold, determines that a coding process different from that of the previous frame can be determined as the coding process of the current frame, and, when not, determines whether a coding process different from that of the previous frame can be determined as the coding process of the current frame or the same coding process as that of the previous frame is determined as the coding process of the current frame, according to a state in which the high-frequency component of the input sound signal is sparse; The encoding device also has: The first encoding unit encodes a coefficient sequence in the frequency domain corresponding to the input sound signal using a spectral envelope based on coefficients that can be transformed into linear prediction coefficients corresponding to the input sound signal; and The second encoding unit encodes the frequency domain coefficient sequence corresponding to the input sound signal with variable length coding, wherein the difference is a difference between a logarithm of average energy of each coefficient of the divided frequency domain and a logarithm of average energy of an adjacent frequency domain, the decision unit is configured to determine that the current frame is encoded by the second coding unit when a difference between an average value of power of all regions of the input sound signal in the current frame and an average value of power of a partial region of the valley is less than a predetermined threshold, and to determine that the current frame is encoded by the first coding unit when a difference between an average value of power of all regions of the input sound signal in the current frame and an average value of power of a partial region of the valley is greater than a predetermined threshold, The partial area of the valley is an area smaller than any of the two adjacent elements.
5. A program product comprising a program for causing a computer to execute each step of the encoding method according to claim 1 or 2.
6. A computer-readable recording medium recording a program for causing a computer to execute each step of the encoding method according to claim 1 or 2.
