Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Purpose
We have recently refactored the boundary conditions for snow and soil (AtmosDriven...) to include a prognostic_land_component field, and we dispatch off of the Value of that field in order to correctly account for fluxes in the presence of other components in integrated models. This adds this to the canopy model.
To-do
Content
Major changes:
atmos
andradiation
many places in the code.Downstream or minor changes:
CanopyModel
underboundary_conditions
, instead of having each separate fields. This is more in line with how snow and soil hold these quantities. It also now has a field forprognostic_land_components
. We check in the constructor that if typeof(ground) <: PrescribedGroundConditions, the only prognostic component is the canopy. And we check that if it is not Prescribed, soil must also be prognostic.Canopy.ground_albedo_PAR
now take as arguments both the "ground" driver (bc.ground, canopy.soil_driver in the previous main) and the prognostic_land_components. Currently this is primarily for consistency, but in the future (with snow) we may need to dispatch off the of Value of prognostic_land_components (snow, soil vs just soil).prognostic_land_components
. This is also to enforce consistency, but we can relax it if needed?