Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Add raster geometric operations (polygon clipping, rotation, seam blending)

Đang mở
#1,144 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
python
Lĩnh vực
data

Hướng nghiên cứu

Start by reading the existing crop() and rasterize() functions for clipping and mask behavior, then inspect merge() for current overlap handling. Define tests for polygon masking, affine transformations, and feathered blending; the work is complete when each requested operation has coverage for its stated inputs and expected raster output.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

after-1.0.0-release enhancement

Some basic raster manipulation operations are missing from xarray-spatial.

Scope

Polygon clipping

Clip a raster to an arbitrary polygon geometry, not just a bounding box like crop() does. Pixels outside the polygon get masked to nodata. This should accept shapely geometries or coordinate arrays for the clip mask.

This is probably the highest priority item here. It comes up constantly in analysis workflows where you need to extract data for an irregular study area, watershed boundary, administrative unit, etc.

Raster rotation and affine transformation

Arbitrary rotation and affine transforms beyond what reprojection handles. Useful for aligning imagery, rotating to a local coordinate frame, or correcting sensor geometry.

Mosaic with feathered blending

Distance-weighted blending at seam lines when mosaicking overlapping rasters. The existing merge() handles overlap by picking one value, but doesn't blend. Feathered blending produces much better results where rasters overlap, especially when there are brightness or exposure differences between tiles.

Notes

Polygon clipping involves rasterizing the polygon boundary and masking. The existing rasterize() function could potentially be reused for the polygon-to-mask step.

Ngôn ngữ chính
Python
Star
972
Fork
92
Merge trung bình
2 ngày 12 giờ
Pull request đã merge (30 ngày)
7

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của xarray-contrib/xarray-spatial

Tất cả issue của xarray-contrib/xarray-spatial

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.