-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMetaMath-13b.sh
31 lines (29 loc) · 905 Bytes
/
MetaMath-13b.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
export HF_ENDPOINT=https://hf-mirror.com
OUTPUT_DIR=Path/to/save/models
deepspeed --include localhost:0,1,2,3,4,5,6,7 --master_port=9903 train_bash.py \
--deepspeed ./ds_config.json \
--stage sft \
--do_train \
--cutoff_len 1024 \
--model_name_or_path /Path/to/MetaMath-13B-V1.0 \
--dataset mgsm_trans_question_answer2 \
--template default \
--finetuning_type full \
--special_train_layers 0 1 2 3 4 5\
--only_mlp \
--output_dir $OUTPUT_DIR \
--overwrite_cache \
--gradient_checkpointing 1 \
--per_device_train_batch_size 32 \
--gradient_accumulation_steps 2 \
--preprocessing_num_workers 8 \
--lr_scheduler_type cosine \
--logging_steps 10 \
--save_steps 10 \
--learning_rate 2e-5 \
--save_only_model \
--save_total_limit 20 \
--num_train_epochs 4.0 \
--plot_loss \
--overwrite_output_dir \
--bf16