pywatershed.StarfitFlowNodeMaker#

class pywatershed.StarfitFlowNodeMaker(discretization, parameters, calc_method=None, io_in_cfs=True, verbose=None, compute_daily=False, imbalance_behavior=None, nhrs_substep=None)[source]#

STARFIT FlowNodeMaker: Storage Targets And Release Function Inference Tool.

This FlowNodeMaker instantiates StarfitFlowNodes for FlowGraph.

See FlowGraph for discussion and a worked example. The notebook examples/06_flow_graph_starfit.ipynb highlights adding a StarfitFlowNode a FlowGraph otherwised comprised of PRMSChannelFlowNodes using the helper functions prms_channel_flow_graph_to_model_dict() and prms_channel_flow_graph_postprocess().

__init__(discretization, parameters, calc_method=None, io_in_cfs=True, verbose=None, compute_daily=False, imbalance_behavior=None, nhrs_substep=None)[source]#

Instantiate StarfitFlowNodeMaker.

Parameters:
  • discretization (Parameters) – A Parameters object.

  • parameters (Parameters) – A Parmaeters object with the parameters listed in StarfitFlowNode dimensioned by number of reservoirs/nodes to instantiate.

  • calc_method (Literal['numba', 'numpy']) – One of “numba” or “numpy”.

  • io_in_cfs (bool) – Are the units in cubic feet per second? False gives units of cubic meters per second.

  • compute_daily (bool) – Daily or subtimestep calculation?

  • nhrs_substep (int) – Number of hours in the subtimestep.

  • imbalance_behavior (Literal['defer', None, 'warn', 'error']) – One of “defer”, “warn”, or “error”.

  • verbose (bool) – bool = None,

Methods

__init__(discretization, parameters[, ...])

Instantiate StarfitFlowNodeMaker.

get_dimensions()

Get a tuple of dimension names for this StarfitFlowNodeMaker.

get_node(control, index)

Instantiate FlowNode at a given index.

get_parameters()

Get a tuple of parameter names for StarfitFlowNodeMaker.

static get_dimensions()[source]#

Get a tuple of dimension names for this StarfitFlowNodeMaker.

Return type:

tuple

get_node(control, index)[source]#

Instantiate FlowNode at a given index.

Parameters:
  • control – A Control object.

  • index – The index in the discretization and parameter data to use when instantiating a FlowNode.

Return type:

StarfitFlowNode

static get_parameters()[source]#

Get a tuple of parameter names for StarfitFlowNodeMaker.

Return type:

tuple