Closed SteffanDavies closed 1 year ago
I am now trying unwrapping with only 1 subswath (F2 only, deleted F1 + F3 from raw_data and no merging) and get a different error:
FileNotFoundError: [Errno 2] No such file or directory: 'raw_stack/F2_20210511_20210523_unwrap.out'
Workdir:
Snaphu tiledir:
I noticed sbas.snaphu_config lists TILEDIR as master filename. Is this a problem for SBAS stack of multiple pairs? Or does your code change the TILEDIR on the fly?
After looking at your code, do I have to create a separate snaphu conf file for each interferogram with the correct master? How do you use tilling on multiple parallel interferograms unwrapping (ex: 4 tiles per IFG while running 2 unwraps for 8 CPU total)?
I noticed sbas.snaphu_config lists TILEDIR as master filename. Is this a problem for SBAS stack of multiple pairs? Or does your code change the TILEDIR on the fly?
Yes, for parallel unwrapping the TILEDIR path is different for the every ref-rep pair, see the code below:
def unwrap_parallel(self, pairs, n_jobs=-1, **kwargs):
...
def unwrap(subswath, pair, **kwargs):
# define unique tiledir name for parallel processing
if 'conf' in kwargs:
dirname = f'F{subswath}_{"_".join(pair).replace("-","")}_snaphu_tiledir'
dirpath = os.path.join(self.basedir, dirname)
kwargs['conf'] += f' TILEDIR {dirpath}'
return self.unwrap(subswath, pair, **kwargs)
...
TILEDIR as master filename is applied for 'unwrap' function designed to process a single grid to check the parameters. Please try to unwrap a single interferogram in 'debug' mode to see SNAPHU logs and errors (/dev/stdout and /dev/stderr):
unwrap, conn = sbas.unwrap(sbas.get_subswath(), pairs.values[0],
func=filter, conf=snaphuconf, mask=landmask_ra, conncomp=True, debug=True)
Yes, I read your code a few hours ago and TILEDIR is correctly created on the fly.
I am currently unwrapping parallel in debug mode.
@SteffanDavies Does it work for you now?
System: Python 3.10.6 Ubuntu 22.04 RAM 240 GB Processor 16 vCores
My code: