Closed forsyth2 closed 3 years ago
Streamflow diagnostics will likely require at least the following:
In templates/default.ini
:
[ts]
: var_xtr = string(default="")
[[__many__]]
subsection of [ts]
: var_xtr = string(default=None)
'streamflow'
to sets
under [e3sm_diags]
and [e3sm_diags_vs_model]
In templates/e3sm_diags.bash
:
rofDir=/lcrc/group/e3sm/ac.forsyth2/E3SM_simulations/20210122.v2_test01.piControl.ne30pg2_EC30to60E2r2-1900_ICG.chrysalis/post/rof/native/ts/monthly/10yr
mkdir -p rof_links
cd rof_links
v="RIVER_DISCHARGE_OVER_LAND_LIQ"
xml_name=${v}_${Y1}01_${Y2}12.xml
cdscan -x ${xml_name} ${rofDir}/${v}_*.nc
cd ..
In the e3sm.py
section of templates/e3sm_diags.bash
:
from acme_diags.parameter.streamflow_parameter import StreamflowParameter
streamflow_param = StreamflowParameter()
streamflow_param.reference_data_path = '{{ obs_ts }}'
streamflow_param.test_data_path = test_ts
streamflow_param.test_name = short_name
streamflow_param.test_start_yr = start_yr
streamflow_param.test_end_yr = end_yr - # Streamflow gauge station data range from year 1986 to 1995
streamflow_param.ref_start_yr = "1986"
streamflow_param.ref_end_yr = "1995"
streamflow_param
to the runner.run_diags
lineIn templates/ts.bash
:
ncclimo
call:
{%- if var_xtr != '' %}
--var_xtr={{ var_xtr }} \
{%- endif %}
In the configuration file (not part of zppy
):
[ts]
:
[[ rof_monthly ]]
input_subdir = "archive/rof/hist"
input_files = "mosart.h0"
frequency = "monthly"
mapping_file = ""
vars = "RIVER_DISCHARGE_OVER_LAND_LIQ"
var_xtr = 'areatotal2'
RIVER_DISCHARGE_OVER_LAND_LIQ
to [e3sm_diags]
> [[ atm_monthly_180x360_aave ]]
> vars
Add streamflow diagnostics