Pandora
Pandora source code navigator
Loading...
Searching...
No Matches
LArPandoraInput.h
Go to the documentation of this file.
1
7#ifndef LAR_PANDORA_INPUT_H
8#define LAR_PANDORA_INPUT_H 1
9
10namespace detinfo {
11 class DetectorPropertiesData;
12}
13
17
19
20namespace pandora {
21 class Pandora;
22}
23
24namespace lar_pandora {
25
30 public:
56
66 static void CreatePandoraHits2D(const art::Event& evt,
67 const Settings& settings,
68 const LArDriftVolumeMap& driftVolumeMap,
69 const HitVector& hitVector,
70 IdToHitMap& idToHitMap);
71
78 static void CreatePandoraLArTPCs(const Settings& settings,
79 const LArDriftVolumeList& driftVolumeList);
80
88 static void CreatePandoraDetectorGaps(const Settings& settings,
89 const LArDriftVolumeList& driftVolumeList,
90 const LArDetectorGapList& listOfGaps);
91
98 static void CreatePandoraReadoutGaps(const Settings& settings,
99 const LArDriftVolumeMap& driftVolumeMap);
100
108 static void CreatePandoraMCParticles(const Settings& settings,
109 const MCTruthToMCParticles& truthToParticles,
110 const MCParticlesToMCTruth& particlesToTruth,
111 const RawMCParticleVector& generatorMCParticleVector);
112
119 static void FindPrimaryParticles(const RawMCParticleVector& mcParticleVector,
120 std::map<const simb::MCParticle, bool>& primaryMCParticleMap);
121
128 static bool IsPrimaryMCParticle(const art::Ptr<simb::MCParticle>& mcParticle,
129 std::map<const simb::MCParticle, bool>& primaryMCParticleMap);
130
138 static void CreatePandoraMCLinks2D(const Settings& settings,
139 const HitMap& hitMap,
140 const HitsToTrackIDEs& hitToParticleMap);
141
142 private:
143 typedef std::map<std::string, lar_content::MCProcess> MCProcessMap;
144
153 static void GetTrueStartAndEndPoints(const Settings& settings,
154 const art::Ptr<simb::MCParticle>& particle,
155 int& startT,
156 int& endT);
157
167 static void GetTrueStartAndEndPoints(const geo::TPCID& ref_tpcid,
168 const art::Ptr<simb::MCParticle>& particle,
169 int& startT,
170 int& endT);
171
179 static float GetTrueX0(const art::Event& evt,
180 const art::Ptr<simb::MCParticle>& particle,
181 const int nT);
182
190 static double GetMips(const detinfo::DetectorPropertiesData& detProp,
191 const Settings& settings,
192 const double hit_Charge,
193 const geo::View_t hit_View);
194
200 static void FillMCProcessMap(MCProcessMap& processMap);
201 };
202
203} // namespace lar_pandora
204
205#endif // #ifndef LAR_PANDORA_INPUT_H
Interface class for LArPandora producer modules, which reconstruct recob::PFParticles from recob::Hit...
Header file for the lar mc particle class.
Helper functions for extracting detector geometry for use in reconsruction.
helper function for LArPandoraInterface producer module
const pandora::Pandora * m_pPrimaryPandora
LArPandoraInput class.
static void CreatePandoraReadoutGaps(const Settings &settings, const LArDriftVolumeMap &driftVolumeMap)
Create pandora line gaps to cover any (continuous regions of) bad channels.
static bool IsPrimaryMCParticle(const art::Ptr< simb::MCParticle > &mcParticle, std::map< const simb::MCParticle, bool > &primaryMCParticleMap)
Check whether an MCParticle can be found in a given map.
static void CreatePandoraDetectorGaps(const Settings &settings, const LArDriftVolumeList &driftVolumeList, const LArDetectorGapList &listOfGaps)
Create pandora line gaps to cover dead regions between TPCs in a global drift volume approach.
static float GetTrueX0(const art::Event &evt, const art::Ptr< simb::MCParticle > &particle, const int nT)
Use detector and time services to get a true X offset for a given trajectory point.
static void CreatePandoraHits2D(const art::Event &evt, const Settings &settings, const LArDriftVolumeMap &driftVolumeMap, const HitVector &hitVector, IdToHitMap &idToHitMap)
Create the Pandora 2D hits from the ART hits.
std::map< std::string, lar_content::MCProcess > MCProcessMap
static double GetMips(const detinfo::DetectorPropertiesData &detProp, const Settings &settings, const double hit_Charge, const geo::View_t hit_View)
Convert charge in ADCs to approximate MIPs.
static void CreatePandoraMCLinks2D(const Settings &settings, const HitMap &hitMap, const HitsToTrackIDEs &hitToParticleMap)
Create links between the 2D hits and Pandora MC particles.
static void FillMCProcessMap(MCProcessMap &processMap)
Populate a map from MC process string to enumeration.
static void FindPrimaryParticles(const RawMCParticleVector &mcParticleVector, std::map< const simb::MCParticle, bool > &primaryMCParticleMap)
Find all primary MCParticles in a given vector of MCParticles.
static void CreatePandoraMCParticles(const Settings &settings, const MCTruthToMCParticles &truthToParticles, const MCParticlesToMCTruth &particlesToTruth, const RawMCParticleVector &generatorMCParticleVector)
Create the Pandora MC particles from the MC particles.
static void GetTrueStartAndEndPoints(const Settings &settings, const art::Ptr< simb::MCParticle > &particle, int &startT, int &endT)
Loop over MC trajectory points and identify start and end points within the detector.
static void CreatePandoraLArTPCs(const Settings &settings, const LArDriftVolumeList &driftVolumeList)
Create pandora LArTPCs to represent the different drift volumes in use.
Pandora class.
Definition Pandora.h:40
std::map< art::Ptr< simb::MCParticle >, art::Ptr< simb::MCTruth > > MCParticlesToMCTruth
std::map< art::Ptr< recob::Hit >, TrackIDEVector > HitsToTrackIDEs
std::vector< simb::MCParticle > RawMCParticleVector
std::map< art::Ptr< simb::MCTruth >, MCParticleVector > MCTruthToMCParticles
std::vector< art::Ptr< recob::Hit > > HitVector
std::map< int, art::Ptr< recob::Hit > > HitMap
std::map< int, art::Ptr< recob::Hit > > IdToHitMap
Definition ILArPandora.h:24
std::vector< LArDetectorGap > LArDetectorGapList
std::vector< LArDriftVolume > LArDriftVolumeList
std::map< unsigned int, LArDriftVolume > LArDriftVolumeMap