[GRASS-user] integration of sample.c algorithms into r.resample

Glynn Clements glynn at gclements.plus.com
Mon Aug 14 03:36:07 EDT 2006


Dylan Beaudette wrote:

> How about this: 
> 1. keep r.resample and update the documentation accordinly. 
> 2. toss r.bilinear, possibly leave a note somewhere in the docs

Or replace it with a script which calls "r.interpolate method=bilinear".

> 3. create a new module 'r.resample.3' (?) for the three methods that it would 
> do? or 'r.interpolate' (?)

I prefer r.interpolate.

> Note: the r.interpolate name would make sense for moving from larger to 
> smaller grid spacing ( 100m -> 10m), however it wouldn't make as much sense 
> for moving from smaller to larger grid spacing (10m -> 100m).

Even in that case, it will normally still perform interpolation. The
only case where no interpolation occurs is when the new resolution is
an exact multiple of the old resolution and the alignment is correct.

> In this case 
> something like r.aggregate  would make more sense. However this potentially 
> opens a new can of worms- as there are many ways to aggregate cells... which 
> might call for a new vector / raster module.

An aggregation tool would be useful in itself. At present, the
only solutions which I know of involve either r.neighbors or
r.average, both of which are a bit awkward.

-- 
Glynn Clements <glynn at gclements.plus.com>




More information about the grass-user mailing list