Analysis of Two-stage Quantizer with Embedded G . 711 Quantizer and Segmental Uniform Quantizer

In this paper a novel two-stage quantizer with the embedded G.711 quantizer is proposed for speech signal processing. The first processing stage, where the input signal is quantized with the G.711 quantizer, is followed by the second stage where the segmental uniform quantizer performs the reduction of the quantization error introduced in the first stage. In this way higher signal quality, measured by signal to quantization noise ratio, is achieved in comparison with the G.711 quantizer while no bit rate reduction is performed. Particularly, in the second stage two additional bits are introduced. Although the expected quality gain, as a result of increasing the overall bit rate for 2 bit/sample, is around 12 dB, the gain achieved with the proposed quantizer is 14 dB. This additional quality gain of 2 dB proves the advantage of the proposed two-stage quantizer. DOI: http://dx.doi.org/10.5755/j01.eee.19.2.1107


I. INTRODUCTION
Quantization is a lossy procedure of digital signal processing which reduces the signal quality by introducing an irreversible error.Higher signal quality, usually measured by SQNR (signal to quantization noise ratio), can be achieved by increasing the bit rate [1], [2].However, due to the limited memory resources the bit rate needs to be limited.Therefore, the development of novel quantizer models is mainly based on the increase of SQNR for the specified bit rate, or it is directed toward the bit rate reduction while the SQNR is kept constant [1], [2].
The public switched telephone networks around the world are mostly subjected to the G.711 standard regulations.The quantizer defined with G.711 standard can achieve almost constant SQNR in a wide range of variances for audio and speech signals [3].This widely applied standard served as a basis for development of novel quantizer models where the goal is to achieve a higher and constant SQNR within the observed variance range.The challenge to provide the gain in the performance over the G.711 quantizer has driven much of the research in this area and several quantizers have been developed and eventually adopted in international standards [4], [5].In these papers for a wideband audio and Manuscript received January 12, 2012; accepted April 30, 2012.
speech signal processing a two-stage quantization has been proposed.Since the compatibility with the G.711 standard is of great importance, the G.711 quantizer has been implemented in the first quantization stage and vector quantizer in the second quantization stage.In this paper, focusing only on the telephone speech signal frequency band, we propose a two-stage quantization with a scalar quantizer in the second stage instead of the vector quantizer.The reasons we have chosen the scalar quantization are its greater simplicity and faster signal processing, which is of importance for the real time speech communications [1], [2].In addition, the goal of this paper is to propose a quantizer which will not only meet, but notably exceed the SQNR of the G.711 quantizer [3].The advantage of the proposed sample-based quantizer is that it has lower encoding delay than the frame-based switched semilogarithmic quantizer proposed in [6].While in [6] and [7] the compression degree has been changed by altering the codebook size, in the case of the proposed two-stage quantizer only goal is to achieve higher signal quality in comparison with the G.711 quantizer without reduction of the bit rate value.
After this introductory section, in this paper a detailed description of the proposed quantizer model is provided.Then, numerical results are presented and discussed.Finally, the last section is devoted to the conclusions which summarize the contribution achieved in the paper, i.e. emphasize the importance of the proposed two-stage quantizer.

