apply_pipe_design#
module wntr.extensions.design_verification.design
- apply_pipe_design(wn, design)[source]#
Apply selected pipe-diameter changes to a copied network.
The original WaterNetworkModel is not modified.
- Parameters:
wn (WaterNetworkModel) – Original WNTR water-distribution network model.
design (PipeDesign) – Proposed pipe-diameter changes in metres.
- Returns:
trial_wn (WaterNetworkModel) – Independent copy of the original network containing the proposed diameter changes.
audit_records (list of dict) – Records containing each pipe’s original and proposed diameter.
- Raises:
TypeError – If wn is not a WaterNetworkModel or design is not a PipeDesign.
ValueError – If the design name is empty, the design contains no changes, or a proposed diameter is invalid.
KeyError – If a named pipe does not exist in the network.
- Return type: