tune=ssimulacra2 efficiency tweaks - Adjusted QP -> QM level formula. Small efficiency gains in SSIMULACRA 2 scores (~0.2%) for several QP regions (e.g. QP 25, QP 40-50). - Further increased chroma delta q boost for 4:2:0 chroma subsampling mode. Similar average SSIMULACRA 2 scores, slightly better 10th percentile scores. Daala subset1 was used to benchmark improvements. Bug: aomedia:401234702 Change-Id: I93b481abc1068e66fe4cdbebe05f7cad1c4c5fa7
diff --git a/av1/common/quant_common.h b/av1/common/quant_common.h index 965a746..6dc82c0 100644 --- a/av1/common/quant_common.h +++ b/av1/common/quant_common.h
@@ -116,17 +116,17 @@ qm_level = 10; } else if (qindex <= 60) { qm_level = 9; - } else if (qindex <= 100) { + } else if (qindex <= 90) { qm_level = 8; } else if (qindex <= 120) { qm_level = 7; - } else if (qindex <= 140) { + } else if (qindex <= 130) { qm_level = 6; - } else if (qindex <= 160) { + } else if (qindex <= 140) { qm_level = 5; - } else if (qindex <= 200) { + } else if (qindex <= 160) { qm_level = 4; - } else if (qindex <= 220) { + } else if (qindex <= 200) { qm_level = 3; } else { qm_level = 2;
diff --git a/av1/encoder/av1_quantize.c b/av1/encoder/av1_quantize.c index 1673d53..c0a1227 100644 --- a/av1/encoder/av1_quantize.c +++ b/av1/encoder/av1_quantize.c
@@ -902,7 +902,13 @@ // The ramp-down of chroma increase was determined by generating the // convex hull of SSIMULACRA 2 scores (for all boosts from 0-16), and // finding a linear equation that fits the convex hull. - chroma_dc_delta_q = -clamp((quant_params->base_qindex / 2) - 14, 0, 16); + // For the SSIMULACRA 2 tune only: a convex hull of SSIMULACRA 2 scores + // (mean, 10th percentile) was generated by decreasing chroma delta_q + // by 3 different values (16, 20 and 24). 20 was selected as it had the + // best 10th percentile performance. + int offset = (tuning == AOM_TUNE_SSIMULACRA2) ? 20 : 16; + chroma_dc_delta_q = + -clamp((quant_params->base_qindex / 2) - 14, 0, offset); chroma_ac_delta_q = chroma_dc_delta_q; } else if (cm->seq_params->subsampling_x == 1 && cm->seq_params->subsampling_y == 0) {