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
Following the proposed API sketch in PModel API for 2.0.0 #394, the suggestion for PModelEnvironment is that with the new PModel API all of the forcing variables can be set in the PModelEnvironment, so fapar and ppfd are set here. This makes it really easy to switch from standard to subdaily P Models.
Free up the definition of extra variables to the PModelEnvironment. At the moment, downstream methods can require extra variables to calculate a method. The method registry setup makes this easily extendable, but at the moment these extra variables are hardcoded into the PModelEnvironment setup. We should change this to add any variables with the right dimensions via kwargs - this does lose specific variable bounds checking, but that is a relatively small price.
Centralise calculation of tk in PModelEnvironment. Many of the calculations in the PModelEnvironment require scaling factors calculated using temperature in Kelvin. At the moment, all of these functions take temperature in °C and then convert internally. It would be much saner to calculate once when creating a PModelEnvironment instance and then store as an attribute and pass tk to functions not tc.
The text was updated successfully, but these errors were encountered:
A set of linked changes to
PModelEnvironment
PModelEnvironment
is that with the newPModel
API all of the forcing variables can be set in thePModelEnvironment
, sofapar
andppfd
are set here. This makes it really easy to switch from standard to subdaily P Models.PModelEnvironment
. At the moment, downstream methods can require extra variables to calculate a method. The method registry setup makes this easily extendable, but at the moment these extra variables are hardcoded into thePModelEnvironment
setup. We should change this to add any variables with the right dimensions viakwargs
- this does lose specific variable bounds checking, but that is a relatively small price.tk
inPModelEnvironment
. Many of the calculations in the PModelEnvironment require scaling factors calculated using temperature in Kelvin. At the moment, all of these functions take temperature in °C and then convert internally. It would be much saner to calculate once when creating a PModelEnvironment instance and then store as an attribute and passtk
to functions nottc
.The text was updated successfully, but these errors were encountered: