1 #ifndef QuickTrackAssociatorByHits_h
2 #define QuickTrackAssociatorByHits_h
108 static bool clusterTPAssociationListGreater(std::pair<OmniClusterRef, TrackingParticleRef>
i,std::pair<OmniClusterRef, TrackingParticleRef>
j) {
return (i.first.rawIndex()>j.first.rawIndex()); }
117 template<
class T_TrackCollection,
class T_TrackingParticleCollection,
class T_hitOrClusterAssociator>
126 template<
class T_TrackCollection,
class T_TrackingParticleCollection,
class T_hitOrClusterAssociator>
206 #endif // end of ifndef QuickTrackAssociatorByHits_h
reco::SimToRecoCollection associateSimToRecoImplementation(T_TrackCollection trackCollection, T_TrackingParticleCollection trackingParticleCollection, T_hitOrClusterAssociator hitOrClusterAssociator) const
The method that does the work for both overloads of associateSimToReco.
const TrackingRecHit * getHitFromIter(trackingRecHit_iterator iter) const
TrackAssociator that associates by hits a bit quicker than the normal TrackAssociatorByHits class...
static bool clusterTPAssociationListGreater(std::pair< OmniClusterRef, TrackingParticleRef > i, std::pair< OmniClusterRef, TrackingParticleRef > j)
const TrackingRecHit * getHitFromIter(TrackingRecHitCollection::const_iterator iter) const
bool trackingParticleContainsIdentifier(const TrackingParticle *pTrackingParticle, const SimTrackIdentifiers &identifier) const
Returns true if the supplied TrackingParticle has the supplied g4 track identifiers.
virtual reco::SimToRecoCollection associateSimToReco(edm::Handle< edm::View< reco::Track > > &trackCollectionHandle, edm::Handle< TrackingParticleCollection > &trackingParticleCollectionHandle, const edm::Event *pEvent=0, const edm::EventSetup *pSetup=0) const override
compare reco to sim the handle of reco::Track and TrackingParticle collections
QuickTrackAssociatorByHits(const edm::ParameterSet &config)
std::vector< std::pair< edm::Ref< TrackingParticleCollection >, size_t > > associateTrack(const TrackerHitAssociator &hitAssociator, T_TPCollection trackingParticles, iter begin, iter end) const
Returns the TrackingParticle that has the most associated hits to the given track.
static bool tpIntPairGreater(std::pair< edm::Ref< TrackingParticleCollection >, size_t > i, std::pair< edm::Ref< TrackingParticleCollection >, size_t > j)
std::pair< uint32_t, EncodedEventId > SimTrackIdentifiers
This is enough information to uniquely identify a sim track.
bool absoluteNumberOfHits_
bool threeHitTracksAreSpecial_
std::vector< std::pair< OmniClusterRef, TrackingParticleRef > > ClusterTPAssociationList
virtual reco::RecoToSimCollection associateRecoToSim(edm::Handle< edm::View< reco::Track > > &trackCollectionHandle, edm::Handle< TrackingParticleCollection > &trackingParticleCollectionHandle, const edm::Event *pEvent=0, const edm::EventSetup *pSetup=0) const override
compare reco to sim the handle of reco::Track and TrackingParticle collections
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
void prepareEitherHitAssociatorOrClusterToTPMap(const edm::Event *pEvent, std::unique_ptr< ClusterTPAssociationList > &pClusterToTPMap, std::unique_ptr< TrackerHitAssociator > &pHitAssociator) const
creates either a ClusterTPAssociationList OR a TrackerHitAssociator and stores it in the provided uni...
edm::ParameterSet hitAssociatorParameters_
int getDoubleCount(const TrackerHitAssociator &hitAssociator, iter begin, iter end, TrackingParticleRef associatedTrackingParticle) const
This method was copied almost verbatim from the standard TrackAssociatorByHits.
bool useClusterTPAssociation_
std::vector< std::pair< SimTrackIdentifiers, size_t > > getAllSimTrackIdentifiers(const TrackerHitAssociator &hitAssociator, iter begin, iter end) const
Returns a vector of pairs where first is a SimTrackIdentifiers (see typedef above) and second is the ...
QuickTrackAssociatorByHitsImpl::ClusterTPAssociationList ClusterTPAssociationList
std::vector< OmniClusterRef > getMatchedClusters(iter begin, iter end) const
reco::RecoToSimCollection associateRecoToSimImplementation(T_TrackCollection trackCollection, T_TrackingParticleCollection trackingParticleCollection, T_hitOrClusterAssociator hitOrClusterAssociator) const
The method that does the work for both overloads of associateRecoToSim.
Monte Carlo truth information used for tracking validation.
SimToRecoDenomType simToRecoDenominator_
~QuickTrackAssociatorByHits()
void setup(std::vector< TH2F > &depth, std::string name, std::string units="")
edm::InputTag cluster2TPSrc_
TrackingRecHitCollection::base::const_iterator trackingRecHit_iterator
iterator over a vector of reference to TrackingRecHit in the same collection