Releases: hyriver/pygeoutils
Releases · hyriver/pygeoutils
v0.13.0
Release Notes
Internal Changes
- Write
nodata
attribute usingrioxarray
ingeotiff2xarray
since the clipping operation ofrioxarray
uses this value as fill value.
Bug Fixes
- In the
break_lines
function, convertMultiLineString
intoLineString
sinceshapely.ops.substring
only acceptsLineString
.
v0.12.3
Release Notes
New Features
- Add a function called
break_lines
for breaking lines at given points. - Add a function called
snap2nearest
for snapping points to the nearest point on a line with a given tolerance. It accepts ageopandas.GeoSeries
of points and ageopandas.GeoSeries
orgeopandas.GeoDataFrame
of lines. It automatically snaps to the closest lines in the input data.
v0.12.2
Release Notes
New Features
- Add a new class called
GeoBSpline
that generates B-splines from a set of coordinates. Thespline
attribute of this class has five attributes:x
andy
coordinates,phi
andradius
which are curvature and radius of curvature, respectively, anddistance
which is the total distance of each point along the B-spline from the starting points. - Add a new class called
Coordinates
that validates a set of lon/lat coordinates. It normalizes longitudes to the range [-180, 180) and has apoints
property that isgeopandas.GeoSeries
with validated coordinates. It uses spatial indexing to speed up the validation and should be able to handle large datasets efficiently. - Make
transform2tuple
a public function.
Internal Changes
- The
geometry
andgeo_crs
arguments ofgtiff2xarray
are now optional. This is useful for cases when the inputGeoTiff
response is the results of a bounding box query and there is no need for a geometry mask. - Replace the missing values after adding geometry mask via
xarray_geomask
by thenodatavals
attribute of the inputxarray.DataArray
orxarray.Dataset
. Therefore, the data type of the inputxarray.DataArray
orxarray.Dataset
is conserved. - Expose
connectivity
argument ofrasterio.features.shapes
function inxarray2geodf
function. - Move all private functions to a new module to make the main module less cluttered.
v0.12.1
Release Notes
Internal Changes
- Refactor
arcgis2geojson
for better readability and maintainability. - In
arcgis2geojson
set the geometry to null if its type is not supported, such as curved polylines.
v0.12.0
Release Notes
Internal Changes
- Add all the missing types so
mypy --strict
passes. - Bump version to 0.12.0 to match the release of
pygeoogc
.
v0.11.7
v0.11.6
Release Notes
New Features
- Add a new function,
xarray2geodf
, to convert anxarray.DataArray
to ageopandas.GeoDataFrame
.
v0.11.5
Release Notes
Bug Fixes
- Fix an issue with
gtiff2xarray
where thescales
andoffsets
attributes of the outputDataArray
were floats rather than tuples (:issue_3dep:[30]{.title-ref}).
Internal Changes
- Add a new function,
transform2tuple
, for convertingAffine
transforms to a tuple. Previously, theAffine
transform was converted to a tuple usingto_gdal()
method ofrasterio.Affine
which was not compatible withrioxarray
.
v0.11.4
Release Notes
Internal Changes
- Use
ujson
for JSON parsing instead oforjson
sinceorjson
only serializes tobytes
which is not compatible withaiohttp
. - Convert the transform attribute data type from
Affine
totuple
since saving an data array tonetcdf
cannot handle theAffine
type.
v0.11.3
Release Notes
- Fix an issue in
geotiff2xarray
related to saving anxarray
object to netcdf when its transform attribute hasAffine
type rather than a tuple.