Describe the bug
When importing coregistered burst SLC data processed by GAMMA via miaplpyAPP miaplpyAPP.cfg --dostep load_data, the slcStack.h5 file is generated successfully with correct dimensions. However, the program throws a dimension broadcast error while creating geometryRadar.h5, failing to generate geometry files for subsequent InSAR processing.
The core error is ValueError: operands could not be broadcast together with shapes (2720,2699) (2720,10797) during incidence angle calculation.
My Operation Workflow
- Process Sentinel-1 burst SLC data and complete coregistration using GAMMA software;
- Prepare geometry input files for Miaplpy: Directly rename the GAMMA-generated lookup table file to*.utc_to_rdc (I am not sure if this operation is correct, which is the core confusion point);
- Execute data loading step: miaplpyAPP miaplpyAPP.cfg --dostep load_data;
- The slcStack.h5 file is written normally, but geometryRadar.h5 generation fails with dimension mismatch error.
Key Questions & Confusion
- File usage correctness: Is it correct to directly rename GAMMA-generated lookup table file to *.utc_to_rdc for Miaplpy geometry input?
- Dimension mismatch root cause: The slcStack.h5 dimension is fixed as (45, 2692, 2720), but the incidence angle calculation shows abnormal dimensions (2720,2699) and (2720,10797). Is this caused by incorrect lookup table/DEM file?
- GAMMA file import specification: Is there an official sample file and detailed specification for importing GAMMA-processed burst SLC data into Miaplpy? Including standard naming rules and file preparation steps for geometry files (utc_to_rdc, rdc.dem, etc.).
Error Logs
searching geometry files info
input data files:
height : ../prep_test/geometry/sim_20241006.rdc.dem
create HDF5 file /mnt/f/DHZ/rawdata/SLC/burst/RSLC/slc/miaplpy/inputs/slcStack.h5 with a mode
create dataset /slc of <class 'numpy.complex64'> in size of (45, 2692, 2720) with compression = None
create dataset /date of <class 'numpy.bytes_'> in size of (45, 1)
create dataset /bperp of <class 'numpy.float32'> in size of (45,)
update LENGTH, WIDTH, Y/XMAX
update/add SUBSET_XMIN/YMIN/XMAX/YMAX: 0/0/2720/2692
update STARTING_RANGE
Finished writing to /mnt/f/DHZ/rawdata/SLC/burst/RSLC/slc/miaplpy/inputs/slcStack.h5
create HDF5 file /mnt/f/DHZ/rawdata/SLC/burst/RSLC/slc/miaplpy/inputs/geometryRadar.h5 with a mode
create dataset /height of <class 'numpy.float32'> in size of (2692, 2720) with compression = lzf
Traceback (most recent call last):
File "/home/adm_insar/miniconda3/envs/mintpy_env/bin/load_slc_geometry.py", line 6, in
sys.exit(main())
File "/home/adm_insar/miniconda3/envs/mintpy_env/lib/python3.9/site-packages/miaplpy/load_slc_geometry.py", line 115, in main
geomRadarObj.write2hdf5(outputFile=inps.out_file[1],
File "/home/adm_insar/miniconda3/envs/mintpy_env/lib/python3.9/site-packages/miaplpy/objects/geometryStack.py", line 224, in write2hdf5
data = self.get_incidence_angle(box=box, xstep=xstep, ystep=ystep)
File "/home/adm_insar/miniconda3/envs/mintpy_env/lib/python3.9/site-packages/mintpy/objects/stackDict.py", line 552, in get_incidence_angle
data = ut.incidence_angle(self.extraMetadata,
File "/home/adm_insar/miniconda3/envs/mintpy_env/lib/python3.9/site-packages/mintpy/utils/utils0.py", line 165, in incidence_angle
inc_angle = (np.pi - np.arccos(((r+dem)2 + range_dist2 - (r+H)**2) /
ValueError: operands could not be broadcast together with shapes (2720,2699) (2720,10797)
Go back to directory: /mnt/f/DHZ/rawdata/SLC/burst/RSLC/slc/miaplpy
Describe the bug
When importing coregistered burst SLC data processed by GAMMA via miaplpyAPP miaplpyAPP.cfg --dostep load_data, the slcStack.h5 file is generated successfully with correct dimensions. However, the program throws a dimension broadcast error while creating geometryRadar.h5, failing to generate geometry files for subsequent InSAR processing.
The core error is ValueError: operands could not be broadcast together with shapes (2720,2699) (2720,10797) during incidence angle calculation.
My Operation Workflow
Key Questions & Confusion
Error Logs
searching geometry files info
input data files:
height : ../prep_test/geometry/sim_20241006.rdc.dem
create HDF5 file /mnt/f/DHZ/rawdata/SLC/burst/RSLC/slc/miaplpy/inputs/slcStack.h5 with a mode
create dataset /slc of <class 'numpy.complex64'> in size of (45, 2692, 2720) with compression = None
create dataset /date of <class 'numpy.bytes_'> in size of (45, 1)
create dataset /bperp of <class 'numpy.float32'> in size of (45,)
update LENGTH, WIDTH, Y/XMAX
update/add SUBSET_XMIN/YMIN/XMAX/YMAX: 0/0/2720/2692
update STARTING_RANGE
Finished writing to /mnt/f/DHZ/rawdata/SLC/burst/RSLC/slc/miaplpy/inputs/slcStack.h5
create HDF5 file /mnt/f/DHZ/rawdata/SLC/burst/RSLC/slc/miaplpy/inputs/geometryRadar.h5 with a mode
create dataset /height of <class 'numpy.float32'> in size of (2692, 2720) with compression = lzf
Traceback (most recent call last):
File "/home/adm_insar/miniconda3/envs/mintpy_env/bin/load_slc_geometry.py", line 6, in
sys.exit(main())
File "/home/adm_insar/miniconda3/envs/mintpy_env/lib/python3.9/site-packages/miaplpy/load_slc_geometry.py", line 115, in main
geomRadarObj.write2hdf5(outputFile=inps.out_file[1],
File "/home/adm_insar/miniconda3/envs/mintpy_env/lib/python3.9/site-packages/miaplpy/objects/geometryStack.py", line 224, in write2hdf5
data = self.get_incidence_angle(box=box, xstep=xstep, ystep=ystep)
File "/home/adm_insar/miniconda3/envs/mintpy_env/lib/python3.9/site-packages/mintpy/objects/stackDict.py", line 552, in get_incidence_angle
data = ut.incidence_angle(self.extraMetadata,
File "/home/adm_insar/miniconda3/envs/mintpy_env/lib/python3.9/site-packages/mintpy/utils/utils0.py", line 165, in incidence_angle
inc_angle = (np.pi - np.arccos(((r+dem)2 + range_dist2 - (r+H)**2) /
ValueError: operands could not be broadcast together with shapes (2720,2699) (2720,10797)
Go back to directory: /mnt/f/DHZ/rawdata/SLC/burst/RSLC/slc/miaplpy