From 469f44f238aee2d2473c82b5067656c6047b358b Mon Sep 17 00:00:00 2001
From: Colm Talbot <colm.talbot@ligo.org>
Date: Tue, 5 Jun 2018 16:30:05 +1000
Subject: [PATCH] PSD needs epoch

---
 tupak/detector.py | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/tupak/detector.py b/tupak/detector.py
index 4bb5e154d..a78edfa7e 100644
--- a/tupak/detector.py
+++ b/tupak/detector.py
@@ -364,12 +364,12 @@ class Interferometer(object):
                     sampling_frequency, duration)
         elif frame_file is not None:
             logging.info('Reading data from frame, {}.'.format(self.name))
-            strain = tupak.utils.read_frame_file(frame_file, t1=epoch, t2=epoch+duration, channel=channel_name,
-                                                 resample=sampling_frequency)
+            strain = tupak.utils.read_frame_file(
+                frame_file, t1=epoch, t2=epoch+duration, channel=channel_name, resample=sampling_frequency)
             frequency_domain_strain, frequencies = tupak.utils.process_strain_data(strain, **kwargs)
             frequencies = utils.create_frequency_series(sampling_frequency, duration)
-            self.power_spectral_density = PowerSpectralDensity(frame_file=frame_file, channel_name=channel_name,
-                                                               **kwargs)
+            self.power_spectral_density = PowerSpectralDensity(
+                frame_file=frame_file, channel_name=channel_name, epoch=epoch, **kwargs)
         else:
             raise ValueError("No method to set data provided.")
 
-- 
GitLab