Unidata - To provide the data services, tools, and cyberinfrastructure leadership that advance Earth system science, enhance educational opportunities, and broaden participation. Unidata
         
  advanced  
 

Re: Efficiency of NetCDF reading and writing functions.

Tim Hume wrote:

> I was wondering about how efficient the NetCDF reading and writing
> functions are. In particular, it should be possible to use the NetCDF
> functions:
> 
> nc_get_varm_type and
> nc_put_varm_type
> 
> to read and write any arbitrary array of NetCDF data. My question is, is
> it less efficient to use the put/get_varm functions than using one of the
> more "specialised" functions (put_var1, put_var, put_vars, put_vara etc)?

In the C interface, the vars (strided) interfaces are implemented in
terms of the varm (mapped) interfaces, which are implemented using the
vara (array) interfaces.

The mapped interfaces don't offer any significant efficiency
advantages over the more specialized interfaces, but may offer
convenience if they do what you want.  They have not been widely used,
and were not implemented in the newer object-oriented interfaces, such
as for Java and C++.

--Russ

_____________________________________________________________________

Russ Rew                                         UCAR Unidata Program
russ@xxxxxxxxxxxxxxxx                     http://www.unidata.ucar.edu


 
 
  Contact Us     Site Map     Search     Terms and Conditions     Privacy Policy     Participation Policy
 
National Science Foundation (NSF) UCAR Community Programs   Unidata is a member of the UCAR Community Programs, is managed by the University Corporation for Atmospheric Research, and is sponsored by the National Science Foundation.
P.O. Box 3000     Boulder, CO 80307-3000 USA     Tel: 303-497-8643     Fax: 303-497-8690