-
Notifications
You must be signed in to change notification settings - Fork 22
Expand file tree
/
Copy pathtrain.sh
More file actions
44 lines (36 loc) · 1.17 KB
/
train.sh
File metadata and controls
44 lines (36 loc) · 1.17 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
#!/usr/bin/env bash
set -euo pipefail
# ===== Global Configuration =====
PROJECT="axell-wppr/gentle_humanoid"
NPROC=4
SCRIPT="scripts/train.py"
run_pipeline() {
local TASK="$1" TAG="$2" SUFFIX="$3"
local ID_TRAIN="${TAG}_train_${SUFFIX}"
local ID_ADAPT="${TAG}_adapt_${SUFFIX}"
local ID_FINETUNE="${TAG}_finetune_${SUFFIX}"
# ---------- TRAIN ----------
cmd=(uv run torchrun --nproc_per_node="$NPROC" "$SCRIPT"
task="$TASK" +exp=train
wandb.id="$ID_TRAIN"
)
echo ">>> ${cmd[*]}"; "${cmd[@]}"
# ---------- ADAPT ----------
cmd=(uv run torchrun --nproc_per_node="$NPROC" "$SCRIPT"
task="$TASK" +exp=adapt
checkpoint_path="run:${PROJECT}/${ID_TRAIN}"
wandb.id="$ID_ADAPT"
)
echo ">>> ${cmd[*]}"; "${cmd[@]}"
# ---------- FINETUNE ----------
cmd=(uv run torchrun --nproc_per_node="$NPROC" "$SCRIPT"
task="$TASK" +exp=finetune
checkpoint_path="run:${PROJECT}/${ID_ADAPT}"
wandb.id="$ID_FINETUNE"
)
echo ">>> ${cmd[*]}"; "${cmd[@]}"
}
run_pipeline "G1/G1_tracking" "track" "0112.3"
# run_pipeline "G1/G1_gentle" "gentle" "1215"
# run_pipeline "G1/G1_no_force" "noforce" "1215"
# run_pipeline "G1/G1_extreme_force" "extremeforce" "1215"