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

Aperta
#1,144 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Tranquilla
Stack tecnologico
python
Ambito
data

Direzione di ricerca

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.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

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.

Lingua principale
Python
Stelle
972
Fork
92
Merge medio
2g 12h
PR unite (30g)
7

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di xarray-contrib/xarray-spatial

Tutte le issue di xarray-contrib/xarray-spatial

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.