From 69c31083c9a04b392daea3ef26b19dbfb37b1e91 Mon Sep 17 00:00:00 2001 From: David Keitel <david.keitel@ligo.org> Date: Tue, 5 Nov 2019 15:22:40 +0000 Subject: [PATCH] pass ephemerides through to PredictFstat --- pyfstat/core.py | 7 +++++++ pyfstat/make_sfts.py | 2 ++ 2 files changed, 9 insertions(+) diff --git a/pyfstat/core.py b/pyfstat/core.py index 914022e..6a27867 100755 --- a/pyfstat/core.py +++ b/pyfstat/core.py @@ -159,6 +159,8 @@ def predict_fstat( IFOs=None, assumeSqrtSX=None, tempory_filename="fs.tmp", + earth_ephem=None, + sun_ephem=None, **kwargs ): """ Wrapper to lalapps_PredictFstat @@ -201,6 +203,11 @@ def predict_fstat( cl_pfs.append("--maxStartTime={}".format(int(maxStartTime))) cl_pfs.append("--outputFstat={}".format(tempory_filename)) + if earth_ephem is not None: + cl_pfs.append("--ephemEarth='{}'".format(earth_ephem)) + if sun_ephem is not None: + cl_pfs.append("--ephemSun='{}'".format(sun_ephem)) + cl_pfs = " ".join(cl_pfs) helper_functions.run_commandline(cl_pfs) d = read_par(filename=tempory_filename) diff --git a/pyfstat/make_sfts.py b/pyfstat/make_sfts.py index fdf0d28..9ad3149 100644 --- a/pyfstat/make_sfts.py +++ b/pyfstat/make_sfts.py @@ -377,6 +377,8 @@ transientTau = {:10.0f}\n""" self.detectors, self.sqrtSX, tempory_filename="{}.tmp".format(self.label), + earth_ephem=self.earth_ephem, + sun_ephem=self.sun_ephem ) # detectors OR IFO? return twoF_expected -- GitLab