Skip to content

Error in 'verifyDEM' of stripmapApp.py for RADARSAT-2 #934

@S-Nari

Description

@S-Nari

Hello.
I am a beginner for analyzing Radarsat-2 data using ISCE2. I would like to know the cause of the error in stripmapApp.py.

After making the modifications to Radarsat2.py, as suggested in @fdelgadodelapuente (#654), I ran the following command ;

$ stripmapApp.py stripmapApp.xml --start=startup --end=verifyDEM

and the, got the following error;

(isce2_env2) $ stripmapApp.py stripmapApp.xml --start=startup --end=verifyDEM
This is the Open Source version of ISCE.
Some of the workflows depend on a separate licensed package.
To obtain the licensed package, please make a request for ISCE
through the website: https://download.jpl.nasa.gov/ops/request/index.cfm.
Alternatively, if you are a member, or can become a member of WinSAR
you may be able to obtain access to a version of the licensed sofware at
https://winsar.unavco.org/software/isce
2025-03-05 04:58:34,844 - isce.insar - INFO - ISCE VERSION = 2.5.3, RELEASE_SVN_REVISION = ,RELEASE_DATE = 20210823, CURRENT_SVN_REVISION = 
ISCE VERSION = 2.5.3, RELEASE_SVN_REVISION = ,RELEASE_DATE = 20210823, CURRENT_SVN_REVISION = 
2025-03-05 04:58:34,845 - root - INFO - reference sensor object provided explicitly
2025-03-05 04:58:34,861 - root - INFO - secondary sensor object provided explicitly
do_unwrap  True
Step processing
Running step startup

    Insar Application:
    Implements InSAR processing flow for a pair of scenes from
    sensor raw data to geocoded, flattened interferograms.
    
The currently supported sensors are:  ['ALOS', 'ALOS2', 'ALOS_SLC', 'COSMO_SKYMED', 'COSMO_SKYMED_SLC', 'ENVISAT', 'ENVISAT_SLC', 'ERS', 'ERS_ENVISAT', 'ERS_ENVISAT_SLC', 'ERS_SLC', 'ICEYE_SLC', 'KOMPSAT5', 'RADARSAT1', 'RADARSAT2', 'RISAT1', 'RISAT1_SLC', 'ROI_PAC', 'SAOCOM_SLC', 'SENTINEL1', 'SICD_RGZERO', 'TERRASARX', 'UAVSAR_HDF5_SLC', 'UAVSAR_POLSAR', 'UAVSAR_RPI', 'UAVSAR_STACK']
Dumping the application's pickle object _insar to file  PICKLE/startup
The remaining steps are (in order):  ['preprocess', 'cropraw', 'formslc', 'cropslc', 'verifyDEM', 'topo', 'geo2rdr', 'coarse_resample', 'misregistration', 'refined_resample', 'dense_offsets', 'rubber_sheet_range', 'rubber_sheet_azimuth', 'fine_resample', 'split_range_spectrum', 'sub_band_resample', 'interferogram', 'sub_band_interferogram', 'filter', 'filter_low_band', 'filter_high_band', 'unwrap', 'unwrap_low_band', 'unwrap_high_band', 'ionosphere', 'geocode', 'geocodeoffsets', 'endup']
Running step preprocess
Reference data is in SLC format. Adding _slc to output name.
2025-03-05 04:58:34,913 - isce.make_raw - INFO - Extracting image
effective PRF 2680.285889, original PRF 1340.142944
Successfully read state vectors from product XML
Warning 1: /home/ksvo/sar_data/NiigataYakeyama/Radarsat2/Dsc/RS2_XF0W2_20160523_479696_HH_SLC/RS2_OK158149_PK1430418_DK1395103_XF0W2_20160523_205124_HH_SLC/imagery_HH.tif: TIFFReadDirectory:Sum of Photometric type-related color channels and ExtraSamples doesn't match SamplesPerPixel. Defining non-color channels as ExtraSamples.
Horizontally Flipping data
Using default doppler values for sensor: NoneType
Doppler Fit:  [-2.21193837e+02  1.44132889e-11  2.99677422e-23]
2025-03-05 04:58:58,846 - isce.make_raw - INFO - Calculating Spacecraft Velocity
Orbit.calculateHeight: self.position =  [-4674616.15540095, 3436134.919670036, 4207304.730782307]
Orbit.calculateHeight: ellipsoid.a, ellipsoid.e2 =  6378137.0 0.0066943799901
Orbit.calculateHeight: self.position =  [-4697934.427674143, 3475136.371968372, 4149061.5272262995]
Orbit.calculateHeight: ellipsoid.a, ellipsoid.e2 =  6378137.0 0.0066943799901
2025-03-05 04:58:58,849 - isce.make_raw - INFO - Calculating Squint Angle
Secondary data is in SLC format. Adding _slc to output name.
2025-03-05 04:58:58,861 - isce.make_raw - INFO - Extracting image
effective PRF 2680.285889, original PRF 1340.142944
Successfully read state vectors from product XML
Warning 1: /home/ksvo/sar_data/NiigataYakeyama/Radarsat2/Dsc/RS2_XF0W2_20160710_490538_HH_SLC/RS2_OK158149_PK1430420_DK1395105_XF0W2_20160710_205122_HH_SLC/imagery_HH.tif: TIFFReadDirectory:Sum of Photometric type-related color channels and ExtraSamples doesn't match SamplesPerPixel. Defining non-color channels as ExtraSamples.
Horizontally Flipping data
Using default doppler values for sensor: NoneType
Doppler Fit:  [-2.13081066e+02  1.51228515e-11 -2.99677422e-23]
2025-03-05 04:59:23,529 - isce.make_raw - INFO - Calculating Spacecraft Velocity
Orbit.calculateHeight: self.position =  [-4674754.618799733, 3435999.903227564, 4207305.723034464]
Orbit.calculateHeight: ellipsoid.a, ellipsoid.e2 =  6378137.0 0.0066943799901
Orbit.calculateHeight: self.position =  [-4698082.600321036, 3475016.724930882, 4149039.417623562]
Orbit.calculateHeight: ellipsoid.a, ellipsoid.e2 =  6378137.0 0.0066943799901
2025-03-05 04:59:23,532 - isce.make_raw - INFO - Calculating Squint Angle
2025-03-05 04:59:23,537 - isce.insar.runPreprocessor - INFO - 
####################################################################################################
    runPreprocessor
----------------------------------------------------------------------------------------------------
reference.chirp_slope = 1202400043640.192
reference.frame.aux_file = None
reference.frame.doppler_vs_pixel = [-221.19383721988413, 1.4413288876243816e-11, 2.996774224868703e-23]
reference.frame.family = frame
reference.frame.far_range = 985786.2229004826
reference.frame.frame_number = None
reference.frame.name = frame_name
reference.frame.number_of_lines = 52459
reference.frame.number_of_samples = 26784
reference.frame.number_range_bins = 26784
reference.frame.orbit_number = None
reference.frame.pass_direction = Descending
reference.frame.polarization = HH
reference.frame.processing_facility = None
reference.frame.processing_level = None
reference.frame.processing_system = None
reference.frame.processing_system_version = CAPPS SAR 1.4
reference.frame.schheight = None
reference.frame.schvelocity = None
reference.frame.sensing_mid = 2016-05-23 20:51:34.729461
reference.frame.sensing_start = 2016-05-23 20:51:24.943565
reference.frame.sensing_stop = 2016-05-23 20:51:44.515358
reference.frame.squint_angle = -0.001649913977760065
reference.frame.starting_range = 914480.3129590126
reference.frame.track_number = None
reference.iBias = None
reference.instrument.azimuth_pixel_size = None
reference.instrument.caltone_location = None
reference.instrument.chirp_slope = 1202400043640.192
reference.instrument.family = radar
reference.instrument.incidence_angle = 35.218239749999995
reference.instrument.inphase_bias = None
reference.instrument.iq_flip = None
reference.instrument.name = radar_name
reference.instrument.prf = 2680.285888671876
reference.instrument.pulse_lenght = 4.159703826904297e-05
reference.instrument.quadrature_bias = None
reference.instrument.radar_frequency = 5404999242.769673
reference.instrument.radar_wavelength = 0.055465772432999993
reference.instrument.range_first_sample = None
reference.instrument.range_pixel_size = 2.66235709
reference.instrument.range_pulse_duration = None
reference.instrument.range_sampling_rate = 56302075.166032664
reference.lookSide = -1
reference.orbit.family = orbit
reference.orbit.max_time = 2016-05-23 20:51:44.515358
reference.orbit.min_time = 2016-05-23 20:51:24.943565
reference.orbit.name = orbit_name
reference.orbit.orbit_quality = 
reference.orbit.orbit_reference_frame = 
reference.orbit.orbit_source = Header: 44065_DEF.ORB
reference.platform.antenna_length = 15.0
reference.platform.family = platform
reference.platform.mission = RADARSAT-2
reference.platform.name = platform_name
reference.platform.pointing_direction = -1
reference.platform.spacecraft_name = None
reference.prf = 2680.285888671876
reference.pri = 0.000373094528545056
reference.pulse_length = 4.159703826904297e-05
reference.qBias = None
reference.range_sampling_rate = 56302075.166032664
reference.sensor.family = radarsat2
reference.sensor.name = reference
reference.sensor.orbitdirectory = None
reference.sensor.orbitfile = None
reference.sensor.output = 20160523_slc/20160523.slc
reference.sensor.tiff = /home/ksvo/sar_data/NiigataYakeyama/Radarsat2/Dsc/RS2_XF0W2_20160523_479696_HH_SLC/RS2_OK158149_PK1430418_DK1395103_XF0W2_20160523_205124_HH_SLC/imagery_HH.tif
reference.sensor.xml = /home/ksvo/sar_data/NiigataYakeyama/Radarsat2/Dsc/RS2_XF0W2_20160523_479696_HH_SLC/RS2_OK158149_PK1430418_DK1395103_XF0W2_20160523_205124_HH_SLC/product.xml
reference.wavelength = 0.055465772432999993
reference.width = 26784
secondary.chirp_slope = 1202400043640.192
secondary.frame.aux_file = None
secondary.frame.doppler_vs_pixel = [-213.08106628987832, 1.5122851540854473e-11, -2.996774224868703e-23]
secondary.frame.family = frame
secondary.frame.far_range = 985786.2229004826
secondary.frame.frame_number = None
secondary.frame.name = frame_name
secondary.frame.number_of_lines = 52480
secondary.frame.number_of_samples = 26784
secondary.frame.number_range_bins = 26784
secondary.frame.orbit_number = None
secondary.frame.pass_direction = Descending
secondary.frame.polarization = HH
secondary.frame.processing_facility = None
secondary.frame.processing_level = None
secondary.frame.processing_system = None
secondary.frame.processing_system_version = CAPPS SAR 1.4
secondary.frame.schheight = None
secondary.frame.schvelocity = None
secondary.frame.sensing_mid = 2016-07-10 20:51:32.238046
secondary.frame.sensing_start = 2016-07-10 20:51:22.448232
secondary.frame.sensing_stop = 2016-07-10 20:51:42.027860
secondary.frame.squint_angle = -0.001589566513329198
secondary.frame.starting_range = 914480.3129590126
secondary.frame.track_number = None
secondary.iBias = None
secondary.instrument.azimuth_pixel_size = None
secondary.instrument.caltone_location = None
secondary.instrument.chirp_slope = 1202400043640.192
secondary.instrument.family = radar
secondary.instrument.incidence_angle = 35.21490005
secondary.instrument.inphase_bias = None
secondary.instrument.iq_flip = None
secondary.instrument.name = radar_name
secondary.instrument.prf = 2680.285888671876
secondary.instrument.pulse_lenght = 4.159703826904297e-05
secondary.instrument.quadrature_bias = None
secondary.instrument.radar_frequency = 5404999242.769673
secondary.instrument.radar_wavelength = 0.055465772432999993
secondary.instrument.range_first_sample = None
secondary.instrument.range_pixel_size = 2.66235709
secondary.instrument.range_pulse_duration = None
secondary.instrument.range_sampling_rate = 56302075.166032664
secondary.lookSide = -1
secondary.orbit.family = orbit
secondary.orbit.max_time = 2016-07-10 20:51:42.027860
secondary.orbit.min_time = 2016-07-10 20:51:22.448232
secondary.orbit.name = orbit_name
secondary.orbit.orbit_quality = 
secondary.orbit.orbit_reference_frame = 
secondary.orbit.orbit_source = Header: 44751_DEF.ORB
secondary.platform.antenna_length = 15.0
secondary.platform.family = platform
secondary.platform.mission = RADARSAT-2
secondary.platform.name = platform_name
secondary.platform.pointing_direction = -1
secondary.platform.spacecraft_name = None
secondary.prf = 2680.285888671876
secondary.pri = 0.000373094528545056
secondary.pulse_length = 4.159703826904297e-05
secondary.qBias = None
secondary.range_sampling_rate = 56302075.166032664
secondary.sensor.family = radarsat2
secondary.sensor.name = secondary
secondary.sensor.orbitdirectory = None
secondary.sensor.orbitfile = None
secondary.sensor.output = 20160710_slc/20160710.slc
secondary.sensor.tiff = /home/ksvo/sar_data/NiigataYakeyama/Radarsat2/Dsc/RS2_XF0W2_20160710_490538_HH_SLC/RS2_OK158149_PK1430420_DK1395105_XF0W2_20160710_205122_HH_SLC/imagery_HH.tif
secondary.sensor.xml = /home/ksvo/sar_data/NiigataYakeyama/Radarsat2/Dsc/RS2_XF0W2_20160710_490538_HH_SLC/RS2_OK158149_PK1430420_DK1395105_XF0W2_20160710_205122_HH_SLC/product.xml
secondary.wavelength = 0.055465772432999993
secondary.width = 26784
####################################################################################################
Dumping the application's pickle object _insar to file  PICKLE/preprocess
The remaining steps are (in order):  ['cropraw', 'formslc', 'cropslc', 'verifyDEM', 'topo', 'geo2rdr', 'coarse_resample', 'misregistration', 'refined_resample', 'dense_offsets', 'rubber_sheet_range', 'rubber_sheet_azimuth', 'fine_resample', 'split_range_spectrum', 'sub_band_resample', 'interferogram', 'sub_band_interferogram', 'filter', 'filter_low_band', 'filter_high_band', 'unwrap', 'unwrap_low_band', 'unwrap_high_band', 'ionosphere', 'geocode', 'geocodeoffsets', 'endup']
Running step cropraw
No region of interesting provided, skipping cropping of raw data
Dumping the application's pickle object _insar to file  PICKLE/cropraw
The remaining steps are (in order):  ['formslc', 'cropslc', 'verifyDEM', 'topo', 'geo2rdr', 'coarse_resample', 'misregistration', 'refined_resample', 'dense_offsets', 'rubber_sheet_range', 'rubber_sheet_azimuth', 'fine_resample', 'split_range_spectrum', 'sub_band_resample', 'interferogram', 'sub_band_interferogram', 'filter', 'filter_low_band', 'filter_high_band', 'unwrap', 'unwrap_low_band', 'unwrap_high_band', 'ionosphere', 'geocode', 'geocodeoffsets', 'endup']
Running step formslc
Reference product was unpacked as an SLC. Skipping focusing ....
Secondary product was unpacked as an SLC. Skipping focusing ....
Dumping the application's pickle object _insar to file  PICKLE/formslc
The remaining steps are (in order):  ['cropslc', 'verifyDEM', 'topo', 'geo2rdr', 'coarse_resample', 'misregistration', 'refined_resample', 'dense_offsets', 'rubber_sheet_range', 'rubber_sheet_azimuth', 'fine_resample', 'split_range_spectrum', 'sub_band_resample', 'interferogram', 'sub_band_interferogram', 'filter', 'filter_low_band', 'filter_high_band', 'unwrap', 'unwrap_low_band', 'unwrap_high_band', 'ionosphere', 'geocode', 'geocodeoffsets', 'endup']
Running step cropslc
No region of interesting provided, skipping cropping of slc data
Dumping the application's pickle object _insar to file  PICKLE/cropslc
The remaining steps are (in order):  ['verifyDEM', 'topo', 'geo2rdr', 'coarse_resample', 'misregistration', 'refined_resample', 'dense_offsets', 'rubber_sheet_range', 'rubber_sheet_azimuth', 'fine_resample', 'split_range_spectrum', 'sub_band_resample', 'interferogram', 'sub_band_interferogram', 'filter', 'filter_low_band', 'filter_high_band', 'unwrap', 'unwrap_low_band', 'unwrap_high_band', 'ionosphere', 'geocode', 'geocodeoffsets', 'endup']
Running step verifyDEM
Polynomial Order: 0 - by - 0 
0	
2025-03-05 04:59:23,620 - isce.Orbit - ERROR - Unable to select 2 state vectors before and after chosen time 2016-05-23 20:51:44.515358
Traceback (most recent call last):
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/applications/stripmapApp.py", line 1002, in <module>
    status = insar.run()
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/iscesys/Component/Application.py", line 142, in run
    exitStatus = self._processSteps()
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/iscesys/Component/Application.py", line 405, in _processSteps
    result = func(*pargs, **kwargs)
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/isceobj/StripmapProc/Factories.py", line 46, in __call__
    return self.method(self.other, *args, **kwargs)
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/isceobj/StripmapProc/runVerifyDEM.py", line 122, in runVerifyDEM
    mbox = getBbox(reference, geom=self._insar.referenceGeometrySystem,
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/isceobj/StripmapProc/runVerifyDEM.py", line 58, in getBbox
    pt = frame.orbit.rdr2geo(taz, rng, doppler=doppler, height=z,
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/isceobj/Orbit/Orbit.py", line 847, in rdr2geo
    hdg = self.getENUHeading(time=aztime)
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/isceobj/Orbit/Orbit.py", line 823, in getENUHeading
    llh1 = refElp.xyz_to_llh(vec1.getPosition())
AttributeError: 'NoneType' object has no attribute 'getPosition'

One thing I am concerned about is that 'orbit name' and 'orbit file' is set to be 'none'. So, I have also tried running it with the 'orbitdirectory' set to where 'schemas/rs2prod_orbitAndAttitude.xds' is, but I am getting the following error, which I have not been able to resolve.

##
Running` step preprocess
Reference data is in SLC format. Adding _slc to output name.
2025-03-05 04:12:49,456 - isce.make_raw - INFO - Extracting image
effective PRF 2680.285889, original PRF 1340.142944
Successfully read 0 state vectors from /home/ksvo/sar_data/NiigataYakeyama/Radarsat2/Dsc/RS2_XF0W2_20150926_424137_HH_SLC/RS2_OK159446_PK1454685_DK1427080_XF0W2_20150926_205136_HH_SLC/schemas/rs2prod_orbitAndAttitude.xsd
Warning 1: /home/ksvo/sar_data/NiigataYakeyama/Radarsat2/Dsc/RS2_XF0W2_20150926_424137_HH_SLC/RS2_OK159446_PK1454685_DK1427080_XF0W2_20150926_205136_HH_SLC/imagery_HH.tif: TIFFReadDirectory:Sum of Photometric type-related color channels and ExtraSamples doesn't match SamplesPerPixel. Defining non-color channels as ExtraSamples.
Horizontally Flipping data
Using default doppler values for sensor: NoneType
Doppler Fit:  [-3.54820006e+02  7.88478078e-12 -3.59666619e-22]
2025-03-05 04:13:12,750 - isce.make_raw - INFO - Calculating Spacecraft Velocity
Traceback (most recent call last):
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/applications/stripmapApp.py", line 1002, in <module>
    status = insar.run()
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/iscesys/Component/Application.py", line 142, in run
    exitStatus = self._processSteps()
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/iscesys/Component/Application.py", line 405, in _processSteps
    result = func(*pargs, **kwargs)
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/isceobj/StripmapProc/Factories.py", line 46, in __call__
    return self.method(self.other, *args, **kwargs)
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/isceobj/StripmapProc/runPreprocessor.py", line 89, in runPreprocessor
    reference = make_raw(sensor, referencedop)
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/isceobj/StripmapProc/runPreprocessor.py", line 206, in make_raw
    objMakeRaw(sensor=sensor, doppler=doppler)
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/iscesys/Component/Component.py", line 179, in __call__
    return getattr(self, self.__class__.__name__.lower())(*args)
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/applications/make_raw.py", line 330, in make_raw
    self.calculateHeightDt()
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/applications/make_raw.py", line 157, in calculateHeightDt
    sv0 = orbit.interpolate(startTime)
  File "/home/ksvo/miniconda3/envs/isce2_env2/lib/python3.8/site-packages/isce/components/isceobj/Orbit/Orbit.py", line 400, in interpolate
    raise ValueError("Time stamp (%s) falls outside of the interpolation interval [%s:%s]"
ValueError: Time stamp (2015-09-26 20:51:36.667023) falls outside of the interpolation interval [9999-12-31 00:00:00:0001-01-01 00:00:00]
##

I use ISCE ver. 2.5.3.
The contents of the input XML files are as follows

stripmapApp.xml
Image

reference_RSAT2.xml
Image

I am not sure how to describe these XML files, so if you can point out any mistakes, I would greatly appreciate it.

Thank you in advance for your help.
Best regards,

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions