Ch. 11 · Measuring Video Quality in Practice

한국어日本語
8 min

The Average Trap: Low Percentiles and Minimum VMAF

An average VMAF of 95 does not mean even the worst frame scores 95. Use this site's measurements to see the gap between the average and the tail.

The headline number libvmaf reports is the average of the per-frame VMAF scores. But what bothers viewers may be a single moment where the picture breaks down, not the average. As long as most frames are good, the average stays high even if a few frames fall apart.

Three summary numbers

If there are 250 per-frame scores (10 seconds at 25 fps), the average is the mean of those 250 scores, the 5th percentile is the value at the 5% mark when you sort them from lowest (about the 12th frame), and the minimum is the score of the single lowest frame. Average − 5th percentile and average − minimum show how far the tail sits below the average.

The gap between average and tail, from our measurements

In Is an Average VMAF of 95 Good Enough? we encoded four 1080p25 10-second clips at eight levels each with x264, x265, and SVT-AV1, and measured the average, 5th percentile, and minimum together (FFmpeg 9.0.2, default model vmaf_v0.6.1). The values below are taken from the table in that article. For each encoder and clip, we picked the measurement point whose average is closest to 90.

ClipEncoder (CRF)Average5th pctMinAvg − Min
riverbedx264 (26)95.23893.47878.52116.717
riverbedSVT-AV1 (42)89.76283.40774.09315.669
rush_hourx265 (24)91.63589.71989.3602.275
rush_hourx264 (26)88.42386.32585.9062.517

Source: selected rows from the table in the measurement article vmaf-worst-frames-v1. SVT-AV1 used preset 6. You can see all 12 combinations in that article.

  • Even with an average above 95, the minimum was 78.521 (riverbed, x264 CRF 26). By the average alone it passes, but the worst frame is nearly 17 points lower.
  • The clip had a large effect on the width of the tail. In the table above, rush_hour's x264 and x265 had a narrow average − minimum of 2.275 to 2.517, while riverbed's x264 and SVT-AV1 were wide at 15.669 to 16.717 (riverbed x265 was 6.312 in the same article). Across all 12 combinations, average − minimum ranged from 2.275 to 16.717.
  • Average − minimum was always larger than average − 5th percentile. That's because the single worst frame falls even below the 5th percentile.

How much does the cost change when you change the target?

The same article estimated, by interpolation, the CRF that satisfies "average 95 or higher" and "minimum 90 or higher" (these are estimates, not measurements). In 9 of the 12 combinations, holding the minimum at 90 required a lower CRF, and for pedestrian_area x265 the difference was 0.1, so effectively the same. The other 8 needed a CRF lower by 1.7 to 9.4, and the file size was about 1.27 to 2.29 times larger. The widest gap was riverbed x264, going from CRF 26.1 to 19.1 at about 2.29 times the size.

There are counterexamples, and there are limits

rush_hour was the opposite. With x264 and x265, once the average hit 95, the minimum was already above 90. Also, the minimum VMAF depends on a single frame, so it can be affected by special frames such as scene changes or the first frame, and that article did not check which frame the minimum came from. With only four 10-second clips, these numbers are not recommended values for any genre.

In the field: don't sign off on the average alone

When you report measurement results, make it a habit to write the 5th percentile (or 1st) and the minimum alongside the average. As lesson 5 shows, libvmaf can output per-frame scores as JSON, so you can compute these from the same run at no extra cost. Decide up front, based on your service's requirements, which value is the pass/fail line: the average, the 5th percentile, or the minimum.

How much the file size grows in the range where the average VMAF barely rises is measured, using the VMAF of the bottom 5% of frames, in the high-quality CRF measurement. On four 10-second clips, going below the highest CRF at which even the bottom 5% of frames reach VMAF 99 or more raised the average VMAF by only 0.01–0.04 points while the file size grew 1.6 to 28 times.

Percentile (p5)Percentile (p5)

The value at a given fraction when scores are sorted from lowest. p5 is the value at the 5% mark.

Worst frameWorst frame

The single frame with the lowest per-frame score. It reveals momentary breakdowns hidden behind the average.

Per-frame scorePer-frame score

A score assigned to each frame rather than to the whole video. The raw material for averages and percentiles.

Check yourself

In this site's measurements, riverbed x264 CRF 26 had an average VMAF of 95.238 but a minimum of 78.521. What does this case show?