aboutsummaryrefslogtreecommitdiffstats
path: root/astro/oskar
diff options
context:
space:
mode:
authorAaron LI <aly@aaronly.me>2017-08-22 22:43:25 +0800
committerAaron LI <aly@aaronly.me>2017-08-22 22:43:25 +0800
commit1f47be26bb4d33daabf97b4726684f3df52ba74b (patch)
treeb43314b53d60254fe22b9af11d378e8137c0fe2c /astro/oskar
parent3aa47a20316b5419c22327c70fcee3abf392b3a9 (diff)
downloadatoolbox-1f47be26bb4d33daabf97b4726684f3df52ba74b.tar.bz2
run_oskar.py: Record total time; print banner between runs
Diffstat (limited to 'astro/oskar')
-rwxr-xr-xastro/oskar/run_oskar.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/astro/oskar/run_oskar.py b/astro/oskar/run_oskar.py
index 1eab9ce..0eff069 100755
--- a/astro/oskar/run_oskar.py
+++ b/astro/oskar/run_oskar.py
@@ -69,6 +69,7 @@ def main():
parser.add_argument("-l", "--list", dest="listfile", required=True,
help="List of frequencies [MHz] and input sky models")
args = parser.parse_args()
+ t1 = time()
if not os.path.exists(args.outdir):
os.mkdir(args.outdir)
@@ -83,6 +84,10 @@ def main():
print("Got sky model: %s @ %s [MHz]" % (skyfile, freq))
for freq, skyfile in skymodels:
+ print(">>>")
+ print(">>> Frequency: %.2f [MHz]" % freq)
+ print(">>> Sky model: %s" % skyfile)
+ print(">>>")
basename = os.path.splitext(os.path.basename(skyfile))[0]
if args.no_vis_oskar:
vis_oskar = ""
@@ -100,6 +105,9 @@ def main():
vis_oskar=vis_oskar, vis_ms=vis_ms,
dryrun=args.dryrun)
+ t2 = time()
+ print("Total elapsed time: %.1f [s]" % (t2-t1))
+
if __name__ == "__main__":
main()