[GRASS-user] Import and reproject COSMO REA6 data set

Markus Metz markus.metz.giswork at gmail.com
Thu Nov 9 00:08:45 PST 2017


On Tue, Nov 7, 2017 at 9:45 PM, Markus Metz <markus.metz.giswork at gmail.com>
wrote:
>
>
>
> On Mon, Nov 6, 2017 at 2:05 PM, Helmut Kudrnovsky <hellik at web.de> wrote:
> >
> > Pietro Zambelli wrote
> > > Dear Helmut,
> > >
> > > On 06/11/17 08:22, Helmut Kudrnovsky wrote:
> > >> not really an answer, but the data documentation says:
> > >>
> > >> "Output format:      GRIB 1, rotated spherical"
> > >>
> > >> a quick web search shows some hints to handle such data.
> > >
> > > Looking at the reference model manual:
> > >
> > > http://www.cosmo-model.org/content/model/documentation/
core/cosmoDyncsNumcs.pdf
> > >
> > > at page 25, there are some equation to transform the rotated spherical
> > > coordinates back and forward, see the attached image.
> > >
> > > Are these the hints that you mentioned in your previous reply?
> > >
> > > Should I convert the raster in to a x_s, y_s, z list of points and
write
> > > a function to convert the spherical coordinates (x_s, y_s) values
> > > defining my own python script to apply the transformation function and
> > > generate the lat, lon, z triplet of values, to be imported into a
WGS84
> > > location?
> > > Any better approach/idea?
> > >
> > > Thank you for the support.
> >
> > never used such kind of data for myself; maybe it would be worth to ask
on
> > the GDAL ML how to used this kind of data.
>
> GDAL and GRASS use proj4 for reprojection, but proj4 does not support
these rotated spheres where the latitude origin for a longlat projection is
not 0. The easiest solution is to use a different data source. Otherwise
you would have to write a reprojection routine for such rotated spheres.
The source code of gdalwarp or r.proj could be used as a template.

The cdo tool [0] can apparently reproject GRIB data from rotated sphere to
regular longlat, e.g. with

cdo remapcon,outgrid.txt T_2M.2D.201501.grb T_2M.2D.201501.ll.grb

where the contents of outgrid.txt are defining the output projection and
grid geometry (computational region) with something like
-->
gridtype = lonlat
xsize = 1319
ysize = 610
xfirst = -44.75
yfirst = 21.8333333333333
xinc = 0.0833333333333333
yinc = 0.0833333333333333
<--

with
xsize: number of columns
ysize: number of rows
xfirst, yfirst: lower left corner coordinates
xinc, yinc: resolution

Markus M

[0] https://code.mpimet.mpg.de/projects/cdo/
>
> Markus M
> >
> > some other things I've found in the web, e.g.
> >
> > https://gis.stackexchange.com/questions/10808/manually-
transforming-rotated-lat-lon-to-regular-lat-lon
> > https://gis.stackexchange.com/questions/64210/transforming-
regular-lat-lon-to-rotated-lat-lon
> > http://jgrib.sourceforge.net/docs/rotLatLon.pdf
> > [...]
> >
> > they looks similar you've found.
> >
> >
> >
> >
> > -----
> > best regards
> > Helmut
> > --
> > Sent from: http://osgeo-org.1560.x6.nabble.com/Grass-Users-f3884509.html
> > _______________________________________________
> > 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/20171109/15a67258/attachment.html>


More information about the grass-user mailing list