Commit ab5f8cdd authored by Cynthia Crowley's avatar Cynthia Crowley

Remove arg window from create_forcing_file(), since only done to create 1-month forcing files

parent 33aa77cc
......@@ -37,7 +37,6 @@ from .step import Step
def create_forcing_file(workspace: DefaultWorkspace,
data: Union[ObservedForcing, ForecastForcing],
*,
window: int,
yearmon: str,
target: Optional[str]=None,
member: Optional[str]=None) -> List[Step]:
......@@ -61,7 +60,7 @@ def create_forcing_file(workspace: DefaultWorkspace,
'Pr:units',
'Pr:standard_name'
])),
output=workspace.forcing(yearmon=yearmon, target=target, member=member, window=window)
output=workspace.forcing(yearmon=yearmon, target=target, member=member, window=1)
)
]
......
......@@ -46,7 +46,7 @@ def monthly_observed(config: Config, yearmon: str, meta_steps: Dict[str, Step])
steps += config.observed_data().prep_steps(yearmon=yearmon)
# Combine forcing data for LSM run
steps += create_forcing_file(config.workspace(), config.observed_data(), yearmon=yearmon, window=1)
steps += create_forcing_file(config.workspace(), config.observed_data(), yearmon=yearmon)
# Run the LSM
steps += run_lsm(config.workspace(), config.static_data(), yearmon=yearmon)
......@@ -130,7 +130,7 @@ def monthly_forecast(config: Config,
# Assemble forcing inputs for forecast
steps += meta_steps['prepare_forecasts'].require(
create_forcing_file(config.workspace(), config.forecast_data(),
yearmon=yearmon, target=target, member=member, window=1))
yearmon=yearmon, target=target, member=member))
for member in config.forecast_ensemble_members(yearmon):
if config.should_run_lsm(yearmon):
......
......@@ -41,13 +41,13 @@ def spinup(config, meta_steps):
forcing_1mo = Step.make_empty()
for yearmon in config.historical_yearmons():
steps += config.observed_data().prep_steps(yearmon=yearmon)
for step in create_forcing_file(config.workspace(), config.observed_data(), yearmon=yearmon, window=1):
for step in create_forcing_file(config.workspace(), config.observed_data(), yearmon=yearmon):
forcing_1mo = forcing_1mo.merge(step)
steps += create_tag(name=config.workspace().tag('spinup_1mo_forcing'),
steps += create_tag(name=config.workspace().tag('spinup_1mo_forcing'),
dependencies=forcing_1mo.targets)
forcing_1mo.replace_targets_with_tag_file(config.workspace().tag('spinup_1mo_forcing'))
steps.append(forcing_1mo)
steps.append(forcing_1mo)
steps += run_lsm_from_final_norm_state(config)
for month in all_months:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment