API documentation for the model_config module#

The core.model_config module contains pydantic models defining the configuration settings required for the Core model in a Virtual Ecosystem simulation.

Classes:

CoreConfiguration(*[, constants, grid, ...])

The core model configuration.

CoreConstants(*[, standard_pressure, ...])

Core constants for use across the Virtual Ecosystem modules.

DataConfiguration(*[, variable])

Data configuration.

DataOutputConfiguration(*[, ...])

Output settings for the Virtual Ecosystem model state.

DataSource(*[, file_path, var_name])

Data source configuration.

DebugConfiguration(*[, truncate_run_at_update])

Debugging options.

GridConfiguration(*[, grid_type, cell_area, ...])

Grid configuration.

LayersConfiguration(*[, soil_layers, ...])

Settings for the simulation vertical structure.

PyrealmConfig(*[, core, pmodel])

Configuration class for pyrealm constant dataclasses.

TimingConfiguration(*[, start_date, ...])

Configuration of the model timing.

class virtual_ecosystem.core.model_config.CoreConfiguration(*, constants: CoreConstants = CoreConstants(standard_pressure=101.325, standard_mole=44.642, molar_heat_capacity_air=29.19, gravity=6.6743e-11, boltzmann_constant=1.380649e-23, stefan_boltzmann_constant=5.6703744191844314e-08, von_karmans_constant=0.4, max_depth_of_microbial_activity=0.25, meters_to_mm=1000.0, mm_to_kg=0.001, molecular_weight_air=28.96, gas_constant_water_vapour=461.51, seconds_to_day=86400.0, seconds_to_hour=3600.0, hours_per_day=24, characteristic_dimension_leaf=0.01, specific_gas_constant_dry_air=287.05, molecular_weight_ratio_water_to_dry_air=0.622, conductance_to_resistance_conversion_factor=40.9, density_water=1000.0, fungal_fruiting_bodies_c_n_ratio=10.0, fungal_fruiting_bodies_c_p_ratio=75.0, fungal_fruiting_bodies_decay_rate=np.float64(0.013862943611198907), air_volumetric_heat_capacity=1200.0, initial_aerodynamic_resistance_canopy=12.1), grid: GridConfiguration = GridConfiguration(grid_type='square', cell_area=8100.0, cell_nx=9, cell_ny=9, xoff=-45.0, yoff=-45.0), data_output_options: DataOutputConfiguration = DataOutputConfiguration(save_initial_state=False, save_continuous_data=True, save_final_state=True, save_merged_config=True, out_path=PosixPath('<DIRPATH_PLACEHOLDER>'), out_initial_file_name='initial_state.nc', out_folder_continuous='.', out_continuous_file_name='all_continuous_data.nc', out_final_file_name='final_state.nc', out_merge_file_name='ve_full_model_configuration.toml'), layers: LayersConfiguration = LayersConfiguration(soil_layers=[-0.25, -1.0], canopy_layers=10, above_canopy_height_offset=2.0, subcanopy_layer_height=1.5, surface_layer_height=0.1), timing: TimingConfiguration = TimingConfiguration(start_date=datetime.date(2013, 1, 1), update_interval='1 month', run_length='2 years'), data: DataConfiguration = DataConfiguration(variable=(DataSource(file_path=PosixPath('<FILEPATH_PLACEHOLDER>'), var_name='variable_name_placeholder_one'), DataSource(file_path=PosixPath('<FILEPATH_PLACEHOLDER>'), var_name='variable_name_placeholder_two'))), debug: DebugConfiguration = DebugConfiguration(truncate_run_at_update=-1), pyrealm: PyrealmConfig = PyrealmConfig(core=CoreConst(k_R=8.3145, k_co=209476.0, k_c_molmass=12.0107, k_water_molmass=18.01258, k_Po=101325.0, k_To=298.15, k_L=0.0065, k_G=9.80665, k_Ma=0.028963, k_Mv=0.01802, k_CtoK=273.15, visible_light_albedo=0.03, swdown_to_ppfd_factor=2.04, transmissivity_coef=(0.25, 0.5, 2.67e-05), net_longwave_radiation_coef=(0.2, 107.0), shortwave_albedo=0.17, solar_constant=1360.8, day_seconds=86400, equation_of_time_coef=(7.5e-05, 0.001868, -0.032077, -0.014615, -0.04089, 229.18), solar_eccentricity=0.0167, solar_obliquity=23.44, solar_perihelion=283.0, magnus_coef=array([611.2, 17.62, 243.12]), mwr=0.622, magnus_option=None, water_density_method='fisher', fisher_dial_lambda=array([1.788316e+03, 2.155053e+01, -4.695911e-01, 3.096363e-03, -7.341182e-06]), fisher_dial_Po=array([5.9184990e+03, 5.8052670e+01, -1.1253317e+00, 6.6123869e-03, -1.4661625e-05]), fisher_dial_Vinf=array([6.980547e-01, -7.435626e-04, 3.704258e-05, -6.315724e-07, 9.829576e-09, -1.197269e-10, 1.005461e-12, -5.437898e-15, 1.699460e-17, -2.295063e-20]), chen_po=array([9.9983952e-01, 6.7882600e-05, -9.0865900e-06, 1.0221300e-07, -1.3543900e-09, 1.4711500e-11, -1.1166300e-13, 5.0440700e-16, -1.0065900e-18]), chen_ko=array([1.965217e+04, 1.481830e+02, -2.299950e+00, 1.281000e-02, -4.915640e-05, 1.035530e-07]), chen_ca=array([3.26138e+00, 5.22300e-04, 1.32400e-04, -7.65500e-07, 8.58400e-10]), chen_cb=array([7.2061e-05, -5.8948e-06, 8.6990e-08, -1.0100e-09, 4.3220e-12]), simple_viscosity=False, huber_tk_ast=647.096, huber_rho_ast=322.0, huber_mu_ast=1e-06, huber_H_i=array([1.67752, 2.20462, 0.6366564, -0.241605]), huber_H_ij=array([[5.20094e-01, 8.50895e-02, -1.08374e+00, -2.89555e-01, 0.00000e+00, 0.00000e+00], [2.22531e-01, 9.99115e-01, 1.88797e+00, 1.26613e+00, 0.00000e+00, 1.20573e-01], [-2.81378e-01, -9.06851e-01, -7.72479e-01, -4.89837e-01, -2.57040e-01, 0.00000e+00], [1.61913e-01, 2.57399e-01, 0.00000e+00, 0.00000e+00, 0.00000e+00, 0.00000e+00], [-3.25372e-02, 0.00000e+00, 0.00000e+00, 6.98452e-02, 0.00000e+00, 0.00000e+00], [0.00000e+00, 0.00000e+00, 0.00000e+00, 0.00000e+00, 8.72102e-03, 0.00000e+00], [0.00000e+00, 0.00000e+00, 0.00000e+00, -4.35673e-03, 0.00000e+00, -5.93264e-04]])), pmodel=PModelConst(sandoval_peak_phio=(6.8681, 0.07956432), sandoval_kinetics={'entropy_intercept': 1558.853, 'entropy_slope': -50.223, 'ha': 75000.0, 'hd': 294.804}, tc_ref=25.0, tk_ref=298.15, heskel_rd=(0.1012, 0.0005), arrhenius_vcmax={'simple': {'ha': 65330}, 'kattge_knorr': {'entropy_intercept': 668.39, 'entropy_slope': -1.07, 'ha': 71513, 'hd': 200000}}, arrhenius_jmax={'simple': {'ha': 43900}, 'kattge_knorr': {'entropy_intercept': 659.7, 'entropy_slope': -0.75, 'ha': 49884, 'hd': 200000}}, kphio_C4=(-0.064, 0.03, -0.000464), kphio_C3=(0.352, 0.022, -0.00034), bernacchi_kmm={'dhac': 79430.0, 'dhao': 36380.0, 'kc25': 39.97, 'ko25': 27480.0}, maximum_phi0=0.125, bernacchi_gs={'dha': 37830.0, 'gs25_0': 4.332}, soilmstress_stocker={'theta0': 0, 'thetastar': 0.6, 'a': 0.0, 'b': 0.733}, soilmstress_mengoli={'psi_a': 0.34, 'psi_b': -0.6, 'y_a': 0.62, 'y_b': -0.45}, beta_cost_ratio_c3=array([146.]), beta_cost_ratio_c4=array([16.22222222]), lavergne_2020_c3=(4.55, 1.73), lavergne_2020_c4=(np.float64(2.3527754226637803), 1.73), wang17_c=0.41, smith19_coef=(0.85, 0.05336251))))[source]#

The core model configuration.

Attributes:

constants

Constants for the core module

data

Configuration of the input variables and data sources.

data_output_options

Configuration of the output of the Virtual Ecosystem model state

debug

Configuration of debugging options.

grid

Configuration of the spatial grid

layers

Configuration of the layers in the vertical structure

pyrealm

Constant dataclasses for the pyrealm package.

timing

Configuration of the model run and step lengths

constants: CoreConstants#

Constants for the core module

data: DataConfiguration#

Configuration of the input variables and data sources.

data_output_options: DataOutputConfiguration#

Configuration of the output of the Virtual Ecosystem model state

debug: DebugConfiguration#

Configuration of debugging options.

grid: GridConfiguration#

Configuration of the spatial grid

layers: LayersConfiguration#

Configuration of the layers in the vertical structure

pyrealm: PyrealmConfig#

Constant dataclasses for the pyrealm package.

At present, the pyrealm configuration settings are excluded from model serialisation because of issues with serialising numpy arrays. This is a problem for replicating simulations where these settings have been altered.

timing: TimingConfiguration#

Configuration of the model run and step lengths

class virtual_ecosystem.core.model_config.CoreConstants(*, standard_pressure: float = 101.325, standard_mole: float = 44.642, molar_heat_capacity_air: float = 29.19, gravity: float = 6.6743e-11, boltzmann_constant: float = 1.380649e-23, stefan_boltzmann_constant: float = 5.6703744191844314e-08, von_karmans_constant: float = 0.4, max_depth_of_microbial_activity: float = 0.25, meters_to_mm: float = 1000.0, mm_to_kg: float = 0.001, molecular_weight_air: float = 28.96, gas_constant_water_vapour: float = 461.51, seconds_to_day: float = 86400.0, seconds_to_hour: float = 3600.0, hours_per_day: int = 24, characteristic_dimension_leaf: float = 0.01, specific_gas_constant_dry_air: float = 287.05, molecular_weight_ratio_water_to_dry_air: float = 0.622, conductance_to_resistance_conversion_factor: float = 40.9, density_water: float = 1000.0, fungal_fruiting_bodies_c_n_ratio: float = 10.0, fungal_fruiting_bodies_c_p_ratio: float = 75.0, fungal_fruiting_bodies_decay_rate: float = np.float64(0.013862943611198907), air_volumetric_heat_capacity: float = 1200.0, initial_aerodynamic_resistance_canopy: float = 12.1)[source]#

Core constants for use across the Virtual Ecosystem modules.

An instance of the CoreConstants dataclass provides definitions of the core constants used across an entire simulation. The core constants can be changed, as shown below, although for many this would likely generate nonsensical results.

Example

>>> consts = CoreConstants()
>>> consts.max_depth_of_microbial_activity
0.25
>>> consts = CoreConstants(max_depth_of_microbial_activity=0.75)
>>> consts.max_depth_of_microbial_activity
0.75

Attributes:

air_volumetric_heat_capacity

Volumetric heat capacity of air at constant pressure, [J m-3 K-1].

boltzmann_constant

The Boltzmann constant, [J K-1]

characteristic_dimension_leaf

Characteristic dimension of leaf, typically around 0.7 * leaf width, [m].

conductance_to_resistance_conversion_factor

Conductance to resistance conversion factor.

density_water

Density of water, [kg m-3].

fungal_fruiting_bodies_c_n_ratio

Carbon to nitrogen ratio of fungal fruiting bodies, [unitless].

fungal_fruiting_bodies_c_p_ratio

Carbon to phosphorus ratio of fungal fruiting bodies, [unitless].

fungal_fruiting_bodies_decay_rate

Rate constant for the decay of fungal fruiting bodies, [day^-1].

gas_constant_water_vapour

Gas constant for water vapour, [J kg-1 K-1]

gravity

Newtonian constant of gravitation, [m s-1].

hours_per_day

Number of hours per day.

initial_aerodynamic_resistance_canopy

Initial aerodynamic resistance of the canopy, [s m-1].

max_depth_of_microbial_activity

Maximum depth of microbial activity in the soil layers [m].

meters_to_mm

Factor to convert variable unit from meters to millimeters.

mm_to_kg

Factor to convert variable unit from millimeters to kilograms of water per square metre.

molar_heat_capacity_air

Molar heat capacity of air, [J mol-1 K-1].

molecular_weight_air

Molecular weight of air, [g mol-1].

molecular_weight_ratio_water_to_dry_air

The molecular weight ratio of water to dry air.

seconds_to_day

Factor to convert variable unit from seconds to day.

seconds_to_hour

Factor to convert variable unit from seconds to hours.

specific_gas_constant_dry_air

Specific gas constant for dry air, [J kg-1 K-1].

standard_mole

Moles of ideal gas in 1 m^3 air at standard atmosphere.

standard_pressure

Standard atmospheric pressure, [kPa]

stefan_boltzmann_constant

Stefan-Boltzmann constant, [W m-2 K-4].

von_karmans_constant

Von Karman's constant, [unitless].

zero_Celsius

Conversion constant from Kelvin to Celsius (°).

air_volumetric_heat_capacity: float#

Volumetric heat capacity of air at constant pressure, [J m-3 K-1].

This represents the amount of heat energy required to raise the temperature of one cubic meter of air by 1 Kelvin.

boltzmann_constant: float#

The Boltzmann constant, [J K-1]

characteristic_dimension_leaf: float#

Characteristic dimension of leaf, typically around 0.7 * leaf width, [m].

conductance_to_resistance_conversion_factor: float#

Conductance to resistance conversion factor.

This factor is used to convert between stomatal conductance in mmol m-2 s-1 and stomatal resistance in s m-1.

density_water: float#

Density of water, [kg m-3].

fungal_fruiting_bodies_c_n_ratio: float#

Carbon to nitrogen ratio of fungal fruiting bodies, [unitless].

This constant is stored in the CoreConsts as it is used by both the animal model (to work out consumption flows) and the soil model (to work out production rates). The current default value is very much a guess.

fungal_fruiting_bodies_c_p_ratio: float#

Carbon to phosphorus ratio of fungal fruiting bodies, [unitless].

This constant is stored in the CoreConsts as it is used by both the animal model (to work out consumption flows) and the soil model (to work out production rates). The current default value is very much a guess.

fungal_fruiting_bodies_decay_rate: float#

Rate constant for the decay of fungal fruiting bodies, [day^-1].

This is calculated based on the assumption that fungal fruiting bodies decay with a half-life of 50 days. This estimate should be improved based on empirical data.

gas_constant_water_vapour: float#

Gas constant for water vapour, [J kg-1 K-1]

gravity: float#

Newtonian constant of gravitation, [m s-1].

hours_per_day: int#

Number of hours per day.

initial_aerodynamic_resistance_canopy: float#

Initial aerodynamic resistance of the canopy, [s m-1].

This parameter is an initial estimate of the resistance to the transfer of momentum, heat, and water vapour between the leaf surface and the atmosphere. The value is based on Australian evergreen forest, taken from Su et al. (2021); note that this assumes a dense canopy.

max_depth_of_microbial_activity: float#

Maximum depth of microbial activity in the soil layers [m].

The soil model needs to identify which of the configured soil layers are sufficiently close to the surface to contain significant microbial activity that drives nutrient processes. The default value is taken from Fatichi et al. (2019). No empirical source is provided for this value.

meters_to_mm: float#

Factor to convert variable unit from meters to millimeters.

mm_to_kg: float#

Factor to convert variable unit from millimeters to kilograms of water per square metre.

molar_heat_capacity_air: float#

Molar heat capacity of air, [J mol-1 K-1].

molecular_weight_air: float#

Molecular weight of air, [g mol-1].

molecular_weight_ratio_water_to_dry_air: float#

The molecular weight ratio of water to dry air.

The ratio of the molar mass of water vapour (18.015 g/mol) to the molar mass of dry air (28.964 g/mol), which is approximately 0.622. This ratio is used in atmospheric calculations, particularly in determining the mixing ratio of water vapour to dry air.

seconds_to_day: float#

Factor to convert variable unit from seconds to day.

seconds_to_hour: float#

Factor to convert variable unit from seconds to hours.

specific_gas_constant_dry_air: float#

Specific gas constant for dry air, [J kg-1 K-1].

standard_mole: float#

Moles of ideal gas in 1 m^3 air at standard atmosphere.

standard_pressure: float#

Standard atmospheric pressure, [kPa]

stefan_boltzmann_constant: float#

Stefan-Boltzmann constant, [W m-2 K-4].

The Stefan-Boltzmann constant relates the energy radiated by a black body to its temperature.

von_karmans_constant: float#

Von Karman’s constant, [unitless].

The von Karman’s constant describes the logarithmic velocity profile of a turbulent fluid near a no-slip boundary.

zero_Celsius: ClassVar[float] = 273.15#

Conversion constant from Kelvin to Celsius (°).

class virtual_ecosystem.core.model_config.DataConfiguration(*, variable: tuple[DataSource, ...] = (DataSource(file_path=PosixPath('<FILEPATH_PLACEHOLDER>'), var_name='variable_name_placeholder_one'), DataSource(file_path=PosixPath('<FILEPATH_PLACEHOLDER>'), var_name='variable_name_placeholder_two')))[source]#

Data configuration.

class virtual_ecosystem.core.model_config.DataOutputConfiguration(*, save_initial_state: bool = False, save_continuous_data: bool = True, save_final_state: bool = True, save_merged_config: bool = True, out_path: Annotated[Path, PathType(path_type=dir), BeforeValidator(func=placeholder_validator, json_schema_input_type=PydanticUndefined)] = PosixPath('<DIRPATH_PLACEHOLDER>'), out_initial_file_name: str = 'initial_state.nc', out_folder_continuous: str = '.', out_continuous_file_name: str = 'all_continuous_data.nc', out_final_file_name: str = 'final_state.nc', out_merge_file_name: str = 've_full_model_configuration.toml')[source]#

Output settings for the Virtual Ecosystem model state.

TODO - this is very confusingly named and structure - restructure and add class validation.

Attributes:

out_continuous_file_name

Name of file to save combined continuous data to

out_final_file_name

File name for final state output file

out_folder_continuous

Folder to save states of simulation with time to

out_initial_file_name

File name for initial state output file

out_merge_file_name

Name for TOML file containing merged configs

out_path

Directory path for output files

save_continuous_data

Whether continuous data should be saved

save_final_state

Whether the final state should be saved

save_initial_state

Whether the initial state should be saved

save_merged_config

Whether to save a merged TOML file containing all config options

out_continuous_file_name: str#

Name of file to save combined continuous data to

out_final_file_name: str#

File name for final state output file

out_folder_continuous: str#

Folder to save states of simulation with time to

out_initial_file_name: str#

File name for initial state output file

out_merge_file_name: str#

Name for TOML file containing merged configs

out_path: DIRPATH_PLACEHOLDER#

Directory path for output files

save_continuous_data: bool#

Whether continuous data should be saved

save_final_state: bool#

Whether the final state should be saved

save_initial_state: bool#

Whether the initial state should be saved

save_merged_config: bool#

Whether to save a merged TOML file containing all config options

class virtual_ecosystem.core.model_config.DataSource(*, file_path: Annotated[Path, PathType(path_type=file), BeforeValidator(func=placeholder_validator, json_schema_input_type=PydanticUndefined)] = PosixPath('<FILEPATH_PLACEHOLDER>'), var_name: str = 'variable_name_placeholder')[source]#

Data source configuration.

class virtual_ecosystem.core.model_config.DebugConfiguration(*, truncate_run_at_update: int = -1)[source]#

Debugging options.

Attributes:

truncate_run_at_update

This option can be used to exit a simulation at a particular update index.

truncate_run_at_update: int#

This option can be used to exit a simulation at a particular update index. This can be useful for testing settings on a model and dataset without having to create a specific temporal subset. If the value is less than 1, then no truncation occurs.

class virtual_ecosystem.core.model_config.GridConfiguration(*, grid_type: str = 'square', cell_area: Annotated[float, Gt(gt=0)] = 8100.0, cell_nx: Annotated[int, Gt(gt=0)] = 9, cell_ny: Annotated[int, Gt(gt=0)] = 9, xoff: float = -45.0, yoff: float = -45.0)[source]#

Grid configuration.

This configuration model sets the size and shape of grid cells within the simulation and then the number of cells in the X and Y directions and their locations in space.

Attributes:

cell_area

The area of each grid cell (m^2)

cell_nx

Number of grid cells in x direction

cell_ny

Number of grid cells in y direction

grid_type

The grid cell type.

xoff

The x offset of the grid origin

yoff

The x offset of the grid origin

cell_area: PositiveFloat#

The area of each grid cell (m^2)

cell_nx: PositiveInt#

Number of grid cells in x direction

cell_ny: PositiveInt#

Number of grid cells in y direction

grid_type: str#

The grid cell type. The value must be one of the options supported by the GRID_REGISTRY.

xoff: float#

The x offset of the grid origin

yoff: float#

The x offset of the grid origin

class virtual_ecosystem.core.model_config.LayersConfiguration(*, soil_layers: Annotated[list[Annotated[float, Lt(lt=0)]], MinLen(min_length=1)] = [-0.25, -1.0], canopy_layers: Annotated[int, Gt(gt=0)] = 10, above_canopy_height_offset: Annotated[float, _PydanticGeneralMetadata(allow_inf_nan=False), Gt(gt=0)] = 2.0, subcanopy_layer_height: Annotated[float, _PydanticGeneralMetadata(allow_inf_nan=False), Gt(gt=0)] = 1.5, surface_layer_height: Annotated[float, _PydanticGeneralMetadata(allow_inf_nan=False), Gt(gt=0)] = 0.1)[source]#

Settings for the simulation vertical structure.

Attributes:

above_canopy_height_offset

A height offset relative to the canopy top that is used as the measurement height of reference climate data.

canopy_layers

The maximum number of canopy layers to simulate.

soil_layers

A list of negative float values that provides the depth in metres of the soil horizons to be used in the simulation, hence also setting the number of soil layers and the horizon depth for each layer relative to the surface.

subcanopy_layer_height

The height above ground level of the ground surface atmospheric layer, used to calculate subcanopy microclimate conditions (metres).

surface_layer_height

The height above ground level of the ground surface atmospheric layer (metres).

above_canopy_height_offset: PositiveFloat#

A height offset relative to the canopy top that is used as the measurement height of reference climate data. It sets the the height above the canopy top of the first layer role above (metres).

canopy_layers: PositiveInt#

The maximum number of canopy layers to simulate. This is used to control the number of layers with the canopy role. Not all of these layers necessarily contain canopy during a simulation as the canopy structure within these layers is dynamic.

soil_layers: list[NegativeFloat]#

A list of negative float values that provides the depth in metres of the soil horizons to be used in the simulation, hence also setting the number of soil layers and the horizon depth for each layer relative to the surface. The values must be unique and strictly decreasing.

subcanopy_layer_height: PositiveFloat#

The height above ground level of the ground surface atmospheric layer, used to calculate subcanopy microclimate conditions (metres).

surface_layer_height: PositiveFloat#

The height above ground level of the ground surface atmospheric layer (metres).

class virtual_ecosystem.core.model_config.PyrealmConfig(*, core: CoreConst = CoreConst(k_R=8.3145, k_co=209476.0, k_c_molmass=12.0107, k_water_molmass=18.01258, k_Po=101325.0, k_To=298.15, k_L=0.0065, k_G=9.80665, k_Ma=0.028963, k_Mv=0.01802, k_CtoK=273.15, visible_light_albedo=0.03, swdown_to_ppfd_factor=2.04, transmissivity_coef=(0.25, 0.5, 2.67e-05), net_longwave_radiation_coef=(0.2, 107.0), shortwave_albedo=0.17, solar_constant=1360.8, day_seconds=86400, equation_of_time_coef=(7.5e-05, 0.001868, -0.032077, -0.014615, -0.04089, 229.18), solar_eccentricity=0.0167, solar_obliquity=23.44, solar_perihelion=283.0, magnus_coef=array([611.2, 17.62, 243.12]), mwr=0.622, magnus_option=None, water_density_method='fisher', fisher_dial_lambda=array([1.788316e+03, 2.155053e+01, -4.695911e-01, 3.096363e-03, -7.341182e-06]), fisher_dial_Po=array([5.9184990e+03, 5.8052670e+01, -1.1253317e+00, 6.6123869e-03, -1.4661625e-05]), fisher_dial_Vinf=array([6.980547e-01, -7.435626e-04, 3.704258e-05, -6.315724e-07, 9.829576e-09, -1.197269e-10, 1.005461e-12, -5.437898e-15, 1.699460e-17, -2.295063e-20]), chen_po=array([9.9983952e-01, 6.7882600e-05, -9.0865900e-06, 1.0221300e-07, -1.3543900e-09, 1.4711500e-11, -1.1166300e-13, 5.0440700e-16, -1.0065900e-18]), chen_ko=array([1.965217e+04, 1.481830e+02, -2.299950e+00, 1.281000e-02, -4.915640e-05, 1.035530e-07]), chen_ca=array([3.26138e+00, 5.22300e-04, 1.32400e-04, -7.65500e-07, 8.58400e-10]), chen_cb=array([7.2061e-05, -5.8948e-06, 8.6990e-08, -1.0100e-09, 4.3220e-12]), simple_viscosity=False, huber_tk_ast=647.096, huber_rho_ast=322.0, huber_mu_ast=1e-06, huber_H_i=array([1.67752, 2.20462, 0.6366564, -0.241605]), huber_H_ij=array([[5.20094e-01, 8.50895e-02, -1.08374e+00, -2.89555e-01, 0.00000e+00, 0.00000e+00], [2.22531e-01, 9.99115e-01, 1.88797e+00, 1.26613e+00, 0.00000e+00, 1.20573e-01], [-2.81378e-01, -9.06851e-01, -7.72479e-01, -4.89837e-01, -2.57040e-01, 0.00000e+00], [1.61913e-01, 2.57399e-01, 0.00000e+00, 0.00000e+00, 0.00000e+00, 0.00000e+00], [-3.25372e-02, 0.00000e+00, 0.00000e+00, 6.98452e-02, 0.00000e+00, 0.00000e+00], [0.00000e+00, 0.00000e+00, 0.00000e+00, 0.00000e+00, 8.72102e-03, 0.00000e+00], [0.00000e+00, 0.00000e+00, 0.00000e+00, -4.35673e-03, 0.00000e+00, -5.93264e-04]])), pmodel: PModelConst = PModelConst(sandoval_peak_phio=(6.8681, 0.07956432), sandoval_kinetics={'entropy_intercept': 1558.853, 'entropy_slope': -50.223, 'ha': 75000.0, 'hd': 294.804}, tc_ref=25.0, tk_ref=298.15, heskel_rd=(0.1012, 0.0005), arrhenius_vcmax={'simple': {'ha': 65330}, 'kattge_knorr': {'entropy_intercept': 668.39, 'entropy_slope': -1.07, 'ha': 71513, 'hd': 200000}}, arrhenius_jmax={'simple': {'ha': 43900}, 'kattge_knorr': {'entropy_intercept': 659.7, 'entropy_slope': -0.75, 'ha': 49884, 'hd': 200000}}, kphio_C4=(-0.064, 0.03, -0.000464), kphio_C3=(0.352, 0.022, -0.00034), bernacchi_kmm={'dhac': 79430.0, 'dhao': 36380.0, 'kc25': 39.97, 'ko25': 27480.0}, maximum_phi0=0.125, bernacchi_gs={'dha': 37830.0, 'gs25_0': 4.332}, soilmstress_stocker={'theta0': 0, 'thetastar': 0.6, 'a': 0.0, 'b': 0.733}, soilmstress_mengoli={'psi_a': 0.34, 'psi_b': -0.6, 'y_a': 0.62, 'y_b': -0.45}, beta_cost_ratio_c3=array([146.]), beta_cost_ratio_c4=array([16.22222222]), lavergne_2020_c3=(4.55, 1.73), lavergne_2020_c4=(np.float64(2.3527754226637803), 1.73), wang17_c=0.41, smith19_coef=(0.85, 0.05336251)))[source]#

Configuration class for pyrealm constant dataclasses.

These dataclasses are not pydantic models and so we permit arbitrary types.

Attributes:

core

Core pyrealm constants

pmodel

Pyrealm constants for the PModel.

core: CoreConst#

Core pyrealm constants

pmodel: PModelConst#

Pyrealm constants for the PModel.

class virtual_ecosystem.core.model_config.TimingConfiguration(*, start_date: date = datetime.date(2013, 1, 1), update_interval: str = '1 month', run_length: str = '2 years')[source]#

Configuration of the model timing.

This configuration section sets the model start data, update length and run time. The update length and run time are provided as a text string that will be automatically parsed to give a total time in seconds.

Attributes:

run_length

The total run length of the simulation.

run_length_seconds

Run length in seconds.

start_date

The simulation start date.

update_interval

The interval at which all models are updated.

update_interval_seconds

Interval update length in seconds.

run_length: str#

The total run length of the simulation.

property run_length_seconds: float[source]#

Run length in seconds.

start_date: date#

The simulation start date.

update_interval: str#

The interval at which all models are updated.

property update_interval_seconds: float[source]#

Interval update length in seconds.