You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Convert netCDF output to user requested units (field "netCDF units" of input file "SW2_netCDF_output_variables.tsv") if compiled against the udunits2 library
The text was updated successfully, but these errors were encountered:
- addressing issue #392
- unit conversion is activated if compiled with `CPPFLAGS='-DSWNETCDF -DSWUDUNITS' make all` (additional flags available to specify paths for udunits2 headers and libraries, see makefile)
- users request output units via field "netCDF units" of input file "SW2_netCDF_output_variables.tsv"; internal units are used if user requested units cannot be converted from internal units
- SOILWAT2 internal units (text string) are stored in the attribute "units_sw" of struct "SW_OUTPUT" for each (netCDF) output variable
- udunits2 unit converters are stored in the attribute "uconv" of struct "SW_OUTPUT" for each (netCDF) output variable
- new SW_NC_create_units_converters() creates udunits2 unit converters from internal units to user requested output units
- SW_NC_write_output() converts units before writing to netCDF output files if a unit converter is available (if no unit converter is available, then output is written using internal units)
- SW_NC_dealloc_outputkey_var_info() de-allocates unit converter memory
Output netCDFs
close#363
* All outputs are written to `"netCDF"` files based on user requests from `"SW2_netCDF_output_variables.tsv"` (#363; @dschlaep, @N1ckP3rsl3y). `"netCDF"` output files combine output variables by output group `"outkey"` and output period (daily, weekly, monthly, yearly).
* New tab-separated value `"tsv"` input file `"SW2_netCDF_output_variables.tsv"` that lists, activates, and describes each output variable in `"netCDF"` mode.
* SOILWAT2 can now be compiled with `"udunits2"` to convert output to user requested units (#392; @dschlaep, @N1ckP3rsl3y).
* Unit conversion is available only in `"netCDF"`-mode and if compiled with the new preprocessor definition `"SWUDUNITS"` and if the `"udunits2"` library is available, e.g., `CPPFLAGS='-DSWNETCDF -DSWUDUNITS' make all`.
* Users request output units via field `"netCDF units"` of the input file `"SW2_netCDF_output_variables.tsv"`.
* The random number generator `"pcg"` is now a submodule of a forked copy of the previous repository `imneme/pcg-c-basic` (#353; @dschlaep). This allowed us to fix a function declaration without a prototype.
Convert netCDF output to user requested units (field "netCDF units" of input file "SW2_netCDF_output_variables.tsv") if compiled against the udunits2 library
The text was updated successfully, but these errors were encountered: