Reproduces the SUM Parts (CVPR 2025) face-labeling benchmark on a single consumer GPU, then applies it to drone-photogrammetry road survey meshes. Verified on RTX 3060 12GB / WSL2 Ubuntu 22.04 / CUDA 11.8 / torch 2.0.1: - CUDA extensions build (pointnet2_batch, pointops, chamfer_dist, emd, subsampling) - PointNet 100 epochs reaches mIoU 17.19, matching the paper's reported 15.1 - OBJ -> PLY conversion round-trips through the model and yields per-point predictions Four upstream source patches, all idempotent, originals preserved: - numpy aliases removed in 1.24 (np.long etc.) and collections ABCs moved in python 3.10 - the blind test split ships label = -1, which crashed ConfusionMatrix - mode=val referenced `epoch` before assignment Documents the traps that cost the most time, including VRAM overflow silently falling back to host RAM on WSL2 (25-100x slowdown, no OOM) and the colour scale mismatch between r/g/b float32 and red/green/blue uint8. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
36 lines
1.0 KiB
Bash
36 lines
1.0 KiB
Bash
#!/usr/bin/env bash
|
|
# SUM Parts - per-epoch wall time, to locate where a run slowed down
|
|
set -uo pipefail
|
|
|
|
RUNROOT="$HOME/sum-parts/runs"
|
|
WORKDIR="${1:-$(cat "$RUNROOT/.latest" 2>/dev/null)}"
|
|
LOG="$WORKDIR/train.log"
|
|
|
|
[ -f "$LOG" ] || { echo "no train.log at $WORKDIR"; exit 1; }
|
|
|
|
grep -E 'Epoch [0-9]+ LR' "$LOG" | awk '
|
|
{
|
|
# [08/20 20:28:44 SUMV2_Triangle]: Epoch 10 LR ...
|
|
# $1 $2 $3 $4 $5
|
|
split($2, t, ":")
|
|
sec = t[1]*3600 + t[2]*60 + t[3]
|
|
for (i = 1; i <= NF; i++) if ($i == "Epoch") { ep = $(i+1); break }
|
|
if (prev_sec != "") {
|
|
d = sec - prev_sec
|
|
if (d < 0) d += 86400 # crossed midnight
|
|
printf "epoch %3d %s +%6.1f s", ep, t[1]":"t[2]":"t[3], d
|
|
if (d > slow_thresh) printf " <-- SLOW"
|
|
printf "\n"
|
|
} else {
|
|
printf "epoch %3d %s\n", ep, t[1]":"t[2]":"t[3]
|
|
}
|
|
prev_sec = sec
|
|
}
|
|
BEGIN { slow_thresh = 300 }
|
|
'
|
|
|
|
echo
|
|
echo "--- summary ---"
|
|
grep -E 'Epoch [0-9]+ LR' "$LOG" | tail -1
|
|
echo "epochs done: $(grep -cE 'Epoch [0-9]+ LR' "$LOG")"
|