mwtoews / surface-water-network

A Python package to create and analyze surface water networks.
https://mwtoews.github.io/surface-water-network/
BSD 3-Clause "New" or "Revised" License
28 stars 7 forks source link

Massive geopandas deprication warnings #64

Closed wkitlasten closed 10 months ago

wkitlasten commented 2 years ago

Not sure how to address this, but the repeated warnings from geopandas (0.9.0) are a bit overwhelming.

My code: ngwf = swn.SwnMf6.from_swn_flopy(n, model=gwf)

The warning (x heaps): C:\ProgramData\Anaconda3\envs\py37\lib\site-packages\geopandas\geoseries.py:207: DeprecationWarning: The default dtype for empty Series will be 'object' instead of 'float64' in a future version. Specify a dtype explicitly to silence this warning.

Not sure where the empty series is being being created. Any suggestions?

wkitlasten commented 2 years ago

seems to come from the overlay? Perhaps keep_geom_type=False, as per: https://stackoverflow.com/questions/62517901/missing-result-of-geopandas-overlay-for-polygons-that-overlap-and-touch-how

https://github.com/mwtoews/surface-water-network/blob/6db6be0382ad970e611207184bd45a4e37b125d4/swn/modflow/_base.py#L728

mwtoews commented 10 months ago

Hopefully resolved with new package updates! Also a few dtype fixes to warnings were just pushed here.