Fine tune the IntelligibilityEnhancer

Label less chunks as speech, adapt slower and be more conservative with the maximum gain it can apply.

Review-Url: https://codereview.webrtc.org/2087623003
Cr-Commit-Position: refs/heads/master@{#13242}
This commit is contained in:
aluebs
2016-06-21 11:30:25 -07:00
committed by Commit bot
parent 435264a183
commit 7bd5f253bc
3 changed files with 6 additions and 6 deletions

View File

@ -31,11 +31,11 @@ const float kClipFreqKhz = 0.2f;
const float kKbdAlpha = 1.5f;
const float kLambdaBot = -1.f; // Extreme values in bisection
const float kLambdaTop = -1e-5f; // search for lamda.
const float kVoiceProbabilityThreshold = 0.02f;
const float kVoiceProbabilityThreshold = 0.5f;
// Number of chunks after voice activity which is still considered speech.
const size_t kSpeechOffsetDelay = 80;
const float kDecayRate = 0.994f; // Power estimation decay rate.
const float kMaxRelativeGainChange = 0.006f;
const size_t kSpeechOffsetDelay = 10;
const float kDecayRate = 0.995f; // Power estimation decay rate.
const float kMaxRelativeGainChange = 0.005f;
const float kRho = 0.0004f; // Default production and interpretation SNR.
const float kPowerNormalizationFactor = 1.f / (1 << 30);
const float kMaxActiveSNR = 128.f; // 21dB

View File

@ -409,7 +409,7 @@ TEST_F(IntelligibilityEnhancerTest, TestSolveForGains) {
TEST_F(IntelligibilityEnhancerTest, TestNoiseGainHasExpectedResult) {
const int kGainDB = 6;
const float kGainFactor = std::pow(10.f, kGainDB / 20.f);
const float kTolerance = 0.003f;
const float kTolerance = 0.007f;
std::vector<float> noise(kNumNoiseBins);
std::vector<float> noise_psd(kNumNoiseBins);
std::generate(noise.begin(), noise.end(), float_rand);

View File

@ -23,7 +23,7 @@ namespace intelligibility {
namespace {
const float kMinFactor = 0.01f;
const float kMaxFactor = 1000.f;
const float kMaxFactor = 100.f;
// Return |current| changed towards |target|, with the relative change being at
// most |limit|.