forked from NOAA-EMC/WW3
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
run_unstr: add job card with two differing MPI runs, no warm start/re…
…start, though
- Loading branch information
1 parent
6539d8c
commit 5fa2dd8
Showing
1 changed file
with
86 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
#!/bin/bash | ||
|
||
#SBATCH -n 40 | ||
#SBATCH -q batch | ||
#SBATCH -t 01:00:00 | ||
#SBATCH -A marine-cpu | ||
#SBATCH -J w3_pdlib | ||
#SBATCH -o w3_pdlib.out | ||
#SBATCH --exclusive | ||
|
||
|
||
nProc=40 # nProc: highest MPI count should match, SBATCH -n <proc>, above | ||
mProc=20 # mProc: lowest MPI count should be less than nProc | ||
|
||
iostyp='1' # WW3 IOSTYP = [0, 1] | ||
|
||
|
||
REGDIR=$SLURM_SUBMIT_DIR | ||
module purge | ||
module use /scratch1/NCEPDEV/nems/role.epic/spack-stack/spack-stack-1.6.0/envs/unified-env-rocky8/install/modulefiles/Core | ||
module load stack-intel/2021.5.0 | ||
module load stack-intel-oneapi-mpi/2021.5.1 | ||
module load cmake/3.23.1 | ||
module load libpng/1.6.37 | ||
module load zlib/1.2.13 | ||
module load jasper/2.0.32 | ||
module load hdf5/1.14.0 | ||
module load netcdf-c/4.9.2 | ||
module load netcdf-fortran/4.6.1 | ||
module load bacio/2.4.1 | ||
module load g2/3.4.5 | ||
module load w3emc/2.10.0 | ||
module load esmf/8.5.0 | ||
module load scotch/7.0.4 | ||
export METIS_PATH=/scratch1/NCEPDEV/climate/Matthew.Masarik/waves/opt/hera/intel/spack-stack/1.6.0/parmetis-4.0.3/install | ||
|
||
|
||
# runs ww3_ufs1.1/unstr_rstrt(grid b) w ascii flag. grid b := block-explicit shceme | ||
function run_pdlib_ascii() { | ||
if [ $# -ne 1 ]; then echo 'usage: run_pdlib_ascii <numProc>'; return; fi | ||
local numProc=$1 | ||
./bin/run_cmake_test -b slurm -o all -S -T -s PDLIB_ASCII -i input_unstr_rstrt -w work_IOSTYP_${iostyp}_$numProc -g b -f -p srun -n $numProc ../model ww3_ufs1.1 | ||
return | ||
} | ||
|
||
|
||
cd $REGDIR | ||
|
||
echo ' ' | ||
echo ' **********************************************' | ||
echo ' *** WAVEWATCH III - PDLIB ***' | ||
echo ' **********************************************' | ||
echo ' ' | ||
export path_build_root=$REGDIR/build | ||
[[ -d ${path_build_root} ]] && rm -rf ${path_build_root} | ||
|
||
|
||
# N PROC - cold start | ||
# ------------------- | ||
echo -e "\nnProc: $nProc" | ||
cp -v ww3_ufs1.1/input_unstr_rstrt/ww3_shel.inp.start.IOSTYP_${iostyp} ww3_ufs1.1/input_unstr_rstrt/ww3_shel.inp | ||
run_pdlib_ascii $nProc | ||
|
||
# M PROC - cold start | ||
# ------------------- | ||
echo -e "\nmProc: $mProc" | ||
cp -v ww3_ufs1.1/input_unstr_rstrt/ww3_shel.inp.start.IOSTYP_${iostyp} ww3_ufs1.1/input_unstr_rstrt/ww3_shel.inp | ||
run_pdlib_ascii $mProc | ||
|
||
# compare NPROC v. MPROC - test.comp | ||
# ---------------------------------- | ||
./bin/test.comp ww3_ufs1.1 work_IOSTYP_${iostyp}_${nProc} work_IOSTYP_${iostyp}_${mProc} | ||
|
||
# check restart sizes (KB) | ||
du -k ww3_ufs1.1/work_IOSTYP_${iostyp}_${nProc}/*restart.ww3 | ||
du -k ww3_ufs1.1/work_IOSTYP_${iostyp}_${mProc}/*restart.ww3 | ||
|
||
|
||
echo -e "\ndone running." | ||
[[ -d ${path_build_root} ]] && rm -rf ${path_build_root}* | ||
echo ' ' | ||
echo ' **************************************************************' | ||
echo ' * end of WAVEWATCH III - PDLIB regtest *' | ||
echo ' **************************************************************' | ||
echo ' ' | ||
exit 0 |