7 #ifndef LAR_PANDORA_HELPER_H 8 #define LAR_PANDORA_HELPER_H 23 class ParticleFlowObject;
40 class PFParticleMetadata;
55 typedef std::set<art::Ptr<recob::Hit>>
HitList;
58 typedef std::vector<art::Ptr<recob::Hit>>
HitVector;
72 typedef std::vector<art::Ptr<anab::T0>>
T0Vector;
73 typedef std::vector<art::Ptr<larpandoraobj::PFParticleMetadata>>
MetadataVector;
75 typedef std::unordered_set<art::Ptr<recob::Hit>>
HitSet;
108 typedef std::map<int, art::Ptr<recob::Hit>>
HitMap;
125 kIgnoreDaughters = 0,
139 WireVector& wireVector);
159 PFParticleVector& particleVector);
171 SpacePointVector& spacePointVector,
172 SpacePointsToHits& spacePointsToHits);
185 SpacePointVector& spacePointVector,
186 SpacePointsToHits& spacePointsToHits,
187 HitsToSpacePoints& hitsToSpacePoints);
199 ClusterVector& clusterVector,
200 ClustersToHits& clustersToHits);
212 PFParticleVector& particleVector,
213 PFParticlesToSpacePoints& particlesToSpacePoints);
225 PFParticleVector& particleVector,
226 PFParticlesToClusters& particlesToClusters);
238 PFParticleVector& particleVector,
239 PFParticlesToMetadata& particlesToMetadata);
251 ShowerVector& showerVector,
252 PFParticlesToShowers& particlesToShowers);
264 ShowerVector& showerVector,
265 ShowersToHits& showersToHits);
277 TrackVector& trackVector,
278 PFParticlesToTracks& particlesToTracks);
290 TrackVector& trackVector,
291 TracksToHits& tracksToHits);
303 SeedVector& seedVector,
304 PFParticlesToSeeds& particlesToSeeds);
316 SeedVector& seedVector,
317 SeedsToHits& seedsToHits);
329 VertexVector& vertexVector,
330 PFParticlesToVertices& particlesToVertices);
342 static void BuildPFParticleHitMaps(
const PFParticleVector& particleVector,
343 const PFParticlesToSpacePoints& particlesToSpacePoints,
344 const SpacePointsToHits& spacePointsToHits,
345 PFParticlesToHits& particlesToHits,
346 HitsToPFParticles& hitsToParticles,
359 static void BuildPFParticleHitMaps(
const PFParticleVector& particleVector,
360 const PFParticlesToClusters& particlesToClusters,
361 const ClustersToHits& clustersToHits,
362 PFParticlesToHits& particlesToHits,
363 HitsToPFParticles& hitsToParticles,
380 PFParticlesToHits& particlesToHits,
381 HitsToPFParticles& hitsToParticles,
383 const bool useClusters =
true);
397 PFParticlesToHits& particlesToHits,
398 HitsToPFParticles& hitsToParticles,
400 const bool useClusters =
true);
412 CosmicTagVector& cosmicTagVector,
413 TracksToCosmicTags& tracksToCosmicTags);
426 PFParticlesToT0s& particlesToT0s);
438 SimChannelVector& simChannelVector,
439 bool& areSimChannelsValid);
450 MCParticleVector& particleVector);
460 static void CollectGeneratorMCParticles(
const art::Event&
evt,
462 RawMCParticleVector& particleVector);
474 MCTruthToMCParticles& truthToParticles,
475 MCParticlesToMCTruth& particlesToTruth);
486 const HitVector& hitVector,
487 const SimChannelVector& simChannelVector,
488 HitsToTrackIDEs& hitsToTrackIDEs);
499 static void BuildMCParticleHitMaps(
const HitsToTrackIDEs& hitsToTrackIDEs,
500 const MCTruthToMCParticles& truthToParticles,
501 MCParticlesToHits& particlesToHits,
502 HitsToMCParticles& hitsToParticles,
517 const HitVector& hitVector,
518 MCParticlesToHits& particlesToHits,
519 HitsToMCParticles& hitsToParticles,
533 HitsToTrackIDEs& hitsToTrackIDEs);
550 MCParticlesToHits& particlesToHits,
551 HitsToMCParticles& hitsToParticles,
563 template <
typename T>
567 HitVector& associatedHits,
576 static void SelectNeutrinoPFParticles(
const PFParticleVector& inputParticles,
577 PFParticleVector& outputParticles);
585 static void SelectFinalStatePFParticles(
const PFParticleVector& inputParticles,
586 PFParticleVector& outputParticles);
594 static void BuildMCParticleMap(
const MCParticleVector& particleVector,
595 MCParticleMap& particleMap);
603 static void BuildPFParticleMap(
const PFParticleVector& particleVector,
604 PFParticleMap& particleMap);
615 const PFParticleMap& particleMap,
627 const PFParticleMap& particleMap,
639 const MCParticleMap& particleMap,
651 const MCParticleMap& particleMap,
671 static int GetGeneration(
const PFParticleMap& particleMap,
682 static int GetParentNeutrino(
const PFParticleMap& particleMap,
693 static bool IsFinalState(
const PFParticleMap& particleMap,
740 const pandora::ParticleFlowObject*
const pPfo);
745 #endif // LAR_PANDORA_HELPER_H std::vector< art::Ptr< simb::MCTruth > > MCTruthVector
std::map< art::Ptr< recob::Hit >, art::Ptr< simb::MCParticle > > HitsToMCParticles
std::map< int, art::Ptr< sim::SimChannel > > SimChannelMap
SlicingAlgorithm::Slice Slice
bool IsNeutrino(int pdgc)
Reconstruction base classes.
std::unordered_set< art::Ptr< recob::Hit > > HitSet
std::map< art::Ptr< recob::PFParticle >, ClusterVector > PFParticlesToClusters
std::map< int, HitVector > HitArray
std::map< art::Ptr< simb::MCTruth >, HitVector > MCTruthToHits
std::map< art::Ptr< simb::MCParticle >, art::Ptr< simb::MCTruth > > MCParticlesToMCTruth
std::map< art::Ptr< simb::MCParticle >, art::Ptr< recob::PFParticle > > MCParticlesToPFParticles
std::vector< art::Ptr< recob::Shower > > ShowerVector
std::vector< int > IntVector
std::vector< art::Ptr< anab::CosmicTag > > CosmicTagVector
std::map< art::Ptr< recob::PFParticle >, TrackVector > PFParticlesToTracks
std::map< art::Ptr< recob::PFParticle >, VertexVector > PFParticlesToVertices
std::map< int, art::Ptr< recob::Hit > > HitMap
std::map< int, art::Ptr< recob::PFParticle > > PFParticleMap
std::map< art::Ptr< recob::Track >, CosmicTagVector > TracksToCosmicTags
std::map< int, art::Ptr< simb::MCParticle > > MCParticleMap
std::map< art::Ptr< recob::Hit >, TrackIDEVector > HitsToTrackIDEs
std::vector< art::Ptr< recob::Seed > > SeedVector
std::map< art::Ptr< recob::PFParticle >, MetadataVector > PFParticlesToMetadata
std::map< art::Ptr< recob::PFParticle >, T0Vector > PFParticlesToT0s
std::map< art::Ptr< recob::Hit >, art::Ptr< simb::MCTruth > > HitsToMCTruth
std::map< int, art::Ptr< recob::Cluster > > ClusterMap
std::map< art::Ptr< recob::PFParticle >, ShowerVector > PFParticlesToShowers
std::vector< simb::MCParticle > RawMCParticleVector
Metadata associated to PFParticles.
std::map< art::Ptr< simb::MCParticle >, HitVector > MCParticlesToHits
std::map< art::Ptr< recob::PFParticle >, SeedVector > PFParticlesToSeeds
std::vector< art::Ptr< recob::PFParticle > > PFParticleVector
std::map< art::Ptr< recob::Cluster >, HitVector > ClustersToHits
std::map< art::Ptr< recob::Shower >, HitVector > ShowersToHits
std::map< art::Ptr< simb::MCTruth >, MCParticleVector > MCTruthToMCParticles
std::map< art::Ptr< simb::MCTruth >, art::Ptr< recob::PFParticle > > MCTruthToPFParticles
std::vector< art::Ptr< recob::SpacePoint > > SpacePointVector
std::map< art::Ptr< recob::PFParticle >, HitVector > PFParticlesToHits
std::map< art::Ptr< recob::Hit >, art::Ptr< recob::SpacePoint > > HitsToSpacePoints
std::vector< art::Ptr< simb::MCParticle > > MCParticleVector
std::vector< sim::TrackIDE > TrackIDEVector
std::vector< art::Ptr< larpandoraobj::PFParticleMetadata > > MetadataVector
std::vector< art::Ptr< recob::Track > > TrackVector
std::map< art::Ptr< recob::PFParticle >, SpacePointVector > PFParticlesToSpacePoints
std::map< art::Ptr< recob::Track >, HitVector > TracksToHits
std::map< int, art::Ptr< recob::SpacePoint > > SpacePointMap
Code to link reconstructed objects back to the MC truth information.
Base utilities and modules for event generation and detector simulation.
DaughterMode
DaughterMode enumeration.
std::map< const pandora::ParticleFlowObject *, size_t > ThreeDParticleMap
std::vector< art::Ptr< recob::Hit > > HitVector
std::vector< art::Ptr< sim::SimChannel > > SimChannelVector
std::vector< art::Ptr< recob::Wire > > WireVector
std::map< art::Ptr< recob::Hit >, art::Ptr< recob::PFParticle > > HitsToPFParticles
std::vector< art::Ptr< recob::Vertex > > VertexVector
boost::graph_traits< ModuleGraph >::vertex_descriptor Vertex
TrackCollectionProxyElement< TrackCollProxy > Track
Proxy to an element of a proxy collection of recob::Track objects.
std::vector< art::Ptr< recob::Cluster > > ClusterVector
std::vector< art::Ptr< anab::T0 > > T0Vector
std::map< art::Ptr< recob::Seed >, art::Ptr< recob::Hit > > SeedsToHits
std::map< const pandora::Vertex *, unsigned int > ThreeDVertexMap
std::set< art::Ptr< recob::Hit > > HitList
std::map< art::Ptr< recob::SpacePoint >, art::Ptr< recob::Hit > > SpacePointsToHits