From 32f309b6e8ebbf0320f8048df80eb7d15addac94 Mon Sep 17 00:00:00 2001 From: Tomas Bylund Date: Thu, 29 Feb 2024 14:38:08 +0100 Subject: [PATCH] Fixed bug where background only used gh-cuts --- src/ctapipe/irf/irfs.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ctapipe/irf/irfs.py b/src/ctapipe/irf/irfs.py index da9ebcda3cd..cf9b84d8fc3 100644 --- a/src/ctapipe/irf/irfs.py +++ b/src/ctapipe/irf/irfs.py @@ -142,7 +142,7 @@ def __init__(self, parent, valid_offset, **kwargs): # check_bins_in_range(self.fov_offset_bins, self.valid_offset) def make_bkg3d_table_hdu(self, bkg_events, obs_time): - sel = bkg_events["selected_gh"] + sel = bkg_events["selected"] self.log.debug("%d background events selected" % sel.sum()) self.log.debug("%f obs time" % obs_time.to_value(u.h)) background_rate = background_3d( @@ -211,7 +211,7 @@ def __init__(self, parent, valid_offset, **kwargs): # check_bins_in_range(self.fov_offset_bins, self.valid_offset) def make_bkg2d_table_hdu(self, bkg_events, obs_time): - sel = bkg_events["selected_gh"] + sel = bkg_events["selected"] self.log.debug("%d background events selected" % sel.sum()) self.log.debug("%f obs time" % obs_time.to_value(u.h))