Downloads · 30 days
14
6% of all-time downloads
chenshake/Llama-2-7b-hf
Llama-2-7b-hf is a text generation model from chenshake. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
使用官方提供的Llama-2-7b-chat,通过colab,进行HF格式转换。目的是为了自己学习使用。
Downloads · 30 days
14
6% of all-time downloads
All-time downloads
221
Public
Parameters
6.7B
13.5 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors13.5 GB · 100%
From the Hugging Face model README
使用官方提供的Llama-2-7b-chat,通过colab,进行HF格式转换。目的是为了自己学习使用。
只需要修改Llama-2 的不同版本,就可以进行格式转换,并且上传到huggingface上。对比官方的转换结果,会有所不同,官方的HF版本提供2种格式,pickle和safetensors 格式。pickle有安全隐患,所以就只转换成safetensors 格式
notebook分享:
大家使用和测试的时候,需要更换你的hugingface的token。如果上传大模型,需要token有写入权限。
无需GPU,但是需要High memery。
官方提供的转换脚本,转换保存的文件格式是pickle格式, 这种格式不安全,需要修改脚本,直接转换成safetensors 格式。上面colab,已经进行了修改。