-
Notifications
You must be signed in to change notification settings - Fork 321
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
Fix FATES branch runs #2955
base: master
Are you sure you want to change the base?
Fix FATES branch runs #2955
Conversation
Two files are getting produced in each run, but only the
The
The entire @ekluzek any idea why this might be happening? |
Figured it out— |
This ensures matching filenames in both parts of ERI tests.
@rgknox has new ERI tests that are coming in, but they maybe on the FATES side (not aux_clm). |
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.
Thank you for addressing this.
@@ -738,7 +738,7 @@ subroutine initialize2(ni,nj, currtime) | |||
deallocate(wt_nat_patch) | |||
|
|||
! Initialise the fates model state structure | |||
if ( use_fates .and. .not.is_restart() .and. finidat == ' ') then | |||
if ( use_fates .and. .not. (is_restart() .or. nsrest .eq. nsrBranch) .and. finidat == ' ') then |
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.
@samsrabin I was expecting the top part of this logical block to also exclude hybrid runs along with branch runs. Is a hybrid run equivalent to is_restart()=.true. ?
For future work I feel like we should clean some of this logic up, I cobbled a lot of this together many years ago when I did not have a good sense of restart options. But my take is that our decision making on how to restart fates (ie cold or from pre-existing vegetation structure in a restart file) really comes down to if it is a startup, branch or hybrid. The finidat string is less straight forward to use here in decide what part of the initialization sequence to use. My understanding is that the finidat should have a meaningful file path only in the latter two scenarios (branch and hybrid), so its better to use the switches that are the root of deciding these things rather variables like finidat that are "downstream" of them. Does that make sense? Again, I'd like to make an issue of this and flag it for future work and not complicate this PR.
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.
I do know that is_restart()
returns true in hybrid runs, but I don't know if they're fully equivalent. As for the rest of it, since you think that work makes sense to do somewhere else, would you mind making an issue with your thoughts and then resolving this conversation?
Description of changes
In FATES branch runs, prevents attempts to re-allocate arrays that already are allocated (in the restart file).
This prevents run failures. However, it exposes a failure in the
COMPARE_base_hybrid
step of ERI tests, due to a badhist_mfilt
. This PR will also fix that.Remaining tasks:
COMPARE_base_hybrid
failure.ERI
tests toaux_clm
andfates
test suites.Notes for testing
Baseline comparisons may fail for the following testmods:
Fates
FatesColdAllVars
FatesColdDryDepSatPhen
FatesColdHydro
FatesColdMeganSatPhen
FatesColdSatPhen
fire_emis
glcMEC_long
However, this is only because I have changed
hist_mfilt
for those to 1. (From 365 for theFates
testmods; from 30 forfire_emis
; from 12 forglcMEC_long
). This ensures that the dates in the history filenames are the same for both parts of the ERI test.When this is next in the merge queue:
mfilt
. Runaux_clm
andfates
suites, comparing to the latest baseline, expecting no diffs.aux_clm
andfates
suites, comparing to the latest baseline, expecting baseline comparison failures (a) only for those tests and (b) only because of missing baseline files.Specific notes
Contributors other than yourself, if any: @ckoven
CTSM Issues Fixed:
Are answers expected to change (and if so in what way)? No, although see "Notes for testing" above.
Any User Interface Changes (namelist or namelist defaults changes)? No
Does this create a need to change or add documentation? Did you do so? No
Testing performed, if any:
ERI_Ld60.f45_f45_mg37.I2000Clm50FatesCruRsGs.derecho_intel.clm-Fates
passes.