comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: GRIB data question
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: GRIB data question [message #78334 is a reply to message #78333] Thu, 10 November 2011 10:56 Go to previous messageGo to previous message
Kenneth P. Bowman is currently offline  Kenneth P. Bowman
Messages: 585
Registered: May 2000
Senior Member
In article <MPG.2925b646c20b58a9898db@news.giganews.com>,
David Fanning <news@dfanning.com> wrote:

> I found this piece of documentation. If you read the
> section entitled The Solution - Part 1, toward the
> end of the section, you find that the GRIB data has
> a grid that goes from 90 to -90 in lat and 0 to 360
> in lon, and he indicates the (1,1) point is at 90
> deg N and 0 deg E. This indicates to me that the
> convention is the upper-left convention, which is
> (honestly) what I would expect.
>
> http://www.iges.org/grads/gadoc/grib2.html

This doesn't really have anything to do with image data. When
global atmospheric models (particularly spectral transform codes)
were first being developed in the 60's and 70's, the designers had
to make choices about storage conventions. Some of the original
models developed at the time used the convention of ordering data
from the north pole to the south pole. This may be in part because
some models had both one- and two-hemisphere versions.
Starting at the north pole makes indices consistent in the
northern hemisphere (where most models were developed).

Models generally evolve from earlier codes, and changing
conventions in the code is likely to be painful and introduce
difficulty to track bugs, so it is not surprising that
spectral transform models continue to this day to start
the latitude indexing at the north pole.

Grid point models are often different.

Similarly, some models (and some data sets) go from (-180, 180)
in longitude, while others go from (0, 360). Different
developers made, and continue to make, different choices.

I think the choice was unfortunate, because I prefer to
have everything in a right-handed coordinate system where a
variable f(x, y, z) is stored as f[i,j,k], with i increasing
in longitude (0 to 360), j increasing in latitude
(-90, 90), and k increasing in altitude (0, top) or decreasing
in pressure (1000, 0).

So when I get GRIB files, the first thing I do is put the
data into right-handed coordinate systems in netCDF files.
This requires some work, but then everything is consistent,
making life vastly easier for me and those I work with.

Ken
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: changing the content of a NCDF file
Next Topic: Re: changing the content of a NCDF file

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Thu Oct 09 23:55:42 PDT 2025

Total time taken to generate the page: 0.47846 seconds