huahua123313's picture
Add files using upload-large-folder tool
7c2871f verified
Raw
History Blame Contribute Delete
737 Bytes
#!/usr/bin/env bash
# Run final test on CTA using an existing checkpoint (no training).
# Usage:
# bash scripts/test_cta.sh # uses outputs/cta/checkpoints/last.ckpt
# bash scripts/test_cta.sh /path/to/other.ckpt # explicit checkpoint
set -euo pipefail
cd "$(dirname "$0")/.."
# load .env if present
[ -f .env ] && set -a && . ./.env && set +a
CKPT="${1:-outputs/cta/checkpoints/last.ckpt}"
shift || true
if [ ! -f "$CKPT" ]; then
echo "[test_cta] checkpoint not found: $CKPT"
exit 1
fi
echo "[test_cta] using checkpoint: $CKPT"
python3 src/train.py \
method=cta \
data=fairtalking \
trainer=ddp \
backbone=timesformer \
+test_only=true \
+test_ckpt="$CKPT" \
"$@"