Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ModelZoo
llama3_pytorch
Commits
15d1457a
Commit
15d1457a
authored
May 24, 2024
by
Rayyyyy
Browse files
update lm-evaluation-harness llama-recipes in README
parent
fd1124b0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
13 deletions
+3
-13
README.md
README.md
+3
-13
No files found.
README.md
View file @
15d1457a
...
@@ -145,28 +145,18 @@ bash chat.sh
...
@@ -145,28 +145,18 @@ bash chat.sh
1.
安装
`llama-recipes`
、
`lm-eval`
库
1.
安装
`llama-recipes`
、
`lm-eval`
库
```
bash
```
bash
# llama-recipes 下载
# llama-recipes 下载
git clone https://github.com/meta-llama/llama-recipes.git
git clone http://developer.hpccube.com/codes/chenych/llama-recipes.git
cd
./llama-recipes/recipes/evaluation/
mv
exact_match.py ~/.cache/huggingface/evaluate/downloads/
# 修改eval.py第15行代码,将from lm_eval.utils import make_table 改为
from lm_eval.evaluator import make_table
# 修改eval.py第121行代码,num_fewshot参数的默认值改为0
default
=
0
# 修改eval.py第215行代码,use_cache=args.use_cache 修改为
no_cache
=
args.use_cache
# 返回根目录
cd
~
# lm-eval 下载
# lm-eval 下载
git clone http://developer.hpccube.com/codes/chenych/lm-evaluation-harness.git
git clone http://developer.hpccube.com/codes/chenych/lm-evaluation-harness.git
cd
./lm-evaluation-harness/
cd
./lm-evaluation-harness/
pip
install
-e
.
pip
install
-e
.
cd
../
```
```
2.
修改待测模型
**pretrained**
参数地址,例如
`/home/Meta-Llama-3-8B-Instruct`
,特别地,当前仅支持
`hellaswag`
数据集进行测试验证。执行以下命令:
2.
修改待测模型
**pretrained**
参数地址,例如
`/home/Meta-Llama-3-8B-Instruct`
,特别地,当前仅支持
`hellaswag`
数据集进行测试验证。执行以下命令:
```
bash
```
bash
cd
/path_of/llama-recipes/recipes/evaluation
cd
/path_of/llama-recipes/recipes/evaluation
export
HF_ENDPOINT
=
https://hf-mirror.com
python eval.py
--model
hf
--model_args
pretrained
=
/home/llama3/Meta-Llama-3-8B-Instruct,dtype
=
"float"
--tasks
hellaswag
--device
cuda
--batch_size
8
python eval.py
--model
hf
--model_args
pretrained
=
/home/llama3/Meta-Llama-3-8B-Instruct,dtype
=
"float"
--tasks
hellaswag
--device
cuda
--batch_size
8
```
```
<div
align=
center
>
<div
align=
center
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment