Patent Publication Number: US-5633936-A

Title: Method and apparatus for detecting a near-end speech signal

Description:
TECHNICAL FIELD OF THE INVENTION 
     The present invention relates in general to telecommunication signal processing and more particularly to a method and apparatus for detecting a near-end speech signal. 
     BACKGROUND OF THE INVENTION 
     An acoustic echo canceler is one of the most desirable capabilities in a hands free telephone environment. The acoustic echo canceler prevents a speaker from hearing one&#39;s own voice during a phone conversation. The speech signal of a far-end speaker travels through a communication channel, a loud speaker, ambient air, a microphone, and through the communication channel back to the far-end speaker. In such a situation the far-end speaker can hear one&#39;s own voice returned with some delay, causing a distraction during phone conversations. The acoustic echo canceler cancels the far-end speech signal before the telephone system sends out the signal to the far-end speaker. Therefore, the purpose of the acoustic echo canceler is to cancel the far-end speech so that the far-end speech does not travel back to the far-end speaker. However, the acoustic echo canceler should not cancel or distort the near-end talker&#39;s speech when it exists. The near-end speech detection logic circuit is one of the critical components of the acoustic echo canceler. Conventional acoustic echo cancelers use near-end speech detection circuits that do not operate well in low signal to noise ratio environments, such as car phone applications during vehicle operation. Therefore, it is desirable to have an acoustic echo canceler with near-end speech detection that performs well in low signal to noise ratio environments. 
     SUMMARY OF THE INVENTION 
     From the foregoing, it may be appreciated that a need has arisen for an acoustic echo canceler with near-end speech detection that operates in low signal to noise ratio environments. A need has also arisen for an echo canceler with near-end speech detection that operates regardless of the surrounding noise environment. 
     In accordance with the present invention, a method and apparatus for detecting a near-end speech signal are provided that substantially eliminate or reduce disadvantages and problems associated with conventional acoustic echo canceler devices. 
     According to an embodiment of the present invention, there is provided a method of detecting a near-end speech signal that includes determining an average power of an acoustic echo canceler output signal over a selected sampling period in response to a received send-in signal from a microphone and an adaptive filter output signal of an adaptive filter. The adaptive filter output signal is generated by a far-end speech signal that is filtered as well as the received send-in signal. An average of the filtered far-end speech signal and an average of the filtered received send-in signal are determined over the selected sampling period. An acoustic echo path gain/loss is determined by taking a ratio of the average filtered received send-in signal and the average filtered far-end speech signal. A long term power average is determined for the acoustic echo canceler output signal and is compared to the average power of the acoustic echo canceler output signal. A long term average of the acoustic echo path gain/loss is determined and compared against the acoustic echo path gain/loss in order to detect a presence of the near-end speech signal. 
     The present invention provides various technical advantages over conventional acoustic echo canceler devices. For example, one technical advantage is in detecting the near-end speech signal regardless of the operating environment. Another technical advantage is in delineating near-end speech from environmental noise. Other technical advantages are readily apparent to one skilled in the art from the following figures, descriptions, and claims. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     For a more complete understanding of the present invention and the advantages thereof, reference is now made to the following description taken in conjunction with the accompanying drawings, wherein like reference numerals represent like parts, in which: 
     FIG. 1 illustrates a block diagram of an acoustic echo canceler with a near-end speech detection circuit; 
     FIG. 2 illustrates a block diagram of a dual structure for an adaptive filter within the acoustic echo canceler; 
     FIG. 3 illustrates a block diagram of the process steps for detecting a near-end speech signal; and 
     FIG. 4 illustrates a graph showing the detection of near-end speech. 
    
    
     DETAILED DESCRIPTION OF THE INVENTION 
     FIG. 1 is a block diagram of an acoustic echo canceler 10. Acoustic echo canceler 10 includes an adaptive filter circuit 12 and a near-end speech detection circuit 14. Adaptive filter circuit 12 includes an adaptive filter 16 and a summing circuit 18. Adaptive filter 16 receives an s(t) far-end speech signal 20 and generates a y(t) response signal 22 in response to a near-end detection signal 24 from near-end detection circuit 14. Adaptive filter circuit 12 generates an e(t) acoustic echo canceler output signal 26 by combining y(t) response signal 22 with an x(t) send-in signal 28 received from a microphone circuit 30. The e(t) acoustic echo canceler output signal 26 is transmitted back to the far-end speaker. Adaptive filter circuit 12 cancels the far-end speech within x(t) send-in signal 28 in order to prevent the far-end speaker from hearing one&#39;s own voice. The relationships of x(t), y(t), s(t), and e(t) are shown by the following equations. ##EQU1## where h(k) is echo path impulse response, 
     s(t-k) is the far-end speech signal, and 
     n(t) is the noise component. ##EQU2## where b(k) represents the coefficients of adaptive filter 16 and is an estimate of the echo path impulse response. 
     
         e(t)=x(t)-y(t)                                             (3) 
    
     Near-end detection circuit 14 includes a high pass filter 32 that filters s(t) far-end speech signal 20. Filtered s(t) far-end speech signal 20 is then processed within a far-end sampling circuit 34 that determines an average of the filtered s(t) far-end speech signal 20. Similarly, near-end speech detection circuit 14 includes a filter 36 that filters x(t) send-in signal 28 received from microphone circuit 30. Filtered x(t) send-in signal 28 is then processed by a send-in sampling circuit 38 that determines an average of filtered x(t) send-in signal 28. The sampling period used for far-end sampling circuit 34 is the same as the sampling period used for send-in sampling circuit 36. After filtering and averaging have been performed, s(t) far-end speech signal 20 and x(t) send-in signal 28 are combined in a divider circuit 40 that generates a γ(t) acoustic echo path gain/loss signal 42. A near-end detector 44 receives γ(t) acoustic echo path gain/loss signal 42 and a ρ.sub.γ long term average signal 46 of γ(t) acoustic echo path gain/loss signal 42 through a long term echo path averaging circuit 48. 
     Near-end speech detection circuit 14 also receives e(t) acoustic echo canceler output signal 26 at a power sampling circuit 50 that determines an e(t) average power signal 51 of e(t) acoustic echo canceler output signal 26. Power sampling circuit 50 has the same sampling period as the other sampling circuits within near-end detection circuit 14. Near-end detector 44 receives the e(t) average power signal 51 and a ρ e  long term power average signal 53 of e(t) acoustic echo canceler output signal 26 through a long term echo canceler averaging circuit 52. Near-end detector 44 detects the presence of near-end speech in response to γ(t) acoustic echo path gain/loss signal 42, ρ.sub.γ long term average signal 46, e(t) average power signal 51, and ρ e  long term power average signal 53 in order to generate near-end detection signal 24 for driving adaptive filter 16 of adaptive filter circuit 12. 
     In operation, a far-end speaker transmits s(t) far-end speech signal 20 that is heard by a near-end speaker 60 over a speaker 62. The x(t) send-in signal 28 is a combination of far-end speech, noise, and near-end speech picked up by microphone circuit 30. The noise characteristic of x(t) send-in signal 28 has significant low frequency components. In automobile applications, the noise components below 1.5 kHz are about 20 dB stronger than those above 1.5 kHz during highway driving conditions. Therefore, x(t) send-in signal 28 is fed through a high pass filter 36 to eliminate that portion of x(t) send-in signal 28 that is below 1.5 kHz in order to eliminate much of the noise component. The s(t) far-end speech signal 20 passes through high pass filter 32 in order to eliminate components below 1.5 kHz in order to be consistent with the filtering of x(t) send-in signal 28. Once the low frequency components have been filtered out, s(t) far-end speech signal 20 and x(t) send-in signal 28 are averaged over a selected sampling period by far-end sampling circuit 34 and send-in sampling circuit 38 respectively. The following equations show the requirements for averaging s(t) far-end speech signal 20 and x(t) send-in signal 28. ##EQU3## where α is a selected constant, 
     M is the sampling period, 
     HPF is a high pass filter operation, 
     P is a p-norm function, 
     x(t-m) is a previous sampling period value, and 
     s(t-m) is a previous sampling period value. 
     After averaging, divider circuit 40 generates a γ(t) acoustic echo path gain/loss signal 42 that is the ratio of the averaged filtered x(t) send-in signal 28 over the averaged filtered s(t) far-end speech signal 20. Long term echo path averaging circuit 48 generates a ρ.sub.γ long term average signal 46 of the γ(t) acoustic echo path gain/loss signal 42. The ρ.sub.γ long term average signal 46 is updated whenever there is no near-end speech present as determined by near-end detector 44. Near-end detector 44 compares the γ(t) acoustic echo path gain/loss signal 42 with ρ.sub.γ long term average signal 46 in order to determine the presence of near-end speech. The following equations represent the γ(t) acoustic echo path gain/loss signal 42, the ρ.sub.γ long term average signal 46 and their comparison for near-end speech detection. ##EQU4## where μ&lt;&lt;1. 
     
         γ(t)&gt;k.sub.2 ρ.sub.γ                       (8) 
    
     representing the first condition, where k 2  is a constant greater than 1. 
     Near-end speech detection may also be achieved by performing a power comparison of e(t) acoustic echo canceler output signal 26. Power sampling circuit 50 receives e(t) acoustic echo canceler output signal 26 and generates an e(t) average power signal 51 of e(t) acoustic echo canceler output signal 26. Long term echo canceler averaging circuit 52 generates a ρ e  long term power average signal 53 of e(t) average power signal 51. The ρ e  long term power average signal 53 is updated whenever there is no near-end speech present as determined by near-end detector 44. Near-end detector 44 compares e(t) average power signal 51 to ρ e  long term power average signal 53 in order to determine the presence of near-end speech. The following equations represent the e(t) average power signal 51, the ρ e  long term power average signal 53, and their comparison for near-end speech detection. ##EQU5## where α is a constant, 
     M is the sampling period, 
     P is the p-norm function, and is the previous sampling period value. ##EQU6## where μ&lt;&lt;1. 
     
         e(t)&gt;k.sub.1 ρ.sub.e                                   (11) 
    
     representing the second condition, where k 1  is a constant greater than 1. 
     Though the presence of near-end speech may be detected through this simple power comparison, near-end detector 44 checks to see if two conditions are satisfied that indicate the presence of near-end speech. The first condition that must be satisfied is that γ(t) acoustic echo path gain/loss signal 42 must be greater than a selected multiple of ρ.sub.γ long term average signal 46. The second condition that must be satisfied is that the e(t) average power signal 51 must be greater than a selected multiple of ρ e  long term power average signal 53. When these two conditions are met, near-end detector 44 generates an indication signal 24 that provides an indication of the presence of near-end speech. 
     Though adaptive filter 16 has been shown as a single path structure of one adaptive filter, a dual path structure using two filters may also be used. FIG. 2 shows a dual path structure for adaptive filter 16. The dual path structure of adaptive filter 16 contains two filters, a background filter 70 and a foreground filter 72. For the dual path structure, foreground filter 72 is an adaptive filter and loads its foreground coefficients 71 to background filter 70 once in a frame period if the power estimate E f  (t) of the foreground signal is less than the power estimate E b  (t) of the background signal. The background filter is an adaptive filter and loads its background coefficients 73 to foreground filter 72 if the power estimate E b  (t) of the background signal is less than the power estimate E f  (t) of the foreground signal. The background coefficients 73 of background filter 70 are also loaded to foreground filter 72 upon the detection of near-end speech. The following equations show the power estimates for the foreground and background filters of a dual structure adaptive filter. ##EQU7## where α is a constant, 
     E f  (t-m) is a previous sampling period value, 
     E b  (t-m) is a previous sampling period value, 
     M is the sampling period, 
     P is the p-norm function, 
     e f  (t-k) is the foreground acoustic output signal, and 
     e b  (t-k) is the background acoustic output signal. 
     
         if E.sub.f (t)&lt;ζE.sub.b (t)                           (14) 
    
     then load foreground coefficients into background filter. 
     
         if E.sub.b (t)&lt;ζE.sub.f (t)                           (15) 
    
     then backload background coefficients into foreground filter, where ζ is a constant. 
     During detection of near-end speech, the power of the near-end speech signal changes quickly. The power of the noise component does not change quickly as compared to the near-end speech signal component. Therefore, the noise condition does not result in a sudden transition in power fluctuation as exhibited by the near-end speech signal. Since the sudden transitions of the near-end speech signal also cause too many decision swaps on the near-end speech, unstable outputs of acoustic echo canceler 10 may occur. Thus, near-end speech detection circuit 14 allows for a hangover period of several frames when the near-end speech is detected in order to reduce too many decision swaps between the near-end speech and no near-end speech conditions. 
     The hangover period implemented upon near-end speech detection is shown in an operational flow chart for acoustic echo canceler 10 at FIG. 3. Operational flow begins at a start block 80 where acoustic echo canceler 10 is initialized. The initialization of acoustic echo canceler 10 includes setting a hangover count to zero and installing default values for parameters used by acoustic echo canceler 10. Process flow proceeds along two paths corresponding to the two conditions used in determining the presence of near-end speech. Along the first path representing the first condition, acoustic echo canceler 10 receives s(t) far-end speech signal 28 at high pass filter 32 and also receives x(t) send-in signal 28 at high pass filter 36, as shown by block 82. After filtering is complete, process flow proceeds to power computation and ratio block 84 where s(t) far-end speech signal 20 and x(t) send-in signal 28 are averaged by far-end sampling circuit 34 and send-in sampling circuit 38 respectively. After averages x(t) and s(t) are obtained for each signal, divider circuit 40 generates a γ(t) acoustic echo path gain/loss signal 42 that is sent to compare block 86 of the operational flow chart. Process flow proceeds to block 88 where γ(t) acoustic echo path gain/loss signal 42 is subjected to a long term average determination. At compare block 86, the γ(t) acoustic echo path gain/loss signal 42 is compared to the ρ.sub.γ long term average in order to interrogate the first condition indicating the presence of near end speech. 
     Along the second path representing the second condition, adaptive filter block 90 receives s(t) far-end speech signal 20 and x(t) send-in signal 18 at adaptive filter circuit 12. Adaptive filter circuit 12 generates e(t) acoustic echo canceler output signal 26. Process flow continues to power computation block 92 where an e(t) average power is determined for e(t) acoustic echo canceler output signal 26. The resulting e(t) average power is sent to compare block 86 for further processing. Process flow continues to long term average block 94 where the e(t) average power is processed into a ρ e  long term power average of e(t) acoustic echo canceler output signal 26. Compare block 86 compares the e(t) average power of e(t) acoustic echo canceler output signal 26 to its ρ e  long term power average in order to interrogate the second condition indicating the presence of near-end speech. 
     Process flow proceeds to decision block 96 where a determination is made as to whether both the first and second conditions are satisfied. If both conditions are satisfied, process flow proceeds to decision block 98 in order to determine the status of the hangover count. If the hangover count is at a zero value, as would be the case upon initial detection of near-end speech, process flow proceeds to block 100 where the hangover count is set to a selected interval value. For an acoustic echo canceler 10 having a dual path structure for adaptive filter 16, the coefficients of background filter 70 are backloaded to foreground filter 72. Process flow then proceeds back to the beginning of the near-end speech detection operation. 
     If the first and second conditions are no longer satisfied at decision block 96, process flow proceeds to decision block 102 where a check is made to determine whether the hangover count is greater than zero. If the hangover count is greater than zero, process flow proceeds to block 104 where the hangover count is decremented by a value of one. Process flow then continues to the beginning of the near-end speech detection operation. If the hangover count is equal to zero at decision block 102, process flow returns to the beginning of the near-end speech detection operation for single filter structures of adaptive filter 16. 
     For a dual path structure within adaptive filter 16, process flow continues to decision block 106 where a check is made to see if the power E f  (t) out of foreground filter 72 is less than the power E b  (t) out of background filter 70. If the foreground power E f  (t) is less than the background power E b  (t), process flow proceeds to block 108 where the coefficients of the foreground filter 72 are loaded into background filter 70. After loading, process flow returns to the beginning of the near-end speech detection operation. If the foreground power E f  (t) is not less than the background power E b  (t), process flow proceeds to decision block 110 where a check is made to see if the background power E b  (t) is less than the foreground power E f  (t). If such a case exists, process flow proceeds to block 112 where the coefficients of background filter 70 are loaded into foreground filter 72. After backloading, process flow returns to the beginning of the near-end speech detection operation. If the background power E b  (t) is not less than the foreground power E f  (t) at this stage, process flow returns to the beginning of the near-end speech detection operation without performing any loading or backloading to or from the foreground filter 72 and the background filter 70. 
     FIG. 4 shows an example of the effectiveness of the near-end speech detection. The graph of FIG. 4 illustrates a speech file collected in an automobile during highway driving. Near-end speech detection is shown by shaded bars. The following values for parameters in the equations were used: ##EQU8## The equations for ρ e  and ρ.sub.γ were modified to avoid long term averages that may be too big for subsequent near-end speech detection. The equations for ρ e  and ρ.sub.γ are as follows, showing when and if updating is to be performed: ##EQU9## Near-end speech detection occurs in noisy conditions having low signal to noise ratios. 
     In summary, an acoustic echo canceler includes a near-end speech detection circuit that determines the presence of near-end speech regardless of the operating environment of the acoustic echo canceler. The near-end speech detection circuit compares an acoustic echo path gain/loss signal with its long term average as a first condition and also compares the average power of an acoustic echo canceler output signal with its long term average as a second condition. For optimum near-end speech detection, both conditions must be satisfied. Both conditions are satisfied when the acoustic echo path gain/loss signal is greater than its long term average in the first condition and the average power of the acoustic echo canceler output signal is greater than its long term average in the second condition. The near-end detection circuit implements a hangover count to prevent unstable outputs of the acoustic echo canceler caused by frequent sudden transitions between the detection of near end speech and no near end speech. 
     Thus, it is apparent that there has been provided, in accordance with the present invention, a method and apparatus for detecting a near-end speech signal that satisfies the advantages set forth above. Although the preferred embodiment has been described in detail, it should be understood that various changes, substitutions, and alterations can be made herein. For example, different parameters and different comparisons of the far-end speech signal, send-in signal, and acoustic echo canceler output signal may be made while still providing for the detection of near-end speech. Other examples are readily ascertainable to one skilled in the art without departing from the spirit and scope of the present invention as defined by the following claims.