-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
488 merge canopy developments from am3 #489
Conversation
…e rest of the model
which is the only place it is used
cable_surface_type_namelist - which will be implemented here as well at a later date
off and ICE density used that has changed as well
ws format
Co-authored-by: Claire Carouge <ccarouge@users.noreply.github.com>
Co-authored-by: Claire Carouge <ccarouge@users.noreply.github.com>
…lopments-from-am3
capitalized as automatically triggers -fpp compilation flag AND every other files is F90 AND every JULES file is F90
CMakeLists.txt
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AM3 implementation of init_wetfac crept in. Although f90 should be
capitalized as automatically triggers -fpp compilation flag AND every
other files is F90 AND every JULES file is F90
src/science/canopy/cable_canopy.F90
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AM3 version treatment of conversion (assuming 1e3 corresponds to units)
! Calculate dewfall: from negative lh wet canopy + neg. lh dry canopy:
canopy%dewmm = - (MIN(0.0,canopy%fevw) + MIN(0.0_r_2,canopy%fevc)) * &
dels / air%rlam
and cansto
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AM3 had neater interface. The explicit REAL typecasting is perhaps unnecessary as it is handled here that was used in AM3 - HOWEVER continued removal of r_2 is advantageous. As argued a million times, REAL(selected_real_kind) does not change CPU hardeware. it's either a 32,64,128 bit machine. All values of selected_real_kind fall into their nearest bin (being either 32,64,128 bit etc). Here r_2 defaults to double. In the UM everything is compiled as -i8, -r8 so r_2 is meaningless and only causes complications in development/refactoring especially when TYPES/kinds dont match up. Additionally the UKMO discouraged us from using r_2, special KINDs. However they have since adopted them themselves. Having many different KINDs on either side of the interface is problematic. Last I spoke with them they were uncertain of what this would all look like with LFRic. At any rate it is easier if we just lay off the r_2 for the moment and re-implement a consistent approach at a later date when we know better what is happening.
@@ -369,15 +381,8 @@ SUBROUTINE dryLeaf( dels, rad, rough, air, met, & | |||
rdx(i,2) = rdx(i,2) * & | |||
(0.5 - 0.05*LOG(jtomol*1.0e6*rad%qcan(i,1,2))) | |||
|
|||
!$ xleuning(i,1) = ( fwsoil(i) / ( csx(i,1) - co2cp3 ) ) & | |||
!$ * ( veg%a1gs(i) / ( 1.0 + dsx(i)/veg%d0gs(i))) | |||
!$ xleuning(i,2) = ( fwsoil(i) / ( csx(i,2) - co2cp3 ) ) & |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This commenting style has lead to issues in some UM builds. Its redundant code anyway
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This has just had the f90 capitalised
@ccarouge - There is still the soilsnow stuff to go in. Fortunately it looks pretty good porting back to AM3. There is an issue around dewmm & canto that I mentioned here, and 1 other, all in cable_canopy |
@JhanSrbinovsky Have you tested these changes in benchcab? What's the effect on the results? |
2024-11-27 13:32:16,679 - INFO - benchcab.benchcab.py:391 - 0 failed, 20 passed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All good then.
CABLE
Thank you for submitting a pull request to the CABLE Project.
Description
Please include a brief summary of the change and list the issues that are fixed.
Please also include relevant motivation and context.
You can link issues by using a supported keyword in the pull request's description or in a commit message:
Fixes #(issue)
Type of change
Please delete options that are not relevant.
Checklist
Please add a reviewer when ready for review.
📚 Documentation preview 📚: https://cable--489.org.readthedocs.build/en/489/