From 999cf2bd7c66ec1944ad48d00fb6a54c1985774e Mon Sep 17 00:00:00 2001 From: peah Date: Tue, 28 Feb 2017 22:07:05 -0800 Subject: [PATCH] Added further tuning of AEC3 TBR=henrik.lundin@webrtc.org BUG=webrtc:6018 Review-Url: https://codereview.webrtc.org/2720973005 Cr-Commit-Position: refs/heads/master@{#16928} --- webrtc/modules/audio_processing/aec3/power_echo_model.cc | 2 +- .../modules/audio_processing/aec3/residual_echo_estimator.cc | 2 +- webrtc/modules/audio_processing/aec3/suppression_filter.cc | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/webrtc/modules/audio_processing/aec3/power_echo_model.cc b/webrtc/modules/audio_processing/aec3/power_echo_model.cc index 9bdc971b9d..8ad5486e07 100644 --- a/webrtc/modules/audio_processing/aec3/power_echo_model.cc +++ b/webrtc/modules/audio_processing/aec3/power_echo_model.cc @@ -28,7 +28,7 @@ void RecentMaximum(const FftBuffer& X_buffer, } } -constexpr float kHInitial = 100.f; +constexpr float kHInitial = 10.f; constexpr int kUpdateCounterInitial = 300; } // namespace diff --git a/webrtc/modules/audio_processing/aec3/residual_echo_estimator.cc b/webrtc/modules/audio_processing/aec3/residual_echo_estimator.cc index 18a07b2f5a..45d3a5f79b 100644 --- a/webrtc/modules/audio_processing/aec3/residual_echo_estimator.cc +++ b/webrtc/modules/audio_processing/aec3/residual_echo_estimator.cc @@ -29,7 +29,7 @@ void InfiniteErlPowerEstimate( size_t blocks_since_last_saturation, const std::array& S2_fallback, std::array* R2) { - if (active_render_blocks > 5 * 250) { + if (active_render_blocks > 20 * 250) { // After an amount of active render samples for which an echo should have // been detected in the capture signal if the ERL was not infinite, set the // residual echo to 0. diff --git a/webrtc/modules/audio_processing/aec3/suppression_filter.cc b/webrtc/modules/audio_processing/aec3/suppression_filter.cc index 3b830a612e..7f7a8d7d22 100644 --- a/webrtc/modules/audio_processing/aec3/suppression_filter.cc +++ b/webrtc/modules/audio_processing/aec3/suppression_filter.cc @@ -139,8 +139,8 @@ void SuppressionFilter::ApplyGain( // Scale and apply the noise to the signals. RTC_DCHECK_LT(3, suppression_gain.size()); - float high_bands_gain = - *std::min_element(suppression_gain.begin() + 3, suppression_gain.end()); + float high_bands_gain = *std::min_element(suppression_gain.begin() + 32, + suppression_gain.end()); float high_bands_noise_scaling = 0.4f * std::max(1.f - high_bands_gain, 0.f);