Closed adrifoster closed 1 week ago
Okay so I've tracked down this error. And it seems to originate from a negative value in the sum of fine leaf litter. (leaf_fines -2.3394756489679232E-006)
This exists in main
branch too - I think the old way of calculating fuel was hiding it.
I am going to file an issue.
@rgknox @glemieux any ideas?
Okay so I've tracked down this error. And it seems to originate from a negative value in the sum of fine leaf litter. (leaf_fines -2.3394756489679232E-006)
This exists in
main
branch too - I think the old way of calculating fuel was hiding it.I am going to file an issue.
@rgknox @glemieux any ideas?
We can ignore this per #1249.
Okay I think I have fixed all the overflow and divide-by-zero issues. I am re-running testing but I think this is now ready for a review.
fates test suite tests are in /glade/derecho/scratch/afoster/tests_0924-151742de
all tests PASS or FAIL due to a BASELINE DIFF, as expected
will run through and make sure all DIFF's are round off
All DIFFs are due to roundoff - this is ready for a review.
@rgknox asked for some functional testing plots:
One general comment. This is something that was already in the code that kind of bothered me. We all know we break up litter into component groups for both decomposition and fire. Both modules use almost the same groups, which are governed by size and location (above and below ground). In general, I'd like this to be a little cleaner, where the super-set of all delineations is contained in a process agnostic module, and decomposition and fire could inherit those delineations and group/use them how they see fit. I don't see this as in-scope for this PR necessarily, but I'm curious how you see all this, and if its still a problem.
One general comment. This is something that was already in the code that kind of bothered me. We all know we break up litter into component groups for both decomposition and fire. Both modules use almost the same groups, which are governed by size and location (above and below ground). In general, I'd like this to be a little cleaner, where the super-set of all delineations is contained in a process agnostic module, and decomposition and fire could inherit those delineations and group/use them how they see fit. I don't see this as in-scope for this PR necessarily, but I'm curious how you see all this, and if its still a problem.
Totally agree. I wanted to try to merge them somehow but they are slightly different in terms of how they are grouped and used, so I wasn't sure how to do it efficiently for this PR. I think it warrants a small group of us sitting down to discuss. If we merged them it would also make further discretizing the litter/fuel easier (i.e. PFT-specific, etc.).
I also don't love that the litter is decayed in one spot, the fuel is combusted in another, etc. And seemingly we do (?) make sure these things align?
Great work! This is so much better organized and easier to understand. I just have some rather minor comments.
Thanks @samsrabin! Great suggestions, will get started on applying them.
I've addressed @samsrabin's comments and made all suggested changes.
Thanks to @glemieux for finding the issue with this PR. All tests now pass.
Refactors the SPITFIRE fuel calculation subroutine and adds a fuel class
Description:
Major changes to the way fuel characteristics are calculated in the SPITFIRE module. Changes are not B4B, but should be round off.
Expectation of Answer Changes:
Round off differences due to order of operation changes. Testing in progress...
Checklist
Contributor
Integrator
Test Results:
Testing ongoing... currently having issues with some divide by zero errors (in rate_of_spread) for only some tests... I'm not sure why this is happening since the code should check and not let SAV, bulk density, etc. equal zero.
/glade/derecho/scratch/afoster/tests_0912-094039de
CTSM (or) E3SM (specify which) test hash-tag:
CTSM (or) E3SM (specify which) baseline hash-tag:
FATES baseline hash-tag:
Test Output: