Published October 27, 2021
| Version v0.12.0
Software
Open
HyRiver: Hydroclimate Data Retriever
Creators
Description
Release Notes New Features
- Add support for getting instantaneous streamflow from NWIS in addition to the daily streamflow by adding
freq
argument toNWIS.get_streamflow
that can be eitheriv
ordv
. The default isdv
to retain the previous behavior of the function. - Convert the time zone of the streamflow data to UTC.
- Add attributes of the requested stations as
attrs
parameter to the returnedpandas.DataFrame
. (:issue_hydro:[75]{.title-ref}) - Add a new flag to
NWIS.get_streamflow
for returning the streamflow asxarray.Dataset
. This dataset has two dimensions;time
andstation_id
. It has ten variables which includesdischarge
and nine other station attributes. (:issue_hydro:[75]{.title-ref}) - Add
drain_sqkm
from GagesII toNWIS.get_info
. - Show
drain_sqkm
in the interactive map generated byinteractive_map
. - Add two new functions for getting NLCD data;
nlcd_bygeom
andnlcd_bycoords
. The newnlcd_bycoords
function returns ageopandas.GeoDataFrame
with the NLCD layers as columns and input coordinates, which should be a list of(lon, lat)
tuples, as thegeometry
column. Moreover, The newnlcd_bygeom
function now accepts ageopandas.GeoDataFrame
as the input. In this case, it returns adict
with keys as indices of the inputgeopandas.GeoDataFrame
. (:issue_hydro:[80]{.title-ref}) - The previous
nlcd
function is being deprecated. For now, it callsnlcd_bygeom
internally and retains the old behavior. This function will be removed in future versions.
- Set the request caching\'s expiration time to never expire. Add two flags to all functions to control the caching:
expire_after
anddisable_caching
. - Replace
NID
class with the new RESTful-based web service of National Inventory of Dams. The new NID service is very different from the old one, so this is considered a breaking change.
- Improve exception handling in
NWIS.get_info
when NWIS returns an error message rather than 500s web service error. - The
NWIS.get_streamflow
function now checks if the site info dataset contains any duplicates. Therefore, all the remaining station numbers will be unique. This prevents an issue with settingattrs
where duplicate indexes cause an exception when being converted to a dict. (:issue_hydro:[75]{.title-ref}) - Add all the missing types so
mypy --strict
passes.
Notes
Files
cheginit/pygeohydro-v0.12.0.zip
Files
(62.0 kB)
Name | Size | Download all |
---|---|---|
md5:1adb23e869e11292128b200989c4b2d3
|
62.0 kB | Preview Download |
Additional details
Related works
- Is supplement to
- https://github.com/cheginit/pygeohydro/tree/v0.12.0 (URL)