Download code/scripts/train_plain.sh from teawhite/ActionRoPE: direct link, hf CLI and curl.
- Browser
- Download file 1.17 kB
-
https://huggingface.co/teawhite/ActionRoPE/resolve/main/code/scripts/train_plain.sh
- Command line
-
hf download hf://teawhite/ActionRoPE/code/scripts/train_plain.sh
-
curl -L -o train_plain.sh https://huggingface.co/teawhite/ActionRoPE/resolve/main/code/scripts/train_plain.sh
1.17 kB
| # plain 对照臂(Wan + Prompt,动作走文本)正式训练:与 train_arope.sh 同样的步数 / 保存 / 验证节奏。 | |
| # 用法:bash scripts/train_plain.sh [额外参数...] | |
| set -euo pipefail | |
| ROOT=/opt/dlami/nvme/zhiyangdeng/ActionRoPE | |
| export DIFFSYNTH_SKIP_DOWNLOAD=True | |
| export PYTHONPATH="$ROOT" | |
| export CUDA_VISIBLE_DEVICES="${CUDA_VISIBLE_DEVICES:-0,1,2,3,4,5,6,7}" | |
| GA="${GA:-2}" # 梯度累积(全局 batch = 8 卡 × GA);yaml 随之选 accelerate_zero2_ga${GA}.yaml(GA=1 用 accelerate_zero2.yaml) | |
| CFG=$([ "$GA" = 1 ] && echo accelerate_zero2.yaml || echo "accelerate_zero2_ga${GA}.yaml") | |
| RUN="${RUN:-plain_40k}" | |
| mkdir -p "$ROOT/outputs/$RUN" | |
| "$ROOT/.venv/bin/accelerate" launch --config_file "$ROOT/configs/$CFG" \ | |
| "$ROOT/actionrope/train.py" \ | |
| --arm plain --scene_dropout 0.1 \ | |
| --lr 1e-5 --weight_decay 0.01 --warmup_steps 500 \ | |
| --max_steps 40000 --save_every 1000 --save_state --val_every 500 --val_n 16 --val_timesteps 200,500,800 \ | |
| --min_rt_ratio 0.8 --val_min_rt_ratio 0.9 \ | |
| --grad_accum "$GA" --num_workers 2 --seed 0 \ | |
| --output "$ROOT/outputs/$RUN" "$@" 2>&1 | tee -a "$ROOT/outputs/$RUN/train.log" | |