Skip to content

Refine reverse NTv2 shifts at the estimated source coordinate - #173

Open
timothyanderson096-ocdealcheck wants to merge 1 commit into
GeoscienceAustralia:masterfrom
timothyanderson096-ocdealcheck:fix/169-reverse-ntv2-refinement
Open

timothyanderson096-ocdealcheck wants to merge 1 commit into
GeoscienceAustralia:masterfrom
timothyanderson096-ocdealcheck:fix/169-reverse-ntv2-refinement

Conversation

@timothyanderson096-ocdealcheck

Copy link
Copy Markdown

Fixes #169.

Implements the single reverse refinement proposed in the issue. After estimating the source coordinate, the transformation evaluates the grid shifts there and applies those refined shifts to the original target coordinate. An estimate outside the grid raises the existing extent error.

Adds self-contained regression tests covering both interpolation methods, positive and negative shifts, interpolation-cell crossings, repeated round trips and an estimate leaving the grid. Expected coordinates are calculated independently of the forward implementation.

Validation:

One refinement reduces the error; it does not guarantee exact inversion for arbitrary grids. Existing rounding and bicubic boundary behavior remain unchanged, keeping #171 and #170 separate.

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.

NTv2 bicubic and bilinear interpolators are not currently 'reversible'; Add a (single) iteration to find grid shift values in the CRS of the grid

1 participant