[GRASS-user] Setting region to add map to location

Markus Metz markus.metz.giswork at gmail.com
Mon Jul 9 08:52:51 PDT 2018


On Sun, Jul 8, 2018 at 1:41 AM, Rich Shepard <rshepard at appl-ecosys.com>
wrote:
>
> On Sun, 8 Jul 2018, Markus Neteler wrote:
>
>> r.patch does exactly that, no flags needed.
>
>
> Markus,
>
>   A related issue: when I want to reproject raster DEMs from their source
> location to a common target location r.proj fails because the source's
> region is outside the target's region.

The source's region does not matter, what matters are the extents of the
source raster map.

> How this can be makes no sense as the
> target's region is an entire state and the DEMs are 7.5' topographic
quads.
> But, that's what r.proj tells me.
>
>   I've not found how to resolve this issue.

Apparently the input raster, when reprojected to the current region in the
location/mapset, does not overlap with the current region.

You can check the reprojected extents of the input raster with r.proj -g.

Markus M

>
>   Example: the target location's (OR) default region is:
>
> g.region -l
> north-west corner: long: 125:01:06.208515W lat: 46:54:29.991261N
> north-east corner: long: 115:30:24.620534W lat: 46:53:20.948674N
> south-east corner: long: 116:00:36.987691W lat: 40:41:04.56057N
> south-west corner: long: 124:33:45.521802W lat: 40:42:06.559349N
> center longitude:  120:16:28.077102W
> center latitude:   43:53:09.60569N
> rows:              691017
> cols:              724617
>
> g.region -p
> projection: 99 (unnamed)
> zone:       0
> datum:      ** unknown (default: WGS84) **
> ellipsoid:  grs80
> north:      369907.96287773
> south:      -321108.56796525
> west:       2155817.84893823
> east:       2880434.93778086
> nsres:      0.99999932
> ewres:      1.00000012
> rows:       691017
> cols:       724617
> cells:      500722665489
>
> and a source's smaller region (Elwood) is:
>
> g.region -l
> north-west corner: long: 122:22:30.177355W lat: 45:14:59.998015N
> north-east corner: long: 122:15:00.21557W lat: 45:15:07.129823N
> south-east corner: long: 122:14:59.838614W lat: 45:14:54.839228N
> south-west corner: long: 122:22:29.773496W lat: 45:14:47.707842N
> center longitude:  122:18:45.005157W
> center latitude:   45:14:57.48019N
> rows:              415
> cols:              10732
>
> g.region -p
> projection: 99 (unnamed)
> zone:       0
> datum:      ** unknown (default: WGS84) **
> ellipsoid:  grs80
> north:      582841.5
> south:      581596.5
> west:       7719262.5
> east:       7751458.5
> nsres:      3
> ewres:      3
> rows:       415
> cols:       10732
> cells:      4453780
>
>   I need to understand why r.proj fails and how I can fix these
situations.
>
> Best regards,
>
> Rich
>
> _______________________________________________
> grass-user mailing list
> grass-user at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/grass-user
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-user/attachments/20180709/72e4d7cd/attachment.html>


More information about the grass-user mailing list