model2netcdf.SIPNETtakesLAIfrom sipnet.out if present (which requires Sipnet > v2.2). If it is not present, LAI is calculated asplantLeafC / leafCSpWtas previously.split_inputs.SIPNETnow avoids internal time format conversions, giving a substantial speedup and reduced memory use when processing multi-year files.model2netcdf.SIPNETnow detects the number of timesteps per day by taking the maximum count across all days in the first simulation year, rather than reading only from day 1. This prevents a factor-of-N error in flux unit conversions when the first day of output is partial (fewer timesteps than a complete day) (#3624, #3989).- Fixed a unit error in model2netcdf.SIPNET's calculation of
GWBI(kgC/m2/sec) fromwoodCreation(actually gC/m2/timestep, was being treated as gC/m2/day). model2netcdf.SIPNETnow takes NPP directly from sipnet.out rather than repeat Sipnet's internal calculation (as GPP - Ra) with identical results.- Updated README with a more complete model description and instructions for installing SIPNET (#3705)
- Removed
tests/Rcheck_reference.log, which was used to ignore historic check messages that have now been fixed. - Initial support for SIPNET v2.0, whose features include simplified input files, simulation of management events, tracking of N cycle components, flooded soils, and anaerobic CH4 generation.
- Breaking:
met2model.SIPNETnow writes 12-column clim files (as expected by Sipnet >= v2.0) by default. To get the previously standard 14-column output, setclim_format_version = "v1". - NITROGEN_CYCLE, LITTER_POOL, and ANAEROBIC enabled by default for SIPNET v2 runs.
model2netcdf.SIPNETnow handles both V1 and v2 output header format (v2 has no Notes line; SIPNET #267).- Removed 13 obsolete v1 parameters from the v2 parameter template
template.param_v2(microbeInit, qualityLeaf, etc.) and added 16 new nitrogen cycle, anaerobic, and methane parameters. - Added nitrogen cycle (mineral_N, soil_organic_N, litter_N, N2O, N leaching, N fixation,
N uptake) and methane (CH4) output conversion to NetCDF in
model2netcdf.SIPNET. - Fixed crash when
litterWatercolumn absent in v2 output (LITTER_WATER removed in v2). write.config.SIPNETnow validates runtime flag dependencies (NITROGEN_CYCLE requires LITTER_POOL and ANAEROBIC) and guards v1 only parameters (litterWHC, litWaterDrainRate, litterWFracInit, microbeInit, m_ballBerry) from being set when using v2 templates.- Removed workarounds for column naming bugs in output from long-outdated legacy
Sipnet version
sipnet.unk. - Added trait to parameter mappings for nitrogen cycle parameters in
write.config.SIPNET, including tissue C:N ratios, N volatilization/leaching/resorption, fixation, and methane rates. segment_dataframe()now returns an empty dataframe when date filtering removes all crop-cycle segments, instead of a single row with NA columns that caused downstream segment config errors (#4007).
write.events.SIPNET()generates SIPNETevents.infiles from anevents.jsonfile (#3623).met2model.SIPNETnow accepts argumentvar.names, listing which variables should be extracted from the file. If not provided, it extracts all variables in the file (#3563).
- The
sipnet2datetimefunction is no longer used anywhere and therefore has been removed (#3622).
- Breaking: Renamed the setting used to pass soil and hydrology parameters.
write.config.SIPNETpreviously read these fromsettings$run$inputs$soilinitcond, nowsettings$run$inputs$soil_physicsto better reflect that these are state factors applicable to the whole run rather than initial conditions (Quianyu Li, #3406). - model2netcdf.SIPNET no longer writes separate
<year>.nc.varfiles for every year of output. UsePEcAn.utils::nc_write_varfiles()to create these as needed (#3611). - Restart and met2model functions now print less to the console unless
verbose = TRUE(#3544, #3563).
write.config.SIPNETnow checks more carefully whether an optional variable exists in an initial condition file before trying to read it, therefore printing fewer messages about (expectedly) missing variables (#3545).- When passed a vector of multiple input paths,
write.config.SIPNETwas choosing one at random; it now throws an error (Blesson Thomas, #3298). Note that a single input path per call has always been the intended usage; being passed many was a second bug in PEcAn.uncertainty that is also now fixed. model2netcdf.SIPNETno longer assumes a constant value ofpecan_start_doyacross years, which lead to incorrect calculations ofsub_datesandsub_dates_cfat year boundaries (@DongchenZ, #3622).- When phenology inputs contain missing values,
write.config.SIPNETnow tries to use an average across years for that site before falling back to fixed cross-site defaults (Quianyu Li, #3680). write.config.SIPNETnow adjusts soil water capacity to match the specified soil depth (#3634).- Fixed unit errors in
write.config.SIPNETcalculation ofleafCSpWtandAmax(#3608, #3664).
- PEcAn.SIPNET is now distributed under the BSD three-clause license instead of the NCSA Open Source license.
met2model.SIPNET()now stops with an error if the result contains missing values, which are not allowed in SIPNET inputs (#3474).write.config.SIPNET()now consults PFT trait definitions to decide whether to initialize LAI in the leaf-on or leaf-off state, instead of the previous hard-coded defaults (#3419). Specifically:- a PFT with
fracLeafFall> 0.5 will be treated as deciduous (previously hardcoded to deciduous for anything other than boreal conifers) - deciduous PFTs will get laiInit=0 if the simulation start date is not between
leafOnDayandleafOffDay(previously hardcoded to May through September)
- a PFT with
- The generated Sipnet run script (job.sh) now works correctly, including across machines, when met/input/output files are specified relative to the working directory (#3418). Absolute paths continue to work as always.
- Support for all Sipnet variables in read_restart and write_restart, for integration with state data assimilation workflows
- All changes in 1.7.1 and earlier were recorded in a single file for all of the PEcAn packages; please see https://github.com/PecanProject/pecan/blob/v1.7.1/CHANGELOG.md for details.