{"action":"created","issue":{"url":"https://api.github.com/repos/rg3/youtube-dl/issues/8749","repository_url":"https://api.github.com/repos/rg3/youtube-dl","labels_url":"https://api.github.com/repos/rg3/youtube-dl/issues/8749/labels{/name}","comments_url":"https://api.github.com/repos/rg3/youtube-dl/issues/8749/comments","events_url":"https://api.github.com/repos/rg3/youtube-dl/issues/8749/events","html_url":"https://github.com/rg3/youtube-dl/issues/8749","id":138374710,"number":8749,"title":"Default settings do not download best quality video from YouTube","user":{"login":"FrostedMint","id":10250449,"avatar_url":"https://avatars.githubusercontent.com/u/10250449?v=3","gravatar_id":"","url":"https://api.github.com/users/FrostedMint","html_url":"https://github.com/FrostedMint","followers_url":"https://api.github.com/users/FrostedMint/followers","following_url":"https://api.github.com/users/FrostedMint/following{/other_user}","gists_url":"https://api.github.com/users/FrostedMint/gists{/gist_id}","starred_url":"https://api.github.com/users/FrostedMint/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FrostedMint/subscriptions","organizations_url":"https://api.github.com/users/FrostedMint/orgs","repos_url":"https://api.github.com/users/FrostedMint/repos","events_url":"https://api.github.com/users/FrostedMint/events{/privacy}","received_events_url":"https://api.github.com/users/FrostedMint/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-03-04T04:26:50Z","updated_at":"2016-03-04T05:06:26Z","closed_at":"2016-03-04T05:06:26Z","body":"It appears that the default quality settings are not always grabbing the best possible video from YouTube.\r\n\r\nHere is a selection of formats reported using `-F` for this [music video](https://www.youtube.com/watch?v=keeYY_5XR4w):\r\n```\r\n251          webm       audio only DASH audio  165k , opus @160k, 4.74MiB\r\n136          mp4        1280x720   720p 2218k , avc1.4d401f, 30fps, video only, 63.58MiB\r\n247          webm       1280x720   720p 2382k , vp9, 30fps, video only, 46.77MiB\r\n22           mp4        1280x720   hd720 , avc1.64001F,  mp4a.40.2@192k (best)\r\n```\r\n\r\nAnd here is what actually gets downloaded and muxed:\r\n\r\nFormat | Container | Size | Video | Audio\r\n--- | --- | --- | --- | ---\r\n**247+251** | WebM | 52 MB | VP9 @ 1454 Kbps | Opus @ 154 Kbps\r\n**136+251** | Matroska | 69 MB | AVC1 @ ~2060 Kbps | Opus @ 154 Kbps\r\n**22** | MP4 | 88 MB | AVC1 @ 2663 Kbps | AAC @ 192 Kbps\r\n\r\nI would expect **22** to be the best possible format, and **136+251** to be the best possible DASH format. Instead, I get **247+251**.\r\n\r\nI'm using [MediaInfo](https://mediaarea.net/en/MediaInfo) on OS X to determine the bitrates.\r\n\r\nHere's the full output of `youtube-dl`:\r\n\r\n```\r\n$ uname -v\r\nDarwin Kernel Version 15.3.0: Thu Dec 10 18:40:58 PST 2015; root:xnu-3248.30.4~1/RELEASE_X86_64\r\n\r\n$ youtube-dl -U\r\nyoutube-dl is up-to-date (2016.03.01)\r\n\r\n$ export VIDEO=https://www.youtube.com/watch?v=keeYY_5XR4w\r\n\r\n$ youtube-dl --ignore-config -vF $VIDEO\r\n[debug] System config: []\r\n[debug] User config: []\r\n[debug] Command-line args: [u'--ignore-config', u'-vF', u'https://www.youtube.com/watch?v=keeYY_5XR4w']\r\n[debug] Encodings: locale UTF-8, fs utf-8, out None, pref UTF-8\r\n[debug] youtube-dl version 2016.03.01\r\n[debug] Python version 2.7.10 - Darwin-15.3.0-x86_64-i386-64bit\r\n[debug] exe versions: ffmpeg 3.0, ffprobe 3.0, rtmpdump 2.4\r\n[debug] Proxy map: {}\r\n[youtube] keeYY_5XR4w: Downloading webpage\r\n[youtube] keeYY_5XR4w: Downloading video info webpage\r\n[youtube] keeYY_5XR4w: Extracting video information\r\n[youtube] {22} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {43} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {18} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {5} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {36} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {17} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {136} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {247} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {135} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {244} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {134} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {243} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {133} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {242} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {160} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {278} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {140} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {171} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {249} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {250} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {251} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[info] Available formats for keeYY_5XR4w:\r\nformat code  extension  resolution note\r\n249          webm       audio only DASH audio   50k , opus @ 50k, 1.47MiB\r\n250          webm       audio only DASH audio   67k , opus @ 70k, 1.91MiB\r\n140          m4a        audio only DASH audio  128k , m4a_dash container, mp4a.40.2@128k, 3.91MiB\r\n171          webm       audio only DASH audio  137k , vorbis@128k, 3.93MiB\r\n251          webm       audio only DASH audio  165k , opus @160k, 4.74MiB\r\n278          webm       256x144    144p   96k , webm container, vp9, 15fps, video only, 2.55MiB\r\n160          mp4        256x144    144p  117k , avc1.42c00c, 15fps, video only, 3.43MiB\r\n242          webm       426x240    240p  257k , vp9, 30fps, video only, 5.97MiB\r\n133          mp4        426x240    240p  262k , avc1.4d4015, 30fps, video only, 7.53MiB\r\n243          webm       640x360    360p  496k , vp9, 30fps, video only, 11.06MiB\r\n134          mp4        640x360    360p  607k , avc1.4d401e, 30fps, video only, 16.49MiB\r\n244          webm       854x480    480p  988k , vp9, 30fps, video only, 20.34MiB\r\n135          mp4        854x480    480p 1110k , avc1.4d401f, 30fps, video only, 31.62MiB\r\n136          mp4        1280x720   720p 2218k , avc1.4d401f, 30fps, video only, 63.58MiB\r\n247          webm       1280x720   720p 2382k , vp9, 30fps, video only, 46.77MiB\r\n36           3gp        320x?      small , mp4v.20.3,  mp4a.40.2\r\n17           3gp        176x144    small , mp4v.20.3,  mp4a.40.2@ 24k\r\n5            flv        400x240    small , h263, mp3  @ 64k\r\n43           webm       640x360    medium , vp8.0,  vorbis@128k\r\n18           mp4        640x360    medium , avc1.42001E,  mp4a.40.2@ 96k\r\n22           mp4        1280x720   hd720 , avc1.64001F,  mp4a.40.2@192k (best)\r\n\r\n$ youtube-dl --ignore-config -v $VIDEO\r\n[debug] System config: []\r\n[debug] User config: []\r\n[debug] Command-line args: [u'--ignore-config', u'-v', u'https://www.youtube.com/watch?v=keeYY_5XR4w']\r\n[debug] Encodings: locale UTF-8, fs utf-8, out None, pref UTF-8\r\n[debug] youtube-dl version 2016.03.01\r\n[debug] Python version 2.7.10 - Darwin-15.3.0-x86_64-i386-64bit\r\n[debug] exe versions: ffmpeg 3.0, ffprobe 3.0, rtmpdump 2.4\r\n[debug] Proxy map: {}\r\n[youtube] keeYY_5XR4w: Downloading webpage\r\n[youtube] keeYY_5XR4w: Downloading video info webpage\r\n[youtube] keeYY_5XR4w: Extracting video information\r\n[youtube] {22} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {43} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {18} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {5} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {36} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {17} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {136} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {247} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {135} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {244} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {134} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {243} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {133} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {242} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {160} signature length 38.44, html5 player en_US-vfl_cdzrt\r\n[youtube] keeYY_5XR4w: Downloading player https://s.ytimg.com/yts/jsbin/player-en_US-vfl_cdzrt/base.js\r\n[youtube] {278} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {140} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {171} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {249} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {250} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[youtube] {251} signature length 40.44, html5 player en_US-vfl_cdzrt\r\n[debug] Invoking downloader on u'https://r19---sn-nx57yn7s.googlevideo.com/videoplayback?sver=3&lmt=1425168130099374&ipbits=0&itag=247&key=yt6&mime=video%2Fwebm&expire=1457085346&mn=sn-nx57yn7s&mm=31&upn=3_RNUWvTAfI&ms=au&mv=m&mt=1457063667&ip=216.243.6.134&fexp=9415516%2C9416126%2C9418183%2C9420052%2C9420452%2C9422596%2C9423038%2C9423661%2C9423662%2C9424416%2C9425398%2C9428063%2C9428247%2C9428329%2C9428559%2C9428965%2C9429693%2C9430989&sparams=clen%2Cdur%2Cgcr%2Cgir%2Cid%2Cinitcwndbps%2Cip%2Cipbits%2Citag%2Ckeepalive%2Clmt%2Cmime%2Cmm%2Cmn%2Cms%2Cmv%2Cnh%2Cpl%2Crequiressl%2Csource%2Cupn%2Cexpire&keepalive=yes&id=o-AJt0o0a7Uh5-603hE-nngo2BRkWoCFTIKdbMEXlMF_1u&clen=49037308&requiressl=yes&gir=yes&nh=IgpwcjAxLnNlYTAzKgkxMjcuMC4wLjE&pl=22&initcwndbps=4033750&dur=257.824&gcr=us&source=youtube&signature=1BF6FA409837EE061CB4BA964E10E6D30FD50543.B67F7DF27BE51D76480494962EA40EA1E9CAC2F2&ratebypass=yes'\r\n[download] Destination: 【ポリリズム】Perfume×capsule【Sound of Silence】-keeYY_5XR4w.f247.webm\r\n[download] 100% of 46.77MiB in 00:02\r\n[debug] Invoking downloader on u'https://r19---sn-nx57yn7s.googlevideo.com/videoplayback?sver=3&lmt=1425167994422249&ipbits=0&itag=251&key=yt6&mime=audio%2Fwebm&expire=1457085346&mn=sn-nx57yn7s&mm=31&upn=3_RNUWvTAfI&ms=au&mv=m&mt=1457063667&ip=216.243.6.134&fexp=9415516%2C9416126%2C9418183%2C9420052%2C9420452%2C9422596%2C9423038%2C9423661%2C9423662%2C9424416%2C9425398%2C9428063%2C9428247%2C9428329%2C9428559%2C9428965%2C9429693%2C9430989&sparams=clen%2Cdur%2Cgcr%2Cgir%2Cid%2Cinitcwndbps%2Cip%2Cipbits%2Citag%2Ckeepalive%2Clmt%2Cmime%2Cmm%2Cmn%2Cms%2Cmv%2Cnh%2Cpl%2Crequiressl%2Csource%2Cupn%2Cexpire&keepalive=yes&id=o-AJt0o0a7Uh5-603hE-nngo2BRkWoCFTIKdbMEXlMF_1u&clen=4970110&requiressl=yes&gir=yes&nh=IgpwcjAxLnNlYTAzKgkxMjcuMC4wLjE&pl=22&initcwndbps=4033750&dur=257.861&gcr=us&source=youtube&signature=B596A2E8254CEDE00DCC35EFC9F1F1CFB102D0CA.8FE4FA58EAC2FCE4FAE5865E5B376C4642AEC648&ratebypass=yes'\r\n[download] Destination: 【ポリリズム】Perfume×capsule【Sound of Silence】-keeYY_5XR4w.f251.webm\r\n[download] 100% of 4.74MiB in 00:00\r\n[ffmpeg] Merging formats into \"【ポリリズム】Perfume×capsule【Sound of Silence】-keeYY_5XR4w.webm\"\r\n[debug] ffmpeg command line: ffmpeg -y -i 'file:【ポリリズム】Perfume×capsule【Sound of Silence】-keeYY_5XR4w.f247.webm' -i 'file:【ポリリズム】Perfume×capsule【Sound of Silence】-keeYY_5XR4w.f251.webm' -c copy -map 0:v:0 -map 1:a:0 'file:【ポリリズム】Perfume×capsule【Sound of Silence】-keeYY_5XR4w.temp.webm'\r\nDeleting original file 【ポリリズム】Perfume×capsule【Sound of Silence】-keeYY_5XR4w.f247.webm (pass -k to keep)\r\nDeleting original file 【ポリリズム】Perfume×capsule【Sound of Silence】-keeYY_5XR4w.f251.webm (pass -k to keep)\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/rg3/youtube-dl/issues/comments/192107175","html_url":"https://github.com/rg3/youtube-dl/issues/8749#issuecomment-192107175","issue_url":"https://api.github.com/repos/rg3/youtube-dl/issues/8749","id":192107175,"user":{"login":"dstftw","id":1908898,"avatar_url":"https://avatars.githubusercontent.com/u/1908898?v=3","gravatar_id":"","url":"https://api.github.com/users/dstftw","html_url":"https://github.com/dstftw","followers_url":"https://api.github.com/users/dstftw/followers","following_url":"https://api.github.com/users/dstftw/following{/other_user}","gists_url":"https://api.github.com/users/dstftw/gists{/gist_id}","starred_url":"https://api.github.com/users/dstftw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dstftw/subscriptions","organizations_url":"https://api.github.com/users/dstftw/orgs","repos_url":"https://api.github.com/users/dstftw/repos","events_url":"https://api.github.com/users/dstftw/events{/privacy}","received_events_url":"https://api.github.com/users/dstftw/received_events","type":"User","site_admin":false},"created_at":"2016-03-04T05:06:26Z","updated_at":"2016-03-04T05:06:26Z","body":"Bitrate for f22 is not known beforehand. Other formats' bitrates are taken from metadata."}}