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

Setting QUILTING: false causes the run_fcst task to fail #867

Closed
gsketefian opened this issue Jul 20, 2023 · 0 comments · Fixed by #869
Closed

Setting QUILTING: false causes the run_fcst task to fail #867

gsketefian opened this issue Jul 20, 2023 · 0 comments · Fixed by #869
Labels
bug Something isn't working

Comments

@gsketefian
Copy link
Collaborator

gsketefian commented Jul 20, 2023

Expected behavior

When QUILTING is set to false in config.yaml, the forecast should complete successfully and generate the history files fv3_history2d.nc and fv3_history.nc instead of dynf###.nc and phyf###.nc.

Current behavior

Setting QUILTING: false causes the run_fcst task to fail in create_model_configure_file.py (even before the forecast is launched) because several variables in the jinja template file model_configure remain undefined for this case (so that the model_configure file is not generated from the template.

Machines affected

Defiinitely Hera (probably all).

Steps To Reproduce

One way to reproduce this error is to run the WE2E test grid_RRFS_CONUScompact_25km_ics_HRRR_lbcs_HRRR_suite_HRRR with QUILTING set to false. To do this, first modify the configuration file for this test, which is at

ufs-srweather-app/tests/WE2E/test_configs/grids_extrn_mdls_suites_community/config.grid_RRFS_CONUScompact_25km_ics_HRRR_lbcs_HRRR_suite_HRRR.yaml

by addding the following bolded lines:

...
workflow:
...
rocoto:
  tasks:
    taskgroups: '{{ ["parm/wflow/prep.yaml", "parm/wflow/coldstart.yaml"]|include }}'
...
task_run_fcst:
...
  QUILTING: false

Then run the run_WE2E_tests.py script for this test. When the experiment gets to the run_fcst task, it should fail with a message in the log file similar to the one shown in the Output section below.

Detailed Description of Fix (optional)

Include a section of code right before if QUILTING: statement in create_model_configure_file.py that sets the undefined parameters to default values (e.g. None).

Output (optional)

Here is the relevant portion of the error message in run_fcst_mem000_2019061518.log:

ERROR: Template requires variables that are not provided
  lat2
  dx
  dlon
  lon1
  cen_lat
  lon2
  stdlat2
  ny
  cen_lon
  write_tasks_per_group
  stdlat1
  nx
  dlat
  write_groups
  dy
  lat1
Missing values needed by template
Traceback (most recent call last):
  File "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/TEST_SRW_phys_tendencies/ufs-srweather-app/ush/create_model_configure_file.py", line 302, in <module>
    create_model_configure_file(
  File "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/TEST_SRW_phys_tendencies/ufs-srweather-app/ush/create_model_configure_file.py", line 215, in create_mod    
el_configure_file
    set_template(
  File "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/TEST_SRW_phys_tendencies/ufs-srweather-app/ush/python_utils/workflow-tools/scripts/templater.py", line     
146, in set_template
    raise ValueError(msg)
ValueError: Missing values needed by template
End exregional_run_fcst.sh at Wed Jul 19 23:40:45 UTC 2023 with error code 1 (time elapsed: 00:00:12)
FATAL ERROR:
ERROR:
  From script:  "JREGIONAL_RUN_FCST"
  Full path to script:  "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/TEST_SRW_phys_tendencies/ufs-srweather-app/jobs/JREGIONAL_RUN_FCST"
Call to ex-script corresponding to J-job "JREGIONAL_RUN_FCST" failed.
Exiting with nonzero status.
End JREGIONAL_RUN_FCST at Wed Jul 19 23:40:45 UTC 2023 with error code 1 (time elapsed: 00:00:13)
@gsketefian gsketefian added the bug Something isn't working label Jul 20, 2023
@MichaelLueken MichaelLueken linked a pull request Jul 21, 2023 that will close this issue
37 tasks
MichaelLueken pushed a commit that referenced this issue Jul 26, 2023
…869)

When QUILTING is set to false, the run_fcst task fails because some of the variables needed in the jinja template file parm/model_configure remain undefined in the call to ush/create_model_configure_file.py. This PR fixes that bug and adds a WE2E test for the QUILTING: false case.

Note that when QUILTING is set to false, the UFS Weather Model generates output files named fv3_history2d.nc and fv3_history.nc that contain data on the native grid, not the write-component grid. Thus, the run_post and subsequent tasks that depend on Weather Model output on the write-component grid cannot be included in the workflow. For this reason, the new WE2E test that this PR adds includes tasks only up to run_fcst.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant