Skip to content

Release 0.10.0#494

Merged
rubencalje merged 190 commits intomainfrom
dev
Jul 21, 2025
Merged

Release 0.10.0#494
rubencalje merged 190 commits intomainfrom
dev

Conversation

@rubencalje
Copy link
Collaborator

So with support for PRT and the renaming of all download-methods, I think it's time for a new version: 0.10.0.

dbrakenhoff and others added 30 commits December 24, 2024 14:33
- add prt submodule with PRT packages (missing FMI at the moment)
- deprecate mpf, add ibound kwarg
- add structured kwarg to pg_from_pd (needed for structured models)
- allow directly registering solution pkgs if model is passed
- add EMS package
- add hash_xarray_coords() to compute hashes on coordinates
- add hash_xarray_data_vars() to compute hashes on data arrays
- optionally include metadata to hash, default is False
- include NumpyEncoder to allow dumping numpy objects to json.
- add an ugly fix to cast layer dtype to the one the cached dataset is using

Co-authored-by: Bas des Tombe <bdestombe@gmail.com>
* Update regis.get_layer_names() to return pre 2.2.3 names

* Renaming regis layer names if version > 2.2.3

If regis version would receive a small version bump, the origional code would crash. With the proposed changes less likely so.

* formatting

* Refactor get_layer_names function to accept dataset as an argument and streamline layer name assignment in get_regis function.

* Remove unused import of 'get' from the arrow module in regis.py

* Removed trainling white space
* add option to maken cross section animation with variable heads

* remove logger and small fix

* fix comments Davíd and add norm by default

* remove animation from local grid refinement, add aniomation for Schoonhoven

* remove comment

* textual
And change `assert ds.gridtype == "structured"` to `assert is_structured(ds)`
dbrakenhoff and others added 10 commits June 25, 2025 15:41
- usually not necessary but I think this was causing a weird error for me
mini adjustment to ensure we get the right int in our modpath input
* Mutiple changes

Add method `nlmod.grid.gdf_area_per_index_to_da'
Replace `"angrot" in ds.attrs and ds.attrs["angrot"] != 0.0` by `is_rotated(ds_out)` in `nlmod.grid`
Add docstring to `nlmod.time.dataframe_to_flopy_timeseries`
Add `nlmod.plot.get_ahn_colormap`
Add parameter `season_filename` to `nlmod.gwf.surface_water.gdf_to_seasonal_pkg`

* Fix Codacy issues

* Add docstring to `nlmod.plot.get_ahn_colormap`

* Change some names
Add pathlib.Path to the list of supported types in _same_function_arguments
for proper cache validation when Path objects are used as function arguments.
return lay * shape[1] * shape[2] + row * shape[2] + col


def get_node_vertex(lay, icell2d, shape):
Copy link
Collaborator

Choose a reason for hiding this comment

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

missing docstring for parameters shape?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Also, what is the shape for a vertex grid? Not (nrow, ncol) right?

Copy link
Collaborator Author

@rubencalje rubencalje Jul 19, 2025

Choose a reason for hiding this comment

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

It is (nlay, ncpl). The modflow manual uses ncpl to define the number of icell2d-cells. Added this to the docstring.

col : int
column number.
shape : tuple
shape of the model grid.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Maybe good to add a definition of the shape: (nrow, ncol)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

it is (nlay, nrow, ncol) I think. Added this to the docstring

obs_ds["modellayer"].values = ds["layer"][
obs_ds["modellayer"].astype(int)
].values
elif drop_nan_layers:
Copy link
Collaborator

Choose a reason for hiding this comment

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

maybe we can convert (i)layer to an int when we drop nans.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I do not really know what you mean by this. Let;s handle this later, I am afraid to break stuff now.



def get_time_step_length(perlen, nstp, tsmult):
"""Get the length of the timesteps within a singe stress-period.
Copy link
Collaborator

Choose a reason for hiding this comment

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

singe -> single

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

@github-project-automation github-project-automation bot moved this from Todo to In Progress in NHFLO Jul 18, 2025
@rubencalje
Copy link
Collaborator Author

rubencalje commented Jul 19, 2025

All 26 remaining codacy issues cannot be solved, as most are not real issues.

@rubencalje rubencalje merged commit 670891a into main Jul 21, 2025
4 of 5 checks passed
@github-project-automation github-project-automation bot moved this from In Progress to Done in NHFLO Jul 21, 2025
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.

6 participants