Plot acknowledged bitrate when compiled with rtc_enable_bwe_test_logging.

Change plotting of detector state from offset and gamma to T and threshold.

BUG=None

Review-Url: https://codereview.webrtc.org/2933243003
Cr-Commit-Position: refs/heads/master@{#18585}
This commit is contained in:
terelius 2017-06-14 02:41:59 -07:00 committed by Commit Bot
parent 58c5a7d4ac
commit 6c4ba9f77d
3 changed files with 8 additions and 5 deletions

View File

@ -12,6 +12,7 @@
#include <cmath>
#include "webrtc/modules/remote_bitrate_estimator/test/bwe_test_logging.h"
#include "webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h"
namespace webrtc {
@ -73,6 +74,8 @@ void AcknowledgedBitrateEstimator::Update(int64_t now_ms, int bytes) {
(sample_var + pred_bitrate_estimate_var);
bitrate_estimate_var_ = sample_var * pred_bitrate_estimate_var /
(sample_var + pred_bitrate_estimate_var);
BWE_TEST_LOGGING_PLOT(1, "acknowledged_bitrate", now_ms,
bitrate_estimate_ * 1000);
}
float AcknowledgedBitrateEstimator::UpdateWindow(int64_t now_ms,

View File

@ -90,8 +90,8 @@ BandwidthUsage OveruseDetector::Detect(double offset,
return BandwidthUsage::kBwNormal;
}
const double T = std::min(num_of_deltas, kMinNumDeltas) * offset;
BWE_TEST_LOGGING_PLOT(1, "offset_ms#1", now_ms, offset);
BWE_TEST_LOGGING_PLOT(1, "gamma_ms#1", now_ms, threshold_ / kMinNumDeltas);
BWE_TEST_LOGGING_PLOT(1, "T", now_ms, T);
BWE_TEST_LOGGING_PLOT(1, "threshold", now_ms, threshold_);
if (T > threshold_) {
if (time_over_using_ == -1) {
// Initialize the timer. Assume that we've been

View File

@ -137,8 +137,7 @@ def main():
kalman_state.AddSubplot(['var_noise'], "Time (s)", "Var noise")
detector_state = Figure("DetectorState")
detector_state.AddSubplot(['offset_ms'], "Time (s)", "Offset")
detector_state.AddSubplot(['gamma_ms'], "Time (s)", "Gamma")
detector_state.AddSubplot(['T', 'threshold'], "Time (s)", "Offset")
trendline_state = Figure("TrendlineState")
trendline_state.AddSubplot(["accumulated_delay_ms", "smoothed_delay_ms"],
@ -146,7 +145,8 @@ def main():
trendline_state.AddSubplot(["trendline_slope"], "Time (s)", "Slope")
target_bitrate = Figure("TargetBitrate")
target_bitrate.AddSubplot(['target_bitrate_bps'], "Time (s)", "Bitrate (bps)")
target_bitrate.AddSubplot(['target_bitrate_bps', 'acknowledged_bitrate'],
"Time (s)", "Bitrate (bps)")
# Select which figures to plot here.
figures = [receiver, detector_state, trendline_state, target_bitrate]