diff --git a/CHANGELOG.md b/CHANGELOG.md index c3dde88..e50506e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,7 +10,7 @@ and uses [Semantic Versioning](https://semver.org/spec/v2.0.0.html). ### Fixed * `isce2_topsapp` CLI dispatch raised `KeyError: 'console_scripts'` on Python 3.12. Now uses the `entry_points(group=..., name=...)` API, resolving the long-standing `FIXME`. -* Updated dem to match NISAR-DEM within 1 cm. +* The DEM is stitched as it was before `dem-stitcher` 3.0.0, so heights stay consistent with the existing ARIA GUNW archive. 3.0.0 moved geoid removal onto the native DEM grid and changed the default registration, which shifted ellipsoidal heights by up to ~3 cm relative to every previously delivered product (it is the more accurate DEM - it agrees with the NISAR DEM to ~1 mm - but time-series consistency wins here). `download_dem_for_isce2` now passes `dst_area_or_point='Point'` and `geoid_correction_mode='aria-legacy'` to `stitch_dem`, which reproduces the 2.5.x correction bit-for-bit (see [dem-stitcher#171](https://github.com/ACCESS-Cloud-Based-InSAR/dem-stitcher/pull/171)); a `UserWarning` is emitted on every call by design. * The JRC/Pekel water mask no longer punches holes in the open ocean. The `255` no-data code is now honored (previously it was reprojected with bilinear resampling, which averaged `255` into neighboring occurrence values and painted a spurious water halo along every no-data edge) and the occurrence threshold dropped from `95` to `90` percent, since open ocean dithers between ~90 and 100 along Landsat WRS-2 scene edges. No-data blocks are dilated by 3 pixels to swallow the thin rim of `0`-occurrence pixels that reads as land and draws hairline seams through the sea. The thresholding logic lives in `water_mask.water_mask_from_occurrence` and is shared by the browse-image mask (`water_mask.py`) and the ISCE2 processing mask (`localize_mask.py`), so the two can no longer drift apart. The processing mask filename now tracks the threshold constant. ### Changed @@ -24,6 +24,7 @@ and uses [Semantic Versioning](https://semver.org/spec/v2.0.0.html). * Solid earth tide test data is computed once per session via the `gunw_paths_with_set` fixture rather than recomputed by each test, and the notebook-derived tests read local test data instead of downloading a GUNW from ASF. * Tests that write to the working directory now run under `tmp_path`, so DEMs, orbits and AUX_CAL files no longer accumulate in the repository root. * Moved the sample delivered GUNW metadata from the repository root into `tests/test_data/`. +* `dem_stitcher` is now pinned to `>=3.1.1`, the first release with `geoid_correction_mode`. The locked environment resolves to 3.2.0, which also declares the source nodata when reprojecting - gdal >= 3.11 was otherwise remapping the JRC/Pekel `255` no-data code to `254` in the water mask reprojection. * Loosened the stale `scipy<1.10` and `jsonschema==3.2.0` pins (neither is required by the code) and pinned remaining dependencies with semver bounds. * `isce2` has been updated v2.6.5 to enable full S1C and S1D support. `isce2` is still strictly pinned to `==2.6.5`. diff --git a/environment.yml b/environment.yml index 957993a..dbc89bb 100644 --- a/environment.yml +++ b/environment.yml @@ -46,7 +46,7 @@ dependencies: - setuptools_scm - shapely - tqdm - - dem_stitcher>=2.5.8 + - dem_stitcher>=3.1.1 - aiohttp # only needed for manifest and swath download - tile_mate>=0.0.8 - s1_orbits diff --git a/isce2_topsapp/localize_dem.py b/isce2_topsapp/localize_dem.py index d602dd8..1d99137 100644 --- a/isce2_topsapp/localize_dem.py +++ b/isce2_topsapp/localize_dem.py @@ -84,7 +84,10 @@ def download_dem_for_isce2( extent_buffered, dem_name, dst_ellipsoidal_height=True, - dst_area_or_point=None, + # 'Point' + 'aria-legacy' reproduce the pre-3.0.0 dem-stitcher DEM for time-series + # consistency with the existing ARIA GUNW archive + dst_area_or_point='Point', + geoid_correction_mode='aria-legacy', n_threads_downloading=5, # ensures square resolution dst_resolution=dem_res, diff --git a/pixi.lock b/pixi.lock index f52c488..4210696 100644 --- a/pixi.lock +++ b/pixi.lock @@ -346,7 +346,7 @@ environments: - conda: https://conda.anaconda.org/conda-forge/noarch/dask-core-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/dateparser-1.4.2-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2 - - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.0.0-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.2.0-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/distributed-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/exceptiongroup-1.3.1-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/executing-2.2.1-pyhd8ed1ab_0.conda @@ -536,7 +536,7 @@ environments: - conda: https://conda.anaconda.org/conda-forge/noarch/dask-core-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/dateparser-1.4.2-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2 - - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.0.0-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.2.0-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/distributed-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/exceptiongroup-1.3.1-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/executing-2.2.1-pyhd8ed1ab_0.conda @@ -1265,7 +1265,7 @@ environments: - conda: https://conda.anaconda.org/conda-forge/noarch/dask-core-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/dateparser-1.4.2-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2 - - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.0.0-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.2.0-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/distributed-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/exceptiongroup-1.3.1-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/executing-2.2.1-pyhd8ed1ab_0.conda @@ -1455,7 +1455,7 @@ environments: - conda: https://conda.anaconda.org/conda-forge/noarch/dask-core-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/dateparser-1.4.2-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2 - - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.0.0-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.2.0-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/distributed-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/exceptiongroup-1.3.1-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/executing-2.2.1-pyhd8ed1ab_0.conda @@ -2186,7 +2186,7 @@ environments: - conda: https://conda.anaconda.org/conda-forge/noarch/dask-core-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/dateparser-1.4.2-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2 - - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.0.0-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.2.0-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/distributed-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/exceptiongroup-1.3.1-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/executing-2.2.1-pyhd8ed1ab_0.conda @@ -2379,7 +2379,7 @@ environments: - conda: https://conda.anaconda.org/conda-forge/noarch/dask-core-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/dateparser-1.4.2-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2 - - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.0.0-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.2.0-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/distributed-2026.7.1-pyhc364b38_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/exceptiongroup-1.3.1-pyhd8ed1ab_0.conda - conda: https://conda.anaconda.org/conda-forge/noarch/executing-2.2.1-pyhd8ed1ab_0.conda @@ -9643,9 +9643,9 @@ packages: run_exports: {} size: 24062 timestamp: 1615232388757 -- conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.0.0-pyhd8ed1ab_0.conda - sha256: f728ddf7a6ff97787aeb8e10fe96f7e8604ea106339f141dd62f59ef8e4fea05 - md5: 5e379844088fac5dde6d35aa2a8361bb +- conda: https://conda.anaconda.org/conda-forge/noarch/dem_stitcher-3.2.0-pyhd8ed1ab_0.conda + sha256: 5740e7a5e8f6529d1f20c7e596de69e38f401986114e91a79d7aec24a2fae4fb + md5: ca6d18f56d1cbdd7d58cf90198dd37b8 depends: - affine - boto3 @@ -9654,7 +9654,7 @@ packages: - numpy - pyarrow - pyproj - - python >=3.10 + - python >=3.11 - rasterio - requests - shapely @@ -9664,8 +9664,8 @@ packages: purls: - pkg:pypi/dem-stitcher?source=hash-mapping run_exports: {} - size: 29307294 - timestamp: 1786724294651 + size: 29286802 + timestamp: 1787268310462 - conda: https://conda.anaconda.org/conda-forge/noarch/distributed-2026.7.1-pyhc364b38_0.conda sha256: bae0d85df264228cbd485b444bd1f5135e32093e32503aa72e4b4b61636d12b2 md5: f06a1abc946ca9b6107851cf148621f3 diff --git a/pyproject.toml b/pyproject.toml index df43209..4f2fe04 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -23,7 +23,7 @@ dependencies = [ "asf_search>=10.0.5", "boto3", "dateparser", - "dem_stitcher>=2.5.8", + "dem_stitcher>=3.1.1", "geopandas", "s1_orbits", "jinja2", @@ -181,7 +181,7 @@ setuptools = ">=83.0.0,<84" setuptools_scm = ">=10.2.1,<11" shapely = ">=2.1.2,<3" tqdm = ">=4.70.0,<5" -dem_stitcher = ">=3,<4" +dem_stitcher = ">=3.1.1,<4" aiohttp = ">=3.14.3,<4" tile_mate = ">=0.0.15" s1_orbits = ">=0.2.0,<0.3"