AviadCoh commited on
Commit
aa57ac0
·
verified ·
1 Parent(s): 8db8bae

Publish TIFXYZ UUID producer audit

Browse files
uuid-producer-audit/README.md ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # TIFXYZ UUID producer audit
2
+
3
+ TIFXYZ Doctor found that most registered normalized roots reuse the literal
4
+ UUID `output_tifxyz`. This audit distinguishes three questions:
5
+
6
+ 1. **Corpus fact:** how many current registered artifacts reuse each UUID?
7
+ 2. **Producer fingerprint:** which public Villa writer has defaults matching
8
+ the emitted metadata?
9
+ 3. **Safe remediation:** can the writer accept an explicit identity without
10
+ changing its backward-compatible directory-name default?
11
+
12
+ The corpus result alone does not prove which private production command was
13
+ run. The source fingerprint is reported as an inference and kept separate from
14
+ the directly observed metadata.
15
+
16
+ ## Frozen result (2026-08-02)
17
+
18
+ - 450 registered TIFXYZ roots were fetched from the current public registry.
19
+ - They contain 174 distinct metadata UUID values.
20
+ - 277/450 roots use the literal UUID `output_tifxyz`.
21
+ - The reuse is systematic in normalized artifacts: 262/262 normalized roots
22
+ use `output_tifxyz`, versus 15/188 original roots.
23
+ - All 262 normalized roots also use scale `[0.05, 0.05]` and the same five-key
24
+ metadata shape (`bbox`, `format`, `scale`, `type`, `uuid`).
25
+ - Among 140 segments with both variants, all 140 normalized roots use
26
+ `output_tifxyz`; 127 of their original counterparts have a source-specific
27
+ identity.
28
+
29
+ Every downloaded `meta.json` is represented in `uuid-audit-2026-08-02.json`
30
+ with its public URL and SHA-256. These are collection-identity observations,
31
+ not a claim that geometry or text content is duplicated.
32
+
33
+ ## Producer inference and remediation
34
+
35
+ The normalized fingerprint is consistent with public
36
+ `vc_obj2tifxyz_legacy` defaults: step size 20 produces scale 0.05, while the
37
+ writer derives `uuid` from the output-directory basename. A production job
38
+ that always writes to a staging directory named `output_tifxyz` would therefore
39
+ create exactly this metadata. The public corpus does not expose its private
40
+ command line, so this remains an inference.
41
+
42
+ The isolated Villa patch in `../villa` adds `--uuid=<id>` to both current and
43
+ legacy OBJ-to-TIFXYZ converters. An explicit value wins; omitting the option
44
+ retains the historical output-directory behavior. The shared resolver has four
45
+ standalone C++ regression tests covering override, compatibility, fallback,
46
+ and empty-input rejection; all four pass under `clang++ -std=c++20 -Werror`.
47
+
48
+ A read-only GitHub issue/PR search on 2026-08-02 found no existing Villa item
49
+ matching `uuid`, `tifxyz`, or `output_tifxyz` together.
50
+
51
+ ```bash
52
+ python audit_uuid_metadata.py \
53
+ --manifest ../boundary-corpus-study/manifest-2026-08-02.json \
54
+ --output uuid-audit-2026-08-02.json
55
+ ```
uuid-producer-audit/audit_uuid_metadata.py ADDED
@@ -0,0 +1,116 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/env python3
2
+ """Fetch current registered TIFXYZ metadata and quantify UUID reuse."""
3
+
4
+ from __future__ import annotations
5
+
6
+ import argparse
7
+ import concurrent.futures
8
+ import hashlib
9
+ import json
10
+ from collections import Counter, defaultdict
11
+ from datetime import datetime, timezone
12
+ from pathlib import Path
13
+
14
+ import requests
15
+
16
+
17
+ HTTPS_ROOT = "https://vesuvius-challenge-open-data.s3.amazonaws.com/"
18
+
19
+
20
+ def fetch(root: dict) -> dict:
21
+ url = HTTPS_ROOT + root["prefix"] + "meta.json"
22
+ response = requests.get(url, timeout=60)
23
+ response.raise_for_status()
24
+ metadata = response.json()
25
+ return {
26
+ "sample": root["sample"],
27
+ "segment": root["segment"],
28
+ "artifact": root["artifact"],
29
+ "prefix": root["prefix"],
30
+ "url": url,
31
+ "sha256": hashlib.sha256(response.content).hexdigest(),
32
+ "metadata": metadata,
33
+ }
34
+
35
+
36
+ def run(manifest_path: Path, output: Path, workers: int) -> None:
37
+ manifest = json.loads(manifest_path.read_text(encoding="utf-8"))
38
+ with concurrent.futures.ThreadPoolExecutor(max_workers=workers) as pool:
39
+ records = list(pool.map(fetch, manifest["roots"]))
40
+ uuid_counts = Counter(str(item["metadata"].get("uuid")) for item in records)
41
+ by_artifact = defaultdict(Counter)
42
+ scales = defaultdict(Counter)
43
+ keysets = defaultdict(Counter)
44
+ for item in records:
45
+ artifact = item["artifact"]
46
+ metadata = item["metadata"]
47
+ by_artifact[artifact][str(metadata.get("uuid"))] += 1
48
+ scales[artifact][json.dumps(metadata.get("scale"), separators=(",", ":"))] += 1
49
+ keysets[artifact][",".join(sorted(metadata))] += 1
50
+
51
+ pairs = defaultdict(dict)
52
+ for item in records:
53
+ pairs[(item["sample"], item["segment"])][item["artifact"]] = item
54
+ paired = [value for value in pairs.values() if set(value) == {"tifxyz_original", "tifxyz_normalized"}]
55
+ normalized_literal_pairs = 0
56
+ source_specific_original_pairs = 0
57
+ for pair in paired:
58
+ normalized_uuid = str(pair["tifxyz_normalized"]["metadata"].get("uuid"))
59
+ original_uuid = str(pair["tifxyz_original"]["metadata"].get("uuid"))
60
+ normalized_literal_pairs += normalized_uuid == "output_tifxyz"
61
+ source_specific_original_pairs += original_uuid not in {"None", "output_tifxyz"}
62
+
63
+ result = {
64
+ "schema_version": "1.0",
65
+ "generated_at": datetime.now(timezone.utc).isoformat(),
66
+ "manifest_sha256": hashlib.sha256(manifest_path.read_bytes()).hexdigest(),
67
+ "observations": {
68
+ "registered_roots": len(records),
69
+ "distinct_uuid_values": len(uuid_counts),
70
+ "uuid_counts_top20": uuid_counts.most_common(20),
71
+ "uuid_counts_by_artifact": {
72
+ key: value.most_common() for key, value in sorted(by_artifact.items())
73
+ },
74
+ "scale_counts_by_artifact": {
75
+ key: value.most_common() for key, value in sorted(scales.items())
76
+ },
77
+ "metadata_keysets_by_artifact": {
78
+ key: value.most_common() for key, value in sorted(keysets.items())
79
+ },
80
+ "paired_original_normalized_segments": len(paired),
81
+ "pairs_with_normalized_uuid_output_tifxyz": normalized_literal_pairs,
82
+ "pairs_with_source_specific_original_uuid": source_specific_original_pairs,
83
+ },
84
+ "source_inference": {
85
+ "claim": (
86
+ "The normalized metadata fingerprint is consistent with Villa's "
87
+ "vc_obj2tifxyz_legacy defaults: scale 1/20 = 0.05 and UUID copied "
88
+ "from the temporary output-directory basename. This does not prove "
89
+ "that a private workflow invoked that executable."
90
+ ),
91
+ "public_source_locations": {
92
+ "legacy_default_step_and_scale": "volume-cartographer/apps/src/vc_obj2tifxyz_legacy.cpp",
93
+ "legacy_uuid_from_output_basename": "volume-cartographer/apps/src/vc_obj2tifxyz_legacy.cpp",
94
+ "shared_metadata_writer": "volume-cartographer/core/src/QuadSurface.cpp",
95
+ },
96
+ },
97
+ "records": records,
98
+ }
99
+ output.parent.mkdir(parents=True, exist_ok=True)
100
+ output.write_text(json.dumps(result, indent=2) + "\n", encoding="utf-8")
101
+ print(json.dumps(result["observations"], indent=2))
102
+ print(f"wrote {output}")
103
+
104
+
105
+ def main() -> int:
106
+ parser = argparse.ArgumentParser(description=__doc__)
107
+ parser.add_argument("--manifest", type=Path, required=True)
108
+ parser.add_argument("--output", type=Path, required=True)
109
+ parser.add_argument("--workers", type=int, default=24)
110
+ args = parser.parse_args()
111
+ run(args.manifest, args.output, args.workers)
112
+ return 0
113
+
114
+
115
+ if __name__ == "__main__":
116
+ raise SystemExit(main())
uuid-producer-audit/uuid-audit-2026-08-02.json ADDED
The diff for this file is too large to render. See raw diff