Closed vlakoff closed 6 years ago
Try :
youtube-dl.exe -f 136+140 "https://www.youtube.com/watch?v=AkI8MvKk64I"
Thanks. It gives me separate video and audio files, still better than nothing.
Yet, youtube-dl should be able to handle this video as regular.
To mix video + audio, you need to put ffmpeg.exe in same directory as youtube-dl. (ffmpeg 32: 'http://ffmpeg.zeranoe.com/builds/win32/static/?C=M&O=D') (ffmpeg 64: 'http://ffmpeg.zeranoe.com/builds/win64/static/?C=M&O=D')
By adding ffmpeg.exe, the video and audio files are now muxed with your -f 136+140
option.
Interestingly, now I can also download the video without format options. However, I get a warning, the result is a mkv file, and the video is 1080p (usually I get 720p, even when 1080p is available, which is fine as I don't need the extra quality of 1080p).
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', 'https://www.youtube.com/watch?v=AkI8MvKk64I']
[debug] Encodings: locale cp1252, fs mbcs, out cp1252, pref cp1252
[debug] youtube-dl version 2017.11.06
[debug] Python version 3.4.4 - Windows-7-6.1.7601-SP1
[debug] exe versions: ffmpeg N-88668-g723b6baaf8
[debug] Proxy map: {}
[youtube] AkI8MvKk64I: Downloading webpage
[youtube] AkI8MvKk64I: Downloading video info webpage
[youtube] AkI8MvKk64I: Extracting video information
[youtube] AkI8MvKk64I: Downloading MPD manifest
[debug] Default format spec: bestvideo+bestaudio/best
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
[debug] Invoking downloader on 'https://r4---sn-n4g-nmce.googlevideo.com/videoplayback/id/02423c32f2a4eb82/itag/137/source/youtube/requiressl/yes/pcm2cms/yes/initcwndbps/580000/mv/m/ms/au/ei/UU0GWo3NLsG5cNbDoeAC/pl/24/mn/sn-n4g-nmce/mm/31/ratebypass/yes/mime/video%2Fmp4/otfp/1/gir/yes/clen/293286033/lmt/1500825285346938/dur/4491.553/mt/1510362286/signature/82D397FFF6B52B098C01BE8886FEF05BE3C0C734.0FA7DFC171A2A0BCDDB59F7FA1FF3A529850C5BA/key/dg_yt0/ip/92.94.220.216/ipbits/0/expire/1510384049/sparams/ip,ipbits,expire,id,itag,source,requiressl,pcm2cms,initcwndbps,mv,ms,ei,pl,mn,mm,ratebypass,mime,otfp,gir,clen,lmt,dur/'
[dashsegments] Total fragments: 843
[download] Destination: Radio Melon - Des Melons et des Hommes 2 - Arnaud et Saint Claude-AkI8MvKk64I.f137.mp4
[download] 0.1% of ~587.79KiB at Unknown speed ETA 01:49
(...)
[download] 100.0% of ~279.69MiB at 2.54MiB/s ETA 00:00
[download] 100% of 279.69MiB in 04:03
[debug] Invoking downloader on 'https://r4---sn-n4g-nmce.googlevideo.com/videoplayback?mm=31&mn=sn-n4g-nmce&id=o-AB9diNBb3G6a5Jf_gmkuE8xcKalHvOfq6q7Sfi3DGUic&keepalive=yes&ip=92.94.220.216&pl=24&mt=1510362286&mv=m&ei=UU0GWt6JEMHHcdW4k6AN&ms=au&expire=1510384049&clen=76519068&itag=251&gir=yes&key=yt6&signature=6EA7AAA0FBA2BF6590D770A815F28223473C41A3.79C8DEBA1D6B91A70D670E1A6056E902C8A3437F&requiressl=yes&source=youtube&dur=4491.601&lmt=1501721011587485&ipbits=0&initcwndbps=580000&sparams=clen%2Cdur%2Cei%2Cgir%2Cid%2Cinitcwndbps%2Cip%2Cipbits%2Citag%2Ckeepalive%2Clmt%2Cmime%2Cmm%2Cmn%2Cms%2Cmv%2Cpcm2cms%2Cpl%2Crequiressl%2Csource%2Cexpire&mime=audio%2Fwebm&pcm2cms=yes&ratebypass=yes'
[download] Destination: Radio Melon - Des Melons et des Hommes 2 - Arnaud et Saint Claude-AkI8MvKk64I.f251.webm
[download] 0.0% of 72.97MiB at Unknown speed ETA Unknown ETA
(...)
[download] 100.0% of 72.97MiB at 4.91MiB/s ETA 00:00
[download] 100% of 72.97MiB in 00:16
[ffmpeg] Merging formats into "Radio Melon - Des Melons et des Hommes 2 - Arnaud et Saint Claude-AkI8MvKk64I.mkv"
[debug] ffmpeg command line: ffmpeg -y -i "file:Radio Melon - Des Melons et des Hommes 2 - Arnaud et Saint Claude-AkI8MvKk64I.f137.mp4" -i "file:Radio Melon - Des Melons et des Hommes 2 - Arnaud et Saint Claude-AkI8MvKk64I.f251.webm" -c copy -map "0:v:0" -map "1:a:0" "file:Radio Melon - Des Melons et des Hommes 2 - Arnaud et Saint Claude-AkI8MvKk64I.temp.mkv"
Deleting original file Radio Melon - Des Melons et des Hommes 2 - Arnaud et Saint Claude-AkI8MvKk64I.f137.mp4 (pass -k to keep)
Deleting original file Radio Melon - Des Melons et des Hommes 2 - Arnaud et Saint Claude-AkI8MvKk64I.f251.webm (pass -k to keep)
For convenience, here is the output from youtube-dl -F
:
format code extension resolution note
139 m4a audio only DASH audio 52k , m4a_dash container, mp4a.40.5@ 48k (22050Hz)
249 webm audio only DASH audio 59k , opus @ 50k, 28.12MiB
250 webm audio only DASH audio 77k , opus @ 70k, 36.76MiB
140 m4a audio only DASH audio 132k , m4a_dash container, mp4a.40.2@128k (44100Hz)
171 webm audio only DASH audio 138k , vorbis@128k, 68.61MiB
251 webm audio only DASH audio 153k , opus @160k, 72.97MiB
160 mp4 256x144 DASH video 66k , avc1.4d400c, 30fps, video only
278 webm 256x144 144p 105k , webm container, vp9, 30fps, video only, 16.30MiB
133 mp4 426x240 DASH video 106k , avc1.4d4015, 30fps, video only
242 webm 426x240 240p 112k , vp9, 30fps, video only, 30.67MiB
134 mp4 640x360 DASH video 164k , avc1.4d401e, 30fps, video only
243 webm 640x360 360p 198k , vp9, 30fps, video only, 53.61MiB
244 webm 854x480 480p 298k , vp9, 30fps, video only, 80.38MiB
135 mp4 854x480 DASH video 319k , avc1.4d401f, 30fps, video only
247 webm 1280x720 720p 544k , vp9, 30fps, video only, 129.86MiB
136 mp4 1280x720 DASH video 568k , avc1.4d401f, 30fps, video only
248 webm 1920x1080 1080p 984k , vp9, 30fps, video only, 193.80MiB
137 mp4 1920x1080 DASH video 2115k , avc1.640028, 30fps, video only
17 3gp 176x144 small , mp4v.20.3, mp4a.40.2@ 24k
36 3gp 320x180 small , mp4v.20.3, mp4a.40.2
43 webm 640x360 medium , vp8.0, vorbis@128k
18 mp4 640x360 medium , avc1.42001E, mp4a.40.2@ 96k
22 mp4 1280x720 hd720 , avc1.64001F, mp4a.40.2@192k (best)
Long story short, would it be possible to improve youtube-dl's handling of videos like this one?
Yes, but this warning
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
is normal. It's a result of the default format selection used by youtube-dl and the formats offered by YouTube.
This video really can't be downloaded without a muxer?
^ Basically any YT vid can, but you're sacrificing vid and audio quality to some extent.
--format "best" "https://www.youtube.com/watch?v=AkI8MvKk64I"
will get you the best single-package option YT offers. You won't get the very best vid and very best audio you'd get by default, but you can play the file right away and it's identical to the one you see on YT.
The issue is precisely that youtube-dl fails downloading the video if there is no muxer installed.
The file with the best resolution is probably corrupted. If you really don't want use a muxer, it's possible to download the video 640x360 with audio 96k :
youtube-dl.exe -f 18 "https://www.youtube.com/watch?v=AkI8MvKk64I"
It works.
youtube-dl fails to download this video in particular: https://www.youtube.com/watch?v=AkI8MvKk64I
I have no trouble downloading other videos, including the other videos of this YouTube channel.