Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[youtube] wrong best #25925

Closed
lilydjwg opened this issue Jul 7, 2020 · 3 comments
Closed

[youtube] wrong best #25925

lilydjwg opened this issue Jul 7, 2020 · 3 comments

Comments

@lilydjwg
Copy link

@lilydjwg lilydjwg commented Jul 7, 2020

Checklist

  • I'm reporting a broken site support
  • I've verified that I'm running youtube-dl version 2020.06.16.1
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar issues including closed ones

Verbose log

>>> youtube-dl -v -F 'https://www.youtube.com/watch?v=iygjJ8M7jnM'
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', '-F', 'https://www.youtube.com/watch?v=iygjJ8M7jnM']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2020.06.16.1
[debug] Python version 3.8.3 (CPython) - Linux-5.4.42-1-lily-x86_64-with-glibc2.2.5
[debug] exe versions: ffmpeg 4.2.3, ffprobe 4.2.3, rtmpdump 2.4
[debug] Proxy map: {}
[youtube] iygjJ8M7jnM: Downloading webpage
[info] Available formats for iygjJ8M7jnM:
format code  extension  resolution note
249          webm       audio only tiny   57k , opus @ 50k (48000Hz), 2.09MiB
250          webm       audio only tiny   74k , opus @ 70k (48000Hz), 2.84MiB
140          m4a        audio only tiny  146k , m4a_dash container, mp4a.40.2@128k (44100Hz), 5.24MiB
251          webm       audio only tiny  148k , opus @160k (48000Hz), 5.69MiB
160          mp4        256x144    144p  105k , avc1.4d400c, 30fps, video only, 1.45MiB
278          webm       256x144    144p  105k , webm container, vp9, 30fps, video only, 2.07MiB
242          webm       426x240    240p  240k , vp9, 30fps, video only, 3.27MiB
133          mp4        426x240    240p  251k , avc1.4d4015, 30fps, video only, 2.28MiB
243          webm       640x360    360p  424k , vp9, 30fps, video only, 5.43MiB
134          mp4        640x360    360p  486k , avc1.4d401e, 30fps, video only, 3.90MiB
135          mp4        854x480    480p  695k , avc1.4d401f, 30fps, video only, 5.69MiB
244          webm       854x480    480p  765k , vp9, 30fps, video only, 9.19MiB
136          mp4        1280x720   720p 1263k , avc1.4d401f, 30fps, video only, 9.47MiB
247          webm       1280x720   720p 1488k , vp9, 30fps, video only, 16.01MiB
248          webm       1920x1080  1080p 2654k , vp9, 30fps, video only, 31.31MiB
137          mp4        1920x1080  1080p 4254k , avc1.640028, 30fps, video only, 28.06MiB
22           mp4        1280x720   720p  362k , avc1.64001F, 30fps, mp4a.40.2@192k (44100Hz)
18           mp4        640x360    360p  373k , avc1.42001E, 30fps, mp4a.40.2@ 96k (44100Hz), 15.11MiB (best)

Description

I've noticed that youtube-dl chooses wrong formats as best recently for YouTube, e.g. in the above log 360p video is marked as best but it should be a 1080p. (Other times it chooses a 720p.)

@lilydjwg
Copy link
Author

@lilydjwg lilydjwg commented Jul 7, 2020

Excuse me, duplicate of which?

@lilydjwg
Copy link
Author

@lilydjwg lilydjwg commented Jul 7, 2020

Did you mean #4659? That one is five years old, and I notice this behavior only recently. youtube-dl happily downloaded better seperate video+audio files rathan than combined one before. Was that considered a bug and recently got fixed?

Edit: I noticed that I was using best[...]+bestaudio which may not be a valid format specifier so the behaviour has changed. I adjust my parameters so I get what I want. But still 360p is not the best audible video in the list, there is a 720p just above it.

@lilydjwg
Copy link
Author

@lilydjwg lilydjwg commented Jul 9, 2020

After digging into the source code (instead of reading previous issues or developer response), I finally see that this is a duplicate of #14143, i.e. youtube-dl chooses higher bitrates even when the codecs differ, so older codecs win over newer, more efficient ones.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.