All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to PEP 440 and uses Semantic Versioning.
- Upgraded the
reusable-mypy
action to v0.15.0.
- Add
mypy
tostatic-analysis
- The
release
Github Actions workflow now uses thegh
CLI instead of the archivedrepo-sync/pull-request
action.
- The
static-analysis
Github Actions workflow now usesruff
rather thanflake8
.
- Support for Python 3.8 and 3.9 has been removed.
- Changed relative link to the watermasking readme in the repo readme to the full URL, so that the link is valid when readme content is mirrored in hyp3-docs
- A description of the
asf_tools.watermasking
sub-package has been added to theasf_tools
README - Installation instructions for
osmium-tool
have been added to theasf_tools.watermasking
README
osmium-tool
dependency handling. Becauseosmium-tool
is not distributed on PyPI and thus is not installed whenpip
installingasf_tools
,asf_tools
will now raise anImportError
whenosmium-tool
is missing that provides installation instructions. Note:osmium-tool
is distributed on conda-forge and will be included when conda installingasf_tools
.
- Scripts and entrypoints for generating our global watermasking dataset added to
watermasking
.
- You can choose whether the
ts
(threat score; default) orfmi
(Fowlkes-Mallows index) minimization metric is used for the flood mapping iterative estimator:- the
flood_map
console script entrypoint now accepts a--minimization-metric
argument - the
asf_tools.hydrosar.floopd_map.make_flood_map
function now accepts aminimization_metric
keyword argument
- the
- The flood mapping iterative estimator will ignore waterbodies smaller than a minimum number of pixels (default = 0)
- the
flood_map
console script entrypoint now accepts a--iterative-min-size
argument - the
asf_tools.hydrosar.floopd_map.make_flood_map
function now accepts aiterative_min_size
keyword argument
- the
- The HydroSAR code (
flood_map
,water_map
, andhand
) inasf_tools
has been isolated to anasf_tools.hydrosar
sub-package - The
asf_tools.hydrosar.flood_map.iterative
estimator now runs with a maximum step size of 3 instead of the default 0.5. - The
asf_tools.hydrosar.flood_map.iterative
estimator now uses the mean of the iterative bounds at the initial guess. - the known water threshold used to determine perennial water when creating flood maps will be calculated
asf_tools.hydrosar.flood_map.get_pw_threshold
if not provided get_epsg_code
andepsg_to_wkt
have been moved fromasf_tools.composite
toasf_tools.util
read_as_array
andwrite_cog
have been moved fromasf_tools.composite
toasf_tools.raster
get_coordinates
has been moved fromasf_tools.flood_map
toasf_tools.util
- The
asf_tools.hydrosar
sub-package is being moved to the HydroSAR project repository and will be provided in a new pip/conda installable packagehydrosar
. Theasf_tools.hydrosar
subpackage will be removed in a future release.
- Reverted the special handling of nan values introduced in v0.5.2, now that GDAL v3.7.0 has been released.
- Updated tests to use a water_map/flood_map job that was created using a known input SLC
- Patched issue with gdalcompare.py's handling of nan values by allowing one differences between two rasters that contain nan values. This patch can be remove once the upstream fix is released within GDAL (likely v3.7.0)
- Fixed incorrect datatype being set for
flood_mask
GeoTIFFs leading to missing nodata.
asf_tools.flood_map
now produces rasters with pixel values of a positive integer where water is present and0
where water is not present. Everywhere else is set to nodata.
- HyP3 plugin entrypoints
water_map
andflood_depth
- Added fuzzy and initial VV and VH geotiffs back to water map output package.
asf_tools.__main__
entrypoint that allows you to select which hyp3 plugin entrypoint you'd like to run (e.g.,python -m asf_tools ++process water_map ...
)
src/asf_tools/etc/entrypoint.sh
is now the docker container entrypoint, which is a simple wrapper script aroundpython -m asf_tools
- Temporary
numpy
version pin was removed; see #160
- Updated the metadata for the RGB Decomposition tool in the ArcGIS Toolbox to more accurately reflect behavior
- Minor formatting and content corrections in all ArcGIS Toolbox xml files
asf-tools
now uses asrc
layout per this recommendation.asf-tools
now only usespyproject.toml
for package creation now thatsetuptools
recommends not using setup.py.- Temporarily pin
numpy
to<1.2.4
; See: #160```
asf_tools.water_map
now produces water extent rasters with pixels values of1
where water is present and0
where water is not presentasf_tools.water_map
now uses the updated ASF Global HAND dataset derived from the 2021 release of the Copernicus GLO-30 Public DEM
asf_tools.water_map
now uses the updated ASF Global HAND dataset derived from the 2021 release of the Copernicus GLO-30 Public DEM
- The accumulation threshold can now be specified in all HAND calculation functions and entry points:
- like
calculate_hand
,calculate_hand_for_basins
andmake_copernicus_hand
functions inasf_tools.hand.calculate
now accept anacc_thresh
keyword argument - The
calculate_hand
console script entrypoint now accepts an-a
/--acc-threshold
argument
- like
asf_tools.flood_map
now creates a cloud-optimized GeoTIFF of the perennial water mask used
asf_tools.flood_map
now correctly removes perennial water from the flood depth GeoTIFFsasf_tools.flood_map
no longer calculates water/flood depth outside of the RTC VV acquisition footprint
asf_tools.dem
now uses the updated 2021 release of the Copernicus GLO-30 Public DEM
asf_tools.hand.calculate
correctly uses pyshed'ssGrid
for calculating HAND across all hydrobasins simultaneously.asf_tools.hand.calculate
will fill NaNs within the hydrobasins in the calculated HAND array with values interpolated from their neighbor's HOND (height of nearest drainage)asf_tools.flood_map.iteartive
now produces more precise flood depth estimates by averaging water levels from a range of different initial guesses
asf_tools.flood_map
and an associatedflood_map
entrypoint for making flood depth maps with products generated byasf_tools.water_map
. This functionality is still under active development and the products created using this function are likely to change in the future.
- Upgraded
asf_tools
'spysheds
dependency to versions>=0.3
asf_tools.hand.calculate_hand
now explicitly usesPysheds.prid.Grid
becausesGrid
has noadd_gridded_data
attributecalculate_hand
entrypoint now allows GDAL virtual file system (/vsi*
) paths for thehand_raster
andvector_file
arguments
- #99 with better masked array handling
- We now provide an ASF Tools docker image:
ghcr.io/asfhyp3/asf-tools
. For usage, see theasf_tools
README.
asf_tools.water_map
will raise aValueError
error if the HAND data is all zero
asf_tools.water_map
and an associatedwater_map
entrypoint for making water extent maps using a multi-mode Expectation Maximization approach and refined using Fuzzy Logicasf_tools.hand
sub package containing:asf_tools.hand.calculate
and an associatedcalculate_hand
entrypoint for calculating Height Above Nearest Drainage (HAND) from the Copernicus GLO-30 DEMasf_tools.hand.prepare
to prepare a raster from the Copernicus GLO-30 DEM derived Global HAND tiles
asf_tools.dem
to prepare a virtual raster (VRT) mosaic of the Copernicus GLO-30 DEM tilesexpectation_maximization_threshold
inasf_tools.threshold
to calculate water threshold value using a multi-mode Expectation Maximization approachtile_array
anduntile_array
inasf_tools.tile
to transform a numpy array into a set of tilesconvert_scale
inasf_tools.raster
to transform calibrated raster between decibel, power, and amplitude scales
- ASF_Tools ArcGIS toolbox now accepts inputs in dB (decibel) scale for the RGBDecomp and ScaleConversion tools.
- The
asf_tools
python package for working with Synthetic Aperture Radar (SAR) data. See the README asf_tools.composite
and an associatedmake_composite
entrypoint for making mosaics using local resolution weighting (à la David Smalls, 2012)
- This repository moved from
ASFHyP3/GIS-tools
toASFHyP3/asf-tools
due to the broadening scope of the tools contained here
- Information and links to On Demand RTC Processing in Data Search - Vertex added to documentation
- RGB Decomposition tool to generate a color image from dual-pol SAR data, which facilitates visual interpretation by decomposing the signals into surface scattering with some volume scattering (red band), volume scattering (green band), and surface scattering with very low volume scattering (blue band)
- Option to add raster outputs to the map automatically when tool processing is complete (set as default for all tools producing raster outputs, but can be turned off in the tool dialog if desired)
README.md
for the ArcGIS Toolbox to explain installation and usage
- For the Scale Conversion and RGB Decomposition tools, the scale (amplitude/power) input parameters are automatically populated when using input products that follow HyP3 naming scheme