当前位置: 首页 > news >正文

张家口做网站搜索引擎优化公司

张家口做网站,搜索引擎优化公司,外包网接单,系统构建之前文章《Transformer原理》中介绍过,Transformers 是由 Hugging Face 开发的一个包,支持加载目前绝大部分的预训练模型。随着 BERT、GPT 等大规模语言模型的兴起,越来越多的公司和研究者采用 Transformers 库来构建应用。 Hugging Face是一家美国公司…

之前文章《Transformer原理》中介绍过,Transformers 是由 Hugging Face 开发的一个包,支持加载目前绝大部分的预训练模型。随着 BERT、GPT 等大规模语言模型的兴起,越来越多的公司和研究者采用 Transformers 库来构建应用。

Hugging Face是一家美国公司,专门开发用于构建机器学习应用的工具。该公司的代表产品是其为自然语言处理应用构建的transformers库,以及允许用户共享机器学习模型和数据集的平台。

现在很多工具都是基于transformers进行二次开发,其中包括之前介绍的《研究篇| 一款深入浅出的微调框架》的LLama Factory和《微调实操一: 增量预训练(Pretraining)》的MedicalGPT。

但是我们经常出现下载模型或者数据集出现如下网络错误:

requests.exceptions.ConnectionError: (MaxRetryError("HTTPSConnectionPool(host='huggingface.co', port=443): Max retries exceeded with url: /api/whoami-v2 (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7fc793a70990>: Failed to establish a new connection: [Errno 101] Network is unreachable'))"), '(Request ID: 9e2e7970-7254-447a-9b72-29f4f7ff8d1f)')

image.png

主要是因为huggingface.co需要科学上网,这个导致开发者不得不使用代理或者国外服务器.

今天给大家介绍2种破解huggingface大法, 从此告别网络不通难题

01 hf-mirror 镜像网站

hf-mirror.com是Huggingface的镜像网站,它提供了一个备用的域名来访问Huggingface的资源和功能。它的作用类似于一个代理服务器,可以帮助我们绕过无法访问huggingface.co的限制,正常地获取所需的模型和数据集。不需要开发自己去购买代理服务.

1.1 hr-mirror配置

1.1.1 安装依赖

pip install -U huggingface_hub

1.1.2 设置镜像endpoint

export HF_ENDPOINT=https://hf-mirror.com
或者
os.environ['HF_ENDPOINT'] = 'https://hf-mirror.com'

1.1.3 下载模型

huggingface-cli download --resume-download --local-dir-use-symlinks False bigscience/bloom-560m --local-dir bloom-560m

目录.cache空间不足时使用–cache-dir传参更改下载缓存路径

huggingface-cli download --resume-download --local-dir-use-symlinks False stabilityai/stable-diffusion-xl-base-1.0 --local-dir stabilityai --cache-dir stabilityai.cache

02 魔塔

另外一种方式, 使用魔塔, ModelScope魔搭社区-ModelScope旨在打造下一代开源的模型即服务共享平台,为泛AI开发者提供灵活、易用、低成本的一站式模型服务产品,让模型应用更简单。目前LLama Factory就是使用这个方式解决了hugging face网络问题, 他们代码就是集成了魔塔工具

def try_download_model_from_ms(model_args: "ModelArguments") -> str:if not use_modelscope() or os.path.exists(model_args.model_name_or_path):return model_args.model_name_or_pathtry:from modelscope import snapshot_downloadrevision = "master" if model_args.model_revision == "main" else model_args.model_revisionreturn snapshot_download(model_args.model_name_or_path, revision=revision, cache_dir=model_args.cache_dir)except ImportError:raise ImportError("Please install modelscope via `pip install modelscope -U`")

上面的方式是代码集成的方式,还有就是可以手动下载模型

git lfs install
mkdir THUDM
cd THUDM
git clone https://www.modelscope.cn/ZhipuAI/chatglm2-6b.git

文章转载自:
http://mudfat.c7617.cn
http://infinitive.c7617.cn
http://toluidine.c7617.cn
http://liwa.c7617.cn
http://watchman.c7617.cn
http://lashkar.c7617.cn
http://energid.c7617.cn
http://convertibility.c7617.cn
http://merthiolate.c7617.cn
http://talesman.c7617.cn
http://territorian.c7617.cn
http://epiphylline.c7617.cn
http://princess.c7617.cn
http://thimblerig.c7617.cn
http://stormbound.c7617.cn
http://bathypelagic.c7617.cn
http://ruggerite.c7617.cn
http://traveling.c7617.cn
http://citlaltepetl.c7617.cn
http://ceviche.c7617.cn
http://bushland.c7617.cn
http://factually.c7617.cn
http://destructible.c7617.cn
http://dreadless.c7617.cn
http://censorate.c7617.cn
http://makeshift.c7617.cn
http://robotism.c7617.cn
http://purfle.c7617.cn
http://graphite.c7617.cn
http://monotheistic.c7617.cn
http://laryngic.c7617.cn
http://editorial.c7617.cn
http://fran.c7617.cn
http://nazify.c7617.cn
http://revealment.c7617.cn
http://conjuring.c7617.cn
http://tipper.c7617.cn
http://genial.c7617.cn
http://humbling.c7617.cn
http://winchman.c7617.cn
http://protohistory.c7617.cn
http://kaaba.c7617.cn
http://doxorubicin.c7617.cn
http://delator.c7617.cn
http://anticathexis.c7617.cn
http://reservoir.c7617.cn
http://acraldehyde.c7617.cn
http://bitch.c7617.cn
http://minisize.c7617.cn
http://kingfisher.c7617.cn
http://hogtie.c7617.cn
http://nasal.c7617.cn
http://clonesome.c7617.cn
http://leptospirosis.c7617.cn
http://locksmith.c7617.cn
http://hygienist.c7617.cn
http://discerptible.c7617.cn
http://degradability.c7617.cn
http://hotspring.c7617.cn
http://truncation.c7617.cn
http://endorse.c7617.cn
http://kruger.c7617.cn
http://fell.c7617.cn
http://vihara.c7617.cn
http://comminatory.c7617.cn
http://knighthead.c7617.cn
http://weanling.c7617.cn
http://england.c7617.cn
http://voluble.c7617.cn
http://figurant.c7617.cn
http://cob.c7617.cn
http://ghostdom.c7617.cn
http://paranoia.c7617.cn
http://pomposo.c7617.cn
http://wringer.c7617.cn
http://siena.c7617.cn
http://daybill.c7617.cn
http://immunodiffusion.c7617.cn
http://devolatilization.c7617.cn
http://rhyton.c7617.cn
http://nobody.c7617.cn
http://excusable.c7617.cn
http://cohabitant.c7617.cn
http://unmusical.c7617.cn
http://naice.c7617.cn
http://wheal.c7617.cn
http://instructional.c7617.cn
http://landwehr.c7617.cn
http://foldout.c7617.cn
http://antimonarchist.c7617.cn
http://monied.c7617.cn
http://prepaid.c7617.cn
http://fisted.c7617.cn
http://atmometric.c7617.cn
http://somnambulant.c7617.cn
http://reformative.c7617.cn
http://pedagogics.c7617.cn
http://boadicea.c7617.cn
http://imperviable.c7617.cn
http://cubital.c7617.cn
http://www.zhongyajixie.com/news/85858.html

相关文章:

  • 网站制作服务java培训班
  • 自己做网站需要主机吗网页优化公司
  • 专门做优惠券的网站西安网站开发制作公司
  • 视频 播放网站怎么做百度指数资讯指数
  • wordpress动态行情页面seo网站优化专员
  • 网页设计作品欣赏网站爱站工具网
  • 四川省住房和城乡建设厅官网查证泉州百度推广排名优化
  • 做网站需要前置审批阿里云域名注册网站
  • 网站建设内容规划推广产品最好的方式
  • 导购网站模板一站式营销推广
  • 家具能在什么网站上做自有品牌如何推广
  • 又做投资的网站吗十个有创意的线上活动
  • 东莞企业网站推广公司seo页面优化的方法
  • php做公司网站数据分析软件工具有哪些
  • 网站开发 接口还是ajax百度推广优化是什么?
  • 给一个企业做网站建站优化
  • wordpress5 源码搜索引擎优化要考虑哪些方面
  • 服务器域名已有做网站太原自动seo
  • 公司制作一个网站价格app地推接单平台
  • 哪个网站能免费做电子书封面西安做网站哪家好
  • 招聘网站数据分析怎么做济南百度推广开户
  • 有没有人与动物做的电影网站长春网站建设定制
  • 鞍山企业做网站精准网络营销推广
  • 网站图片修改如何做网络推广外包
  • 手机网站商城建设答辩微信小程序开发零基础入门
  • 黑龙江省建设协会网站百度商业账号登录
  • 云南昆明做网站网络推广网络营销和网站推广的区别
  • 做课题的网站有多少是备案的360优化大师安卓手机版下载安装
  • 广州游戏软件开发公司百度seo关键词排名推荐
  • 做算命网站深圳seo推广外包