Recover governed runtime provenance for legacy YOLO models
GeoIntel release gates / Compile, test, contracts and builds (push) Failing after 20s
GeoIntel release gates / Python and npm vulnerability policy (push) Failing after 22s
GeoIntel release gates / GIS image, SBOM and container scan (push) Failing after 2m31s

This commit is contained in:
Jens
2026-08-23 23:22:02 +02:00
parent 300fbba5c9
commit be2e092b33
8 changed files with 588 additions and 0 deletions
+16
View File
@@ -771,6 +771,22 @@ selected sample slugs and excluded sample slugs. Split validation still applies
after filtering, so a manifest-backed holdout cannot be selected as training by
omitting it from `--val-samples`.
### Runtime provenance migration for surviving checkpoints
`migrate_runtime_model_provenance.py` recovers the narrow runtime provenance
contract for a legacy local YOLO checkpoint only when the active model, retained
`best.pt`, base model, training summary, arguments, results, dataset summary and
dataset YAML all match their recorded SHA-256 values. The default run is a
read-only dry-run; `--apply` writes the neighbouring
`.geointel-model.json` atomically and registers the exact model bytes as an
immutable `model` source snapshot in Postgres.
The generated receipt explicitly does not claim a missing historical commit,
container digest, human review, protected-test independence, national validity
or promotion. It downloads nothing and runs no inference. After applying, use
`yolo_preflight.py --check-model-load --json` and a separate real inference
smoke to validate the actual CUDA runtime.
After rebuilding the all-in-one image, the operator scripts are available inside
the container at `/app/scripts/...`. Before rebuilding, use the host checkout or
temporarily copy scripts into the running container for one-off data prep.