question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Inconsistent quality behavior?

See original GitHub issue

Make sure you are using the latest version: run youtube-dl --version and ensure your version is 2016.07.11. If it’s not read this FAQ entry and update. Issues with outdated version will be rejected.

  • I’ve verified and I assure that I’m running youtube-dl 2016.07.11

Before submitting an issue make sure you have:

  • At least skimmed through README and most notably FAQ and BUGS sections
  • Searched the bugtracker for similar issues including closed ones

What is the purpose of your issue?

  • Bug report (encountered problems with youtube-dl)
  • Site support request (request for adding support for a new site)
  • Feature request (request for a new functionality)
  • Question
  • Other

Hello, I have a little question about what seems to be inconsistent behavior regarding format/quality selection. Or perhaps my expectations about said options are inaccurate? I hope someone can help clarify if that is the case.

I’ll explain/show my actions and results below.

Video used as example: https://www.youtube.com/watch?v=f25R9Gl6FWc

Download without any parameters(for reference): http://imgur.com/GS4fSku

Media info: http://imgur.com/kT0uW9R

Now for the interesting part, download with parameters taken from the “Format selection examples” section. (https://github.com/rg3/youtube-dl#format-selection-examples)

Download best mp4 format available or any other best if no mp4 available

$ youtube-dl -f ‘bestvideo[ext=mp4]+bestaudio[ext=m4a]/best[ext=mp4]/best’

http://imgur.com/VOrVs9N

Media info: http://imgur.com/LnjUqHl

Now for the final result using -f best http://imgur.com/LVQP4QI

Media info: http://imgur.com/BDuaDNx

Note the significantly larger file size and higher bit rates for both audio and video.

Why does “# Download best mp4 format available or any other best if no mp4 available” not actually return the best quality mp4 available but -f best does? Am I misunderstanding things? Am I doing something wrong? Are my expectations off?

Please explain if you can, thanks in advance.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7

github_iconTop GitHub Comments

2reactions
yan12125commented, Jul 12, 2016

It’s a limitation of youtube-dl: sometimes the actual quality is unknown until the file is downloaded. In this example, bestvideo is:

136          mp4        1280x720   720p  278k , avc1.4d401f, 30fps, video only, 48.46MiB

And best is:

22           mp4        1280x720   hd720 , avc1.64001F,  mp4a.40.2@192k (best)

As both formats have the same dimension, the only factor is their bitrates. Unfortunately, YouTube does not provide the bitrate information for format 22 of this video. In most cases, bestvideo is better than best, so we make it the default. This video is a good counterexample, but we can do nothing without sufficient information. If you know how to determine video qualities without actual downloading, please propose it. There are already lots of related feature requests. For example, a not-so-good idea was proposed at #6055. (It downloads some portion of the video, which slows down the extraction step.)

0reactions
yan12125commented, Aug 17, 2016

bigger is usually better

Not always true. Comparing bitrates among different codecs is meaningless. See https://github.com/rg3/youtube-dl/issues/6018#issuecomment-114008839 and https://en.wikipedia.org/wiki/Video_quality. You need some mathematical metrics, such as SSIM, PSNR, etc.

Read more comments on GitHub >

github_iconTop Results From Across the Web

The Pitfalls of Inconsistent Leader Behavior - IO at Work
The study found that when high self-esteem and high quality of work life employees were exposed to inconsistent leader behavior, they used ...
Read more >
Behavioral Inconsistencies Do Not Imply Inconsistent Strategies
Inconsistencies in observed behavior have been interpreted as conflicting with assumed stable preferences or traits. According to our analysis, ...
Read more >
Your Inconsistency Is More Noticeable Than You Think - Forbes
1. Failed to achieve goals in the allotted time. 2. Resists setting high standards of excellence. 3. Withholds or forgets important information.
Read more >
5 Types of Inconsistent Parenting and How To Prevent It
Inconsistent parenting is the use of different discipline practices across time or between parents ​1​. It can happen when rules and expectations ...
Read more >
Behavioral Inconsistencies Do Not Imply Inconsistent Strategies
Inconsistencies in observed behavior have been interpreted as conflicting with assumed stable preferences or traits. According to our analysis, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found