You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
from huggingface_hub import HfApi
api = HfApi()
api.upload_large_folder(repo_id="YourUserName/reponame",
repo_type="model",
folder_path=r"/home/Ubuntu/apps/StableSwarmUI/Models/Lora")
print(".\n.\nUPLOAD COMPLETED")
Describe the bug
Initial upload
10581 files, 304.8 GB
I waited few hours, it uploaded and committed like 9576, then i stopped execution and came back few hours later
However when I execute again, it checks which files were already uploaded and it consumes API limit immediately
The folder structure of uploaded repo like this. I think somehow upload of small files can be more optimized to not consume API request limit
Extension:
Total files: 1
Average size: 4.00 KB
Min size: 4.00 KB
Max size: 4.00 KB
Extension: .metadata
Total files: 10581
Average size: 4.00 KB
Min size: 4.00 KB
Max size: 4.00 KB
Extension: .safetensors
Total files: 44
Average size: 6.35 GB
Min size: 3.97 GB
Max size: 6.46 GB
Extension: .json
Total files: 3
Average size: 4.00 KB
Min size: 4.00 KB
Max size: 4.00 KB
Extension: .toml
Total files: 6
Average size: 4.00 KB
Min size: 4.00 KB
Max size: 4.00 KB
Extension: .npz
Total files: 5240
Average size: 260.00 KB
Min size: 260.00 KB
Max size: 260.00 KB
Extension: .png
Total files: 44
Average size: 1.48 MB
Min size: 1.29 MB
Max size: 1.64 MB
Extension: .txt
Total files: 42
Average size: 4.00 KB
Min size: 4.00 KB
Max size: 4.00 KB
Extension: .jpg
Total files: 5200
Average size: 640.86 KB
Min size: 220.00 KB
Max size: 1.27 MB
Upload used code as below
Describe the bug
Initial upload
10581 files, 304.8 GB
I waited few hours, it uploaded and committed like 9576, then i stopped execution and came back few hours later
However when I execute again, it checks which files were already uploaded and it consumes API limit immediately
The folder structure of uploaded repo like this. I think somehow upload of small files can be more optimized to not consume API request limit
Reproduction
No response
Logs
No response
System info
The text was updated successfully, but these errors were encountered: