Skip to content

Low-hanging Fruit #1024

@brendancol

Description

@brendancol
  1. Edge detection filters (Sobel, Laplacian, Prewitt)

You already have convolution.py and focal.apply. These are just predefined kernels + a convolution call. Sobel-x,
Sobel-y, Laplacian, and Prewitt are ~10 lines each and are among the most-requested raster operations.

  1. More spectral indices

You have 14 band-ratio indices. Each new one is ~20 lines of band arithmetic. Common missing ones:

  • NDSI (Normalized Difference Snow Index) - green vs SWIR
  • NDBI (Normalized Difference Built-up Index) - SWIR vs NIR
  • BAI (Burn Area Index) - distance in spectral space to charcoal point
  • MSAVI2 (Modified SAVI) - self-adjusting soil line, no L parameter needed
  • OSAVI (Optimized SAVI) - fixed L=0.16 variant
  1. Northness / eastness

cos(aspect) and sin(aspect) — two trivial wrappers, but they're the standard way to use aspect in statistical models
(aspect is circular, so raw degrees are useless in regression). Very commonly needed.

  1. Cell statistics (local operations across a raster stack)

Given a list of aligned rasters, compute per-cell min/max/mean/std/range/count. This is ArcGIS's "Cell Statistics" and
is one of the most common raster operations. Implementation is straightforward np.stack + np.nanmean along axis 0,
and the dask/cupy paths follow naturally.

  1. Focal range and focal variety

focal_statistics has min, max, median, std, sum — but not:

  • range (max - min in window) — trivial
  • variety (count of unique values in window) — useful for categorical rasters, slightly more work but still simple
    with numba

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions