diff --git a/flopy/discretization/grid.py b/flopy/discretization/grid.py index 87e24d4577..fe5af99707 100644 --- a/flopy/discretization/grid.py +++ b/flopy/discretization/grid.py @@ -128,7 +128,7 @@ class Grid: ndarrays for the x, y, and z coordinates Methods - ---------- + ------- get_coords(x, y) transform point or array of points x, y from model coordinates to spatial coordinates diff --git a/flopy/discretization/structuredgrid.py b/flopy/discretization/structuredgrid.py index befe50ded2..ba5a1a4302 100644 --- a/flopy/discretization/structuredgrid.py +++ b/flopy/discretization/structuredgrid.py @@ -140,7 +140,7 @@ class for a structured model grid y-location points for the edges of the model grid Methods - ---------- + ------- get_cell_vertices(i, j) returns vertices for a single cell at row, column i, j. """ diff --git a/flopy/discretization/vertexgrid.py b/flopy/discretization/vertexgrid.py index 580f6f9b4a..a043e6d3d6 100644 --- a/flopy/discretization/vertexgrid.py +++ b/flopy/discretization/vertexgrid.py @@ -61,7 +61,7 @@ class for a vertex model grid returns list of cells and their vertices Methods - ---------- + ------- get_cell_vertices(cellid) returns vertices for a single cell at cellid. diff --git a/flopy/export/netcdf.py b/flopy/export/netcdf.py index 6ad1daffb7..02916ad060 100644 --- a/flopy/export/netcdf.py +++ b/flopy/export/netcdf.py @@ -976,7 +976,7 @@ def initialize_group( Method to initialize a new group within a netcdf file. This group can have independent dimensions from the global dimensions - Parameters: + Parameters ---------- name : str name of the netcdf group diff --git a/flopy/export/utils.py b/flopy/export/utils.py index 1c3ee4d550..b82f934f4f 100644 --- a/flopy/export/utils.py +++ b/flopy/export/utils.py @@ -324,10 +324,11 @@ def output_helper( Returns ------- - None - Note: + None + + Note ---- - casts down double precision to single precision for netCDF files + casts down double precision to single precision for netCDF files """ assert isinstance(ml, (BaseModel, ModelInterface)) @@ -867,7 +868,7 @@ def mflist_export(f: Union[str, os.PathLike, NetCdf], mfl, **kwargs): export helper for MfList instances Parameters - ----------- + ---------- f : str or PathLike or NetCdf file path or existing export instance type (NetCdf only for now) mfl : MfList instance @@ -1024,7 +1025,7 @@ def transient2d_export(f: Union[str, os.PathLike], t2d, fmt=None, **kwargs): export helper for Transient2d instances Parameters - ----------- + ---------- f : str or PathLike filename or existing export instance type (NetCdf only for now) t2d : Transient2d instance @@ -1184,7 +1185,7 @@ def array3d_export(f: Union[str, os.PathLike], u3d, fmt=None, **kwargs): export helper for Transient2d instances Parameters - ----------- + ---------- f : str or PathLike filename or existing export instance type (NetCdf only for now) u3d : Util3d instance diff --git a/flopy/mbase.py b/flopy/mbase.py index 3cddbe8295..b36cf25551 100644 --- a/flopy/mbase.py +++ b/flopy/mbase.py @@ -1678,7 +1678,7 @@ def plot(self, SelPackList=None, **kwargs): MfList dictionary key. (default is None) Returns - ---------- + ------- axes : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis are returned. diff --git a/flopy/mf6/coordinates/modeldimensions.py b/flopy/mf6/coordinates/modeldimensions.py index 878f74a71b..b801136244 100644 --- a/flopy/mf6/coordinates/modeldimensions.py +++ b/flopy/mf6/coordinates/modeldimensions.py @@ -28,7 +28,7 @@ class DataDimensions: (optional) Methods - ---------- + ------- get_model_grid : () returns a model grid based on the current simulation data @@ -151,7 +151,7 @@ class PackageDimensions: Tuple representing the path to this package Methods - ---------- + ------- get_aux_variables : (model_num=0) returns the package's aux variables boundnames : (model_num=0) @@ -322,7 +322,7 @@ class ModelDimensions: object containing simulation time information Methods - ---------- + ------- get_model_grid : () returns a model grid based on the current simulation data diff --git a/flopy/mf6/coordinates/modelgrid.py b/flopy/mf6/coordinates/modelgrid.py index 7b3f698549..50a612511c 100644 --- a/flopy/mf6/coordinates/modelgrid.py +++ b/flopy/mf6/coordinates/modelgrid.py @@ -20,7 +20,7 @@ class ModelCell: id of model cell Methods - ---------- + ------- See Also -------- @@ -50,7 +50,7 @@ class UnstructuredModelCell(ModelCell): name of the model Methods - ---------- + ------- get_cellid : () returns the cellid get_top : () @@ -341,7 +341,7 @@ class ModelGrid: DiscretizationType.DISU) Methods - ---------- + ------- grid_type : () returns the grid type grid_type_consistent : () @@ -789,7 +789,7 @@ class UnstructuredModelGrid(ModelGrid): contains all simulation related data Methods - ---------- + ------- get_unstruct_jagged_array_list : {} returns a dictionary of jagged arrays used in the unstructured grid diff --git a/flopy/mf6/data/mfdataarray.py b/flopy/mf6/data/mfdataarray.py index 786838083e..d3c02dbdbf 100644 --- a/flopy/mf6/data/mfdataarray.py +++ b/flopy/mf6/data/mfdataarray.py @@ -1531,7 +1531,7 @@ def plot( List of unique values to be excluded from the plot. Returns - ---------- + ------- out : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. @@ -2100,7 +2100,7 @@ def plot( extracted. (default is zero). Returns - ---------- + ------- axes : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. diff --git a/flopy/mf6/data/mfdatalist.py b/flopy/mf6/data/mfdatalist.py index f35147206b..ab5a2aa663 100644 --- a/flopy/mf6/data/mfdatalist.py +++ b/flopy/mf6/data/mfdatalist.py @@ -136,7 +136,7 @@ def to_array(self, kper=0, mask=False): return array with np.nan instead of zero Returns - ---------- + ------- out : dict of numpy.ndarrays Dictionary of 3-D numpy arrays containing the stress period data for a selected stress period. The dictionary keys are the @@ -1451,7 +1451,7 @@ def plot( List of unique values to be excluded from the plot. Returns - ---------- + ------- out : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. @@ -2122,7 +2122,7 @@ def plot( List of unique values to be excluded from the plot. Returns - ---------- + ------- out : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. diff --git a/flopy/mf6/data/mfdataplist.py b/flopy/mf6/data/mfdataplist.py index dd397699df..507795e70a 100644 --- a/flopy/mf6/data/mfdataplist.py +++ b/flopy/mf6/data/mfdataplist.py @@ -815,7 +815,7 @@ def to_array(self, kper=0, mask=False): return array with np.nan instead of zero Returns - ---------- + ------- out : dict of numpy.ndarrays Dictionary of 3-D numpy arrays containing the stress period data for a selected stress period. The dictionary keys are the @@ -1882,7 +1882,7 @@ def plot( List of unique values to be excluded from the plot. Returns - ---------- + ------- out : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. @@ -2604,7 +2604,7 @@ def plot( List of unique values to be excluded from the plot. Returns - ---------- + ------- out : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. diff --git a/flopy/mf6/data/mfdatascalar.py b/flopy/mf6/data/mfdatascalar.py index 8eb4824285..94c4f1e3fd 100644 --- a/flopy/mf6/data/mfdatascalar.py +++ b/flopy/mf6/data/mfdatascalar.py @@ -668,7 +668,8 @@ def plot(self, filename_base=None, file_extension=None, **kwargs): """ Helper method to plot scalar objects - Parameters: + Parameters + ---------- scalar : flopy.mf6.data.mfscalar object filename_base : str Base file name that will be used to automatically generate file @@ -976,7 +977,7 @@ def plot( extracted. (default is zero). Returns - ---------- + ------- axes : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. diff --git a/flopy/mf6/data/mfdatautil.py b/flopy/mf6/data/mfdatautil.py index 9a4d6cdbfe..ec244c3fea 100644 --- a/flopy/mf6/data/mfdatautil.py +++ b/flopy/mf6/data/mfdatautil.py @@ -155,7 +155,7 @@ def list_to_array(sarr, model_grid, kper=0, mask=False): return array with np.nan instead of zero Returns - ---------- + ------- out : dict of numpy.ndarrays Dictionary of 3-D numpy arrays containing the stress period data for a selected stress period. The dictionary keys are the diff --git a/flopy/mf6/data/mfstructure.py b/flopy/mf6/data/mfstructure.py index f45625ed57..0b4c659695 100644 --- a/flopy/mf6/data/mfstructure.py +++ b/flopy/mf6/data/mfstructure.py @@ -63,7 +63,7 @@ class Dfn: ----- Examples - ---- + -------- """ def __init__(self): @@ -179,7 +179,7 @@ class DfnPackage(Dfn): ----- Examples - ---- + -------- """ def __init__(self, package): @@ -447,7 +447,7 @@ class DfnFile(Dfn): ----- Examples - ---- + -------- """ def __init__(self, file): diff --git a/flopy/mf6/mfpackage.py b/flopy/mf6/mfpackage.py index 43a49e5c35..f16d7be094 100644 --- a/flopy/mf6/mfpackage.py +++ b/flopy/mf6/mfpackage.py @@ -3279,7 +3279,7 @@ def plot(self, **kwargs): MfList dictionary key. (default is None) Returns - ---------- + ------- axes : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis are returned. diff --git a/flopy/mf6/mfsimbase.py b/flopy/mf6/mfsimbase.py index e924bfebff..793bee6b9c 100644 --- a/flopy/mf6/mfsimbase.py +++ b/flopy/mf6/mfsimbase.py @@ -603,7 +603,7 @@ def __repr__(self): Override __repr__ to print custom string. Returns - -------- + ------- repr string : str string describing object @@ -615,7 +615,7 @@ def __str__(self): Override __str__ to print custom string. Returns - -------- + ------- str string : str string describing object @@ -671,7 +671,7 @@ def model_names(self): Return a list of model names associated with this simulation. Returns - -------- + ------- list: list of model names """ @@ -683,7 +683,7 @@ def exchange_files(self): Return list of exchange files associated with this simulation. Returns - -------- + ------- list: list of exchange names """ @@ -1699,7 +1699,7 @@ def run_simulation( default is None, i.e. use the builtion print Returns - -------- + ------- success : bool buff : list of lines of stdout @@ -1786,7 +1786,7 @@ def model_dict(self): Return a dictionary of models associated with this simulation. Returns - -------- + ------- model dict : dict dictionary of models @@ -1805,7 +1805,7 @@ def get_model(self, model_name=None): will get the first model. Returns - -------- + ------- model : MFModel """ @@ -1833,7 +1833,7 @@ def get_exchange_file(self, filename): Name of exchange file to get Returns - -------- + ------- exchange package : MFPackage """ @@ -1853,7 +1853,7 @@ def get_file(self, filename): Name of mover file to get Returns - -------- + ------- mover package : MFPackage """ @@ -2076,7 +2076,7 @@ def register_package( Produce a filename for this package Returns - -------- + ------- (path : tuple, package structure : MFPackageStructure) """ @@ -2213,7 +2213,7 @@ def register_model(self, model, model_type, model_name, model_namefile): Solution group of model Returns - -------- + ------- model_structure_object : MFModelStructure """ @@ -2262,7 +2262,7 @@ def get_solution_package(self, key): solution package file name Returns - -------- + ------- solution_package : MFPackage """ @@ -2318,7 +2318,7 @@ def is_valid(self): Returns - -------- + ------- valid : bool Whether this is a valid simulation @@ -2556,7 +2556,7 @@ def plot( MFList dictionary key. (default is None) Returns - -------- + ------- axes: (list) matplotlib.pyplot.axes objects diff --git a/flopy/mf6/modflow/mfgnc.py b/flopy/mf6/modflow/mfgnc.py index 434f39752c..b40a6493af 100644 --- a/flopy/mf6/modflow/mfgnc.py +++ b/flopy/mf6/modflow/mfgnc.py @@ -229,7 +229,7 @@ class GncPackages(mfpackage.MFChildPackages): GncPackages is a container class for the ModflowGnc class. Methods - ---------- + ------- initialize Initializes a new ModflowGnc package removing any sibling child packages attached to the same parent package. See ModflowGnc init diff --git a/flopy/mf6/modflow/mfgwemve.py b/flopy/mf6/modflow/mfgwemve.py index e57ef46467..744439c1ed 100644 --- a/flopy/mf6/modflow/mfgwemve.py +++ b/flopy/mf6/modflow/mfgwemve.py @@ -197,7 +197,7 @@ class GwemvePackages(mfpackage.MFChildPackages): GwemvePackages is a container class for the ModflowGwemve class. Methods - ---------- + ------- initialize Initializes a new ModflowGwemve package removing any sibling child packages attached to the same parent package. See ModflowGwemve init diff --git a/flopy/mf6/modflow/mfgwfgnc.py b/flopy/mf6/modflow/mfgwfgnc.py index 4457379479..7f2a16ec12 100644 --- a/flopy/mf6/modflow/mfgwfgnc.py +++ b/flopy/mf6/modflow/mfgwfgnc.py @@ -229,7 +229,7 @@ class GwfgncPackages(mfpackage.MFChildPackages): GwfgncPackages is a container class for the ModflowGwfgnc class. Methods - ---------- + ------- initialize Initializes a new ModflowGwfgnc package removing any sibling child packages attached to the same parent package. See ModflowGwfgnc init diff --git a/flopy/mf6/modflow/mfgwfmvr.py b/flopy/mf6/modflow/mfgwfmvr.py index 73949339db..1423f652a4 100644 --- a/flopy/mf6/modflow/mfgwfmvr.py +++ b/flopy/mf6/modflow/mfgwfmvr.py @@ -406,7 +406,7 @@ class GwfmvrPackages(mfpackage.MFChildPackages): GwfmvrPackages is a container class for the ModflowGwfmvr class. Methods - ---------- + ------- initialize Initializes a new ModflowGwfmvr package removing any sibling child packages attached to the same parent package. See ModflowGwfmvr init diff --git a/flopy/mf6/modflow/mfgwtmvt.py b/flopy/mf6/modflow/mfgwtmvt.py index 9bfdf24386..d67b244944 100644 --- a/flopy/mf6/modflow/mfgwtmvt.py +++ b/flopy/mf6/modflow/mfgwtmvt.py @@ -197,7 +197,7 @@ class GwtmvtPackages(mfpackage.MFChildPackages): GwtmvtPackages is a container class for the ModflowGwtmvt class. Methods - ---------- + ------- initialize Initializes a new ModflowGwtmvt package removing any sibling child packages attached to the same parent package. See ModflowGwtmvt init diff --git a/flopy/mf6/modflow/mfmvr.py b/flopy/mf6/modflow/mfmvr.py index 2d68412267..2d30d3e13f 100644 --- a/flopy/mf6/modflow/mfmvr.py +++ b/flopy/mf6/modflow/mfmvr.py @@ -406,7 +406,7 @@ class MvrPackages(mfpackage.MFChildPackages): MvrPackages is a container class for the ModflowMvr class. Methods - ---------- + ------- initialize Initializes a new ModflowMvr package removing any sibling child packages attached to the same parent package. See ModflowMvr init diff --git a/flopy/mf6/modflow/mfmvt.py b/flopy/mf6/modflow/mfmvt.py index 8c16eea4aa..a4994f0847 100644 --- a/flopy/mf6/modflow/mfmvt.py +++ b/flopy/mf6/modflow/mfmvt.py @@ -197,7 +197,7 @@ class MvtPackages(mfpackage.MFChildPackages): MvtPackages is a container class for the ModflowMvt class. Methods - ---------- + ------- initialize Initializes a new ModflowMvt package removing any sibling child packages attached to the same parent package. See ModflowMvt init diff --git a/flopy/mf6/modflow/mfutlats.py b/flopy/mf6/modflow/mfutlats.py index c8752d9f69..09925eb878 100644 --- a/flopy/mf6/modflow/mfutlats.py +++ b/flopy/mf6/modflow/mfutlats.py @@ -177,7 +177,7 @@ class UtlatsPackages(mfpackage.MFChildPackages): UtlatsPackages is a container class for the ModflowUtlats class. Methods - ---------- + ------- initialize Initializes a new ModflowUtlats package removing any sibling child packages attached to the same parent package. See ModflowUtlats init diff --git a/flopy/mf6/modflow/mfutlobs.py b/flopy/mf6/modflow/mfutlobs.py index a917c35d83..8464e6d898 100644 --- a/flopy/mf6/modflow/mfutlobs.py +++ b/flopy/mf6/modflow/mfutlobs.py @@ -217,7 +217,7 @@ class UtlobsPackages(mfpackage.MFChildPackages): UtlobsPackages is a container class for the ModflowUtlobs class. Methods - ---------- + ------- initialize Initializes a new ModflowUtlobs package removing any sibling child packages attached to the same parent package. See ModflowUtlobs init diff --git a/flopy/mf6/modflow/mfutltas.py b/flopy/mf6/modflow/mfutltas.py index 078f1a8f21..b00d56dbc0 100644 --- a/flopy/mf6/modflow/mfutltas.py +++ b/flopy/mf6/modflow/mfutltas.py @@ -196,7 +196,7 @@ class UtltasPackages(mfpackage.MFChildPackages): UtltasPackages is a container class for the ModflowUtltas class. Methods - ---------- + ------- initialize Initializes a new ModflowUtltas package removing any sibling child packages attached to the same parent package. See ModflowUtltas init diff --git a/flopy/mf6/modflow/mfutlts.py b/flopy/mf6/modflow/mfutlts.py index 38e70b352d..3113e423e1 100644 --- a/flopy/mf6/modflow/mfutlts.py +++ b/flopy/mf6/modflow/mfutlts.py @@ -272,7 +272,7 @@ class UtltsPackages(mfpackage.MFChildPackages): UtltsPackages is a container class for the ModflowUtlts class. Methods - ---------- + ------- initialize Initializes a new ModflowUtlts package removing any sibling child packages attached to the same parent package. See ModflowUtlts init diff --git a/flopy/mf6/modflow/mfutltvk.py b/flopy/mf6/modflow/mfutltvk.py index 4f72614ebf..1d77403516 100644 --- a/flopy/mf6/modflow/mfutltvk.py +++ b/flopy/mf6/modflow/mfutltvk.py @@ -236,7 +236,7 @@ class UtltvkPackages(mfpackage.MFChildPackages): UtltvkPackages is a container class for the ModflowUtltvk class. Methods - ---------- + ------- initialize Initializes a new ModflowUtltvk package removing any sibling child packages attached to the same parent package. See ModflowUtltvk init diff --git a/flopy/mf6/modflow/mfutltvs.py b/flopy/mf6/modflow/mfutltvs.py index a21b93b8d5..d9fe1111cc 100644 --- a/flopy/mf6/modflow/mfutltvs.py +++ b/flopy/mf6/modflow/mfutltvs.py @@ -236,7 +236,7 @@ class UtltvsPackages(mfpackage.MFChildPackages): UtltvsPackages is a container class for the ModflowUtltvs class. Methods - ---------- + ------- initialize Initializes a new ModflowUtltvs package removing any sibling child packages attached to the same parent package. See ModflowUtltvs init diff --git a/flopy/mf6/utils/binaryfile_utils.py b/flopy/mf6/utils/binaryfile_utils.py index aba094a04e..91bcd0abd2 100644 --- a/flopy/mf6/utils/binaryfile_utils.py +++ b/flopy/mf6/utils/binaryfile_utils.py @@ -57,7 +57,7 @@ class MFOutputRequester: binary data from the SimulationDict() object on the fly without actually storing it in the SimulationDict() object. - Parameters: + Parameters ---------- mfdict: dict local instance of the SimulationDict() object @@ -66,12 +66,12 @@ class MFOutputRequester: key: tuple user requested data key - Methods: + Methods ------- MFOutputRequester.querybinarydata returns: Xarray object - Examples: + Examples -------- >>> data = MFOutputRequester(mfdict, path, key) >>> data.querybinarydata diff --git a/flopy/mf6/utils/mfobservation.py b/flopy/mf6/utils/mfobservation.py index 4699e7d450..33e3eefe1b 100644 --- a/flopy/mf6/utils/mfobservation.py +++ b/flopy/mf6/utils/mfobservation.py @@ -53,15 +53,16 @@ class Observations: Simple class to extract and view Observation files for Uzf models (possibly all obs/hobs)? - Input: - ------ - fi = (string) name of the observation binary output file + Parameters + ---------- + fi : str + name of the observation binary output file - Methods: - -------- + Methods + ------- get_data(): (np.array) returns array of observation data parameters: - ----------- + ---------- text = (str) specific modflow record name contained in Obs.out file idx = (int), (slice(start, stop)) integer or slice of data to be returned. corresponds to kstp*kper - 1 @@ -478,7 +479,7 @@ def _get_obsfile_names(self, partial_key, OBS8, obstype): obstype: (string) SINGLE or CONTINUOUS Returns: - -------- + ------- sets key: path to self.obs_dataDict """ diff --git a/flopy/mfusg/mfusg.py b/flopy/mfusg/mfusg.py index 9c01130a0e..6f84d2b40f 100644 --- a/flopy/mfusg/mfusg.py +++ b/flopy/mfusg/mfusg.py @@ -307,7 +307,7 @@ def _load_packages( Option to raise exceptions on package load failure. Returns - ---------- + ------- files_successfully_loaded : list of loaded files files_not_loaded : list of files that were not loaded """ diff --git a/flopy/mfusg/mfusgwel.py b/flopy/mfusg/mfusgwel.py index bb3ca0bbe6..493c7a19c7 100644 --- a/flopy/mfusg/mfusgwel.py +++ b/flopy/mfusg/mfusgwel.py @@ -249,9 +249,10 @@ def __init__( def _check_for_aux(self, options, cln=False): """Check dtype for auxiliary variables, and add to options. - Parameters: + Parameters ---------- - options: (list) package options + options: list + package options Returns ------- @@ -278,9 +279,10 @@ def _check_for_aux(self, options, cln=False): def write_file(self, f=None): """Write the package file. - Parameters: + Parameters ---------- - f: (str) optional file name + f : str, optional + file name Returns ------- diff --git a/flopy/modflow/mfwel.py b/flopy/modflow/mfwel.py index b6532331e5..e211c949a8 100644 --- a/flopy/modflow/mfwel.py +++ b/flopy/modflow/mfwel.py @@ -251,8 +251,10 @@ def write_file(self, f=None): """ Write the package file. - Parameters: - f: (str) optional file name + Parameters + ---------- + f : str, optional + file name Returns ------- diff --git a/flopy/pakbase.py b/flopy/pakbase.py index 2e69c70966..e714630217 100644 --- a/flopy/pakbase.py +++ b/flopy/pakbase.py @@ -812,7 +812,7 @@ def plot(self, **kwargs): MfList dictionary key. (default is None) Returns - ---------- + ------- axes : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis are returned. diff --git a/flopy/utils/binaryfile.py b/flopy/utils/binaryfile.py index fa70ad254f..a7d57c4e48 100644 --- a/flopy/utils/binaryfile.py +++ b/flopy/utils/binaryfile.py @@ -554,7 +554,7 @@ def get_ts(self, idx): row, and column values must be zero based. Returns - ---------- + ------- out : numpy array Array has size (ntimes, ncells + 1). The first column in the data array will contain time (totim). @@ -937,7 +937,7 @@ def get_ts(self, idx): values must be zero based. Returns - ---------- + ------- out : numpy array Array has size (ntimes, ncells + 1). The first column in the data array will contain time (totim). @@ -1474,7 +1474,7 @@ def get_unique_record_names(self, decode=False): Optional boolean used to decode byte strings (default is False). Returns - ---------- + ------- names : list of strings List of unique text names in the binary file. @@ -1499,7 +1499,7 @@ def get_unique_package_names(self, decode=False, to=False): Optional boolean used to decode byte strings (default is False). Returns - ---------- + ------- names : list of strings List of unique package names in the binary file. @@ -1520,7 +1520,7 @@ def _unique_package_names(self, to=False): Get a list of unique package names in the file Returns - ---------- + ------- out : list of strings List of unique package names in the binary file. @@ -1551,7 +1551,7 @@ def get_indices(self, text=None): 'RIVER LEAKAGE', 'STORAGE', 'FLOW RIGHT FACE', etc. Returns - ---------- + ------- out : tuple indices of selected record name in budget file. @@ -1632,7 +1632,7 @@ def get_data( 'COMPACT BUDGET' MODFLOW budget file. (Default is False.) Returns - ---------- + ------- recordlist : list of records A list of budget objects. The structure of the returned object depends on the structure of the data in the cbb file. @@ -1738,7 +1738,7 @@ def get_ts(self, idx, text=None, times=None): List of times to from which to get time series. Returns - ---------- + ------- out : numpy array Array has size (ntimes, ncells + 1). The first column in the data array will contain time (totim). @@ -1885,7 +1885,7 @@ def get_record(self, idx, full3D=False): 'COMPACT BUDGET' MODFLOW budget file. (Default is False.) Returns - ---------- + ------- record : a single data record The structure of the returned object depends on the structure of the data in the cbb file. Compact list data are returned as @@ -2065,7 +2065,7 @@ def __create3D(self, data): Dictionary with node keywords and flows (q) items. Returns - ---------- + ------- out : numpy masked array List contains unique simulation times (totim) in binary file. @@ -2083,7 +2083,7 @@ def get_times(self): Get a list of unique times in the file Returns - ---------- + ------- out : list of floats List contains unique simulation times (totim) in binary file. diff --git a/flopy/utils/datafile.py b/flopy/utils/datafile.py index 6477ecfe02..d5043f2f0d 100644 --- a/flopy/utils/datafile.py +++ b/flopy/utils/datafile.py @@ -252,7 +252,7 @@ def to_shapefile( Whether to print verbose output Returns - ---------- + ------- None See Also @@ -341,7 +341,7 @@ def plot( if filename_base is not None. (default is 'png') Returns - ---------- + ------- None See Also @@ -468,7 +468,7 @@ def get_times(self): Get a list of unique times in the file Returns - ---------- + ------- out : list of floats List contains unique simulation times (totim) in binary file. @@ -505,7 +505,7 @@ def get_data(self, kstpkper=None, idx=None, totim=None, mflay=None): all layers will be included. (Default is None.) Returns - ---------- + ------- data : numpy array Array has size (nlay, nrow, ncol) if mflay is None or it has size (nrow, ncol) if mlay is specified. @@ -556,7 +556,7 @@ def get_alldata(self, mflay=None, nodata=-9999): nodata value will be assigned np.nan. Returns - ---------- + ------- data : numpy array Array has size (ntimes, nlay, nrow, ncol) if mflay is None or it has size (ntimes, nrow, ncol) if mlay is specified. diff --git a/flopy/utils/formattedfile.py b/flopy/utils/formattedfile.py index dd4c795bae..784265037d 100644 --- a/flopy/utils/formattedfile.py +++ b/flopy/utils/formattedfile.py @@ -54,7 +54,7 @@ def read_header(self, text_file): the header Returns - ---------- + ------- out : numpy array of header information also stores the header's format string as self.format_string @@ -257,7 +257,7 @@ def get_ts(self, idx): row, and column values must be zero based. Returns - ---------- + ------- out : numpy array Array has size (ntimes, ncells + 1). The first column in the data array will contain time (totim). diff --git a/flopy/utils/geometry.py b/flopy/utils/geometry.py index d22990f8a8..dac27c1441 100644 --- a/flopy/utils/geometry.py +++ b/flopy/utils/geometry.py @@ -11,7 +11,7 @@ class Shape: """ Parent class for handling geo interfacing, do not instantiate directly - Parameters: + Parameters ---------- type : str shapetype string @@ -233,9 +233,9 @@ class MultiPolygon(Collection): Container for housing and describing multipolygon geometries (e.g. to be read or written to shapefiles or other geographic data formats) - Parameters: + Parameters ---------- - polygons : list + polygons : list, tuple, default () list of flopy.utils.geometry.Polygon objects """ @@ -261,9 +261,9 @@ class MultiLineString(Collection): Container for housing and describing multilinestring geometries (e.g. to be read or written to shapefiles or other geographic data formats) - Parameters: + Parameters ---------- - polygons : list + linestrings : list, tuple, default () list of flopy.utils.geometry.LineString objects """ @@ -289,9 +289,9 @@ class MultiPoint(Collection): Container for housing and describing multipoint geometries (e.g. to be read or written to shapefiles or other geographic data formats) - Parameters: + Parameters ---------- - polygons : list + points : list, tuple, default () list of flopy.utils.geometry.Point objects """ diff --git a/flopy/utils/mflistfile.py b/flopy/utils/mflistfile.py index 38d4b21936..df952c985a 100644 --- a/flopy/utils/mflistfile.py +++ b/flopy/utils/mflistfile.py @@ -183,7 +183,7 @@ def get_kstpkper(self): water budgets. Returns - ---------- + ------- out : list of (kstp, kper) tuples List of unique kstp, kper combinations in list file. kstp and kper values are zero-based. @@ -551,7 +551,7 @@ def get_reduced_pumping(self): file. Example - -------- + ------- >>> objLST = MfListBudget("my_model.lst") >>> raryReducedPpg = objLST.get_reduced_pumping() >>> dfReducedPpg = pd.DataFrame.from_records(raryReducedPpg) diff --git a/flopy/utils/modpathfile.py b/flopy/utils/modpathfile.py index 813160c5de..8a4dc9347e 100644 --- a/flopy/utils/modpathfile.py +++ b/flopy/utils/modpathfile.py @@ -585,7 +585,7 @@ def get_maxtraveltime(self): Get the maximum travel time. Returns - ---------- + ------- out : float Maximum travel time. @@ -600,7 +600,7 @@ def get_alldata(self): ---------- Returns - ---------- + ------- data : numpy record array A numpy recarray with the endpoint particle data diff --git a/flopy/utils/observationfile.py b/flopy/utils/observationfile.py index f2b612f8fa..73325e1139 100644 --- a/flopy/utils/observationfile.py +++ b/flopy/utils/observationfile.py @@ -18,7 +18,7 @@ def get_times(self): Get a list of unique times in the file Returns - ---------- + ------- out : list of floats List contains unique simulation times (totim) in binary file. @@ -30,7 +30,7 @@ def get_ntimes(self): Get the number of times in the file Returns - ---------- + ------- out : int The number of simulation times (totim) in binary file. @@ -42,7 +42,7 @@ def get_nobs(self): Get the number of observations in the file Returns - ---------- + ------- out : tuple of int A tuple with the number of records and number of flow items in the file. The number of flow items is non-zero only if @@ -56,7 +56,7 @@ def get_obsnames(self): Get a list of observation names in the file Returns - ---------- + ------- out : list of strings List of observation names in the binary file. totim is not included in the list of observation names. @@ -82,7 +82,7 @@ def get_data(self, idx=None, obsname=None, totim=None): data for all simulation times are returned. (default is None) Returns - ---------- + ------- data : numpy record array Array has size (ntimes, nitems). totim is always returned. nitems is 2 if idx or obsname is not None or nobs+1. diff --git a/flopy/utils/particletrackfile.py b/flopy/utils/particletrackfile.py index 5029c5860d..5cc7da452f 100644 --- a/flopy/utils/particletrackfile.py +++ b/flopy/utils/particletrackfile.py @@ -60,7 +60,7 @@ def get_maxid(self) -> int: Get the maximum particle ID. Returns - ---------- + ------- out : int Maximum particle ID. @@ -72,7 +72,7 @@ def get_maxtime(self) -> float: Get the maximum tracking time. Returns - ---------- + ------- out : float Maximum tracking time. @@ -99,7 +99,7 @@ def get_data( Whether to return only the minimal, canonical fields. Default is False. Returns - ---------- + ------- data : np.recarray Recarray with dtype ParticleTrackFile.outdtype @@ -136,7 +136,7 @@ def get_alldata(self, totim=None, ge=True, minimal=False): Whether to return only the minimal, canonical fields. Default is False. Returns - ---------- + ------- data : list of numpy record arrays List of recarrays with dtype ParticleTrackFile.outdtype diff --git a/flopy/utils/swroutputfile.py b/flopy/utils/swroutputfile.py index a75beeb7a6..e15948de25 100644 --- a/flopy/utils/swroutputfile.py +++ b/flopy/utils/swroutputfile.py @@ -109,7 +109,7 @@ def get_connectivity(self): ---------- Returns - ---------- + ------- data : numpy array Array has size (nrecord, 3). None is returned if swrtype is not 'flow' @@ -134,7 +134,7 @@ def get_nrecords(self): Get the number of records in the file Returns - ---------- + ------- out : tuple of int A tuple with the number of records and number of flow items in the file. The number of flow items is non-zero only if @@ -149,7 +149,7 @@ def get_kswrkstpkper(self): in the file Returns - ---------- + ------- out : list of (kswr, kstp, kper) tuples List of unique kswr, kstp, kper combinations in binary file. kswr, kstp, and kper values are zero-based. @@ -162,7 +162,7 @@ def get_ntimes(self): Get the number of times in the file Returns - ---------- + ------- out : int The number of simulation times (totim) in binary file. @@ -174,7 +174,7 @@ def get_times(self): Get a list of unique times in the file Returns - ---------- + ------- out : list of floats List contains unique simulation times (totim) in binary file. @@ -186,7 +186,7 @@ def get_record_names(self): Get a list of unique record names in the file Returns - ---------- + ------- out : list of strings List of unique text names in the binary file. @@ -210,7 +210,7 @@ def get_data(self, idx=None, kswrkstpkper=None, totim=None): The simulation time. (default is None) Returns - ---------- + ------- data : numpy record array Array has size (nitems). @@ -288,7 +288,7 @@ def get_ts(self, irec=0, iconn=0, klay=0, istr=0): (default is 0) Returns - ---------- + ------- out : numpy recarray Array has size (ntimes, nitems). The first column in the data array will contain time (totim). nitems is 2 for stage diff --git a/flopy/utils/util_array.py b/flopy/utils/util_array.py index b307a23538..637036281c 100644 --- a/flopy/utils/util_array.py +++ b/flopy/utils/util_array.py @@ -708,7 +708,7 @@ def plot( List of unique values to be excluded from the plot. Returns - ---------- + ------- out : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. @@ -1520,7 +1520,7 @@ def plot( extracted. (default is zero). Returns - ---------- + ------- out : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. @@ -1974,7 +1974,7 @@ def plot( List of unique values to be excluded from the plot. Returns - ---------- + ------- out : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. diff --git a/flopy/utils/util_list.py b/flopy/utils/util_list.py index 2aa3e5a5f7..968547bb62 100644 --- a/flopy/utils/util_list.py +++ b/flopy/utils/util_list.py @@ -964,7 +964,7 @@ def plot( List of unique values to be excluded from the plot. Returns - ---------- + ------- out : list Empty list is returned if filename_base is not None. Otherwise a list of matplotlib.pyplot.axis is returned. @@ -1015,7 +1015,7 @@ def to_array(self, kper=0, mask=False): mask : boolean return array with np.nan instead of zero Returns - ---------- + ------- out : dict of numpy.ndarrays Dictionary of 3-D numpy arrays containing the stress period data for a selected stress period. The dictionary keys are the MfList dtype diff --git a/flopy/utils/utils_def.py b/flopy/utils/utils_def.py index 1a4cd56dd4..4212223947 100644 --- a/flopy/utils/utils_def.py +++ b/flopy/utils/utils_def.py @@ -151,7 +151,7 @@ def get_util2d_shape_for_layer(model, layer=0): layer (base 0) for which Util2d shape is sought. Returns - --------- + ------- (nrow,ncol) : tuple of ints util2d shape for the given layer """ @@ -185,7 +185,7 @@ def get_unitnumber_from_ext_unit_dict( Default is 0, in which case the returned output file is None. Returns - --------- + ------- unitnumber : int file unit number for the given modflow package (or None) filenames : list @@ -218,7 +218,7 @@ def type_from_iterable(_iter, index=0, _type=int, default_val=0): default_val : default value (0) Returns - ---------- + ------- val : value of type _type, or default_val """ try: diff --git a/pyproject.toml b/pyproject.toml index 3d9e0607ec..067aeddc86 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -130,7 +130,12 @@ extend-include = [ ] [tool.ruff.lint] -select = ["F", "E", "I001"] +select = [ + "D409", # pydocstyle - section-underline-matches-section-length + "E", # pycodestyle error + "F", # Pyflakes + "I001", # isort - unsorted-imports +] ignore = [ "E402", # module level import not at top of file "E501", # line too long TODO FIXME