SNAPHU Unwrapping

Dear ABraun,

Thank you very much for your answer – you’re right, I’ve missed an overlap parameters and used default values = 0.

I’ve just tried row and column overlap = 200 and 400.

Even though my image is only 1597×571 pixels, for overlap = 200 I got messages “WARNING: Tile overlap is small (may give bad results)” and “SUGGESTION: Try increasing tile overlap and/or size if solution has edge artifacts” but the unwrapping finished successfully.

For overlap = 400 everything was OK. Now the unwrapped phase looks better – new values appeared and somehow many of them are located in the area of low coherence (blue area). However, the area with high coherence is still 0.

I’ve also tested color stretching, but it made no difference as the values are all 0.

Should I try any other parameters or additional processing steps? Thank you in advance!

if your image is only 571 rows large, 10x10 tiles and and overlap with 200 pixels makes little sense to me. because the tiles (129x57 pixels) are smaller than the selected overlap.
If it is really this small, you can try to test 2 x 2 tiles or even to unwrap the entire scene as one single tile.

Hello,

I would like to measure the subsidence of a tailings pile over the last few years. I started using your software (SNAP) after seeing a tutorial on youtube. I have no experience in remote sensing or satellite image processing. I have a problem in the Unwrapping phase using snaphu.
I would like to measure the subsidence of a tailings pile over the last few years. I started using your software (SNAP) after seeing a tutorial on youtube. I have no experience in remote sensing or satellite image processing. I have a problem in the Unwrapping phase using snaphu.After the export phase of Snaphu, I can only find 4 files (not 6 files as in the tutorial), yet I continued the steps. In the Unwrapping phase, I found an error (Unexpected or abnormal exit of child process) and I don’t know how to handle it.I try to increase the number of columns and rows, but I always get the same error. I tried to change the snaphu parameters (number of raws-colums/overlaps) but I have same problem and I get only 4 files in the exported snaphu.

I have other Questions :
‎1-‎ ‎ What is the influence of the selected DEM? ‎
‎2-‎ How can I solve the snaphu Unwrapping problem (see picture above, cmd)?‎
‎3-‎ ‎ How can I evaluate the accuracy of the consistency between the two selected images ‎and is there a problem if the period between the images is two years?‎
‎4-‎ ‎ I want to know if the selected parameters are correct and how to know if they should ‎be adjusted.‎

Thank you for your help,
image
image
image
image

I don’t think that automating this task makes much sense, because you lose control over the different steps and don’t have the chance to inspect the images after each step. InSAR is quite sensitive to many error sources so it is required to adjust parameters before proceeding. Also, finding the source of errors can be difficult if you only have one output file.

If you want reliable results, I recommend going through the process step by step and carefully check the results: Sentinel-1 TOPS interferometry

The error message in your case states that the DEM you use for BackGeocoding is not available in your area. Please switch from SRTM 3Sec to Copernicus 30m

2 Likes

Dear ABraun,

Thank you very much for your recommendation! I tried to unwrap my image as 1 tile but still the interested areas remain 0. The result with tile size 2×2 and overlap 200 looks better but also has 0 in interested areas.


But nevertheless in further processing of the images of this size I plan to use tile size 2×2 and overlap 200 (they seem to be the most reliable).

I thought that the problem might be because of areas of existing areas with low coherence. Therefore, I decided to mask the areas with coherence less than 0.2 before the unwrapping:

I applied “Use coherence mask” = 0.2 on the step of Goldstein filtering but according to my results it is not efficient – phase is not 0 for areas with low coherence.

Then I applied the method presented here: https://yenyiwu.wordpress.com/2021/03/03/phase-unwrapping1/

Phase became 0 for areas with low coherence but after unwrapping the abs phase in these points is not 0 (it is, for example, 6.2). So it means that masked out pixels were included in unwrapping. I tested it on other pairs and saw the same problem – I get non-zero abs phase (and therefore displacements) for masked pixels.

Could you please tell me what might be the reason for such a mistake and what is the right way to unwrap the masked low coherence pixels?

using the coherencethreshold of 0.2 in the Goldstein filtering will not automatically set the phase to zero at these pixels.

The masking you mentioned is effective, we have also discussed it here: Filter out low coherence pixels before phase unwrapping
These areas are treated as equal in the unwrapping, but they will not remain zero, because unwrapping adds up adjacent phase values to an absolute surface. The only benefit from masking before unwrapping is that these areas will not introduce ramps in your unwrapped data because random phase is integrated.

Hi Andreas,
Can you please elaborate this overlap of 50 pixels in 10x10 while 100 in 5x5?

I am multiplying 10x10 = 100 and then 600x400 = 240000
240000/100 = 2400 ???

How can I calculate size of single tile and then set the overlap accordingly.

there is no mathematical relationship to determine a suitable overlap, but the tile number determines the tile size and the overlap should be considering the tile size.

For example, if your raster has 8500 columns and 6300 rows. If you select 10x10 tiles, each of the tiles has a size of 850 x 630 pixels. an overlap of 200 is fine.
But if your raster has 2300x1400 pixels and you select 10x10 tiles, the size of the tiles (230x140 pixels) does not allow an overlap of 200 any longer, because the overlap would be larger than the number of rows. It then makes more sense to reduce the number of tiles (e.g. 2x2 > 1150x1200) and stick withan overlap of 200 .
The overall idea behind the overlap is to seamlessly merge the unwrapped tiles so that no “chessboard pattern” is produced in the unwrapped raster.

1 Like

:roll_eyes: :disappointed_relieved:
Still not getting that 8500x6300 example. Sorry! Maybe it’s something really easy and I am not getting it. Apologies but please make it more simple for me. I don’t get that 1150x1200 part.

In the end, you want a good unwrapping result, right? So simply run it and check if it looks alright. If you see regular patterns in azimuth and range direction , change the number of tiles and adjust the overlap size. There is no ideal value to set. The only thing important is that the overlap is not larger than the tile and not too small. It should be in a reasonable relation to the tile size in azimuth and range direction.

4 Likes

Ok gave it a deep thought. So far this is what I got, Overlap has to do something with “Number of Tiles”. And it has to be less than or equal to Number of tiles. Sweet … I get it now.

  1. Find the image dimensions (Tile Size)
  2. Decide number of rows and columns e.g. any number you like and divide the entire image by it
  3. If the overlap amount is equal to or exceeds single row or column size it will show error!

Correct??

One last thing what is this Tile Threshold nd What if I set the overlap to zero, as I did in my DEM example. Just changed row and column numbers. Impact of Overlapping on Spatial Resolution of end product?

yes. SNAPHU is not very efficient in unrapping the entire raster at once, also errors add up if you do so. So especially for large rasters, it makes sense to cut the raster into smaller parts (=tiles), determined by the number of rows and colums. If you select many, the tiles will become small. But then, the overlap has to be small as well. The overlap is the area which is added to each tile (in pixels) so that adjacent tiles can be mosaiced seamlessly.

With zero overlap you often end up with jumps like this.
grafik

It is more important that you check your results and say if you like them or not. If not, then you change some parameters to fix it, not the other way round. But to do that reasonably, it is good to understand how unwrapping works in general.

Have you seen this? SNAPHU parameters
I’m not sure about the tile cost threshold to be honest, it is explained somehwere in the manual: https://web.stanford.edu/group/radar/softwareandlinks/sw/snaphu/snaphu_man1.html

2 Likes

Thank you so so much Andreas. Followed you on Twitter also. is there any impact of overlapping on spatial resolution? Again what would we do without you :slight_smile: Stay blessed man.

Luckily saw that 7 hours ago. Those parameters let me check the second link.

the input product will not change from different parameters, but surely, an inteferogram of TerraSAR-X (3m) will always look different than one of ENVISAT (30m) in general. Again, best way to find out is to try different configurations and compare the results.
I’m not actively producing content on twitter, but mostly use it to receive Earth Observation news. But I’m happy if I could help you moving forward.

1 Like

Got it. Thank you

Hello.

I wonder if anyone has any ideas on, or has previously come across, an unwrapping issue which seems to give an offset related to the wavelength of the Sentinel C-band

I am trying to produce some interferograms of a small area (5x5km). The average coherence is around 0.3, which is not ideal, but there are some large separated block of high coherence.

When I alter the Spaphu output parameters for a single pair of images from the same orbit paired 12 days apart, the product shows the general background deformation oscillating either around +0.0150, -0.0125 or -0.0400m. The differences between these figures are exactly half the wavelength of the C-band (~0.055m). I would expect the deformation to oscillate around zero outside of anomalies for such a small temporal baseline, so I guess it’s something to do with snaphu picking up the wrong cycle.

Does anyone know what is going on here?

can you please share a screenshot of the interferogram before and after unwrapping? Also where the profile of your plot is located.

1 Like

There has to be some displacement. It could be nominal but displacement is always there. Any natural -earth quake / anthropogenic events-construction on those days? Also I feel like it has to do something with the small area. How good was your back-geocoding? As you said coherence is low (0.3) lots of factors to consider. Try with another slave image etc How much pixel overlap did you gave? Try with a zero overlap. Please attach screenshot of snaphu export parameters too.

Many thanks for getting back to me and helping with this. I really appreciate it. I’ve had to reprocess with a slightly different subset boundary and this time the displacement oscillates around -0.0125 (half wavelength difference to the previous example which has the background displacement around +0.0150).

The attached shows the before and after unwrapping interferogram and the location of the profile. Naturally I would like to investigate the feature in the red circle, but absolute values would be useful.