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

Side by Side Diff: webrtc/modules/remote_bitrate_estimator/overuse_detector_unittest.cc

Issue 2201093006: Tune BWE to be more sensitive on low capacity networks. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Tests passing. Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
324 size_t packet_size = 1200; 324 size_t packet_size = 1200;
325 int packets_per_frame = 1; 325 int packets_per_frame = 1;
326 int frame_duration_ms = 333; 326 int frame_duration_ms = 333;
327 int drift_per_frame_ms = 1; 327 int drift_per_frame_ms = 1;
328 int sigma_ms = 3; 328 int sigma_ms = 3;
329 int unique_overuse = Run100000Samples(packets_per_frame, packet_size, 329 int unique_overuse = Run100000Samples(packets_per_frame, packet_size,
330 frame_duration_ms, sigma_ms); 330 frame_duration_ms, sigma_ms);
331 EXPECT_EQ(0, unique_overuse); 331 EXPECT_EQ(0, unique_overuse);
332 int frames_until_overuse = RunUntilOveruse(packets_per_frame, packet_size, 332 int frames_until_overuse = RunUntilOveruse(packets_per_frame, packet_size,
333 frame_duration_ms, sigma_ms, drift_per_frame_ms); 333 frame_duration_ms, sigma_ms, drift_per_frame_ms);
334 EXPECT_EQ(21, frames_until_overuse); 334 EXPECT_EQ(20, frames_until_overuse);
335 } 335 }
336 336
337 TEST_F(OveruseDetectorTest, LowGaussianVarianceFastDrift30Kbit3fps) { 337 TEST_F(OveruseDetectorTest, LowGaussianVarianceFastDrift30Kbit3fps) {
338 size_t packet_size = 1200; 338 size_t packet_size = 1200;
339 int packets_per_frame = 1; 339 int packets_per_frame = 1;
340 int frame_duration_ms = 333; 340 int frame_duration_ms = 333;
341 int drift_per_frame_ms = 100; 341 int drift_per_frame_ms = 100;
342 int sigma_ms = 3; 342 int sigma_ms = 3;
343 int unique_overuse = Run100000Samples(packets_per_frame, packet_size, 343 int unique_overuse = Run100000Samples(packets_per_frame, packet_size,
344 frame_duration_ms, sigma_ms); 344 frame_duration_ms, sigma_ms);
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
386 size_t packet_size = 1200; 386 size_t packet_size = 1200;
387 int packets_per_frame = 2; 387 int packets_per_frame = 2;
388 int frame_duration_ms = 200; 388 int frame_duration_ms = 200;
389 int drift_per_frame_ms = 1; 389 int drift_per_frame_ms = 1;
390 int sigma_ms = 3; 390 int sigma_ms = 3;
391 int unique_overuse = Run100000Samples(packets_per_frame, packet_size, 391 int unique_overuse = Run100000Samples(packets_per_frame, packet_size,
392 frame_duration_ms, sigma_ms); 392 frame_duration_ms, sigma_ms);
393 EXPECT_EQ(0, unique_overuse); 393 EXPECT_EQ(0, unique_overuse);
394 int frames_until_overuse = RunUntilOveruse(packets_per_frame, packet_size, 394 int frames_until_overuse = RunUntilOveruse(packets_per_frame, packet_size,
395 frame_duration_ms, sigma_ms, drift_per_frame_ms); 395 frame_duration_ms, sigma_ms, drift_per_frame_ms);
396 EXPECT_EQ(21, frames_until_overuse); 396 EXPECT_EQ(20, frames_until_overuse);
397 } 397 }
398 398
399 #if defined(WEBRTC_ANDROID) 399 #if defined(WEBRTC_ANDROID)
400 #define MAYBE_HighGaussianVariance100Kbit5fps \ 400 #define MAYBE_HighGaussianVariance100Kbit5fps \
401 DISABLED_HighGaussianVariance100Kbit5fps 401 DISABLED_HighGaussianVariance100Kbit5fps
402 #else 402 #else
403 #define MAYBE_HighGaussianVariance100Kbit5fps HighGaussianVariance100Kbit5fps 403 #define MAYBE_HighGaussianVariance100Kbit5fps HighGaussianVariance100Kbit5fps
404 #endif 404 #endif
405 TEST_F(OveruseDetectorTest, MAYBE_HighGaussianVariance100Kbit5fps) { 405 TEST_F(OveruseDetectorTest, MAYBE_HighGaussianVariance100Kbit5fps) {
406 size_t packet_size = 1200; 406 size_t packet_size = 1200;
(...skipping 19 matching lines...) Expand all
426 size_t packet_size = 1200; 426 size_t packet_size = 1200;
427 int packets_per_frame = 1; 427 int packets_per_frame = 1;
428 int frame_duration_ms = 100; 428 int frame_duration_ms = 100;
429 int drift_per_frame_ms = 1; 429 int drift_per_frame_ms = 1;
430 int sigma_ms = 3; 430 int sigma_ms = 3;
431 int unique_overuse = Run100000Samples(packets_per_frame, packet_size, 431 int unique_overuse = Run100000Samples(packets_per_frame, packet_size,
432 frame_duration_ms, sigma_ms); 432 frame_duration_ms, sigma_ms);
433 EXPECT_EQ(0, unique_overuse); 433 EXPECT_EQ(0, unique_overuse);
434 int frames_until_overuse = RunUntilOveruse(packets_per_frame, packet_size, 434 int frames_until_overuse = RunUntilOveruse(packets_per_frame, packet_size,
435 frame_duration_ms, sigma_ms, drift_per_frame_ms); 435 frame_duration_ms, sigma_ms, drift_per_frame_ms);
436 EXPECT_EQ(21, frames_until_overuse); 436 EXPECT_EQ(20, frames_until_overuse);
437 } 437 }
438 438
439 #if defined(WEBRTC_ANDROID) 439 #if defined(WEBRTC_ANDROID)
440 #define MAYBE_HighGaussianVariance100Kbit10fps \ 440 #define MAYBE_HighGaussianVariance100Kbit10fps \
441 DISABLED_HighGaussianVariance100Kbit10fps 441 DISABLED_HighGaussianVariance100Kbit10fps
442 #else 442 #else
443 #define MAYBE_HighGaussianVariance100Kbit10fps HighGaussianVariance100Kbit10fps 443 #define MAYBE_HighGaussianVariance100Kbit10fps HighGaussianVariance100Kbit10fps
444 #endif 444 #endif
445 TEST_F(OveruseDetectorTest, MAYBE_HighGaussianVariance100Kbit10fps) { 445 TEST_F(OveruseDetectorTest, MAYBE_HighGaussianVariance100Kbit10fps) {
446 size_t packet_size = 1200; 446 size_t packet_size = 1200;
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after
771 if (overuse_state == kBwOverusing) { 771 if (overuse_state == kBwOverusing) {
772 overuse_detected = true; 772 overuse_detected = true;
773 } 773 }
774 ++num_deltas; 774 ++num_deltas;
775 now_ms += 5; 775 now_ms += 5;
776 } 776 }
777 EXPECT_TRUE(overuse_detected); 777 EXPECT_TRUE(overuse_detected);
778 } 778 }
779 } // namespace testing 779 } // namespace testing
780 } // namespace webrtc 780 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/remote_bitrate_estimator/overuse_detector.cc ('k') | webrtc/modules/remote_bitrate_estimator/test/bwe.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698