Skip to content

Commit

Permalink
Feature/aq mv7 release v11 (#1009)
Browse files Browse the repository at this point in the history
* update jaqm_forecast_manager.ecf

* update post scripts for posting grib2 files on NOMADS

* clean up exaqm_post_stat scripts
  • Loading branch information
JianpingHuang-NOAA authored Feb 7, 2024
1 parent 9198b6a commit 567da2b
Show file tree
Hide file tree
Showing 7 changed files with 76 additions and 21 deletions.
5 changes: 0 additions & 5 deletions ecf/scripts/forecast/jaqm_forecast_manager.ecf
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,6 @@ export cyc="%CYC%"
############################################################
module load intel/${intel_ver}
module load craype/${craype_ver}
module load cray-mpich/${cray_mpich_ver}
module load cray-pals/${cray_pals_ver}
module load hdf5/${hdf5_ver}
module load netcdf/${netcdf_ver}
module load python/${python_ver}

module list

Expand Down
1 change: 1 addition & 0 deletions jobs/JAQM_FORECAST
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ export RUN="${RUN:-${RUN_dfv}}"
export umbrella_forecast_data=${DATAROOT}/${RUN}_forecast_${cyc}_${aqm_ver}
# exception handling for retro case
if [ -d ${umbrella_forecast_data}/RESTART_ORG ]; then
[[ -d ${DATAROOT}/${RUN}_forecast_${cyc}_${aqm_ver}-BAK ]] && rm -rf ${DATAROOT}/${RUN}_forecast_${cyc}_${aqm_ver}-BAK
mv ${umbrella_forecast_data} ${DATAROOT}/${RUN}_forecast_${cyc}_${aqm_ver}-BAK
fi

Expand Down
7 changes: 6 additions & 1 deletion scripts/exaqm_bias_correction_o3.sh
Original file line number Diff line number Diff line change
Expand Up @@ -362,6 +362,8 @@ EOF1
if [ "$SENDDBN" = "YES" ]; then
${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_1hr_o3_bc.227.grib2
${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_8hr_o3_bc.227.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_1hr_o3_bc.793.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_8hr_o3_bc.793.grib2
fi

# Add WMO header for daily 1h and 8h max O3
Expand Down Expand Up @@ -435,9 +437,12 @@ if [ "${cyc}" = "06" ] || [ "${cyc}" = "12" ]; then
fi

if [ "${SENDDBN}" = "YES" ] ; then
${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_o3_bc.227.grib2
#${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_o3_bc.227.grib2
if [ "${cyc}" = "06" ] || [ "${cyc}" = "12" ]; then
${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_o3_bc.227.grib2
${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_8hr_o3_bc.227.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_o3_bc.793.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_8hr_o3_bc.793.grib2
fi
fi

Expand Down
3 changes: 3 additions & 0 deletions scripts/exaqm_bias_correction_pm25.sh
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,8 @@ EOF1
if [ "${SENDDBN}" = "YES" ]; then
${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_1hr_pm25_bc.227.grib2
${DBNROOT}/bin/dbn_alert MODEL AQM_PM ${job} ${COMOUT}/${NET}.${cycle}.ave_24hr_pm25_bc.227.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_1hr_pm25_bc.793.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_PM ${job} ${COMOUT}/${NET}.${cycle}.ave_24hr_pm25_bc.793.grib2
fi
fi

Expand All @@ -369,6 +371,7 @@ cp tmpfile_pm25_bc ${COMOUT}/${NET}.${cycle}.ave_1hr_pm25_bc.${id_domain}.grib2
cp ${NET}.${cycle}.grib2_pm25_bc.227 ${COMOUT}/${NET}.${cycle}.ave_1hr_pm25_bc.227.grib2
if [ "${SENDDBN}" = "YES" ]; then
${DBNROOT}/bin/dbn_alert MODEL AQM_PM ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_pm25_bc.227.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_PM ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_pm25_bc.793.grib2
fi

#--------------------------------------------------------------
Expand Down
3 changes: 3 additions & 0 deletions scripts/exaqm_fire_emission.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,11 @@ export pgm=aqm_fire_emission
#
#-----------------------------------------------------------------------
#

. $USHaqm/source_util_funcs.sh

source_config_for_task "cpl_aqm_parm|task_fire_emission" ${GLOBAL_VAR_DEFNS_FP}

#
#-----------------------------------------------------------------------
#
Expand Down
36 changes: 31 additions & 5 deletions scripts/exaqm_post_stat_o3.sh
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,16 @@ while [ ${fhr} -le ${FCST_LEN_HRS} ]; do
(( fhr=fhr+1 ))
done

cp ${DATA}/${NET}.${cycle}.ave_1hr_o3.${id_domain}.grib2 ${COMOUT}

if [ "${cyc}" = "06" ] || [ "${cyc}" = "12" ]; then
cp ${DATA}/${NET}.${cycle}.ave_8hr_o3.${id_domain}.grib2 ${COMOUT}
# if [ "$SENDDBN" = "YES" ]; then
# ${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_o3.${id_domain}.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_8hr_o3.${id_domain}.grib2
# fi
fi

grid227="lambert:265.0000:25.0000:25.0000 226.5410:1473:5079.000 12.1900:1025:5079.000"
grid196="mercator:20.0000 198.4750:321:2500.000:206.1310 18.0730:255:2500.000:23.0880"
grid198="nps:210.0000:60.0000 181.4290:825:5953.000 40.5300:553:5953.000"
Expand Down Expand Up @@ -161,10 +171,20 @@ for grid in 227 196 198;do
tocgrib2super < ${PARMaqm}/aqm_utils/wmo/grib2_aqm_ave_${hr}hr_o3-awpozcon.${cycle}.${grid}
done

cp ${DATA}/${NET}.${cycle}.ave_1hr_o3*grib2 ${COMOUT}
cp ${DATA}/${NET}.${cycle}.ave_8hr_o3*grib2 ${COMOUT}
cp ${DATA}/awpaqm.${cycle}.1ho3*grib2 ${PCOM}
cp ${DATA}/awpaqm.${cycle}.8ho3*grib2 ${PCOM}
cp ${DATA}/${NET}.${cycle}.ave_1hr_o3.${grid}.grib2 ${COMOUT}
cp ${DATA}/${NET}.${cycle}.ave_8hr_o3.${grid}.grib2 ${COMOUT}
cp ${DATA}/awpaqm.${cycle}.1ho3.${grid}.grib2 ${PCOM}
cp ${DATA}/awpaqm.${cycle}.8ho3.${grid}.grib2 ${PCOM}

if [ "$SENDDBN" = "YES" ]; then
${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_o3.${grid}.grib2
${DBNROOT}/bin/dbn_alert MODEL AQM_CONC ${job} ${COMOUT}/${NET}.${cycle}.ave_8hr_o3.${grid}.grib2
fi

if [ "$SENDDBN_NTC" = "YES" ]; then
${DBNROOT}/bin/dbn_alert ${DBNALERT_TYPE} ${NET} ${job} ${PCOM}/awpaqm.${cycle}.1ho3.${grid}.grib2
${DBNROOT}/bin/dbn_alert ${DBNALERT_TYPE} ${NET} ${job} ${PCOM}/awpaqm.${cycle}.8ho3.${grid}.grib2
fi

for var in awpozcon;do
cp ${DATA}/${NET}.${cycle}.${var}*grib2 ${COMOUT}
Expand Down Expand Up @@ -243,6 +263,12 @@ EOF1
wgrib2 aqm-maxi.${id_domain}.grib2 |grep "OZMAX1" | wgrib2 -i aqm-maxi.${id_domain}.grib2 -grib ${NET}.${cycle}.max_1hr_o3.${id_domain}.grib2
wgrib2 aqm-maxi.${id_domain}.grib2 |grep "OZMAX8" | wgrib2 -i aqm-maxi.${id_domain}.grib2 -grib ${NET}.${cycle}.max_8hr_o3.${id_domain}.grib2

cp ${DATA}/${NET}.${cycle}.max_*hr_o3.${id_domain}.grib2 ${COMOUT}
# if [ "$SENDDBN" = "YES" ]; then
# ${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_1hr_o3.${id_domain}.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_8hr_o3.${id_domain}.grib2
# fi

grid227="lambert:265.0000:25.0000:25.0000 226.5410:1473:5079.000 12.1900:1025:5079.000"
grid196="mercator:20.0000 198.4750:321:2500.000:206.1310 18.0730:255:2500.000:23.0880"
grid198="nps:210.0000:60.0000 181.4290:825:5953.000 40.5300:553:5953.000"
Expand All @@ -252,7 +278,7 @@ EOF1
wgrib2 ${NET}.${cycle}.max_8hr_o3.${id_domain}.grib2 -set_grib_type c3b -new_grid_winds earth -new_grid ${!gg} ${NET}.${cycle}.max_8hr_o3.${grid}.grib2
wgrib2 ${NET}.${cycle}.max_1hr_o3.${id_domain}.grib2 -set_grib_type c3b -new_grid_winds earth -new_grid ${!gg} ${NET}.${cycle}.max_1hr_o3.${grid}.grib2

cp ${DATA}/${NET}.${cycle}.max_*hr_o3.*.grib2 ${COMOUT}
cp ${DATA}/${NET}.${cycle}.max_*hr_o3.${grid}.grib2 ${COMOUT}
if [ "$SENDDBN" = "YES" ]; then
${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_1hr_o3.${grid}.grib2
${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_8hr_o3.${grid}.grib2
Expand Down
42 changes: 32 additions & 10 deletions scripts/exaqm_post_stat_pm25.sh
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,13 @@ if [ -e "${pgmout}" ]; then
fi
cat ${NET}.${cycle}.pm25.*.${id_domain}.grib2 >> ${NET}.${cycle}.ave_1hr_pm25.${id_domain}.grib2

cp ${DATA}/${NET}.${cycle}.ave_1hr_pm25.${id_domain}.grib2 ${COMOUT}
#if [ "${cyc}" = "06" ] || [ "${cyc}" = "12" ]; then
# if [ "$SENDDBN" = "YES" ]; then
# ${DBNROOT}/bin/dbn_alert MODEL AQM_PM ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_pm25.${id_domain}.grib2
# fi
#fi

export grid227="lambert:265.0000:25.0000:25.0000 226.5410:1473:5079.000 12.1900:1025:5079.000"
#export grid148="lambert:263.0000:33.0000:45.0000 239.3720:442:12000.000 21.8210:265:12000.000"
export grid196="mercator:20.0000 198.4750:321:2500.000:206.1310 18.0730:255:2500.000:23.0880"
Expand All @@ -128,7 +135,7 @@ for grid in 227 196 198; do
done

cp ${DATA}/${NET}.${cycle}*pm25*.grib2 ${COMOUT}

# Create AWIPS GRIB2 data for Bias-Corrected PM2.5
if [ "${cyc}" = "06" ] || [ "${cyc}" = "12" ]; then
for grid in 227 198 196; do
Expand All @@ -140,17 +147,25 @@ if [ "${cyc}" = "06" ] || [ "${cyc}" = "12" ]; then
export FORT51=${NET}.${cycle}.ave_1hr_pm25.${grid}.grib2.temp
tocgrib2super < ${PARMaqm}/aqm_utils/wmo/grib2_aqm_1hpm25.${cycle}.${grid}

echo `ls -l ${NET}.${cycle}.grib2_pm25.${grid}.temp | awk '{print $5} '` > filesize
echo `ls -l ${NET}.${cycle}.ave_1hr_pm25.${grid}.grib2.temp | awk '{print $5} '` > filesize
export XLFRTEOPTS="unit_vars=yes"
export FORT11=${NET}.${cycle}.ave_1hr_pm25.${grid}.grib2.temp
export FORT12="filesize"
export FORT31=
export FORT51=awpaqm.${cycle}.1hpm25.${grid}.grib2
tocgrib2super < ${PARMaqm}/aqm_utils/wmo/grib2_aqm_1hpm25.${cycle}.${grid}

if [ "$SENDDBN" = "YES" ]; then
${DBNROOT}/bin/dbn_alert MODEL AQM_PM ${job} ${COMOUT}/${NET}.${cycle}.ave_1hr_pm25.${grid}.grib2
fi

# Post Files to PCOM
cp awpaqm.${cycle}.1hpm25.${grid}.grib2 ${PCOM}

if [ "$SENDDBN_NTC" = "YES" ]; then
${DBNROOT}/bin/dbn_alert ${DBNALERT_TYPE} ${NET} ${job} ${PCOM}/awpaqm.${cycle}.1hpm25.${grid}.grib2
fi

done
fi

Expand Down Expand Up @@ -219,6 +234,14 @@ EOF1
wgrib2 ${NET}_pm25_24h_ave.${id_domain}.grib2 |grep "PMTF" | wgrib2 -i ${NET}_pm25_24h_ave.${id_domain}.grib2 -grib ${NET}.${cycle}.ave_24hr_pm25.${id_domain}.grib2
wgrib2 ${NET}_pm25_24h_ave.${id_domain}.grib2 |grep "PDMAX1" | wgrib2 -i ${NET}_pm25_24h_ave.${id_domain}.grib2 -grib ${NET}.${cycle}.max_1hr_pm25.${id_domain}.grib2

cp ${DATA}/${NET}.${cycle}.ave_24hr_pm25.${id_domain}.grib2 ${COMOUT}
cp ${DATA}/${NET}.${cycle}.max_1hr_pm25.${id_domain}.grib2 ${COMOUT}

# if [ "$SENDDBN" = "YES" ]; then
# ${DBNROOT}/bin/dbn_alert MODEL AQM_PM ${job} ${COMOUT}/${NET}.${cycle}.ave_24hr_pm25.${id_domain}.grib2
# ${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_1hr_pm25.${id_domain}.grib2
# fi

export grid227="lambert:265.0000:25.0000:25.0000 226.5410:1473:5079.000 12.1900:1025:5079.000"
export grid196="mercator:20.0000 198.4750:321:2500.000:206.1310 18.0730:255:2500.000:23.0880"
export grid198="nps:210.0000:60.0000 181.4290:825:5953.000 40.5300:553:5953.000"
Expand All @@ -230,6 +253,12 @@ EOF1

cp ${DATA}/${NET}.${cycle}.ave_24hr_pm25.${grid}.grib2 ${COMOUT}
cp ${DATA}/${NET}.${cycle}.max_1hr_pm25.${grid}.grib2 ${COMOUT}

if [ "$SENDDBN" = "YES" ]; then
${DBNROOT}/bin/dbn_alert MODEL AQM_PM ${job} ${COMOUT}/${NET}.${cycle}.ave_24hr_pm25.${grid}.grib2
${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${COMOUT}/${NET}.${cycle}.max_1hr_pm25.${grid}.grib2
fi

# Add WMO header for daily 1h PM2.5 and 24hr_ave PM2.5
rm -f filesize
echo 0 > filesize
Expand Down Expand Up @@ -265,8 +294,6 @@ EOF1
export FORT51=awpaqm.${cycle}.24hr-pm25-ave.${grid}.grib2
tocgrib2super < ${PARMaqm}/aqm_utils/wmo/grib2_aqm_ave_24hrpm25_awp.${cycle}.${grid}

cp ${DATA}/${NET}.${cycle}.ave_24hr_pm25*.grib2 ${COMOUT}
cp ${DATA}/${NET}.${cycle}.max_1hr_pm25*.grib2 ${COMOUT}
cp awpaqm.${cycle}.daily-1hr-pm25-max.${grid}.grib2 ${PCOM}
cp awpaqm.${cycle}.24hr-pm25-ave.${grid}.grib2 ${PCOM}

Expand All @@ -275,14 +302,9 @@ EOF1
##############################

if [ "${SENDDBN_NTC}" = "YES" ] ; then
${DBNROOT}/bin/dbn_alert ${DBNALERT_TYPE} ${NET} ${job} ${PCOM}/awpaqm.${cycle}.1hpm25.${grid}.grib2
${DBNROOT}/bin/dbn_alert ${DBNALERT_TYPE} ${NET} ${job} ${PCOM}/awpaqm.${cycle}.24hr-pm25-ave.${grid}.grib2
${DBNROOT}/bin/dbn_alert ${DBNALERT_TYPE} ${NET} ${job} ${PCOM}/awpaqm.${cycle}.daily-1hr-pm25-max.${grid}.grib2
fi

if [ "$SENDDBN" = "YES" ]; then
${DBNROOT}/bin/dbn_alert MODEL AQM_PM ${job} ${PCOM}/awpaqm.${cycle}.24hr-pm25-ave.${grid}.grib2
${DBNROOT}/bin/dbn_alert MODEL AQM_MAX ${job} ${PCOM}/awpaqm.${cycle}.daily-1hr-pm25-max.${grid}.grib2
fi
done
fi

Expand Down

0 comments on commit 567da2b

Please sign in to comment.