39 ERRMSG(
"Give parameters: <ctl> <met_in> <met_in_type>"
40 " <met_out> <met_out_type>");
54 if (!
read_met(argv[2], &ctl, clim, met))
55 ERRMSG(
"Cannot open file!");
int main(int argc, char *argv[])
int write_met(const char *filename, ctl_t *ctl, met_t *met)
Writes meteorological data to a binary file.
void read_clim(ctl_t *ctl, clim_t *clim)
Reads various climatological data and populates the given climatology structure.
void read_ctl(const char *filename, int argc, char *argv[], ctl_t *ctl)
Reads control parameters from a configuration file and populates the given structure.
int read_met(const char *filename, ctl_t *ctl, clim_t *clim, met_t *met)
Reads meteorological data from a file and populates the provided structures.
MPTRAC library declarations.
#define ERRMSG(...)
Print an error message with contextual information and terminate the program.
#define ALLOC(ptr, type, n)
Allocate memory for a pointer with error handling.
int met_type
Type of meteo data files (0=netCDF, 1=binary, 2=pck, 3=zfp, 4=zstd, 5=cms).