Skip to content

Commit

Permalink
dirname no scratch
Browse files Browse the repository at this point in the history
  • Loading branch information
jurjen93 committed Oct 24, 2024
1 parent 769d77b commit 12ccb9d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions subtract/subtract_with_wsclean.py
Original file line number Diff line number Diff line change
Expand Up @@ -964,8 +964,11 @@ def main():
# clean up scratch directory (for big MS)
os.system(f'cp *.log {outpath} && rm -rf *.ms')
os.chdir(outpath)

print(f'DONE: See output --> {dirname.replace("Dir","facet_")}-*.ms')

else:
for ms in msout: os.system(f"mv {ms} {dirname.replace("Dir","facet_")}-{ms.split("/")[-1]}")

elif args.scratch_toil:
# copy back the subtracted MS to the output path
for ms in subpred.mslist: fast_copy(ms, f'{outpath}/subfov_{ms.split("/")[-1]}')
Expand All @@ -975,6 +978,5 @@ def main():
for ms in subpred.mslist: os.system(f'mv {ms} subfov_{ms.split("/")[-1]}')
print(f"DONE: Output is SUBTRACT_DATA column in input MS")


if __name__ == "__main__":
main()

0 comments on commit 12ccb9d

Please sign in to comment.