]> granicus.if.org Git - libvpx/commitdiff
Enable VP10 HBD PSNR checking unit test
authorYi Luo <luoyi@google.com>
Mon, 2 May 2016 18:29:58 +0000 (11:29 -0700)
committerYi Luo <luoyi@google.com>
Mon, 2 May 2016 18:29:58 +0000 (11:29 -0700)
We enable this unit test to protect the high bit depth picture
quality from degrading under VP10 optimization and new experimental
tools.

Change-Id: I6297a44cf01954773e06549ab2a68c319fc848a8

test/vp9_end_to_end_test.cc

index c6333a2f4a3d1ce50d5ea6f19d68cdb4adcec368..98e9e3058ee579b10cd25acbefba347ac55b9608 100644 (file)
@@ -25,6 +25,20 @@ const unsigned int kFrames = 10;
 const int kBitrate = 500;
 // List of psnr thresholds for speed settings 0-7 and 5 encoding modes
 const double kPsnrThreshold[][5] = {
+// Note:
+// VP10 HBD average PSNR is slightly lower than VP9.
+// We make two cases here to enable the testing and
+// guard picture quality.
+#if CONFIG_VP10_ENCODER && CONFIG_VP9_HIGHBITDEPTH
+  { 36.0, 37.0, 37.0, 37.0, 37.0 },
+  { 31.0, 36.0, 36.0, 36.0, 36.0 },
+  { 32.0, 35.0, 35.0, 35.0, 35.0 },
+  { 32.0, 34.0, 34.0, 34.0, 34.0 },
+  { 32.0, 33.0, 33.0, 33.0, 33.0 },
+  { 31.0, 32.0, 32.0, 32.0, 32.0 },
+  { 30.0, 31.0, 31.0, 31.0, 31.0 },
+  { 29.0, 30.0, 30.0, 30.0, 30.0 },
+#else
   { 36.0, 37.0, 37.0, 37.0, 37.0 },
   { 35.0, 36.0, 36.0, 36.0, 36.0 },
   { 34.0, 35.0, 35.0, 35.0, 35.0 },
@@ -33,6 +47,7 @@ const double kPsnrThreshold[][5] = {
   { 31.0, 32.0, 32.0, 32.0, 32.0 },
   { 30.0, 31.0, 31.0, 31.0, 31.0 },
   { 29.0, 30.0, 30.0, 30.0, 30.0 },
+#endif  // CONFIG_VP9_HIGHBITDEPTH && CONFIG_VP10_ENCODER
 };
 
 typedef struct {
@@ -194,21 +209,14 @@ VP9_INSTANTIATE_TEST_CASE(
 
 #if CONFIG_VP9_HIGHBITDEPTH
 # if CONFIG_VP10_ENCODER
-// TODO(angiebird): many fail in high bitdepth mode.
 INSTANTIATE_TEST_CASE_P(
-    DISABLED_VP10, EndToEndTestLarge,
+    VP10, EndToEndTestLarge,
     ::testing::Combine(
         ::testing::Values(static_cast<const libvpx_test::CodecFactory *>(
             &libvpx_test::kVP10)),
         ::testing::ValuesIn(kEncodingModeVectors),
         ::testing::ValuesIn(kTestVectors),
         ::testing::ValuesIn(kCpuUsedVectors)));
-# endif  // CONFIG_VP10_ENCODER
-#else
-VP10_INSTANTIATE_TEST_CASE(
-    EndToEndTestLarge,
-    ::testing::ValuesIn(kEncodingModeVectors),
-    ::testing::ValuesIn(kTestVectors),
-    ::testing::ValuesIn(kCpuUsedVectors));
+#endif  // CONFIG_VP10_ENCODER
 #endif  // CONFIG_VP9_HIGHBITDEPTH
 }  // namespace