8000 Canopy sorting problems with nclmax>2 · Issue #1388 · NGEET/fates · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Canopy sorting problems with nclmax>2 #1388

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

Open
rgknox opened this issue Apr 11, 2025 · 1 comment
Open

Canopy sorting problems with nclmax>2 #1388

rgknox opened this issue Apr 11, 2025 · 1 comment

Comments

@rgknox
Copy link
Contributor
rgknox commented Apr 11, 2025

Tests with nclmax = 3 are generating model crashes on an f10 smoke test using nocomp and fixed biogeography.

Branch (April 11 2025): https://github.com/rgknox/fates/tree/nclmax-3

I attach an error message, and added in a patch dump (modified to dump cohorts too) before the error triggers.

Error triggered at EDCanopyStructureMod.F90 Line 2233, apparently trying to divide by patch%total_canopy_area (which is zero). There is a cohort on the patch with positive LAI, so there is something clearly wrong with how it is calculating total_canopy_area

/glade/u/home/rgknox/ctsm/src/fates/biogeochem/EDCanopyStructureMod.F90:2233):

write(fates_log(),*)'broken area?',cl,currentPatch%total_canopy_area,currentCohort%treelai,currentCohort%pft
dec1048.hsn.de.hpc.ucar.edu 109:  broken area?           2   0.0000000000000000        4.0938325628941036E-002          14
dec1048.hsn.de.hpc.ucar.edu 109:  ----------------------------------------
dec1048.hsn.de.hpc.ucar.edu 109:   Dumping Patch Information              
dec1048.hsn.de.hpc.ucar.edu 109:   (omitting arrays)                      
dec1048.hsn.de.hpc.ucar.edu 109:  ----------------------------------------
dec1048.hsn.de.hpc.ucar.edu 109:  pa%patchno            =            5
dec1048.hsn.de.hpc.ucar.edu 109:  pa%age                =    3.9424657534247611     
dec1048.hsn.de.hpc.ucar.edu 109:  pa%age_class          =            3
dec1048.hsn.de.hpc.ucar.edu 109:  pa%area               =    5949.6906240181215     
dec1048.hsn.de.hpc.ucar.edu 109:  pa%num_cohorts        =            1
dec1048.hsn.de.hpc.ucar.edu 109:  pa%ncl_p              =            2
dec1048.hsn.de.hpc.ucar.edu 109:  pa%total_canopy_area  =    0.0000000000000000     
dec1048.hsn.de.hpc.ucar.edu 109:  pa%total_tree_area    =    0.0000000000000000     
dec1048.hsn.de.hpc.ucar.edu 109:  pa%total_grass_area   =    0.0000000000000000     
dec1048.hsn.de.hpc.ucar.edu 109:  pa%zstar              =    0.0000000000000000     
dec1048.hsn.de.hpc.ucar.edu 109:  pa%gnd_alb_dif        =    1.0000000000000000E+036   1.0000000000000000E+036
dec1048.hsn.de.hpc.ucar.edu 109:  pa%gnd_alb_dir        =    1.0000000000000000E+036   1.0000000000000000E+036
dec1048.hsn.de.hpc.ucar.edu 109:  pa%c_stomata          =   0.20224004271799170     
dec1048.hsn.de.hpc.ucar.edu 109:  pa%c_lblayer          =    973301.70559794537     
dec1048.hsn.de.hpc.ucar.edu 109:  pa%disturbance_rates  =    0.0000000000000000        0.0000000000000000        0.0000000000000000        0.0000000000000000     
dec1048.hsn.de.hpc.ucar.edu 109:  pa%land_use_label     =            1
dec1048.hsn.de.hpc.ucar.edu 109:  ----------------------------------------
dec1048.hsn.de.hpc.ucar.edu 109:  element id:            1
dec1048.hsn.de.hpc.ucar.edu 109:  seed mass:    8.0927125825396490E-002
dec1048.hsn.de.hpc.ucar.edu 109:  seed germ mass:    8.3345008483262252E-005
dec1048.hsn.de.hpc.ucar.edu 109:  leaf fines(pft):   0.96928896671652287     
dec1048.hsn.de.hpc.ucar.edu 109:  root fines(pft,sl):   0.32240494404004033     
dec1048.hsn.de.hpc.ucar.edu 109:  ag_cwd(c):    0.0000000000000000     
dec1048.hsn.de.hpc.ucar.edu 109:  bg_cwd(c,sl):    0.0000000000000000     
dec1048.hsn.de.hpc.ucar.edu 109: 
dec1048.hsn.de.hpc.ucar.edu 109: Program received signal SIGFPE: Floating-point exception - erroneous arithmetic operation.
dec1048.hsn.de.hpc.ucar.edu 109: 
dec1048.hsn.de.hpc.ucar.edu 109: Backtrace for this error:
dec1048.hsn.de.hpc.ucar.edu 109: #0  0x149fea376d4f in ???
dec1048.hsn.de.hpc.ucar.edu 109: 	at /usr/src/debug/glibc-2.31-150300.41.1.x86_64/signal/../sysdeps/unix/sysv/linux/x86_64/sigaction.c:0
dec1048.hsn.de.hpc.ucar.edu 109: #1  0x992969 in __edcanopystructuremod_MOD_updatepatchlai
dec1048.hsn.de.hpc.ucar.edu 109: 	at /glade/u/home/rgknox/ctsm/src/fates/biogeochem/EDCanopyStructureMod.F90:2233
dec1048.hsn.de.hpc.ucar.edu 109: #2  0x992bf9 in leaf_area_profile
dec1048.hsn.de.hpc.ucar.edu 109: 	at /glade/u/home/rgknox/ctsm/src/fates/biogeochem/EDCanopyStructureMod.F90:1563
dec1048.hsn.de.hpc.ucar.edu 109: #3  0x99823e in __edcanopystructuremod_MOD_canopy_summarization

@rgknox
Copy link
Contributor Author
7C59 rgknox commented Apr 16, 2025

A fix for this is in the works. The error here is triggering in a very strange scenario. I believe that a third canopy layer, and the cohorts inhabiting it, were the only cohorts to survive the day's mortality and termination. When this cohort was presented to promotion/demotion logic, it was promoted from level 3 to 2. However, this satisfied the logic to stop promotion/demotion since the canopy areas did not exceed total area. The simple solution is to improve the logic that determines promotion/demotion sucess to require that the the top layers ( ie max(nlcmax,ncl_p)-1 ) match the patch area within a reasonable tolerance, and that only the bottom-most layer is allowed to be less than the patch area.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: ❕Todo
Development

No branches or pull requests

1 participant
0