nasa-jpl / autoRIFT

A Python module of a fast and intelligent algorithm for finding the pixel displacement between two images
Apache License 2.0
218 stars 53 forks source link

Index out of bound error while running autoRIFT #31

Closed bjmarfito closed 3 years ago

bjmarfito commented 3 years ago

I've encountered an index out of bound error while running autoRIFT on the two ascending Sentinel-1 images. I've also did this to the two descending Sentinel-1 images though they've run successfully.

Below is the output of the error on the terminal.

(isce2expe) abscissa@ABSCISSA:/mnt/f/2020_Masbate/Sentinel-1/DInSAR/autoRIFT$ python testautoRIFT_ISCE.py -m ../20200815_20200821_asc_neworb/merged/reference.slc.full -s ../20200815_20200821_asc_neworb/merged/secondary.slc.full -g window_location.tif
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
2021-06-01 07:46:05,649 - root - DEBUG - Creating readonly ISCE mmap with
file = ../20200815_20200821_asc_neworb/merged/reference.slc.full
bands = 1
width = 24435
length = 8203
scheme = BIP
dtype = CFLOAT

2021-06-01 07:46:06,019 - root - DEBUG - Creating readonly ISCE mmap with
file = ../20200815_20200821_asc_neworb/merged/secondary.slc.full
bands = 1
width = 24435
length = 8203
scheme = BIP
dtype = CFLOAT

Traceback (most recent call last):
  File "testautoRIFT_ISCE.py", line 957, in <module>
    main()
  File "testautoRIFT_ISCE.py", line 387, in main
    generateAutoriftProduct(indir_m=inps.indir_m, indir_s=inps.indir_s, grid_location=inps.grid_location,
  File "testautoRIFT_ISCE.py", line 494, in generateAutoriftProduct
    Dx, Dy, InterpMask, ChipSizeX, ScaleChipSizeY, SearchLimitX, SearchLimitY, origSize, noDataMask = runAutorift(
  File "testautoRIFT_ISCE.py", line 201, in runAutorift
    if (I1[obj.yGrid[ii,jj]-1,obj.xGrid[ii,jj]-1]==0)|(I2[obj.yGrid[ii,jj]-1,obj.xGrid[ii,jj]-1]==0):
IndexError: index 12225 is out of bounds for axis 0 with size 8203
leiyangleon commented 3 years ago

@bjmarfito the Geogrid output "window_location.tif" is not right. From the error message, the azimuth index cannot be larger than 8203-1=8202, while 12225 is referred to here. You might want to check the Geogrid command you used and the Geogrid output "window_location.tif".