...
Create a directory in your /glade/work/$USER/ space for a repository of your created files ($REPO). For example, :
- $REPO = /glade/work/emmons/tutorial_Nanjing/ne0np4.Nanjing.ne30x8/
...
Create a new variable resolution mesh (VRM)
...
On casper start the VRM Editor from your $REPO/grids directory:
> cd $REPO/grids
> /glade/work/emmons/tutorial_Nanjing/VRM_tools/VRM_Editor/src/VRM_Editor
...
Plot EXODUS file with /glade/u/home/emmons/tutorial_Nanjing_notebooks/Plot_exodus_grid.ipynb
Create grid files
Several types of grid files need to be created.
Create SCRIP and LATLON grid files from EXODUS file
On casper:
> cd $REPO/grids
> cp /glade/work/emmons/tutorial_Nanjing/VRM_tools/VRM_ControlVolumes/src/input.nl input-Nanjing.nl
Edit input-Nanjing_ne30x8.nl to have your path to $REPO/grids and the grid name. Then run Gen_ControlVolumes:
> /glade/work/emmons/tutorial_Nanjing/VRM_tools/VRM_ControlVolumes/src/Gen_ControlVolumes.exe input-Nanjing.nl > LOG_Nanjing
This produces Nanjing_ne30x8_np4_SCRIP.nc and Nanjing_ne30x8_np4_LATLON.nc
Examine the LATLON file to get the number of columns in your new grid:
> ncdump -h Nanjing_ne30x8_np4_LATLON.nc
This prints (among other things):
ncol = 60482 ;
Create ESMF mesh file from SCRIP file
On casper, load needed modules:
> module load mpi-serial/2.3.0
> module load esmf/8.5.0
To find the path toESMF_Scrip2Unstruct, run:
> module show esmf/8.5.0
Find the listing for the "PATH" directory:
"PATH","/glade/u/apps/casper/23.10/spack/opt/spack/esmf/8.5.0/mpi-serial/2.3.0/oneapi/2023.2.1/dfkx/bin"
In the directory with your SCRIP file, run:
> /glade/u/apps/casper/23.10/spack/opt/spack/esmf/8.5.0/mpi-serial/2.3.0/oneapi/2023.2.1/dfkx/bin/ESMF_Scrip2Unstruct Nanjing_ne30x8_np4_SCRIP.nc Nanjing_ne30x8_np4_MESH.nc
Generate CESM input files on new grid
...