Skip to content

Add exact 2D geometry rebuild and inward containment validation - #325

Open
gpt-cmdr wants to merge 5 commits into
mainfrom
codex/rasmapper-exact-geometry-compile
Open

Add exact 2D geometry rebuild and inward containment validation#325
gpt-cmdr wants to merge 5 commits into
mainfrom
codex/rasmapper-exact-geometry-compile

Conversation

@gpt-cmdr

@gpt-cmdr gpt-cmdr commented Aug 31, 2026

Copy link
Copy Markdown
Owner

Summary

  • add guarded, atomic replacement APIs for 2D breaklines, refinement regions, and reference lines
  • add an exact, task-local plain-text geometry-to-HDF refresh workflow through the explicitly initialized HEC-RAS version
  • preserve and validate terrain, land-classification, infiltration, and sediment associations; verify sibling geometry HDFs are unchanged; roll back on failure
  • add owned-process supervision and numbered evidence backups for GUI/native mutations
  • add a fail-closed pre-mesh containment audit using the exact compiled 2D perimeter buffered inward by one full base-cell spacing
  • keep external boundary-condition lines outside that inward gate so they can be validated against external-face association and overlap rules
  • support collection-level imported perimeters, native multipart index variants, complete breakline parameters, and modern reference-line result extraction
  • add exact 2D boundary-location creation/replacement and inline hydrograph authoring with geometry-backed selectors and atomic mutation
  • require semantic geometry-HDF readiness instead of accepting HEC-RAS's early empty placeholder
  • supervise Wine CompleteGeometry by semantic HDF stability and terminate only the owned process tree
  • remove stale RAS event-condition map layers from task-local project clones
  • normalize disabled meteorology across unsteady text, sidecar HDF, and the compiled plan artifact
  • validate native solves using the completion banner plus populated unsteady result datasets and reject in-band ERROR/HDF_ERROR records
  • cap native solver cores to the process-affinity envelope and update both plan text and compiled-HDF core attributes

Validation

  • consolidated focused suite: 216 passed, 1 skipped
  • changed geometry surface: 204 passed, 1 skipped
  • all focused unsteady-flow tests: 239 passed
  • exact 2D boundary-location surface: 14 passed
  • repository suite before the boundary-location addition: 2,553 passed, 61 skipped, 2 deselected; seven global-state/order failures all passed in fresh isolated processes
  • package wheel and source distribution built and passed twine check
  • documentation built successfully
  • real Bald Eagle 2D geometry/unsteady fixture: existing geometry-backed boundary location round-tripped byte-for-byte without mutation
  • real HEC-RAS 6.6 qualification in an isolated Linux guest using a task-local Wine prefix:
    • exact cloned geometry/flow/plan identities retained
    • zero inward-containment violations across 1,056 breaklines and all present refinements/structures at a 200-foot base-cell spacing
    • regenerated mesh: 198,448 authoritative cells and 432,044 faces
    • Wine geometry HDF rebuild completed after semantic readiness was added
    • CompleteGeometry returned by stable semantic HDF readiness with no owned-process survivors
    • native HEC-RAS 6.6 preprocessing and the full two-hour unsteady plan completed
    • solver log contained the Finished Unsteady Flow Simulation banner and a 0.0000009538% volume error
    • result HDF contained populated 2D water-surface results for three mapping times
    • an affinity-limited four-core probe updated both 1D and per-mesh 2D compiled-HDF settings with exact readback

Qualification findings

Two preparation failures were intentionally preserved and converted into fail-closed APIs:

  1. Stale RASEventConditions layers caused Wine preprocessing to fail before the solver. Removing every inherited event-condition layer from the owned clone resolved that class of failure.
  2. Enabled evapotranspiration state with no values caused native execution to fail in-band. The canonical HEC-RAS 6.6 no-meteorology state removes the compiled Meteorology group; the new helper now reproduces that state while retaining and disabling sidecar data.

The hydraulic time stepping itself was short, but complete plan processing remained roughly 43 minutes because property-table/preprocessing work dominated. Prepared geometry and compiled execution artifacts should therefore be reused when the geometry and forcing are unchanged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant