Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(309)

Issue 2537043003: fix wrong implementation of AimdRateControl::TimeToReduceFurther. (Closed)

Created:
4 years ago by zhengpeng
Modified:
3 years, 11 months ago
Reviewers:
terelius, stefan-webrtc
Target Ref:
refs/pending/heads/master
Project:
webrtc
Visibility:
Public.

Description

fix wrong implementation of AimdRateControl::TimeToReduceFurther. The comment of this method says that it returns true if "the incoming_bitrate is more than 5% above the current estimate". BUG=

Patch Set 1 #

Total comments: 2

Patch Set 2 : fix wrong implementation of AimdRateControl::TimeToReduceFurther #

Unified diffs Side-by-side diffs Delta from patch set Stats (+36 lines, -6 lines) Patch
M webrtc/modules/remote_bitrate_estimator/aimd_rate_control.h View 1 1 chunk +1 line, -1 line 0 comments Download
M webrtc/modules/remote_bitrate_estimator/aimd_rate_control.cc View 1 2 chunks +3 lines, -5 lines 0 comments Download
M webrtc/modules/remote_bitrate_estimator/aimd_rate_control_unittest.cc View 1 1 chunk +32 lines, -0 lines 0 comments Download

Messages

Total messages: 21 (8 generated)
zhengpeng
fix an obvious wrong implementation of AimdRateControl::TimeToReduceFurther
4 years ago (2016-11-29 15:34:37 UTC) #2
stefan-webrtc
Thanks for this! https://codereview.webrtc.org/2537043003/diff/1/webrtc/modules/remote_bitrate_estimator/aimd_rate_control.cc File webrtc/modules/remote_bitrate_estimator/aimd_rate_control.cc (right): https://codereview.webrtc.org/2537043003/diff/1/webrtc/modules/remote_bitrate_estimator/aimd_rate_control.cc#newcode77 webrtc/modules/remote_bitrate_estimator/aimd_rate_control.cc:77: return incoming_bitrate_bps > threshold; Agree that ...
4 years ago (2016-11-29 15:52:08 UTC) #5
zhengpeng
add review comments. https://codereview.webrtc.org/2537043003/diff/1/webrtc/modules/remote_bitrate_estimator/aimd_rate_control.cc File webrtc/modules/remote_bitrate_estimator/aimd_rate_control.cc (right): https://codereview.webrtc.org/2537043003/diff/1/webrtc/modules/remote_bitrate_estimator/aimd_rate_control.cc#newcode77 webrtc/modules/remote_bitrate_estimator/aimd_rate_control.cc:77: return incoming_bitrate_bps > threshold; On 2016/11/29 ...
4 years ago (2016-11-30 04:33:11 UTC) #6
zhengpeng
Hi, Stefan. Here is the updated patch-set. Bitrate reduction becomes less aggressive as expected, which ...
4 years ago (2016-11-30 12:20:25 UTC) #7
stefan-webrtc
On 2016/11/30 12:20:25, zhengpeng wrote: > Hi, Stefan. > > Here is the updated patch-set. ...
4 years ago (2016-11-30 13:00:33 UTC) #10
zhengpeng
On 2016/11/30 13:00:33, stefan-webrtc (holmer) wrote: > On 2016/11/30 12:20:25, zhengpeng wrote: > > Hi, ...
4 years ago (2016-11-30 14:45:22 UTC) #11
zhengpeng
Code comment added. https://codereview.webrtc.org/2537043003/diff/40001/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.cc File webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.cc (right): https://codereview.webrtc.org/2537043003/diff/40001/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.cc#newcode509 webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.cc:509: bitrate_bps = bitrate_observer_->latest_bitrate(); when number_of_streams = ...
4 years ago (2016-11-30 14:49:56 UTC) #12
stefan-webrtc
terelius, could you review this also. Especially help figure out why the tests with the ...
4 years ago (2016-11-30 14:58:50 UTC) #14
terelius
On 2016/11/30 12:20:25, zhengpeng wrote: > Hi, Stefan. > > Here is the updated patch-set. ...
4 years ago (2016-11-30 16:38:50 UTC) #15
terelius
On 2016/11/30 14:58:50, stefan-webrtc (holmer) wrote: > terelius, could you review this also. Especially help ...
4 years ago (2016-11-30 19:38:03 UTC) #16
zhengpeng
On 2016/11/30 16:38:50, terelius wrote: > On 2016/11/30 12:20:25, zhengpeng wrote: > > Hi, Stefan. ...
4 years ago (2016-12-01 03:44:07 UTC) #17
terelius
On 2016/12/01 03:44:07, zhengpeng wrote: > On 2016/11/30 16:38:50, terelius wrote: > > On 2016/11/30 ...
4 years ago (2016-12-01 09:31:03 UTC) #18
zhengpeng
4 years ago (2016-12-01 12:44:31 UTC) #21
On 2016/12/01 09:31:03, terelius wrote:
> On 2016/12/01 03:44:07, zhengpeng wrote:
> > On 2016/11/30 16:38:50, terelius wrote:
> > > On 2016/11/30 12:20:25, zhengpeng wrote:
> > > > Hi, Stefan.
> > > > 
> > > > Here is the updated patch-set. 
> > > > Bitrate reduction becomes less aggressive as expected, which lead to 14
> > failed
> > > > unit tests. All of them are related to sudden drop of network capacity,
> such
> > > as:
> > > > 
> > > >
> > >
> >
>
../../webrtc/modules/congestion_controller/delay_based_bwe_unittest_helper.cc:432:
> > > > Failure
> > > > The difference between expected_bitrate_drop_delta and bitrate_drop_time
-
> > > > overuse_start_time is 66, which exceeds 33, where
> > > > expected_bitrate_drop_delta evaluates to 567,
> > > > bitrate_drop_time - overuse_start_time evaluates to 633, and
> > > > 33 evaluates to 33.
> > > > [  FAILED  ] DelayBasedBweTest.CapacityDropOneStream (11 ms)
> > > 
> > > As far as I can tell, reductions should be more aggressive now, not less.
> > > The old code would reduce if
> > > estimate - incoming_bitrate > 1.05 * incoming_bitrate
> > > or equivalently, if
> > > incoming_bitrate < 0.4878 * estimate
> > > The new code will reduce if
> > > incoming_bitrate < 0.95 * estimate
> > 
> > Please correct me if wrong: 
> > when overusing, do early reduction only when the incoming bitrate is
> > sufficiently low,
> > which is defined by kWithinIncomingBitrateHysteresis, otherwise do 'regular'
> > reductions every rtt.
> > 
> > How is kWithinIncomingBitrateHysteresis determined? By experience?
> > If so, only the comment needs to be updated.
> 
> I think your code looks good, and I don't think
kWithinIncomingBitrateHysteresis
> was used as intended. However, the problem with making earlier reductions
> is that the measured bitrate lags behind the capacity drop, so if you back
> off earlier then you won't back off as much. This impacts the choices of
> several other parameters, and the current tuning seems to depend on the
> old, "incorrect", behavior of the aimd rate controller.
> 
> If you want to land your CL quickly, then the easiest fix might be to set
> the threshold to 0.5 * LatestEstimate() rather than 0.95 * LatestEstimate().
> That way there is (almost) no functional change and you don't have to update
> any unit tests. Stefan, do you have input?

I accidentally started a new issue:
https://codereview.webrtc.org/2549453002/

Powered by Google App Engine
This is Rietveld 408576698