bodaay / HuggingFaceModelDownloader

Simple go utility to download HuggingFace Models and Datasets
Apache License 2.0
483 stars 49 forks source link

FYI shockingly slow transfer in wsl2 #12

Closed pinballelectronica closed 1 year ago

pinballelectronica commented 1 year ago

Great idea to build this- Model downloading is unnecessarily annoying with HF.

Very slow xfer in wsl2

_Downloading Storage/turboderpCodeLlama-34B-instruct-exl2/output-00001-of-00004.safetensors Speed: 1.12 MB/sec, 1.24%

At the same time fast.com is giving me upwards of 500mbit/sec. LFS clone is 20x faster on this machine usually It's also eating a pretty significant amount of CPU considering what it's doing - 30% on a i9-12900k

1491 root 20 0 1606540 42548 7840 S 31.7 0.1 1:08.95 hfdownloader

Ubuntu 22.04

_/mnt/g/exllama# hfdownloader -m turboderp/CodeLlama-34B-instruct-exl2 -t access_token -b 6.0bpw Model: turboderp/CodeLlama-34B-instruct-exl2 Branch: 6.0bpw Storage: Storage NumberOfConcurrentConnections: 5 Append Filter Names to Folder: false Skip SHA256 Check: false Token: some_token__

Am I doing something wrong? Thanks

pinballelectronica commented 1 year ago

Merging Storage/turboderp_CodeLlama-34B-instruct-exl2/output-00001-of-00004.safetensors Chunks

(stuck here for two hours).

jtabox commented 4 months ago

I know this is closed, but in case anyone stumbles upon this issue: Yeah, don't download to a Windows NTFS partition mount directly (as the OP here doing in /mnt/g/...). Generally it's not a good idea to perform high I/O tasks from Windows to WSL and vice versa since the conversion taking place is very slow. Better download your files inside WSL and move them afterwards.

pinballelectronica commented 2 months ago

It's never too late for the present :) Sometimes I forget about this and wonder why a model is taking literally 10-20x longer to chug through /mnt/c/blah over /home.