Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
bf8b69a
update wave_sbs
AntonMFernando-NOAA Mar 19, 2026
44410fa
create restart dirs only when copying
AntonMFernando-NOAA Mar 23, 2026
8e82fc9
add NET specific logic
AntonMFernando-NOAA Mar 23, 2026
fbf9f85
update cpfs
AntonMFernando-NOAA Mar 25, 2026
6e801a6
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Mar 26, 2026
8510e0f
remove input files
AntonMFernando-NOAA Mar 26, 2026
7395367
Ensure output directory is created only after confirming input data e…
AntonMFernando-NOAA Mar 27, 2026
87d127a
Update archiving conditions for gcafs and gfs in YAML templates
AntonMFernando-NOAA Mar 27, 2026
93cd8fd
Remove redundant directory creation for COMOUT_ATMOS_TRACK and ensure…
AntonMFernando-NOAA Mar 28, 2026
a7f950e
update wxflow
AntonMFernando-NOAA Mar 30, 2026
e24f683
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Mar 30, 2026
fc2c357
wxflow add copy function
AntonMFernando-NOAA Mar 30, 2026
57c20b7
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Mar 30, 2026
d826acd
Remove unnecessary directory creation for wave station outputs and st…
AntonMFernando-NOAA Mar 30, 2026
473c15f
Revert "wxflow add copy function"
AntonMFernando-NOAA Mar 30, 2026
bf0837d
Update subproject commit reference in wxflow
AntonMFernando-NOAA Mar 30, 2026
c028c67
update wxflow to currect hash
AntonMFernando-NOAA Mar 30, 2026
d4c6d89
Remove redundant directory creation for ocean LETKF outputs
AntonMFernando-NOAA Mar 30, 2026
8078ef8
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Mar 31, 2026
36a4054
Remove redundant directory creation for wave output paths and ensure …
AntonMFernando-NOAA Mar 31, 2026
dcb090a
Remove redundant output directory creation before data processing
AntonMFernando-NOAA Mar 31, 2026
e9791b6
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Mar 31, 2026
2a842b0
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Apr 1, 2026
0c91afc
Update GOCART output command and ensure output directory exists
AntonMFernando-NOAA Apr 1, 2026
33ffcf7
Move varbc_params.tar to optional section in gdas_restarta.yaml.j2
AntonMFernando-NOAA Apr 1, 2026
79e24b7
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Apr 2, 2026
ea6aecd
Update gdas_restarta.yaml.j2 to include varbc_params.tar in required …
AntonMFernando-NOAA Apr 2, 2026
1a97667
Add directory creation for COM output and conditional file copying in…
AntonMFernando-NOAA Apr 3, 2026
4b2a123
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Apr 6, 2026
4123764
Update ush/forecast_predet.sh
AntonMFernando-NOAA Apr 6, 2026
f52a78f
Update dev/scripts/exglobal_atmos_sfcanl.sh
AntonMFernando-NOAA Apr 6, 2026
aa8a685
Update dev/jobs/JGLOBAL_ATMOS_SFCANL
AntonMFernando-NOAA Apr 6, 2026
1b6265f
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Apr 6, 2026
1cba43f
Update grib2 file generation to use 'c2' grib type for improved compa…
AntonMFernando-NOAA Apr 6, 2026
b659fe9
add simple packing
Apr 7, 2026
bee4160
add simple packing with c2 packing
Apr 7, 2026
5862563
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Apr 7, 2026
f9327a9
Merge branch 'NOAA-EMC:develop' into bug/warning_wave
AntonMFernando-NOAA Apr 8, 2026
81828b6
Refactor AnalysisStats initialization to accept analysis type as para…
AntonMFernando-NOAA Apr 8, 2026
45b6215
Remove unnecessary file tracking logic in save_obsdataout method
AntonMFernando-NOAA Apr 8, 2026
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
7 changes: 0 additions & 7 deletions dev/jobs/JGEFS_WAVE_STAT
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,7 @@ for grid in ${wavepostGRD}; do
process_grdID "${grid}"
prod_dir_grid="COMOUT_WAVE_GRID_${grid}"
declare -rx "${prod_dir_grid}"="${ROTDIR}/${RUN}.${PDY}/${cyc}/ensstat/products/wave/gridded"
if [[ ! -d "${!prod_dir_grid}" ]]; then
mkdir -m 775 -p "${!prod_dir_grid}"
fi
done
declare -rx COMOUT_WAVE_STATION_ENS="${ROTDIR}/${RUN}.${PDY}/${cyc}/ensstat/products/wave/station"
if [[ ! -d "${COMOUT_WAVE_STATION_ENS}" ]]; then
mkdir -m 775 -p "${COMOUT_WAVE_STATION_ENS}"
fi

# Execute the Script
#"${SCRglobal}/exgefs_wave_stat.sh"
Expand Down
7 changes: 0 additions & 7 deletions dev/jobs/JGEFS_WAVE_STAT_PNT
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,6 @@ source "${USHglobal}/jjob_shell_setup.sh"
# and exit on error in a pipeline (e.g. if a command in "cmd | cmd2" fails)
source "${USHglobal}/set_strict.sh"

# Set COM Paths

declare -rx COMOUT_WAVE_STATION_ENS="${ROTDIR}/${RUN}.${PDY}/${cyc}/ensstat/products/wave/station"
if [[ ! -d "${COMOUT_WAVE_STATION_ENS}" ]]; then
mkdir -m 775 -p "${COMOUT_WAVE_STATION_ENS}"
fi

# Execute the Script
#"${SCRglobal}/exgefs_wave_stat_pnt.sh"
export err=$?
Expand Down
1 change: 0 additions & 1 deletion dev/jobs/JGLOBAL_AERO_ANALYSIS_FINALIZE
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ declare -rx COMOUT_CONF="${ROTDIR}/${RUN}.${PDY}/${cyc}/conf"
declare -rx COMOUT_ATMOS_RESTART="${ROTDIR}/${RUN}.${PDY}/${cyc}/model/atmos/restart"

mkdir -m 755 -p "${COMOUT_CHEM_ANALYSIS}"
mkdir -m 755 -p "${COMOUT_ATMOS_RESTART}"
mkdir -m 755 -p "${COMOUT_CONF}"

###############################################################
Expand Down
1 change: 0 additions & 1 deletion dev/jobs/JGLOBAL_ANALYSIS_STATS
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ declare -rx COMIN_ATMOS_ANALYSIS="${ROTDIR}/${RUN}.${PDY}/${cyc}/analysis/atmos"
declare -rx COMOUT_ATMOS_ANALYSIS="${ROTDIR}/${RUN}.${PDY}/${cyc}/analysis/atmos"
declare -rx COMOUT_ATMOS_ANLMON="${ROTDIR}/${RUN}.${PDY}/${cyc}/products/atmos/anlmon"
mkdir -m 755 -p "${COMOUT_ATMOS_ANALYSIS}"
mkdir -m 755 -p "${COMOUT_ATMOS_ANLMON}"
mkdir -m 755 -p "${COMOUT_CONF}"

if [[ "${DO_AERO_ANL:-NO}" == "YES" ]]; then
Expand Down
2 changes: 0 additions & 2 deletions dev/jobs/JGLOBAL_ARCHIVE_TARS
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ declare -rx COMIN_SNOW_ANLMON="${COMIN}/products/snow/anlmon"
declare -rx COMIN_ICE_ANALYSIS="${COMIN}/analysis/ice"
declare -rx COMIN_ICE_BMATRIX="${COMIN}/bmatrix/ice"
declare -rx COMIN_ICE_HISTORY="${COMIN}/model/ice/history"
declare -rx COMIN_ICE_INPUT="${COMIN}/model/ice/input"
declare -rx COMIN_ICE_RESTART="${COMIN}/model/ice/restart"
declare -rx COMIN_ICE_GRIB="${COMIN}/products/ice/grib2"
declare -rx COMIN_ICE_NETCDF="${COMIN}/products/ice/netcdf"
Expand All @@ -79,7 +78,6 @@ declare -rx COMOUT_CONF="${COMOUT}/conf"
declare -rx COMOUT_ATMOS_TRACK="${COMOUT}/products/atmos/cyclone/tracks"

mkdir -p "${COMOUT_CONF}"
mkdir -p "${COMOUT_ATMOS_TRACK}"

for grid in "0p25" "0p50" "1p00"; do
declare -rx "COMIN_ATMOS_GRIB_${grid}"="${COMIN}/products/atmos/grib2/${grid}"
Expand Down
2 changes: 0 additions & 2 deletions dev/jobs/JGLOBAL_ATMOS_SFCANL
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ declare -rx COMOUT_ATMOS_RESTART="${ROTDIR}/${RUN}.${PDY}/${cyc}/model/atmos/res

declare -rx COMIN_ATMOS_ENKF_ANALYSIS_STAT="${ROTDIR}/enkfgdas.${PDY}/${cyc}/ensstat/analysis/atmos"

mkdir -p "${COMOUT_ATMOS_RESTART}"

# Use CFP to stage and save files in parallel
export USE_CFP=YES

Expand Down
2 changes: 0 additions & 2 deletions dev/jobs/JGLOBAL_FORECAST
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@ fi

if [[ "${DO_OCN}" == "YES" ]]; then
declare -rx COMIN_OCEAN_ANALYSIS="${COMIN}/analysis/ocean"
declare -rx COMIN_OCEAN_INPUT="${COMIN}/model/ocean/input"
declare -rx COMOUT_MED_RESTART="${COMOUT}/model/med/restart"
declare -rx COMOUT_OCEAN_RESTART="${COMOUT}/model/ocean/restart"
declare -rx COMOUT_OCEAN_HISTORY="${COMOUT}/model/ocean/history"
Expand All @@ -104,7 +103,6 @@ if [[ "${DO_OCN}" == "YES" ]]; then
fi

if [[ "${DO_ICE}" == "YES" ]]; then
declare -rx COMIN_ICE_INPUT="${COMIN}/model/ice/input"
declare -rx COMIN_ICE_ANALYSIS="${COMIN}/analysis/ice"
declare -rx COMOUT_ICE_RESTART="${COMOUT}/model/ice/restart"
declare -rx COMOUT_ICE_HISTORY="${COMOUT}/model/ice/history"
Expand Down
1 change: 0 additions & 1 deletion dev/jobs/JGLOBAL_MARINE_ANALYSIS_FINALIZE
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ declare -rx COMOUT_CONF="${ROTDIR}/${RUN}.${PDY}/${cyc}/conf"

mkdir -m 775 -p "${COMOUT_OCEAN_ANALYSIS}"
mkdir -m 775 -p "${COMOUT_ICE_ANALYSIS}"
mkdir -m 775 -p "${COMOUT_ICE_RESTART}"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is still used

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@AndrewEichmann-NOAA JGLOBAL_MARINE_ANALYSIS_FINALIZE declares the variable but never actually uses it. The real usage happens in the FORECAST job via CICE_out() in ush/forecast_postdet.sh.

This PR, included the directory creation inside if [[ -s "${cmdfile}" ]] (L780 and L910). This means the directory is only created when there are actual CICE or MOM6 restart files to copy.

mkdir -m 775 -p "${COMOUT_CONF}"

###############################################################
Expand Down
1 change: 0 additions & 1 deletion dev/jobs/JGLOBAL_MARINE_ANALYSIS_LETKF
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ declare -rx COMOUT_ICE_LETKF="${ROTDIR}/${RUN}.${PDY}/${cyc}/analysis/ice/letkf"

declare -rx COMOUT_CONF="${ROTDIR}/${RUN}.${PDY}/${cyc}/ensstat/conf"

if [[ ! -d "${COMOUT_OCEAN_LETKF}" ]]; then mkdir -p "${COMOUT_OCEAN_LETKF}"; fi
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not always used right now, but is when marine LETKF runs. This is expected to be the default

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@AndrewEichmann-NOAA These directories are created by the Python workflow engine (via the YAML mkdir: list). So removing the shell mkdir has no effect.

if [[ ! -d "${COMOUT_ICE_LETKF}" ]]; then mkdir -p "${COMOUT_ICE_LETKF}"; fi
if [[ ! -d ${COMOUT_CONF} ]]; then mkdir -p "${COMOUT_CONF}"; fi
##############################################
Expand Down
2 changes: 0 additions & 2 deletions dev/jobs/JGLOBAL_WAVE_POST_SBS
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@ declare -rx COMIN_WAVE_PREP="${COMIN}/model/wave/prep"
declare -rx COMIN_WAVE_HISTORY="${COMIN}/model/wave/history"
declare -rx COMOUT_WAVE_GRID="${COMOUT}/products/wave/gridded"

mkdir -p "${COMOUT_WAVE_GRID}"

if [[ -n "${wavepostGRD}" || -n "${waveinterpGRD}" ]]; then
for grdID in ${wavepostGRD} ${waveinterpGRD}; do
process_grdID "${grdID}"
Expand Down
2 changes: 1 addition & 1 deletion dev/scripts/exglobal_analysis_stats.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
# Initialize JEDI variational analysis
if 'atmos_gsi' in config.STAT_ANALYSES:
AnlStats.convert_gsi_diags()
AnlStats.initialize()
for anl in config.STAT_ANALYSES:
AnlStats.initialize(anl)
AnlStats.execute(anl)
AnlStats.finalize(anl)
2 changes: 1 addition & 1 deletion dev/scripts/exglobal_atmos_sfcanl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ for hr in "${!gcycle_dates[@]}"; do

# Copy outputs from DATA to COMOUT
for ((nn = 1; nn <= ntiles; nn++)); do
cpfs "${DATA}/sfc_data_cycle.00${nn}" "${COMOUT_ATMOS_RESTART}/${datestr}.sfcanl_data.tile${nn}.nc"
"${HOMEglobal}/ush/cpfsd.sh" "${DATA}/sfc_data_cycle.00${nn}" "${COMOUT_ATMOS_RESTART}/${datestr}.sfcanl_data.tile${nn}.nc"
done

done
Expand Down
4 changes: 2 additions & 2 deletions dev/scripts/exglobal_enkf_sfc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ if [[ "${DOIAU}" == "YES" ]]; then
fi

if [[ ${TILE_NUM} -eq 1 ]]; then
mkdir -p "${COMOUT_ATMOS_RESTART_MEM}"
if [[ ! -d "${COMOUT_ATMOS_RESTART_MEM}" ]]; then mkdir -p "${COMOUT_ATMOS_RESTART_MEM}"; fi
fi
cpreq "${sfcdata_dir}/${bPDY}.${bcyc}0000.${snow_prefix}sfc_data.tile${n}.nc" \
"${DATA}/sfc_data_cycle.${cmem}"
Expand Down Expand Up @@ -223,7 +223,7 @@ if [[ "${DOIAU}" == "YES" ]]; then
declare -x COMOUT_ATMOS_RESTART_MEM=${ROTDIR}/${RUN}.${PDY}/${cyc}/${memchar}/model/atmos/restart

if [[ ${TILE_NUM} -eq 1 ]]; then
mkdir -p "${COMOUT_ATMOS_RESTART_MEM}"
if [[ ! -d "${COMOUT_ATMOS_RESTART_MEM}" ]]; then mkdir -p "${COMOUT_ATMOS_RESTART_MEM}"; fi
fi

cpfs "${DATA}/sfc_data_cycle.${cmem}" "${COMOUT_ATMOS_RESTART_MEM}/${bPDY}.${bcyc}0000.sfcanl_data.tile${n}.nc"
Expand Down
2 changes: 1 addition & 1 deletion parm/archive/gcafs_arcdir.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

mkdir:
- "{{ ARCDIR }}"
{% if DO_FIT2OBS == True %}
{% if RUN == "gcafs" and DO_FIT2OBS == True %}
- "{{ VFYARC }}/{{ RUN }}.{{ cycle_YMD }}/{{ cycle_HH }}"
{% endif %}

Expand Down
2 changes: 1 addition & 1 deletion parm/archive/gfs_arcdir.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

mkdir:
- "{{ ARCDIR }}"
{% if DO_FIT2OBS == True %}
{% if RUN == "gfs" and DO_FIT2OBS == True %}
- "{{ VFYARC }}/{{ RUN }}.{{ cycle_YMD }}/{{ cycle_HH }}"
{% endif %}

Expand Down
31 changes: 31 additions & 0 deletions ush/cpfsd.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
#! /usr/bin/env bash

#---------------------------------------------------------
# cpfsd.sh
#
# A wrapper around cpfs that automatically creates the
# destination directory if it does not already exist
# before copying the file.
#
# USAGE: cpfsd <source> <destination>
# source - path to the source file
# destination - path to the destination file
#---------------------------------------------------------

dest="${!#}"
dest_dir=$(dirname "${dest}")
if [[ ! -d "${dest_dir}" ]]; then
echo "INFO: Directory ${dest_dir} does not exist, creating..."
mkdir -p "${dest_dir}"
err=$?
if [[ ${err} -ne 0 ]]; then
echo "ERROR: Failed to create destination directory ${dest_dir}"
exit "${err}"
fi
fi
cpfs "$@"
err=$?
if [[ ${err} -ne 0 ]]; then
echo "ERROR: cpfs failed to copy to ${dest}"
exit "${err}"
fi
47 changes: 41 additions & 6 deletions ush/forecast_postdet.sh
Original file line number Diff line number Diff line change
Expand Up @@ -361,6 +361,7 @@ EOF
FV3_RESTART_FH="$(seq -s ' ' "${restart_interval_start}" "${restart_interval}" "${restart_interval_end}")"
fi
export FV3_RESTART_FH
if [[ -n "${FV3_RESTART_FH}" ]]; then mkdir -p "${DATArestart}/FV3_RESTART"; fi
#============================================================================
}

Expand Down Expand Up @@ -432,13 +433,20 @@ FV3_out() {
done
done

"${USHglobal}/run_mpmd.sh" "${cmdfile}" && true
export err=$?
if [[ ${err} -ne 0 ]]; then
err_exit "run_mpmd.sh failed to copy FV3 restart files!"
fi
if [[ -s "${cmdfile}" ]]; then
if [[ ! -d "${COMOUT_ATMOS_RESTART}" ]]; then
echo "INFO: Directory ${COMOUT_ATMOS_RESTART} does not exist, creating..."
mkdir -p "${COMOUT_ATMOS_RESTART}"
fi

echo "SUB ${FUNCNAME[0]}: Output data for FV3 copied"
"${USHglobal}/run_mpmd.sh" "${cmdfile}" && true
export err=$?
if [[ ${err} -ne 0 ]]; then
err_exit "run_mpmd.sh failed to copy FV3 restart files!"
fi

echo "SUB ${FUNCNAME[0]}: Output data for FV3 copied"
fi
fi
}

Expand Down Expand Up @@ -592,6 +600,11 @@ WW3_out() {
fi

if [[ -s "${cmdfile}" ]]; then
if [[ ! -d "${COMOUT_WAVE_RESTART}" ]]; then
echo "INFO: Directory ${COMOUT_WAVE_RESTART} does not exist, creating..."
mkdir -p "${COMOUT_WAVE_RESTART}"
fi

"${USHglobal}/run_mpmd.sh" "${cmdfile}" && true
export err=$?
if [[ ${err} -ne 0 ]]; then
Expand All @@ -604,6 +617,10 @@ WW3_out() {
CPL_out() {
echo "SUB ${FUNCNAME[0]}: Copying output data for general cpl fields"
if [[ "${esmf_profile:-.false.}" == ".true." ]]; then
if [[ ! -d "${COMOUT_ATMOS_HISTORY}" ]]; then
echo "INFO: Directory ${COMOUT_ATMOS_HISTORY} does not exist, creating..."
mkdir -p "${COMOUT_ATMOS_HISTORY}"
fi
cpfs "${DATA}/ESMF_Profile.summary" "${COMOUT_ATMOS_HISTORY}/ESMF_Profile.summary"
fi
}
Expand Down Expand Up @@ -760,6 +777,11 @@ MOM6_out() {
esac

if [[ -s "${cmdfile}" ]]; then
if [[ ! -d "${COMOUT_OCEAN_RESTART}" ]]; then
echo "INFO: Directory ${COMOUT_OCEAN_RESTART} does not exist, creating..."
mkdir -p "${COMOUT_OCEAN_RESTART}"
fi

"${USHglobal}/run_mpmd.sh" "${cmdfile}" && true
export err=$?
if [[ ${err} -ne 0 ]]; then
Expand Down Expand Up @@ -886,6 +908,11 @@ CICE_out() {
esac

if [[ -s "${cmdfile}" ]]; then
if [[ ! -d "${COMOUT_ICE_RESTART}" ]]; then
echo "INFO: Directory ${COMOUT_ICE_RESTART} does not exist, creating..."
mkdir -p "${COMOUT_ICE_RESTART}"
fi

"${USHglobal}/run_mpmd.sh" "${cmdfile}" && true
export err=$?
if [[ ${err} -ne 0 ]]; then
Expand Down Expand Up @@ -966,6 +993,7 @@ GOCART_out() {

for fhr in $(GOCART_output_fh); do
vdate=$(date --utc -d "${current_cycle:0:8} ${current_cycle:8:2} + ${fhr} hours" +%Y%m%d%H)

for file_type in "${file_types[@]}"; do
if [[ -e "${DATA}/gocart.${file_type}.${vdate:0:8}_${vdate:8:2}00z.nc4" ]]; then
echo "cpfs ${DATA}/gocart.${file_type}.${vdate:0:8}_${vdate:8:2}00z.nc4 ${COMOUT_CHEM_HISTORY}/gocart.${file_type}.${vdate:0:8}_${vdate:8:2}00z.nc4" >> "${cmdfile}"
Expand All @@ -974,6 +1002,11 @@ GOCART_out() {
done

if [[ -s "${cmdfile}" ]]; then
if [[ ! -d "${COMOUT_CHEM_HISTORY}" ]]; then
echo "INFO: Directory ${COMOUT_CHEM_HISTORY} does not exist, creating..."
mkdir -p "${COMOUT_CHEM_HISTORY}"
fi

"${USHglobal}/run_mpmd.sh" "${cmdfile}" && true
export err=$?
if [[ ${err} -ne 0 ]]; then
Expand Down Expand Up @@ -1094,6 +1127,8 @@ CMEPS_out() {
esac

if [[ -s "${cmdfile}" ]]; then
if [[ ! -d "${COMOUT_MED_RESTART}" ]]; then mkdir -p "${COMOUT_MED_RESTART}"; fi

"${USHglobal}/run_mpmd.sh" "${cmdfile}" && true
export err=$?
if [[ ${err} -ne 0 ]]; then
Expand Down
13 changes: 3 additions & 10 deletions ush/forecast_predet.sh
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,11 @@ FV3_predet() {
echo "SUB ${FUNCNAME[0]}: Defining variables for FV3"

if [[ ! -d "${COMOUT_ATMOS_HISTORY}" ]]; then mkdir -p "${COMOUT_ATMOS_HISTORY}"; fi
if [[ ! -d "${COMOUT_ATMOS_MASTER}" ]]; then mkdir -p "${COMOUT_ATMOS_MASTER}"; fi
if [[ ! -d "${COMOUT_ATMOS_RESTART}" ]]; then mkdir -p "${COMOUT_ATMOS_RESTART}"; fi
if [[ ! -d "${DATAoutput}/FV3ATM_OUTPUT" ]]; then mkdir -p "${DATAoutput}/FV3ATM_OUTPUT"; fi
if [[ ! -d "${DATArestart}/FV3_RESTART" ]]; then mkdir -p "${DATArestart}/FV3_RESTART"; fi
if [[ "${WRITE_DOPOST:-}" == ".true." ]] && [[ ! -d "${COMOUT_ATMOS_MASTER}" ]]; then
mkdir -p "${COMOUT_ATMOS_MASTER}"
fi

# The $DATA/RESTART directory is used for writing FV3 restart files (it is hard-wired in the model)
# Link the output and restart directories to the DATA directory
Expand Down Expand Up @@ -609,7 +610,6 @@ WW3_predet() {
echo "SUB ${FUNCNAME[0]}: WW3 before run type determination"

if [[ ! -d "${COMOUT_WAVE_HISTORY}" ]]; then mkdir -p "${COMOUT_WAVE_HISTORY}"; fi
if [[ ! -d "${COMOUT_WAVE_RESTART}" ]]; then mkdir -p "${COMOUT_WAVE_RESTART}"; fi
if [[ ! -d "${DATAoutput}/WW3_OUTPUT" ]]; then mkdir -p "${DATAoutput}/WW3_OUTPUT"; fi
if [[ ! -d "${DATArestart}/WW3_RESTART" ]]; then mkdir -p "${DATArestart}/WW3_RESTART"; fi

Expand Down Expand Up @@ -665,8 +665,6 @@ CICE_predet() {
echo "SUB ${FUNCNAME[0]}: CICE before run type determination"

if [[ ! -d "${COMOUT_ICE_HISTORY}" ]]; then mkdir -p "${COMOUT_ICE_HISTORY}"; fi
if [[ ! -d "${COMOUT_ICE_RESTART}" ]]; then mkdir -p "${COMOUT_ICE_RESTART}"; fi
if [[ ! -d "${COMIN_ICE_INPUT}" ]]; then mkdir -p "${COMIN_ICE_INPUT}"; fi
if [[ ! -d "${DATAoutput}/CICE_OUTPUT" ]]; then mkdir -p "${DATAoutput}/CICE_OUTPUT"; fi
if [[ ! -d "${DATArestart}/CICE_RESTART" ]]; then mkdir -p "${DATArestart}/CICE_RESTART"; fi

Expand All @@ -690,8 +688,6 @@ MOM6_predet() {
echo "SUB ${FUNCNAME[0]}: MOM6 before run type determination"

if [[ ! -d "${COMOUT_OCEAN_HISTORY}" ]]; then mkdir -p "${COMOUT_OCEAN_HISTORY}"; fi
if [[ ! -d "${COMOUT_OCEAN_RESTART}" ]]; then mkdir -p "${COMOUT_OCEAN_RESTART}"; fi
if [[ ! -d "${COMIN_OCEAN_INPUT}" ]]; then mkdir -p "${COMIN_OCEAN_INPUT}"; fi
if [[ ! -d "${DATAoutput}/MOM6_OUTPUT" ]]; then mkdir -p "${DATAoutput}/MOM6_OUTPUT"; fi
if [[ ! -d "${DATArestart}/MOM6_RESTART" ]]; then mkdir -p "${DATArestart}/MOM6_RESTART"; fi

Expand Down Expand Up @@ -745,7 +741,6 @@ EOF
CMEPS_predet() {
echo "SUB ${FUNCNAME[0]}: CMEPS before run type determination"

if [[ ! -d "${COMOUT_MED_RESTART}" ]]; then mkdir -p "${COMOUT_MED_RESTART}"; fi
if [[ ! -d "${DATArestart}/CMEPS_RESTART" ]]; then mkdir -p "${DATArestart}/CMEPS_RESTART"; fi

# Link the restart directory to the DATA directory
Expand All @@ -756,8 +751,6 @@ CMEPS_predet() {
GOCART_predet() {
echo "SUB ${FUNCNAME[0]}: GOCART before run type determination"

if [[ ! -d "${COMOUT_CHEM_HISTORY}" ]]; then mkdir -p "${COMOUT_CHEM_HISTORY}"; fi

# FHMAX gets modified when IAU is on, so keep origianl value for GOCART output
GOCART_MAX=${FHMAX}

Expand Down
3 changes: 2 additions & 1 deletion ush/python/pygfs/jedi/jedi.py
Original file line number Diff line number Diff line change
Expand Up @@ -499,7 +499,8 @@ def save_obsbiasout(self, comout: str, archive_name: str) -> None:
logger.info(f"Adding temperature lapse rate file {tlapfile_rename} to {tarball}")
bcor.add(tlapfile, arcname=os.path.basename(tlapfile_rename))

# Copy files to COM
# Always copy the tarball to COM; it is always created above and required by the archive step
FileHandler({'mkdir': [comout]}).sync()
FileHandler({'copy_opt': [[tarball, comout]]}).sync()

@staticmethod
Expand Down
Loading
Loading