Пример #1
0
    # 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))
Пример #2
0
# here are some examples of things that can be done with the postprocessor.
# many of these require certain external targets to be specified when building
# the model (e.g. runoff, groundwater, snow)

# make a plot of daily or monthly flows, precipitation, and evapotranspiration

p.plot_hydrograph(tstep = 'daily')

# 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 
Пример #3
0
# here are some examples of things that can be done with the postprocessor.
# many of these require certain external targets to be specified when building
# the model (e.g. runoff, groundwater, snow)

# make a plot of daily or monthly flows, precipitation, and evapotranspiration

p.plot_hydrograph(tstep='daily')

# 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
Пример #4
0
        "runoff",
        "groundwater",
        "snow_state",
        "snowpack",
        "snowfall",
    ]

    # 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))