Skip to content

Fix the troposphere phase screen datacube across the dateline#330

Merged
xhuang-jpl merged 2 commits into
isce-framework:developfrom
xhuang-jpl:fix_tropo
Jun 29, 2026
Merged

Fix the troposphere phase screen datacube across the dateline#330
xhuang-jpl merged 2 commits into
isce-framework:developfrom
xhuang-jpl:fix_tropo

Conversation

@xhuang-jpl

@xhuang-jpl xhuang-jpl commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Problem: The AOI bounding box used plain min/max over radar-grid longitudes. For scenes crossing ±180°, wrapped longitudes (e.g. +179°/−179°) inflate the AOI to ~358° wide, so RAiDER loads a near-global weather model and the delay cube is wrong for dateline-crossing acquisitions.

Fix: Wrap raider_tropo_delay in compute_tropo_delay_dateline, which detects the crossing and only then splits the output grid into east/west sub-AOIs, runs each against its own weather-model crop, and merges the cubes back along x (reassembled in original column order). Non-crossing scenes take a single call with unchanged behavior.

Runtime: It takes about 64 seconds on the c5.4xlarge instance, and the plot looks like

image

@bhawkins bhawkins left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the patch. The approach makes sense, though it has some limitations.

Comment thread python/packages/nisar/workflows/troposphere.py
Comment thread python/packages/nisar/workflows/troposphere.py
Comment thread python/packages/nisar/workflows/troposphere.py Outdated
Comment thread python/packages/nisar/workflows/troposphere.py
Comment thread python/packages/nisar/workflows/troposphere.py Outdated
Comment thread python/packages/nisar/workflows/troposphere.py Outdated
Comment thread python/packages/nisar/workflows/troposphere.py
-------
the (merged) xarray.Dataset tropospheric delay cube
'''
rtd = tropo_delay_fn or raider_tropo_delay

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure why tropo_delay_fn is introduced. Previously, it seems that you used the radar_tropo_delay at default, and I don't see the usage of tropo_delay_fn.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it is a parameter of the compute_tropo_delay function and its default is radar_tropo_delay, I can delete it.

@bhawkins bhawkins left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks. Hopefully we can address the remaining gap in a future PR.

@hfattahi hfattahi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We reviewed in a PR review and these changes look good to me.
Please open an issue for the remaining artifact at the dateline boundary.

@xhuang-jpl
xhuang-jpl merged commit bdf1f6f into isce-framework:develop Jun 29, 2026
8 checks passed
@hfattahi hfattahi added this to the R05.02.3 milestone Jun 30, 2026
Tyler-g-hudson pushed a commit that referenced this pull request Jun 30, 2026
* fix the tropo across the dateline

* address the comments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants