Skip to content
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

bug: Updates to snow mass and snow height resulting from snow repartitioning in dart_to_clm.f90 are causing CLM to generate NaN fluxes to the coupler and NaN state variables. #659

Open
XueliHuo opened this issue Mar 22, 2024 · 6 comments
Labels
CLM Community Land Model

Comments

@XueliHuo
Copy link
Collaborator

🐛 Your bug may already be reported!
Please search on the issue tracker before creating a new issue.

Describe the bug

I am using the snow repartition in dart_to_clm.f90 for my snow data assimilation project.
The dart_to_clm.f90 used in my project has the latest commit 8c75bd3
At the assimilation step, the snow observation was successfully assimilated into CLM, and the snow mass (both liquid and ice components) and snow thickness in the restart files were updated with no error. However, when CLM continued running with these restart files where the snow mass and snow thickness were updated, it stopped with an error.

Error Message

clm: completed timestep         1489
 # of NaNs =            7
 Which are NaNs =  F F F F F F T F F T F F F F F F F F F F F F F F F F F F F F F
 F F F F F T T T T F F F F T F F F F F F F F F F F F F F F F F F F F F F F F
 Sl_t
 Sl_snowh
 Fall_lat
 Fall_sen
 Fall_lwup
 Fall_evap
 Flrl_rofsur
 gridcell index =           77
 local  gridcell index =           77
 ENDRUN:
 ERROR: 
 lnd_export                       ERROR: One or more of the output from CLM to the coupler are NaN

Which model(s) are you working with?

clm with the version as release-cesm2.2.01

Screenshots

If applicable, add screenshots to help explain your problem.

Version of DART

Which version of DART are you using?
You can find the version using git describe --tags
v10.7.0-111-g70e6af803

Have you modified the DART code? No

If your code changes are available on GitHub, please provide the repository.

Build information

Please describe:

  1. The machine you are running on (e.g. windows laptop, NSF NCAR supercomputer Derecho).
    I am using the HPC provided by University of Utah.
  2. The compiler you are using (e.g. gnu, intel).
    intel
@XueliHuo
Copy link
Collaborator Author

I am working on this issue and making some changes to the snow partition in the dart_to_clm.f90.
These new changes are being tested in a snow data assimilation experiment which is undergoing.
I will provide more information later of these changes if they work out.

@braczka
Copy link
Contributor

braczka commented Mar 22, 2024

This is perfect @XueliHuo. Thank you for posting and updating us. We look forward to the PR at some point when the changes have been fully vetted.

@hkershaw-brown
Copy link
Member

is this related to #254 (comment)?

@braczka
Copy link
Contributor

braczka commented Apr 5, 2024

#254 (comment)

I don' t think so. It's most closely related to previous snow layer NaN issues fixed in PR #606. This is an additional issue that goes beyond the external clamping solutions (i.e. physical snow layer quantities >=0 etc) posed in that previous issue/fix. Because this is new science, @XueliHuo will update with PR at her own discretion.

@hkershaw-brown hkershaw-brown added the CLM Community Land Model label Apr 5, 2024
@hkershaw-brown
Copy link
Member

@hkershaw-brown need test cases for this code.

@hkershaw-brown
Copy link
Member

#254 (comment)

I don' t think so. It's most closely related to previous snow layer NaN issues fixed in PR #606. This is an additional issue that goes beyond the external clamping solutions (i.e. physical snow layer quantities >=0 etc) posed in that previous issue/fix. Because this is new science, @XueliHuo will update with PR at her own discretion.

ok sounds good. It would be good to get a description of the code that is causing problem in dart_to_clm.f90 once the bug is identified (so what the code is doing vs. what the code should be doing), and a reproducer so we can test before and after a fix (and add to our tests).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLM Community Land Model
Projects
None yet
Development

No branches or pull requests

3 participants