From 510d9da627f727d5ebf7dc85767d2e0d59602bb0 Mon Sep 17 00:00:00 2001
From: "chad.hanna" <crh184@psu.edu>
Date: Tue, 25 Sep 2018 06:48:30 -0700
Subject: [PATCH] gstlal_ll_inspiral_state: FIXME this implements a hack to
 take into account that ALIGO uses a 16Hz dq vector and virgo uses a 1 Hz dq
 vector. gstlal inspiral should just report the output of added and dropped
 data in seconds rather than samples and this would go away

---
 gstlal-ugly/bin/gstlal_ll_inspiral_state | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/gstlal-ugly/bin/gstlal_ll_inspiral_state b/gstlal-ugly/bin/gstlal_ll_inspiral_state
index b7daa3fd48..7323ffc86c 100755
--- a/gstlal-ugly/bin/gstlal_ll_inspiral_state
+++ b/gstlal-ugly/bin/gstlal_ll_inspiral_state
@@ -121,6 +121,9 @@ if __name__ == '__main__':
 			logging.info("getting data from kafka")
 			timedata, datadata = aggregator.get_data_from_kafka(jobs, routes, consumer, req_all = True)
 			for (job,route) in timedata:
+				if "L1" in route or "H1" in route:
+					# FIXME hack to adjust for 16 Hz sample rate of ALIGO vs 1 Hz of Virgo
+					datadata[(job,route)] /= 16
 				path = "%s/by_job/%s" % (options.base_dir, job)
 				fname = aggregator.create_new_dataset(path, route.replace("/","_"), timedata = timedata[(job,route)], data = datadata[(job,route)], tmp = True)
 				shutil.move(fname, fname.replace(".tmp", ""))
-- 
GitLab