-
Notifications
You must be signed in to change notification settings - Fork 9
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
Is 16MiB a hard limit for max pieces size? #34
Comments
This is a soft limit. It only affects the automatic piece size calculation. You can override/specify the piece size yourself with the For example to create a torrent with 64 MiB: Now why does py3createtorrent prefer to keep the piece size limited to 16 MiB in the first place? The BitTorrent spec itself does not explicitly limit the piece size, but many clients only have limited support for large piece sizes. Quote:
Source: qbittorrent/qBittorrent#19535 The 16 MiB soft limit, however, is from over 10 years ago. Today it should be safe (widely supported) to use 64 MiB pieces. So I will increase the soft limit from 16 MiB to 64 MiB. |
Wow, apprecaite for such a detailed explaination! Yup, increasing 16MB to 64MB can reduce up to 4x of the torrent file size and definitely will help my project. Thanks! |
Hi author,
Thanks for sharing the great tools! I am using your implementation to prototype torrent seeding for large language models in huggingface. Those files (usually >10GB) will lead to many chunks thus make .torrent file itself very large.
I am considering whether we should increase the piece_length in
calculate_piece_length()
, but noticing there is one comment sayingI checked the specification and documents for torrent protocal but didn't find the source of
16MiB
. I wonder is this a hard limit?The text was updated successfully, but these errors were encountered: