custom grid definition

Hi,

I'm trying to define custom grid definition

I've populated the flowing values in set_predef_grid_params.sh

"BG_REGIONAL_3km")

  GRID_GEN_METHOD="ESGgrid"

  ESGgrid_LON_CTR="25.686"
  ESGgrid_LAT_CTR="42.094"

  ESGgrid_DELX="3000.0"
  ESGgrid_DELY="3000.0"

  ESGgrid_NX="-303"
  ESGgrid_NY="-245"

  ESGgrid_WIDE_HALO_WIDTH="6"

  DT_ATMOS="${DT_ATMOS:-40}"

  LAYOUT_X="${LAYOUT_X:-30}"
  LAYOUT_Y="${LAYOUT_Y:-16}"
  BLOCKSIZE="${BLOCKSIZE:-32}"

  if [ "$QUILTING" = "TRUE" ]; then
    WRTCMP_write_groups="1"
    WRTCMP_write_tasks_per_group="1"
    WRTCMP_write_tasks_per_group=$(( 1*LAYOUT_Y ))
    WRTCMP_output_grid="regional_latlon"
    WRTCMP_cen_lon="${ESGgrid_LON_CTR}"
    WRTCMP_cen_lat="${ESGgrid_LAT_CTR}"
    WRTCMP_stdlat1="${ESGgrid_LAT_CTR}"
    WRTCMP_stdlat2="${ESGgrid_LAT_CTR}"
    WRTCMP_nx="298"
    WRTCMP_ny="240"
    WRTCMP_lon_lwr_left="38.786"
    WRTCMP_lat_lwr_left="21.730"
    WRTCMP_dx="${ESGgrid_DELX}"
    WRTCMP_dy="${ESGgrid_DELY}"
  fi
  ;;

 

After that, I ran the ./generate_FV3LAM_wflow.sh the command exited with success, but when I run run_make_grid.sh from my experiment dir I got the following error: 

 

This is the ex-script for the task that generates grid files.
========================================================================

No arguments have been passed to the script in file

  "/home/dimitar/Work/ufs-srweather-app/regional_workflow/scripts/exregional_make_grid.sh"


Starting grid file generation...

Creating namelist file (rgnl_grid_nml_fp) to be read in by the grid
generation executable (exec_fp):
  rgnl_grid_nml_fp = "/home/dimitar/Work/expt_dirs/bg_regional_3km/grid/tmp/regional_grid.nml"
  exec_fp = "/home/dimitar/Work/ufs-srweather-app/bin/regional_esg_grid"
Traceback (most recent call last):
  File "/home/dimitar/Work/ufs-srweather-app/regional_workflow/ush/set_namelist.py", line 330, in <module>
    main(cla)
  File "/home/dimitar/Work/ufs-srweather-app/regional_workflow/ush/set_namelist.py", line 304, in main
    update_dict(nml, cla.user_config.items(), quiet=cla.quiet)
  File "/home/dimitar/Work/ufs-srweather-app/regional_workflow/ush/set_namelist.py", line 277, in update_dict
    _ = dest[sect].pop(key, None)
  File "/home/dimitar/.local/lib/python3.8/site-packages/f90nml/namelist.py", line 104, in __contains__
    return super(Namelist, self).__contains__(key.lower())
AttributeError: 'int' object has no attribute 'lower'

ERROR:
  From script:  "exregional_make_grid.sh"
  Full path to script:  "/home/dimitar/Work/ufs-srweather-app/regional_workflow/scripts/exregional_make_grid.sh"
Call to python script set_namelist.py to set the variables in the
regional_esg_grid namelist file failed.  Parameters passed to this script
are:
  Full path to output namelist file:
    rgnl_grid_nml_fp = "/home/dimitar/Work/expt_dirs/bg_regional_3km/grid/tmp/regional_grid.nml"
  Namelist settings specified on command line (these have highest precedence):
    settings =

'regional_grid_nml': {
    'plon': 25.686,
    'plat': 42.094,
    'delx': 0,0000000000,
    'dely': 0,0000000000,
    'lx': 291,
    'ly': 233,
 }

Exiting with nonzero status.

ERROR:
  From script:  "JREGIONAL_MAKE_GRID"
  Full path to script:  "/home/dimitar/Work/ufs-srweather-app/regional_workflow/jobs/JREGIONAL_MAKE_GRID"
Call to ex-script corresponding to J-job "JREGIONAL_MAKE_GRID" failed.
Exiting with nonzero status.
 

Any advice in continuing of localizing the domain?

Hi,

Within the section of your grid parameters in set_predef_grid_params.sh, please remove the negative signs in the following:

ESGgrid_NX="-303"
ESGgrid_NY="-245"

Hopefully that will solve your problem!