1 #ifndef CRTHITRECOALG_H_SEEN
2 #define CRTHITRECOALG_H_SEEN
13 #include "art/Framework/Principal/Event.h"
14 #include "art/Framework/Core/ModuleMacros.h"
15 #include "fhiclcpp/ParameterSet.h"
16 #include "art/Framework/Principal/Handle.h"
17 #include "canvas/Persistency/Common/Ptr.h"
18 #include "canvas/Persistency/Common/PtrVector.h"
19 #include "art/Framework/Services/Registry/ServiceHandle.h"
20 #include "messagefacility/MessageLogger/MessageLogger.h"
21 #include "canvas/Persistency/Common/FindManyP.h"
28 class DetectorClocksData;
29 class DetectorPropertiesData;
33 #include "messagefacility/MessageLogger/MessageLogger.h"
34 #include "fhiclcpp/ParameterSet.h"
35 #include "fhiclcpp/types/Table.h"
36 #include "fhiclcpp/types/Atom.h"
37 #include "cetlib/pow.h"
57 #include "TGeoManager.h"
68 std::pair<std::string, unsigned>
tagger;
81 Name(
"UseReadoutWindow"),
82 Comment(
"Only reconstruct hits within readout window")
87 Comment(
"Pedestal offset [ADC]")
92 Comment(
"Pedestal slope [ADC/photon]")
96 Name(
"NpeScaleShift"),
97 Comment(
"Parameter for correcting for distance along strip")
101 Name(
"TimeCoincidenceLimit"),
102 Comment(
"Minimum time between two overlapping hit crt strips")
106 Name(
"ClockSpeedCRT"),
107 Comment(
"Clock speed of the CRT system [MHz]")
112 Comment(
"The global time offset to use for the CRT times")
115 Name(
"UseG4RefTimeOffset"),
116 Comment(
"Wheater or not to use the G4RefTime as GlobalT0Offset"),
120 Comment(
"Delay in pulse arrival time [ns/m]"),
124 Comment(
"Time delay fit: Gaussian normalization"),
128 Comment(
"Time delay fit: Gaussian x shift"),
132 Comment(
"Time delay fit: Gaussian width"),
135 Name(
"TDelayOffset"),
136 Comment(
"Time delay fit: Gaussian baseline offset"),
157 CRTStrip
CreateCRTStrip(art::Ptr<sbnd::crt::CRTData> sipm1, art::Ptr<sbnd::crt::CRTData> sipm2,
size_t ind);
159 std::pair<double, double>
DistanceBetweenSipms(art::Ptr<sbnd::crt::CRTData> sipm1, art::Ptr<sbnd::crt::CRTData> sipm2);
161 std::vector<std::pair<sbn::crt::CRTHit, std::vector<int>>>
CreateCRTHits(std::map<std::pair<std::string, unsigned>, std::vector<CRTStrip>> taggerStrips);
167 std::vector<double>
CrtOverlap(std::vector<double> strip1, std::vector<double> strip2);
177 std::vector<std::pair<int,float>>> tpesmap,
float peshit,
double time,
int plane,
178 double x,
double ex,
double y,
double ey,
double z,
double ez, std::string
tagger);
181 double CorrectNpe(CRTStrip strip1, CRTStrip strip2, TVector3 position);
184 double CorrectTime(CRTStrip strip1, CRTStrip strip2, TVector3 position);
process_name opflash particleana ie ie ie z
fhicl::Atom< double > NpeScaleShift
fhicl::Atom< double > TDelayShift
process_name opflash particleana ie x
fhicl::Atom< double > PropDelay
Declaration of signal hit object.
fhicl::Atom< double > TDelayNorm
CRTStrip CreateCRTStrip(art::Ptr< sbnd::crt::CRTData > sipm1, art::Ptr< sbnd::crt::CRTData > sipm2, size_t ind)
fhicl::Atom< double > TDelayOffset
std::pair< std::string, unsigned > tagger
std::pair< double, double > DistanceBetweenSipms(art::Ptr< sbnd::crt::CRTData > sipm1, art::Ptr< sbnd::crt::CRTData > sipm2)
bool CheckModuleOverlap(uint32_t channel)
auto vector(Vector const &v)
Returns a manipulator which will print the specified array.
process_name opflash particleana ie ie y
CRTHitRecoAlg(const fhicl::ParameterSet &pset, double g4RefTime)
fhicl::Atom< double > QPed
void reconfigure(const Config &config)
std::map< std::pair< std::string, unsigned >, std::vector< CRTStrip > > CreateTaggerStrips(detinfo::DetectorClocksData const &clockData, detinfo::DetectorPropertiesData const &detProp, std::vector< art::Ptr< sbnd::crt::CRTData >> data)
fhicl::Atom< double > TimeOffset
fhicl::Atom< double > ClockSpeedCRT
double CorrectNpe(CRTStrip strip1, CRTStrip strip2, TVector3 position)
BEGIN_PROLOG vertical distance to the surface Name
std::vector< std::pair< sbn::crt::CRTHit, std::vector< int > > > CreateCRTHits(std::map< std::pair< std::string, unsigned >, std::vector< CRTStrip >> taggerStrips)
fhicl::Atom< bool > UseReadoutWindow
std::pair< std::string, unsigned > ChannelToTagger(uint32_t channel)
Provides recob::Track data product.
fhicl::Atom< double > TimeCoincidenceLimit
fhicl::Atom< double > QSlope
sbn::crt::CRTHit FillCrtHit(std::vector< uint8_t > tfeb_id, std::map< uint8_t, std::vector< std::pair< int, float >>> tpesmap, float peshit, double time, int plane, double x, double ex, double y, double ey, double z, double ez, std::string tagger)
Contains all timing reference information for the detector.
double fTimeCoincidenceLimit
std::vector< double > CrtOverlap(std::vector< double > strip1, std::vector< double > strip2)
std::vector< double > ChannelToLimits(CRTStrip strip)
stream1 can override from command line with o or output services user sbnd
double CorrectTime(CRTStrip strip1, CRTStrip strip2, TVector3 position)
fhicl::Atom< double > TDelaySigma
fhicl::Atom< bool > UseG4RefTimeOffset
CRTHitRecoAlg(const Config &config, double g4RefTime)