II. MODEL OF THE PROPOSED TWO-STAGE QUANTIZER
The G.711 quantizer is a piecewise uniform scalar quantizer based on a piecewise linear approximation to the A-law or µ-law compressor characteristics [3].The support region of the G.711 quantizer, [-x max , x max ], is divided into 2L = 16 unequal segments, each of which has an equal number of uniform cells.Particularly, the G.711 quantizer defines a symmetric piecewise uniform scalar quantizer by 8 bits of resolution and L = 8 positive segments increased in width by a factor of 2 for each successive segment having 16 cells [3].The piecewise uniform scalar quantizers are widely used in practice due to their simple encoding procedure, which, in contrast to that of the nonuniform quantizer models, does not require the full search of the quantizer code Analysis of Two-stage Quantizer with Embedded G. 711 Quantizer and Segmental Uniform Quantizer book [1], [2].Fig. 1 gives the schematic overview of the proposed twostage quantizer in which the G.711 quantizer, as the first stage, and segmental uniform quantizer, as the second processing stage are implemented.In the first stage input signal samples are quantized with the G.711 quantizer, while the difference between so quantized samples and input samples is quantized with the segmental uniform quantizer.The uniform quantizer, used for the processing of the signal of difference, is called a segmental because its support region [-∆ i /2, ∆ i /2], is adapted on the basis of the step size ∆ i from the corresponding i-th segment [x i l , x i h ] to which the current sample belongs: Parameter x max denotes the maximal amplitude of the G.711 quantizer, while m is the number of cells within each segment of the piecewise uniform G.711 quantizer.In the Fig. 1, a sequence of input samples is denoted with x(n), where n denotes the index of the current sample to be quantized.The sequence of the quantized samples at the G.711 quantizer output is given by: ( ) ( ) Accordingly, the signal of difference d(n) is defined with quantization error ε G.711 introduced by G.711 quantizer In the second quantization stage, signal of difference is processed with the segmental uniform quantizer where ε u is the introduced error.The output of the two-stage quantizer now has the following form ( ) ( ) ( ) The total error introduced by the two-stage quantization process is As the possible error values introduced with the G.711 quantizer ranges within [-∆ i /2, ∆ i /2], the step size of segmental uniform quantizer with n u quantization levels is Previous expressions confirm the correctness of our decision to include the second quantization stage because at the end of it the total error, which ranges within [-∆ u /2, ∆ u /2], is obviously decreased.This is the manner how in this paper the signal quality increase is provided.
In order to evaluate the quality which can be achieved with the proposed quantizer we use distortion along with signal to quantization noise ratio.The total distortion is the sum of granular distortion D g where L denotes the number of segments in the first quadrant, i indicates the ordinal number of the segment, and j indicates the ordinal number of the cell within the i-th segment of the G.711 quantizer.Finally, k indicates the ordinal number of the cell of the segmental uniform quantizer.The decision thresholds and reproduction levels of the proposed two-stage quantizer, denoted with x ijk and y ijk respectively, can be defined with: where 1 ,..., denotes the thresholds of the cells within the same i-th segment of the G.711 quantizer.These thresholds can be further calculated with where x i denotes the segment thresholds defined with ( ) The first two sums in the expression (10) refer to the model of the piecewise uniform G.711 quantizer, while the third sum (per k) defines the contribution to the granular distortion in the second quantization stage.The probability density function (PDF) of a signal at the input of the proposed quantizer model is denoted with p(x), while the reproduction level from the last cell of the last segment is denoted with y N .Asymptotic analysis, applicable in the case of a large number of quantization levels (N>>1) assumes that p(x) can be considered as a constant inside the k-th cell of the segmental uniform quantizer, p(x) ≈ p(y ijk ) [1].Applying this approximation yields By further introducing probabilities P ij , P i : The expression for the granular distortion gets the following form where where x i = x i l and x i+1 = x i h are the thresholds of the i-th segment.By assuming the Laplacian PDF of the speech signal values at the input of the proposed quantizer model [1], [2] ( ) and by approximating y N with 2 The following explicit expressions for the granular distortion and the overload distortion can be derived: By summing values of the granular and the overload distortion, the total distortion D of the proposed quantizer can be determined.The total distortion and signal variance σ 2 determine the signal to quantization noise ratio In order to estimate the quality gain obtained with the proposed two-stage quantizer in comparison with the G.711 quantizer, we can define the average signal to quantization noise ratio ( ) where q represents the number of SQNR values included in the calculation.
Let us define the manner of speech signal samples encoding while they are passing through both processing stages.It is obvious that for defining of the sample sign one bit is sufficient.In this way, the part of the G.711 quantizer's support region (positive part or negative part) to which the current sample belongs is determined.To more precisely determine the sample location, the segment to which it belongs to must be specified.For this purpose three bits are used.Four more bits are used for specifying the cell to which the current sample belongs.So, at the output of the firststage code words are eight bits long.In the second processing stage, segmental uniform quantizer introduces two more bits.This means that code words, at the end of the encoding process, are ten bits long and that the bit rate of the proposed quantizer is 10 bit/sample.

III. NUMERICAL RESULTS
This section provides the analysis of numerical results obtained by employing the mathematic relations listed in the previous section.As mentioned above, SQNR is the proper measure for estimating the achieved quality of the quantized signal.To compare the signal qualities obtained with the proposed quantizer and the G.711 quantizer, in the Fig. 2 are given functional dependencies of SQNR on the normalized signal variance for different values of the maximal amplitude x max .The assumed speech signal dynamic range of variances is 40 dB.From Fig. 2 one can conclude that the proposed two-stage quantizer achieves higher quality than the G.711 quantizer, and that the quality gain has the maximal value of 14 dB when the proposed quantizer designed for maximal amplitude of x max = 65 is employed.This maximal value of the quality gain represents a difference between average SQNR av values of the two-stage quantizer designed for x max = 65 and the G.711 quantizer.
-  As we have already explained, the second quantizer increases the overall bit rate for 2 bit/sample.Typically, with the bit rate increase for 2 bit/sample SQNR is increased for 12 dB (or 6 dB per one bit [1], [2]).However, the proposed quantizer has achieved 2 dB higher quality gain than the one expected.This is much higher gain than the one achieved in [4] and [5] where the obtained quality gain is for about 0.5 dB higher than the one theoretically expected.This is due to the unsuitable choice of the second stage quantizer.

IV. CONCLUSIONS
In this paper the two-stage scalar quantizer with the embedded G.711 quantizer and the segmental uniform scalar quantizer has been proposed.By increasing the overall bit rate for 2 bit/sample in the second processing stage instead of the theoretically expected gain of 12 dB, the proposed quantizer has achieved the quality gain of 14 dB in comparison with the G.711 quantizer.The presented results show the advantage of the proposed two-stage quantizer, not only over the G.711 quantizer, but also over the two-stage quantizer model with vector quantizer embedded in the second stage.Due to the compatibility our solution can be widely used as a suitable and not very expensive improvement or replacement of the G.711 quantizer, especially in PSTN and other systems for speech transmission.Also, our model can be considered for implementation in the low-frequency part of the quantizer that is a wide-band extension of the G.711 quantizer.All above mentioned recommends the proposed two-stage quantizer with the embedded G.711 quantizer for highquality quantization of wide class of signals with Laplacian PDF.

Fig. 1 .
Fig. 1.The schematic view of the proposed two-stage quantizer model.

Fig. 2 .
Fig. 2. The functional dependence of SQNR on the normalized variance of input signal for different values of maximal amplitude xmax and σref = 1.
the k-th step size of the considered segmental uniform quantizer having the support region [-∆ i /2, ∆ i /2].The probability P i , that the current value of the sample belongs to the i-th segment of the G.711 quantizer, is defined with