Skip to content

Commit

Permalink
debug disu, cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
wpbonelli committed Dec 1, 2023
1 parent d94f938 commit 7b77d18
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions flopy/utils/gridgen.py
Original file line number Diff line number Diff line change
Expand Up @@ -286,9 +286,7 @@ def __init__(
# Set up a blank _refinement_features list with empty list for
# each layer
self._rfdict = {}
self._refinement_features = []
for k in range(self.nlay):
self._refinement_features.append([])
self._refinement_features = [[] for _ in range(self.nlay)]

# Set up blank _elev and _elev_extent dictionaries
self._asciigrid_dict = {}
Expand Down Expand Up @@ -403,7 +401,7 @@ def add_active_domain(self, feature, layers):
# expand shapefile path or create one from polygon feature
if isinstance(feature, (str, os.PathLike)):
shapefile_path = self.resolve_shapefile_path(feature)
elif isinstance(feature, list):
elif isinstance(feature, (list, tuple, np.ndarray)):
shapefile_path = self.model_ws / f"ad{len(self._addict)}.shp"
features_to_shapefile(feature, "polygon", shapefile_path)
else:
Expand Down

0 comments on commit 7b77d18

Please sign in to comment.