AsianPlayer/TriDrive / code /eval /run_joint_evals_final.sh
AsianPlayer's picture
download
raw
3.05 kB
#!/usr/bin/env bash
# cwm3/eval/run_joint_evals_final.sh — E1 pairs of the FINAL joint runs (2026-09-11, roadmap §四 E1 / E2; layout guards on; TRAIN_DONE + PRED_DONE required).
# Per seed k (identical rows, paired_compare_joint; every tag idempotent on results/paired_compare.csv):
# finalc_s<k>_{allminus,all}_vs_indep, finalc_s<k>_allminus_vs_all — driver populations from the v2 CAUSAL kin targets (--kin-targets causal_routes --kin-version v2):
# the targets the U base was trained on; own endpoints incl. the driver cells, cross-leg C1 / C2, hazard NLL, emissions
# finalcm_s<k>_{allminus,all}_vs_indep — the same with the 64 v2 driver-box-suspect routes censored from every population (--mask-routes)
# final_s<k>_{allminus,all}_vs_indep — cwm2 route-median kin targets (continuity with stage_I1_v2b; driver cells descriptive: causal inputs, old targets)
# finalc_s<k>_{indep,allminus,all}_vs_k0, finalcm_s<k>_..._vs_k0 — driver cells vs the k0 heuristic / persistence (claim B1 on the joint model), all rows and masked
# bash eval/run_joint_evals_final.sh "0 1 2" [render=1]
set -u
cd "$(dirname "$0")/.."
PY=python
export OMP_NUM_THREADS=4 MKL_NUM_THREADS=4
MASK=results/targets_kin_causal_routes_v2/driver_box_suspect_routes.json
have_tag() { grep -q ",$1,$2,test," results/paired_compare.csv 2>/dev/null; }
done_run() { [[ -f results/runs/$1/PRED_DONE && -f results/runs/$1/TRAIN_DONE ]]; }
pc() { # tag a b [extra args] (b = none with --b-k0)
local tag="$1" a="$2" b="$3"; shift 3
done_run "$a" || { echo "skip $tag ($a not finished)"; return; }
[[ "$b" == none ]] || done_run "$b" || { echo "skip $tag ($b not finished)"; return; }
for reg in manual engaged; do
have_tag "$tag" "$reg" && continue
echo "== $tag $reg"
$PY eval/paired_compare_joint.py --regime "$reg" --a "results/runs/$a" --b "results/runs/$b" --tag "$tag" "$@" 2>&1 | grep -E "appended|Error|Traceback|File \"|LAYOUT GUARD"
done
}
C="--kin-targets causal_routes --kin-version v2"
for s in ${1:-0 1 2}; do
I=I1_indep_s${s}_final; AM=I1_all_minus_road2drv_s${s}_final; AL=I1_all_s${s}_final
pc "finalc_s${s}_allminus_vs_indep" $AM $I $C
pc "finalc_s${s}_all_vs_indep" $AL $I $C
pc "finalc_s${s}_allminus_vs_all" $AM $AL $C
pc "finalcm_s${s}_allminus_vs_indep" $AM $I $C --mask-routes $MASK
pc "finalcm_s${s}_all_vs_indep" $AL $I $C --mask-routes $MASK
pc "final_s${s}_allminus_vs_indep" $AM $I
pc "final_s${s}_all_vs_indep" $AL $I
for v in indep allminus all; do
d=$I; [[ $v == allminus ]] && d=$AM; [[ $v == all ]] && d=$AL
pc "finalc_s${s}_${v}_vs_k0" $d none $C --b-k0
pc "finalcm_s${s}_${v}_vs_k0" $d none $C --b-k0 --mask-routes $MASK
done
done
if [[ "${2:-1}" == "1" ]]; then S=${1:-0 1 2}
$PY eval/report_final.py --seeds ${S// /,} --out results/tables/stage_final.md 2>&1 | grep -E "written|verdict|main model"
fi
echo FINAL_EVALS_DONE

Xet Storage Details

Size:
3.05 kB
·
Xet hash:
01ee6d4c259afa4bafddf6f80ebf6ea67e16582d67c9c8963df889bca8c0df13

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.