[gdal-dev] can't handle grib file

Margherita Di Leo diregola at gmail.com
Thu Aug 23 06:52:58 PDT 2012


In order to check what is inside the grib file, I just installed the grib
API [1] and ran

grib_dump dwd_grib1_ispra_gmi202_2012063000 > tst.txt

The information I get looking into the txt file is:

***** FILE: dwd_grib1_ispra_gmi202_2012063000
#==============   MESSAGE 1 ( length=68884 )               ==============
GRIB {
  editionNumber = 1;
  table2Version = 2;
  # Offenbach  (RSMC)  (grib1/0.table)
  centre = 78;
  generatingProcessIdentifier = 207;
  # U U-component of wind m s**-1 (grib1/2.0.2.table)
  indicatorOfParameter = 33;
  # Fixed height above ground height in meters  (2 octets)  (grib1/3.table)

  indicatorOfTypeOfLevel = 105;
  level = 10;
  # Initialized analysis product for reference time  (P1=0)
 (grib1/5.table)
  timeRangeIndicator = 1;
  # Unknown code table entry ()
  subCentre = 255;
  paramId = 165;
  #-READ ONLY- units = m s**-1;
  #-READ ONLY- nameECMF = 10 metre U wind component;
  #-READ ONLY- name = 10 metre U wind component;
  decimalScaleFactor = 0;
  dataDate = 20120630;
  dataTime = 0;
  # Hour (stepUnits.table)
  stepUnits = 1;
  stepRange = 0;
  startStep = 0;
  endStep = 0;
  #-READ ONLY- marsParam = 33.2;
  shortName = 10u;
  GDSPresent = 1;
  bitmapPresent = 1;
  numberOfVerticalCoordinateValues = 0;
  Ni = 201;
  Nj = 161;
  latitudeOfFirstGridPointInDegrees = 35;
  longitudeOfFirstGridPointInDegrees = -10;
  earthIsOblate = 0;
  uvRelativeToGrid = 0;
  latitudeOfLastGridPointInDegrees = 74.96;
  longitudeOfLastGridPointInDegrees = 40.04;
  iScansNegatively = 0;
  jScansPositively = 1;
  jPointsAreConsecutive = 0;
  #-READ ONLY- alternativeRowScanning = 0;
  jDirectionIncrementInDegrees = 0.24975;
  iDirectionIncrementInDegrees = 0.2502;
  #-READ ONLY- numberOfDataPoints = 32361;
  #-READ ONLY- numberOfValues = 32361;
  missingValue = 9999;
  tableReference = 0;
  #-READ ONLY- binaryScaleFactor = -11;
  #-READ ONLY- referenceValue = -11.346;
  sphericalHarmonics = 0;
  complexPacking = 0;
  integerPointValues = 0;
  additionalFlagPresent = 0;
  packingType = grid_simple;
  bitsPerValue = 16;
  values(32361) =  {
  1.5509548187e+00, 1.4977321625e+00, 1.5494899750e+00, 1.6993923187e+00,
1.9513454437e+00,
  2.2316188812e+00, 2.5079860687e+00, 2.7740993500e+00, 3.0099391937e+00,
3.2716579437e+00,
  3.5905056000e+00, 3.9567165375e+00, 4.3610134125e+00, 4.6178493500e+00,
4.2081813812e+00,
  1.7648220062e+00, 1.5626735687e+00, 1.2032985687e+00, 6.4226341248e-01,
4.3620872498e-01,
  6.7986106873e-01, -9.1135025024e-02, 8.1716537476e-02, 2.3650169373e-01,
5.7488059998e-01,
  8.7077903748e-01, 3.6931419373e-01, -2.2541236877e-01, -7.8439712524e-02,
-6.3312721252e-01,
  -7.3127174377e-01, -3.0500221252e-01, 4.7087669373e-01, 8.9812278748e-01,
7.7019309998e-01,
  6.2175559998e-01, 7.5798606873e-01, 6.8425559998e-01, 9.6941184998e-01,
1.1735134125e+00,
  7.9851341248e-01, 2.5163841248e-01, -6.4386940002e-01, -1.0427951813e+00,
-9.9543190002e-01,
  -2.3191623688e+00, -1.5120334625e+00, 5.5388450623e-01, 1.7501735687e+00,
1.6022243500e+00,
  -1.3963108063e+00, -2.5066623688e+00, -2.1536350250e+00,
-2.0496311188e+00, -1.8875217438e+00,
  -1.5056858063e+00, -7.7424049377e-01, -8.3283424377e-01,
-9.7248268127e-01, -6.6681861877e-01,
  -1.1380100250e+00, -2.5716037750e+00, -3.6634006500e+00,
-3.5447483063e+00, -2.6272678375e+00,
  -1.4226779938e+00, -9.0168190002e-01, -8.6750221252e-01,
-1.0720920563e+00, -1.6135959625e+00,
  -1.5720920563e+00, -1.0823459625e+00, -9.9201393127e-01,
-5.9504127502e-01, -7.6105690002e-01,
  -1.1116428375e+00, -7.0002174377e-01, -2.5861549377e-01,
-2.4201393127e-01, 2.2673606873e-01,
  5.2907943726e-02, -4.4318580627e-01, -6.2287330627e-01,
-6.9855690002e-01, -7.3615455627e-01,
  -1.9607639313e+00, -2.2805881500e+00, -2.2483615875e+00,
-2.0520725250e+00, -1.8782444000e+00,
  -1.7024631500e+00, -1.4602756500e+00, -1.1492404938e+00,
-8.0695533752e-01, -4.1486549377e-01,
  4.3142318726e-02, 5.3532981873e-01, 9.9675559998e-01, 1.4259548187e+00,
1.8199977875e+00
  ... 32261 more values
  }
  #-READ ONLY- numberOfCodedValues = 32361;
  #-READ ONLY- maximum = 13.5881;
  #-READ ONLY- minimum = -11.346;
  #-READ ONLY- average = 0.101585;
  #-READ ONLY- numberOfMissing = 0;
  #-READ ONLY- standardDeviation = 3.29306;
  #-READ ONLY- skewness = -29313.5;
  #-READ ONLY- kurtosis = 1.62527e+07;
  #-READ ONLY- isConstant = 0;
  gridType = regular_ll;
  #-READ ONLY- getNumberOfValues = 32361;

[...]

So it looks like the information is actually there, but the gdal driver
can't handle it. Any hint?

Thanks,

Margherita

[1] http://www.ecmwf.int/products/data/software/grib_api.html

On Thu, Aug 23, 2012 at 8:53 AM, Margherita Di Leo <diregola at gmail.com>wrote:

> Hi all,
>
> I have a problem handling some grib files, I get a warning message and I
> can't understand how to deal with it..
>
> running gdalinfo, it says:
>
> Un-handled possible ensemble section center 78 subcenter 255
> [... several times, cut]
> Un-handled possible ensemble section center 78 subcenter 255
> Driver: GRIB/GRIdded Binary (.grb)
> Files:
> /home/leomarg/Desktop/Fire_event_test_case_Valencia/grib/dwd_grib1_ispra_gmi202_
> 2012063000
> Size is 201, 161
> Coordinate System is:
> GEOGCS["Coordinate System imported from GRIB file",
>     DATUM["unknown",
>         SPHEROID["Sphere",6367470,0]],
>     PRIMEM["Greenwich",0],
>     UNIT["degree",0.0174532925199433]]
> Origin = (-10.000000000000000,74.960000000000008)
> Pixel Size = (0.000000000000000,-0.000000000000000)
> Corner Coordinates:
> Upper Left  ( -10.0000000,  74.9600000) ( 10d 0' 0.00"W, 74d57'36.00"N)
> Lower Left  ( -10.0000000,  74.9600000) ( 10d 0' 0.00"W, 74d57'36.00"N)
> Upper Right ( -10.0000000,  74.9600000) ( 10d 0' 0.00"W, 74d57'36.00"N)
> Lower Right ( -10.0000000,  74.9600000) ( 10d 0' 0.00"W, 74d57'36.00"N)
> Center      ( -10.0000000,  74.9600000) ( 10d 0' 0.00"W, 74d57'36.00"N)
> Band 1 Block=201x1 Type=Float64, ColorInterp=Undefined
>   Description = 10[m] HTGL (Specified height level above ground)
>   Metadata:
>     GRIB_COMMENT=u-component (zonal) of wind [m/s]
>     GRIB_ELEMENT=U
>     GRIB_FORECAST_SECONDS=0 sec
>     GRIB_REF_TIME=  1341014400 sec UTC
>     GRIB_SHORT_NAME=10-HTGL
>     GRIB_UNIT=[m/s]
>     GRIB_VALID_TIME=  1341014400 sec UTC
> Band 2 Block=201x1 Type=Float64, ColorInterp=Undefined
>   Description = 10[m] HTGL (Specified height level above ground)
>   Metadata:
>     GRIB_COMMENT=v-component (merdional) of wind [m/s]
>     GRIB_ELEMENT=V
>     GRIB_FORECAST_SECONDS=0 sec
>     GRIB_REF_TIME=  1341014400 sec UTC
>     GRIB_SHORT_NAME=10-HTGL
>     GRIB_UNIT=[m/s]
>     GRIB_VALID_TIME=  1341014400 sec UTC
>
> [...]
>
> Furthermore, when I try with gdal_translate to convert one of the bands in
> tif format, the size of the pixels created is 0x0.
>
> Thanks in advance for any hint.
>
> --
> Dr. Margherita Di Leo
>



-- 
Dr. Margherita Di Leo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20120823/11da436a/attachment-0001.html>


More information about the gdal-dev mailing list