From 3501ddfb026fdda292690f3033f1c252184aeb5e Mon Sep 17 00:00:00 2001 From: apcraig Date: Thu, 12 Oct 2023 15:59:32 -0600 Subject: [PATCH] Remove use of the deprecated "_old" tfrz_options in set_nml files. This changes answers for some test cases, as expected. Update tfrz_option implementation to not allow _old options. --- cicecore/cicedyn/general/ice_init.F90 | 18 ++++++++---------- configuration/scripts/options/set_nml.alt04 | 2 +- configuration/scripts/options/set_nml.alt06 | 2 +- configuration/scripts/options/set_nml.bgcskl | 2 +- .../scripts/options/set_nml.bgcsklclim | 2 +- configuration/scripts/options/set_nml.bgcz | 2 +- configuration/scripts/options/set_nml.bgczclim | 2 +- configuration/scripts/options/set_nml.bgczm | 2 +- configuration/scripts/options/set_nml.boxadv | 2 +- .../scripts/options/set_nml.boxchan1e | 2 +- .../scripts/options/set_nml.boxchan1n | 2 +- configuration/scripts/tests/baseline.script | 4 ++-- configuration/scripts/tests/omp_suite.ts | 2 -- 13 files changed, 20 insertions(+), 24 deletions(-) diff --git a/cicecore/cicedyn/general/ice_init.F90 b/cicecore/cicedyn/general/ice_init.F90 index ff952629e..9d21b84fc 100644 --- a/cicecore/cicedyn/general/ice_init.F90 +++ b/cicecore/cicedyn/general/ice_init.F90 @@ -1510,15 +1510,14 @@ subroutine input_data abort_list = trim(abort_list)//":13" endif -! tcraig, is it really OK for users to run inconsistently? -! ech: yes, for testing sensitivities. It's not recommended for science runs - if (ktherm == 1 .and. trim(tfrz_option(1:11)) /= 'linear_salt') then +! ech: allow inconsistency for testing sensitivities. It's not recommended for science runs + if (ktherm == 1 .and. trim(tfrz_option) /= 'linear_salt') then if (my_task == master_task) then write(nu_diag,*) subname//' WARNING: ktherm = 1 and tfrz_option = ',trim(tfrz_option) write(nu_diag,*) subname//' WARNING: For consistency, set tfrz_option = linear_salt' endif endif - if (ktherm == 2 .and. trim(tfrz_option(1:5)) /= 'mushy') then + if (ktherm == 2 .and. trim(tfrz_option) /= 'mushy') then if (my_task == master_task) then write(nu_diag,*) subname//' WARNING: ktherm = 2 and tfrz_option = ',trim(tfrz_option) write(nu_diag,*) subname//' WARNING: For consistency, set tfrz_option = mushy' @@ -1530,7 +1529,6 @@ subroutine input_data write(nu_diag,*) subname//' WARNING: For consistency, set saltflux_option = constant' endif endif -!tcraig if (ktherm == 1 .and. .not.sw_redist) then if (my_task == master_task) then write(nu_diag,*) subname//' WARNING: ktherm = 1 and sw_redist = ',sw_redist @@ -2104,19 +2102,19 @@ subroutine input_data if (trim(saltflux_option) == 'constant') then write(nu_diag,1002) ' ice_ref_salinity = ',ice_ref_salinity endif - if (trim(tfrz_option(1:8)) == 'constant') then + if (trim(tfrz_option) == 'constant') then tmpstr2 = ' : constant ocean freezing temperature (Tocnfrz)' - elseif (trim(tfrz_option(1:8)) == 'minus1p8') then + elseif (trim(tfrz_option) == 'minus1p8') then tmpstr2 = ' : constant ocean freezing temperature (-1.8C) (to be deprecated)' - elseif (trim(tfrz_option(1:11)) == 'linear_salt') then + elseif (trim(tfrz_option) == 'linear_salt') then tmpstr2 = ' : linear function of salinity (use with ktherm=1)' - elseif (trim(tfrz_option(1:5)) == 'mushy') then + elseif (trim(tfrz_option) == 'mushy') then tmpstr2 = ' : Assur (1958) as in mushy-layer thermo (ktherm=2)' else tmpstr2 = ' : unknown value' endif write(nu_diag,1030) ' tfrz_option = ', trim(tfrz_option),trim(tmpstr2) - if (trim(tfrz_option(1:8)) == 'constant') then + if (trim(tfrz_option) == 'constant') then write(nu_diag,1002) ' Tocnfrz = ', Tocnfrz endif if (update_ocn_f) then diff --git a/configuration/scripts/options/set_nml.alt04 b/configuration/scripts/options/set_nml.alt04 index f58c05312..273f7d87d 100644 --- a/configuration/scripts/options/set_nml.alt04 +++ b/configuration/scripts/options/set_nml.alt04 @@ -27,4 +27,4 @@ krdg_partic = 0 krdg_redist = 0 frzpnd = 'ccsm' natmiter = 20 -tfrz_option = 'linear_salt_old' +tfrz_option = 'linear_salt' diff --git a/configuration/scripts/options/set_nml.alt06 b/configuration/scripts/options/set_nml.alt06 index 02a594fe5..01657cede 100644 --- a/configuration/scripts/options/set_nml.alt06 +++ b/configuration/scripts/options/set_nml.alt06 @@ -2,4 +2,4 @@ ncat = 7 kcatbound = 3 nslyr = 3 ice_ic = 'internal' -tfrz_option = 'mushy_old' +tfrz_option = 'mushy' diff --git a/configuration/scripts/options/set_nml.bgcskl b/configuration/scripts/options/set_nml.bgcskl index 770f53724..91e0af6bd 100644 --- a/configuration/scripts/options/set_nml.bgcskl +++ b/configuration/scripts/options/set_nml.bgcskl @@ -24,5 +24,5 @@ tr_bgc_PON = .true. tr_bgc_hum = .true. tr_bgc_DON = .true. tr_bgc_Fe = .true. -tfrz_option = 'mushy_old' +tfrz_option = 'mushy' diff --git a/configuration/scripts/options/set_nml.bgcsklclim b/configuration/scripts/options/set_nml.bgcsklclim index e100d57ce..c71c7bca4 100644 --- a/configuration/scripts/options/set_nml.bgcsklclim +++ b/configuration/scripts/options/set_nml.bgcsklclim @@ -27,4 +27,4 @@ tr_bgc_PON = .true. tr_bgc_hum = .true. tr_bgc_DON = .true. tr_bgc_Fe = .true. -tfrz_option = "mushy_old" +tfrz_option = "mushy" diff --git a/configuration/scripts/options/set_nml.bgcz b/configuration/scripts/options/set_nml.bgcz index 6d5257d1b..46e4dee74 100644 --- a/configuration/scripts/options/set_nml.bgcz +++ b/configuration/scripts/options/set_nml.bgcz @@ -28,4 +28,4 @@ tr_bgc_DON = .true. tr_bgc_Fe = .true. # modal_aero = .true. # dEdd_algae = .true. -tfrz_option = 'mushy_old' +tfrz_option = 'mushy' diff --git a/configuration/scripts/options/set_nml.bgczclim b/configuration/scripts/options/set_nml.bgczclim index c5bb2f198..feb900ede 100644 --- a/configuration/scripts/options/set_nml.bgczclim +++ b/configuration/scripts/options/set_nml.bgczclim @@ -29,6 +29,6 @@ tr_bgc_PON = .true. tr_bgc_hum = .true. tr_bgc_DON = .true. tr_bgc_Fe = .true. -tfrz_option = "mushy_old" +tfrz_option = "mushy" diff --git a/configuration/scripts/options/set_nml.bgczm b/configuration/scripts/options/set_nml.bgczm index a80c17033..53513ca87 100644 --- a/configuration/scripts/options/set_nml.bgczm +++ b/configuration/scripts/options/set_nml.bgczm @@ -28,4 +28,4 @@ tr_bgc_DON = .true. tr_bgc_Fe = .true. modal_aero = .true. # dEdd_algae = .true. -tfrz_option = 'mushy_old' +tfrz_option = 'mushy' diff --git a/configuration/scripts/options/set_nml.boxadv b/configuration/scripts/options/set_nml.boxadv index 434ced169..933099029 100644 --- a/configuration/scripts/options/set_nml.boxadv +++ b/configuration/scripts/options/set_nml.boxadv @@ -24,4 +24,4 @@ krdg_partic = 0 krdg_redist = 0 shortwave = 'ccsm3' albedo_type = 'constant' -tfrz_option = 'mushy_old' +tfrz_option = 'mushy' diff --git a/configuration/scripts/options/set_nml.boxchan1e b/configuration/scripts/options/set_nml.boxchan1e index ebfa5c535..cf8b0d314 100644 --- a/configuration/scripts/options/set_nml.boxchan1e +++ b/configuration/scripts/options/set_nml.boxchan1e @@ -26,7 +26,7 @@ ice_data_dist = 'uniform' calc_strair = .false. rotate_wind = .false. restore_ice = .false. -tfrz_option = 'mushy_old' +tfrz_option = 'mushy' f_aice = 'd1' f_hi = 'd1' f_hs = 'd' diff --git a/configuration/scripts/options/set_nml.boxchan1n b/configuration/scripts/options/set_nml.boxchan1n index 6e3613547..f90d4da0c 100644 --- a/configuration/scripts/options/set_nml.boxchan1n +++ b/configuration/scripts/options/set_nml.boxchan1n @@ -26,7 +26,7 @@ ice_data_dist = 'uniform' calc_strair = .false. rotate_wind = .false. restore_ice = .false. -tfrz_option = 'mushy_old' +tfrz_option = 'mushy' f_aice = 'd1' f_hi = 'd1' f_hs = 'd' diff --git a/configuration/scripts/tests/baseline.script b/configuration/scripts/tests/baseline.script index a24236c9e..9fd2fe001 100644 --- a/configuration/scripts/tests/baseline.script +++ b/configuration/scripts/tests/baseline.script @@ -146,9 +146,9 @@ if (${ICE_BFBCOMP} != ${ICE_SPVAL}) then @ cnt = $cnt + 1 echo "Waiting for $job to complete $cnt" sleep 60 # Sleep for 1 minute, so as not to overwhelm the queue manager - if ($cnt > 100) then + if ($cnt > 30) then echo "No longer waiting for $job to complete" - set qstatjob = 0 # Abandon check after 100 sleep 60 checks + set qstatjob = 0 # Abandon check after cnt sleep 60 checks endif endif # echo $qstatjob diff --git a/configuration/scripts/tests/omp_suite.ts b/configuration/scripts/tests/omp_suite.ts index 62630e874..57effbe75 100644 --- a/configuration/scripts/tests/omp_suite.ts +++ b/configuration/scripts/tests/omp_suite.ts @@ -78,8 +78,6 @@ smoke gbox128 14x2 boxrestore,reprosum,run10day,gridcd smoke gbox80 4x5 box2001,reprosum,run10day,gridcd smoke gbox80 11x3 boxslotcyl,reprosum,run10day,gridcd -sleep 180 - #gridB smoke gx3 4x2 diag1,reprosum,run10day,cmplogrest smoke_gx3_8x4_diag1_reprosum_run10day