Skip to content

Commit

Permalink
Adds notes about using mksurfdata_map
Browse files Browse the repository at this point in the history
  • Loading branch information
bishtgautam committed Sep 18, 2024
1 parent 3e6959e commit ff40c9c
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 2 deletions.
8 changes: 6 additions & 2 deletions components/elm/docs/user-guide/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,11 @@ Using the above-mentioned settings:
The [FATES User's Guide section on namelist options](https://fates-users-guide.readthedocs.io/en/latest/user/Namelist-Options-and-Run-Time-Modes.html)
provides guidance on enabling these different FATES run modes.

## Generate land initial condition
## Create land surface dataset

A new surface dataset for ELM is generated using `mksurfdata_map` and the notes about it are available [here](surface_dataset.md)

Initial ELM condition can be generated using `interpinic` and the notes about it are available [here](interpinic.md).

Check failure on line 84 in components/elm/docs/user-guide/index.md

View workflow job for this annotation

GitHub Actions / linter

Multiple consecutive blank lines

components/elm/docs/user-guide/index.md:84 MD012/no-multiple-blanks Multiple consecutive blank lines [Expected: 1; Actual: 2] https://github.com/DavidAnson/markdownlint/blob/v0.35.0/doc/md012.md
## Generate land initial condition

Initial ELM condition can be generated using `interpinic` and the notes about it are available [here](interpinic.md).

Check failure on line 87 in components/elm/docs/user-guide/index.md

View workflow job for this annotation

GitHub Actions / linter

Files should end with a single newline character

components/elm/docs/user-guide/index.md:87:117 MD047/single-trailing-newline Files should end with a single newline character https://github.com/DavidAnson/markdownlint/blob/v0.35.0/doc/md047.md
49 changes: 49 additions & 0 deletions components/elm/docs/user-guide/surface_dataset.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Creating an ELM surface dataset

The notes describe the steps in creating an ELM surface dataset at 0.5x0.5 resolution for 1950 on Perlmutter.

1. Load the appropriate modules.

```

Check failure on line 7 in components/elm/docs/user-guide/surface_dataset.md

View workflow job for this annotation

GitHub Actions / linter

Fenced code blocks should have a language specified

components/elm/docs/user-guide/surface_dataset.md:7 MD040/fenced-code-language Fenced code blocks should have a language specified [Context: "```"] https://github.com/DavidAnson/markdownlint/blob/v0.35.0/doc/md040.md
cd <e3ms-dir>
eval $(./cime/CIME/Tools/get_case_env)
```

2. Compile `mksurfdata_map`.

Check failure on line 12 in components/elm/docs/user-guide/surface_dataset.md

View workflow job for this annotation

GitHub Actions / linter

Ordered list item prefix

components/elm/docs/user-guide/surface_dataset.md:12:1 MD029/ol-prefix Ordered list item prefix [Expected: 1; Actual: 2; Style: 1/1/1] https://github.com/DavidAnson/markdownlint/blob/v0.35.0/doc/md029.md

```
cd components/elm/tools/mksurfdata_map/src/
make clean
export USER_LDFLAGS="-L$NETCDF_DIR/lib -lnetcdf -lnetcdff -lnetcdf_intel"
export USER_LDFLAGS=$USER_LDFLAGS" -L$HDF5_DIR/lib -lhdf5 -lhdf5_fortran -lhdf5_hl_intel -lhdf5hl_fortran_intel"
USER_FC=ifort LIB_NETCDF="`nc-config --flibs`" INC_NETCDF="`nf-config --includedir`" make VERBOSE=1
```

3. Build the namelist. This steps assumes that the resolution for which the new surface dataset is being created is a supported resolution.
If the surface dataset is being created for an unsupported resolution, 16 mapping files will have to be created to map the raw datasets
onto this unsupported resolution.

```
cd ../
RES=0.5x0.5
YR=1950
DIN_LOC_ROOT=/global/cfs/cdirs/e3sm/inputdata
./mksurfdata.pl -res $RES -years $YR -d -dinlc $DIN_LOC_ROOT
mv namelist namelist.$RES.$YR
```

4. Run `mksurfdata_map` via an interactive job.

```
salloc --nodes 1 --qos interactive --time 01:00:00 --constraint cpu --account e3sm
RES=0.5x0.5
YR=1950
NAMELIST=namelist.$RES.$YR
srun -n 1 ./mksurfdata_map < $NAMELIST
```

0 comments on commit ff40c9c

Please sign in to comment.