diff --git a/docs/Users_Guide/glossary.rst b/docs/Users_Guide/glossary.rst index e7c5c0257..6a3d717e5 100644 --- a/docs/Users_Guide/glossary.rst +++ b/docs/Users_Guide/glossary.rst @@ -10302,6 +10302,11 @@ METplus Configuration Glossary | *Used by:* TCDiag + TC_DIAG_DOMAIN_INFO_OVERRIDE_DIAGS + Specify the value for the nth 'domain_info.override_diags' in the MET configuration file for TCDiag. + + | *Used by:* TCDiag + TC_DIAG_CENSOR_THRESH .. warning:: **DEPRECATED:** Please use :term:`BOTH_VAR_OPTIONS` instead. diff --git a/docs/Users_Guide/wrappers.rst b/docs/Users_Guide/wrappers.rst index 71280f708..380c7e867 100644 --- a/docs/Users_Guide/wrappers.rst +++ b/docs/Users_Guide/wrappers.rst @@ -8225,6 +8225,7 @@ METplus Configuration | :term:`TC_DIAG_DOMAIN_INFO_N_AZIMUTH` | :term:`TC_DIAG_DOMAIN_INFO_DELTA_RANGE_KM` | :term:`TC_DIAG_DOMAIN_INFO_DIAG_SCRIPT` +| :term:`TC_DIAG_DOMAIN_INFO_OVERRIDE_DIAGS` | :term:`TC_DIAG_INPUT_DATATYPE` | :term:`TC_DIAG_DATA_DOMAIN` | :term:`TC_DIAG_DATA_LEVEL` @@ -8444,6 +8445,8 @@ ${METPLUS_DOMAIN_INFO_LIST} - domain_info.delta_range_km * - :term:`TC_DIAG_DOMAIN_INFO_DIAG_SCRIPT` - domain_info.diag_script + * - :term:`TC_DIAG_DOMAIN_INFO_OVERRIDE_DIAGS` + - domain_info.override_diags ${METPLUS_DATA_FILE_TYPE} """"""""""""""""""""""""" diff --git a/internal/tests/pytests/wrappers/tc_diag/test_tc_diag_wrapper.py b/internal/tests/pytests/wrappers/tc_diag/test_tc_diag_wrapper.py index d03fd5d18..2a0954cb2 100644 --- a/internal/tests/pytests/wrappers/tc_diag/test_tc_diag_wrapper.py +++ b/internal/tests/pytests/wrappers/tc_diag/test_tc_diag_wrapper.py @@ -101,26 +101,31 @@ def set_minimum_config_settings(config): {'METPLUS_DOMAIN_INFO_LIST': 'domain_info = [{delta_range_km = 10.0;}];'}), ({'TC_DIAG_DOMAIN_INFO1_DIAG_SCRIPT': 'MET_BASE/python/tc_diag/compute_all_diagnostics.py,MET_BASE/python/tc_diag/compute_custom_diagnostics.py', }, {'METPLUS_DOMAIN_INFO_LIST': 'domain_info = [{diag_script = ["MET_BASE/python/tc_diag/compute_all_diagnostics.py", "MET_BASE/python/tc_diag/compute_custom_diagnostics.py"];}];'}), + ({'TC_DIAG_DOMAIN_INFO1_OVERRIDE_DIAGS': 'RMW,SST', }, + {'METPLUS_DOMAIN_INFO_LIST': 'domain_info = [{override_diags = ["RMW", "SST"];}];'}), ({'TC_DIAG_DOMAIN_INFO1_DOMAIN': 'parent', 'TC_DIAG_DOMAIN_INFO1_N_RANGE': '150', 'TC_DIAG_DOMAIN_INFO1_N_AZIMUTH': '8', 'TC_DIAG_DOMAIN_INFO1_DELTA_RANGE_KM': '10.0', 'TC_DIAG_DOMAIN_INFO1_DIAG_SCRIPT': 'MET_BASE/python/tc_diag/compute_all_diagnostics.py,MET_BASE/python/tc_diag/compute_custom_diagnostics.py', + 'TC_DIAG_DOMAIN_INFO1_OVERRIDE_DIAGS': 'RMW,SST', }, - {'METPLUS_DOMAIN_INFO_LIST': 'domain_info = [{domain = "parent";n_range = 150;n_azimuth = 8;delta_range_km = 10.0;diag_script = ["MET_BASE/python/tc_diag/compute_all_diagnostics.py", "MET_BASE/python/tc_diag/compute_custom_diagnostics.py"];}];'}), + {'METPLUS_DOMAIN_INFO_LIST': 'domain_info = [{domain = "parent";n_range = 150;n_azimuth = 8;delta_range_km = 10.0;diag_script = ["MET_BASE/python/tc_diag/compute_all_diagnostics.py", "MET_BASE/python/tc_diag/compute_custom_diagnostics.py"];override_diags = ["RMW", "SST"];}];'}), # domain_info 2 dictionaries in list ({'TC_DIAG_DOMAIN_INFO1_DOMAIN': 'parent', 'TC_DIAG_DOMAIN_INFO1_N_RANGE': '150', 'TC_DIAG_DOMAIN_INFO1_N_AZIMUTH': '8', 'TC_DIAG_DOMAIN_INFO1_DELTA_RANGE_KM': '10.0', 'TC_DIAG_DOMAIN_INFO1_DIAG_SCRIPT': 'MET_BASE/python/tc_diag/compute_all_diagnostics.py,MET_BASE/python/tc_diag/compute_custom_diagnostics.py', + 'TC_DIAG_DOMAIN_INFO1_OVERRIDE_DIAGS': 'RMW,SST', 'TC_DIAG_DOMAIN_INFO2_DOMAIN': 'nest', 'TC_DIAG_DOMAIN_INFO2_N_RANGE': '100', 'TC_DIAG_DOMAIN_INFO2_N_AZIMUTH': '7', 'TC_DIAG_DOMAIN_INFO2_DELTA_RANGE_KM': '12.0', 'TC_DIAG_DOMAIN_INFO2_DIAG_SCRIPT': 'MET_BASE/python/tc_diag/compute_sst_diagnostics.py', + 'TC_DIAG_DOMAIN_INFO2_OVERRIDE_DIAGS': 'SST', }, - {'METPLUS_DOMAIN_INFO_LIST': 'domain_info = [{domain = "parent";n_range = 150;n_azimuth = 8;delta_range_km = 10.0;diag_script = ["MET_BASE/python/tc_diag/compute_all_diagnostics.py", "MET_BASE/python/tc_diag/compute_custom_diagnostics.py"];},{domain = "nest";n_range = 100;n_azimuth = 7;delta_range_km = 12.0;diag_script = ["MET_BASE/python/tc_diag/compute_sst_diagnostics.py"];}];'}), + {'METPLUS_DOMAIN_INFO_LIST': 'domain_info = [{domain = "parent";n_range = 150;n_azimuth = 8;delta_range_km = 10.0;diag_script = ["MET_BASE/python/tc_diag/compute_all_diagnostics.py", "MET_BASE/python/tc_diag/compute_custom_diagnostics.py"];override_diags = ["RMW", "SST"];},{domain = "nest";n_range = 100;n_azimuth = 7;delta_range_km = 12.0;diag_script = ["MET_BASE/python/tc_diag/compute_sst_diagnostics.py"];override_diags = ["SST"];}];'}), ({'TC_DIAG_DATA_DOMAIN': 'parent,nest', }, {'METPLUS_DATA_DOMAIN': 'domain = ["parent", "nest"];'}), diff --git a/metplus/wrappers/tc_diag_wrapper.py b/metplus/wrappers/tc_diag_wrapper.py index 3d3e7080f..b846d578e 100755 --- a/metplus/wrappers/tc_diag_wrapper.py +++ b/metplus/wrappers/tc_diag_wrapper.py @@ -169,6 +169,7 @@ def create_c_dict(self): 'n_azimuth': 'int', 'delta_range_km': 'float', 'diag_script': 'list', + 'override_diags': 'list', } if not add_met_config_dict_list(config=self.config, app_name=self.app_name, diff --git a/parm/use_cases/met_tool_wrapper/TCDiag/TCDiag.conf b/parm/use_cases/met_tool_wrapper/TCDiag/TCDiag.conf index 993d9db89..e7bb03fe2 100644 --- a/parm/use_cases/met_tool_wrapper/TCDiag/TCDiag.conf +++ b/parm/use_cases/met_tool_wrapper/TCDiag/TCDiag.conf @@ -97,11 +97,14 @@ TC_DIAG_DOMAIN_INFO1_N_RANGE = 150 TC_DIAG_DOMAIN_INFO1_N_AZIMUTH = 8 TC_DIAG_DOMAIN_INFO1_DELTA_RANGE_KM = 10.0 #TC_DIAG_DOMAIN_INFO1_DIAG_SCRIPT = +#TC_DIAG_DOMAIN_INFO1_OVERRIDE_DIAGS = TC_DIAG_DOMAIN_INFO2_DOMAIN = nest TC_DIAG_DOMAIN_INFO2_N_RANGE = 150 TC_DIAG_DOMAIN_INFO2_N_AZIMUTH = 8 TC_DIAG_DOMAIN_INFO2_DELTA_RANGE_KM = 2.0 +#TC_DIAG_DOMAIN_INFO2_DIAG_SCRIPT = +#TC_DIAG_DOMAIN_INFO2_OVERRIDE_DIAGS = #TC_DIAG_DATA_DOMAIN = #TC_DIAG_DATA_LEVEL =