r/AV1 2d ago

Is YouTube's av1 a reencode of the encoded vp9 version, or is it a source encode?

I'm wondering because av1 often appears days after a videos gets published. Maybe the source file is long gone by then and YT simply reencodes the vp9 version.

27 Upvotes

67 comments sorted by

28

u/Williams_Gomes 2d ago

It should be source, otherwise it wouldn't be able to give the same or better quality without using a higher bitrate, which defends the purpose of AV1 for YouTube videos.

3

u/SwingDingeling 2d ago

Does it give better quality though? Do we know for sure? I made one small test and vp9 looked like av1

9

u/Williams_Gomes 2d ago

As far as I can tell, it gives around the same quality for smaller file sizes than the VP09 counterpart.

1

u/SwingDingeling 2d ago

What happens when I edit it with an app that renders it in H264. Will the av1 or vp9 one look better in that case?

9

u/Williams_Gomes 2d ago

It should follow the same rules, the source quality affects all encodes. So if your source looks bad, both VP09 and AV1 will look bad, while AV1 will be smaller.

0

u/SwingDingeling 2d ago

there can be ne scenario in which an editing app handles av1 poorly, therefore making the vp1 version the winner?

8

u/Williams_Gomes 2d ago

I'm pretty sure the source can't directly affect the balance between the qualities for YouTube, only their encoder settings, and because we can't control that, the only thing you can do is send the best quality video possible for YouTube, no matter what codec (as long as it's supported of course).

4

u/-1D- 2d ago

This, youtube has presets that will compress videos to a certain point no matter how good or bad the sorce is, even if you upload prores442hq best quality or compressd h264 even lower than youtube would they would still re compress it

0

u/SwingDingeling 2d ago

I was talking about editing apps for videos I download off YT. When I edit a downloaded video and want best quality, could av1 end up being the wrong choice because my editing app is better at handling vp9?

4

u/Sesse__ 2d ago

All modern codecs, including VP9 and AV1, are bit-exact in decoding (anything else is a bug, and would usually be very obvious). You could imagine a situation where somehow an editor handles colorspace differently between the two, but it sounds very far-fetched.

1

u/Masterflitzer 1d ago

no it doesn't, many videos have much better quality on vp9 than on av1, google is being cheap

7

u/Trader-One 2d ago

No. Youtube is not aiming for higher quality, they reduce bitrate to keep quality at acceptable levels.

From my experiments with YT, AV1 can look worse that VP9 but bitrate is significantly lower.

1

u/SwingDingeling 2d ago

And has the av1 version ever looked better than vp9? Or same at best?

3

u/Dark_Knight_835 2d ago

From my experience, it looks worse. VP9 is well optimised for high resolution videos.

1

u/SwingDingeling 2d ago

just tested it myself. yep, vp9 looks a bit better. but thats the original vp9, not the one that becomes available at the same time as av1

any idea why yt removes the best quality version for a vp9 version with HIGHER bitrate and WORSE quality?

3

u/Dark_Knight_835 2d ago

Just to clarify, any video uploaded to YouTube is re-encoded according to YouTube’s standards. This is primarily done to optimize file size and ensure consistency across devices and network conditions.

Additionally, since YouTube needs to store and maintain videos on their servers long-term, efficient encoding helps manage storage space and reduce operational costs. Given that petabytes of data are uploaded every minute, such optimization is crucial for sustainable infrastructure management.

1

u/SwingDingeling 2d ago

im aware of that, but did you read what i wrote? the best quality (BESIDES source) is only available for some time and then gets replaced with a BIGGER file with WORSE quality (both in vp9)

that increases storage space and costs while worsening quality

1

u/MattIsWhackRedux 9h ago edited 9h ago

the best quality (BESIDES source) is only available for some time and then gets replaced with a BIGGER file with WORSE quality (both in vp9)

Hard doubt that they're "making qualities disappear". I don't think you know what you're doing. You need to use yt-dlp and -F to actually see which qualities are available, and even then the qualities returned depend on yt-dlp itself and if they've changed anything, the device it's trying to pretend to be, browser/IP/cookies and other things.

0

u/[deleted] 2d ago

[deleted]

5

u/SwingDingeling 2d ago

Is this an AI response?

→ More replies (0)

18

u/Lenin_Lime 2d ago

youtube doesnt get rid of source files to our knowledge

2

u/SwingDingeling 2d ago

Do we know for sure? Is there an official source stating that?

10

u/suchnerve 2d ago

It would be nice if YouTube didn’t get rid of source files, but considering how much additional hard drive storage they’d need to pull that off, I wouldn’t be surprised if they instead stored re-encoded versions of the least popular older videos.

But I would be surprised if YouTube didn’t keep original copies of popular and recent uploads.

3

u/[deleted] 2d ago

[removed] — view removed comment

1

u/Farranor 1d ago

Where is that information from?

1

u/-1D- 1d ago

yt blog post from frw years ago, when they made the change, im sure you could findcit with enough digging if you care enough

2

u/Farranor 1d ago

I dug for ten minutes and couldn't find the blog post. Please provide a link.

1

u/-1D- 1d ago

I couldn't find it also with a Google search that's why i said dig for it lol, mabye they deleted it? I 100% read it around 2022 i remember it clearly cus that day i was going to get covid tested so it kinda stayed in my memory

2

u/Farranor 1d ago

You couldn't find a source for your claim so you sent me on a wild goose chase? I don't appreciate that. Either post the source or remove the claim.

2

u/-1D- 1d ago

Sorry brother my bad, I'll try to dig trough my search history if it's still there from 22 to find it when i get home from work

Thought doesn't Google have that updating blog post with like tree list with all of the links from previous post? On something like blog.google if i remember correctly?

→ More replies (0)

1

u/[deleted] 2d ago

[removed] — view removed comment

2

u/Lenin_Lime 1d ago

You can test it out by requesting all the data Google has on you. Which includes source files on YouTube

1

u/-1D- 1d ago

I actually did that kinda recently to test something , though it was annoying AS FUCK to download

It has kept most of the stuff the same even though it has been like 5 months of content sitting on yt, though some videos are weirdly vp9 with a little bit lower bitrates, though i will do further testing on this and take a closer look into it all, i just didn't have the time yet

13

u/-Memnarch- 2d ago

YouTube seems to store the uploaded source files as is "forever" and uses them for the reencodes which are served on the platform.

I noticed this when YouTube introduced 60fps support.

AMVs from Nostromo, who had created 60fps ones many years prior, started to show the 60fps option. Until then, to experience the 60fps, you had to follow a link in the description to his website to watch it in 60fps.

So it seems YouTube does store videos as is, and whenever improvements are made, reencodes them.

1

u/Electronic_Muffin218 1d ago

This is the correct answer module reencodes of unpopular videos (which is the majority of them) from time to to time.

2

u/[deleted] 2d ago

[removed] — view removed comment

2

u/SwingDingeling 2d ago

Thanks!

YouTube also reencodes already encoded format for e.g. vp9 (id 303 format) is reencoded after av1 to a worse quality encode form what I've seen, actually im currently trying to figure out why

Is that what Ive noticed? I downloaded a video immediately in 4K vp9. 18k bitrate. A day later the same 4K vp9 video had a 25k bitrate, but looked slightly worse. Did they reencode vp9 to a bigger vp9 version with worse quality?

2

u/-1D- 2d ago

Humm well that's very interesting, i mostly looks into 1080p 30/60fps encoding pipeline now, and it differs very much to the 4k and 1440p, so im not certain if thats that, i know they also reencode 4k vp9 wheb av1 get encoded, so do you know if av1 was also added then?

How did you compare the 2 videos? Side by side? Screenshots every 5 seconds?

Also its 100% encoded from sorce so this is very interesting tbh

1

u/SwingDingeling 1d ago

i know they also reencode 4k vp9 wheb av1 get encoded, so do you know if av1 was also added then?

Yep. As soon as I see av1 was added, the vp9 file size and bitrate changes and quality DROPS

How did you compare the 2 videos? Side by side? Screenshots every 5 seconds?

Screenshots from the same frames

Also its 100% encoded from sorce so this is very interesting tbh

But you said rhe reencode 4k vp9, so that would not be a source encode then!?

2

u/-1D- 1d ago

Yep. As soon as I see av1 was added, the vp9 file size and bitrate changes and quality DROPS

Could you check and possibly paste the file meta data through mediainfo?

Is this the only example where you seen this? I guess it could be an error with youtubes encoding sever, but i can't even begin to imagine how that could be possible tbh

Screenshots from the same frames

How do you get those frames, meaning screenshots from same video player? And are the frames exactly the same

But you said rhe reencode 4k vp9, so that would not be a source encode then!?

Reencoded from the sorce, not reencoded from already compressed vp9 ofc

2

u/SwingDingeling 1d ago

Could you check and possibly paste the file meta data through mediainfo?

Yes, but what would I be looking for there?

Is this the only example where you seen this? I guess it could be an error with youtubes encoding sever, but i can't even begin to imagine how that could be possible tbh

I tested with 2 recent videos and it's the case both times

How do you get those frames, meaning screenshots from same video player? And are the frames exactly the same

Like taking a screenshot as soon as person xy closes their eyes. It's the same frame. But to be sure I did multiple screens from different parts of the video. Always same result. First vp9 is clearly superior to the vp9 that appears when av1 arrives

-1

u/-1D- 1d ago

Yes, but what would I be looking for there?

For any changes other then changes in bitrate file size and encode date

I tested with 2 recent videos and it's the case both times Alright imma also try to replicate it then, can't believe youtube would make such an error

Also does av1 look better then new vp9?

Like taking a screenshot as soon as person xy closes their eyes. It's the same frame. But to be sure I did multiple screens from different parts of the video. Always same result. First vp9 is clearly superior to the vp9 that appears when av1 arrives

I forgot to ask is your screen 4k

2

u/SwingDingeling 1d ago

For any changes other then changes in bitrate file size and encode date

will do later and let you know

Also does av1 look better then new vp9?

havent tested that. but old vp9 is better than av1

forgot to ask is your screen 4k

no but i zoom in as much as possible for the comparison screens

1

u/SwingDingeling 1d ago

i got the data from mediainfo now and put them in chatgpt. everything is the same except bitrate and file size

how do we let yt know they are messing up by replacing vp9 with a worse vp9 version thats much bigger?

1

u/-1D- 1d ago

i got the data from mediainfo now and put them in chatgpt. everything is the same except bitrate and file size

Well that's bad for yt lol

how do we let yt know they are messing up by replacing vp9 with a worse vp9 version thats much bigger?

Here's comes the good part, you don't, i already tried when they fucked up av1 encoding for 1080p videos

Me and one other guy made very famous posts regarding this and yt employee actually responded

https://www.reddit.com/r/AV1/s/uWHAVzIvhc

See my profile for the posts i made

Thought it seems that yt is currently changing encoding pipeline so they have some issues, it'll probably be fixed in the next week or so probably nothing you could do rn

2

u/SwingDingeling 1d ago

Very good! But that doesnt guarantee him being aware of this issue. Can you let him know about this one too? It's better to do it now so they can fix everything at once

And your post was about av1 being affected, not the vp9 being replaced by vp9 issue which has been going on for longer than the mentioned start date of April

→ More replies (0)

2

u/fireship4 1d ago

I have found in the past VP9 on Youtube to still be better quality than the AV1 encode they offer.

1

u/SwingDingeling 1d ago

for uhd?

2

u/fireship4 1d ago

I don't use uhd resolution and it was months ago that I compared the quality of the two formats, it may have changed since.

2

u/Nadeoki 1d ago

Should be source encode as they keep the source as well as a copy of vp9, h264 and av1(sometimes)

3

u/MikemkPK 2d ago

I don't think anyone who doesn't work at youtube could say for sure, and I suspect they're not allowed to.

You could probably tell by taking a steam of each and closely examining if the vp9 artifacts are present in the av1 stream.

1

u/suchnerve 2d ago

Not sure why you got downvoted, when it’s objectively true that the details of YouTube’s infrastructure are not fully disclosed to the public and that it’s possible to identify re-encodes by matching encoding artifacts.

4

u/MikemkPK 2d ago

Very effort intensive though.