012_023790_IW1 #3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Extract bursts from SLCs | |
name: InSAR_Pair | |
run-name: ${{ inputs.BurstID }} | |
on: | |
workflow_dispatch: | |
inputs: | |
reference: | |
type: string | |
required: true | |
description: Reference SLC | |
default: S1A_IW_SLC__1SDV_20230621T121402_20230621T121429_049084_05E705_BAD8 | |
secondary: | |
type: string | |
required: true | |
description: Secondary SLC | |
default: S1A_IW_SLC__1SDV_20230703T121403_20230703T121430_049259_05EC58_F9AB | |
burstId: | |
type: string | |
required: true | |
description: Secondary SLC | |
default: 012_023790_IW1 | |
polarization: | |
type: choice | |
required: true | |
description: Polarization | |
default: 'VV' | |
options: ['VV', 'VH', 'HH'] | |
looks: | |
type: choice | |
required: true | |
description: Range x Azimuth Looks | |
default: 20x4 | |
options: | |
- 20x4 | |
- 10x2 | |
- 5x1 | |
jobname: | |
type: string | |
required: true | |
description: Shorthand jobname (e.g. 20230621_20230703) | |
default: hyp3-isce2 | |
# Must duplicate inputs for workflow_call (https://github.com/orgs/community/discussions/39357) | |
workflow_call: | |
inputs: | |
reference: | |
type: string | |
required: true | |
secondary: | |
type: string | |
required: true | |
burstId: | |
type: string | |
required: true | |
polarization: | |
type: string | |
required: true | |
year: | |
type: string | |
required: true | |
looks: | |
type: string | |
required: true | |
jobname: | |
type: string | |
required: false | |
jobs: | |
hyp3-isce2: | |
name: ${{ inputs.jobname }} | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
shell: bash -el {0} | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
with: | |
repository: 'relativeorbit/hyp3-isce2' | |
ref: 'backprocess' | |
- name: Install Conda environment with Micromamba | |
uses: mamba-org/setup-micromamba@v1 | |
with: | |
cache-environment: true | |
environment-file: environment.yml | |
# TODO: lock in specific version once workflow is stable | |
- name: Development install | |
run: pip install -e . | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
aws-region: us-west-2 | |
- name: Get Bucket Prefix | |
env: | |
REF: ${{ inputs.reference }} | |
SEC: ${{ inputs.secondary }} | |
run: | | |
PREFIX=${REF:17:25}_${SEC:17:25} | |
echo "PREFIX=${PREFIX}" >> $GITHUB_ENV | |
- name: Run Hyp3-ISCE2 | |
env: | |
EARTHDATA_USERNAME: ${{ secrets.EARTHDATA_USERNAME }} | |
EARTHDATA_PASSWORD: ${{ secrets.EARTHDATA_PASSWORD}} | |
ESA_USERNAME: ${{ secrets.ESA_USERNAME }} | |
ESA_PASSWORD: ${{ secrets.ESA_PASSWORD}} | |
run: | | |
python -m hyp3_isce2 ++process insar_tops_fufiters \ | |
${{ inputs.reference }} \ | |
${{ inputs.secondary }} \ | |
--burstId ${{ inputs.burstId }} \ | |
--polarization ${{ inputs.polarization }} \ | |
--looks ${{ inputs.looks }} \ | |
--apply-water-mask False | |
- name: Create STAC Metadata | |
run: | | |
python scripts/hyp3isce2stac.py | |
- name: Upload to AWS S3 | |
run: | | |
OUTDIR=`ls -d S1_*` | |
aws s3 sync $OUTDIR s3://fufiters/backprocess/$PREFIX/$OUTDIR | |
# - name: Upload to GitHub Artifact | |
# uses: actions/upload-artifact@v4 | |
# with: | |
# name: ${{ env.PREFIX }} | |
# path: S1*.zip |