From ebc150fff646cb4a39fc09e7f290217f69946154 Mon Sep 17 00:00:00 2001 From: Nicholas Kamp Date: Wed, 6 Mar 2024 11:55:35 -0500 Subject: [PATCH] Calculate in_fiducial flag correctly in LIController --- python/LIController.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/python/LIController.py b/python/LIController.py index b1b7f3f3..a59c9f25 100644 --- a/python/LIController.py +++ b/python/LIController.py @@ -417,11 +417,9 @@ def SaveEvents(self, filename, fill_tables_at_exit=True, hdf5=True, parquet=True if self.fid_vol is not None: pos = _math.Vector3D(datasets["vertex"][-1][-1]) - geo_pos = self.detector_model.DetPositionToGeoPosition(pos) dir = _math.Vector3D(datasets["primary_momentum"][-1][-1][1:]) dir.normalize() - geo_dir = self.detector_model.DetDirectionToGeoDirection(dir) - datasets["in_fiducial"][-1].append(self.fid_vol.IsInside(geo_pos.get(),geo_dir.get())) + datasets["in_fiducial"][-1].append(self.fid_vol.IsInside(pos,dir)) else: datasets["in_fiducial"][-1].append(False)