Download scripts/train_ablations.sh from -1/Brigalow-QLD-v1: direct link, hf CLI and curl.
- Browser
- Download file 1.92 kB
-
https://huggingface.co/-1/Brigalow-QLD-v1/resolve/main/scripts/train_ablations.sh
- Command line
-
hf download hf://-1/Brigalow-QLD-v1/scripts/train_ablations.sh
-
curl -L -o train_ablations.sh https://huggingface.co/-1/Brigalow-QLD-v1/resolve/main/scripts/train_ablations.sh
1.92 kB
| # Stage 1 controlled ablations on RTX 5090 (180k crops of 256 x 256 px each, ~35-45 min) | |
| set -euo pipefail | |
| DATA=/data | |
| WIN=/data/windows.parquet | |
| OUT=/data/runs_ablations | |
| mkdir -p "$OUT" | |
| export PYTHONPATH=/root/clearing-qld/src | |
| run_exp() { | |
| local NAME=$1; shift | |
| if grep -q '"event": "done"' "$OUT/$NAME/train_log.jsonl" 2>/dev/null; then | |
| echo "[SKIP] $NAME already done" | |
| return | |
| fi | |
| echo "=== START $NAME $(date -u +%H:%M:%S) ===" | |
| mkdir -p "$OUT/$NAME" | |
| python3 -m brigalow.train --data "$DATA" --windows "$WIN" --out "$OUT/$NAME" \ | |
| --crop 256 --stride 128 --bs 16 --grad-accum 2 --samples 180000 --eval-every 90000 \ | |
| --workers 8 --ema 0.999 --seed 0 --resume "$@" > "$OUT/$NAME/stdout.log" 2>&1 | |
| echo "=== DONE $NAME $(date -u +%H:%M:%S) ===" | |
| tail -n 2 "$OUT/$NAME/train_log.jsonl" | |
| } | |
| # A1: Core frontier recipe (ConvNeXt-Small + aligned_tversky + hard_neg + lovasz + aux + online date/drought aug) | |
| run_exp A1_convnext_s --arch convnext_small --lr 3e-4 --bb-lr-mult 0.25 --loss-mode aligned_tversky --tversky-alpha 0.65 --tversky-beta 0.35 --hard-neg-w 2.0 --lovasz-w 0.15 --aux-w 1.0 | |
| # A2: Loss ablation (exact same as A1 except standard bce_dice loss) | |
| run_exp A2_convnext_bcedice --arch convnext_small --lr 3e-4 --bb-lr-mult 0.25 --loss-mode bce_dice --aux-w 1.0 | |
| # A3: Architecture diversity 2 (CAFormer-S36 Conv+Transformer MetaFormer) | |
| run_exp A3_caformer_s36 --arch caformer_s36 --lr 3e-4 --bb-lr-mult 0.25 --loss-mode aligned_tversky --tversky-alpha 0.65 --tversky-beta 0.35 --hard-neg-w 2.0 --lovasz-w 0.15 --aux-w 1.0 | |
| # A4: Architecture diversity 3 (SatlasPretrain Sentinel-2 9-band EO Foundation Model Siamese Swin-B) | |
| run_exp A4_satlas_swin_b --arch satlas_swin_b --lr 2.5e-4 --bb-lr-mult 0.15 --loss-mode aligned_tversky --tversky-alpha 0.65 --tversky-beta 0.35 --hard-neg-w 2.0 --lovasz-w 0.15 --aux-w 1.0 | |
| echo "ALL_STAGE1_ABLATIONS_DONE $(date -u +%H:%M:%S)" | |