I have a doubt about the use of r.tile with overlap. r.tile without overlap works without problem, however when I set an overlap, no matter how large (have tried 400, 40 and 4 with same outcome) it gives me the error:
ERROR: Illegal latitude for North
How should I calculate my overlap and my tiles in order to avoid this problem?
Furthermore, is there a way to set a different rule for rows and columns? say I want to generate vertical stripes that overlap each other for a certain number of columns?
On Aug 10, 2016 4:34 PM, “Margherita Di Leo” <diregola@gmail.com> wrote:
Hi,
I have a doubt about the use of r.tile with overlap. r.tile without overlap works without problem, however when I set an overlap, no matter how large (have tried 400, 40 and 4 with same outcome) it gives me the error:
ERROR: Illegal latitude for North
Which projection are you using?
I suspect latlong?
How should I calculate my overlap and my tiles in order to avoid this problem?
Please let us know more… Perhaps also the command with parameters.
Furthermore, is there a way to set a different rule for rows and columns? say I want to generate vertical stripes that overlap each other for a certain number of columns?
On Wed, Aug 10, 2016 at 8:00 PM, Markus Neteler <neteler@osgeo.org> wrote:
Hi
On Aug 10, 2016 4:34 PM, “Margherita Di Leo” <diregola@gmail.com> wrote:
ERROR: Illegal latitude for North
Which projection are you using?
I suspect latlong?
yes, correct.
How should I calculate my overlap and my tiles in order to avoid this problem?
Please let us know more… Perhaps also the command with parameters.
The data source I’m using is GMTED 2010 at 30 arc second spatial resolution, global coverage → created VRT → linked via r.external → set g.region rast=
On Thu, Aug 11, 2016 at 10:09 AM, Margherita Di Leo <diregola@gmail.com> wrote:
Ciao Markus! Thanks for your answer,
On Wed, Aug 10, 2016 at 8:00 PM, Markus Neteler <neteler@osgeo.org> wrote:
Which projection are you using?
I suspect latlong?
yes, correct.
...
r.tile input=bln300_mosaic output=tiled width=14400 height=9600 overlap=4 --v
ERROR: Illegal latitude for North
I guess that the distance value must be given in degree when in
LatLong since I cannot see any geodesic support in r.tile (it does
exist e.g. in r.grow.distance). Internally it calculates with the
coordinates.
Probably r.tile is not yet suitable for LatLong?
Test case:
g.region res=1 n=90 s=-90 w=-180 e=180 -p
r.mapcalc "myarea = 1"
r.tile input=myarea output=tiled width=14400 height=9600 overlap=4
ERROR: Illegal latitude for North
In the meantime you could try the following as a workaround:
Create a grid (v.mkgrid) for your tiles,
then loop over the tiles and set the region to your tile plus / minus the overlap you like to have at the boundaries after checking that current boundary does not exceed north or south limits.
It seems that g.region does not wrap latitudinal boundaries in the north, while it does for longitudinal limits and rounds latitudinal boundaries in the south.