赞
踩
The Hugging Face Hub is a platform with over 350k models, 75k datasets, and 150k demo apps (Spaces), all open source and publicly available, in an online platform where people can easily collaborate and build ML together. The Hub works as a central place where anyone can explore, experiment, collaborate, and build technology with Machine Learning.
Downloading models
https://huggingface.co/docs/hub/models-downloading
https://huggingface.co/ggerganov/whisper.cpp/tree/main
# Make sure you have git-lfs installed (https://git-lfs.com)
git lfs install
git clone https://huggingface.co/ggerganov/whisper.cpp
# If you want to clone without large files - just their pointers
GIT_LFS_SKIP_SMUDGE=1 git clone https://huggingface.co/ggerganov/whisper.cpp
(base) yongqiang@yongqiang:~/whisper_work/whisper_cpp_models$ git lfs install
Error: Failed to call git rev-parse --git-dir: exit status 128
Git LFS initialized.
(base) yongqiang@yongqiang:~/whisper_work/whisper_cpp_models$
(base) yongqiang@yongqiang:~/whisper_work/whisper_cpp_models$ git lfs install --skip-repo
Git LFS initialized.
(base) yongqiang@yongqiang:~/whisper_work/whisper_cpp_models$
(base) yongqiang@yongqiang:~/whisper_work/whisper_cpp_models$ GIT_LFS_SKIP_SMUDGE=1 git clone https://huggingface.co/ggerganov/whisper.cpp
Cloning into 'whisper.cpp'...
remote: Enumerating objects: 56, done.
remote: Counting objects: 100% (39/39), done.
remote: Compressing objects: 100% (39/39), done.
remote: Total 56 (delta 6), reused 0 (delta 0), pack-reused 17 (from 1)
Unpacking objects: 100% (56/56), 11.31 KiB | 964.00 KiB/s, done.
(base) yongqiang@yongqiang:~/whisper_work/whisper_cpp_models$
You can use the huggingface_hub
library to create, delete, update and retrieve information from repos. You can also download files from repos or integrate them into your library! For example, you can quickly load a Scikit-learn model with a few lines.
from huggingface_hub import hf_hub_download
import joblib
REPO_ID = "YOUR_REPO_ID"
FILENAME = "sklearn_model.joblib"
model = joblib.load(
hf_hub_download(repo_id=REPO_ID, filename=FILENAME)
)
Since all models on the Model Hub are Git repositories, you can clone the models locally by running:
git lfs install
git clone git@hf.co:<MODEL ID> # example: git clone git@hf.co:bigscience/bloom
git lfs install
git clone https://huggingface.co/ggerganov/whisper.cpp
If you have write-access to the particular model repo, you’ll also have the ability to commit and push revisions to the model.
[1] Yongqiang Cheng, https://yongqiang.blog.csdn.net/
[2] Downloading models, https://huggingface.co/docs/hub/models-downloading
[3] Git Large File Storage (LFS) 的安装与使用, https://yongqiang.blog.csdn.net/article/details/139218502
[4] 配置 HTTP 代理 (HTTP proxy), https://yongqiang.blog.csdn.net/article/details/139378962
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。