An echo cancellation system and method
By introducing a time delay module and a residual echo suppression module into the voice communication system, combined with dual-talk detection, the time coverage of the echo path is extended, achieving efficient echo cancellation with low resource consumption and solving the problem of balancing system resources and echo suppression effect.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SPREADTRUM COMMUNICATION (SHANGHAI) CO LTD
- Filing Date
- 2026-01-27
- Publication Date
- 2026-06-05
AI Technical Summary
In existing technologies, adaptive filtering algorithms struggle to balance system resource consumption and echo suppression in voice communication systems, resulting in poor echo suppression performance.
A time delay module is introduced to delay the reference signal. Combined with an adaptive filter and a residual echo suppression module, the time coverage of the echo path is extended by doubly estimating the echo signal, and the suppression intensity is adjusted in real time by a dual-talk detection module.
While reducing computational complexity and memory footprint, it achieves echo cancellation performance comparable to high-order filters, resolving the contradiction between resource consumption and echo suppression effect, and ensuring that echoes are fully suppressed and near-end speech is not damaged.
Smart Images

Figure CN122157632A_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of voice communication technology, and in particular to an echo cancellation system and method. Background Technology
[0002] In voice communication systems, acoustic echo cancellation (AEC) technology uses an adaptive filter (ADF) to simulate the echo path in order to estimate and eliminate the linear echo that is played from the far end through the speaker and picked up by the near end microphone, thereby ensuring call quality.
[0003] In related technologies, adaptive filtering algorithms based on FIR structures are often used to model echo paths and eliminate echo signals. However, there is an irreconcilable contradiction between system resource consumption and echo suppression effect in these adaptive filtering algorithms, making it impossible to achieve both simultaneously. Summary of the Invention
[0004] This disclosure provides an echo cancellation system and method.
[0005] According to a first aspect of this disclosure, an echo cancellation system is provided, the system comprising: an adaptive filter, a residual echo suppression module, a dual-talk detection module, and a time delay module;
[0006] The adaptive filter is used to receive the microphone signal and the reference signal under the same processing frame, and to process the processing frame through adaptive filtering to obtain the estimated echo signal and the residual signal. The delay module is used to apply a preset delay to the reference signal and output the delayed reference signal. The dual-talk detection module is used to perform dual-talk detection on the microphone signal and the residual signal to obtain the dual-talk status detection result; The residual echo suppression module is used to determine the total residual echo estimate based on the estimated echo signal, the residual signal, and the time-delayed reference signal, and to suppress the residual signal using the total residual echo estimate and the dual-talk state detection result, and output the target signal.
[0007] According to a second aspect of this disclosure, an echo cancellation method is provided, applied to the echo cancellation system described above, the method comprising: The microphone signal and reference signal under the same processing frame are received, and the processing frame is processed by adaptive filtering to obtain the estimated echo signal and residual signal; A preset time delay is applied to the reference signal, and the delayed reference signal is output. Perform dual-talk detection on the microphone signal and the residual signal to obtain the dual-talk status detection result; The total residual echo estimate is determined based on the estimated echo signal, the residual signal, and the time-delayed reference signal. The residual signal is then suppressed using the total residual echo estimate and the dual-talk state detection result to output the target signal.
[0008] Further, the step of performing dual-talk detection on the microphone signal and the residual signal to obtain the dual-talk state detection result includes: The echo rejection ratio is calculated based on the microphone signal and the residual signal; The echo suppression ratio is compared with a preset threshold. If the echo suppression ratio is less than the preset threshold, the processing frame is determined to be in dual-talk state, and a dual-talk state detection result indicating the dual-talk state is output.
[0009] Further, determining the total residual echo estimate based on the estimated echo signal, the residual signal, and the time-delayed reference signal includes: Determine a first coefficient and a second coefficient; wherein the first coefficient is used to characterize the weight of the residual echo component in the estimated echo signal, and the second coefficient is used to characterize the correlation between the time-delayed reference signal and the residual echo component in the residual signal; The first residual echo estimate is determined based on the estimated echo signal and the first coefficient; The second residual echo estimate is determined based on the time-delayed reference signal and the second coefficient; The total residual echo estimate is determined based on the first residual echo estimate and the second residual echo estimate.
[0010] Further, determining the first coefficient and the second coefficient includes: Calculate the first cross-correlation value between the estimated echo signal and the residual signal in the frequency domain; Calculate the autocorrelation value of the estimated echo signal; The ratio of the first cross-correlation value to the autocorrelation value is determined as the first coefficient.
[0011] Further, determining the first coefficient and the second coefficient includes: Calculate the second cross-correlation value between the delayed reference signal and the residual signal in the frequency domain; Calculate the first power spectrum of the residual signal and the second power spectrum of the time-delayed reference signal; The product of the second cross-correlation value and the conjugate value of the second cross-correlation value is determined as the first calculation result, and the product of the first power spectrum and the second power spectrum is determined as the second calculation result; The second coefficient is determined based on the ratio of the first calculation result to the second calculation result.
[0012] Further, determining the first residual echo estimate based on the estimated echo signal and the first coefficient includes: The product of the amplitude of the estimated echo signal and the first coefficient is determined as the first residual echo estimate.
[0013] Further, determining the second residual echo estimate based on the time-delayed reference signal and the second coefficient includes: The product of the amplitude of the time-delayed reference signal and the second coefficient is determined as the second residual echo estimate.
[0014] Further, determining the total residual echo estimate based on the first residual echo estimate and the second residual echo estimate includes: The first residual echo estimate and the second residual echo estimate are weighted and summed based on preset weights to obtain the total residual echo estimate; or, the larger value between the first residual echo estimate and the second residual echo estimate is determined as the total residual echo estimate.
[0015] Further, the step of suppressing the residual signal using the total residual echo estimation and the dual-talk state detection results to output the target signal includes: The total residual echo estimate is corrected based on the dual-talk state detection results to obtain the corrected echo estimate; The residual signal is suppressed based on the corrected echo estimation, and the target signal is output.
[0016] According to a third aspect of this disclosure, an electronic device is provided. The electronic device includes a memory and a processor, wherein the memory stores a computer program, and the processor executes the program to implement the method described above.
[0017] According to a fourth aspect of this disclosure, a computer-readable storage medium is provided having a computer program stored thereon that, when executed by a processor, implements the methods described above.
[0018] According to a fifth aspect of this disclosure, a computer program product is provided. The computer program product includes a computer program that, when executed by a processor, implements the methods described above.
[0019] This disclosure provides an echo cancellation system and method, the system comprising: an adaptive filter, a residual echo suppression module, a dual-talk detection module, and a time delay module; the adaptive filter is used to receive a microphone signal and a reference signal under the same processing frame, and to process the processing frame through adaptive filtering to obtain an estimated echo signal and a residual signal; the time delay module is used to apply a time delay of a preset length to the reference signal and output the time-delayed reference signal; the dual-talk detection module is used to perform dual-talk detection on the microphone signal and the residual signal to obtain a dual-talk state detection result; the residual echo suppression module is used to determine the total residual echo estimate based on the estimated echo signal, the residual signal, and the time-delayed reference signal, and to suppress the residual signal through the total residual echo estimate and the dual-talk state detection result, and output the target signal.
[0020] As described above, the echo cancellation system provided by this disclosure introduces a time delay module to delay the reference signal, enabling the residual echo suppression module to perform dual estimation by combining the estimated echo signal of the current frame with the time-delayed reference signal. This effectively expands the system's time coverage of the echo path, thus accurately estimating and suppressing echo tails that are difficult to eliminate with traditional methods, even when using a lower-order adaptive filter. Simultaneously, the dual-talk detection module determines the call status in real time based on the microphone signal and residual signal, and dynamically adjusts the intensity of residual echo suppression. This ensures that echoes are sufficiently suppressed while preventing damage to near-end speech during dual-talk. The echo cancellation system provided by this disclosure achieves echo cancellation performance comparable to higher-order filters while significantly reducing computational complexity and memory consumption, resolving the technical contradiction in existing technologies where echo suppression effectiveness and resource consumption are difficult to balance. Attached Figure Description
[0021] The above and other objects, features, and advantages of this disclosure will become more apparent from the more detailed description of the embodiments thereof in conjunction with the accompanying drawings. The drawings are provided to further illustrate the embodiments of this disclosure and form part of the specification. They are used together with the embodiments of this disclosure to explain the disclosure and do not constitute a limitation thereof. In the drawings, the same reference numerals generally represent the same components or steps.
[0022] Figure 1 A schematic diagram of the structure of an echo cancellation system provided in an exemplary embodiment of this disclosure; Figure 2 A flowchart of an echo cancellation method provided as an exemplary embodiment of this disclosure; Figure 3 One of the flowcharts for an echo cancellation method provided as another exemplary embodiment of this disclosure; Figure 4 A second flowchart of an echo cancellation method provided for another exemplary embodiment of this disclosure; Figure 5 A structural block diagram of an electronic device provided as an exemplary embodiment of this disclosure; Figure 6 A structural block diagram of a computer system provided as an exemplary embodiment of this disclosure; Figure 7 A structural block diagram of a computer program product provided for an exemplary embodiment of this disclosure. Detailed Implementation
[0023] Embodiments of this disclosure will now be described in more detail with reference to the accompanying drawings. While some embodiments of this disclosure are shown in the drawings, it should be understood that this disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this disclosure. It should be understood that the accompanying drawings and embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of protection of this disclosure.
[0024] It should be understood that the steps described in the method embodiments of this disclosure may be performed in different orders and / or in parallel. Furthermore, the method embodiments may include additional steps and / or omit the steps shown. The scope of this disclosure is not limited in this respect.
[0025] The term "comprising" and its variations as used herein are open-ended, meaning "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Definitions of other terms will be given in the description below. It should be noted that the concepts of "first", "second", etc., used in this disclosure are only used to distinguish different devices, modules, or units, and are not intended to limit the order of functions performed by these devices, modules, or units or their interdependencies.
[0026] It should be noted that the terms "a" and "a plurality of" used in this disclosure are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".
[0027] The names of messages or information exchanged between multiple devices in the embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.
[0028] It is understood that before using the technical solutions disclosed in the various embodiments of this disclosure, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in this disclosure in an appropriate manner in accordance with relevant laws and regulations, and user authorization should be obtained.
[0029] For example, upon receiving a user's active request, a prompt message is sent to the user to explicitly inform them that the requested operation will require the acquisition and use of the user's personal information. This allows the user to independently choose whether to provide personal information to the software or hardware, such as the electronic device, application, server, or storage medium performing the operations of this disclosed technical solution, based on the prompt message.
[0030] As an optional but non-limiting implementation, in response to a user's active request, sending a prompt message to the user can be done via a pop-up window, where the prompt message can be presented in text format. Furthermore, the pop-up window can also include a selection control allowing the user to choose "agree" or "disagree" to provide personal information to the electronic device. It is understood that the above notification and user authorization process is merely illustrative and does not constitute a limitation on the implementation of this disclosure; other methods that comply with relevant laws and regulations may also be applied to the implementation of this disclosure.
[0031] In one embodiment, such as Figure 1 As shown, an echo cancellation system is provided, including: an adaptive filter 1, a residual echo suppression module 2, a dual-talk detection module 3, and a time delay module 4. The adaptive filter 1 is used to receive a microphone signal 101 and a reference signal 102 under the same processing frame, and process the processing frame through adaptive filtering to obtain an estimated echo signal 105 and a residual signal 106. The time delay module 4 is used to apply a time delay of a preset length to the reference signal 102 and output a time-delayed reference signal 103. The dual-talk detection module 3 is used to perform dual-talk detection on the microphone signal 101 and the residual signal 106 to obtain a dual-talk state detection result. The residual echo suppression module 2 is used to determine the total residual echo estimate based on the estimated echo signal 105, the residual signal 106, and the time-delayed reference signal 103, and suppress the residual signal 106 through the total residual echo estimate and the dual-talk state detection result to output a target signal 109.
[0032] Specifically, adaptive filter 1 corresponds to Figure 1The ADF in the process receives the microphone signal 101 (mic signal) and the reference signal 102 (ref signal) under the same processing frame. The adaptive filter 1 processes the microphone signal 101 and the reference signal 102 under the same processing frame using adaptive filtering algorithms such as NLMS (Normalized Minimum Mean Square Error), FDAF (Frequency Domain Adaptive Filtering), or Kalman (Kalman Filtering) to simulate the echo path. The adaptive filter 1 outputs two signals: an estimated signal for the linear echo of the current frame, namely the estimated echo signal 105, and a preliminary echo cancellation signal obtained by subtracting the estimated echo signal 105 from the original microphone signal 101, namely the residual signal 106.
[0033] Delay module 4 corresponds to Figure 1 The delay function in the input reference signal 102 applies a preset time delay to the input reference signal 102, thereby outputting a reference signal containing historical information, i.e., delaying the reference signal 103.
[0034] Dual-talk detection module 3 corresponding Figure 1 The DTD in the system receives the original microphone signal 101 and the residual signal 106 after being processed by the adaptive filter 1. By analyzing these two signals, such as calculating the echo suppression ratio and comparing it with a threshold, it determines whether the current call is in a dual-talk state where near-end speech and far-end echo coexist, and outputs the corresponding dual-talk state detection result.
[0035] Residual echo suppression module 2 corresponds to Figure 1 The RES module in the system integrates three input signals: the estimated echo signal 105 and the residual signal 106 from the adaptive filter 1, and the time-delayed reference signal 103 from the time-delay module 4, to construct and calculate a more accurate and comprehensive total residual echo estimate. Subsequently, the residual echo suppression module 2 suppresses the residual signal 106 based on this total residual echo estimate and the state results provided by the dual-talk detection module 3, and finally outputs the target signal 109, i.e., the out signal, in which the echo is fully eliminated.
[0036] In one possible embodiment, the overall workflow of the echo cancellation system is as follows: After system startup, microphone signal 101 and reference signal 102 are synchronously input into the system. Adaptive filter 1 first performs adaptive filtering on microphone signal 101 and reference signal 102 to generate an estimated echo signal 105 for the current frame, which is then subtracted from microphone signal 101 to output a residual signal 106 that has initially eliminated linear echoes. Simultaneously, reference signal 102 is sent in parallel to delay module 4 for delay processing to generate a delayed reference signal 103 carrying historical information. Subsequently, dual-talk detection module 3 processes the original microphone signal... The residual signal 106 obtained after adaptive filtering is analyzed to determine the call status in real time and output the dual-talk status detection result. The residual echo suppression module 2 synchronously receives the estimated echo signal 105, the residual signal 106, and the time-delayed reference signal 103, and calculates a comprehensive total residual echo estimate based on these three signals through a dual-path estimation mechanism. Finally, the residual echo suppression module 2 combines this total residual echo estimate with the dual-talk status detection result, dynamically adjusts the suppression intensity, and performs the final residual echo suppression processing on the residual signal 106, outputting the target signal 109 where the echo is fully eliminated and the near-end speech is protected.
[0037] It should be noted that in the echo cancellation system architecture provided in this embodiment, the dual-talk detection module 3 is an optional processing link for optimizing dual-talk speech performance. The core of this disclosure lies in constructing a low-complexity dual-path residual echo estimation and suppression mechanism through the collaboration of the adaptive filter 1, the delay module 4, and the residual echo suppression module 2. The introduction of the dual-talk detection module 3 can further finely adjust the suppression process according to the call state, thereby obtaining better speech fidelity during dual-talk. However, whether the dual-talk detection module 3 is physically implemented, its specific detection algorithm, or whether it exists as an independent module, does not limit the establishment and implementation of the above-mentioned core mechanism of this disclosure. In other words, a system that only includes the adaptive filter 1, the delay module 4, and the residual echo suppression module 2 to achieve dual-path estimation and suppression, or a system that achieves dual-talk state perception and adjustment in other ways, as long as it is based on the inventive concept of this disclosure, should be considered to fall within the protection scope of this disclosure. Figure 1 The structural diagram shown is an exemplary system composition diagram including optional functions. In practical applications, the dual-talk detection function can be included, omitted, or integrated with other modules in various adaptive designs according to specific performance requirements and resource constraints, without any restrictions here.
[0038] This disclosure provides an echo cancellation system and method, the system comprising: an adaptive filter, a residual echo suppression module, a dual-talk detection module, and a time delay module; the adaptive filter is used to receive a microphone signal and a reference signal under the same processing frame, and to process the processing frame through adaptive filtering to obtain an estimated echo signal and a residual signal; the time delay module is used to apply a time delay of a preset length to the reference signal and output the time-delayed reference signal; the dual-talk detection module is used to perform dual-talk detection on the microphone signal and the residual signal to obtain a dual-talk state detection result; the residual echo suppression module is used to determine the total residual echo estimate based on the estimated echo signal, the residual signal, and the time-delayed reference signal, and to suppress the residual signal through the total residual echo estimate and the dual-talk state detection result, and output the target signal.
[0039] As described above, the echo cancellation system provided by this disclosure introduces a time delay module to delay the reference signal, enabling the residual echo suppression module to perform dual estimation by combining the estimated echo signal of the current frame with the time-delayed reference signal. This effectively expands the system's time coverage of the echo path, thus accurately estimating and suppressing echo tails that are difficult to eliminate with traditional methods, even when using a lower-order adaptive filter. Simultaneously, the dual-talk detection module determines the call status in real time based on the microphone signal and residual signal, and dynamically adjusts the intensity of residual echo suppression. This ensures that echoes are sufficiently suppressed while preventing damage to near-end speech during dual-talk. The echo cancellation system provided by this disclosure achieves echo cancellation performance comparable to higher-order filters while significantly reducing computational complexity and memory consumption, resolving the technical contradiction in existing technologies where echo suppression effectiveness and resource consumption are difficult to balance.
[0040] In one embodiment, such as Figure 2 As shown, this embodiment relates to an echo cancellation method for an echo cancellation system used in any of the above embodiments, and the method includes the following steps: Step 201: Receive the microphone signal and reference signal under the same processing frame, and process the processing frame through adaptive filtering to obtain the estimated echo signal and residual signal.
[0041] Here, the adaptive filter 1 can receive the microphone signal 101 and the reference signal 102 under the same processing frame, and process the processing frame through adaptive filtering to obtain the estimated echo signal 105 and the residual signal 106.
[0042] In one possible embodiment, the adaptive filter 1 receives the microphone signal 101 and the reference signal 102 of the current processing frame, and uses an adaptive filtering algorithm, such as the normalized minimum mean square error algorithm, the frequency domain adaptive filtering algorithm, or the Kalman filtering algorithm, to process the microphone signal 101 and the reference signal 102. This process simulates the echo path and outputs an estimated signal for the linear echo of the current frame, namely the estimated echo signal 105. Subsequently, the adaptive filter 1 subtracts the estimated echo signal 105 from the input microphone signal 101 to obtain a signal with the linear echo initially eliminated, namely the residual signal 106.
[0043] Step 202: Apply a preset time delay to the reference signal and output the delayed reference signal.
[0044] Here, when the adaptive filter 1 receives the microphone signal 101 and the reference signal 102 under the same processing frame, the delay module 4 can apply a preset delay to the reference signal 102 and output the delayed reference signal 103.
[0045] In one possible embodiment, the delay module 4 applies a delay of a preset time length to the input reference signal 102. This delay length can be configured based on the length of the processing frame. After the delay, the delay module 4 outputs a time-lagging reference signal, i.e., the delayed reference signal 103, which carries reference information of the historical frame.
[0046] Step 203: Perform dual-talk detection on the microphone signal and residual signal to obtain the dual-talk status detection result.
[0047] Here, the dual-talk detection module 3 can perform dual-talk detection on the microphone signal 101 and the residual signal 106 to obtain the dual-talk status detection result.
[0048] In one possible embodiment, dual-talk detection is performed on the microphone signal and the residual signal to obtain the dual-talk status detection result, including the following steps: Echo suppression ratio is calculated based on microphone signal and residual signal; The echo suppression ratio is compared with a preset threshold. If the echo suppression ratio is less than the preset threshold, the processing frame is determined to be in dual-talk state, and a dual-talk state detection result indicating the dual-talk state is output.
[0049] Specifically, firstly, the dual-talk detection module 3 calculates the echo suppression ratio based on the microphone signal 101 and the residual signal 106; then, the dual-talk detection module 3 compares the echo suppression ratio with a preset threshold. If the echo suppression ratio is less than the preset threshold, it determines that the processing frame is in dual-talk state and outputs a dual-talk state detection result indicating the dual-talk state.
[0050] In one possible embodiment, before performing residual echo suppression processing, the system first performs dual-talk detection and dynamically adjusts the calculated total residual echo estimate based on the detection result to achieve better voice protection. Specifically, the dual-talk detection module 3 uses the residual signal output by the adaptive filter 1... and the original microphone signal Here's an example of how to calculate the Echo Reduction Ratio (ERLE), a measure of echo cancellation effectiveness:
[0051] in, and microphone signals With residual signal The smoothed power estimates can be calculated and updated in the time or frequency domain using the following recursive smoothing formula, as shown below:
[0052]
[0053] Among them, in the formula It is a smoothing coefficient between 0 and 1.
[0054] Subsequently, the dual-talk detection module 3 compares the calculated ERLE value with a preset threshold T. When ERLE is less than the threshold T, it determines that the current processing frame is in dual-talk state, that is, the near-end speech and the far-end echo exist at the same time, and outputs the corresponding dual-talk state detection result. For example, the dual-talk detection module 3 outputs DTD=1.
[0055] It should be noted that the dual-talk detection method based on echo suppression ratio (ERLE) in this embodiment is only a specific example for realizing dual-talk state discrimination. This disclosure does not impose any restrictions on the technical implementation path of dual-talk detection function. In practical applications, any feasible dual-talk detection algorithm, including but not limited to correlation analysis, signal statistical features, machine learning models, etc., can be selected according to system design requirements and scenario characteristics. Alternatively, the perception logic of dual-talk state can be integrated into other modules. Even if the actual product does not contain an independent dual-talk detection module or does not use the echo suppression ratio calculation and comparison method of this embodiment, as long as the product is based on the core mechanism of dual-path residual echo estimation using time delay reference signal proposed in this disclosure and can realize adaptive processing of dual-talk state in its signal processing flow to optimize voice quality, the product should be considered to fall within the protection scope of this disclosure.
[0056] Step 204: Determine the total residual echo estimate based on the estimated echo signal, residual signal, and time-delayed reference signal, and suppress the residual signal using the total residual echo estimate and dual-talk state detection results to output the target signal.
[0057] Here, the residual echo suppression module 2 can determine the total residual echo estimate based on the estimated echo signal 105, the residual signal 106 and the time-delayed reference signal 103, and suppress the residual signal 106 through the total residual echo estimate and the dual-talk state detection result, and output the target signal 109.
[0058] In one possible embodiment, such as Figure 3 As shown, the total residual echo estimate is determined based on the estimated echo signal, residual signal, and time-delayed reference signal, including the following steps: Step 301: Determine the first coefficient and the second coefficient.
[0059] In one possible embodiment, the process of determining the first coefficient includes the following steps: Calculate and estimate the first cross-correlation value of the echo signal and the residual signal in the frequency domain; Calculate and estimate the autocorrelation value of the echo signal; The ratio of the first cross-correlation value to the autocorrelation value is determined as the first coefficient.
[0060] Specifically, firstly, the residual echo suppression module 2 calculates the first cross-correlation value of the estimated echo signal 105 and the residual signal 106 in the frequency domain; then, the residual echo suppression module 2 calculates the autocorrelation value of the estimated echo signal 105; finally, the residual echo suppression module 2 determines the ratio of the first cross-correlation value to the autocorrelation value as the first coefficient.
[0061] In one possible embodiment, the residual echo suppression module 2 acquires the estimated echo signal 105 and the residual signal 106 output by the adaptive filter 1. Let n be the frame index and k be the frequency index. The residual echo suppression module 2 first calculates the first cross-correlation value of the estimated echo signal Y and the residual signal E in the frequency domain. First cross-correlation value The update can be performed using a recursive smoothing method, as shown in the following formula:
[0062] in, For iterative index, For smoothing coefficients, and These are the estimated power spectra of the echo signal and the residual signal at frequency k, respectively.
[0063] After calculating the first cross-correlation value Then, the residual echo suppression module 2 calculates the autocorrelation value of the estimated echo signal. Autocorrelation value Similarly, a smooth update can be achieved through recursion, as shown in the following formula:
[0064] Finally, the residual echo suppression module 2 calculates the first cross-correlation value at each frequency point. Sum and Autocorrelation Value The ratio of the sums is used as the first coefficient. The specific formula is as follows:
[0065] In one possible embodiment, the process of determining the second coefficient includes the following steps: Calculate the second cross-correlation value of the reference signal and the residual signal in the frequency domain after the time delay; Calculate the first power spectrum of the residual signal and the second power spectrum of the reference signal after time delay; The product of the second cross-correlation value and the conjugate value of the second cross-correlation value is determined as the first calculation result, and the product of the first power spectrum and the second power spectrum is determined as the second calculation result; The second coefficient is determined based on the ratio of the first calculation result to the second calculation result.
[0066] Specifically, firstly, the residual echo suppression module 2 calculates the second cross-correlation value of the reference signal and the residual signal in the frequency domain after the time delay. Then, the residual echo suppression module 2 calculates the first power spectrum of the residual signal and the second power spectrum of the reference signal after the time delay. After that, the residual echo suppression module 2 determines the product of the second cross-correlation value and the conjugate value of the second cross-correlation value as the first calculation result, and determines the product of the first power spectrum and the second power spectrum as the second calculation result. Finally, the residual echo suppression module 2 determines the second coefficient based on the ratio of the first calculation result to the second calculation result.
[0067] In one possible embodiment, the residual echo suppression module 2 acquires the time-delayed reference signal output by the time delay module 4. And the residual signal E(n,k), where n is the frame index and k is the frequency index. To determine the time delay, firstly, the residual echo suppression module 2 calculates the second cross-correlation value in the frequency domain between the time-delayed reference signal 103 and the residual signal 106. (n,k), the second cross-correlation value (n,k) can be updated and estimated through recursive smoothing. Then, the residual echo suppression module 2 calculates the first power spectrum of the residual signal 106. The second power spectrum of the time-delayed reference signal 103 Among them, the second power spectrum of the reference signal after time delay The calculation formula is:
[0068] in, For smoothing coefficients, express . conjugate.
[0069] Next, the residual echo suppression module 2 calculates the first calculation result and the second calculation result, where the first calculation result is the second cross-correlation value. Its conjugate value The product of, i.e. The second calculation result is the first power spectrum. With the second power spectrum The product of, i.e. .
[0070] Finally, the residual echo suppression module 2 determines the second coefficient based on the ratio of the first calculation result to the second calculation result. The specific calculation formula is as follows:
[0071] Step 302: Determine the first residual echo estimate based on the estimated echo signal and the first coefficient.
[0072] Here, after obtaining the first coefficient, the residual echo suppression module 2 can determine the first residual echo estimate based on the estimated echo signal and the first coefficient.
[0073] In one possible embodiment, determining a first residual echo estimate based on the estimated echo signal and a first coefficient includes the following steps: The product of the estimated echo signal amplitude and the first coefficient is determined as the first residual echo estimate.
[0074] Specifically, let the amplitude of the estimated echo signal 105 in the current frame be... The first coefficient is Then the first residual echo estimation The calculation formula is: =
[0075] It should be noted that this calculation process scales the echo signal energy initially estimated by the filter using a coefficient that characterizes its correlation with the residual signal, thereby obtaining the residual echo estimation component derived from the contribution of the currently estimated echo signal.
[0076] Step 303: Determine the second residual echo estimate based on the time-delayed reference signal and the second coefficient.
[0077] Here, after obtaining the second coefficient, the residual echo suppression module 2 can determine the second residual echo estimate based on the time-delayed reference signal and the second coefficient.
[0078] In one possible embodiment, determining the second residual echo estimate based on the time-delayed reference signal and the second coefficient includes the following steps: The product of the amplitude of the time-delayed reference signal and the second coefficient is determined as the second residual echo estimate.
[0079] Specifically, let the amplitude of the reference signal 103 after the time delay be... The second coefficient is Second residual echo estimation The calculation formula is: =
[0080] Step 304: Determine the total residual echo estimate based on the first residual echo estimate and the second residual echo estimate.
[0081] Here, after obtaining the first residual echo estimate and the second residual echo estimate, the residual echo suppression module 2 can determine the total residual echo estimate based on the first residual echo estimate and the second residual echo estimate.
[0082] In one possible embodiment, determining the total residual echo estimate based on the first residual echo estimate and the second residual echo estimate includes the following steps: The first residual echo estimate and the second residual echo estimate are weighted and summed based on preset weights to obtain the total residual echo estimate; or, the larger value between the first residual echo estimate and the second residual echo estimate is determined as the total residual echo estimate.
[0083] In one possible embodiment, the residual echo suppression module 2 is based on a preset first weighting coefficient. Second weighting coefficient The first residual echo estimate R1(n) and the second residual echo estimate R2(n) are weighted and summed to obtain the total residual echo estimate. The specific calculation formula is as follows:
[0084] The first residual echo is estimated as R1(n) = The second residual echo is estimated as R2(n) = Weighting coefficient and The settings and adjustments can be made according to the actual application scenario and performance requirements. For example, both can be set to 0.5 to achieve average fusion, or different weights can be assigned according to the characteristics of the echo path. It should be noted that the specific method of setting the weight coefficient is not limited here.
[0085] In another possible embodiment, to obtain a larger residual echo estimate to ensure sufficient suppression, the larger of the first residual echo estimate R1(n) and the second residual echo estimate R2(n) can be directly determined as the total residual echo estimate R(n), that is: R(n) = max(R1(n), R2(n)) After determining the total residual echo estimate using any of the above methods, this estimate will serve as the basis for subsequent suppression processing, and will be combined with the dual-talk state detection results for final adjustment to output the target signal.
[0086] In this embodiment, firstly, the residual echo suppression module determines a first coefficient and a second coefficient; then, the residual echo suppression module determines a first residual echo estimate based on the estimated echo signal and the first coefficient; subsequently, the residual echo suppression module determines a second residual echo estimate based on the time-delayed reference signal and the second coefficient; finally, the residual echo suppression module determines a total residual echo estimate based on the first residual echo estimate and the second residual echo estimate.
[0087] As described above, the residual echo suppression module in this embodiment constructs a dual-path residual echo estimation mechanism. First, it calculates two independent residual echo estimation components based on the estimated echo signal of the current frame and the historical reference signal after time delay. Then, it fuses these components to generate a total residual echo estimate. This enables the system to not only effectively estimate and suppress linear echoes directly modeled by the adaptive filter, but also to fully utilize historical reference signal information to accurately capture echo tail components missed due to the limited filter order. As a result, the system significantly improves the estimation accuracy and suppression effect of residual echoes in long reverberation environments, providing key technical support for significantly reducing system computational complexity while ensuring excellent echo cancellation performance.
[0088] In one possible embodiment, such as Figure 4 As shown, the residual signal is suppressed by the total residual echo estimation and the dual-talk state detection results, and the target signal is output. The process includes the following steps: Step 401: Based on the dual-talk state detection results, the total residual echo estimate is corrected to obtain the corrected echo estimate.
[0089] Here, after determining the total residual echo estimate based on the estimated echo signal, residual signal and time-delayed reference signal, the residual echo suppression module 2 can correct the total residual echo estimate based on the dual-talk state detection results to obtain the corrected echo estimate.
[0090] In one possible embodiment, the residual echo suppression module 2 determines whether the current processing frame is in a dual-talk state based on the dual-talk state detection result. If it is determined to be in a dual-talk state, for example, DTD=1, the total residual echo estimate is multiplied by a constant correction coefficient c less than 1, thereby reducing the estimated value. This allows for better protection of near-end speech while suppressing residual echoes. The specific correction process can be performed according to the following formula:
[0091] Where c is a preset constant less than 1. If the call is not in a two-way talk state, for example, DTD=0, the total residual echo estimate R(n) remains unchanged. Through this step, the system can dynamically adjust the suppression intensity of residual echo according to the call state.
[0092] Step 402: Suppress the residual signal based on the corrected echo estimation and output the target signal.
[0093] Here, the residual echo suppression module 2 corrects the total residual echo estimate based on the dual-talk state detection results. After obtaining the corrected echo estimate, it can suppress the residual signal based on the corrected echo estimate and output the target signal.
[0094] In one possible embodiment, the residual echo suppression module 2 uses the corrected echo estimate R(n) as an estimate of the residual echo component in the residual signal 106, and based on this estimate, processes the residual signal using a classic suppression algorithm. For example, Wiener filtering, spectral subtraction, or logarithmic spectral amplitude estimation methods can be used. These methods calculate the corresponding suppression gain or spectral gain based on the energy relationship between the residual echo estimate and the residual signal, and apply it to the spectral or time-domain representation of the residual signal to suppress the residual echo component. Finally, the residual echo suppression module 2 performs necessary post-processing on the processed signal, such as inverse transform and smoothing, to obtain the final target signal 109 output.
[0095] In this embodiment, the adaptive filter receives the microphone signal and the reference signal under the same processing frame, and processes the processing frame through adaptive filtering to obtain the estimated echo signal and the residual signal. The delay module applies a preset delay to the reference signal and outputs the delayed reference signal. The dual-talk detection module performs dual-talk detection on the microphone signal and the residual signal to obtain the dual-talk state detection result. The residual echo suppression module determines the total residual echo estimate based on the estimated echo signal, the residual signal and the delayed reference signal, and suppresses the residual signal through the total residual echo estimate and the dual-talk state detection result, and outputs the target signal.
[0096] As described above, this embodiment, through the efficient collaboration of various modules, enables the system to reduce computational complexity by employing low-order adaptive filters, while comprehensively utilizing the current estimated echo and historical reference signals for dual-path residual echo estimation, thereby significantly improving the ability to suppress echo tails in long reverberation environments. Furthermore, this embodiment dynamically adjusts the suppression intensity based on the dual-talk detection results, effectively protecting near-end speech during dual-talk while completely eliminating echoes, ultimately achieving an excellent balance between echo cancellation performance and system efficiency under limited hardware resources.
[0097] In one possible implementation, when the estimated echo signal energy for the current frame is extremely low due to limitations in the order of the adaptive filter, for example when the amplitude... When the residual echo is close to or equal to 0, the first residual echo estimate R1(n) cannot be accurately calculated or loses its reference value. In this case, the residual echo suppression module 2 can directly estimate the residual echo of the current frame by using a recursive attenuation method based on the characteristic that the echo decays with time in the later stage of reverberation. Specifically, the residual echo suppression module 2 can obtain the total residual echo estimate R(n) determined in the previous frame and multiply it by a preset attenuation coefficient that is less than 1. Thus, the total residual echo estimate R(n+1) of the current frame can be directly obtained, which can be expressed by the following formula:
[0098] Among them, attenuation coefficient The value is set according to the reverberation time characteristics of the acoustic environment. The closer the value is to 1, the slower the residual echo decays.
[0099] As can be seen from the above description, this embodiment ensures that the system can still effectively track and suppress the continuously decaying echo tail sound within the blind zone of the adaptive filter, thereby maintaining the continuity of the echo cancellation process.
[0100] As described above, the technical solution disclosed herein provides a systematic solution for achieving high-performance echo cancellation with low computational complexity. By introducing a time delay module and a dual-path estimation mechanism, this technical solution effectively overcomes the problem of insufficient estimation of long reverberant echo tails by low-order adaptive filters, significantly improving the suppression effect of residual echoes. At the same time, by combining dynamic adjustment of dual-talk detection, this technical solution reliably protects the dual-talk voice quality while completely eliminating echoes. Ultimately, it achieves an optimal balance between echo cancellation performance and system resource consumption, providing a practical and feasible technical foundation for achieving high-quality full-duplex calls in resource-constrained terminal devices.
[0101] Figure 5 This is a schematic diagram of the structure of an electronic device provided as an exemplary embodiment of this disclosure. For example... Figure 5As shown, the electronic device 500 includes at least one processor 501 and a memory 502 coupled to the processor 501, which can perform the corresponding steps in the methods disclosed in the embodiments of this disclosure.
[0102] The processor 501 described above can also be called a central processing unit (CPU), which can be an integrated circuit chip with signal processing capabilities. Each step in the method disclosed in this embodiment can be implemented by the integrated logic circuitry in the processor 501 or by software instructions. The processor 501 can be a general-purpose processor, a digital signal processor (DSP), an ASIC, a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in this embodiment can be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software modules can be located in the memory 502, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. The processor 501 reads information from the memory 502 and, in conjunction with its hardware, completes the steps of the method described above.
[0103] Furthermore, various operations / processes according to this disclosure, implemented via software and / or firmware, can be transmitted from a storage medium or network to a computer system with a dedicated hardware architecture, such as... Figure 6 The computer system 600 shown is equipped with the programs that constitute the software. When various programs are installed, the computer system is able to perform various functions, including functions such as those described above. Figure 6 A block diagram of a computer system provided for an exemplary embodiment of this disclosure.
[0104] Computer system 600 is intended to represent various forms of digital electronic computer devices, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. Electronic devices may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.
[0105] like Figure 6 As shown, the computer system 600 includes a computing unit 601, which can perform various appropriate actions and processes based on a computer program stored in a read-only memory (ROM) 602 or a computer program loaded from a storage unit 608 into a random access memory (RAM) 603. The RAM 603 may also store various programs and data required for the operation of the computer system 600. The computing unit 601, ROM 602, and RAM 603 are interconnected via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.
[0106] Multiple components in the computer system 600 are connected to the I / O interface 605, including: an input unit 606, an output unit 607, a storage unit 608, and a communication unit 609. The input unit 606 can be any type of device capable of inputting information into the computer system 600. The input unit 606 can receive input numerical or character information and generate key signal inputs related to user settings and / or function control of the electronic device. The output unit 607 can be any type of device capable of presenting information and may include, but is not limited to, a monitor, speaker, video / audio output terminal, vibrator, and / or printer. The storage unit 608 may include, but is not limited to, a hard disk and an optical disk. The communication unit 609 allows the computer system 600 to exchange information / data with other devices via a network such as the Internet, and may include, but is not limited to, a modem, network card, infrared communication device, wireless communication transceiver, and / or chipset, such as Bluetooth™ device, WiFi device, WiMax device, cellular communication device, and / or the like.
[0107] The computing unit 601 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 601 performs the various methods and processes described above. For example, in some embodiments, the methods disclosed in this disclosure can be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 608. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 500 via ROM 602 and / or communication unit 609. In some embodiments, the computing unit 601 can be configured to perform the methods disclosed in this disclosure by any other suitable means (e.g., by means of firmware).
[0108] This disclosure also provides a computer-readable storage medium, wherein when the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is able to perform the methods disclosed in this disclosure.
[0109] The computer-readable storage medium in this disclosure can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. The aforementioned computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specifically, the aforementioned computer-readable storage medium may include electrical connections based on one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0110] The aforementioned computer-readable medium may be included in the aforementioned electronic device; or it may exist independently and not assembled into the electronic device.
[0111] Figure 7 A computer program product 700 is provided as an exemplary embodiment of the present disclosure. The computer program product 700 includes a computer program 701, wherein the computer program 701, when executed by a processor, implements the methods disclosed in the embodiments of the present disclosure.
[0112] In embodiments of this disclosure, computer program code for performing the operations of this disclosure can be written in one or more programming languages or a combination thereof. These programming languages include, but are not limited to, object-oriented programming languages such as Java, Smalltalk, and C++, as well as conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network (including a local area network (LAN) or a wide area network (WAN)), or it can be connected to an external computer.
[0113] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0114] The modules, components, or units described in the embodiments of this disclosure can be implemented in software or hardware. The names of the modules, components, or units do not necessarily constitute a limitation on the module, component, or unit itself.
[0115] The functions described above in this document can be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary hardware logic components that can be used include: field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), system-on-a-chip (SoCs), complex programmable logic devices (CPLDs), and so on.
[0116] The above description is merely an embodiment of this disclosure and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of this disclosure is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features disclosed in this disclosure that have similar functions.
[0117] While specific embodiments of this disclosure have been described in detail by way of example, those skilled in the art should understand that the examples are for illustrative purposes only and not intended to limit the scope of this disclosure. Those skilled in the art should understand that modifications can be made to the above embodiments without departing from the scope and spirit of this disclosure. The scope of this disclosure is defined by the appended claims.
Claims
1. An echo cancellation system, characterized in that, The system includes: an adaptive filter, a residual echo suppression module, a dual-talk detection module, and a time delay module; The adaptive filter is used to receive the microphone signal and the reference signal under the same processing frame, and to process the processing frame through adaptive filtering to obtain the estimated echo signal and the residual signal. The delay module is used to apply a preset delay to the reference signal and output the delayed reference signal. The dual-talk detection module is used to perform dual-talk detection on the microphone signal and the residual signal to obtain the dual-talk status detection result; The residual echo suppression module is used to determine the total residual echo estimate based on the estimated echo signal, the residual signal, and the time-delayed reference signal, and to suppress the residual signal using the total residual echo estimate and the dual-talk state detection result, and output the target signal.
2. An echo cancellation method, characterized in that, The method, applied to the echo cancellation system of claim 1 above, comprises: The microphone signal and reference signal under the same processing frame are received, and the processing frame is processed by adaptive filtering to obtain the estimated echo signal and residual signal; A preset time delay is applied to the reference signal, and the delayed reference signal is output. Perform dual-talk detection on the microphone signal and the residual signal to obtain the dual-talk status detection result; The total residual echo estimate is determined based on the estimated echo signal, the residual signal, and the time-delayed reference signal. The residual signal is then suppressed using the total residual echo estimate and the dual-talk state detection result to output the target signal.
3. The method according to claim 2, characterized in that, The step of performing dual-talk detection on the microphone signal and the residual signal to obtain the dual-talk status detection result includes: The echo rejection ratio is calculated based on the microphone signal and the residual signal; The echo suppression ratio is compared with a preset threshold. If the echo suppression ratio is less than the preset threshold, the processing frame is determined to be in dual-talk state, and a dual-talk state detection result indicating the dual-talk state is output.
4. The method according to claim 2, characterized in that, The determination of the total residual echo estimate based on the estimated echo signal, the residual signal, and the time-delayed reference signal includes: Determine a first coefficient and a second coefficient; wherein the first coefficient is used to characterize the weight of the residual echo component in the estimated echo signal, and the second coefficient is used to characterize the correlation between the time-delayed reference signal and the residual echo component in the residual signal; The first residual echo estimate is determined based on the estimated echo signal and the first coefficient; The second residual echo estimate is determined based on the time-delayed reference signal and the second coefficient; The total residual echo estimate is determined based on the first residual echo estimate and the second residual echo estimate.
5. The method according to claim 4, characterized in that, The determination of the first coefficient and the second coefficient includes: Calculate the first cross-correlation value between the estimated echo signal and the residual signal in the frequency domain; Calculate the autocorrelation value of the estimated echo signal; The ratio of the first cross-correlation value to the autocorrelation value is determined as the first coefficient.
6. The method according to claim 4, characterized in that, The determination of the first coefficient and the second coefficient includes: Calculate the second cross-correlation value between the delayed reference signal and the residual signal in the frequency domain; Calculate the first power spectrum of the residual signal and the second power spectrum of the time-delayed reference signal; The product of the second cross-correlation value and the conjugate value of the second cross-correlation value is determined as the first calculation result, and the product of the first power spectrum and the second power spectrum is determined as the second calculation result; The second coefficient is determined based on the ratio of the first calculation result to the second calculation result.
7. The method according to claim 4, characterized in that, The step of determining the first residual echo estimate based on the estimated echo signal and the first coefficient includes: The product of the amplitude of the estimated echo signal and the first coefficient is determined as the first residual echo estimate.
8. The method according to claim 4, characterized in that, The step of determining the second residual echo estimate based on the time-delayed reference signal and the second coefficient includes: The product of the amplitude of the time-delayed reference signal and the second coefficient is determined as the second residual echo estimate.
9. The method according to claim 4, characterized in that, Determining the total residual echo estimate based on the first residual echo estimate and the second residual echo estimate includes: The first residual echo estimate and the second residual echo estimate are weighted and summed based on preset weights to obtain the total residual echo estimate; or, the larger value between the first residual echo estimate and the second residual echo estimate is determined as the total residual echo estimate.
10. The method according to claim 2, characterized in that, The process of suppressing the residual signal using the total residual echo estimation and the dual-talk state detection results to output the target signal includes: The total residual echo estimate is corrected based on the dual-talk state detection results to obtain the corrected echo estimate; The residual signal is suppressed based on the corrected echo estimation, and the target signal is output.