Skip to content

Add get_flow_residuals and get_flow_lower_face#327

Merged
rubencalje merged 6 commits intodevfrom
output_from_flow-ja-face
Mar 6, 2024
Merged

Add get_flow_residuals and get_flow_lower_face#327
rubencalje merged 6 commits intodevfrom
output_from_flow-ja-face

Conversation

@rubencalje
Copy link
Collaborator

@rubencalje rubencalje commented Feb 22, 2024

See the title of this PR

@rubencalje rubencalje marked this pull request as ready for review February 23, 2024 08:59
So it also works for multiple packages of the same type (for example 3 DRN-packages), by summing the budgets
Parameters
----------
ds : xarray.Dataset
Xarray dataset with model data.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Xarray dataset with model data and the 'botm' datavar.

return da


def get_flow_lower_face(ds, kstpkper=None, grb_file=None, lays=None):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sluikreclame? Why not layers instead of lays?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Omdat het integers zijn. layer duidt meer op de laag-naam.

flowja = cbf.get_data(text="FLOW-JA-FACE", kstpkper=kstpkper)

if ds.gridtype == "vertex":
# detemine flf_index first
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo: determine

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed

return np.ma.sum(data, axis=0)


def _get_binary_budget_record(fobj, ipos, header, column):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

docstring?

@rubencalje
Copy link
Collaborator Author

Thanks for the review. I implemented most of the requested changes. On top of that, I renamed grbfile to grb_file everywhere, as this is also the way FloPy names this variable.

@rubencalje rubencalje merged commit 7232234 into dev Mar 6, 2024
@rubencalje rubencalje deleted the output_from_flow-ja-face branch March 6, 2024 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants