insarlab / MintPy

Miami InSAR time-series software in Python
https://mintpy.readthedocs.io
Other
575 stars 252 forks source link

prep_aria is looking for information about IW2 #412

Closed EJFielding closed 4 years ago

EJFielding commented 4 years ago

Description of the problem

The load_data step fails with data prepared with recent version of ariaTSsetup.py. It seems to be looking for metadata about subswath IW2 that is not in the sensor metadata.

Full script that generated the error

ariaDownload.py --bbox "26 28 83 86" --track 19 -o download
# unit of minimumOverlap are km^2
ariaTSsetup.py -f 'products/*.nc' --bbox "26 28 83 86" -d download --mask download -w bbox26_28_ml3 -mo 42000 -ml 3 -v
cd bbox26_28_ml3/MintPy
smallbaselineApp.py NepalSenD019.txt --dostep=load_data

Full error message

Using default MintPy Path: /home/fielding/tools/MintPy

_________________________________________________
 ____    ____   _            _   _______
|_   \  /   _| (_)          / |_|_   __ \
  |   \/   |   __   _ .--. `| |-' | |__) |_   __
  | |\  /| |  [  | [ `.-. | | |   |  ___/[ \ [  ]
 _| |_\/_| |_  | |  | | | | | |, _| |_    \ '/ /
|_____||_____|[___][___||__]\__/|_____| [\_:  /
                                         \__.'

   Miami InSAR Time-series software in Python
          MintPy v1.2.3-5, 2020-07-20
_________________________________________________

--RUN-at-2020-07-23 21:59:12.254342--
Current directory: /u/sar-r0/fielding/Nepal/S1-ARIA/D019/bbox26_28_ml3/MintPy
Run routine processing with smallbaselineApp.py on steps: ['load_data', 'modify_network', 'reference_point', 'quick_overview', 'correct_unwrap_error', 'invert_network', 'correct_LOD', 'correct_troposphere', 'deramp', 'correct_topography', 'residual_RMS', 'reference_date', 'velocity', 'geocode', 'google_earth', 'hdfeos5']
Remaining steps: ['modify_network', 'reference_point', 'quick_overview', 'correct_unwrap_error', 'invert_network', 'correct_LOD', 'correct_troposphere', 'deramp', 'correct_topography', 'residual_RMS', 'reference_date', 'velocity', 'geocode', 'google_earth', 'hdfeos5']
--------------------------------------------------
Project name: NepalSenD019
Go to work directory: /u/sar-r0/fielding/Nepal/S1-ARIA/D019/bbox26_28_ml3/MintPy
copy default template file /home/fielding/tools/MintPy/mintpy/defaults/smallbaselineApp.cfg to work directory
read custom template file: /u/sar-r0/fielding/Nepal/S1-ARIA/D019/bbox26_28_ml3/MintPy/NepalSenD019.txt
update default template based on input custom template
    mintpy.load.processor: auto --> aria
    mintpy.load.unwFile: auto --> ../stack/unwrapStack.vrt
    mintpy.load.corFile: auto --> ../stack/cohStack.vrt
    mintpy.load.connCompFile: auto --> ../stack/connCompStack.vrt
    mintpy.load.demFile: auto --> ../DEM/SRTM_3arcsec.dem
    mintpy.load.incAngleFile: auto --> ../incidenceAngle/20160517_20150710.vrt
    mintpy.load.azAngleFile: auto --> ../azimuthAngle/20160517_20150710.vrt
    mintpy.load.waterMaskFile: auto --> ../mask/watermask.msk
    mintpy.network.coherenceBased: auto --> no
    mintpy.network.keepMinSpanTree: auto --> yes
    mintpy.networkInversion.weightFunc: auto --> no
    mintpy.troposphericDelay.method: auto --> no
    mintpy.deramp: auto --> no
    mintpy.topographicResidual: auto --> no
copy NepalSenD019.txt to inputs directory for backup.
copy smallbaselineApp.cfg to inputs directory for backup.
copy NepalSenD019.txt to pic directory for backup.
copy smallbaselineApp.cfg to pic directory for backup.
read default template file: /u/sar-r0/fielding/Nepal/S1-ARIA/D019/bbox26_28_ml3/MintPy/smallbaselineApp.cfg
copy /home/fielding/tools/MintPy/mintpy/../sh/plot_smallbaselineApp.sh to work directory: /u/sar-r0/fielding/Nepal/S1-ARIA/D019/bbox26_28_ml3/MintPy

******************** step - load_data ********************
read options from template file: smallbaselineApp.cfg
update mode: ON
extract metadata from ../stack/unwrapStack.vrt
Traceback (most recent call last):
  File "/home/fielding/tools/MintPy/mintpy/smallbaselineApp.py", line 1116, in <module>
    main()
  File "/home/fielding/tools/MintPy/mintpy/smallbaselineApp.py", line 1106, in main
    app.run(steps=inps.runSteps, plot=inps.plot)
  File "/home/fielding/tools/MintPy/mintpy/smallbaselineApp.py", line 1035, in run
    self.run_load_data(sname)
  File "/home/fielding/tools/MintPy/mintpy/smallbaselineApp.py", line 349, in run_load_data
    prep_aria.main(iargs)
  File "/home/fielding/tools/MintPy/mintpy/prep_aria.py", line 442, in main
    metadata = extract_metadata(inps.unwFile)
  File "/home/fielding/tools/MintPy/mintpy/prep_aria.py", line 261, in extract_metadata
    rgfact = sen_dict['IW2']['range_resolution'] / sen_dict['range_pixel_size']
KeyError: 'range_resolution'

System information

---------interferogram datasets:

mintpy.load.unwFile = ../stack/unwrapStack.vrt mintpy.load.corFile = ../stack/cohStack.vrt mintpy.load.connCompFile = ../stack/connCompStack.vrt

---------geometry datasets:

mintpy.load.demFile = ../DEM/SRTM_3arcsec.dem mintpy.load.incAngleFile = ../incidenceAngle/20160517_20150710.vrt mintpy.load.azAngleFile = ../azimuthAngle/20160517_20150710.vrt mintpy.load.waterMaskFile = ../mask/watermask.msk

mintpy.reference.yx = 490,630

mintpy.network.coherenceBased = no mintpy.networkInversion.weightFunc = no mintpy.deramp = no #[no / linear / quadratic], auto for no - no ramp will be removed mintpy.topographicResidual = no #[yes / no], auto for yes

network modification

mintpy.network.excludeDate = 20160107 #[20080520,20090817 / no], auto for no

mintpy.network.excludeIfgIndex = 25, 30, 34, 40, 46, 52, 56, 57, 61, 62, 67, 70, 74, 80

mintpy.network.keepMinSpanTree = yes mintpy.network.tempBaseMax = auto #[1-inf, no], auto for no, maximum temporal baseline in days mintpy.network.perpBaseMax = auto #[1-inf, no], auto for no, maximum perpendicular spatial baseline in meter mintpy.network.startDate = auto #[20090101 / no], auto for no mintpy.network.endDate = auto #[20110101 / no], auto for no

do not modify

mintpy.troposphericDelay.method = no

yunjunz commented 4 years ago

Hi @EJFielding, this issue is reported here https://github.com/insarlab/MintPy/issues/408 also and had been fixed yesterday!

EJFielding commented 4 years ago

Yes, seems very similar error, but I did a git pull and full reinstall today.

@yunjunz I see now that you changed the main branch to be named main instead of master. I missed that change. Is there some way to warn people that the master branch they may have installed before is not being updated?

git pull origin main solved my problem.

yunjunz commented 4 years ago

I see. Deleting the master branch seems to be the only way. Then git pull will return the following warning:

Your configuration specifies to merge with the ref 'refs/heads/master'
from the remote, but no such ref was fetched.

I will go ahead and do it since everything is backed up in the new main branch and put an announcement in the google forum. Thank you for the suggestion @EJFielding.