-
Notifications
You must be signed in to change notification settings - Fork 24
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
External Downloader #207
Comments
Hi, interesting, do you have an exempel URL i can test with? Not sure how youtube-dl work with streaming to stdout like ydls do and external downloader |
Direct download (YDLS downloads same speed as this)
Adding chunk:
|
Thanks, will have a look in a few days, on vacation. If you want to experiment, what would be needed for ydls is for youtube-dl to somehow use external downloader while writing to stdout, which kind i guess might make it a bit harder to do parellell downloads |
External downloader is unneded if You can manage to make it possible to use option CHUNK SIZE That is internal YoutubeDL command Ty |
Hi again, i tried to reproduce without external downloader and only use chunk size but i get about the same speed for dailymotion. But with external downloader aria2c i get much faster speed. Unfortunately it looks like aria2c does not support streaming to stdout which would be required they way ydls works currently, to respond fast with http body and store as little as possible on disk. There is an open issue for aria2c to support stdout aria2/aria2#190 also found this won't fix issue for youtube-dl about streaming and aria2c ytdl-org/youtube-dl#25345 Could the reason you saw faster download with There shouldn't in theory be any problems supporting streaming and parallell downloads just have to use a bit more disk or memory to buffer to get ordering right. I had a quick look at the other supported external downloaders but couldn't find any that seem to support it. |
Hi, want to investigate or work on this more or should i close? |
Hi, This is test from 2 separate videos, so it is not resuming download TY
|
For me i see this: https://www.dailymotion.com/video/x7y1b78 (downloads a 27651229 byte file, media bitrate 463 kb/s) https://www.dailymotion.com/video/x4gmtws (downloads a 21496392 byte file, media bitrate 2138 kb/s) I wonder if they do some throttling based on media bitrate etc? |
Probably some throttling with token because download from YT is getting full speed. |
Do you think this would be a global option or a per request option? Also thinking this should probably be off by default? Have some fear sending range requests might affect some sites. And ideas? |
Better peer request, there is many sites this is unneeded I believe with multiple request it might get to much memory consuption or something else can go bad... http://ydls/?format=mp4&chunk=10&url=http..... Default disabled |
Initial version #208 requires wader/goutubedl#89 you can use go module To test:
I noticed that Also been thinking if ydls should have some kind of known sites config? maybe hard to maintain? |
Great work mate, I don't know how much other people would use site config, I personaly don't need it. OR Config1= Config2= Then with YDLS |
Was thinking that ydls would ship (in ydls.json etc) with known-good site configurations, ex that dailymotion works and is probably faster with chunk size. Could be something like this in ydls.json:
(URL regex might be messy, could possibly look at what extractor youtube-dl choose also) How would you like to use user-agent and referer? use own hardcoded values for some reason? |
Actually, that would be good with json, great idea... User agend and referrer are just example commands, but for instance some videos need login with commands "-u username -p password" So to add to json
|
But, at least for me, next what I would really much use could be different downloader. |
Yes good idea, i've thought about how to do login, this could be one way. For downloader i think it should be easy to support as long as youtube-dl can do streaming using it. To support non-streaming would require some bigger changes and also would mean require more temp disk space where ydls is running, maybe also would require doing some trix to keep the connection from timing out if used thru a proxy etc. |
Hello, Would it be possible to make it as follows: Where downloader = optional synopsis So to use YDLS as online transcode services for videos or music with direct link, just to skip YOUTUBE DL completely For instance one of videos from https://www.nhc.noaa.gov/video/?C=D;O=A You can use it in ffmpeg directly but it would be good if I can use ydls to transcode it do desired format and have it on the fly without much hustle |
I think that should kind of already work. Quite sure if one gives youtube-dl a URL to a plain media file it will just download it. A bit wasteful that is goes thru youtube-dl but shouldnt be much |
Remembered that i should mention that because ydls streams it do tell and make ffmpeg to skip writing some seek indexes and fragment depending on conatiner format. Usually not a problem for most players but maybe good to know. |
Hey, i switched to yt-dlp some weeks ago, maybe that will make tweaks less needed? |
Hello,
Any possibility to add option for external downloader or add some arguments?
eg. "--external-downloader aria2c" and "--http-chunk-size 10M"
On some files I get very slow downloads (same on ydls and youtube-dl directly) but when using external downloader or adding chunk size it goes well with youtube-dl
TY
The text was updated successfully, but these errors were encountered: