[gdal-dev] Is there a reference documentation for GDALMetadata structure?

Andrea Aime andrea.aime at geo-solutions.it
Mon May 27 01:38:49 PDT 2019


Hi,
I was wondering if there is any documentation on what a GDALMetadata XML
structure might contain, both in terms
of element/attributes, and key names?

Online I've found this example:
https://www.awaresystems.be/imaging/tiff/tifftags/gdal_metadata.html

But checking some files I have laying around there is more variety, for
example:

<GDALMetadata>.
    <Item name="Band_1">Max Band_1</Item>.
    <Item name="Band_2">Min Band_1</Item>.
    <Item name="Band_3">Mean Band_1</Item>.
    <Item name="Band_4">SD Band_1</Item>.
    <Item name="Band_5">MASD Band_1</Item>.
    <Item name="Band_6">Valid Inputs</Item>.
    <Item name="OFFSET" sample="0" role="offset">0</Item>.
    <Item name="SCALE" sample="0"
role="scale">0.000100000000000000005</Item>.
    <Item name="OFFSET" sample="1" role="offset">0</Item>.
    <Item name="SCALE" sample="1"
role="scale">0.000100000000000000005</Item>.
    <Item name="OFFSET" sample="2" role="offset">0</Item>.
    <Item name="SCALE" sample="2"
role="scale">0.000100000000000000005</Item>.
    <Item name="OFFSET" sample="3" role="offset">0</Item>.
    <Item name="SCALE" sample="3"
role="scale">0.000100000000000000005</Item>.
    <Item name="OFFSET" sample="4" role="offset">0</Item>.
    <Item name="SCALE" sample="4"
role="scale">0.000100000000000000005</Item>.
    <Item name="OFFSET" sample="5" role="offset">0</Item>.
    <Item name="SCALE" sample="5"
role="scale">0.000100000000000000005</Item>.
</GDALMetadata>.

but also:

<GDALMetadata>.
    <Item name="lat#units">degrees_north</Item>.
    <Item name="LatLon_Projection#earth_radius">6371229</Item>.
    <Item
name="LatLon_Projection#grid_mapping_name">latitude_longitude</Item>.
    <Item name="lon#units">degrees_east</Item>.
    <Item
name="NC_GLOBAL#Analysis_or_forecast_generating_process_identifier_defined_by_originating_centre">Coastal
Ocean Circulation Model</Item>.
    <Item name="NC_GLOBAL#Conventions">CF-1.6</Item>.
    <Item name="NC_GLOBAL#featureType">GRID</Item>.
    <Item name="NC_GLOBAL#file_format">GRIB-2</Item>.
    <Item name="NC_GLOBAL#GRIB_table_version">2,1</Item>.
    <Item name="NC_GLOBAL#history">Read using CDM IOSP GribCollection
v3</Item>.
    <Item name="NC_GLOBAL#Originating_or_generating_Center">US National
Weather Service, National Centres for Environmental Prediction
(NCEP)</Item>.
    <Item name="NC_GLOBAL#Originating_or_generating_Subcenter">0</Item>.
    <Item name="NC_GLOBAL#Type_of_generating_process">Forecast</Item>.
    <Item name="NETCDF_DIM_EXTRA">{time}</Item>.
    <Item name="NETCDF_DIM_time_DEF">{1,6}</Item>.
    <Item name="NETCDF_DIM_time_VALUES">3</Item>.
    <Item name="time#calendar">proleptic_gregorian</Item>.
    <Item name="time#long_name">GRIB forecast or observation time</Item>.
    <Item name="time#standard_name">time</Item>.
    <Item name="time#units">Hour since 2014-01-23T00:00:00Z</Item>.
    <Item name="u-component_of_current_surface#abbreviation">UOGRD</Item>.
    <Item name="u-component_of_current_surface#coordinates">reftime time
lat lon </Item>.
    <Item
name="u-component_of_current_surface#Grib2_Generating_Process_Type">Forecast</Item>.

    <Item name="u-component_of_current_surface#Grib2_Level_Type">Ground or
