3 ms·
Netflix surely spends less compute power encoding videos than sites like YouTube though, right? Netflix skews more towards fewer videos, higher view counts, mor
by klodolph 6y ago
Netflix surely spends less compute power encoding videos than sites like YouTube though, right? Netflix skews more towards fewer videos, higher view counts, more money per video.
- clouddrover 6y agoYouTube rolled out AV1 support quite some time ago. Many YouTube videos are AV1 encoded. Here's one example: https://www.youtube.com/watch?v=k3Yk6FrjMkQ https://www.youtube.com/watch?v=k3Yk6FrjMkQ You can tell if it's playing back in AV1 in your browser by right-clicking on the video and selecting "Stats for Nerds" to find out the video and the audio codecs. On my system in Firefox it's AV1 for video and Opus for audio. For that video the file size savings are a bit hit and miss. AV1 saves a lot versus H.264 at 1080p, saves a little bit at 720p and 480p, and saves a bit more at 360p. The 1080p results for that video are: - AV1 50.28MiB - VP9 69.12MiB - H.264 106.68MiB So a clear win at 1080p for AV1 versus VP9 and H.264. Sometimes YouTube's AV1 encodes can actually end up being bigger than the H.264 versions due to the vagaries of automated transcoding. When AV1 support was newly added to Firefox I used this 1080p60 video as a benchmark for my system: https://www.youtube.com/watch?v=Fmdb-KmlzD8 https://www.youtube.com/watch?v=Fmdb-KmlzD8 Over the course of the development of Firefox's AV1 support and the switch to the dav1d decoder (https://code.videolan.org/videolan/dav1d https://code.videolan.org/videolan/dav1d) that video has gone from being unwatchable due to too many dropped frames to now playing back smoothly. My system still struggles with AV1 above 1080p in Firefox though.
- klodolph 6y agoI’m interested in the relative CPU costs of encoding, so this doesn’t really address that. When you say “many” videos are AV1-encoded, it makes me wonder why other videos aren’t AV1-encoded, if supported. Presumably there is some cost/benefit analysis at Google to decide which formats to use, and it is decided that a particular video should not be encoded using AV1 due to the resulting impact on disk/CPU/network usage (more disk, more CPU, less network egress). I also suppose YouTube has a massive pool of low-priority batch services for transcoding and can do last-minute encoding for unpopular videos / unpopular formats, so YouTube’s tradeoff will not be the same as your tradeoff. I just wonder what the tradeoff is.
- clouddrover 6y ago> When you say “many” videos are AV1-encoded, it makes me wonder why other videos aren’t AV1-encoded They will be eventually. The priority goes to the videos with the highest trending view counts because that's where the bandwidth savings are going to be the most significant. This video is five days old and has an AV1 encode: https://www.youtube.com/watch?v=j8oD9jlCFJw https://www.youtube.com/watch?v=j8oD9jlCFJw Whereas this video which has been there for nearly 7 years does not yet have an AV1 encode: https://www.youtube.com/watch?v=Dqf1BdsV5WE https://www.youtube.com/watch?v=Dqf1BdsV5WE With only 7,777 views it doesn't matter that much if it has an AV1 encode (or even a VP9 encode really). The bandwidth savings won't be that significant for the number of views it gets.
- amadvance 6y agoAlso consider that all video have a H264 encoding to play on low end devices. Any additional encoding, in VP9 or AV1, is an additional cost as the H264 encoding cannot be avoided. Even VP9 is not used for all video. Only if the video is 4K or 2K7, or has a high number of view.
- clouddrover 6y ago> Even VP9 is not used for all video. Only if the video is 4K or 2K7, or has a high number of view. No, the low view count video example I provided above has VP9 encodes for all resolutions, 144p through to 1080p. Lots of low view count videos are encoded in VP9. But when VP9 was new it followed the same approach AV1 is following now: high trending view count videos get the priority.
- prvc 6y agoThose comparisons are meaningless without also factoring in some measure of quality such as VMAF. The advantages of AV1 become clear in that case.
- clouddrover 6y agoOr you can just look at them with your eyes. The end goal of video is for it to be looked at, after all. The quality of these different encodes is about the same. With different codecs at about the same quality it becomes a case of picking your errors and artefacts. A given codec will be weak in some areas and strong in others.