IAOCEA / healpix-convolution

Other
1 stars 2 forks source link

padding #25

Open keewis opened 4 months ago

keewis commented 4 months ago

As part of #18, we need to pad the input array. #23 added the basic infrastructure and the constant mode.

Planned modes:

The remaining cells all need a way to find the nearest neighbour from the list of computed neighbours. In addition to that, linear_ramp needs the distance in rings, and symmetric needs to work with vector geometry to find the right cells.

keewis commented 4 months ago

as pointed out by @jmdelouis, it looks like for some cells there is multiple nearest neighbours, so we'd have to compute the average of those neighbours.

Instead, we have a couple of other modes: mean, mode, max, min (simple aggregation of the neighbourhood – group neighbours by the padded cell to implement this), and a different mode (mostly mean, but could also be median / max, min) that includes more data the further the padded cell is away from any data cells to capture larger-scale features.