Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix shape masking #6129

Draft
wants to merge 16 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Ruff fixes
  • Loading branch information
hsteptoe committed Aug 22, 2024
commit e32f911b1e08f94e8d2afc6f38a5806ccf2d0d81
4 changes: 2 additions & 2 deletions lib/iris/_shapefiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ def create_shapefile_mask(


def _transform_coord_system(
geometry: shapely.Geometry,
cube: iris.cube.Cube,
geometry: shapely.Geometry,
cube: iris.cube.Cube,
geometry_crs: cartopy.crs = None
) -> shapely.Geometry:
"""Project the shape onto another coordinate system.
Expand Down
1 change: 0 additions & 1 deletion lib/iris/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -2166,7 +2166,6 @@ def mask_cube_from_shapefile(

Notes
-----

To mask a cube from a shapefile, both must first be on the same coordinate system.
Shapefiles are mostly on a lat/lon grid with a projection very similar to GeogCS
The shapefile is projected to the coord system of the cube using cartopy, then each cell
Expand Down
Loading