-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into add_video_llavaov
- Loading branch information
Showing
921 changed files
with
64,852 additions
and
23,149 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,4 +8,6 @@ slurm* | |
logs | ||
.vscode | ||
log_file/* | ||
outputs | ||
outputs | ||
*.log | ||
*.out |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,100 @@ | ||
system: | ||
tensor_model_parallel_size: 4 | ||
pipeline_model_parallel_size: 2 | ||
disable_bias_linear: True | ||
use_flash_attn: True | ||
sequence_parallel: True | ||
use_distributed_optimizer: True | ||
precision: | ||
bf16: True | ||
attention_softmax_in_fp32: true | ||
accumulate_allreduce_grads_in_fp32: true | ||
logging: | ||
log_interval: 1 | ||
tensorboard_log_interval: 1 | ||
wandb_project: "train-llama3-8B" | ||
wandb_exp_name: "train-test-8B" | ||
checkpoint: | ||
load: outputs_llama3/checkpoint_mc | ||
save_interval: 10 | ||
finetune: True | ||
ckpt_format: "torch" | ||
|
||
model: | ||
use_mcore_models: True | ||
transformer_impl: transformer_engine | ||
num_layers: 32 | ||
hidden_size: 4096 | ||
ffn_hidden_size: 14336 | ||
num_attention_heads: 32 | ||
seq_length: 4096 | ||
group_query_attention: True | ||
num_query_groups: 8 | ||
max_position_embeddings: 8192 | ||
norm_epsilon: 1e-5 | ||
use_rotary_position_embeddings: True | ||
no_position_embedding: True | ||
swiglu: True | ||
normalization: RMSNorm | ||
rotary_interleaved_patch: False | ||
position_embedding_type: rope | ||
rotary_base: 500000 | ||
untie_embeddings_and_output_weights: True | ||
init_method_std: 0.02 | ||
attention_dropout: 0.0 | ||
hidden_dropout: 0.0 | ||
clip_grad: 1.0 | ||
train_samples: 200000 | ||
eval_iters: 100 | ||
eval_interval: 1000 | ||
micro_batch_size: 1 | ||
global_batch_size: 16 | ||
|
||
hetero: | ||
enable_hetero: True | ||
hetero_use_cpu_communication: True | ||
# mesh format [tp1,cp1,ep1,dp1,pp1,(tp2,cp2...)] | ||
|
||
# 2 mesh, diff tp dp pp | ||
hetero_pipeline_layer_split: [18, 14] | ||
hetero_process_meshes: [2, 1, 1, 4, 1, 4, 1, 1, 2, 1] | ||
hetero_device_types: ["A800", "A100"] | ||
|
||
standalone_embedding_stage: False | ||
hetero_current_device_type: "A800" | ||
|
||
# recompute: | ||
# recompute_granularity: "full" | ||
# recompute_method: "uniform" | ||
# recompute_num_layers: 1 | ||
|
||
# ## pp 2 stages and num_micro_batches 4 | ||
# recompute_granularity_per_stage_micro_batch: | ||
# - [1, 3, 0, 1, 0] | ||
# - [1, 3, 1, 1, 1] | ||
# recompute_method_per_stage_micro_batch: | ||
# - [1, 3, 0, 1, 0] | ||
# - [1, 3, 0, 1, 0] | ||
# recompute_num_layers_per_stage_micro_batch: | ||
# - [1, 3, 2, 1, 2] | ||
# - [1, 3, 1, 1, 1] | ||
|
||
|
||
optimizer: | ||
weight_decay: 1e-2 | ||
adam_beta1: 0.9 | ||
adam_beta2: 0.95 | ||
lr_scheduler: | ||
lr: 1.0e-5 | ||
min_lr: 1.0e-6 | ||
lr_warmup_fraction: .1 | ||
lr_decay_style: cosine | ||
|
||
data: | ||
data_path: examples/llama/pile-openwebtext_text_document/pile-openwebtext_text_document | ||
split: 1 | ||
tokenizer: | ||
tokenizer_type: Llama3TokenizerFS | ||
tokenizer_path: meta-llama3/Meta-Llama-3-8B | ||
vocab_size: 128256 | ||
make_vocab_size_divisible_by: 64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
defaults: | ||
- _self_ | ||
- train: train_qwen_2.5_1.5b | ||
# - train: train_mixtral_1.8b | ||
|
||
experiment: | ||
exp_name: train_qwen_2.5_1.5b | ||
exp_dir: ./outputs # outputs ## log、checkpoints output path | ||
task: | ||
type: train | ||
backend: megatron | ||
entrypoint: ./flagscale/train/train_aquila.py | ||
runner: | ||
backend: torchrun | ||
nnodes: 2 | ||
nproc_per_node: 8 | ||
hostfile: torchrun # Please replace with your actual hostfile path | ||
envs: | ||
CUDA_VISIBLE_DEVICES: "0,1,2,3,4,5,6,7" | ||
CUDA_DEVICE_MAX_CONNECTIONS: 1 | ||
NCCL_SOCKET_IFNAME: eth0 | ||
NCCL_IB_DISABLE: 0 | ||
NCCL_IB_CUDA_SUPPORT: 1 | ||
NCCL_IB_GID_INDEX: 0 | ||
NCCL_DEBUG: INFO | ||
OMP_NUM_THREADS: 4 | ||
GLOO_SOCKET_IFNAME: eth0 | ||
NCCL_IB_HCA: mlx5_2,mlx5_5 | ||
|
||
action: run |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
defaults: | ||
- _self_ | ||
- serve: serve_qwen2.5_72b | ||
|
||
experiment: | ||
exp_name: qwen2.5_72b | ||
exp_dir: outputs/${experiment.exp_name} | ||
task: | ||
type: serve | ||
backend: vllm | ||
entrypoint: null | ||
runner: | ||
hostfile: null | ||
envs: | ||
CUDA_VISIBLE_DEVICES: 0,1,2,3 | ||
CUDA_DEVICE_MAX_CONNECTIONS: 1 | ||
|
||
action: run | ||
|
||
hydra: | ||
run: | ||
dir: ${experiment.exp_dir}/hydra |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
defaults: | ||
- _self_ | ||
- serve: serve_qwen2.5_7b | ||
|
||
experiment: | ||
exp_name: qwen2.5_7b | ||
exp_dir: outputs/${experiment.exp_name} | ||
task: | ||
type: serve | ||
backend: vllm | ||
entrypoint: null | ||
runner: | ||
hostfile: null | ||
envs: | ||
CUDA_VISIBLE_DEVICES: 0 | ||
CUDA_DEVICE_MAX_CONNECTIONS: 1 | ||
|
||
action: run | ||
|
||
hydra: | ||
run: | ||
dir: ${experiment.exp_dir}/hydra |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
defaults: | ||
- _self_ | ||
- serve: serve_qwen2.5_7b | ||
|
||
experiment: | ||
exp_name: qwen2.5_7b | ||
exp_dir: outputs/${experiment.exp_name} | ||
task: | ||
type: serve | ||
backend: vllm | ||
entrypoint: null | ||
runner: | ||
hostfile: /path/to/hostfile # type: {remote ip} slots={gpu num} type={gpu type} (like: x.x.x.x slots=8 type=A100) | ||
ssh_port: 22 # replace with your ssh port | ||
envs: | ||
CUDA_VISIBLE_DEVICES: 0 | ||
CUDA_DEVICE_MAX_CONNECTIONS: 1 | ||
cmds: | ||
before_start: source /root/miniconda3/bin/activate flagscale | ||
|
||
action: run | ||
|
||
hydra: | ||
run: | ||
dir: ${experiment.exp_dir}/hydra |
Oops, something went wrong.