#!/usr/bin/env bash
# load-0800 was analysed before the greyscale-frame fix landed. Re-run its
# analysis (detection cache is reused, so this is minutes) once the batch ends.
set -uo pipefail
cd "$(dirname "$0")/.."
PY=/home/brad/proj/sonice-ai-sentinel-edge/.cache/roven-real-model-eval/venv/bin/python
while ps -eo args | grep -q '[r]un_batch.sh'; do sleep 30; done
echo "[fixup] batch finished, re-analysing load-0800 with greyscale fix"
./scripts/run_clip.sh load-0800
$PY scripts/build_clips_index.py --out runs/clips.json
echo "[fixup] DONE"
