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

Add domain level to wave gridded COM path #3137

Open
wants to merge 122 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 115 commits
Commits
Show all changes
122 commits
Select commit Hold shift + click to select a range
b6a732e
modified config.com
AntonMFernando-NOAA Dec 3, 2024
0a5ca0e
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 3, 2024
cb496d1
modified jobs\JGLOBAL_EXTRACTVARS
AntonMFernando-NOAA Dec 3, 2024
3492b8c
modified jobs\JGLOBAL_WAVE_POST_SBS
AntonMFernando-NOAA Dec 3, 2024
92cba9c
modified jobs\JGLOBAL_WAVE_PRDGEN_GRIDDED
AntonMFernando-NOAA Dec 4, 2024
a0aa55b
updated the relevant yaml files
AntonMFernando-NOAA Dec 4, 2024
fe0f375
Merge branch 'NOAA-EMC:develop' into wavegrid_compath
AntonMFernando-NOAA Dec 4, 2024
52eda4b
modified parm\archive\gefs_extracted_wave.yaml.j2
AntonMFernando-NOAA Dec 4, 2024
2f220ea
Merge branch 'NOAA-EMC:develop' into wavegrid_compath
AntonMFernando-NOAA Dec 5, 2024
c2ce78f
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 5, 2024
403a395
Merge branch 'wavegrid_compath' of https://github.com/AntonMFernando-…
AntonMFernando-NOAA Dec 5, 2024
261c833
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 5, 2024
8b01949
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 5, 2024
257cd4a
modified typos JGLOBAL_ARCHIVE and JGLOBAL_WAVE_POST_SBS
AntonMFernando-NOAA Dec 5, 2024
4674706
modifed jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 5, 2024
bac1bb9
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 5, 2024
477df47
modified jobs\JGLOBAL_EXTRACTVARS
AntonMFernando-NOAA Dec 5, 2024
f1e54ba
modified jobs\JGLOBAL_WAVE_POST_SBS
AntonMFernando-NOAA Dec 5, 2024
a91797e
modified jobs\JGLOBAL_WAVE_POST_SBS
AntonMFernando-NOAA Dec 5, 2024
832141f
modified jobs\JGLOBAL_WAVE_POST_SBS
AntonMFernando-NOAA Dec 5, 2024
cccf13a
modified JGLOBAL
AntonMFernando-NOAA Dec 5, 2024
2ce47a6
modified JGLOBAL jobs
AntonMFernando-NOAA Dec 6, 2024
fd3e0e4
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 6, 2024
75bb84a
modified jobs\JGLOBAL_WAVE_PRDGEN_GRIDDED
AntonMFernando-NOAA Dec 6, 2024
acee85c
modified JGLOBAl scripts
AntonMFernando-NOAA Dec 6, 2024
da77adb
modified JGLOBAl srcipts
AntonMFernando-NOAA Dec 6, 2024
e94833c
Merge branch 'develop' into wavegrid_compath
AntonMFernando-NOAA Dec 9, 2024
0d16694
Merge branch 'develop' into wavegrid_compath
AntonMFernando-NOAA Dec 9, 2024
3f547c6
modified yamls
AntonMFernando-NOAA Dec 10, 2024
8092065
modified jobs\JGLOBAL_WAVE_POST_SBS
AntonMFernando-NOAA Dec 10, 2024
84bb387
modified JGLOBAL files and yaml files
AntonMFernando-NOAA Dec 10, 2024
4ef4cf8
modified jobs\JGLOBAL_EXTRACTVARS
AntonMFernando-NOAA Dec 11, 2024
4a74e55
modified jobs\JGLOBAL_EXTRACTVARS
AntonMFernando-NOAA Dec 11, 2024
72ef7ed
modified WAVE_PRDGEN_GRIDDED scripts
AntonMFernando-NOAA Dec 11, 2024
13cb413
modified JGLOBAL scripts
AntonMFernando-NOAA Dec 11, 2024
4424330
modified yaml files
AntonMFernando-NOAA Dec 11, 2024
7328021
modifed ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 12, 2024
8a15b34
modified sh scripts
AntonMFernando-NOAA Dec 12, 2024
df91f12
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 12, 2024
f9022dc
modified sh scripts
AntonMFernando-NOAA Dec 12, 2024
aa89cea
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 12, 2024
7feba53
Merge branch 'develop' into wavegrid_compath
AntonMFernando-NOAA Dec 12, 2024
df06e3d
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 12, 2024
e100663
Merge branch 'NOAA-EMC:develop' into wavegrid_compath
AntonMFernando-NOAA Dec 13, 2024
670150e
modifed scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 13, 2024
903651e
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
de46766
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
128b795
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
4ca3eee
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
f71079d
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
8a3ee56
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
c76bca8
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
deedc41
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
ca1ec7e
modifed scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
909bbde
modified sh scripts
AntonMFernando-NOAA Dec 14, 2024
7345a00
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
0e883e2
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
1bb734d
Merge branch 'develop' into wavegrid_compath
AntonMFernando-NOAA Dec 14, 2024
84d07d5
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
73c9798
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
38b102c
modified sh scripts
AntonMFernando-NOAA Dec 14, 2024
9cc88ee
modified ush\wave_grib2_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
cffdf5f
modified sh scripts
AntonMFernando-NOAA Dec 14, 2024
dc8426d
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
a2d0db2
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
ada6bf5
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
93e11db
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
5af3e06
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
1197a98
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
d314b3d
modified wave scripts
AntonMFernando-NOAA Dec 14, 2024
f58a972
modified jobs\JGLOBAL_WAVE_POST_SBS
AntonMFernando-NOAA Dec 14, 2024
ac2cf81
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 14, 2024
805fe00
Merge branch 'NOAA-EMC:develop' into wavegrid_compath
AntonMFernando-NOAA Dec 16, 2024
2a5a464
remove path from config.com and yamls
AntonMFernando-NOAA Dec 16, 2024
9627ffb
modified yamls files
AntonMFernando-NOAA Dec 16, 2024
9abd685
modified parm\archive\gefs_extracted_wave.yaml.j2
AntonMFernando-NOAA Dec 16, 2024
33fc0d5
modify jobs\JGLOBAL_WAVE_PRDGEN_GRIDDED
AntonMFernando-NOAA Dec 16, 2024
922c959
modified jobs\JGLOBAL_WAVE_PRDGEN_GRIDDED
AntonMFernando-NOAA Dec 16, 2024
df7ae3f
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 16, 2024
f9ee0a5
modified scripts\exgfs_wave_prdgen_gridded.sh
AntonMFernando-NOAA Dec 16, 2024
05492e8
modified jobs\JGLOBAL_EXTRACTVARS
AntonMFernando-NOAA Dec 16, 2024
49deb1a
modified scripts\exgfs_wave_prdgen_gridded.sh
AntonMFernando-NOAA Dec 16, 2024
2446f7d
modified ush\wave_extractvars.sh
AntonMFernando-NOAA Dec 16, 2024
b477638
Merge branch 'NOAA-EMC:develop' into wavegrid_compath
AntonMFernando-NOAA Dec 16, 2024
852371f
modified yaml files
AntonMFernando-NOAA Dec 17, 2024
054d8c9
Merge branch 'wavegrid_compath' of https://github.com/AntonMFernando-…
AntonMFernando-NOAA Dec 17, 2024
e0892ca
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 17, 2024
e491b50
modified parm\archive\gefs_extracted_wave.yaml.j2
AntonMFernando-NOAA Dec 17, 2024
b3ffd3c
modified parm\archive\gefs_extracted_wave.yaml.j2
AntonMFernando-NOAA Dec 17, 2024
4abd558
modified parm\archive\gefs_extracted_wave.yaml.j2
AntonMFernando-NOAA Dec 18, 2024
fce5b42
modified gfswave.yaml.j2
AntonMFernando-NOAA Dec 18, 2024
e174626
modified parm\archive\gefs_extracted_wave.yaml.j2
AntonMFernando-NOAA Dec 18, 2024
c24fb1f
modified scripts\exglobal_extractvars.sh
AntonMFernando-NOAA Dec 18, 2024
34f8d72
Merge branch 'develop' into wavegrid_compath
AntonMFernando-NOAA Dec 18, 2024
6ba4f73
adding a function to the scripts
AntonMFernando-NOAA Dec 19, 2024
b824970
modified function related stuff
AntonMFernando-NOAA Dec 19, 2024
5246106
modified ush\wave_domain_grid.sh
AntonMFernando-NOAA Dec 19, 2024
7354fff
modified ush\wave_domain_grid.sh
AntonMFernando-NOAA Dec 19, 2024
2da9187
modified the function
AntonMFernando-NOAA Dec 19, 2024
853d0fa
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 19, 2024
7f76c14
modified scripts\exgfs_wave_post_gridded_sbs.sh
AntonMFernando-NOAA Dec 19, 2024
faf873b
modified the function
AntonMFernando-NOAA Dec 19, 2024
56cde14
modifief gridded sh
AntonMFernando-NOAA Dec 20, 2024
5319296
modified ush\wave_domain_grid.sh
AntonMFernando-NOAA Dec 20, 2024
494ac19
modified wave_extractvars and archive scripts
AntonMFernando-NOAA Dec 20, 2024
586793a
modified ush\wave_domain_grid.sh
AntonMFernando-NOAA Dec 20, 2024
d456d62
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 20, 2024
aaef28f
updated jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 20, 2024
7f22b5e
modifed jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 20, 2024
4fa01f4
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 20, 2024
d7d5ba8
Merge branch 'develop' into wavegrid_compath
AntonMFernando-NOAA Dec 20, 2024
51c4527
correcting shell check warnings
AntonMFernando-NOAA Dec 20, 2024
0feab4f
Merge branch 'wavegrid_compath' of https://github.com/AntonMFernando-…
AntonMFernando-NOAA Dec 20, 2024
54588fe
correcting shellcheck warnings
AntonMFernando-NOAA Dec 20, 2024
50ff441
modified jobs\JGLOBAL_ARCHIVE
AntonMFernando-NOAA Dec 20, 2024
3df7660
corrected typos
AntonMFernando-NOAA Dec 20, 2024
5d20aba
modified ush\wave_domain_grid.sh
AntonMFernando-NOAA Dec 20, 2024
f7a7dda
modified ush\wave_domain_grid.sh
AntonMFernando-NOAA Dec 20, 2024
0cbcec6
Merge branch 'develop' into wavegrid_compath
AntonMFernando-NOAA Dec 24, 2024
103b6ec
Merge branch 'develop' into wavegrid_compath
aerorahul Dec 26, 2024
cd397d7
Merge branch 'develop' into wavegrid_compath
AntonMFernando-NOAA Jan 2, 2025
8e90e65
Merge branch 'develop' into wavegrid_compath
AntonMFernando-NOAA Jan 3, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions jobs/JGLOBAL_ARCHIVE
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
source "${HOMEgfs}/ush/preamble.sh"
source "${HOMEgfs}/ush/jjob_header.sh" -e "arch" -c "base arch"

###############################################################
#select the correct domain.grid for gridded data
source "${USHgfs}/wave_domain_grid.sh"
process_grdID "${waveGRD}"
###############################################################

##############################################
# Set variables used in the script
Expand Down Expand Up @@ -49,7 +54,6 @@ for grid in "0p25" "0p50" "1p00"; do
YMD=${PDY} HH=${cyc} GRID=${grid} declare_from_tmpl -rx \
"COMIN_ATMOS_GRIB_${grid}:COM_ATMOS_GRIB_GRID_TMPL"
done

###############################################################
# Run archive script
###############################################################
Expand All @@ -68,8 +72,6 @@ status=$?
if [[ -e "${pgmout}" ]] ; then
cat "${pgmout}"
fi


##########################################
# Remove the Temporary working directory
##########################################
Expand Down
23 changes: 10 additions & 13 deletions parm/archive/gefs_extracted_wave.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ gefs_wave:
{% set ofst_hr = FHMIN_GFS %}
{% endif %}

{% set res = (waveGRD[-3:])[0] ~ "p" ~ (waveGRD[-3:])[-2:] %}

#select mem%03d and ensstat files required
{% set members = [] %}
{% for mem_nm in range(0, NMEM_ENS + 1) %}
Expand All @@ -27,17 +25,6 @@ gefs_wave:
'${YMD}':cycle_YMD,
'${HH}':cycle_HH,
'${MEMDIR}':mem }) %}

{% set COMIN_WAVE_GRID = COM_WAVE_GRID_TMPL | replace_tmpl(tmpl_dict) %}
# Select grib2 files to copy to the atardir
{% if path_exists(COMIN_WAVE_GRID) %}
{% for fhr in range(ofst_hr, FHMAX_GFS + FHOUT_WAV, FHOUT_WAV) %}
{% set file_name = head ~ "global." ~ res ~ ".f" ~ '%03d'|format(fhr) ~ ".grib2" %}
{% set file_path = COMIN_WAVE_GRID ~ "/" ~ file_name %}
- "{{ file_path | relpath(ROTDIR)}}"
{% endfor %}
{% endif %}

{% set COMIN_WAVE_STATION = COM_WAVE_STATION_TMPL | replace_tmpl(tmpl_dict) %}
# Select station files to copy to the atardir
{% if path_exists(COMIN_WAVE_STATION) %}
Expand All @@ -48,4 +35,14 @@ gefs_wave:
{% set file_path = COMIN_WAVE_STATION ~ "/" ~ RUN ~ "wave.t" ~ cycle_HH ~ "z.bull_tar" %}
- "{{ file_path | relpath(ROTDIR)}}"
{% endif %}

{% set COMIN_WAVE_GRID = COM_WAVE_GRID_TMPL | replace_tmpl(tmpl_dict) %}
# Select grib2 files to copy to the atardir
{% if path_exists(COMIN_WAVE_GRID) %}
{% for fhr in range(ofst_hr, FHMAX_GFS + FHOUT_WAV, FHOUT_WAV) %}
{% set file_name = head ~ grdNAME ~ ".f" ~ '%03d'|format(fhr) ~ ".grib2" %}
{% set file_path = COMIN_WAVE_GRID ~ "/" ~ grdNAME ~ "/" ~ file_name %}
- "{{ file_path | relpath(ROTDIR)}}"
{% endfor %}
{% endif %}
{% endfor %}
10 changes: 6 additions & 4 deletions parm/archive/gfswave.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,19 @@ gfswave:
target: "{{ ATARDIR }}/{{ cycle_YMDH }}/gfswave.tar"
required:
# Wave GRIB2 regional forecast products
{% set file_path = COMIN_WAVE_GRID ~ "/" ~ grdNAME %}

