Closed zmoon closed 8 months ago
@drnimbusrain how do we want to handle FPEs? First one is here (case that hcmref
is 0):
--- a/src/canopy_calcs.F90
+++ b/src/canopy_calcs.F90
@@ -78,8 +78,12 @@ SUBROUTINE canopy_calcs
! ... calculate wind speed from u and v
ubzref = sqrt((uref**2.0) + (vref**2.0))
-! ... get scaled canopy model profile and sub-canopy layers
- zhc = zk/hcmref
+ ! ... get scaled canopy model profile and sub-canopy layers
+ if (hcmref > 0) then
+ zhc = zk / hcmref
+ else
+ zhc = 0
+ end if
cansublays = floor(hcmref/modres)
! ... check for valid model vegetation types
I agree with your first FPE change here. Do you want to make this (and other) change to your branch as the FPEs come up with your improved debugging options?
@zmoon Do you think you will be able to work on this again soon? Thank you!
@drnimbusrain I'll try to work on it again soon.
Thanks Zach...I added the additional debug flags and checked/solved the FPEs in latest develop.
On Wed, Jan 24, 2024, 1:36 PM Zachary Moon @.***> wrote:
@drnimbusrain https://github.com/drnimbusrain I'll try to work on it again soon.
— Reply to this email directly, view it on GitHub https://github.com/noaa-oar-arl/canopy-app/pull/85#issuecomment-1908707187, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGLFYNQFPNHD3JUWKZGQXHLYQFIBDAVCNFSM6AAAAAA3HJFUT2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMBYG4YDOMJYG4 . You are receiving this because you were mentioned.Message ID: @.***>
That's good, I'll merge that into here before working on it more then.
@drnimbusrain some notes:
@zmoon Thank you for working on this, and agree that more comprehensive checks of the different code pathways/options are needed to check for all FPEs. I will try and work on this with your new debug options more thoroughly as we go along with more robust testing. I think that @btang1 @MaggieMarvin @angehung5 could help with this DEBUG=2 testing of the different options for FPEs as well, since they are going to be focusing on different parts of code. For now I approve, and we can improve later.
I can also work on the "array temporary was created" issues too. Thanks!
OK, I will merge then and work with the DEBUG=2 option some to fix some other potential FPEs and the warnings...