SwnMf6#

Constructors#

SwnMf6([logger])

Surface water network adaptor for MODFLOW 6.

SwnMf6.from_swn_flopy(swn, model[, ...])

Create a MODFLOW 6 SFR structure from a surface water network.

SwnMf6.from_pickle(path[, swn, model])

Read a pickled format from a file.

Properties#

SwnMf6.model

Flopy model object.

SwnMf6.segments

Geo dataframe of segments.

SwnMf6.diversions

[Geo] dataframe of diversions.

SwnMf6.reaches

Geo dataframe of model cell-by-cell reaches.

Reach data generation#

SwnMf6.set_reach_data_from_array(name, array)

Set reach data from an array that matches the model (nrow, ncol).

SwnMf6.set_reach_data_from_segments(name, value)

Set reach data based on segment series (or scalar).

SwnMf6.set_reach_slope([method, min_slope])

Set slope for reaches.

Streamflow Routing Package#

SwnMf6.default_packagedata([hyd_cond1, ...])

High-level function to set MODFLOW 6 SFR PACKAGEDATA defaults.

SwnMf6.packagedata_frame(style[, auxiliary, ...])

Return DataFrame of PACKAGEDATA for MODFLOW 6 SFR.

SwnMf6.write_packagedata(fname[, auxiliary, ...])

Write PACKAGEDATA file for MODFLOW 6 SFR.

SwnMf6.flopy_packagedata([auxiliary, boundname])

Return list of lists for flopy.

SwnMf6.connectiondata_series(style)

Return Series of CONNECTIONDATA for MODFLOW 6 SFR.

SwnMf6.write_connectiondata(fname)

Write CONNECTIONDATA file for MODFLOW 6 SFR.

SwnMf6.flopy_connectiondata()

Return list of lists for flopy.

SwnMf6.diversions_frame(style)

Return DataFrame of DIVERSIONS for MODFLOW 6 SFR.

SwnMf6.write_diversions(fname)

Write DIVERSIONS file for MODFLOW 6 SFR.

SwnMf6.flopy_diversions()

Return list of lists for flopy.

SwnMf6.set_sfr_obj([auxiliary, boundnames])

Set MODFLOW 6 SFR package data to flopy model.

Other packages#

SwnMf6.set_package_obj(package[, auxiliary, ...])

Set MODFLOW 6 package data to flopy model.

SwnMf6.package_period_frame(package, style)

Return DataFrame of PERIOD data for MODFLOW 6 packages.

SwnMf6.write_package_period(package, fname)

Write PERIOD file for MODFLOW 6 packages, to be used within OPEN/CLOSE.

SwnMf6.flopy_package_period(package[, ...])

Return dict of lists of lists for flopy's stress_period_data.

Utilities#

SwnMf6.get_location_frame_reach_info(loc_df)

Get reach information to location data frame, matched by segnum.

SwnMf6.gather_reaches(*[, upstream, ...])

Return reaches upstream (inclusive) and downstream (exclusive).

SwnMf6.route_reaches(start, end, *[, ...])

Return a list of reach numbers that connect a pair of reaches.