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

Unable to download enhanced bitrate videos (format ID 616) even with YouTube premium #6786

Closed
10 of 11 tasks
tummypics opened this issue Apr 12, 2023 · 9 comments
Closed
10 of 11 tasks
Labels
question Question

Comments

@tummypics
Copy link

tummypics commented Apr 12, 2023

DO NOT REMOVE OR SKIP THE ISSUE TEMPLATE

  • I understand that I will be blocked if I intentionally remove or skip any mandatory* field

Checklist

Region

France

Provide a description that is worded well enough to be understood

I checked that the video does indeed have an enhanced encode beforehand by using -F -cookies-from-browser chromium --extractor-args "youtube:player_client=ios" but it does not download ID 616 when running yt-dlp -f 616 --cookies-from-browser chromium --extractor-args "youtube:player_client=ios" https://www.youtube.com/watch?v=GuAcdIqcanA

Provide verbose output that clearly demonstrates the problem

  • Run your yt-dlp command with -vU flag added (yt-dlp -vU <your command line>)
  • If using API, add 'verbose': True to YoutubeDL params instead
  • Copy the WHOLE output (starting with [debug] Command-line config) and insert it below

Complete Verbose Output

C:\Users\mukatsuku\Downloads>yt-dlp.exe -vU -f 616 --cookies-from-browser chromium --extractor-args "youtube:player_client=ios" https://www.youtube.com/watch?v=GuAcdIqcanA
[debug] Command-line config: ['-vU', '-f', '616', '--cookies-from-browser', 'chromium', '--extractor-args', 'youtube:player_client=ios', 'https://www.youtube.com/watch?v=GuAcdIqcanA']
[debug] User config "C:\Users\mukatsuku\AppData\Roaming\yt-dlp\config.txt": ['--embed-thumbnail', '--format', 'bestvideo+bestaudio/best/mp4/ext:mp4:m4a', '--add-metadata', '-S', 'codec:av1:m4a']
[debug] Encodings: locale cp932, fs utf-8, pref cp932, out utf-8, error utf-8, screen utf-8
[debug] yt-dlp version stable@2023.03.04 [392389b7d] (win_exe)
[debug] Python 3.8.10 (CPython AMD64 64bit) - Windows-10-10.0.19044-SP0 (OpenSSL 1.1.1k  25 Mar 2021)
[debug] exe versions: ffmpeg N-110057-g1e406692e5-20230320 (setts), ffprobe N-110057-g1e406692e5-20230320
[debug] Optional libraries: Cryptodome-3.17, brotli-1.0.9, certifi-2022.12.07, mutagen-1.46.0, sqlite3-2.6.0, websockets-10.4
[Cookies] Extracting cookies from chromium
[debug] Extracting cookies from: "C:\Users\mukatsuku\AppData\Local\Chromium\User Data\Default\Cookies"
[debug] Found local state file at "C:\Users\mukatsuku\AppData\Local\Chromium\User Data\Local State"
[Cookies] Extracted 742 cookies from chromium
[debug] cookie version breakdown: {'v10': 742, 'other': 0, 'unencrypted': 0}
[debug] Proxy map: {}
[debug] Loaded 1786 extractors
[debug] Fetching release info: https://api.github.com/repos/yt-dlp/yt-dlp/releases/latest
Available version: stable@2023.03.04, Current version: stable@2023.03.04
Current Build Hash: 5590c57bd0433ed239a2deaaf92e2ad6f37fe50f53664c821575cafe106a9421
yt-dlp is up to date (stable@2023.03.04)
[youtube] Extracting URL: https://www.youtube.com/watch?v=GuAcdIqcanA
[youtube] GuAcdIqcanA: Downloading webpage
[debug] [youtube] Extracted SAPISID cookie
[youtube] GuAcdIqcanA: Downloading ios player API JSON
[youtube] GuAcdIqcanA: Downloading m3u8 information
[debug] Sort order given by user: codec:av1:m4a
[debug] Sort order given by extractor: quality, res, fps, hdr:12, source, vcodec:vp9.2, channels, acodec, lang, proto
[debug] Formats sorted by: hasvid, ie_pref, vcodec:av1(11), acodec:m4a(9), quality, res, fps, hdr:12(7), source, channels, lang, proto, filesize, fs_approx, tbr, vbr, abr, asr, vext, aext, hasaud, id
[info] GuAcdIqcanA: Downloading 1 format(s): 616
[info] Downloading video thumbnail 41 ...
WARNING: Unable to download video thumbnail 41: HTTP Error 404: Not Found
[info] Downloading video thumbnail 40 ...
WARNING: Unable to download video thumbnail 40: HTTP Error 404: Not Found
[info] Downloading video thumbnail 39 ...
WARNING: Unable to download video thumbnail 39: HTTP Error 404: Not Found
[info] Downloading video thumbnail 38 ...
WARNING: Unable to download video thumbnail 38: HTTP Error 404: Not Found
[info] Downloading video thumbnail 37 ...
[info] Writing video thumbnail 37 to: TVアニメ『天国大魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].webp
[debug] Invoking hlsnative downloader on "https://manifest.googlevideo.com/api/manifest/hls_playlist/expire/1681314869/ei/1X82ZMCAMOa4mLAP8c646A0/ip/193.32.126.218/id/1ae01c748a9c6a70/itag/616/source/youtube/requiressl/yes/ratebypass/yes/wft/1/sgovp/clen%3D31037886%3Bdur%3D100.016%3Bgir%3Dyes%3Bitag%3D356%3Blmt%3D1680996599403557/hls_chunk_host/rr5---sn-5hnednss.googlevideo.com/mh/8u/mm/31,26/mn/sn-5hnednss,sn-4g5edndr/ms/au,onr/mv/m/mvi/5/pl/24/ctier/A/pfa/5/initcwndbps/1285000/hightc/yes/vprv/1/playlist_type/DVR/dover/13/txp/5532434/mt/1681292920/fvip/3/short_key/1/keepalive/yes/fexp/24007246/sparams/expire,ei,ip,id,itag,source,requiressl,ratebypass,wft,sgovp,ctier,pfa,hightc,vprv,playlist_type/sig/AOq0QJ8wRAIgCphPVzEQD7hcb4O823o-B_acAjtgi1bg4C6eRlca0YsCIB8U3VMOy2AKzG3StoIfVFnKpbgU7NF4uZ_-gYDGYvyQ/lsparams/hls_chunk_host,mh,mm,mn,ms,mv,mvi,pl,initcwndbps/lsig/AG3C_xAwRgIhAJLceqI206TIJfGQOf1Iry9YbEuQvAnidJniA2_XgD5SAiEA26-eD43h-u8GWdFa3Zmh-MgjjMo_agkYfRG7L5RkGVY%3D/playlist/index.m3u8"
[hlsnative] Downloading m3u8 manifest
[hlsnative] Total fragments: 19
[download] Destination: TVアニメ『天国大魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].mp4
[debug] File locking is not supported. Proceeding without locking
[download] 100% of   29.61MiB in 00:00:06 at 4.42MiB/s
[debug] ffprobe command line: ffprobe -hide_banner -show_format -show_streams -print_format json "file:TVアニメ『天国大 魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].mp4"
[Metadata] Adding metadata to "TVアニメ『天国大魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].mp4"
[debug] ffmpeg command line: ffmpeg -y -loglevel "repeat+info" -i "file:TVアニメ『天国大魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].mp4" -map 0 -dn -ignore_unknown -c copy -write_id3v1 1 -metadata "title=TVアニメ『天国大魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」" -metadata "date=20230408" -metadata "description=TVアニメ『天国大魔境』
📌2023年4月1日より毎週土曜22時〜TOKYOMX・BS11ほかにて順次放送中
📌毎週土曜22時〜ディズニープラスにて世界見放題独占配信中

【OPテーマ】
💽BiSH「innocent arrogance」
 各プラットフォームにて楽曲配信中!!
 ▶https://bish.lnk.to/innocent_arrogance

公式サイト:https://tdm-anime.com/
公式Twitter:https://twitter.com/tdm_anime

【INTRODUCTION】
2024年、世界は崩壊した―
未曾有の大災害から15年。廃墟となった日本の地には“人食い(ヒルコ)”と呼ばれる異形の化け物が巣食い、人々は細々と身を寄せ合って生きていた。
東京・中野で便利屋を営むキルコは、とある女性から謎の依頼を受ける。
『この子を“天国”に連れて行って―』
そう言い残し息を引き取った彼女に託された少年、マル。
彼は「“天国”には俺と同じ顔をしたやつがいるらしい」と言うがそれ以上のことは何も知らず、2人は『天国探し』の旅に出ること に。

一方、壁に囲まれた美しい世界で暮らす子供たち。
学園長、優しい先生達・・・。そこには日々豊かで穏やかな時間が流れていた。そんなある日、トキオは “外の外に行きたいですか?”という謎のメッセージを受け取る。
「ここより外の世界があるの?」
初めて芽生えた疑問に戸惑うトキオはその出来事をきっかけとして、当たり前の日常に違和感を抱き始める――。

【CAST】
マル:佐藤元
キルコ:千本木彩花
稲崎露敏:中井和哉
トキオ:山村響
コナ:豊永利行
ミミヒメ:福圓美里
シロ:武内駿輔
クク:黒沢ともよ
アンズ:松岡美里
タカ:新祐樹
園長:磯辺万沙子
猿渡:武藤正史
青島:種﨑敦美

【STAFF】
原作:石黒正数(講談社「アフタヌーン」連載)
監督:森大貴 
シリーズ構成:深見真 
キャラクターデザイン:うつした(南方研究所)
ヒルコデザイン:古川良太
プロップデザイン: 富坂真帆、澤田譲治
銃器デザイン:髙田晃
メカデザイン:常木志伸
色彩設計:広瀬いづみ
美術監督:金子雄司
美術設定:ブリュネ・スタニスラス / 伊井蔵、上田瑞香、平澤晃弘、高橋武之
3D:directrain、IG3D、5(five)
モーショングラフィックス:大城丈宗
2DW:CAPSULE、濱中亜希子
撮影監督:脇顯太朗
編集:坂本久美子
音響監督:木村絵理子
音楽:牛尾憲輔
オープニングテーマ:BiSH「innocent arrogance」
エンディングテーマ:ASOBI 同盟「誰も彼も何処も何も知らない」
アニメ―ション制作:Production I.G
製作:天国大魔境製作委員会

【原作情報】
原作: 石黒正数 『天国大魔境』
連載: 講談社『アフタヌーン』(毎月25日頃発売)にて好評連載中!
コミックス: 第1巻~第8巻&公式コミックガイド発売中!

©石黒正数・講談社/天国大魔境製作委員会
#天国大魔境 #HeavenlyDelusion #BiSH #innocentarrogance #2023春アニメ #TENGOKUDAIMAKYO" -metadata "synopsis=TVアニメ『天 国大魔境』
📌2023年4月1日より毎週土曜22時〜TOKYOMX・BS11ほかにて順次放送中
📌毎週土曜22時〜ディズニープラスにて世界見放題独占配信中

【OPテーマ】
💽BiSH「innocent arrogance」
 各プラットフォームにて楽曲配信中!!
 ▶https://bish.lnk.to/innocent_arrogance

公式サイト:https://tdm-anime.com/
公式Twitter:https://twitter.com/tdm_anime

【INTRODUCTION】
2024年、世界は崩壊した―
未曾有の大災害から15年。廃墟となった日本の地には“人食い(ヒルコ)”と呼ばれる異形の化け物が巣食い、人々は細々と身を寄せ合って生きていた。
東京・中野で便利屋を営むキルコは、とある女性から謎の依頼を受ける。
『この子を“天国”に連れて行って―』
そう言い残し息を引き取った彼女に託された少年、マル。
彼は「“天国”には俺と同じ顔をしたやつがいるらしい」と言うがそれ以上のことは何も知らず、2人は『天国探し』の旅に出ること に。

一方、壁に囲まれた美しい世界で暮らす子供たち。
学園長、優しい先生達・・・。そこには日々豊かで穏やかな時間が流れていた。そんなある日、トキオは “外の外に行きたいですか?”という謎のメッセージを受け取る。
「ここより外の世界があるの?」
初めて芽生えた疑問に戸惑うトキオはその出来事をきっかけとして、当たり前の日常に違和感を抱き始める――。

【CAST】
マル:佐藤元
キルコ:千本木彩花
稲崎露敏:中井和哉
トキオ:山村響
コナ:豊永利行
ミミヒメ:福圓美里
シロ:武内駿輔
クク:黒沢ともよ
アンズ:松岡美里
タカ:新祐樹
園長:磯辺万沙子
猿渡:武藤正史
青島:種﨑敦美

【STAFF】
原作:石黒正数(講談社「アフタヌーン」連載)
監督:森大貴 
シリーズ構成:深見真 
キャラクターデザイン:うつした(南方研究所)
ヒルコデザイン:古川良太
プロップデザイン: 富坂真帆、澤田譲治
銃器デザイン:髙田晃
メカデザイン:常木志伸
色彩設計:広瀬いづみ
美術監督:金子雄司
美術設定:ブリュネ・スタニスラス / 伊井蔵、上田瑞香、平澤晃弘、高橋武之
3D:directrain、IG3D、5(five)
モーショングラフィックス:大城丈宗
2DW:CAPSULE、濱中亜希子
撮影監督:脇顯太朗
編集:坂本久美子
音響監督:木村絵理子
音楽:牛尾憲輔
オープニングテーマ:BiSH「innocent arrogance」
エンディングテーマ:ASOBI 同盟「誰も彼も何処も何も知らない」
アニメ―ション制作:Production I.G
製作:天国大魔境製作委員会

【原作情報】
原作: 石黒正数 『天国大魔境』
連載: 講談社『アフタヌーン』(毎月25日頃発売)にて好評連載中!
コミックス: 第1巻~第8巻&公式コミックガイド発売中!

©石黒正数・講談社/天国大魔境製作委員会
#天国大魔境 #HeavenlyDelusion #BiSH #innocentarrogance #2023春アニメ #TENGOKUDAIMAKYO" -metadata "purl=https://www.youtube.com/watch?v=GuAcdIqcanA" -metadata "comment=https://www.youtube.com/watch?v=GuAcdIqcanA" -metadata "artist=avex pictures" -movflags "+faststart" "file:TVアニメ『天国大魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].temp.mp4"
[ThumbnailsConvertor] Converting thumbnail "TVアニメ『天国大魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].webp" to png
[debug] ffmpeg command line: ffmpeg -y -loglevel "repeat+info" -f image2 -pattern_type none -i "file:TVアニメ『天国大魔 境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].webp" -update 1 -movflags "+faststart" "file:TVアニメ『天国大魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].png"
[EmbedThumbnail] mutagen: Adding thumbnail to "TVアニメ『天国大魔境』ノンクレジットオープニング映像 |BiSH「innocent arrogance」 [GuAcdIqcanA].mp4"
@tummypics tummypics added site-bug Issue with a specific website triage Untriaged issue labels Apr 12, 2023
@pukkandan
Copy link
Member

[info] GuAcdIqcanA: Downloading 1 format(s): 616
[debug] Invoking hlsnative downloader on "https://manifest.googlevideo.com/.../itag/616/source/...

The logs say otherwise. Why do you think it's not?

@pukkandan pukkandan added incomplete Further information is needed and removed triage Untriaged issue labels Apr 12, 2023
@tummypics
Copy link
Author

[info] GuAcdIqcanA: Downloading 1 format(s): 616
[debug] Invoking hlsnative downloader on "https://manifest.googlevideo.com/.../itag/616/source/...

The logs say otherwise. Why do you think it's not?

when i run the command with -F it says the file should be 66mb
image
image

@bashonly
Copy link
Member

bashonly commented Apr 12, 2023

614 mp4   1920x1080   24    │ ~ 34.93MiB 2861k m3u8  │ vp09.00.40.08 2861k video only          IOS
616 mp4   1920x1080   24    │ ~ 66.15MiB 5419k m3u8  │ vp09.00.40.08 5419k video only          IOS

The ~ signifies that the filesize is approximate, calculated by yt-dlp based on duration and bitrate. It is not a value provided by youtube.

If you download format 614 you can see that its actual filesize is smaller, too:

[info] GuAcdIqcanA: Downloading 1 format(s): 614
[download] 100% of   17.16MiB in 00:00:04 at 3.45MiB/s

It seems that youtube is exaggerating the bitrate somewhat for these 1080p HLS formats:

$ ffprobe f616.mp4
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'f616.mp4':
  Metadata:
    major_brand     : dash
    minor_version   : 0
    compatible_brands: iso6mp41
    creation_time   : 2023-04-12T12:00:32.000000Z
  Duration: 00:01:40.02, start: 0.000000, bitrate: 2483 kb/s
  Stream #0:0[0x1](und): Video: vp9 (Profile 0) (vp09 / 0x39307076), yuv420p(tv, bt709), 1920x1080, 2481 kb/s, 23.98 fps, 23.98 tbr, 1k tbn (default)
    Metadata:
      creation_time   : 2023-04-12T12:00:32.000000Z
      handler_name    : ISO Media file produced by Google Inc. Created on: 04/12/2023.
      vendor_id       : [0][0][0][0]

which explains the discrepancy between the approx filesize and actual filesize. Note that this actual bitrate is still higher than any other available format's bitrate

@bashonly bashonly added question Question and removed incomplete Further information is needed site-bug Issue with a specific website labels Apr 12, 2023
@derrod
Copy link

derrod commented Apr 13, 2023

It seems that youtube is exaggerating the bitrate somewhat for these 1080p HLS formats

Per RFC 8216 the BANDWIDTH property in the master playlist is the "peak segment bit rate", i.e. a maximum and not an average, therefore multiplying it by the duration will lead to exaggerated results: https://datatracker.ietf.org/doc/html/rfc8216#section-4.3.4.2

YouTube does not provide the AVERAGE-BANDWIDTH property that would allow a closer approximation.

Edit: Per a YouTube blog post from a few days ago they plan to roll out this "enhanced" quality on the web player soon. So from then on the rendition should be available as a DASH variant and the size displayed should be correct.

@ThePhoenix576
Copy link

I just downloaded it and it seems to be working. and it seems like it doesn't even need a premium account. Might be changed later ?? Here is the command i used to download the premium version

yt-dlp -f "616+251" --extractor-args "youtube:player_client=all" "https://www.youtube.com/watch?v=GuAcdIqcanA"

I used all so i can try 251 which is the highest audio in opus codec.

I compared the one with 614+251 and 616+251 and it does seem to be bigger. and this is without any account used. Might be needed in the future tho

image

@pukkandan
Copy link
Member

I used all so i can try 251 which is the highest audio in opus codec.

player_client=default,ios would be faster and give you the same results

and it seems like it doesn't even need a premium account.

Yeah, this, alongside the wrong filesize reported, appears to have been the cause of so much confusion

@ThePhoenix576
Copy link

I used all so i can try 251 which is the highest audio in opus codec.

player_client=default,ios would be faster and give you the same results

and it seems like it doesn't even need a premium account.

Yeah, this, alongside the wrong filesize reported, appears to have been the cause of so much confusion

Yeah true. It is weird how we can download it without a premium account. is it the same for premium audio or the 320kbps or something audio? also, it is weird how "premium" 1080p is not on all videos. It is only on some videos, and the average bitrate ranges from 1.5x of the original or sometimes 2x. So far haven't seen it on any gameplay streams so i can't judge that well. Would be nice if they applied it on some gameplay streams so we can actually see if it is worth the size etc

@ThePhoenix576
Copy link

ThePhoenix576 commented Apr 13, 2023

Seems like it is available here
https://www.youtube.com/watch?v=Z899M4v2NL8

More details. Not that much. Tho this is just a still frame
image
image

Here's the bitrate difference :
image

@azzydoesgit
Copy link

azzydoesgit commented Apr 16, 2023

I used all so i can try 251 which is the highest audio in opus codec.

player_client=default,ios would be faster and give you the same results

and it seems like it doesn't even need a premium account.

Yeah, this, alongside the wrong filesize reported, appears to have been the cause of so much confusion

Yeah true. It is weird how we can download it without a premium account. is it the same for premium audio or the 320kbps or something audio? also, it is weird how "premium" 1080p is not on all videos. It is only on some videos, and the average bitrate ranges from 1.5x of the original or sometimes 2x. So far haven't seen it on any gameplay streams so i can't judge that well. Would be nice if they applied it on some gameplay streams so we can actually see if it is worth the size etc

Is this still the case? I'm trying to see the differences in bitrate by using --list-formats, and even with --allow-unplayable-formats, I don't see the enhanced bitrate options for https://www.youtube.com/watch?v=Z899M4v2NL8

Nevermind, just had to use --extractor-args "youtube:player_client=all"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Question
Projects
None yet
Development

No branches or pull requests

6 participants