Skip to main content

No project description provided

Project description

HF Transfer

Speed up file transfers with the Hub.

DISCLAIMER

This library is a power user tool, to go beyond ~500MB/s on very high bandwidth network, where Python cannot cap out the available bandwidth.

This is not meant to be a general usability tool. Progressbar is experimentally implemented as callback.

Please file issues only if there's an issue on the underlying downloaded file.

Contributing

python3 -m venv ~/.venv/hf_transfer
source ~/.venv/hf_transfer/bin/activate
pip install maturin
maturin develop

huggingface_hub

If you are working on changes with huggingface_hub

git clone git@github.com:huggingface/huggingface_hub.git
# git clone https://github.com/huggingface/huggingface_hub.git

cd huggingface_hub
python3 -m pip install -e ".[quality]"

You can use the following test script:

import os

# os.environ["HF_ENDPOINT"] = "http://localhost:5564"
os.environ["HF_HUB_ENABLE_HF_TRANSFER"] = "1"

from huggingface_hub import HfApi, logging

logging.set_verbosity_debug()
hf = HfApi()
hf.upload_file(path_or_fileobj="/path/to/my/repo/some_file", path_in_repo="some_file", repo_id="my/repo", repo_type="model")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hf_transfer-0.1.4rc1.tar.gz (20.6 kB view hashes)

Uploaded Source

Built Distributions

hf_transfer-0.1.4rc1-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-pp37-pypy37_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-cp312-none-win_amd64.whl (1.3 MB view hashes)

Uploaded CPython 3.12 Windows x86-64

hf_transfer-0.1.4rc1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded CPython 3.12 manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-cp311-none-win_amd64.whl (1.3 MB view hashes)

Uploaded CPython 3.11 Windows x86-64

hf_transfer-0.1.4rc1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-cp311-cp311-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl (3.3 MB view hashes)

Uploaded CPython 3.11 macOS 10.9+ universal2 (ARM64, x86-64) macOS 10.9+ x86-64 macOS 11.0+ ARM64

hf_transfer-0.1.4rc1-cp310-none-win_amd64.whl (1.3 MB view hashes)

Uploaded CPython 3.10 Windows x86-64

hf_transfer-0.1.4rc1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl (3.3 MB view hashes)

Uploaded CPython 3.10 macOS 10.9+ universal2 (ARM64, x86-64) macOS 10.9+ x86-64 macOS 11.0+ ARM64

hf_transfer-0.1.4rc1-cp39-none-win_amd64.whl (1.3 MB view hashes)

Uploaded CPython 3.9 Windows x86-64

hf_transfer-0.1.4rc1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl (3.3 MB view hashes)

Uploaded CPython 3.9 macOS 10.9+ universal2 (ARM64, x86-64) macOS 10.9+ x86-64 macOS 11.0+ ARM64

hf_transfer-0.1.4rc1-cp38-none-win_amd64.whl (1.3 MB view hashes)

Uploaded CPython 3.8 Windows x86-64

hf_transfer-0.1.4rc1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded CPython 3.8 manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl (3.3 MB view hashes)

Uploaded CPython 3.8 macOS 10.9+ universal2 (ARM64, x86-64) macOS 10.9+ x86-64 macOS 11.0+ ARM64

hf_transfer-0.1.4rc1-cp37-none-win_amd64.whl (1.3 MB view hashes)

Uploaded CPython 3.7 Windows x86-64

hf_transfer-0.1.4rc1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view hashes)

Uploaded CPython 3.7m manylinux: glibc 2.17+ x86-64

hf_transfer-0.1.4rc1-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl (3.3 MB view hashes)

Uploaded CPython 3.7m macOS 10.9+ universal2 (ARM64, x86-64) macOS 10.9+ x86-64 macOS 11.0+ ARM64

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page