From 10392dcc1f206ee444669ae0ed843c135e3af002 Mon Sep 17 00:00:00 2001 From: "Sergey E. Koposov" Date: Wed, 27 Dec 2023 15:15:21 +0000 Subject: [PATCH] speed up reading --- py/minimint/mist_interpolator.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/py/minimint/mist_interpolator.py b/py/minimint/mist_interpolator.py index 52a5ea6..1b1b690 100644 --- a/py/minimint/mist_interpolator.py +++ b/py/minimint/mist_interpolator.py @@ -75,7 +75,7 @@ def read_grid(eep_prefix, outp_prefix): for i, f in enumerate(fs): if i % (N // 100) == 0: print('%d/%d' % (i, N)) - curt = atpy.Table().read(f, format='ascii') + curt = atpy.Table().read(f, format='ascii.fast_no_header') for i, k in enumerate(list(curt.columns)): curt.rename_column(k, list(tab0.columns)[i]) D = getheader(f) @@ -175,7 +175,6 @@ def writer(url, pref): f'7z x {fname_out1}') else: cmd = f'cd {pref}; tar xfJ {fname_out}' - #ret = subprocess.run(cmd, capture_output=True, shell=True, timeout=60) ret = subprocess.run(cmd, shell=True, timeout=60) if ret.returncode != 0: raise RuntimeError('Failed to untar the files' +