diff --git a/env/HERA.env b/env/HERA.env index 0f903611c5e..d61c738cd07 100755 --- a/env/HERA.env +++ b/env/HERA.env @@ -270,6 +270,8 @@ elif [[ "${step}" = "init" ]]; then elif [[ "${step}" = "postsnd" ]]; then + export CFP_MP="YES" + nth_max=$((npe_node_max / npe_node_postsnd)) export NTHREADS_POSTSND=${nth_postsnd:-1} @@ -278,7 +280,7 @@ elif [[ "${step}" = "postsnd" ]]; then export NTHREADS_POSTSNDCFP=${nth_postsndcfp:-1} [[ ${NTHREADS_POSTSNDCFP} -gt ${nth_max} ]] && export NTHREADS_POSTSNDCFP=${nth_max} - export APRUN_POSTSNDCFP="${launcher} -n ${npe_postsnd} ${mpmd_opt}" + export APRUN_POSTSNDCFP="${launcher} -n ${npe_postsndcfp} ${mpmd_opt}" elif [[ "${step}" = "awips" ]]; then diff --git a/env/ORION.env b/env/ORION.env index 61f6105eb3b..a05d1bcec0a 100755 --- a/env/ORION.env +++ b/env/ORION.env @@ -268,6 +268,8 @@ elif [[ "${step}" = "init" ]]; then elif [[ "${step}" = "postsnd" ]]; then + export CFP_MP="YES" + nth_max=$((npe_node_max / npe_node_postsnd)) export NTHREADS_POSTSND=${nth_postsnd:-1} @@ -276,7 +278,7 @@ elif [[ "${step}" = "postsnd" ]]; then export NTHREADS_POSTSNDCFP=${nth_postsndcfp:-1} [[ ${NTHREADS_POSTSNDCFP} -gt ${nth_max} ]] && export NTHREADS_POSTSNDCFP=${nth_max} - export APRUN_POSTSNDCFP="${launcher} -n ${npe_postsnd} ${mpmd_opt}" + export APRUN_POSTSNDCFP="${launcher} -n ${npe_postsndcfp} ${mpmd_opt}" elif [[ "${step}" = "awips" ]]; then diff --git a/env/S4.env b/env/S4.env index a4a156dd191..25e335e334e 100755 --- a/env/S4.env +++ b/env/S4.env @@ -270,6 +270,8 @@ elif [[ ${step} = "init" ]]; then elif [[ ${step} = "postsnd" ]]; then + export CFP_MP="YES" + npe_node_postsnd=${npe_node_postsnd:-${npe_node_max}} nth_max=$((npe_node_max / npe_node_postsnd)) diff --git a/scripts/exgfs_atmos_postsnd.sh b/scripts/exgfs_atmos_postsnd.sh index 114ab4e2344..44676f122ab 100755 --- a/scripts/exgfs_atmos_postsnd.sh +++ b/scripts/exgfs_atmos_postsnd.sh @@ -137,34 +137,23 @@ fi # Create Regional Collectives of BUFR data and # add appropriate WMO Headers. ######################################## -collect=' 1 2 3 4 5 6 7 8 9' -if [ $machine == "HERA" -o $machine == "JET" ]; then -for m in ${collect} -do -sh $USHbufrsnd/gfs_sndp.sh $m -done - -################################################ -# Convert the bufr soundings into GEMPAK files -################################################ -sh $USHbufrsnd/gfs_bfr2gpk.sh - -else rm -rf poe_col -for m in ${collect} -do -echo "sh $USHbufrsnd/gfs_sndp.sh $m " >> poe_col +for (( m = 1; m <10 ; m++ )); do + echo "sh ${USHbufrsnd}/gfs_sndp.sh ${m} " >> poe_col done -mv poe_col cmdfile +if [[ ${CFP_MP:-"NO"} == "YES" ]]; then + nl -n ln -v 0 poe_col > cmdfile +else + mv poe_col cmdfile +fi cat cmdfile chmod +x cmdfile ${APRUN_POSTSNDCFP} cmdfile -sh $USHbufrsnd/gfs_bfr2gpk.sh -fi +sh "${USHbufrsnd}/gfs_bfr2gpk.sh" ############## END OF SCRIPT ####################### diff --git a/ush/gfs_bufr.sh b/ush/gfs_bufr.sh index 1e8ad8cde0b..65d81ce5213 100755 --- a/ush/gfs_bufr.sh +++ b/ush/gfs_bufr.sh @@ -50,13 +50,12 @@ cat << EOF > gfsparm / EOF -hh=${FSTART} -while (( hh <= FEND )); do - hh2=$(printf %02i ${hh}) - hh3=$(printf %03i ${hh}) +for (( hr = 10#${FSTART}; hr <= 10#${FEND}; hr = hr + 10#${FINT} )); do + hh2=$(printf %02i "${hr}") + hh3=$(printf %03i "${hr}") -#--------------------------------------------------------- -# Make sure all files are available: + #--------------------------------------------------------- + # Make sure all files are available: ic=0 while (( ic < 1000 )); do if [ ! -f "${COMIN}/${RUN}.${cycle}.logf${hh3}.${logfm}" ]; then @@ -71,11 +70,9 @@ while (( hh <= FEND )); do exit 2 fi done -#------------------------------------------------------------------ + #------------------------------------------------------------------ ln -sf "${COMIN}/${RUN}.${cycle}.atmf${hh3}.${atmfm}" "sigf${hh2}" ln -sf "${COMIN}/${RUN}.${cycle}.sfcf${hh3}.${atmfm}" "flxf${hh2}" - - hh=$((hh + FINT)) done # define input BUFR table file.