Skip to content

Commit

Permalink
only call 'assemble_rfc_dataframes()' if rfc is activated
Browse files Browse the repository at this point in the history
  • Loading branch information
shorvath-noaa committed Nov 13, 2023
1 parent 1decd72 commit 51ea7fd
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions src/troute-network/troute/DataAssimilation.py
Original file line number Diff line number Diff line change
Expand Up @@ -559,13 +559,15 @@ def __init__(self, network, from_files, value_dict):
if rfc:
rfc_timeseries_path = str(rfc_parameters.get('reservoir_rfc_forecasts_time_series_path'))
self._rfc_timeseries_df = _read_timeseries_files(rfc_timeseries_path, timeseries_dates, start_datetime, final_persist_datetime)

self._reservoir_rfc_df, self._reservoir_rfc_param_df = assemble_rfc_dataframes(
self._rfc_timeseries_df,
network.rfc_lake_gage_crosswalk,
network.t0,
rfc_parameters,
)
self._reservoir_rfc_df, self._reservoir_rfc_param_df = assemble_rfc_dataframes(
self._rfc_timeseries_df,
network.rfc_lake_gage_crosswalk,
network.t0,
rfc_parameters,
)
else:
self._reservoir_rfc_df = pd.DataFrame()
self._reservoir_rfc_param_df = pd.DataFrame()

def update_after_compute(self, run_results):
'''
Expand Down

0 comments on commit 51ea7fd

Please sign in to comment.