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

威宁住房和城乡建设局网站/百度推广服务

威宁住房和城乡建设局网站,百度推广服务,黑龙江网站建设企业,b2c 网站导航栏设计运行Vicuna-7B需要RAM>30GB或者14GB的显存 运行Vicuna-13B需要RAM>60GB或者28GB的显存 如果没有上面的硬件配置请绕行了,我笔记本有64G内存,两个都跑跑看,使用python3.9,当时转换13b时一直崩溃后来发现是没有设定虚拟内存&…

运行Vicuna-7B需要RAM>30GB或者14GB的显存
运行Vicuna-13B需要RAM>60GB或者28GB的显存

如果没有上面的硬件配置请绕行了,我笔记本有64G内存,两个都跑跑看,使用python3.9,当时转换13b时一直崩溃后来发现是没有设定虚拟内存,后来加上了9个G,才可以跑起来

 

下载llama原始模型 

nyanko7/LLaMA-7B at mainWe’re on a journey to advance and democratize artificial intelligence through open source and open science.https://huggingface.co/nyanko7/LLaMA-7B/tree/mainhuggyllama/llama-13b at mainWe’re on a journey to advance and democratize artificial intelligence through open source and open science.https://huggingface.co/huggyllama/llama-13b/tree/main也可以用迅雷下载下面的链接,注只要7b,13b就可以了

磁力链接:magnet:?xt=urn:btih:b8287ebfa04f879b048d4d4404108cf3e8014352&dn=LLaMA

下载的文件如下:

下载vicuna-7b-delta-v1.1 和vicuna-13b-delta-v1.1 

https://huggingface.co/lmsys/vicuna-7b-delta-v1.1/tree/mainWe’re on a journey to advance and democratize artificial intelligence through open source and open science.https://huggingface.co/lmsys/vicuna-7b-delta-v1.1/tree/mainlmsys/vicuna-13b-delta-v1.1 at mainWe’re on a journey to advance and democratize artificial intelligence through open source and open science.https://huggingface.co/lmsys/vicuna-13b-delta-v1.1/tree/main 

 安装相关软件

pip install fschat
pip install protobuf==3.20.0
git clone https://github.com/huggingface/transformers.git
cd transformers
python setup.py install

转换llaMA模型

7b

python transformers/src/transformers/models/llama/convert_llama_weights_to_hf.py  --input_dir LLaMA/  --model_size 7B  --output_dir ./output/llama-7b

13b

python transformers/src/transformers/models/llama/convert_llama_weights_to_hf.py  --input_dir LLaMA/  --model_size 13B  --output_dir ./output/llama-13b

 

 合并生成Vicuna模型,13b的64g内存罩不住,得要设定虚拟内存16G-64G左右就够了

python -m fastchat.model.apply_delta --base ./output/llama-7b --target ./vicuna-7b --delta ./vicuna-7b-delta-v1.1python -m fastchat.model.apply_delta --base ./output/llama-13b --target ./vicuna-13b --delta ./vicuna-13b-delta-v1.1

 参数介绍:

base转换llaMA模型后的路径
target合并生成后的保存路径
delta下载的vicuna-7b-delta-v1.1路径

 

 

 

 

运行模型

python -m fastchat.serve.cli --model-path ./vicuna-7b --device cpupython -m fastchat.serve.cli --model-path ./vicuna-13b --device cpu

7b的占用约26G内存,在64G内存上,i9 12900h运行、响应速度还可以,

 

13b的占用大约50G内存,在64G内存上,i9 12900h运行缓慢

 总结:尽管小点的模型可以运行了,如果想自己进行微调还是要使用gpu ,推荐A100显卡,或者A800. 先期不投硬件先租用可以用矩池云 - 专注于人工智能领域的云服务商矩池云是一家专注于人工智能领域的GPU云服务商。提供稳定的人工智能云服务器、人工智能教学实训环境、高速网盘等服务,支持公有云、私有云、专有云、硬件直采等专业级人工智能解决方案。https://matpool.com/

 

模型推理(Web UI方式)
如果想要以web UI方式提供服务,则需要配置3个部分。

web servers,用户的交互界面
model workers,托管模型
controller,用以协调web server和model worker
启动控制器

python3 -m fastchat.serve.controller --host 0.0.0.0

启动model worker

python -m fastchat.serve.model_worker  --model-path ./vicuna-7b --model-name vicuna-7b --host 0.0.0.0 --device cpu

当进程完成模型的加载后,会看到「Uvicorn running on …」 

python -m fastchat.serve.gradio_web_server --port 8809

http://www.jmfq.cn/news/5229775.html

相关文章:

  • 网站制作知识/怎样开自己的网站
  • 新手什么网站做外贸/常见的推广平台有哪些
  • 前程无忧招聘网站标记怎么做/企业培训网
  • 哪个网站可以做抑郁症测试题/论文收录网站排名
  • 网站开发出来有后台么/谷歌app下载
  • wordpress 微信图标/网站内容优化关键词布局
  • 国学大师网站谁做的/北京网络推广公司wyhseo
  • 湖南高端网站制作公司/360手机优化大师下载
  • 建站公司转型做什么业务/宜昌今日头条新闻
  • 做网站有哪些费用/志鸿优化网
  • org已经备案的网站/网络营销案例分析题
  • 最专业的网站建设/google移动服务应用优化
  • 长安网站建设制作/媒体营销
  • 男人做爽的免费网站/抖音seo培训
  • 网站商城建设/合肥优化排名推广
  • 做网站开发的公司哪家好/百度移动版
  • 百度网站公司信息推广怎么做/软件开发培训班
  • 怎么把做的网站传/seo权威入门教程
  • 傻瓜做网站软件/搜索引擎营销ppt
  • 公司的网站如何进行修改布局/关于营销的最新的新闻
  • 西安知名网站推广/朝阳区seo技术
  • 云空间搭建网站/seo线下培训班
  • 成都市住房和城乡建设厅官网/南京网站设计优化公司
  • 我做网站/seo软件系统
  • 找人做网站推广/常州网站优化
  • 怎么做网站收录/个人网站免费制作平台
  • 网站没有地图怎么做/百度公司图片
  • 企业问题及解决方案/优化大师win10下载
  • 北京网站建设哪个好/统计工具
  • 网站建设与管理 吴代文/重庆网站排名优化教程