diff --git a/gstlal-calibration/bin/gstlal_compute_strain b/gstlal-calibration/bin/gstlal_compute_strain index c5fbdd153d1584d47197af9d4bde63f5cd1e23e2..557ecf10c0f2a6617201ba7471406e6d642b864b 100755 --- a/gstlal-calibration/bin/gstlal_compute_strain +++ b/gstlal-calibration/bin/gstlal_compute_strain @@ -167,6 +167,7 @@ parser.add_option("--no-gamma", action = "store_true", help = "Set this to turn parser.add_option("--apply-gamma", action = "store_true", help = "Set this to have the \gamma factors multiply the sensing chain.") parser.add_option("--compute-gamma-sr", metavar = "Hz", type = int, default = 2048, help = "Sample rate at which \gamma(t) is computed. (Default = 2048 Hz)") parser.add_option("--record-gamma-sr", metavar = "Hz", type = int, default = 16, help = "Sample rate at which \gamma(t) is recorded. (Default = 16 Hz)") +parser.add_option("--gamma-integration-time", metavar = "sec", type = float, default = 1.0, help = "Integration time for \gamma(t) computation. (Default = 1 s)") parser.add_option("--gamma-real-min", metavar = "float", type = float, default = 0.5, help = "Minimum acceptable value for real part of \gamma(t).") parser.add_option("--gamma-real-max", metavar = "float", type = float, default = 1.5, help = "Maximum acceptable value for real part of \gamma(t).") parser.add_option("--gamma-imag-min", metavar = "float", type = float, default = -0.5, help = "Minimum acceptable value for imaginary part of \gamma(t).") @@ -377,11 +378,16 @@ if not options.no_gamma: cal_line_freq = 1144.300000 """ # If you have a filters file with all of the info in it, uncomment the following lines - olgR = float(filters["olg_re"]) - olgI = float(filters["olg_im"]) - wR = float(filters["whitener_re"]) - wI = float(filters["whitener_im"]) - cal_line_freq = float(filters["cal_line_freq"]) + #olgR = float(filters["olg_re"]) + #olgI = float(filters["olg_im"]) + #wR = float(filters["whitener_re"]) + #wI = float(filters["whitener_im"]) + #cal_line_freq = float(filters["cal_line_freq"]) + olgR = -1.00075 + olgI = 0.00075569 + wR = 1.6177e-5 + wI = -1.8659e-4 + cal_line_freq = 535.1 wmod = wR * wR + wI * wI olgmod = olgR * olgR + olgI * olgI @@ -462,7 +468,7 @@ if not options.no_gamma: ctrl_for_gamma = pipeparts.mkqueue(pipeline, ctrltee, max_size_time = gst.SECOND * 100) elif options.partial_calibration: ctrl_for_gamma = pipeparts.mkqueue(pipeline, darm_ctrl, max_size_time = gst.SECOND * 100) - compute_gamma_bin = pipeparts.mkcomputegamma(pipeline, ctrl_for_gamma, pipeparts.mkqueue(pipeline, exctee, max_size_time = gst.SECOND * 100), pipeparts.mkqueue(pipeline, cos, max_size_time = gst.SECOND * 100), pipeparts.mkqueue(pipeline, sin, max_size_time = gst.SECOND * 100), olgI = olgI, olgR = olgR, sr = options.compute_gamma_sr, time_domain = True, wI = wI, wR = wR, wmod = wmod, olgmod = olgmod) + compute_gamma_bin = pipeparts.mkcomputegamma(pipeline, ctrl_for_gamma, pipeparts.mkqueue(pipeline, exctee, max_size_time = gst.SECOND * 100), pipeparts.mkqueue(pipeline, cos, max_size_time = gst.SECOND * 100), pipeparts.mkqueue(pipeline, sin, max_size_time = gst.SECOND * 100), integration_samples = int(options.compute_gamma_sr*options.gamma_integration_time), olgI = olgI, olgR = olgR, sr = options.compute_gamma_sr, time_domain = True, wI = wI, wR = wR, wmod = wmod, olgmod = olgmod) gammaR = compute_gamma_bin.get_pad("gammaR") gammaR = pipeparts.mkaudioconvert(pipeline, gammaR) gammaR = pipeparts.mkcapsfilter(pipeline, gammaR, "audio/x-raw-float, width=64, rate=%d" % options.compute_gamma_sr) diff --git a/gstlal-calibration/configure.ac b/gstlal-calibration/configure.ac index fc60984279f48344f18a2af4b4abd18b640e0394..8c574a78853f72e7d699e3a1cdefe39323fb431f 100644 --- a/gstlal-calibration/configure.ac +++ b/gstlal-calibration/configure.ac @@ -3,7 +3,7 @@ # -AC_INIT([gstlal-calibration],[0.3.3],[gstlal-discuss@ligo.org],[gstlal-calibration]) +AC_INIT([gstlal-calibration],[0.4.0],[gstlal-discuss@ligo.org],[gstlal-calibration]) AC_COPYRIGHT([Copyright (C) 2008--2015 Madeline Wade]) # a file whose existance can be used to use to check that we are in the # top-level directory of the source tree diff --git a/gstlal-calibration/debian/changelog b/gstlal-calibration/debian/changelog index 7b63706b4b42e462ed4b6ad087b82178472bf037..6fe32d11f31db8a913e693b72ff6273cac8689aa 100644 --- a/gstlal-calibration/debian/changelog +++ b/gstlal-calibration/debian/changelog @@ -1,3 +1,9 @@ +gstlal-calibration (0.4.0-1) unstable; urgency=low + + * First pre-ER8 release + + -- Madeline Wade <madeline.wade@ligo.org> Fri, 31 July 2015 15:47:00 -0500 + gstlal-calibration (0.3.3-1) unstable; urgency=low * Another bug fix release for the --wings option (again) diff --git a/gstlal-calibration/gst/python/lal_compute_gamma.py b/gstlal-calibration/gst/python/lal_compute_gamma.py index 30166f02056d6e4e24a90691aafd77dc4cca57f2..e564ad02857765f44743a60be2da928edb816bd4 100644 --- a/gstlal-calibration/gst/python/lal_compute_gamma.py +++ b/gstlal-calibration/gst/python/lal_compute_gamma.py @@ -54,6 +54,7 @@ class lal_compute_gamma(gst.Bin): olgmod_default = 1.0 sr_default = 16384 time_domain_default = True + integration_samples_default = sr_default __gstdetails__ = ( 'Compute Gamma', @@ -118,6 +119,13 @@ class lal_compute_gamma(gst.Bin): 'set to True to perform FIR filtering in the time domain', time_domain_default, gobject.PARAM_READWRITE | gobject.PARAM_CONSTRUCT + ), + 'integration-samples' : ( + gobject.TYPE_UINT, + 'integration time', + 'number of samples in integration', + 0, gobject.G_MAXUINT, integration_samples_default, + gobject.PARAM_READWRITE | gobject.PARAM_CONSTRUCT ) } @@ -128,16 +136,18 @@ class lal_compute_gamma(gst.Bin): self.excI_capsfilter.set_property("caps", gst.Caps("audio/x-raw-float, rate=%d" % val)) self.dctrlR_capsfilter.set_property("caps", gst.Caps("audio/x-raw-float, rate=%d" % val)) self.dctrlI_capsfilter.set_property("caps", gst.Caps("audio/x-raw-float, rate=%d" % val)) - self.excR_firbank.set_property("fir-matrix", [numpy.hanning(val)]) - self.excI_firbank.set_property("fir-matrix", [numpy.hanning(val)]) - self.dctrlR_firbank.set_property("fir-matrix", [numpy.hanning(val)]) - self.dctrlI_firbank.set_property("fir-matrix", [numpy.hanning(val)]) elif prop.name == 'time-domain': self.time_domain = val self.excR_firbank.set_property("time-domain", val) self.excI_firbank.set_property("time-domain", val) self.dctrlR_firbank.set_property("time-domain", val) self.dctrlI_firbank.set_property("time-domain", val) + elif prop.name == 'integration-samples': + self.integration_samples = val + self.excR_firbank.set_property("fir-matrix", [numpy.hanning(val+1)]) + self.excI_firbank.set_property("fir-matrix", [numpy.hanning(val+1)]) + self.dctrlR_firbank.set_property("fir-matrix", [numpy.hanning(val+1)]) + self.dctrlI_firbank.set_property("fir-matrix", [numpy.hanning(val+1)]) elif prop.name == 'olgR': self.olgR = val self.dctrl_mod_w_mod_olgR.set_property("amplification", val) @@ -186,6 +196,8 @@ class lal_compute_gamma(gst.Bin): return self.sr elif prop.name == 'time-domain': return self.time_domain + elif prop.name == 'integration-samples': + return self.integration_samples elif prop.name == 'olgR': return self.olgR elif prop.name == 'olgI': @@ -228,9 +240,10 @@ class lal_compute_gamma(gst.Bin): self.add(excR) pipeparts.mkqueue(self, exc).link(excR) pipeparts.mkqueue(self, cos).link(excR) - excR = pipeparts.mkresample(self, excR, quality=9) + #excR = pipeparts.mkresample(self, excR, quality=9) + excR = pipeparts.mkaudioundersample(self, excR) self.excR_capsfilter = excR = pipeparts.mkgeneric(self, excR, "capsfilter") - self.excR_firbank = excR = pipeparts.mkfirbank(self, excR) + self.excR_firbank = excR = pipeparts.mkfirbank(self, excR) excR = pipeparts.mktee(self, excR) excI = gst.element_factory_make("lal_multiplier") @@ -238,7 +251,8 @@ class lal_compute_gamma(gst.Bin): self.add(excI) pipeparts.mkqueue(self, exc).link(excI) pipeparts.mkqueue(self, sin).link(excI) - excI = pipeparts.mkresample(self, excI, quality=9) + #excI = pipeparts.mkresample(self, excI, quality=9) + excI = pipeparts.mkaudioundersample(self, excI) self.excI_capsfilter = excI = pipeparts.mkgeneric(self, excI, "capsfilter") self.excI_firbank = excI = pipeparts.mkfirbank(self, excI) excI = pipeparts.mktee(self, excI)