WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Commit e830cc9

Browse files
authored
Merge pull request #125 from GeoscienceAustralia/update/aus_cop_hub_orbits
Update/aus cop hub orbits
2 parents 5639612 + 0441f5c commit e830cc9

File tree

9 files changed

+520
-175
lines changed

9 files changed

+520
-175
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
This repository contains code for running SAR processing pipelines on the NCI and AWS. Currently, this codebase supports two pipelines for generating Sentinel-1 Normalised Radar Backscatter (NRB).
44

5-
* [isce3_rtc (Sentinel-1 IW) that can be run locally and on AWS](docs/pipelines/aws_isce3_rtc.md)
5+
* [isce3_rtc (Sentinel-1 IW) that can be run locally and on AWS](docs/pipelines/isce3_rtc.md)
66
* [pyroSAR-GAMMA (Sentinel-1 IW/EW) that can be run on the NCI](docs/pipelines/pyrosar_gamma.md)
77

88
For more information see [Pipelines](docs/pipelines/README.md) or the specific workflow docs for usage examples and running tests.

docs/pipelines/isce3_rtc.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ At runtime, the script [run_isce3_rtc_pipeline.sh](../../scripts/run_isce3_rtc_p
122122
--make_existing_products=false
123123
--skip_upload_to_s3=false
124124
--scene_data_source=("AUS_COP_HUB" "ASF" "CDSE") # order of preference
125-
--orbit_data_source=("ASF" "CDSE") # order of preference
125+
--orbit_data_source=("AUS_COP_HUB" "ASF" "CDSE") # order of preference
126126
--skip_validate_stac=false
127127
# Required inputs for linking RTC_S1_STATIC to RTC_S1
128128
# Assumes that a RTC_S1_STATIC products exist for all RTC_S1 bursts being processed
@@ -147,7 +147,7 @@ At runtime, the script [run_isce3_rtc_pipeline.sh](../../scripts/run_isce3_rtc_p
147147
- **WARNING** - Passing this flag will create duplicate files and overwrite existing metadata, which may affect downstream workflows.
148148
- `skip_upload_to_s3` -> Make the products, but skip uploading them to AWS S3.
149149
- `scene_data_source` -> Where to download the scene SLC file. Can be single string or a list of preferences separated by a space. Supported values are any of `AUS_COP_HUB`, `ASF` or `CDSE`. The default is (`AUS_COP_HUB` `ASF` `CDSE`).
150-
- `orbit_data_source` -> Where to download the orbit files. Can be single string or a list of preferences separated by a space. Can be any of `ASF` or `CDSE`. The default is (`ASF` `CDSE`).
150+
- `orbit_data_source` -> Where to download the orbit files. Can be single string or a list of preferences separated by a space. Can be any of `AUS_COP_HUB`, `ASF` or `CDSE`. The default is (`AUS_COP_HUB` `ASF` `CDSE`).
151151
- `skip_validate_stac` -> To skip validation of the created STAC doc within the code. If this is not set and the stac is invalid, products will not be uploaded. By default we want to validate the stac.
152152
- `link_static_layers` -> Flag to link RTC_S1_STATIC to RTC_S1
153153
- `linked_static_layers_s3_bucket` -> bucket where RTC_S1_STATIC stored

pixi.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,9 @@ test-isce3-rtc = "pytest tests/sar_pipeline/isce3_rtc -o log_cli=true --capture=
9696
test-isce3-rtc-full-docker-run = "pytest tests/sar_pipeline/isce3_rtc/test_full_docker_build_and_run.py -o log_cli=true --capture=tee-sys --log-cli-level=INFO -v -s"
9797
test-isce3-rtc-cli-make-rtc-opera-stac-and-upload-bursts = "pytest tests/sar_pipeline/isce3_rtc/test_cli_make_rtc_opera_stac_and_upload_bursts.py -o log_cli=true --capture=tee-sys --log-cli-level=INFO -v -s"
9898
# test queries from all providers (ASF, CDSE, AUS_COP_HUB). pygssearch conda environment is required for the AUS_COP_HUB test
99-
test-scene-data-source-queries="pixi run install-pygssearch-env && pytest tests/sar_pipeline/test_scenes.py -o log_cli=true --capture=tee-sys --log-cli-level=INFO -v -s"
99+
test-scene-data-source-queries="pixi run install-pygssearch-env && export PYGSSEARCH_CONDA_ENV='$(conda info --base)/envs/pygssearch-env' && pytest tests/sar_pipeline/test_scenes.py -o log_cli=true --capture=tee-sys --log-cli-level=INFO -v -s"
100100
# test downloads from all providers. pygssearch conda environment is required for the AUS_COP_HUB test
101-
test-isce3-rtc-downloads= "pixi run install-pygssearch-env && pytest tests/sar_pipeline/isce3_rtc/test_downloads.py -o log_cli=true --capture=tee-sys --log-cli-level=INFO -v -s"
101+
test-isce3-rtc-downloads= "pixi run install-pygssearch-env && export PYGSSEARCH_CONDA_ENV='$(conda info --base)/envs/pygssearch-env' && pytest tests/sar_pipeline/isce3_rtc/test_downloads.py -o log_cli=true --capture=tee-sys --log-cli-level=INFO -v -s"
102102
# nci specific tests that should be run locally on the nci
103103
test-nci-filesystem = "pytest tests/filesystem"
104104
lint = "black sar_pipeline"

sar_pipeline/pipelines/isce3_rtc/cli.py

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
NonSingleSceneResultError,
1616
)
1717
from sar_pipeline.preparation.downloads.orbits import (
18-
download_orbits,
18+
download_orbits_from_preference_list,
1919
VALID_ORBIT_DATA_SOURCES,
2020
)
2121
from sar_pipeline.pipelines.isce3_rtc.utils.burst_utils import (
@@ -347,6 +347,18 @@ def get_data_for_scene_and_make_run_config(
347347
all_scene_burst_info = get_burst_info_for_scene_from_cdse(scene)
348348
logger.info(f"{len(all_scene_burst_info)} burst ids found for scene from CDSE API")
349349

350+
# write the geometries to a geojson. Useful for debugging if needed
351+
if save_burst_geometries:
352+
_burst_id_list = all_scene_burst_info.keys()
353+
_burst_geoms_list = [
354+
all_scene_burst_info[b]["geometry"] for b in _burst_id_list
355+
]
356+
write_burst_geometries_to_geojson(
357+
_burst_id_list,
358+
_burst_geoms_list,
359+
out_folder / f"{scene}_burst_geoms.json",
360+
)
361+
350362
# Limit the bursts to be processed if a list has been provided
351363
if burst_id_list:
352364
logger.info(f"List of bursts to process provided")
@@ -420,24 +432,17 @@ def get_data_for_scene_and_make_run_config(
420432

421433
# # download the orbits
422434
logger.info(f"Downloading Orbits for scene : {scene}")
423-
ORBIT_PATH = download_orbits(
435+
ORBIT_PATH = download_orbits_from_preference_list(
424436
scene_safe_file=scene + ".SAFE",
425-
save_dir=orbit_folder,
426-
source=orbit_data_sources,
437+
download_folder=orbit_folder,
438+
orbit_data_source_preferences=orbit_data_sources,
427439
)
428440
logger.info(f"File downloaded to : {ORBIT_PATH}")
429441

430442
# get the shape of the area covering the bursts to be processed
431443
burst_geoms_to_process = [
432444
all_scene_burst_info[id_]["geometry"] for id_ in burst_id_list_to_process
433445
]
434-
# write the geometries to a geojson. Useful for debugging if needed
435-
if save_burst_geometries:
436-
write_burst_geometries_to_geojson(
437-
burst_id_list_to_process,
438-
burst_geoms_to_process,
439-
out_folder / f"{scene}_burst_geoms.json",
440-
)
441446

442447
# download the DEM
443448
dem_folder = download_folder / "dem" / dem_type

0 commit comments

Comments
 (0)