After searching the forum I have not seen this issue being asked. Any help will be appreciated.
Whenever I compute the coherence of two images I am getting many isolated NaN pixels in the coherence image. Is there a mathematical explanation for this?
As an example:
Input images (Atacama desert)
graph_backgeo_coh.xml (4.7 KB)
Subset of the output coherence for swath IW2, VV pol:
There are 5 NaN pixels, surrounded by pixels with coherence > 0.9
S1TBX 5.0.3 on Fedora 25.
if you right-click on your coherence band and select properties: Is ‘use NoData value’ checked? Is a NoData value assigned?
Thanks for your reply.
In the coherence band properties, I can see:
No-Data value used: checked
No-Data value: 0.0
Tracing back the NaN pixels in the graph, they seem to originate from pixels in the input images with 0 in either the I or Q component. Those pixels are converted to NaN, and these NaNs are propagated forward in the graph. Could this be? If this is what is happening, is there a way to make sure that gpt treats zeros as zeros and not as NaNs?
Problems with NaN values have recently reported here:
It seems the data conversion operation has an issue. It's not handling NaN values correctly. There is also the question how it should do it when converting the data from float32 to uint8. uint8 has no NaN value and so NaN becomes 255, for some reason. It would be good if the data conversion asks for the value which shall replace Nan values. How can you over com this? Either don't wright NaN values with your Band Math or you use the Band Maths again and replace the NaN values manually. The expres…
This won’t probably help you right now but maybe you can also suggest improvements there.