ADAPTIVE PCM AND DPCM (ADPCM)

Một phần của tài liệu Digital signal processing using MATLAB 3rd edition slicer (Trang 633 - 637)

In general, the power in a speech signal varies slowly with time. PCM and DPCM encoders, however, are designed on the basis that the speech signal power is constant, and hence the quantizer is fixed. The efficiency

and performance of these encoders can be improved by having them adapt to the slowly time-variant power level of the speech signal.

In both PCM and DPCM the quantization errorq(n) resulting from a uniform quantizer operating on a slowly varying power level input signal will have a time-variant variance (quantization noise power). One im- provement that reduces the dynamic range of the quantization noise is the use of an adaptive quantizer.

Adaptive quantizers can be classified as feedforward or feedback. A feedforward adaptive quantizer adjusts its step size for each signal sample, based on a measurement of the input speech signal variance (power). For example, the estimated variance, based as a sliding window estimator, is

ˆ

σn+12 = 1 M

n+1

k=n+1−M

s2(k) (12.18)

Then the step size for the quantizer is

∆ (n+ 1) = ∆(nσn+1 (12.19) In this case it is necessary to transmit ∆ (n+ 1) to the decoder in order for it to reconstruct the signal.

A feedback adaptive quantizer employs the output of the quantizer in the adjustment of the step size. In particular, we may set the step size as

∆ (n+ 1) =α(n)∆(n) (12.20)

where the scale factor α(n) depends on the previous quantizer output.

For example, if the previous quantizer output is small, we may select α(n)<1 in order to provide for finer quantization. On the other hand, if the quantizer output is large, then the step size should be increased to reduce the possibility of signal clipping. Such an algorithm has been successfully used in the encoding of speech signals. Figure 12.5 illustrates such a (3-bit) quantizer in which the step size is adjusted recursively according to the relation

∆ (n+ 1) = ∆(n)ãM(n)

where M(n) is a multiplication factor whose value depends on the quan- tizer level for the samples(n), and ∆(n) is the step size of the quantizer for processings(n). Values of the multiplication factors optimized for speech encoding have been given by [14]. These values are displayed in Table 12.1 for 2-, 3-, and 4-bit quantization for PCM and DPCM.

In DPCM the predictor can also be made adaptive. Thus in ADPCM the coefficients of the predictor are changed periodically to reflect the changing signal statistics of the speech. The linear equations given by (12.11) still apply, but the short-term autocorrelation function of s(n), rss(m) changes with time.

FIGURE 12.5 Example of a quantizer with an adaptive step size ([10])

12.3.1 ADPCM STANDARD

Figure 12.6 illustrates, in block diagram form, a 32,000 bps ADPCM encoder and decoder that has been adopted as an international (CCITT) standard for speech transmission over telephone channels. The ADPCM encoder is designed to accept 8-bit PCM compressed signal samples at 64,000 bps, and by means of adaptive prediction and adaptive 4-bit quantization to reduce the bit rate over the channel to 32,000 bps. The ADPCM decoder accepts the 32,000 bps data stream and reconstructs the signal in the form of an 8-bit compressed PCM at 64,000 bps. Thus we have a configuration shown in Figure 12.7, where the ADPCM encoder/

decoder is embedded into a PCM system. Although the ADPCM encoder/

TABLE 12.1 Multiplication factors for adaptive step size adjustment ([9])

PCM DPCM

2 3 4 2 3 4

M(1) 0.60 0.85 0.80 0.80 0.90 0.90

M(2) 2.20 1.00 0.80 1.60 0.90 0.90

M(3) 1.00 0.80 1.25 0.90

M(4) 1.50 0.80 1.70 0.90

M(5) 0.80 1.20

M(6) 0.80 1.60

M(7) 0.80 2.00

M(8) 0.80 2.40

FIGURE 12.6 ADPCM block diagram

decoder could be used directly on the speech signal, the interface to the PCM system is necessary in practice in order to maintain compatibility with existing PCM systems that are widely used in the telephone network.

The ADPCM encoder accepts the 8-bit PCM compressed signal and expands it to a 14-bit-per-sample linear representation for processing. The predicted value is subtracted from this 14-bit linear value to produce a difference signal sample that is fed to the quantizer. Adaptive quantiza- tion is performed on the difference signal to produce a 4-bit output for transmission over the channel.

Both the encoder and decoder update their internal variables, based only on the ADPCM values that are generated. Consequently, an ADPCM

FIGURE 12.7 ADPCM interface to PCM system

decoder, including an inverse adaptive quantizer, is embedded in the encoder so that all internal variables are updated, based on the same data. This ensures that the encoder and decoder operate in synchronism without the need to transmit any information on the values of internal variables.

The adaptive predictor computes a weighted average of the last six dequantized difference values and the last two predicted values. Hence this predictor is basically a 2-pole (p= 2) and 6-zero (m= 6) filter governed by the difference equation given by (12.16). The filter coefficients are updated adaptively for every new input sample.

At the receiving decoder and at the decoder that is embedded in the encoder, the 4-bit transmitted ADPCM value is used to update the inverse adaptive quantizer, whose output is a dequantized version of the difference signal. This dequantized value is added to the value generated by the adaptive predictor to produce the reconstructed speech sample.

This signal is the output of the decoder, which is converted to compressed PCM format at the receiver.

12.3.2 PROJECT 12.3: ADPCM

The objective of this project is to gain familiarity with, and understanding of, ADPCM and its interface with a PCM encoder/decoder (transcoder).

As described, the ADPCM transcoder is inserted between the PCM com- pressor and the PCM expander as shown in Figure 12.7. Use the already developed MATLAB PCM and DPCM modules for this project.

The input to the PCM-ADPCM transcoder system can be supplied from internally generated waveform data files, just as in the case of the PCM project. The output of the transcoder can be plotted. Compar- isons should be made between the output signal from the PCM-ADPCM transcoder with the signal from the PCM transcoder (PCM Project 12.1), and with the original input signal.

Một phần của tài liệu Digital signal processing using MATLAB 3rd edition slicer (Trang 633 - 637)

Tải bản đầy đủ (PDF)

(671 trang)