This CL moves the residual echo detector to reside outside of
the band-scheme in APM. The benefit of this is that the
residual echo detector will then no longer enforce the
band-splitting to be used when it is the only active component
inside APM.
This CL also introduces diagnostic dumping of data inside the
residual echo detector.
BUG=webrtc:6220, webrtc:6183
Review-Url: https://codereview.webrtc.org/2884593002
Cr-Commit-Position: refs/heads/master@{#18150}
The residual echo likelihood should report a likelihood between 0.0 and 1.0. Currently it can happen that echo likelihoods > 1.0 are reported. As a temporary mitigation to stop this, this CL enforces a hard maximum of 1.0 for the echo likelihood while we investigate the issue further.
BUG=b/38014838
Review-Url: https://codereview.webrtc.org/2861123002
Cr-Commit-Position: refs/heads/master@{#18030}
Reason for revert:
The original patch set was correct, but the Chromium bug number needed to be corrected.
Original issue's description:
> Revert of Added ARM Neon SIMD optimizations for AEC3 (patchset #2 id:970001 of https://codereview.webrtc.org/2834073005/ )
>
> Reason for revert:
> The bug number for the chromium bug was wrong.
>
> Original issue's description:
> > Added ARM Neon optimizations for AEC3
> >
> > This CL adds Neon SIMD optimizations for AEC3 on ARM, resulting
> > in an 8 times complexity reduction. The optimizations are basically
> > identical to what was already in place for SSE2.
> >
> > BUG=chromium:14993, webrtc:6018
> >
> > Review-Url: https://codereview.webrtc.org/2834073005
> > Cr-Commit-Position: refs/heads/master@{#17993}
> > Committed: f246b91eba
>
> TBR=ivoc@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=chromium:14993, webrtc:6018
>
> Review-Url: https://codereview.webrtc.org/2856113003
> Cr-Commit-Position: refs/heads/master@{#17994}
> Committed: b70f8cfd4dTBR=ivoc@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=chromium:714993, webrtc:6018
Review-Url: https://codereview.webrtc.org/2862573002
Cr-Commit-Position: refs/heads/master@{#17997}
Reason for revert:
The bug number for the chromium bug was wrong.
Original issue's description:
> Added ARM Neon optimizations for AEC3
>
> This CL adds Neon SIMD optimizations for AEC3 on ARM, resulting
> in an 8 times complexity reduction. The optimizations are basically
> identical to what was already in place for SSE2.
>
> BUG=chromium:14993, webrtc:6018
>
> Review-Url: https://codereview.webrtc.org/2834073005
> Cr-Commit-Position: refs/heads/master@{#17993}
> Committed: f246b91ebaTBR=ivoc@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=chromium:14993, webrtc:6018
Review-Url: https://codereview.webrtc.org/2856113003
Cr-Commit-Position: refs/heads/master@{#17994}
This CL adds Neon SIMD optimizations for AEC3 on ARM, resulting
in an 8 times complexity reduction. The optimizations are basically
identical to what was already in place for SSE2.
BUG=chromium:14993, webrtc:6018
Review-Url: https://codereview.webrtc.org/2834073005
Cr-Commit-Position: refs/heads/master@{#17993}
This CL corrects the behavior in AEC3 during buffer overruns
and underruns in three ways.
1) When there is no render signal available (due to a buffering
issues, a zero block is inserted instead of the previous render
block. This avoids the same block being repeatedly inserted when
there are many back-to-back calls.
2) The internal counters in the main adaptive filter gain are also
reset when the filter is reset.
3) The internal counters in the shadow adaptive filter gain are
reset when the filter is reset.
BUG=chromium:717920,webrtc:7559
Review-Url: https://codereview.webrtc.org/2862533002
Cr-Commit-Position: refs/heads/master@{#17991}
In this CL, the neteq_unittest_tools target is split in two separate
targets. One still called neteq_tools which does not set
testonly=true and that includes code related to audio input,
replacement audio and fake decoding. The other target called
neteq_test_tools contains the remaining files, and is
still under testonly=true.
Other renames:
neteq_test_tools -> neteq_test_tools_deprecated
neteq_test_minimal -> neteq_tools_minimal
Cyclic dependencies were also cleaned up.
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_chromium_compile_rel_ng,linux_chromium_compile_dbg_ng
BUG=webrtc:7467,webrtc:6828
Review-Url: https://codereview.webrtc.org/2845013003
Cr-Commit-Position: refs/heads/master@{#17921}
This target keeps track of .h the files under webrtc/modules/include/
that are not part of any target.
If a .h file is not part of a target the 'gn check' utility is not
able to spot if a target is missing a dependency because even if
it parses '#include' directives it is not able to find a target that
contains these headers.
BUG=webrtc:7513
NOTRY=True
Review-Url: https://codereview.webrtc.org/2838873002
Cr-Commit-Position: refs/heads/master@{#17880}
Specifically, they handle all combinations of two integer and two
floating-point arguments by picking a result type that is guaranteed
to be able to hold the result. This means callers no longer have to
deal with potentially dangerous casting to make all the arguments have
the same type, like they have to with std::min() and std::max().
Also, they're constexpr.
Mostly for illustrative purposes, this CL replaces a few std::min()
and std::max() calls with SafeMin() and SafeMax().
BUG=webrtc:7459
Review-Url: https://codereview.webrtc.org/2810483002
Cr-Commit-Position: refs/heads/master@{#17869}
Make all rtc_source_test target that contains tests that
are included in a test executable only be visible to the
rtc_test target. Doing this exposed a couple of errors and
dependency problems that were resolved. Having this could
have prevented duplicated execution of tests like the case that
was recently fixed by deadbeef@ in
https://codereview.webrtc.org/2820263004
New targets:
* //webrtc/modules/rtp_rtcp:fec_test_helper
* //webrtc/modules/rtp_rtcp:mock_rtp_rtcp
* //webrtc/modules/remote_bitrate_estimator:mock_remote_bitrate_observer
The mock files and targets should probably be moved into webrtc/test in
the future, but that's out of the scope of this CL.
BUG=webrtc:5716
NOTRY=True
Review-Url: https://codereview.webrtc.org/2828793003
Cr-Commit-Position: refs/heads/master@{#17863}
This CL improves the echo cancellation performance on setups where
headsets are used (systems with such low echo path gain
that no correlation between the render and capture signals
can be found) in 4 ways:
1) The echo path gain for systems with headsets is assumed to be
nonzero.
2) The stationary component of the render power is not included
in nonlinear echo power estimate.
3) The behavior after echo path gain changes is made less cautious.
4) The detection of systems with headsets is made more rapid.
BUG=chromium:712651, webrtc:6018
Review-Url: https://codereview.webrtc.org/2823903003
Cr-Commit-Position: refs/heads/master@{#17768}
- BUILD file reorganized, unit tests now have dedicated targets.
- "fake_polqa" is a binary producing fake output in the same format of PolqaOem64; the binary is injected for unit tests instead of the actual POLQA tool.
- Minor refactoring to inject the path to the POLQA binary instead of its parent folder.
- Unit tests for the evaluation score workers.
- Unit tests for the ApmModuleSimulator class.
- Unit tests for the test data generators: ReverberationTestDataGenerator added.
BUG=webrtc:7218
Review-Url: https://codereview.webrtc.org/2811953002
Cr-Commit-Position: refs/heads/master@{#17674}
This CL adds tuning to AEC3 for the purpose of reducing the impact of
gain changes in the analog microphone gain.
BUG=chromium:710818, webrtc:6018
Review-Url: https://codereview.webrtc.org/2811283003
Cr-Commit-Position: refs/heads/master@{#17673}
This CL adds further SSE2 optimizations for the AEC3
adaptive filter.
The changes are bitexact
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2810133002
Cr-Commit-Position: refs/heads/master@{#17667}
Most of the complex functionality in AEC3 is done using
vector maths. This CL adds a new functionality for
performing these using SIMD operations in a simple manner
whenever such are available.
The reason for putting the implementations in the header file
is to allow any possible inlining.
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2813823002
Cr-Commit-Position: refs/heads/master@{#17663}
The SSE2 optimizations of the filter core in the matched
filter was only half-done. This CL finalizes those.
In particular:
-It adds finalization of updating of the filter.
-It removes the manual loop unrolling in order to reduce and
simplify the code.
Note that the changes pass the bitexactness tests in an
external AEC3 test suite, and the test
MatchedFilter.TestOptimizations succeed.
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2813563003
Cr-Commit-Position: refs/heads/master@{#17655}
This CL changes the name of classes, methods and variables making using "noise generator".
This naming is replaced with "input-reference generator" which is more descriptive of the actual role.
Comments, CSS class and HTML item names have also been changed.
Consistency for variable names has been verified and the style checked with pylint.
BUG=webrtc:7218
Review-Url: https://codereview.webrtc.org/2805653002
Cr-Commit-Position: refs/heads/master@{#17639}
Changes in the microphone gain are effecting the AEC in the sense
that each change in the microphone gain is a change in the echo
path seen by the AEC. This CL utilizes the ability of AEC3 to
leverage information about known changes in the analog microphone
gain.
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2808073002
Cr-Commit-Position: refs/heads/master@{#17625}
During the first few capture frames, there is no way for the AEC
to tell whether there is echo in the capture signal as the echo
removal functionality in the AEC has not yet seen any render
signal. To avoid initial echo bursts due to this, this CL adds
functionality for forcing the echo suppression gain to zero during
the first 50 blocks (200 ms) after call start and after a reported
echo path change.
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2808733002
Cr-Commit-Position: refs/heads/master@{#17624}
The unit test ConversationalSpeechTest.MultiEndCallWavReaderAdaptorSine uses CreateSineWavFile() and writes temporary wav files that are used for test (deleted only if the test passes).
BUG=webrtc:7218
Review-Url: https://codereview.webrtc.org/2774423005
Cr-Commit-Position: refs/heads/master@{#17608}
This CL includes extensive tests to match accept or reject decisions on several different timing setups. The setups are simulated using mocks (by far more light-weight than using actual timing and audio track files).
The client code, the unit tests in this case, passes information about the fake audio tracks to MockWavReaderFactory. MockWavReader instances are then created using the parameters defined in the client code. To improve the readability of the tests, generator_unittest.cc includes a docstring explaining how each MultiEndCallSetup* test is documented.
Run tests as follows:
$ out/Default/modules_unittests --gtest_filter=ConversationalSpeechTest.*
BUG=webrtc:7218
Review-Url: https://codereview.webrtc.org/2781573002
Cr-Commit-Position: refs/heads/master@{#17592}
This CL adds support for handling highly reverberant echoes in
AEC3. The functionality is hardcoded to be have no effect (via
a decay factor of 0), but this CL will be followed by other CLs
for which nonzero decay factors will be allowed.
Apart from this change, this CL also refactors the residual
echo estimation code to make it shorter and more readable.
The changes introduced herein are bitexact (for a decay factor
of 0).
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2804223002
Cr-Commit-Position: refs/heads/master@{#17589}
This CL ensures that the number of bands
for the render side matches that for the capture side
when AEC3 is active. Without this, there was problems
when the render rate is different from the capture rate.
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2800033003
Cr-Commit-Position: refs/heads/master@{#17586}
Reason for revert:
Trying to re-land after solving some related issues.
There are no changes compared to the original CL.
Original issue's description:
> Revert of Loosening the coupling between WebRTC and //third_party/protobuf (patchset #16 id:300001 of https://codereview.webrtc.org/2747863003/ )
>
> Reason for revert:
> I will try to reland next week because it is causing some problems.
>
> Original issue's description:
> > To accommodate some downstream WebRTC users we need to loosen
> > the coupling between our code and the //third_party/protobuf.
> >
> > This includes using typedefs to define strings instead of
> > assuming std::string.
> >
> > After this refactoring it will be possible to link with other
> > protobuf implementations than the current one.
> >
> > We moved the PRESUBMIT check to another CL [1]. The goal of this
> > presubmit is to avoid the direct usage of google::protobuf outside
> > of the webrtc/base/protobuf_utils.h header file.
> >
> > [1] - https://codereview.webrtc.org/2753823003/
> >
> > BUG=webrtc:7340
> > NOTRY=True
> >
> > Review-Url: https://codereview.webrtc.org/2747863003
> > Cr-Commit-Position: refs/heads/master@{#17466}
> > Committed: 16ab93b952
>
> TBR=kjellander@webrtc.org,henrik.lundin@webrtc.org,kwiberg@webrtc.org,michaelt@webrtc.org,peah@webrtc.org
> # Not skipping CQ checks because original CL landed more than 1 days ago.
> BUG=webrtc:7340
>
> Review-Url: https://codereview.webrtc.org/2786363002
> Cr-Commit-Position: refs/heads/master@{#17483}
> Committed: d00aad5eb2TBR=kjellander@webrtc.org,henrik.lundin@webrtc.org,kwiberg@webrtc.org,michaelt@webrtc.org,peah@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:7340
NOTRY=True
Review-Url: https://codereview.webrtc.org/2791963003
Cr-Commit-Position: refs/heads/master@{#17584}
This CL corrects the behavior during buffer underruns.
Furthermore, it increases the tolerance for API call jitter, and
removes the minimum value for the comfort noise.
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2787123003
Cr-Commit-Position: refs/heads/master@{#17576}
This CL adds fairly significant changes to the echo removal
functionality, the main ones being.
-More centralized control over the echo removal.
-Updated echo suppression gain behavior.
-Significantly increased usage of the linear adaptive filter.
-New echo removal functionality when the linear filter is not usable.
This CL is chained to the CL https://codereview.webrtc.org/2784023002/
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2782423003
Cr-Commit-Position: refs/heads/master@{#17575}
This CL adds major render pipeline changes to the AEC3 code. The reason
for these are that
1) It allows the echo removal unit to receive information about the content
in bands beyond band 0, thereby allowing removal of high-frequency
echoes
2) It allows more controlled handling of the render buffers, allowing proper
buffer behaviour during capture glitches and clock-drift.
Unfortunately, the render pipeline caused a lot of related changes in much
of the rest of the AEC3 files. Most of these are, however, caused by
a change of class name.
Another unfortunate effect of this CL, is that a number of unittest cease to
compile. I chose to temporarily solve that by removing them from the
build using #if/#endif. The reason for that is that those will anyway again
need to be changed in the next review, and doing like this avoids them
having to be reviewed twice.
BUG=webrtc:6018
Review-Url: https://codereview.webrtc.org/2784023002
Cr-Commit-Position: refs/heads/master@{#17547}
- snake_case -> CapWords
- compulsory docstring added
- style
A followup CL will fix remaining issues as raised by the next version of the WebRTC Python linter (update in progress).
BUG=webrtc:7218
NOTRY=True
Review-Url: https://codereview.webrtc.org/2793903006
Cr-Commit-Position: refs/heads/master@{#17543}
Reason for revert:
Issue with rebasing from depending CL
Original issue's description:
> Export library that generates an HTLM file with the scores organized in tables.
>
> BUG=webrtc:7218
> NOTRY=True
>
> Review-Url: https://codereview.webrtc.org/2717973006
> Cr-Commit-Position: refs/heads/master@{#17512}
> Committed: 29e3330139TBR=aleloi@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:7218
Review-Url: https://codereview.webrtc.org/2791293002
Cr-Commit-Position: refs/heads/master@{#17513}