diff --git a/scripts/pmt_hrv.py b/scripts/pmt_hrv.py index a523b54b29966b43a3d645d00852ec4a483c6ea8..30b4aac6aa92379f1f5ae84b3b770e6d20e94c8f 100755 --- a/scripts/pmt_hrv.py +++ b/scripts/pmt_hrv.py @@ -44,7 +44,7 @@ VERSION = "1.0" log = kp.logger.logging.getLogger("PMTrates") -class PMTRates(kp.Module): +class PMTHRV(kp.Module): def configure(self): self.detector = self.require("detector") self.du = self.require("du") @@ -107,7 +107,7 @@ class PMTRates(kp.Module): ax.imshow(m, origin='lower', interpolation='none') ax.set_title("HRV Ratios (Monitoring Channel) for DetID-{} DU-{}\n" "PMTs ordered from top to bottom - {}" - .format(self.det_id, self.du, datetime.utcnow())) + .format(self.detector.det_id, self.du, datetime.utcnow())) ax.set_xlabel("UTC time [{}s/px]".format(interval)) plt.yticks([i*31 for i in range(18)], ["Floor {}".format(f) for f in range(1, 19)]) @@ -169,7 +169,7 @@ def main(): tags='IO_MONIT', timeout=60*60*24*7, max_queue=2000) - pipe.attach(PMTRates, + pipe.attach(PMTHRV, detector=detector, du=du, interval=interval, diff --git a/scripts/pmt_rates.py b/scripts/pmt_rates.py index 992ae663f5245692eb4ae7fe69533878935a7a4a..ee2bc25b6bad9e91d9c4d14d4e17fe6e7950784b 100755 --- a/scripts/pmt_rates.py +++ b/scripts/pmt_rates.py @@ -110,7 +110,7 @@ class PMTRates(kp.Module): ax.set_title("Mean PMT Rates (Monitoring Channel) for DetID-{} DU-{} " "- colours from 5kHz to 15kHz\n" "PMTs ordered from top to bottom - {}" - .format(self.det_id, self.du, datetime.utcnow())) + .format(self.detector.det_id, self.du, datetime.utcnow())) ax.set_xlabel("UTC time [{}s/px]".format(interval)) plt.yticks([i*31 for i in range(18)], ["Floor {}".format(f) for f in range(1, 19)])