Merged
Conversation
dbrakenhoff
reviewed
Nov 5, 2024
dbrakenhoff
reviewed
Nov 5, 2024
Collaborator
dbrakenhoff
left a comment
There was a problem hiding this comment.
Looks good, some comments about the lake package from Ruben and my conversation:
- Currently the lake package has to be created before the RCH pkg because the creation of the lake package modifies the recharge/rainfall/evaporation at locations with lakes. This is somewhat sneaky and perhaps not so obvious?
- Would it make sense to pass "recharge", in which case positive recharge is rainfall and negative recharge is evaporation, OR pass both "rainfall" and "evaporation" separately? Currently recharge has something of a double meaning in the
lake_from_gdffunction. - ...
Collaborator
Author
I make some breaking (!) changes, so the user needs to get the values of rainfall and evaporation from the model dataset before running |
dbrakenhoff
reviewed
Nov 12, 2024
dbrakenhoff
reviewed
Nov 12, 2024
| "name": ["lake_0", "lake_0", "lake_1"], | ||
| "strt": [1.0, 1.0, 2.0], | ||
| "clake": [10.0, 10.0, 10.0], | ||
| "INFLOW": ["inflow", "inflow", None], |
Collaborator
Author
dbrakenhoff
approved these changes
Nov 12, 2024
OnnoEbbens
approved these changes
Nov 12, 2024
dbrakenhoff
reviewed
Nov 13, 2024
dbrakenhoff
approved these changes
Nov 13, 2024
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

This PR changes and improves the
lake_from_gdfmethod. The booleanrechargeparameter is removed, and replaced by arainfalllandevaporationparameter. A new method is introduced, calledcut_meteorological_data_from_ds, that takes the values of rainfall and evraporation from the model dataset, and returns a pandas DataFrame, with values in time for each of the lakes. This method sets therechargeandevaporationvariables in ds at the location of the lakes to 0. By doing this in a separate method, the user has more control in when this is done (before writing the RCH and EVT packages), and he can optionally change the rainfall and evaporation values before passing them to `lake_from_gdf'.Another improvement is that the
lakenovariable does not have to be supplied anymore.lake_from_gdfwill calculate thelakenovariable based on the boundname-column in the geodataframe. In outlets, the user can now pass a boundary name, to what other lake the outlet is supplying water to. This makes the code more readable. So instead of:The user now just uses the names specified in the boundname-column ("name") for lakeout:
lakes.loc[lakes['name'] == "oudehaven", "lakeout"] = "grotegracht"Also, support is added for a lake transport model (lkt) when a groundwater transport model (gwt) is supplied.
Some of the other changes are:
get_icell2d_from_xymhod, which calculates the icell2d number from a x and y coordinate.