#!/bin/bash # Real-data v9 output for all of 2024, both satellites, for comparison with the # v8 render. Bad frames are the stored production judgment (run 48, the current # rules); every judged-bad or missing band is filled by v9, which also sees the # target slot's undamaged bands. One satellite at a time so # GOES-16's video arrives first. # # Resumable: rerun this script after any stop. Finished (day, satellite) pairs are # skipped, a half-done day continues from its first missing composite, and # composites are written atomically and never rewritten. set -u -o pipefail # Paths are relative to this script's directory, whatever the caller's. cd "$(dirname "$(readlink -f "$0")")" PY="./.venv/bin/python -W ignore" OUT=../renders/real2024_v9 export SUVI_MODEL=../models/v9_best.pt LOG() { echo "[$(date '+%F %T')] $*"; } [ -s "$SUVI_MODEL" ] || { LOG "no checkpoint at $SUVI_MODEL; stopping"; exit 1; } for sat in 16 18; do LOG "rendering GOES-$sat, 2024" $PY render_real.py --start 2024-01-01 --end 2025-01-01 --satellites 16,18 \ --render $sat --filler learned --workers 2 --batch 6 --out $OUT \ || { LOG "render failed; stopping (rerun this script to resume)"; exit 1; } LOG "GOES-$sat rendered; scanning the composites for escaped defects" $PY render_qa.py $OUT/learned/goes$sat --out $OUT/qa 2>&1 | tail -15 \ || { LOG "QA failed; stopping"; exit 1; } LOG "building the GOES-$sat video" $PY make_comparison_video.py --streams $OUT --variants learned:$sat \ --labels "GOES-$sat | v9" --out ../renders/real2024_v9_g$sat.mp4 2>&1 | tail -6 \ || { LOG "video failed; stopping"; exit 1; } done LOG "real 2024 v9 run complete"