BES - Modules - The NetCDF Handler

From OPeNDAP Documentation
Revision as of 20:28, 15 September 2011 by Jimg (talk | contribs)
⧼opendap2-jumptonavigation⧽

Kinds of files the handler will serve

There are several versions of the netCDF software for reading and writing data and using those different versions, it's possible to make several different kinds of data files. For the most part, netCDF strives to maintain compatibility so that any older file can be read using any newer version of the library. To ensure that the netCDF handler can read (almost) any valid netCDF data file, you should make sure to use the latest version of the netCDF library when you build or install the handler.

However, as of netCDF 4, there are some new data model components in netCDF that are hard to represent in DAP2 (hence the 'almost' in the preceding paragraph). If the handler, as of version 3.10.x, is linked with netCDF 4.1.x or later, you will be able to read any netCDF file that fits the 'classic' model of netCDF (as defined by documentation) which essentially means any file that uses only data types present in the netCDF 3.x API. In addition, these files can employ both internal compression and chunking.

The new data types present in the netCDF data model present more of a challenge. However, as of version 3.10.x, the Hyrax data handler will serve most of the new cardinal types and the more commonly used 'user defined types'.

Mappings between NetCDF version 4 data model and DAP2 data types

All of the cardinal types in the netCDF 4 data model map directly to types in DAP2 except for the following:

NC_BYTE
There is no 'signed byte' type in DAP2 so these map to an unsigned byte.
NC_CHAR
There is no 'character' type in DAP2 so these map to DAP Strings of length one. Arrays of N characters in netCDF map to arrays of N-1 Strings in DAP
NC_INT64 and NC_UINT64
DAP2 does not support 64-bit integers (this will be added soon to the next version of the protocol).

Configuration parameters