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

Release v0.8 #360

Merged
merged 94 commits into from
Jul 5, 2024
Merged

Release v0.8 #360

merged 94 commits into from
Jul 5, 2024

Conversation

dbrakenhoff
Copy link
Collaborator

@dbrakenhoff dbrakenhoff commented Jul 3, 2024

Getting ready for a new nlmod release v0.8...

I'm a bit confused why commits from last year are showing up in the list...? Am I doing something wrong?

EDIT: it's just the first one I guess (cef2b4b), still confusing but less worrisome.

marcovanbaar and others added 30 commits August 31, 2023 14:55
* Change from tqdm import tqdm

to from tqdm.auto import tqdm
And update notebook 2

* Fix nbconvert version

* Fix codacy issues

And revert tqdm import

* Add ipywidgets as dependency for the docs-build

* Add docstring and tests to some ahn-methods
Landflag was calculated wrongly. A value of 0 was assigned to the first active cell even if it was active. This commit fixes this.
Two issues are solved:
- If values for a large area are prompted, the query url gets very long and is not accepted by HHNK polderpeil server. Is now queried in chunks
- An error in the database of HHNK resulted in duplicate peil definitions. Only use the unambigious entries and leave a note in the logs.
* HHNK revert to old url

* Fix failing test (unrelated to other change in this PR)

---------

Co-authored-by: Ruben Caljé <r.calje@artesia-water.nl>
* Add support for NHI GWO database

with extraction data

* Add timeout to solve codacy-issues

* docs typos

* Make nhi gwo methods more robust

Add checks for empty empty content
Determine empty lines in get_gwo_wells, to be used in skiprows

* Fix codacy issue

---------

Co-authored-by: Davíd Brakenhoff <d.brakenhoff@artesia-water.nl>
* ds_to_gridprops() to also pass unaltered datavars

ds_to_gridprops() is called by refine(). If the time settings were configured prior to calling the refine function, the refine function silently threw away the steady array, as it is non-numeric. Not anymore.

* Minor edit to ds_to_gridprops
…ng (#324)

* Zero layer thickness layers are considered active due to float rounding

Subtracting two botms to calculate the thickness results is some layers with a thickness of ~1e-9. This rounding later results in a problem because this positive thickness leads to an idomain of 1.

This can either be solved in `nlmod.layers.calculating_thickness()` or in `nlmod.layers.get_idomain()`. What do you prefer?

* Remove trailing whitespace

* Applied patch also to get_idomain
* Some changes to better implement grid rotation for structured grids

* Add a test for a rotated grid

* Add extra tests for grids

And fix wrong values for xc and yc for rotated vertex grids
Also fix gdf_to_count_da for rotated grids

* Test vertex_da_to_ds and fillnan_da

* Update tests to fix failing tests

* Improve docstrings of xorigin, yorigin and angrot
* Add get_flow_residuals and get_flow_lower_face

* Minor changes

Fix lays parameter for structured grids

* Fix failing tests

* Fix last failing test

* Improve  nlmod.gwf.output.get_budget_da()

So it also works for multiple packages of the same type (for example 3 DRN-packages), by summing the budgets

* Handle comments from @OnnoEbbens and replace grbfile by grb_file

Like in flopy
* Improve export to ugrid_nc-file, to support imod qgis plugin

* Improve docstring
Error in computing the add_offset
* Update cache.py

The netcdf cache function validates the cache by comparing the ds argument and other function arguments to the pickled arguments. If they match, the cache can be used.

Currently, just the coordinates of the argument ds and the output ds had to match, introducing two errors:
- If the data_vars differ and are used the cache is falsely valid
- The coordintates of the ds argument has to match the coordinates of the output ds. This limits the use of the cache function.

The PR compares the hash of the coords and data_vars of the ds argument to those that were stored in the pickle together with the cached output ds.

Ideally, the cache.cache_netcdf() accepts arguments that specify specifically which data_vars and coords need to be included in the validation check. Beyond the scope of this pr.

- Included tests
dbrakenhoff and others added 11 commits July 3, 2024 14:09
- convert ds time coordinate to pandas DateTimeIndex, optionally with the starting date.
- can be useful for resampling time series to model period
- fixes the warning
- allows flox to be used for faster groupby operations
- Improve docststring get_exe_path
- lower log-level get_flopy_bin_directories to DEBUG
- Improve docststring get_exe_path
- lower log-level get_flopy_bin_directories to DEBUG
- typos
- numpy 2.0
- show pkg versions at top
rubencalje and others added 5 commits July 4, 2024 11:12
…ng to file)

Which would result the following error

ValueError: Dimensions {'band'} do not exist. Expected one or more of FrozenMappingWarningOnValuesAccess({'y': 600, 'x': 700})
- rendering of numbered/bulleted lists
- fix pyogrio warnings
- other minor things
- suppress pyogrio no CRS warning
Test skips were added in #358 because they failed.

Co-Authored-By: Martin Vonk <66305055+martinvonk@users.noreply.github.com>
Copy link
Collaborator

@OnnoEbbens OnnoEbbens left a comment

Choose a reason for hiding this comment

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

I only have 2 small suggestions

.github/workflows/python-publish.yml Outdated Show resolved Hide resolved
nlmod/plot/__init__.py Outdated Show resolved Hide resolved
- comments onno
- new link with info on EPSG 28992
- add trap for duplicate indices in gdf_to_grid (better error message for users)
@bdestombe
Copy link
Collaborator

Great work guys! Sorry for not being able to put more time in it at the moment.

@dbrakenhoff dbrakenhoff merged commit 9fe0e50 into main Jul 5, 2024
6 checks passed
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.

7 participants