From 7cab3fdf7def164a3f839eb936b4dd801d89547c Mon Sep 17 00:00:00 2001 From: mhuen Date: Mon, 10 Feb 2020 23:00:08 +0100 Subject: [PATCH] only consider energy losses within 2000m and above energy cutoff --- ic3_data/utils/mc_tree_input.py | 3 ++- ic3_data_ext/ext_boost.cpp | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ic3_data/utils/mc_tree_input.py b/ic3_data/utils/mc_tree_input.py index f4874a4..ffbc6ce 100644 --- a/ic3_data/utils/mc_tree_input.py +++ b/ic3_data/utils/mc_tree_input.py @@ -29,7 +29,8 @@ def get_mc_tree_input_data_dict(frame, angle_bins, distance_bins, for loss in frame['I3MCTree']: # skip energy loss if it is not one of the allowed types - if loss.type not in allowed_types: + if (loss.type not in allowed_types or loss.energy < energy_cutoff + or loss.pos.magnitude > 2000): continue # walk through DOMs and calculate data diff --git a/ic3_data_ext/ext_boost.cpp b/ic3_data_ext/ext_boost.cpp index 94217fc..ace6030 100644 --- a/ic3_data_ext/ext_boost.cpp +++ b/ic3_data_ext/ext_boost.cpp @@ -325,7 +325,8 @@ inline boost::python::dict get_mc_tree_input_data_dict( break; default: is_allowed_type=false; } - if (!is_allowed_type){ + if (!is_allowed_type || loss.GetEnergy() < energy_cutoff || + loss.GetPos().Magnitude() > 2000){ continue; }