legacyapi vs new API feature comparison

legacyapi vs new API feature comparison

In general both API should be comparable in handling netCDF4 files. The legacyapi is more in line with netCDF4-python , whereas the new API aligns to h5py. Still, there are some differences which are outlined in the following table.

feature

legacyapi

new api

type

1D boolean indexer

Variable/Dataset

resize on write

Dimension Variable/Dataset

resize dimension

only current dimension

dimension and all connected variables

Dimension Variable/Dataset

group name

name only

full path

Group

phony_dims

kwarg

kwarg

Dimension

decode_vlen_strings

kwarg

Variable/Dataset

chunk sizes

h5netcdf-style

kwarg

Variable/Dataset

dimension .size

max size dimension and connected variables

size dimension

Dimension

valid netcdf

kwarg

kwarg

Attribute Variable/Dataset

h5py.Empty string attrs

b""

b""

Attribute

endian

Variable/Dataset

track order

File/Group Dataset