water surface</Item>.
    <Item
name="u-component_of_current_surface#Grib2_Parameter">{10,1,2}</Item>.
    <Item
name="u-component_of_current_surface#Grib2_Parameter_Category">Currents</Item>.

    <Item
name="u-component_of_current_surface#Grib2_Parameter_Discipline">Oceanographic
products</Item>.
    <Item
name="u-component_of_current_surface#Grib2_Parameter_Name">u-component of
current</Item>.
    <Item
name="u-component_of_current_surface#Grib_Variable_Id">VAR_10-1-2_L1</Item>.

    <Item
name="u-component_of_current_surface#grid_mapping">LatLon_Projection</Item>.

    <Item name="u-component_of_current_surface#long_name">u-component of
current @ Ground or water surface</Item>.
    <Item name="u-component_of_current_surface#missing_value">nan</Item>.
    <Item name="u-component_of_current_surface#units">m/s</Item>.
    <Item name="abbreviation" sample="0">UOGRD</Item>.
    <Item name="coordinates" sample="0">reftime time lat lon </Item>.
    <Item name="Grib2_Generating_Process_Type" sample="0">Forecast</Item>.
    <Item name="Grib2_Level_Type" sample="0">Ground or water
surface</Item>.
    <Item name="Grib2_Parameter" sample="0">{10,1,2}</Item>.
    <Item name="Grib2_Parameter_Category" sample="0">Currents</Item>.
    <Item name="Grib2_Parameter_Discipline" sample="0">Oceanographic
products</Item>.
    <Item name="Grib2_Parameter_Name" sample="0">u-component of
current</Item>.
    <Item name="Grib_Variable_Id" sample="0">VAR_10-1-2_L1</Item>.
    <Item name="grid_mapping" sample="0">LatLon_Projection</Item>.
    <Item name="long_name" sample="0">u-component of current @ Ground or
water surface</Item>.
    <Item name="missing_value" sample="0">nan</Item>.
    <Item name="NETCDF_DIM_time" sample="0">3</Item>.
    <Item name="NETCDF_VARNAME"
sample="0">u-component_of_current_surface</Item>.
    <Item name="units" sample="0">m/s</Item>.
    <Item name="UNITTYPE" sample="0" role="unittype">m/s</Item>.
</GDALMetadata>

The periods at the end of the line are not valid, not sure where they are
coming from, exiftool reports them out
of one tiff file I have handy, which was converted out of a grib file a few
years ago

Cheers
Andrea

== GeoServer Professional Services from the experts! Visit
http://goo.gl/it488V for more information. == Ing. Andrea Aime @geowolf
Technical Lead GeoSolutions S.A.S. Via di Montramito 3/A 55054 Massarosa
(LU) phone: +39 0584 962313 fax: +39 0584 1660272 mob: +39 339 8844549
http://www.geo-solutions.it http://twitter.com/geosolutions_it
------------------------------------------------------- *Con riferimento
alla normativa sul trattamento dei dati personali (Reg. UE 2016/679 -
Regolamento generale sulla protezione dei dati “GDPR”), si precisa che ogni
circostanza inerente alla presente email (il suo contenuto, gli eventuali
allegati, etc.) è un dato la cui conoscenza è riservata al/i solo/i
destinatario/i indicati dallo scrivente. Se il messaggio Le è giunto per
errore, è tenuta/o a cancellarlo, ogni altra operazione è illecita. Le
sarei comunque grato se potesse darmene notizia. This email is intended
only for the person or entity to which it is addressed and may contain
information that is privileged, confidential or otherwise protected from
disclosure. We remind that - as provided by European Regulation 2016/679
“GDPR” - copying, dissemination or use of this e-mail or the information
herein by anyone other than the intended recipient is prohibited. If you
have received this email by mistake, please notify us immediately by
telephone or e-mail.*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20190527/4c90c3cd/attachment.html>


More information about the gdal-dev mailing list