...
A model adapter is the interface between a so-called model and the Delft-FEWS system. It enables FEWS to run such a model, thus providing the essential forecasting functionality. For each particular FEWS application applying a model, however, some aspects of this system have to be configured by the user in order for the system to work correctly. To achieve this, it is useful that the user has at least some basic understanding of the relation between Delft-FEWS, the model adapter and the forecasting model. In this section, a brief overview of this relation is provided. For more information, the user is referred to the FEWS manual: General Adapter..
Also make sure to use the following new configuration options that have been added to the FEWS General Adapter recently. Use these options for handling log files and state files and writing placeholder files, so that model adapters do not need to do those things themselves:
- General Adapter Module - parsing log files without using PI diagnostics files
- General Adapter Module - exporting state files without using PI state description files
- General Adapter Module - importing state files without using PI state description files
- General Adapter Module - exporting placeholder NetCDF files that can be filled with data by the model post adapter
NetCDF Files
Since FEWS 2014.01 it is possible to use only NetCDF files (no-xml) for the communication between FEWS and the model adapter. Good libraries for reading and writing NetCDF files exist for several languages. XML files are a lot more complex to read and to write.
- Java: httpshttp://www.unidata.ucar.edu/software/thredds/current/netcdf-java/v4.2/javadoc/documentation.htm
- Fortran: https://www.unidata.ucar.edu/software/netcdf/docs/netcdf-f90/
- python, http://unidata.github.io/netcdf4-python/
- R-project http://cran.r-project.org/web/packages/RNetCDF/index.html
- C: http://www.unidata.ucar.edu/software/netcdf/docs/netcdf-c/
- C++: http://www.unidata.ucar.edu/software/netcdf/docs/netcdf-cxx/
NetCDF time series and attributes can be read with just a few lines of source code.
For more information about the NetCDF format in general, see NetCDF formats that can be imported in Delft-FEWS and the links on that page.
Running model adapters within FEWS
...