Skip to content

Commit

Permalink
Refactor UFS-DA ATM var component to use python g-w (#1372)
Browse files Browse the repository at this point in the history
This PR contains UFS-DA ATM var changes in PR #1354.   

Below is a list of changes in this PR
- rename UFS-DA ATM var jobs `atmanalprep`, `atmanalrun`, and `atmanalpost` as `atmanlinit`, `atmanlrun`, and `atmanlfinal`, respectively
- replace UFS-DA ATM var shell scripts with python scripts
- rename UFS-DA ATM var j-jobs consistent with initialize, run, and finalize functions.  Update j-jobs to execute python scripts instead of shell scripts
- rename UFS-DA ATM var rocoto jobs to be consistent with initialize, run, and finalize functions.  Update jobs to set python paths and execute renamed j-jobs
- update rocoto workflow generation to new names for UFS-DA ATM var jobs 
- update UFS-DA ATM var job names in machine dependent `env` files to new job names
- rename UFS-DA ATM var configuration files consistent with change in job names
- add UFS-DA ATM yaml files for UFS-DA fix files, crtm files, and increments
- add python class for UFS-DA ATM var analysis
- link UFS-DA python increment conversion script from GDASApp to g-w `ush` directory

The above changes are part of a larger g-w effort to transition from shell scripts to python.  UFS-DA Aerosol was the first GDASApp system to be converted.   This PR represents the second GDASApp system, UFS-DA atmospheric variational DA, to be converted.  PR #1373 contains changes to convert the UFS-DA ensemble DA to a python based approach.   

Fixes (in part) #1313
Depends (in part) on PR #1370 and [GDASApp #388](NOAA-EMC/GDASApp#388)
  • Loading branch information
RussTreadon-NOAA authored Apr 18, 2023
1 parent 70a7d99 commit b2ed864
Show file tree
Hide file tree
Showing 40 changed files with 1,047 additions and 695 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ ush/global_chgres.sh
ush/global_chgres_driver.sh
ush/global_cycle.sh
ush/global_cycle_driver.sh
ush/jediinc2fv3.py
ush/mkwfsgbl.sh
ush/ufsda
ush/wafs_blending.sh
Expand Down
3 changes: 1 addition & 2 deletions env/CONTAINER.env
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ if [[ $# -ne 1 ]]; then

echo "Must specify an input argument to set runtime environment variables!"
echo "argument can be any one of the following:"
echo "atmanalrun atmensanalrun"
echo "aeroanlrun"
echo "atmanlrun atmensanalrun aeroanlrun"
echo "anal sfcanl fcst post vrfy metp"
echo "eobs eupd ecen efcs epos"
echo "postsnd awips gempak"
Expand Down
19 changes: 6 additions & 13 deletions env/HERA.env
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ if [[ $# -ne 1 ]]; then

echo "Must specify an input argument to set runtime environment variables!"
echo "argument can be any one of the following:"
echo "atmanalrun atmensanalrun"
echo "aeroanlrun"
echo "atmanlrun atmensanalrun aeroanlrun"
echo "anal sfcanl fcst post vrfy metp"
echo "eobs eupd ecen efcs epos"
echo "postsnd awips gempak"
Expand Down Expand Up @@ -49,22 +48,16 @@ elif [[ "${step}" = "waveinit" ]] || [[ "${step}" = "waveprep" ]] || [[ "${step}
export wavempexec=${launcher}
export wave_mpmd=${mpmd_opt}

elif [[ "${step}" = "atmanalrun" ]]; then
elif [[ "${step}" = "atmanlrun" ]]; then

export CFP_MP=${CFP_MP:-"YES"}
export USE_CFP=${USE_CFP:-"YES"}
export APRUNCFP="${launcher} -n \$ncmd ${mpmd_opt}"
nth_max=$((npe_node_max / npe_node_atmanlrun))

nth_max=$((npe_node_max / npe_node_atmanalrun))

export NTHREADS_ATMANAL=${nth_atmanalrun:-${nth_max}}
[[ ${NTHREADS_ATMANAL} -gt ${nth_max} ]] && export NTHREADS_ATMANAL=${nth_max}
export APRUN_ATMANAL="${launcher} -n ${npe_atmanalrun}"
export NTHREADS_ATMANL=${nth_atmanlrun:-${nth_max}}
[[ ${NTHREADS_ATMANL} -gt ${nth_max} ]] && export NTHREADS_ATMANL=${nth_max}
export APRUN_ATMANL="${launcher} -n ${npe_atmanlrun}"

elif [[ "${step}" = "atmensanalrun" ]]; then

export CFP_MP=${CFP_MP:-"YES"}
export USE_CFP=${USE_CFP:-"YES"}
export APRUNCFP="${launcher} -n \$ncmd ${mpmd_opt}"

nth_max=$((npe_node_max / npe_node_atmensanalrun))
Expand Down
16 changes: 6 additions & 10 deletions env/JET.env
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ if [[ $# -ne 1 ]]; then

echo "Must specify an input argument to set runtime environment variables!"
echo "argument can be any one of the following:"
echo "atmanalrun atmensanalrun aeroanlrun"
echo "atmanlrun atmensanalrun aeroanlrun"
echo "anal sfcanl fcst post vrfy metp"
echo "eobs eupd ecen efcs epos"
echo "postsnd awips gempak"
Expand Down Expand Up @@ -47,17 +47,13 @@ elif [[ "${step}" = "waveinit" ]] || [[ "${step}" = "waveprep" ]] || [[ "${step}
export wavempexec=${launcher}
export wave_mpmd=${mpmd_opt}

elif [[ "${step}" = "atmanalrun" ]]; then
elif [[ "${step}" = "atmanlrun" ]]; then

export CFP_MP=${CFP_MP:-"YES"}
export USE_CFP=${USE_CFP:-"YES"}
export APRUNCFP="${launcher} -n \$ncmd ${mpmd_opt}"

nth_max=$((npe_node_max / npe_node_atmanalrun))
nth_max=$((npe_node_max / npe_node_atmanlrun))

export NTHREADS_ATMANAL=${nth_atmanalrun:-${nth_max}}
[[ ${NTHREADS_ATMANAL} -gt ${nth_max} ]] && export NTHREADS_ATMANAL=${nth_max}
export APRUN_ATMANAL="${launcher} -n ${npe_atmanalrun}"
export NTHREADS_ATMANL=${nth_atmanlrun:-${nth_max}}
[[ ${NTHREADS_ATMANL} -gt ${nth_max} ]] && export NTHREADS_ATMANL=${nth_max}
export APRUN_ATMANL="${launcher} -n ${npe_atmanlrun}"

elif [[ "${step}" = "atmensanalrun" ]]; then

Expand Down
17 changes: 6 additions & 11 deletions env/ORION.env
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ if [[ $# -ne 1 ]]; then

echo "Must specify an input argument to set runtime environment variables!"
echo "argument can be any one of the following:"
echo "atmanalrun atmensanalrun"
echo "aeroanlrun"
echo "atmanlrun atmensanalrun aeroanlrun"
echo "anal sfcanl fcst post vrfy metp"
echo "eobs eupd ecen efcs epos"
echo "postsnd awips gempak"
Expand Down Expand Up @@ -49,17 +48,13 @@ elif [[ "${step}" = "waveinit" ]] || [[ "${step}" = "waveprep" ]] || [[ "${step}
export wavempexec=${launcher}
export wave_mpmd=${mpmd_opt}

elif [[ "${step}" = "atmanalrun" ]]; then
elif [[ "${step}" = "atmanlrun" ]]; then

export CFP_MP=${CFP_MP:-"YES"}
export USE_CFP=${USE_CFP:-"YES"}
export APRUNCFP="${launcher} -n \$ncmd ${mpmd_opt}"

nth_max=$((npe_node_max / npe_node_atmanalrun))
nth_max=$((npe_node_max / npe_node_atmanlrun))

export NTHREADS_ATMANAL=${nth_atmanalrun:-${nth_max}}
[[ ${NTHREADS_ATMANAL} -gt ${nth_max} ]] && export NTHREADS_ATMANAL=${nth_max}
export APRUN_ATMANAL="${launcher} -n ${npe_atmanalrun}"
export NTHREADS_ATMANL=${nth_atmanlrun:-${nth_max}}
[[ ${NTHREADS_ATMANL} -gt ${nth_max} ]] && export NTHREADS_ATMANL=${nth_max}
export APRUN_ATMANL="${launcher} -n ${npe_atmanlrun}"

elif [[ "${step}" = "atmensanalrun" ]]; then

Expand Down
17 changes: 6 additions & 11 deletions env/S4.env
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ if [[ $# -ne 1 ]]; then

echo "Must specify an input argument to set runtime environment variables!"
echo "argument can be any one of the following:"
echo "atmanalrun atmensanalrun"
echo "aeroanlrun"
echo "atmanlrun atmensanalrun aeroanlrun"
echo "anal sfcanl fcst post vrfy metp"
echo "eobs eupd ecen efcs epos"
echo "postsnd awips gempak"
Expand Down Expand Up @@ -47,17 +46,13 @@ elif [[ "${step}" = "waveinit" ]] || [[ "${step}" = "waveprep" ]] || [[ "${step}
export wavempexec=${launcher}
export wave_mpmd=${mpmd_opt}

elif [[ "${step}" = "atmanalrun" ]]; then
elif [[ "${step}" = "atmanlrun" ]]; then

export CFP_MP=${CFP_MP:-"YES"}
export USE_CFP=${USE_CFP:-"YES"}
export APRUNCFP="${launcher} -n \$ncmd ${mpmd_opt}"

nth_max=$((npe_node_max / npe_node_atmanalrun))
nth_max=$((npe_node_max / npe_node_atmanlrun))

export NTHREADS_ATMANAL=${nth_atmanalrun:-${nth_max}}
[[ ${NTHREADS_ATMANAL} -gt ${nth_max} ]] && export NTHREADS_ATMANAL=${nth_max}
export APRUN_ATMANAL="${launcher} -n ${npe_atmanalrun}"
export NTHREADS_ATMANL=${nth_atmanlrun:-${nth_max}}
[[ ${NTHREADS_ATMANL} -gt ${nth_max} ]] && export NTHREADS_ATMANL=${nth_max}
export APRUN_ATMANL="${launcher} -n ${npe_atmanlrun}"

elif [[ "${step}" = "atmensanalrun" ]]; then

Expand Down
17 changes: 6 additions & 11 deletions env/WCOSS2.env
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ if [[ $# -ne 1 ]]; then

echo "Must specify an input argument to set runtime environment variables!"
echo "argument can be any one of the following:"
echo "atmanalrun atmensanalrun"
echo "aeroanlrun"
echo "atmanlrun atmensanalrun aeroanlrun"
echo "anal sfcanl fcst post vrfy metp"
echo "eobs eupd ecen esfc efcs epos"
echo "postsnd awips gempak"
Expand Down Expand Up @@ -36,17 +35,13 @@ elif [[ "${step}" = "waveinit" ]] || [[ "${step}" = "waveprep" ]] || [[ "${step}
export wavempexec="${launcher} -np"
export wave_mpmd=${mpmd_opt}

elif [[ "${step}" = "atmanalrun" ]]; then
elif [[ "${step}" = "atmanlrun" ]]; then

export CFP_MP=${CFP_MP:-"YES"}
export USE_CFP=${USE_CFP:-"YES"}
export APRUNCFP="${launcher} -np \$ncmd ${mpmd_opt}"

nth_max=$((npe_node_max / npe_node_atmanalrun))
nth_max=$((npe_node_max / npe_node_atmanlrun))

export NTHREADS_ATMANAL=${nth_atmanalrun:-${nth_max}}
[[ ${NTHREADS_ATMANAL} -gt ${nth_max} ]] && export NTHREADS_ATMANAL=${nth_max}
export APRUN_ATMANAL="${launcher} -n ${npe_atmanalrun}"
export NTHREADS_ATMANL=${nth_atmanlrun:-${nth_max}}
[[ ${NTHREADS_ATMANL} -gt ${nth_max} ]] && export NTHREADS_ATMANL=${nth_max}
export APRUN_ATMANL="${launcher} -n ${npe_atmanlrun}"

elif [[ "${step}" = "atmensanalrun" ]]; then

Expand Down
63 changes: 0 additions & 63 deletions jobs/JGDAS_GLOBAL_ATMOS_ANALYSIS_POST

This file was deleted.

62 changes: 0 additions & 62 deletions jobs/JGDAS_GLOBAL_ATMOS_ANALYSIS_PREP

This file was deleted.

63 changes: 0 additions & 63 deletions jobs/JGDAS_GLOBAL_ATMOS_ANALYSIS_RUN

This file was deleted.

Loading

0 comments on commit b2ed864

Please sign in to comment.