Task: Implement the Globe Box feature
TASK-DESCRIPTION
- Modify:
scripts/globe-box-build.sh - Modify:
scripts/globe_box_build.py - Modify:
tests/03-globe-box-build.sh - Modify:
tests/04-globe-box-math.sh - Modify:
Makefile - Modify:
scripts/site-state-fetch.sh - Modify:
TODO.md
Implement feature prompts/features/03-globe-box.md (Globe Box) in scripts/globe-box-build.sh plus a Python module scripts/globe_box_build.py that the script drives.
The build renders the Earth’s surface from the ETOPO 2022 source tiles (/datasets/dataset-etopo-2022/, read-only) into three watertight binary-STL pieces (north half, south half, twist-lock cylinder) in dataflow.out/box/ with a manifest, plus a --check validation mode.
TASK-OUTPUT
- Implement the files, then run
make build,make check, andmake testfrom the repository root. - Report the piece counts, sizes, and verification results.
- End with the
VERIFICATION:line.
TASK-CONTEXT
- The geometry decisions are recorded in
documents/05-globe-box-approach.md: 100 mm sea-level globe (radius 50), land relief over the global ETOPO range with flat oceans, two hollow hemisphere halves with flat rims at z = 0, an inner sphere of radiusradius_mm - wall_mmwith a cylindrical socket (bore) of radiussocket_radius_mmforsocket_depth_mm, and a hollow twist-lock cylinder with a knurled band whose outer surface mates with the halves’ sockets. Bayonet pins on the cylinder engage L-shaped grooves in the sockets; one twist of the band locks both halves while the relief seam stays aligned (south-half grooves are mirror images). - The shell script owns the log file and the GDAL VRT over the source tiles; the Python module owns the parameter plan, per-piece sampling (average resampling via
osgeo.gdal.Warp), mesh construction, STL writing, manifest, and--checkvalidation. - The geometry math must be importable without
osgeoornumpy(pure Python), sotests/04-globe-box-math.shstays portable. - Tests: tool-gated
tests/03-globe-box-build.sh(builds the full set at coarse sampling, then validates), portabletests/04-globe-box-math.sh(parameter and mating-geometry invariants).
TASK-FILES
| Operation | Path |
|---|---|
| modify | scripts/globe-box-build.sh |
| modify | scripts/globe_box_build.py |
| modify | tests/03-globe-box-build.sh |
| modify | tests/04-globe-box-math.sh |
| modify | Makefile |
| modify | scripts/site-state-fetch.sh |
| modify | TODO.md |
TASK-VERIFY
- Run:
make build,make check, andmake testfrom the repository root. - Expected: exit status 0 from each.
TASK-FEATURES
prompts/features/03-globe-box.md
TASK-ACCEPTANCE
GLOBE-BOX-R001GLOBE-BOX-R002GLOBE-BOX-R003
OUTPUT: the implemented files, the piece counts and sizes, and the verification results, ending with the VERIFICATION: line.