From 9ab1ed1f0a3725096d7146e4a7a72ea774e632e8 Mon Sep 17 00:00:00 2001 From: Josh Sixsmith Date: Wed, 15 Jun 2016 15:38:17 +1000 Subject: [PATCH] Added a check for scene completeness. If complete do not add to the list of scenes to run nbar over. --- workflow/nbar.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/workflow/nbar.py b/workflow/nbar.py index 4c729b6..b6e0589 100755 --- a/workflow/nbar.py +++ b/workflow/nbar.py @@ -1842,7 +1842,10 @@ def main(inpath, outpath, workpath, nnodes=1, nodenum=1): for l1t in l1t_files: acq = gaip.acquisitions(l1t)[0] if ((87 <= acq.path <= 116) & (67 <= acq.row <= 91)): - filtered_l1t.append(l1t) + completed = pjoin(workpath, (basename(l1t).replace('OTH', 'NBAR') + + '.completed')) + if not exists(completed): + filtered_l1t.append(l1t) else: msg = "Skipping {}".format(acq.dir_name) logging.info(msg)