# build the UCI and output WDM files hspfmodel.build_uci(targets, start, end, atemp = True, snow = True, hydrology = True) # run it hspfmodel.run(verbose = True) # use the Postprocessor to analyze and save the results dates = start + datetime.timedelta(days = warmup), end postprocessor = Postprocessor(hspfmodel, dates, comid = comid) postprocessor.get_hspexp_parameters(verbose = False) postprocessor.plot_hydrograph(tstep = 'monthly', show = False, output = '{}/hydrography'.format(calibration)) postprocessor.plot_calibration(output = '{}/statistics'.format(calibration), show = False) postprocessor.plot_runoff(tstep = 'daily', show = False, output = '{}/runoff'.format(calibration)) output = '{}/calibration_report.csv'.format(calibration) postprocessor.calibration_report(output = output) postprocessor.plot_snow(output = '{}/snow'.format(calibration), show = False) postprocessor.plot_dayofyear(output = '{}/dayofyear'.format(calibration), show = False) postprocessor.plot_storms(season = 'all', show = False, output = '{}/storms'.format(calibration))
# plot the runoff components, flows, and precipitation on linear and log scales p.plot_runoff(tstep='daily') # make a similar plot looking at the largest storm events for each year both # in summer and outside summer p.plot_storms(tstep='hourly') # make plots of calibration statistics including flow-duration curves and # parity plots for both daily and monthly flows p.plot_calibration(verbose=True) # get a mass balance of the components p.get_mass_balance() # calculate the HSP Expert parameters for the simulated and observed data p.get_hspexp_parameters() # calculate and show the errors in the calibration parameters. the product # of the daily log-flow and daily flow Nash-Sutcliffe model efficiency are # one possible optimization parameter for a calibration. the log-flow # captures relative errors (low-flow conditions) while the flow captures # absolute error (high-flow conditions). p.calculate_errors()
# plot the runoff components, flows, and precipitation on linear and log scales p.plot_runoff(tstep = 'daily') # make a similar plot looking at the largest storm events for each year both # in summer and outside summer p.plot_storms(tstep = 'hourly') # make plots of calibration statistics including flow-duration curves and # parity plots for both daily and monthly flows p.plot_calibration(verbose = True) # get a mass balance of the components p.get_mass_balance() # calculate the HSP Expert parameters for the simulated and observed data p.get_hspexp_parameters() # calculate and show the errors in the calibration parameters. the product # of the daily log-flow and daily flow Nash-Sutcliffe model efficiency are # one possible optimization parameter for a calibration. the log-flow # captures relative errors (low-flow conditions) while the flow captures # absolute error (high-flow conditions). p.calculate_errors()
# build the UCI and output WDM files hspfmodel.build_uci(targets, start, end, atemp=True, snow=True, hydrology=True) # run it hspfmodel.run(verbose=True) # use the Postprocessor to analyze and save the results postprocessor = Postprocessor(hspfmodel, (start, end), comid=calibrator.comid) postprocessor.get_hspexp_parameters() postprocessor.plot_hydrograph(tstep='monthly', output='{}/hydrography'.format(calibration)) postprocessor.plot_calibration(output='{}/statistics'.format(calibration)) postprocessor.plot_runoff(tstep='daily', output='{}/runoff'.format(calibration)) # Using the preprocessor in other watersheds/gages *should* be as simple as # supplying the parameters above (start and end date, state, 8-digit HUC, # NWIS gage ID, land use year, maximum drainage area); if you try and # get an error please report it!
'evaporation', 'runoff', 'groundwater', ] # build the UCI and output WDM files hspfmodel.build_uci(targets, start, end, atemp = True, snow = True, hydrology = True) # run it hspfmodel.run(verbose = True) # use the Postprocessor to analyze and save the results postprocessor = Postprocessor(hspfmodel, (start, end), comid = calibrator.comid) postprocessor.get_hspexp_parameters() postprocessor.plot_hydrograph(tstep = 'monthly', output = '{}/hydrography'.format(calibration)) postprocessor.plot_calibration(output = '{}/statistics'.format(calibration)) postprocessor.plot_runoff(tstep = 'daily', output = '{}/runoff'.format(calibration)) # Using the preprocessor in other watersheds/gages *should* be as simple as # supplying the parameters above (start and end date, state, 8-digit HUC, # NWIS gage ID, land use year, maximum drainage area); if you try and # get an error please report it!