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
OpenDAS
Megatron-LM
Commits
e2c0b4f7
Commit
e2c0b4f7
authored
Apr 17, 2025
by
wxj
Browse files
Update README.md
parent
edb026d5
Pipeline
#2654
passed with stage
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
9 deletions
+20
-9
README.md
README.md
+20
-9
No files found.
README.md
View file @
e2c0b4f7
...
...
@@ -214,15 +214,26 @@ DATA_PATH="/datasets/oscar-1GB-llama_text_document"
将hf格式转为pt格式
```
shell
python tools/checkpoint/convert.py
\
--model-type
GPT
\
--loader
llama_mistral
\
--saver
megatron
\
--target-tensor-parallel-size
1
\
--checkpoint-type
hf
\
--model-size
llama2-7Bf
\
--load-dir
/models/llama2/Llama-2-7b-hf/
\
--save-dir
./Llama-2-7b-megatron-lm-0108
\
--tokenizer-model
/models/llama2/Llama-2-7b-hf
--model-type
GPT
\
--loader
llama_mistral
\
--saver
megatron
\
--target-tensor-parallel-size
1
\
--target-pipeline-parallel-size
2
\
--checkpoint-type
hf
\
--model-size
llama2-7Bf
\
--load-dir
/data/model_weights/Llama-2-7b-hf/
\
--save-dir
./tmp_modelconvert
\
--tokenizer-model
/data/model_weights/Llama-2-7b-hf/
```
然后在训练的脚本上添加微调的参数
```
shell
FINETUNE_ARGS
=(
# --finetune
# --pretrained-checkpoint $CHECKPOINT_PATH
--load
$CHECKPOINT_PATH
--no-load-optim
--no-load-rng
)
```
# 参考
...
...
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