{% for fh in range(0, FHMAX_HF_WAV + FHOUT_HF_WAV, FHOUT_HF_WAV) %}
# NOTE This is as explicit as possible without major logic to parse wavepostGRD.
# Matches files of the form "gfswave.tCCz.<region>.<res>.fHHH.grib2".
- "{{ COMIN_WAVE_GRID | relpath(ROTDIR) }}/{{ head }}*.*.f{{ '%03d' % fh }}.grib2"
- "{{ COMIN_WAVE_GRID | relpath(ROTDIR) }}/{{ head }}*.*.f{{ '%03d' % fh }}.grib2.idx"
- "{{ file_path | relpath(ROTDIR) }}/{{ head }}*.*.f{{ '%03d' % fh }}.grib2"
- "{{ file_path | relpath(ROTDIR) }}/{{ head }}*.*.f{{ '%03d' % fh }}.grib2.idx"
{% endfor %}

# Global wave GRIB2 forecast products
{% for fh in range(FHMAX_HF_WAV + FHOUT_WAV, FHMAX_WAV_GFS + FHOUT_WAV, FHOUT_WAV) %}
- "{{ COMIN_WAVE_GRID | relpath(ROTDIR) }}/{{ head }}*.*.f{{ '%03d' % fh }}.grib2"
- "{{ COMIN_WAVE_GRID | relpath(ROTDIR) }}/{{ head }}*.*.f{{ '%03d' % fh }}.grib2.idx"
- "{{ file_path | relpath(ROTDIR) }}/{{ head }}*.*.f{{ '%03d' % fh }}.grib2"
- "{{ file_path | relpath(ROTDIR) }}/{{ head }}*.*.f{{ '%03d' % fh }}.grib2.idx"
{% endfor %}

# Wave bulletins
Expand Down
51 changes: 15 additions & 36 deletions scripts/exgfs_wave_post_gridded_sbs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -261,20 +261,8 @@ source "${USHgfs}/preamble.sh"
if [ "$DOGRB_WAV" = 'YES' ]
then
gribFL=\'$(echo ${OUTPARS_WAV})\'
case $grdID in
glo_15mxt) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
reg025) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
glo_025) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
glo_100) GRDNAME='global' ; GRDRES=1p00 ; GRIDNR=255 ; MODNR=11 ;;
glo_200) GRDNAME='global' ; GRDRES=2p00 ; GRIDNR=255 ; MODNR=11 ;;
glo_500) GRDNAME='global' ; GRDRES=5p00 ; GRIDNR=255 ; MODNR=11 ;;
glo_30mxt) GRDNAME='global' ; GRDRES=0p50 ; GRIDNR=255 ; MODNR=11 ;;
glo_30m) GRDNAME='global' ; GRDRES=0p50 ; GRIDNR=255 ; MODNR=11 ;;
at_10m) GRDNAME='atlocn' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
ep_10m) GRDNAME='epacif' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
wc_10m) GRDNAME='wcoast' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
ak_10m) GRDNAME='alaska' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
esac
source "${USHgfs}/wave_domain_grid.sh"
process_grdID "${grdID}"
echo "${USHgfs}/wave_grib2_sbs.sh $grdID $GRIDNR $MODNR $ymdh $fhr $GRDNAME $GRDRES $gribFL > grib_$grdID.out 2>&1" >> ${fcmdigrd}.${nigrd}
fi
echo "${GRIBDATA}/${fcmdigrd}.${nigrd}" >> ${fcmdnow}
Expand All @@ -288,23 +276,8 @@ source "${USHgfs}/preamble.sh"
for grdID in ${wavepostGRD} # First concatenate grib files for sbs grids
do
gribFL=\'$(echo ${OUTPARS_WAV})\'
case $grdID in
aoc_9km) GRDNAME='arctic' ; GRDRES=9km ; GRIDNR=255 ; MODNR=11 ;;
ant_9km) GRDNAME='antarc' ; GRDRES=9km ; GRIDNR=255 ; MODNR=11 ;;
glo_10m) GRDNAME='global' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
gnh_10m) GRDNAME='global' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
gsh_15m) GRDNAME='gsouth' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
glo_15m) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
ao_20m) GRDNAME='arctic' ; GRDRES=0p33 ; GRIDNR=255 ; MODNR=11 ;;
so_20m) GRDNAME='antarc' ; GRDRES=0p33 ; GRIDNR=255 ; MODNR=11 ;;
glo_15mxt) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
reg025) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
glo_025) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
glo_100) GRDNAME='global' ; GRDRES=1p00 ; GRIDNR=255 ; MODNR=11 ;;
glo_200) GRDNAME='global' ; GRDRES=2p00 ; GRIDNR=255 ; MODNR=11 ;;
glo_500) GRDNAME='global' ; GRDRES=5p00 ; GRIDNR=255 ; MODNR=11 ;;
gwes_30m) GRDNAME='global' ; GRDRES=0p50 ; GRIDNR=255 ; MODNR=10 ;;
esac
source "${USHgfs}/wave_domain_grid.sh"
process_grdID "${grdID}"
echo "${USHgfs}/wave_grib2_sbs.sh $grdID $GRIDNR $MODNR $ymdh $fhr $GRDNAME $GRDRES $gribFL > grib_$grdID.out 2>&1" >> ${fcmdnow}
done
fi
Expand Down Expand Up @@ -379,15 +352,21 @@ source "${USHgfs}/preamble.sh"
rm -f out_grd.* # Remove large binary grid output files

cd $DATA


if [ "$fhr" = "$fhrg" ]
then

if [ "$fhr" = "$fhrg" ]; then
Fixed Show fixed Hide fixed
Fixed Show fixed Hide fixed
# Check if grib2 file created
ENSTAG=""
if [ ${waveMEMB} ]; then ENSTAG=".${membTAG}${waveMEMB}" ; fi
gribchk="${RUN}wave.${cycle}${ENSTAG}.${GRDNAME}.${GRDRES}.f${FH3}.grib2"
if [ ! -s ${COMOUT_WAVE_GRID}/${gribchk} ]; then
gribchk_idx="${RUN}wave.${cycle}${ENSTAG}.${GRDNAME}.${GRDRES}.f${FH3}.grib2.idx"
if [[ ! -d "${COMOUT_WAVE_GRID}/${GRDNAME}.${GRDRES}" ]]; then
mkdir -m 775 -p "${COMOUT_WAVE_GRID}/${GRDNAME}.${GRDRES}"
fi
# move grib2 files to domain.dimension
if [[ -s "${COMOUT_WAVE_GRID}/${gribchk}" && -s "${COMOUT_WAVE_GRID}/${gribchk_idx}" ]]; then
mv -f "${COMOUT_WAVE_GRID}/${gribchk}" "${COMOUT_WAVE_GRID}/${GRDNAME}.${GRDRES}"
mv -f "${COMOUT_WAVE_GRID}/${gribchk_idx}" "${COMOUT_WAVE_GRID}/${GRDNAME}.${GRDRES}"
else
set +x
echo ' '
echo '********************************************'
Expand Down
6 changes: 3 additions & 3 deletions scripts/exgfs_wave_prdgen_gridded.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# - Supplemental error output is witten to the wave.log file. #
# #
# COM inputs: #
# - ${COMIN_WAVE_GRID}/${RUNwave}.${cycle}.${grdID}.f${fhr}.grib2 #
# - ${COMIN_WAVE_GRID}/${grdID}/${RUNwave}.${cycle}.${grdID}.f${fhr}.grib2 #
# #
# COM outputs: #
# - ${COMOUT_WAVE_WMO}/grib2.${cycle}.f${fhr}.awipsww3_${grdOut} #
Expand Down Expand Up @@ -89,7 +89,7 @@ grids=${grids:-ak_10m at_10m ep_10m wc_10m glo_30m}
fhr=$(printf "%03d" $fhcnt)
for grdOut in $grids;do
case $grdOut in
ao_9km) grdID='arctic.9km' ;;
aoc_9km) grdID='arctic.9km' ;;
at_10m) grdID='atlocn.0p16' ;;
ep_10m) grdID='epacif.0p16' ;;
wc_10m) grdID='wcoast.0p16' ;;
Expand All @@ -100,7 +100,7 @@ grids=${grids:-ak_10m at_10m ep_10m wc_10m glo_30m}
esac
#

GRIBIN="${COM_WAVE_GRID}/${RUNwave}.${cycle}.${grdID}.f${fhr}.grib2"
GRIBIN="${COM_WAVE_GRID}/${grdID}/${RUNwave}.${cycle}.${grdID}.f${fhr}.grib2"
GRIBIN_chk="${GRIBIN}.idx"
sleep_interval=5
max_tries=1000
Expand Down
2 changes: 1 addition & 1 deletion scripts/exglobal_archive.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def main():
'NMEM_ENS', 'DO_JEDIATMVAR', 'DO_VRFY_OCEANDA', 'FHMAX_FITS', 'waveGRD',
'IAUFHRS', 'DO_FIT2OBS', 'NET', 'FHOUT_HF_GFS', 'FHMAX_HF_GFS', 'REPLAY_ICS',
'OFFSET_START_HOUR', 'ARCH_EXPDIR', 'EXPDIR', 'ARCH_EXPDIR_FREQ', 'ARCH_HASHES',
'ARCH_DIFFS', 'SDATE', 'EDATE', 'HOMEgfs']
'ARCH_DIFFS', 'SDATE', 'EDATE', 'HOMEgfs', 'grdNAME']

archive_dict = AttrDict()
for key in keys:
Expand Down
40 changes: 40 additions & 0 deletions ush/wave_domain_grid.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
#! /usr/bin/env bash

################################################################################
## UNIX Script Documentation Block
## Script name: wave_domain_grid.sh
## Script description: provides the wave grid specific values that
## are needed for the wave related jobs
#######################
# Main body starts here
#######################

process_grdID() {
AntonMFernando-NOAA marked this conversation as resolved.
Show resolved Hide resolved
grdID=$1
case ${grdID} in
glo_10m) GRDNAME='global' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
glo_15mxt) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
glo_30mxt) GRDNAME='global' ; GRDRES=0p50 ; GRIDNR=255 ; MODNR=11 ;;
glo_30m) GRDNAME='global' ; GRDRES=0p50 ; GRIDNR=255 ; MODNR=11 ;;
glo_025) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
glo_100) GRDNAME='global' ; GRDRES=1p00 ; GRIDNR=255 ; MODNR=11 ;;
glo_200) GRDNAME='global' ; GRDRES=2p00 ; GRIDNR=255 ; MODNR=11 ;;
glo_500) GRDNAME='global' ; GRDRES=5p00 ; GRIDNR=255 ; MODNR=11 ;;
at_10m) GRDNAME='atlocn' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
ep_10m) GRDNAME='epacif' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
wc_10m) GRDNAME='wcoast' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
ak_10m) GRDNAME='alaska' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
aoc_9km) GRDNAME='arctic' ; GRDRES=9km ; GRIDNR=255 ; MODNR=11 ;;
ant_9km) GRDNAME='antarc' ; GRDRES=9km ; GRIDNR=255 ; MODNR=11 ;;
gnh_10m) GRDNAME='global' ; GRDRES=0p16 ; GRIDNR=255 ; MODNR=11 ;;
gsh_15m) GRDNAME='gsouth' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
ao_20m) GRDNAME='arctic' ; GRDRES=0p33 ; GRIDNR=255 ; MODNR=11 ;;
so_20m) GRDNAME='antarc' ; GRDRES=0p33 ; GRIDNR=255 ; MODNR=11 ;;
reg025) GRDNAME='global' ; GRDRES=0p25 ; GRIDNR=255 ; MODNR=11 ;;
gwes_30m) GRDNAME='global' ; GRDRES=0p50 ; GRIDNR=255 ; MODNR=10 ;;
*)
echo "FATAL ERROR: No grid specific wave config values exist for ${grdID}. Aborting."
exit 1 ;;
esac
export grdNAME="${GRDNAME}.${GRDRES}"
}
7 changes: 5 additions & 2 deletions ush/wave_extractvars.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,16 @@ source "${USHgfs}/preamble.sh"

subdata=${1}

source "${USHgfs}/wave_domain_grid.sh"
process_grdID "${waveGRD}"

[[ -d "${subdata}" ]] || mkdir -p "${subdata}"

for (( nh = FHOUT_WAV_EXTRACT; nh <= FHMAX_WAV; nh = nh + FHOUT_WAV_EXTRACT )); do
fnh=$(printf "%3.3d" "${nh}")

infile=${COMIN_WAVE_GRID}/${RUN}wave.t${cyc}z.global.${wavres}.f${fnh}.grib2
outfile=${subdata}/${RUN}wave.t${cyc}z.global.${wavres}.f${fnh}.grib2
infile="${COMIN_WAVE_GRID}/${GRDNAME}.${GRDRES}/${RUN}wave.t${cyc}z.global.${wavres}.f${fnh}.grib2"
outfile="${subdata}/${RUN}wave.t${cyc}z.global.${wavres}.f${fnh}.grib2"
rm -f "${outfile}" # Remove outfile if it already exists before extraction

if [[ -f "${infile}" ]]; then # Check if input file exists before extraction
Expand Down