Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(usgcln) add explicit second dimension to util2d.load calls #2097

Merged
merged 2 commits into from
Feb 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions flopy/mfusg/mfusgcln.py
Original file line number Diff line number Diff line change
Expand Up @@ -625,13 +625,13 @@ def load(cls, f, model, pak_type="cln", ext_unit_dict=None, **kwargs):
if model.verbose:
print(" Reading ibound...")
ibound = Util2d.load(
f, model, (nclnnds,), np.int32, "ibound", ext_unit_dict
f, model, (nclnnds, 1), np.int32, "ibound", ext_unit_dict
)

if model.verbose:
print(" Reading strt...")
strt = Util2d.load(
f, model, (nclnnds,), np.float32, "strt", ext_unit_dict
f, model, (nclnnds, 1), np.float32, "strt", ext_unit_dict
)

if hasattr(f, "read"):
Expand Down Expand Up @@ -788,7 +788,7 @@ def _load_items_3to6(f_obj, model, ncln, iclnnds, ext_unit_dict):
if model.verbose:
print(" Reading nndcln...")
nndcln = Util2d.load(
f_obj, model, (ncln,), np.int32, "nndcln", ext_unit_dict
f_obj, model, (ncln, 1), np.int32, "nndcln", ext_unit_dict
)
nclnnds = nndcln.array.sum()
if iclnnds > 0:
Expand All @@ -814,13 +814,13 @@ def _load_items_3to6(f_obj, model, ncln, iclnnds, ext_unit_dict):
print(" Reading iac_cln...")
nclnnds = abs(iclnnds)
iac_cln = Util2d.load(
f_obj, model, (nclnnds,), np.int32, "iac_cln", ext_unit_dict
f_obj, model, (nclnnds, 1), np.int32, "iac_cln", ext_unit_dict
)

if model.verbose:
print(" Reading ja_cln...")
ja_cln = Util2d.load(
f_obj, model, (nja_cln,), np.int32, "ja_cln", ext_unit_dict
f_obj, model, (nja_cln, 1), np.int32, "ja_cln", ext_unit_dict
)
else:
raise Exception("mfcln: negative number of CLN segments")
Expand Down
Loading