Lightweight CRS parser to remove hard pyproj dependency#1072
Merged
brendancol merged 9 commits intomasterfrom Mar 24, 2026
Merged
Lightweight CRS parser to remove hard pyproj dependency#1072brendancol merged 9 commits intomasterfrom
brendancol merged 9 commits intomasterfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1057
Summary
CRSclass that covers the ~150 EPSG codes with Numba fast paths (WGS84, NAD83, NAD27, UTM zones, Web Mercator, Albers, LCC, LAEA, polar/oblique stereographic, CEA, ellipsoidal Mercator)_resolve_crs()and_crs_from_wkt()try the built-in table first, fall back to pyproj for anything else_grid.pyboundary estimation and_source_footprint_in_targetuse a newtransform_points()scatter-point helper that reuses existing Numba kernels, so pyproj.Transformer is only needed for unsupported CRS pairs_reproject_chunk_numpy,_reproject_chunk_cupy) andreproject()/merge()no longer call_require_pyproj()upfront -- pyproj is imported lazily only when the fast path can't handle the CRSTest plan
test_lite_crs.pycovering construction,to_dict/to_wktround-trips, pyproj comparison for all embedded codes, two-tier resolution, scatter-point transforms, grid computation with lite CRS, and monkeypatched no-pyproj integration teststest_reproject.pyfor fullreproject()with lite CRS