#!/usr/bin/env bash set -euo pipefail ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" cd "$ROOT_DIR" DEBUG_ROOT="${DOVLA_DEBUG_ROOT:-outputs/phase5_train_debug}" DATASET_DIR="$DEBUG_ROOT/cil" CHECKPOINT="$DEBUG_ROOT/run/best.pt" OUT_PATH="${DOVLA_EVAL_OUT:-outputs/phase5_eval/causalstress.json}" if [[ ! -f "$CHECKPOINT" || ! -f "$DATASET_DIR/manifest.json" ]]; then DOVLA_DEBUG_ROOT="$DEBUG_ROOT" bash scripts/run_train_debug.sh fi python scripts/eval_causalstress.py \ --checkpoint "$CHECKPOINT" \ --backend toy \ --out "$OUT_PATH" \ --num-tasks "${DOVLA_EVAL_NUM_TASKS:-6}" \ --k "${DOVLA_EVAL_K:-4}" \ --seed 0 \ --device "${DOVLA_DEVICE:-auto}" echo "evaluation output: $OUT_PATH"