#!/usr/bin/env bash # Unattended serial PD-ablation campaign: reuse sweep -> conc sweep. # STRICTLY one driver at a time (the hard lesson): each inner driver brings up and # tears down its own vLLM per config via scripts/mb5_run_gpu.sh, and the two sweeps # run sequentially (reuse fully finishes + tears down before conc starts). We verify # GPUs are clear between sweeps. NO set -e here: a sub-sweep nonzero must NOT skip the # other sweep; rc is captured and reported. Detached launch writes a DONE marker. cd /home/admin/cpfs/wjh/agentic-kv-fresh export MB5_VENV="${MB5_VENV:-/home/admin/cpfs/wjh/agentic-kv-fresh/.venv_dash0}" FS=microbench/fresh_setup echo "=== CAMPAIGN START $(date) ===" echo "=== [1/2] REUSE SWEEP (fixed real prefill delta=2048, out=256, reuse 20-95%, N=8) $(date) ===" bash "$FS/run_reuse_fixed.sh"; rc_reuse=$? echo "=== reuse sweep rc=$rc_reuse $(date) ===" sleep 15 echo "--- GPU mem after reuse sweep (expect ~0 before conc) ---" nvidia-smi --query-gpu=index,memory.used --format=csv,noheader | head -8 echo "=== [2/2] CONC SWEEP (in=32768 reuse=0.984, balanced N grid 8 16 32 48 64 96 128) $(date) ===" NLIST="8 16 32 48 64 96 128" bash "$FS/run_conc.sh"; rc_conc=$? echo "=== conc sweep rc=$rc_conc $(date) ===" echo "=== CAMPAIGN DONE reuse_rc=$rc_reuse conc_rc=$rc_conc $(date) ==="