As you can see from the NEWS file, there have been significant changes in fimex 1.0 compared to previous versions. Most of the changes affect the C++ code, but there are also some changes affecting the commandline programs.
The conversion from text to numbers has become more strict. While text
after numbers had previously been ignored sometimes (sometimes not),
now the text may not contain anything else but the number. In
particular, f
or L
suffixes that had previously been ignored in
GRIB reader configuration files will cause errors in fimex 1.0.
Using a command like
find . -name "*ml" | xargs -r sed -i -e 's,\([0-9]\+\)[fL]",\1",g'
on the configuration files should do most of the work, but the original files should be backed up before starting these automatic changes, and the result should be checked before use.
As part of the transition to std::regex
, the regex format has
changed slightly. They are no longer 'perl' format but 'modified
ECMAscript', the default in C++11. This may affect a few configuration
files when using rather advanced regular expressions.
The data types 'string' and 'byte' are now treated separately.
Compression in fiIndexGribs
and fiGribCut
is no longer
supported. The fiIndexGribs
command line has changed in version 1.0
to make it more clear which file is written or appended to.
Previously, options specified in a file could be overwritten on the command line. This is now rejected (by the mi-programoptions library). Adding back this feature requires major changes in mi-programoptions, therefore it might not come back. There are some other subtle changes in reading options from files.
Boost was removed from fimex 1.0 C++ code in favour of C++11 and some small helper libraries. This requires changes in C++ code using fimex:
boost::shared_ptr
is replaced bystd::shared_ptr
boost::shared_array
is replaced byMetNoFimex::shared_array
(this is a wrapper aroundstd::shared_ptr
with an array deleter and index access, asstd::shared_ptr
does not support arrays in C++11)- many typedefs have been changed. Except for
DataPtr
, all of them should now be named<Class>_p
forstd::shared_ptr<Class>
and<Class>_cp
forstd::shared_ptr<const Class>
. Nested typedefs have been removed. fimex/Utils.h
has been split up into several filesfimex/...Utils.h
by topic- all times returned by the fimex library are
FimexTime
objects. There are conversion functions forstd::chrono
(infimex/TimeUtils.h
) and forboost::posix_time
infimex/boost-posix-time-compat.h
(untested). - some deprecated functions have been removed
CDMFileReaderFactory
only supports strings to identify file types ('netcdf'). The filetype constants infimex/CDMconstants.h
have been removed.
The python binding has been improved and extended very much in fimex
1.0. In particular, data are usually not copied any more between
python and C++, instead pointers are used. It is now also possible to
implement a CDMReader
subclass in python and to pass that to C++
code for writing, interpolation, etc.