|
| 1 | +/** |
| 2 | + * @file sbnobj/Common/Reco/TPCPMTBarycenterMatch.h |
| 3 | + * @author Jack Smedley (jsmedley@fnal.gov) |
| 4 | + * @date June 21, 2023 |
| 5 | + * |
| 6 | + */ |
| 7 | + |
| 8 | +#include <limits> |
| 9 | +#include "larcoreobj/SimpleTypesAndConstants/geo_vectors.h" |
| 10 | + |
| 11 | + |
| 12 | +#ifndef SBNOBJ_COMMON_RECO_TPCPMTBARYCENTERMATCH_H |
| 13 | +#define SBNOBJ_COMMON_RECO_TPCPMTBARYCENTERMATCH_H |
| 14 | + |
| 15 | +namespace sbn { |
| 16 | + /** |
| 17 | + * @brief Information on matching of a reconstructed TPC object with a optical flash via barycenter matching algorithm. |
| 18 | + */ |
| 19 | + class TPCPMTBarycenterMatch { |
| 20 | + public: |
| 21 | + |
| 22 | + // NaN value to initialize data members |
| 23 | + static constexpr float fDefault = std::numeric_limits<float>::signaling_NaN(); |
| 24 | + |
| 25 | + /// @name Data members related to the slice barycenter determination |
| 26 | + /// @{ |
| 27 | + float chargeTotal { fDefault }; ///< Total charge in slice contributing to barycenter (integrated ADC counts) |
| 28 | + float chargeCenterXLocal { fDefault }; ///< Weighted mean X position of spacepoints, measured with respect to the cathode (cm) |
| 29 | + geo::Point_t chargeCenter { fDefault, fDefault, fDefault }; ///< Weighted mean spacepoint position in X,Y,Z (cm) |
| 30 | + geo::Vector_t chargeWidth { fDefault, fDefault, fDefault }; ///< Weighted standard devitation of spacepoint position in X,Y,Z (cm) |
| 31 | + /// @} |
| 32 | + |
| 33 | + |
| 34 | + /// @name Data members related to matched recob::OpFlash, also reachable by association |
| 35 | + /// @{ |
| 36 | + float flashTime { fDefault }; ///< Matched OpFlash time (us) |
| 37 | + float flashFirstHit { fDefault }; ///< Time of first OpHit in matched OpFlash (us) |
| 38 | + float flashPEs { fDefault }; ///< Total PEs in matched flash |
| 39 | + float flashAsymmetry { fDefault }; ///< East-West asymmetry of PEs in matched flash |
| 40 | + geo::Point_t flashCenter { fDefault, fDefault, fDefault }; ///< Weighted mean ophit position in X,Y,Z [no meaingful X info for ophits] (cm) |
| 41 | + geo::Vector_t flashWidth { fDefault, fDefault, fDefault }; ///< Weighted standard devitation of ophit position in X,Y,Z [no meaingful X info for ophits] (cm) |
| 42 | + /// @} |
| 43 | + |
| 44 | + |
| 45 | + /// @name Data members related to quality of match |
| 46 | + /// @{ |
| 47 | + float deltaY { fDefault }; ///< | Matched flash Y center - charge Y center | (cm) |
| 48 | + float deltaZ { fDefault }; ///< | Matched flash Z center - charge Z center | (cm) |
| 49 | + float radius { fDefault }; ///< Hypotenuse of DeltaY and DeltaZ (cm) |
| 50 | + float deltaT { fDefault }; ///< | Matched flash time - anab::T0 | when available (us) |
| 51 | + float overlapY { fDefault }; ///< Spatial overlap of flash and charge centroids in Y [>0] OR distance apart if no overlap [<0] (cm) |
| 52 | + float overlapZ { fDefault }; ///< Spatial overlap of flash and charge centroids in Z [>0] OR distance apart if no overlap [<0] (cm) |
| 53 | + float deltaZ_Trigger { fDefault }; ///< | Triggering flash Z center - charge Z center | (cm) |
| 54 | + float deltaY_Trigger { fDefault }; ///< | Triggering flash Y center - charge Y center | (cm) |
| 55 | + float radius_Trigger { fDefault }; ///< Hypotenuse of DeltaY_Trigger and DeltaZ_Trigger (cm) |
| 56 | + /// @} |
| 57 | + |
| 58 | + }; |
| 59 | +} |
| 60 | + |
| 61 | +#endif |
0 commit comments