CAM icon indicating copy to clipboard operation
CAM copied to clipboard

Nudging code doesn't error out when there are no nudging files

Open adamrher opened this issue 10 months ago • 0 comments

What happened?

@mattldawson ran a nudging case but the model couldn't access the streams set by the nudge_path directory. The model did not error out and rather printed this message for each nudging time-step:

 NUDGING: WARNING - analyses file NOT FOUND. Switching
 NUDGING:           nudging OFF to coast thru the gap.

Coasting through the gaps can be useful, but it doesn't distinguish whether there are literally no nudging files for the entirety of a simulation. Ideally the model would error out if there are no nudging files.

What are the steps to reproduce the bug?

./create_newcase --case $CASE_DIR --compset FMTHIST --res ne30pg3_ne30pg3_mg17 --walltime 00:29:00 --mach derecho --pecount 768 --project P19010000 --compiler gnu --queue main --run-unsupported

./xmlchange RUN_STARTDATE=2010-09-01

open up user_nl_cam w/ an editor and add these entries:
model_times_per_day            = 24
nudge_beg_day          = 1
nudge_beg_month                = 9
nudge_beg_year         = 2010
nudge_end_day          = 7
nudge_end_month                = 9
nudge_end_year         = 2010
nudge_path                     ='/glade/derecho/scratch/aherring/restart/nudging/ne30pg3/L93/2010/'
nudge_file_template            ='ERA5_x_ne30pg3_L93_rgC1_WO.%y-%m-%d-%s.nc'
nudge_force_opt                = 0
nudge_hwin_invert              = .false.
nudge_hwin_lat0                = 0.0
nudge_hwin_latdelta            = 1.0
nudge_hwin_latwidth            = 9999.0
nudge_hwin_lon0                = 180.
nudge_hwin_londelta            = 1.0
nudge_hwin_lonwidth            = 9999.0
nudge_model            = .true.
nudge_pscoef           = 0
nudge_psprof           = 0
nudge_qcoef            = 0.0
nudge_qprof            = 2
nudge_tcoef            = 0.16667
nudge_times_per_day            = 24
nudge_timescale_opt            = 0
nudge_tprof            = 2
nudge_ucoef            = 0.16667
nudge_uprof            = 2
nudge_vcoef            = 0.16667
nudge_vprof            = 2
nudge_vwin_hdelta              = 0.001
nudge_vwin_hindex              = 0.
nudge_vwin_invert              = .true.
nudge_vwin_ldelta              = 0.001
nudge_vwin_lindex              = 0.

What CAM tag were you using?

any recent tag

What machine were you running CAM on?

CISL machine (e.g. cheyenne)

What compiler were you using?

GNU

Path to a case directory, if applicable

/glade/derecho/scratch/mattdawson/Nudging-cam6_4_075/

Will you be addressing this bug yourself?

No

Extra info

No response

adamrher avatar Mar 13 '25 15:03 adamrher