Describe the Issue
Hello, I am encountering an issue when running SOFA (version v0.1). The input file I used is SHARAD EDR file 371502, which is the same as the one in your example at https://af-projects.it/sofa-slopes. The output I get is incorrect. I have run the script in debug mode and repeatedly received the warning: "RuntimeWarning: invalid value encountered in arccos". I tried different parameters, but the results are still incorrect. Below is the command I ran and the detailed output.
Command and Output
sofa.py -ip Data/1 -op Output -if input_radargram -of ouput_radargram -im megr88n090hb -imtM '88.' -imgm '90.' -d -p '20'
coherence time = 8.773632
Doppler half window width = 3
ZDS half window width = 0
Gaussian filters number: 2
power coefficients = [0.66, 0.2244, 0.11559999999999993] (including no filter coeff.)
std devs = [1.75, 3.5]
Reading MOLA data...
MOLA data read
SC mean altitude = 319384.1105320408
squint_offset_approx_distance = -0.0
squint_offset_approx_frames = 0
n_input_frames = 55000
frames_to_be_focused_start = 769
frames_to_be_focused_end = 54231
n_frames_to_be_focused = 2057
n_frames_to_be_processed = 54998
frames_to_be_processed_start = 1
frames_to_be_processed_end = 54999
read_block_size_optimal_approx = 4261.0
n_frames_to_be_focused_within_block_max = 106
read_block_size = 4267
overlapping_size = 1511
read_min_block_size = 1537
N BLOCKS = 20
last_block_n_frames_to_be_processed_within_block = 2629
...matched filtering...
...matched filtering...
...matched filtering...
...matched filtering...
...matched filtering...
FOCUSING FROM ABS 768 TO 3498 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
...matched filtering...
FOCUSING FROM ABS 3524 TO 6254 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
...matched filtering...
FOCUSING FROM ABS 6280 TO 9010 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
...matched filtering...
FOCUSING FROM ABS 9036 TO 11766 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
FOCUSING FROM ABS 11792 TO 14522 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
...matched filtering...
...
...matched filtering...
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
FOCUSING FROM ABS 44864 TO 47594 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
FOCUSING FROM ABS 47620 TO 50350 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
FOCUSING FROM ABS 53132 TO 54224 WITH SKIP 26
n_frames_to_be_focused_within_block = 43
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
FOCUSING FROM ABS 50376 TO 53106 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
...
angle=np.arccos(np.dot(v1_u, v2_u))
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
average real squint angle for block 0 = 3.9736042519350374e-07 mean aperture angle = 5.3641829566285235
average real squint angle for block 1 = 3.91089706870532e-07 mean aperture angle = 5.358660425088912
...
average real squint angle for block 19 = 3.2881161925445795e-07 mean aperture angle = 5.356168316721615
Image written to Output/ouput_radargram_769-54231_skip-26_ha-768_freq_ML-7_0.4_ZDS-1_GAUSS-2_AZ-hanning_RG-hanning_DPC-True_SQUINT_0.0.tif


Expected Behavior
I expect the radar-processed output image to be consistent with expected geological layering.
Questions
- What can I do to reasonable result?
Thank you in advance for your help. Any guidance you can provide would be greatly appreciated.
Describe the Issue
Hello, I am encountering an issue when running SOFA (version v0.1). The input file I used is SHARAD EDR file 371502, which is the same as the one in your example at https://af-projects.it/sofa-slopes. The output I get is incorrect. I have run the script in debug mode and repeatedly received the warning: "RuntimeWarning: invalid value encountered in arccos". I tried different parameters, but the results are still incorrect. Below is the command I ran and the detailed output.
Command and Output
sofa.py -ip Data/1 -op Output -if input_radargram -of ouput_radargram -im megr88n090hb -imtM '88.' -imgm '90.' -d -p '20'


coherence time = 8.773632
Doppler half window width = 3
ZDS half window width = 0
Gaussian filters number: 2
power coefficients = [0.66, 0.2244, 0.11559999999999993] (including no filter coeff.)
std devs = [1.75, 3.5]
Reading MOLA data...
MOLA data read
SC mean altitude = 319384.1105320408
squint_offset_approx_distance = -0.0
squint_offset_approx_frames = 0
n_input_frames = 55000
frames_to_be_focused_start = 769
frames_to_be_focused_end = 54231
n_frames_to_be_focused = 2057
n_frames_to_be_processed = 54998
frames_to_be_processed_start = 1
frames_to_be_processed_end = 54999
read_block_size_optimal_approx = 4261.0
n_frames_to_be_focused_within_block_max = 106
read_block_size = 4267
overlapping_size = 1511
read_min_block_size = 1537
N BLOCKS = 20
last_block_n_frames_to_be_processed_within_block = 2629
...matched filtering...
...matched filtering...
...matched filtering...
...matched filtering...
...matched filtering...
FOCUSING FROM ABS 768 TO 3498 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
...matched filtering...
FOCUSING FROM ABS 3524 TO 6254 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
...matched filtering...
FOCUSING FROM ABS 6280 TO 9010 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
...matched filtering...
FOCUSING FROM ABS 9036 TO 11766 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
FOCUSING FROM ABS 11792 TO 14522 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
...matched filtering...
...
...matched filtering...
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
FOCUSING FROM ABS 44864 TO 47594 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
FOCUSING FROM ABS 47620 TO 50350 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
FOCUSING FROM ABS 53132 TO 54224 WITH SKIP 26
n_frames_to_be_focused_within_block = 43
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
FOCUSING FROM ABS 50376 TO 53106 WITH SKIP 26
n_frames_to_be_focused_within_block = 106
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
...
angle=np.arccos(np.dot(v1_u, v2_u))
c:\Users\Administrator\OneDrive - 旅 (1)\Code\Git\sofa\v0.1\utils\geometry.py:107: RuntimeWarning: invalid value encountered in arccos
angle=np.arccos(np.dot(v1_u, v2_u))
average real squint angle for block 0 = 3.9736042519350374e-07 mean aperture angle = 5.3641829566285235
average real squint angle for block 1 = 3.91089706870532e-07 mean aperture angle = 5.358660425088912
...
average real squint angle for block 19 = 3.2881161925445795e-07 mean aperture angle = 5.356168316721615
Image written to Output/ouput_radargram_769-54231_skip-26_ha-768_freq_ML-7_0.4_ZDS-1_GAUSS-2_AZ-hanning_RG-hanning_DPC-True_SQUINT_0.0.tif
Expected Behavior
I expect the radar-processed output image to be consistent with expected geological layering.
Questions
Thank you in advance for your help. Any guidance you can provide would be greatly appreciated.