Skip to content

Commit

Permalink
Update algo parameters to point at new overrides (#205)
Browse files Browse the repository at this point in the history
  • Loading branch information
scottstanie authored Nov 29, 2024
1 parent 22e8134 commit c6609c6
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 18 deletions.
2 changes: 1 addition & 1 deletion configs/algorithm_parameters_historical.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# JSON file containing frame-specific algorithm parameters to override the defaults passed
# in the `algorithm_parameters.yaml`.
# Type: string | null.
algorithm_parameters_overrides_json: opera-disp-s1-algorithm-parameters-overrides-2024-10-14.json
algorithm_parameters_overrides_json: opera-disp-s1-algorithm-parameters-overrides-2024-11-26.json
ps_options:
# Amplitude dispersion threshold to consider a pixel a PS.
# Type: number.
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"18903": {
"unwrap_options": {
"unwrap_method": "phass",
"run_interpolation": false
}
},
"23210": {
"unwrap_options": {
"unwrap_method": "spurt"
}
},
"23211": {
"unwrap_options": {
"unwrap_method": "spurt"
}
},
"33038": {
"unwrap_options": {
"unwrap_method": "spurt"
}
},
"33039": {
"unwrap_options": {
"unwrap_method": "spurt"
}
}
}
1 change: 0 additions & 1 deletion src/disp_s1/_ps.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,6 @@ def run_combine(
mean = reader_mean[rows, cols][np.newaxis].filled(0)
dispersion = reader_dispersion[rows, cols][np.newaxis].filled(0)

# Fit a line to each pixel with weighted least squares
dispersions = np.vstack([compslc_dispersion, dispersion])

means = np.vstack([compslc_mean, mean])
Expand Down
2 changes: 1 addition & 1 deletion src/disp_s1/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ def create_displacement_products(
los_north_file: Path | None = None,
near_far_incidence_angles: tuple[float, float] = (30.0, 45.0),
water_mask: Path | None = None,
max_workers: int = 3,
max_workers: int = 4,
) -> None:
"""Run parallel processing for all interferograms.
Expand Down
8 changes: 5 additions & 3 deletions src/disp_s1/plotting.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ def plot_product(
filename: Filename,
downsample=3,
use_recommended_mask: bool = True,
figsize: tuple[float, float] = (9, 6),
figsize: tuple[float, float] = (10, 10),
disp_cmap: str = DEFAULT_CMAP,
disp_limits: tuple[float, float] = (-0.20, 0.20),
filtered_disp_limits: tuple[float, float] = (-0.05, 0.05),
Expand Down Expand Up @@ -97,10 +97,12 @@ def plot_product(
bad_mask = ds["recommended_mask"][::downsample, ::downsample] == 0

fig, axes = plt.subplots(
ncols=5, nrows=2, sharex=True, sharey=True, figsize=figsize
ncols=4, nrows=3, sharex=True, sharey=True, figsize=figsize
)

for ax, dset_name, cmap, vm in zip(axes.ravel(), dsets, cmaps, vms, strict=True):
for ax, dset_name, cmap, vm in zip(
axes.ravel()[: len(dsets)], dsets, cmaps, vms, strict=True
):
dset = ds[dset_name][::downsample, ::downsample]
if not use_recommended_mask:
bad_mask = dset == 0
Expand Down

0 comments on commit c6609c6

Please sign in to comment.