TRACE-VLA code snapshot 2026-11-22 11:47 +07: 456 canonical files + SHA256 manifest + sync report
b4396f0 verified Download code/sera_v4/tools/chain_long.sh from phammminhhieu/trace-vla-code: direct link, hf CLI and curl.
- Browser
- Download file 2.08 kB
-
https://huggingface.co/phammminhhieu/trace-vla-code/resolve/main/code/sera_v4/tools/chain_long.sh
- Command line
-
hf download hf://phammminhhieu/trace-vla-code/code/sera_v4/tools/chain_long.sh
-
curl -L -o chain_long.sh https://huggingface.co/phammminhhieu/trace-vla-code/resolve/main/code/sera_v4/tools/chain_long.sh
2.08 kB
| # Post-training chain for the LONG RUN (campaign 24h): after the | |
| # 60k training completes — routing + token measurements at | |
| # 20k/40k/60k, RSA at the same milestones, then the 70-ep probe | |
| # and composition Z at 60k. Usage: chain_long.sh <g|q2> | |
| set -u | |
| RECIPE="${1:?usage: chain_long.sh <g|q2>}" | |
| EXP=$HOME/sera_v4_experiments | |
| RUN=sera-v4-long-$RECIPE | |
| LOG=$EXP/chain_long_$RECIPE.log | |
| exec >> "$LOG" 2>&1 | |
| echo "CHAIN_LONG_$RECIPE START $(date -Is)" | |
| while true; do | |
| if [ -d "$EXP/$RUN/checkpoints/060000" ] \ | |
| && ! pgrep -f "output_dir=$EXP/$RUN" > /dev/null; then | |
| break | |
| fi | |
| sleep 30 | |
| done | |
| echo "LONG TRAINING DONE $(date -Is)" | |
| cd "$HOME/lerobot" || exit 1 | |
| export MUJOCO_GL=egl PYTHONUNBUFFERED=1 | |
| for s in 020000 040000 060000; do | |
| n=$((10#$s)) | |
| .venv/bin/python "$EXP/tools/measure_routing.py" \ | |
| --ckpt "$EXP/$RUN/checkpoints/$s/pretrained_model" \ | |
| --out "$EXP/measurement/results/long-$RECIPE-$n.json" --batch 32 | |
| echo "ROUTING_$n DONE $(date -Is)" | |
| .venv/bin/python "$EXP/tools/measure_tokens.py" \ | |
| --ckpt "$EXP/$RUN/checkpoints/$s/pretrained_model" \ | |
| --out "$EXP/measurement/results/long-$RECIPE-tokens-$n.json" --batch 32 | |
| echo "TOKENS_$n DONE $(date -Is)" | |
| done | |
| for n in 20000 40000 60000; do | |
| if [ -f "$EXP/measurement/results/long-$RECIPE-tokens-$n.json" ]; then | |
| .venv/bin/python "$EXP/tools/measure_rsa.py" \ | |
| --tokens "$EXP/measurement/results/long-$RECIPE-tokens-$n.json" \ | |
| --out "$EXP/measurement/results/long-$RECIPE-rsa-$n.json" | |
| echo "RSA_$n DONE $(date -Is)" | |
| fi | |
| done | |
| .venv/bin/python "$EXP/tools/eval_v4.py" \ | |
| --ckpt "$EXP/$RUN/checkpoints/060000/pretrained_model" \ | |
| --arm "long-$RECIPE" --out "$EXP/quest_probe/results/long-$RECIPE.jsonl" --seed 0 | |
| echo "PROBE DONE $(date -Is)" | |
| .venv/bin/python "$EXP/tools/rollout_skill_v4.py" \ | |
| --ckpt "$EXP/$RUN/checkpoints/060000/pretrained_model" \ | |
| --model v3 --tasks 1,3,4,6,7,8 --eps 0,1,2,3,4,5,6,7,8,9 \ | |
| --out "$EXP/quest_probe/results/long-$RECIPE-comp-z.jsonl" --seed 0 | |
| echo "COMP_Z DONE $(date -Is)" | |
| echo "CHAIN_LONG_${RECIPE}_END $(date -Is)" | |