Recent Releases of xagg
xagg - v0.3.3.1
What's Changed
- Bug fixes and optimizations in numba implementation, better partial nan warnings by @ks905383 in https://github.com/ks905383/xagg/pull/92
Full Changelog: https://github.com/ks905383/xagg/compare/v0.3.3...v0.3.3.1
Major changes
- The
numbaimplementation works withweightsnow (closing #91 ) and is much faster - The partial nan warning is now much clearer, and won't trigger when all grid cells for a given coordinate value are nan (in which case, the output is nan anyways)
Scientific Software - Peer-reviewed
- Python
Published by ks905383 11 months ago
xagg - v0.3.3
v0.3.3
We have a new backend implementation for particularly large datasets! Try running your code with :
with xa.set_options(impl='numba'):
and let us know your experiences!
What's Changed
- Bump mamba-org/setup-micromamba from 1 to 2 by @dependabot in https://github.com/ks905383/xagg/pull/84
- Fixes triggered regridding on identical grids issue by @ks905383 in https://github.com/ks905383/xagg/pull/87
- add fixds to diagfig call by @ks905383 in https://github.com/ks905383/xagg/pull/88
- Bump codecov/codecov-action from 4 to 5 by @dependabot in https://github.com/ks905383/xagg/pull/89
- Implement numba backend option by @ks905383 in https://github.com/ks905383/xagg/pull/90
Full Changelog: https://github.com/ks905383/xagg/compare/v0.3.2.4...v0.3.3
Scientific Software - Peer-reviewed
- Python
Published by ks905383 about 1 year ago
xagg - v0.3.2.4
Bug fixes
- The
impl='dot_prod'functionality now supports >2-D data
What's Changed
- Fix dotprod extradims by @JPMastrogiacomo in https://github.com/ks905383/xagg/pull/81
- Fix dotprod extradims by @ks905383 in https://github.com/ks905383/xagg/pull/83
New Contributors
- @JPMastrogiacomo made their first contribution in https://github.com/ks905383/xagg/pull/81
Full Changelog: https://github.com/ks905383/xagg/compare/v0.3.2.3...v0.3.2.4
Scientific Software - Peer-reviewed
- Python
Published by ks905383 over 1 year ago
xagg - v0.3.2.3
Minor updates
wm.diag_fig()no longer needs the extrasubset_findstep to homogenize gridswm.diag_fig()now covered by tests- minor bug fixes
What's Changed
- Create tests for diag_fig() robustness, make auxfuncs work with silent option by @ks905383 in https://github.com/ks905383/xagg/pull/76
Full Changelog: https://github.com/ks905383/xagg/compare/v0.3.2.2...v0.3.2.3
Scientific Software - Peer-reviewed
- Python
Published by ks905383 over 1 year ago
xagg - 0.3.2.2
Updates
- Regridding weights to the input dataset grid now uses the "conservative" regridding algorithm from
xesmfinstead of the "bilinear" one; the bilinear one is inappropriate for many weights (population, etc.), since it throws away many low-valued source boxes. - Weights now have
nans set to 0 before regridding, to make surenanpixels are included in weights. Sincenans usually imply 0s in weights (for example, population weights for which water surfaces are set tonan), this prevents entire coarser pixels from being set to 0 if they overlap with anan - Both of the above can be changed with
xa.set_options(rgrd_alg='bilinear',nan_to_zero_regridding=False), respectively.
Bug fixes
wm.diag_fig()now accepts DataArrays, as stated in docs.
What's Changed
- Increase codecov by @ks905383 in https://github.com/ks905383/xagg/pull/72
- Diag fig fix by @kerriegeil in https://github.com/ks905383/xagg/pull/73
- Add in main updates by @ks905383 in https://github.com/ks905383/xagg/pull/74
- Changes regridding algorithm default to conservative, done after setting weight nans to 0s by @ks905383 in https://github.com/ks905383/xagg/pull/75
Full Changelog: https://github.com/ks905383/xagg/compare/v0.3.2.1...v0.3.2.2
Scientific Software - Peer-reviewed
- Python
Published by ks905383 over 1 year ago
xagg - v0.3.2.1
Major updates
Creates a module-wide way to set defaults for : - silencing behavior - backend algorithm
So, for example, to set the backend to use the dot product implementation, call:
import xagg as xa
xa.set_options(impl='dot_product')
Alternatively, use a with block for individual chunks of code, here using an example with silent:
with xa.set_options(silent=True):
wm = xa.pixel_overlaps(ds,gdf)
which silences all status updates.
Bug fixes
Closes #55 ; silent=True now should suppress all status updates to standard out.
Scientific Software - Peer-reviewed
- Python
Published by ks905383 over 1 year ago
xagg - v0.3.2.0
Major Changes
Features
xesmfis now an optional dependency, which should remove a lot of installation issues; this should close #47 .- Support for Windows: the
auxmodule has been renamedauxfuncs; together with making thexesmfdependency optional, this should close #23 #22 #58 . - The
weightmapclass now has a new method that creates diagnostic figures, showing individual polygons and the grid that overlaps with them, shaded by overlapping area. Try it out and let me know what you think! (wm.diag_fig())
Bug fixes
xaggis now more robust to grids with a challenging relationship with major longitudes / latitudes: notably, grids can now have grid cells that cross the antimeridian (following GeoJSON conventions of splitting those into MultiPolygons)xa.aux.get_bnds()now works with grids that are misaligned with the antimeridian, that only partially cross the antimeridian, or that have half pixels at the poles-
xa.core.process_weights()now will matchweightsgrids todsgrids even if they arenp.allclose()but not identical, and throws a warning if the resultantweightsvariables is entirely 0s ornp.nans xa.aux.normalize()will now returnnp.nanarrays if the vector is entirely 0s (to avoid the divide by 0 warning)silent=Trueshould now actually prevent all normal standard output. Most warnings are unaffected. Closes #55 .
Short Changelog
- Bump actions/setup-python from 4 to 5 by @dependabot in https://github.com/ks905383/xagg/pull/53
- Fixing wraparound issue by @ks905383 in https://github.com/ks905383/xagg/pull/60
- Aims to address #58 and #23 by renaming
auxtoauxfuncsby @ks905383 in https://github.com/ks905383/xagg/pull/61 - Closes #55 by making silent=True silence all std out by @ks905383 in https://github.com/ks905383/xagg/pull/63
- make tests more robust to dot product implementation by @ks905383 in https://github.com/ks905383/xagg/pull/64
- Remove explicit dependency on
xesmfby @ks905383 in https://github.com/ks905383/xagg/pull/65 - Update test envs to support python 3.9-3.12, plus an env without xesmf by @ks905383 in https://github.com/ks905383/xagg/pull/66
Full Changelog: https://github.com/ks905383/xagg/compare/v0.3.1.1...v0.3.2.0
Scientific Software - Peer-reviewed
- Python
Published by ks905383 about 2 years ago
xagg - v0.3.1
New features:
- Suppress status updates through silent=True feature, closes #38
Bug fixes:
- Fixes incorrect for loop call, closes #37
- Fixes warnings and errors from gpd.overlay(), closes #24
- Addresses a few FutureWarnings, etc.
- Fixes ESMF installation issue.
Scientific Software - Peer-reviewed
- Python
Published by ks905383 over 2 years ago
xagg - v0.3.0.2
Bug fixes
.to_dataset()functions again.read_wm()is now loaded by default
What's Changed
- fix export to dataset issue, insert export tests by @ks905383 in https://github.com/ks905383/xagg/pull/35
- add read_wm() to init by @ks905383 in https://github.com/ks905383/xagg/pull/36
Full Changelog: https://github.com/ks905383/xagg/compare/v0.3.0.1...v0.3.0.2
Scientific Software - Peer-reviewed
- Python
Published by ks905383 almost 4 years ago
xagg - v0.3.0
Performance upgrades
Various performance upgrades, particularly for working with high resolution grids.
In create_raster_polygons:
- replacing the for-loop assigning pixels to polygons with a lambda apply
- creating flexible buffer for subsetting to bounding box, replacing the hardcoded 0.1 degrees used previously with twice the max grid spacing
In aggregate:
- an optional replacement of the aggregating calculation with a dot-product implementation (impl='dot_product' in pixel_overlaps() and aggregate()), which may improve performance in certain situations
Expanded functionality
Weightmaps can now be saved using wm.to_file() and loaded using xagg.core.read_wm(), and no longer have to be regenerated with each code run.
Bug fixes
Various bug fixes
What's Changed
- speed improvement for high res grids in createrasterpolygons by @kerriegeil in https://github.com/ks905383/xagg/pull/29
- dot product implementation by @jsadler2 in https://github.com/ks905383/xagg/pull/4
- Speedup for large grids - mod gdfpixels in createraster_polgons by @kerriegeil in https://github.com/ks905383/xagg/pull/30
- implement making dot product optional, restoring default agg behavior by @ks905383 in https://github.com/ks905383/xagg/pull/32
- Implement a way to save weightmaps (output from
pixel_overlaps) by @ks905383 in https://github.com/ks905383/xagg/pull/33
New Contributors
- @kerriegeil made their first contribution in https://github.com/ks905383/xagg/pull/29
- @jsadler2 made their first contribution in https://github.com/ks905383/xagg/pull/4
Full Changelog: https://github.com/ks905383/xagg/compare/v0.2.6...v0.3.0
Scientific Software - Peer-reviewed
- Python
Published by ks905383 almost 4 years ago
xagg - v0.2.6
Bug fixes:
- #11 pixel_overlaps no longer changes the gdf_in outside of the function
Functionality tweaks
- added agg.to_geodataframe(), similar to agg.to_dataframe(), but keeping the geometries from the original shapefile
- adapted xarray's ds.to_dataframe() in agg.to_dataframe(), which has better functionality
- .csvs now export long instead of wide, using the output from ds.to_dataframe() above
Scientific Software - Peer-reviewed
- Python
Published by ks905383 about 4 years ago